Re: [sqlalchemy] SQLAlchemy 0.8 issue: with appending items to relationship

2013-10-13 Thread Michael Bayer
I'm glad you're still poking because I'm still not seeing anything that would trigger this warning. Here is that exact code in a test case, I can't get it to produce the warning: from sqlalchemy import * from sqlalchemy.orm import * from sqlalchemy.ext.declarative import declarative_base Base

Re: [sqlalchemy] SQLAlchemy 0.8 issue: with appending items to relationship

2013-10-13 Thread Marc Van Olmen
I did some more digging today to see If I can pin down the exact reason: I tested with a unit test, and reduced the code above to bare minimum and not doing references to collections anymore. def serials(self): requiredAmountOfSerials = self.quantity if requiredAmountOfSeria

Re: [sqlalchemy] SQLAlchemy 0.8 issue: with appending items to relationship

2013-10-13 Thread Marc Van Olmen
Michael, Thanks always for your time! amazing those details answers. I looked at the code and see they did something like this: beforeSerials = self._serials[:] Then a few lines later followed by: self._serials.append(MetaSerial(value=u')) Then followed by afterSeria

Re: [sqlalchemy] SQLAlchemy 0.8 issue: with appending items to relationship

2013-10-12 Thread Michael Bayer
On Oct 12, 2013, at 11:54 AM, Marc Van Olmen wrote: > hi, > > Just wanted to quickly report this issue, didn't had time to write unit test > for corning the case: > Was upgrading an 0.4.8 legacy project to 0.8.2 > > Got an SAWarning: This collection has been invalidated in the following case:

[sqlalchemy] SQLAlchemy 0.8 issue: with appending items to relationship

2013-10-12 Thread Marc Van Olmen
hi, Just wanted to quickly report this issue, didn't had time to write unit test for corning the case: Was upgrading an 0.4.8 legacy project to 0.8.2 Got an SAWarning: This collection has been invalidated in the following case: Original 0.4.8 code: self._serials.append(MetaSerial(