heartcombo / devise

Flexible authentication solution for Rails with Warden.
http://blog.plataformatec.com.br/tag/devise/
MIT License
23.97k stars 5.55k forks source link

Use a dedicated ActiveSupport::Deprecation #5583

Closed etiennebarrie closed 1 year ago

etiennebarrie commented 1 year ago

Rails 7.1 will deprecate using the singleton ActiveSupport::Deprecation instance (https://github.com/rails/rails/pull/47354). This defines one for the gem and uses it.

RailsCod3rFuture commented 1 year ago

Hope to see these depreciation issues fixed before Rails 7.1 official release. I was playing around with MRSK. Doesn't seem plausible just yet.

carlosantoniodasilva commented 1 year ago

I was playing around with MRSK. Doesn't seem plausible just yet.

@RailsCod3rFuture I'm not sure how this relates to the changes here? You mean the deprecations are causing you trouble with MRSK?

RailsCod3rFuture commented 1 year ago

I was playing around with MRSK. Doesn't seem plausible just yet.

@RailsCod3rFuture I'm not sure how this relates to the changes here? You mean the deprecations are causing you trouble with MRSK?

The rails server doesn't start on rails 7.1 as a result of the ActiveSupport::Deprecation instance. If someone else can check on their end for an r 7.1. app, that should confirm the symptoms that I'm experiencing. Thanks!

carlosantoniodasilva commented 1 year ago

@RailsCod3rFuture so I'd guess this is not a Devise problem, but an MRSK problem? I mean, I see no reason why the deprecations would prevent Devise from working. (I'm not saying we aren't gonna fix it, just mentioning it shouldn't break stuff like that imo.)

RailsCod3rFuture commented 1 year ago

@RailsCod3rFuture so I'd guess this is not a Devise problem, but an MRSK problem? I mean, I see no reason why the deprecations would prevent Devise from working. (I'm not saying we aren't gonna fix it, just mentioning it shouldn't break stuff like that imo.)

This is the exception that I receive while launching the rails app for 7.1

/bin/zsh -c "bash -c 'env RBENV_VERSION=3.1.2 /usr/local/Cellar/rbenv/1.2.0/libexec/rbenv exec ruby /Users/dwood/RubymineProjects/test_app/bin/rails server -b 0.0.0.0 -p 3000 -e development'"
DEPRECATION WARNING: DeprecatedConstantAccessor.deprecate_constant without a deprecator is deprecated (called from <module:Authenticatable> at /Users/dwood/.rbenv/versions/3.1.2/lib/ruby/gems/3.1.0/gems/devise-4.8.1/lib/devise/models/authenticatable.rb:65)
/Users/dwood/.rbenv/versions/3.1.2/lib/ruby/gems/3.1.0/gems/bootsnap-1.10.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:15:in `require': cannot load such file -- polyamorous/activerecord_7.1_ruby_2/join_association (LoadError)
etiennebarrie commented 1 year ago

I think you're just seeing the deprecation just above your real issue with polyamorous.

RailsCod3rFuture commented 1 year ago

I think you're just seeing the deprecation just above your real issue with polyamorous.

Good catch. I'll probably have to reach out to the ransack team on that note....see if they have any solutions or knowledge of this issue.