Clear transaction cache after commit

If there are multiple commits, the data in the database may have been modified.

issue11014
review381481003
This commit is contained in:
Cédric Krier committed 2021-12-16 22:12:42 +01:00
1 parent 3bf27ac06a
commit e4529b45ee
1 file changed
+2
+2
View File
@@ -238,6 +238,8 @@ class Transaction(object):
for datamanager in self._datamanagers:
datamanager.tpc_vote(self)
self.started_at = self.monotonic_time()
for cache in self.cache.values():
cache.clear()
Cache.commit(self)
self.connection.commit()
except Exception: