On 6 Jan 2009, at 12:52, Mark Reginald James wrote: >> >> ---------- >> >> What is going on here? This is so anti-intuitive - how could a bug >> like this exist and not have been detected hundreds of times before? > > Yes, I would regard this as a Rails bug. > The clear method is not setting the foreign key to > nil on the in-memory object. > Even if it were setting it on the in memory object it wouldn't be in memory object you think it is. Because a was reloaded, the objects in a.steps are not the objects b & c (although they do correspond to the same database rows).
Fred > It's only being manifest though because of the > unnecessary saves you're doing, meaning that > the problem has probably been rarely seen. > > -- > Rails Wheels - Find Plugins, List & Sell Plugins - http://railswheels.com > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

