[Zope3-checkins] CVS: ZODB/src/ZODB - fsrecover.py:1.21
Tim Peters
tim.one at comcast.net
Mon May 3 14:14:16 EDT 2004
Update of /cvs-repository/ZODB/src/ZODB
In directory cvs.zope.org:/tmp/cvs-serv1634/src/ZODB
Modified Files:
fsrecover.py
Log Message:
recover(): Changed 'force' and 'partial' arguments to bools. Changed
'pack' default value from 0 to None (this looks like the clear intent
of the code).
Note that fsrecover.py is totally broken, but testRecover.py isn't
detecting it. I'm working on repairing both.
=== ZODB/src/ZODB/fsrecover.py 1.20 => 1.21 ===
--- ZODB/src/ZODB/fsrecover.py:1.20 Mon May 3 12:21:34 2004
+++ ZODB/src/ZODB/fsrecover.py Mon May 3 14:14:15 2004
@@ -239,21 +239,22 @@
die("two positional arguments required", show_docstring=True)
inp, outp = args
- force = partial = verbose = 0
+ force = partial = False
+ verbose = 0
pack = None
for opt, v in opts:
if opt == "-v":
verbose = int(v)
elif opt == "-p":
- partial = 1
+ partial = True
elif opt == "-f":
- force = 1
+ force = True
elif opt == "-P":
pack = time.time() - float(v)
recover(inp, outp, verbose, partial, force, pack)
-def recover(inp, outp, verbose=0, partial=0, force=0, pack=0):
+def recover(inp, outp, verbose=0, partial=False, force=False, pack=None):
print "Recovering", inp, "into", outp
if os.path.exists(outp) and not force:
More information about the Zope3-Checkins
mailing list