actionpack-action_caching: Broken by Rails 6.1?
Upgraded to Ruby 2.7.2 and Rails 6.1 and I get the following error running under Rails 6.1. Works fine with Rails 6.0.3.4
NoMethodError: undefined method
eager_autoload’ for ActionController::Caching:Module
/home/dev/.rvm/gems/ruby-2.7.2/gems/actionpack-action_caching-1.2.1/lib/action_controller/action_caching.rb:5:in <module:Caching>' /home/dev/.rvm/gems/ruby-2.7.2/gems/actionpack-action_caching-1.2.1/lib/action_controller/action_caching.rb:4:in
module:ActionController’
/home/dev/.rvm/gems/ruby-2.7.2/gems/actionpack-action_caching-1.2.1/lib/action_controller/action_caching.rb:3:in <top (required)>' /home/dev/.rvm/gems/ruby-2.7.2/gems/zeitwerk-2.4.2/lib/zeitwerk/kernel.rb:34:in
require’
/home/dev/.rvm/gems/ruby-2.7.2/gems/zeitwerk-2.4.2/lib/zeitwerk/kernel.rb:34:in require' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/dependencies.rb:332:in
block in require’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/dependencies.rb:299:in load_dependency' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/dependencies.rb:332:in
require’
/home/dev/.rvm/gems/ruby-2.7.2/gems/actionpack-action_caching-1.2.1/lib/actionpack/action_caching/railtie.rb:8:in block (2 levels) in <class:Railtie>' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:71:in
class_eval’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:71:in block in execute_hook' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:61:in
with_execution_control’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:66:in execute_hook' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:52:in
block in run_load_hooks’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:51:in each' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:51:in
run_load_hooks’
/home/dev/.rvm/gems/ruby-2.7.2/gems/actionpack-6.1.0/lib/action_controller/api.rb:148:in <class:API>' /home/dev/.rvm/gems/ruby-2.7.2/gems/actionpack-6.1.0/lib/action_controller/api.rb:89:in
module:ActionController’
/home/dev/.rvm/gems/ruby-2.7.2/gems/actionpack-6.1.0/lib/action_controller/api.rb:7:in <top (required)>' /home/dev/.rvm/gems/ruby-2.7.2/gems/zeitwerk-2.4.2/lib/zeitwerk/kernel.rb:34:in
require’
/home/dev/.rvm/gems/ruby-2.7.2/gems/zeitwerk-2.4.2/lib/zeitwerk/kernel.rb:34:in require' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/dependencies.rb:332:in
block in require’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/dependencies.rb:299:in load_dependency' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/dependencies.rb:332:in
require’
/home/dev/.rvm/gems/ruby-2.7.2/gems/jbuilder-2.10.1/lib/jbuilder/railtie.rb:20:in block (2 levels) in <class:Railtie>' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:71:in
class_eval’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:71:in block in execute_hook' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:61:in
with_execution_control’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:66:in execute_hook' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:52:in
block in run_load_hooks’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:51:in each' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:51:in
run_load_hooks’
/home/dev/.rvm/gems/ruby-2.7.2/gems/actionpack-6.1.0/lib/action_controller/base.rb:271:in <class:Base>' /home/dev/.rvm/gems/ruby-2.7.2/gems/actionpack-6.1.0/lib/action_controller/base.rb:166:in
module:ActionController’
/home/dev/.rvm/gems/ruby-2.7.2/gems/actionpack-6.1.0/lib/action_controller/base.rb:7:in <top (required)>' /home/dev/.rvm/gems/ruby-2.7.2/gems/zeitwerk-2.4.2/lib/zeitwerk/kernel.rb:34:in
require’
/home/dev/.rvm/gems/ruby-2.7.2/gems/zeitwerk-2.4.2/lib/zeitwerk/kernel.rb:34:in require' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/dependencies.rb:332:in
block in require’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/dependencies.rb:299:in load_dependency' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/dependencies.rb:332:in
require’
/home/dev/.rvm/gems/ruby-2.7.2/gems/railties-6.1.0/lib/rails/engine.rb:506:in helpers' /home/dev/.rvm/gems/ruby-2.7.2/gems/railties-6.1.0/lib/rails/railtie.rb:207:in
public_send’
/home/dev/.rvm/gems/ruby-2.7.2/gems/railties-6.1.0/lib/rails/railtie.rb:207:in method_missing' /home/dev/.rvm/gems/ruby-2.7.2/gems/actiontext-6.1.0/lib/action_text/engine.rb:42:in
block (3 levels) in class:Engine’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:71:in class_eval' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:71:in
block in execute_hook’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:61:in with_execution_control' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:66:in
execute_hook’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:43:in block in on_load' /home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:42:in
each’
/home/dev/.rvm/gems/ruby-2.7.2/gems/activesupport-6.1.0/lib/active_support/lazy_load_hooks.rb:42:in on_load' /home/dev/.rvm/gems/ruby-2.7.2/gems/actiontext-6.1.0/lib/action_text/engine.rb:41:in
block (2 levels) in class:Engine’
/home/dev/.rvm/gems/ruby-2.7.2/gems/actiontext-6.1.0/lib/action_text/engine.rb:40:in each' /home/dev/.rvm/gems/ruby-2.7.2/gems/actiontext-6.1.0/lib/action_text/engine.rb:40:in
block in class:Engine’
/home/dev/.rvm/gems/ruby-2.7.2/gems/railties-6.1.0/lib/rails/initializable.rb:32:in instance_exec' /home/dev/.rvm/gems/ruby-2.7.2/gems/railties-6.1.0/lib/rails/initializable.rb:32:in
run’
/home/dev/.rvm/gems/ruby-2.7.2/gems/railties-6.1.0/lib/rails/initializable.rb:61:in block in run_initializers' /home/dev/.rvm/gems/ruby-2.7.2/gems/railties-6.1.0/lib/rails/initializable.rb:60:in
run_initializers’
/home/dev/.rvm/gems/ruby-2.7.2/gems/railties-6.1.0/lib/rails/application.rb:384:in initialize!'
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 12
- Comments: 18 (3 by maintainers)
@rafaelfranca @sikachu Hello, is it possible to release it to RubyGems please ? That would be awesome we really need it for Rails 6.1 ♥️ We still heavily using it and removing it is not that easy 😒
@rafaelfranca @sikachu @matthewd can you release this Gems with 6.1 support please?
@rafaelfranca should we do another release for Rails 6.1 support?
Sorry for being a little late - had to fix some servers over the weekend 😩
Have pushed a new version now: https://rubygems.org/gems/actionpack-action_caching/versions/1.2.2
@sikachu, thanks for merging the pull and getting this fixed. It works for me on master (7bdfa663274a2620dde8daad7dcb995c1cfef840). Is there going to be a new gem released?
@attenzione if no-one gets to it before then I’ll do it at the weekend
@exocode Hmm. You should be fine with that. I don’t even define the branch, just the GitHub, and it’s been working for me. Have you tried
bundle update actionpack-action_caching
or nuking the Gemfile.lock and running bundle again? Seems like something isn’t reading that in. Might also tryrequire actionpack/action_caching
at the top of that file to see if you can push it down to the controller level (although I don’t need that in my 6.1.3.1/2.7.2 app).