Jon Nelson wrote:
>
> I encountered an odd issue today that I can't explain, and it seems like a
> bug.
> I've checked 0.5.4p2 and 0.5.5, and the behavior is the same.

its a mistake I've seen before.  Backrefs change the collection, so the
iteration ends up granting only every other item.

   # solution
   for child in list(root.children):
        child.parent = new_root


also the root.parent = root thing will require post_update, see the mapper
docs for this.



--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to