On Feb 13, 2010, at 11:03 AM, avdd wrote: > I'm getting some strange errors with unpickling. I've tried all > combinations of pickle/cPickle and protocol in (0,1,2) and still > getting this apparent random error: > > sqlalchemy.orm.collections:622 __setstate__ > self.attr = getattr(d['owner_state'].obj().__class__, > d['key']).impl > AttributeError: type object 'NoneType' has no attribute 'flights' > > When I inspect this frame, I see that: > >>>> d['owner_state'].obj > <bound method InstanceState.obj of <sqlalchemy.orm.state.InstanceState > object at 0xa1b5acc>> > > So it seems that __setstate__ is not being called for the > InstanceState object.
pickling of instances (using 0.5.8 or 0.6beta) is widely tested and used successfully in great volume, so you'd have to provide more specifics. note that pickle formats may not be entirely compatible coming from an older version of 0.5 (like pre 0.5.5) and 0.6. > > Any ideas? > > -- > You received this message because you are subscribed to the Google Groups > "sqlalchemy" 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/sqlalchemy?hl=en. > -- You received this message because you are subscribed to the Google Groups "sqlalchemy" 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/sqlalchemy?hl=en.
