[FIX] openerp.api.Environment: move recomputation todos into a shared object
authorRaphael Collet <rco@openerp.com>
Wed, 3 Sep 2014 12:33:14 +0000 (14:33 +0200)
committerRaphael Collet <rco@openerp.com>
Thu, 4 Sep 2014 08:18:55 +0000 (10:18 +0200)
commit4ce06c238b68b8c2d0ebf392faa0b2cb3cd286dc
treeeb52a1b1084f7321a21770da5c4e2e6445dcb67b
parent9a3b48de0ff94c61fd1731439820999dc40a0506
[FIX] openerp.api.Environment: move recomputation todos into a shared object

This fixes a bug which is usually triggered in module account_followup, but
does not occur deterministically.  Some recomputations of computed fields are
apparently missing.  Environment objects containing recomputations todos and
kept alive by a WeakSet, are removed by the Python garbage collector before
recomputation takes place.  We fix the bug by moving the recomputation todos in
a non-weakref'ed object.
openerp/api.py
openerp/models.py