Displaying 2 results from an estimated 2 matches for "callbacks_for".
2007 Sep 05
2
after_create callback called twice in test env when using fixtures
All,
I''ve been trying to figure out a strange bug in one of my applications
that I think I''ve narrowed down to a problem with rails fixtures. It
seems as though the after_create callback is being run twice when I
save a record. This is only happening a) in the test environment, and
b) when there is a fixture file for that table.
The test below only prints "Doing
2006 Aug 15
0
SystemStackError: stack level too deep
..../script/../config/../config/../vendor/rails/activerecord/lib/../../activesupport/lib/active_support/core_ext/class/inheritable_attributes.rb:100:in
`read_inheritable_attribute''
from
./script/../config/../config/../vendor/rails/activerecord/lib/active_record/callbacks.rb:354:in
`callbacks_for''
from
./script/../config/../config/../vendor/rails/activerecord/lib/active_record/callbacks.rb:330:in
`callback''
from
./script/../config/../config/../vendor/rails/activerecord/lib/active_record/callbacks.rb:296:in
`valid?''
from
./script/../con...