[Zodb-checkins] SVN: ZODB/trunk/src/transaction/_manager.py Merge rev 30262 from 3.4 branch.

Tim Peters tim.one at comcast.net
Thu May 5 23:58:56 EDT 2005

Log message for revision 30263:
  Merge rev 30262 from 3.4 branch.
  `synchs` can be None -- deal with it.  Reported by Gary Poster.

  U   ZODB/trunk/src/transaction/_manager.py

Modified: ZODB/trunk/src/transaction/_manager.py
--- ZODB/trunk/src/transaction/_manager.py	2005-05-06 03:57:35 UTC (rev 30262)
+++ ZODB/trunk/src/transaction/_manager.py	2005-05-06 03:58:56 UTC (rev 30263)
@@ -33,14 +33,15 @@
 # at top level here.
 # Call the ISynchronizer newTransaction() method on every element of
-# WeakSet synchs.
+# WeakSet synchs (or skip it if synchs is None).
 # A transaction manager needs to do this whenever begin() is called.
 # Since it would be good if tm.get() returned the new transaction while
 # newTransaction() is running, calling this has to be delayed until after
 # the transaction manager has done whatever it needs to do to make its
 # get() return the new txn.
 def _new_transaction(txn, synchs):
-    synchs.map(lambda s: s.newTransaction(txn))
+    if synchs:
+        synchs.map(lambda s: s.newTransaction(txn))
 class TransactionManager(object):

More information about the Zodb-checkins mailing list