-
Notifications
You must be signed in to change notification settings - Fork 21.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't remove transactional callbacks deprecation warning (issued from gems) #18084
Comments
This is a huge problem at thinking_sphinx, it means that any Active Record configuration you place in your application will not be applied because thinking_sphinx already loaded You should open an issue there. |
I am unable to extinguish warning also. Im not using thinking_sphinx. |
@atstockland the warning should mention a line of code which is causing it to be loaded early - the example above by @Envek is from Thining Sphinx. What's that line of code for you? |
Hi @pat. Here is the full trace when I load the console. You can opt into the new behavior and remove this warning by setting: config.active_record.raise_in_transactional_callbacks = true (called from require at /Users/Hank/.rvm/gems/ruby-2.1.5@global/gems/bundler-1.7.6/lib/bundler/runtime.rb:76) I don't have any after_rollback or after_commit calls, so its coming from a gem. I updated gems and bundler... Any ideas? Thanks. |
After updating gem bundler (again)...now I get a more meaningful message. (called from <top (required)> at /Users/Hank/Sites/StudentFlightRecord/config/application.rb:14). Line 14 is Bundler.require(*Rails.groups). |
Sounds like there's something in your Gemfile that's loading AR stuff too quickly? Shame the warning message doesn't give a few lines to make it more obvious. |
Ya. Ill run through gem versions again...maybe I still have one that is outdated. Or, Ill remove all gems and add back one at a time and see who is to blame. Thanks @pat. |
This is not a support forum, please take this to Stack Overflow, or email each other. The contributor team is getting emailed every time you post here. |
This prevents deprecation message for `after_rollback`/`after_commit` similar to rails/rails#18084
I'm trying to upgrade my app to upcoming Rails 4.2 (RC 3) and according to upgrading manual I've placed next string to
config/application.rb
:But I still getting next output immediately after
rails server
:After some playing with
puts
inconfig/application.rb
I've encountered that thinking_sphinx's file/lib/thinking_sphinx/active_record/base.rb
is getting required before the most part of my app'sconfig/application.rb
is executed.At this point I've using code from today's
develop
branch of thinking sphinx. I've tried to roll back to published version 3.1.2 and then I've get this warning issued somewhere frombundler
:~/.rvm/gems/ruby-2.1.5-gost@global/gems/bundler-1.7.6/lib/bundler/runtime.rb:76
. I've played with puts more and encountered that it's issued while requiring gem better_errors, but it seems unrelated to Active Record at all. Weird.Any ideas how to solve this?
The text was updated successfully, but these errors were encountered: