@new_record round trip with associations problem #3720

kennyj opened this Issue Nov 22, 2011 · 3 comments


None yet

3 participants

kennyj commented Nov 22, 2011

When investigating to fix the warning, I faced a strange problem.

The next testcase is failed (line no 1920).

This problem is reproduced on cruby 1.9.2-p180 and 1.9.3-p0, but one isn't reproduced (success) on ree-1.8.7-2011.03

It seems that there is @new_record instance variable in dump string, but loaded object is not defined @new_record.

related to #2431 ?

/cc @jonleighton

@carlosantoniodasilva carlosantoniodasilva added a commit to carlosantoniodasilva/rails that referenced this issue Mar 4, 2012
@carlosantoniodasilva carlosantoniodasilva Initialize @stale_state to nil in association
This apparently fix the warning related to @new_record variable not
being initialized in AR's test suit, when an association is built and
the object is marshalled/loaded.

See these tests in AR's base_test.rb:


Closes #3720.

Was this fixed when #5268 was merged?


@steveklabnik yes, I believe so. My bad, I completely forgot to close this one. Thanks!



Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment