When I Upgraded application from rails 5.2 to 6.0.0.alpha, application starts getting crash showing error on sign_in page.
Started GET "/admins/sign_in" for 127.0.0.1 at 2018-06-05 08:23:21 +0530
(1.9ms) SELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC
↳ /home/rotlu_crush/.rvm/gems/ruby-2.4.1/gems/activerecord-5.2.0/lib/active_record/log_subscriber.rb:98
ActionController::RoutingError (undefined local variable or method `mimes_for_respond_to' for DeviseController:Class):
devise (4.4.3) app/controllers/devise_controller.rb:18:in `<class:DeviseController>'
devise (4.4.3) app/controllers/devise_controller.rb:4:in `<main>'
bootsnap (1.3.0) lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:100:in `load'
bootsnap (1.3.0) lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:100:in `load'
activesupport (5.2.0) lib/active_support/dependencies.rb:468:in `block in load_file'
activesupport (5.2.0) lib/active_support/dependencies.rb:653:in `new_constants_in'
activesupport (5.2.0) lib/active_support/dependencies.rb:467:in `load_file'
Devise wouldn't crash, It should work with rails 6.0.0.alpha
I think that "responders" does not support Rails 6.0.x yet.
If you take a look at responders.gemspec you will see the following lines:
s.add_dependency "railties", ">= 4.2.0", "< 6.0"
s.add_dependency "actionpack", ">= 4.2.0", "< 6.0"
So, responders gem requires "railties < 6.0.x", but you are using railties >= 6.0.x
Rails 6 is really early in development and devise or responders have no plan to support a version of rails that early. We will fix those issue before the 6.0.0.beta release.
I am on current master and still having the same issue will it be fixed within January 15: Beta 1 as mentioned in https://weblog.rubyonrails.org/2018/12/20/timeline-for-the-release-of-Rails-6-0/.
Thanks.
gem 'responders', github: 'plataformatec/responders'
Same problem with rails 6.0.0.beta1
Like @nikolaokonesh pointed out above, it's a matter of updating the responders dependency. I'm going to work on this and send a pull request.
It works now with responders 2.4.1.
I think a bundle update responders for existing applications might do it.
Most helpful comment
gem 'responders', github: 'plataformatec/responders'