I’ve dug through the code and bit and cannot figure out how or why this
is, but between Rails 2.1 and 22.214.171.124 production ActiveResource objects
became frozen upon retrieval.
class Resource < ActiveRecource::Base
@my_thing ||= Finder.find_by_something( self.a_thing )
@resource = Resource.find_by_id( a_number )
@resource.frozen? #=> true
@resource.my_thing #=> TypeError: can’t modify frozen object
In 2.1 returned objects were not frozen, and in 126.96.36.199’s development
mode they are not. Disabling caches didn’t help.
Is it something from the LibXML/Nokogiri move? Anyone else using
ActiveResource on 188.8.131.52?
Matthew B. :: 607 227 0871
Resume & Portfolio @ http://madhatted.com