Open TALlama opened 12 years ago
I forgot to add that this bug causes slightly different effects when what you've marshaled is an ActiveRecord object with a has_many
association to a group of audited ActiveRecord objects: the group fails to load
just the same, but Rails provides you with the incredibly unhelpful error message dump format error for symbol(0x30)
, which only makes sense after you know that the thing that ActiveRecord::Association
got back is a symbol (:@audit_comment
) and not the ActiveRecord::Base
object it was expecting.
I'm running into this 'dump format error for symbol' error as well.
Does anyone have a solution/work-around?
My workaround was to stop using the audited gem and come back to it later. Wish I had better news than that. :-1:
So the same workaround as me then ;-)
Round-tripping of a collection of ActiveRecord objects fails when the ActiveRecord class being marshaled is
audited
. When marshaling two objects, the first object round-trips fine but the second is replaced by the symbol:@audit_comment
(and the third is nil, if there is a third object).See full Rails app here: http://cl.ly/HTuL
I don't see where in the audited gem this might be happening; there's no
_dump
ormarshal_dump
overrides and no monkey-patching ofMarshal
. But it certainly is happening.