[undo] when we can't undo an inlined relation change, point at None, not a broken eid
authorJulien Cristau <julien.cristau@logilab.fr>
Fri, 16 Jan 2015 10:56:30 +0100
changeset 10206 0ecd61f4bd37
parent 10205 737271ffe407
child 10207 5ec5d17b5e5b
[undo] when we can't undo an inlined relation change, point at None, not a broken eid This whole thing is "a bit" weird.
server/sources/native.py
--- a/server/sources/native.py	Thu Jan 15 19:17:32 2015 +0100
+++ b/server/sources/native.py	Fri Jan 16 10:56:30 2015 +0100
@@ -1151,6 +1151,7 @@
                         err(cnx._("can't restore entity %(eid)s of type %(eschema)s, "
                                       "target of %(rtype)s (eid %(value)s) does not exist any longer")
                             % locals())
+                        changes[column] = None
             elif eschema.destination(rtype) in ('Bytes', 'Password'):
                 changes[column] = self._binary(value)
                 edited[rtype] = Binary(value)