Select.replace must properly reset old node's parent attribute
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Tue, 19 Jul 2011 18:10:56 +0200
changeset 641 f813dfc090ed
parent 640 e154f58bb9d6
child 642 1f4c9c361cd4
Select.replace must properly reset old node's parent attribute
ChangeLog
stmts.py
--- a/ChangeLog	Thu Jul 07 14:05:59 2011 +0200
+++ b/ChangeLog	Tue Jul 19 18:10:56 2011 +0200
@@ -7,6 +7,8 @@
     * rql annotator add 'having' list into variable's stinfo, and
       properly update variable graph
 
+    * Select.replace must properly reset old node's parent attribute
+
     * new undo_modification context manager on select nodes
 
 2011-06-09  --  0.29.0
--- a/stmts.py	Thu Jul 07 14:05:59 2011 +0200
+++ b/stmts.py	Tue Jul 19 18:10:56 2011 +0200
@@ -708,8 +708,7 @@
             raise Exception('duh XXX %s' % oldnode)
         # XXX no undo/reference support 'by design' (eg breaks things if you add
         # it...)
-        # XXX resetting oldnode parent cause pb with cw.test_views (w/ facets)
-        #oldnode.parent = None
+        oldnode.parent = None
         newnode.parent = self
         return oldnode, self, None