[Zodb-checkins] CVS: StandaloneZODB/ZODB - FileStorage.py:1.76.8.3

Guido van Rossum guido@python.org
Thu, 27 Dec 2001 15:15:28 -0500


Update of /cvs-repository/StandaloneZODB/ZODB
In directory cvs.zope.org:/tmp/cvs-serv31777

Modified Files:
      Tag: Standby-branch
	FileStorage.py 
Log Message:
FileIterator.next():

- Use symbolic constant BLATHER rather than hardcoding -100.

- Log transaction ids as hex numbers.


=== StandaloneZODB/ZODB/FileStorage.py 1.76.8.2 => 1.76.8.3 ===
 from lock_file import lock_file
 from utils import t32, p64, U64, cp
-from zLOG import LOG, WARNING, ERROR, PANIC, register_subsystem
+from zLOG import LOG, BLATHER, WARNING, ERROR, PANIC, register_subsystem
 register_subsystem('ZODB FS')
 import BaseStorage
 from cPickle import Pickler, Unpickler, loads
@@ -2047,7 +2047,7 @@
         read=file.read
         pos=self._pos
 
-        LOG("ZODB FS", -100, "next(%d)" % index)
+        LOG("ZODB FS", BLATHER, "next(%d)" % index)
         while 1:
             # Read the transaction record
             seek(pos)
@@ -2099,9 +2099,9 @@
                     break
 
             if self._stop is not None:
-                LOG("ZODB FS", -100,
-                    ("tid %s > stop %s ? %d" %
-                     (repr(tid), repr(self._stop), tid > self._stop)))
+                LOG("ZODB FS", BLATHER,
+                    ("tid %x > stop %x ? %d" %
+                     (U64(tid), U64(self._stop), tid > self._stop)))
             if self._stop is not None and tid > self._stop:
                 raise IndexError, index