Hello community,
here is the log from the commit of package duplicity
checked in at Wed Aug 6 01:42:54 CEST 2008.
--------
--- duplicity/duplicity.changes 2008-04-17 13:30:43.000000000 +0200
+++ /mounts/work_src_done/STABLE/duplicity/duplicity.changes 2008-07-24 22:07:46.215869000 +0200
@@ -1,0 +2,25 @@
+Thu Jul 24 22:04:48 CEST 2008 - cthiel@suse.de
+
+- update to version 0.4.12
+ * Dan Muresan created a patch to minimize the number of password
+ prompts. To do so, it sometimes requests a password once without
+ confirmation; if later it turns out that a full backup is needed,
+ the user is prompted for confirmation.
+ * bug #23540: doc bug in man page (environment FTP_PASSWORD)
+ https://savannah.nongnu.org/bugs/index.php?23540
+ * bug #23362: Documentation for --version, --time-separator <char>
+ https://savannah.nongnu.org/bugs/index.php?23362
+ * bug #23283: interactive passphrase query is suboptimal
+ https://savannah.nongnu.org/bugs/index.php?23283
+ * bug #23066 was not actually applied to 0.4.11. Its here now.
+ https://savannah.nongnu.org/bugs/index.php?23066
+ * bug #22826: regressions caused by boto 1.1c
+ * https://savannah.nongnu.org/bugs/index.php?22826
+- changes in 0.4.11
+ * Changes applied to allow duplicity to run under Python 2.3 again.
+ * patch #6485: Reinstate patch #6340 with a detailed explanation.
+ https://savannah.nongnu.org/patch/index.php?6485
+ * bug #23066: ssh uris with given portnumbers are not handled correctly
+ https://savannah.nongnu.org/bugs/index.php?23066
+
+-------------------------------------------------------------------
Old:
----
duplicity-0.4.10.tar.bz2
New:
----
duplicity-0.4.12.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ duplicity.spec ++++++
--- /var/tmp/diff_new_pack.l28458/_old 2008-08-06 01:42:23.000000000 +0200
+++ /var/tmp/diff_new_pack.l28458/_new 2008-08-06 01:42:23.000000000 +0200
@@ -1,20 +1,28 @@
#
-# spec file for package duplicity (Version 0.4.10)
+# spec file for package duplicity (Version 0.4.12)
#
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
-# This file and all modifications and additions to the pristine
-# package are under the same license as the package itself.
#
+# All modifications and additions to the file contributed by third parties
+# remain the property of their copyright owners, unless otherwise agreed
+# upon. The license for this file, and modifications and additions to the
+# file, is the same license as for the pristine package itself (unless the
+# license for the pristine package is not an Open Source License, in which
+# case the license is the MIT License). An "Open Source License" is a
+# license that conforms to the Open Source Definition (Version 1.9)
+# published by the Open Source Initiative.
+
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
+# norootforbuild
Name: duplicity
BuildRequires: librsync >= 0.9.6
BuildRequires: python-devel python-pexpect
Summary: Encrypted bandwidth-efficient backup using the rsync algorithm
-Version: 0.4.10
+Version: 0.4.12
Release: 1
License: GPL v3 or later
Group: Productivity/Archiving/Backup
@@ -72,6 +80,28 @@
%endif
%changelog
+* Fri Jul 25 2008 cthiel@suse.de
+- update to version 0.4.12
+ * Dan Muresan created a patch to minimize the number of password
+ prompts. To do so, it sometimes requests a password once without
+ confirmation; if later it turns out that a full backup is needed,
+ the user is prompted for confirmation.
+ * bug #23540: doc bug in man page (environment FTP_PASSWORD)
+ https://savannah.nongnu.org/bugs/index.php?23540
+ * bug #23362: Documentation for --version, --time-separator <char>
+ https://savannah.nongnu.org/bugs/index.php?23362
+ * bug #23283: interactive passphrase query is suboptimal
+ https://savannah.nongnu.org/bugs/index.php?23283
+ * bug #23066 was not actually applied to 0.4.11. Its here now.
+ https://savannah.nongnu.org/bugs/index.php?23066
+ * bug #22826: regressions caused by boto 1.1c
+ * https://savannah.nongnu.org/bugs/index.php?22826
+- changes in 0.4.11
+ * Changes applied to allow duplicity to run under Python 2.3 again.
+ * patch #6485: Reinstate patch #6340 with a detailed explanation.
+ https://savannah.nongnu.org/patch/index.php?6485
+ * bug #23066: ssh uris with given portnumbers are not handled correctly
+ https://savannah.nongnu.org/bugs/index.php?23066
* Thu Apr 17 2008 cthiel@suse.de
- update to version 0.4.10
* bug #22728: FTP backend fails on empty directory
++++++ duplicity-0.4.10.tar.bz2 -> duplicity-0.4.12.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/CHANGELOG new/duplicity-0.4.12/CHANGELOG
--- old/duplicity-0.4.10/CHANGELOG 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/CHANGELOG 2008-07-22 17:20:04.000000000 +0200
@@ -1,28 +1,62 @@
+New in v0.4.12 (2008/07/22)
+---------------------------
+Dan Muresan created a patch to minimize the number of password
+prompts. To do so, it sometimes requests a password once without
+confirmation; if later it turns out that a full backup is needed,
+the user is prompted for confirmation.
+
+bug #23540: doc bug in man page (environment FTP_PASSWORD)
+https://savannah.nongnu.org/bugs/index.php?23540
+
+bug #23362: Documentation for --version, --time-separator <char>
+https://savannah.nongnu.org/bugs/index.php?23362
+
+bug #23283: interactive passphrase query is suboptimal
+https://savannah.nongnu.org/bugs/index.php?23283
+
+bug #23066 was not actually applied to 0.4.11. Its here now.
+https://savannah.nongnu.org/bugs/index.php?23066
+
+bug #22826: regressions caused by boto 1.1c
+https://savannah.nongnu.org/bugs/index.php?22826
+
+
+New in v0.4.11 (2008/05/05)
+---------------------------
+Changes applied to allow duplicity to run under Python 2.3 again.
+
+patch #6485: Reinstate patch #6340 with a detailed explanation.
+https://savannah.nongnu.org/patch/index.php?6485
+
+bug #23066: ssh uris with given portnumbers are not handled correctly
+https://savannah.nongnu.org/bugs/index.php?23066
+
+
New in v0.4.10 (2008/03/27)
---------------------------
bug #22728: FTP backend fails on empty directory
-https://savannah.nongnu.org/bugs/?22728
+https://savannah.nongnu.org/bugs/index.php?22728
patch #6374: Duplicity --tempdir patch documentation.
-https://savannah.nongnu.org/patch/?6374
+https://savannah.nongnu.org/patch/index.php?6374
patch #6375: Duplicity reports the epoch for a nonexistant last full backup date
-https://savannah.nongnu.org/patch/?6375
+https://savannah.nongnu.org/patch/index.php?6375
patch #6380: add additional named logging levels
-https://savannah.nongnu.org/patch/?6380
+https://savannah.nongnu.org/patch/index.php?6380
patch #6389: Possible Fix for pagefile.sys on Win32 systems
-https://savannah.nongnu.org/patch/?6389
+https://savannah.nongnu.org/patch/index.php?6389
patch #6403: Restore by overwriting files/directories by using --force option
-https://savannah.nongnu.org/patch/?6403
+https://savannah.nongnu.org/patch/index.php?6403
patch #6449: add additional debug level logging
-https://savannah.nongnu.org/patch/?6449
+https://savannah.nongnu.org/patch/index.php?6449
patch #6453: handle absolute urls in webdav backend
-https://savannah.nongnu.org/patch/?6453
+https://savannah.nongnu.org/patch/index.php?6453
Fix problem where S3 prefix was prepended with 'd'. This caused
a failure in the regression tests.
@@ -62,13 +96,13 @@
https://savannah.nongnu.org/bugs/index.php?21909
patch #6354: S3 staight typo results in a bogus exception
-https://savannah.nongnu.org/patch/?6354
+https://savannah.nongnu.org/patch/index.php?6354
patch #6356: Command line option for the temporary directory root.
-https://savannah.nongnu.org/patch/?6356
+https://savannah.nongnu.org/patch/index.php?6356
patch #6357: Explicit restore action is missing from the command list,
-https://savannah.nongnu.org/patch/?6357
+https://savannah.nongnu.org/patch/index.php?6357
New in v0.4.8 (2007/12/15)
@@ -89,10 +123,10 @@
https://savannah.nongnu.org/bugs/index.php?21752
patch #6340: S3 short filename regression
-https://savannah.nongnu.org/patch/?6340
+https://savannah.nongnu.org/patch/index.php?6340
patch #6344: S3 bad bad key key handling
-http://savannah.nongnu.org/patch/?6344
+http://savannah.nongnu.org/patch/index.php?6344
New in v0.4.7 (2007/12/07)
@@ -107,25 +141,25 @@
https://savannah.nongnu.org/bugs/index.php?21686
patch #6292: Amazon S3 bucket creation deferral
-https://savannah.nongnu.org/patch/?6292
+https://savannah.nongnu.org/patch/index.php?6292
patch #6293: left-over patch from remove-all-but-n-full
-https://savannah.nongnu.org/patch/?6293
+https://savannah.nongnu.org/patch/index.php?6293
patch #6296: Generic S3 url support for Duplicity 0.4.6
-https://savannah.nongnu.org/patch/?6296
+https://savannah.nongnu.org/patch/index.php?6296
patch #6298: URI unquoting patch for FTP backend
-https://savannah.nongnu.org/patch/?6298
+https://savannah.nongnu.org/patch/index.php?6298
patch #6299: re-design tempfile handling
-https://savannah.nongnu.org/patch/?6299
+https://savannah.nongnu.org/patch/index.php?6299
patch #6300: Standard library replacement for ParsedUrl class
-https://savannah.nongnu.org/patch/?6300
+https://savannah.nongnu.org/patch/index.php?6300
patch #6301: log sftp commands at verbosity 5
-https://savannah.nongnu.org/patch/?6301
+https://savannah.nongnu.org/patch/index.php?6301
New in v0.4.6 (2007/11/28)
@@ -144,10 +178,10 @@
https://savannah.nongnu.org/bugs/index.php?21657
bug #21657: ncftpls fails to create dir in ver 0.4.5
-https://savannah.nongnu.org/patch/?6284
+https://savannah.nongnu.org/patch/index.php?6284
patch #6284: document TMPDIR and friends
-https://savannah.nongnu.org/patch/?6284
+https://savannah.nongnu.org/patch/index.php?6284
patch #6285: security fix: eliminate use of mktemp()
https://savannah.nongnu.org/patch/index.php?6289
@@ -270,7 +304,7 @@
DP: make tempfiles with useful names
DP: do not ask for a passphrase if none is required!
-https://savannah.nongnu.org/bugs/?21123
+https://savannah.nongnu.org/bugs/index.php?21123
duplicity 0.4.3 ftpBackend did not find backup sets when there was
more than 20 files in directory.
@@ -307,7 +341,7 @@
Note: do not add spaces in the string value.
Fixed bug 20764 - unable to use port in ssh backend.
-https://savannah.nongnu.org/bugs/?20764
+https://savannah.nongnu.org/bugs/index.php?20764
Remove ssh_command option, add ssh_options. This adds
options to the scp and sftp commands that are used by
@@ -325,7 +359,7 @@
-------------------------------
Fix index out of range in Bug 20730, triggered when there
is only one incremental in the list.
-https://savannah.nongnu.org/bugs/?20730
+https://savannah.nongnu.org/bugs/index.php?20730
Changed the file:, ftp:, and ssh: backends so that
the target directory will be created at start.
@@ -475,7 +509,7 @@
dAniel hAhler submitted a patch to change "Error initializing file
foo" (log level 2), where foo was a socket, to "Skipping socket foo"
-(log level 7). https://savannah.nongnu.org/patch/?5985
+(log level 7). https://savannah.nongnu.org/patch/index.php?5985
Change logging to flush after every write, unbuffering stdout and
stderr, thus producing logs that are coherent.
@@ -502,26 +536,26 @@
------------------------------
Fixed bug in tarfile.py that was causing ValueError exception. Thanks
to dAniel hAhler for the patch that fixed the problem. Refer to:
-http://savannah.nongnu.org/bugs/?19998
+http://savannah.nongnu.org/bugs/index.php?19998
New in v0.4.3.RC1 (2007/05/26)
------------------------------
Applied patches:
- https://savannah.nongnu.org/patch/?4486
- https://savannah.nongnu.org/patch/?5183
- https://savannah.nongnu.org/patch/?5185
- https://savannah.nongnu.org/patch/?5412
- https://savannah.nongnu.org/patch/?5413
- https://savannah.nongnu.org/patch/?5680
- https://savannah.nongnu.org/patch/?5681
- https://savannah.nongnu.org/patch/?5682
- https://savannah.nongnu.org/patch/?5794
- https://savannah.nongnu.org/patch/?5830
+ https://savannah.nongnu.org/patch/index.php?4486
+ https://savannah.nongnu.org/patch/index.php?5183
+ https://savannah.nongnu.org/patch/index.php?5185
+ https://savannah.nongnu.org/patch/index.php?5412
+ https://savannah.nongnu.org/patch/index.php?5413
+ https://savannah.nongnu.org/patch/index.php?5680
+ https://savannah.nongnu.org/patch/index.php?5681
+ https://savannah.nongnu.org/patch/index.php?5682
+ https://savannah.nongnu.org/patch/index.php?5794
+ https://savannah.nongnu.org/patch/index.php?5830
Fixed bugs:
- https://savannah.nongnu.org/bugs/?2441
- https://savannah.nongnu.org/bugs/?16711
+ https://savannah.nongnu.org/bugs/index.php?2441
+ https://savannah.nongnu.org/bugs/index.php?16711
ProFTPD resets the connection after returning 226 when NLSTing an
empty directory, so changed code to allow that exception.
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/duplicity new/duplicity-0.4.12/duplicity
--- old/duplicity-0.4.10/duplicity 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/duplicity 2008-07-22 17:20:04.000000000 +0200
@@ -1,6 +1,6 @@
#!/usr/bin/env python
# duplicity -- Encrypted bandwidth efficient backup
-# Version 0.4.10 released September 29, 2002
+# Version 0.4.12 released September 29, 2002
#
# Copyright (C) 2002 Ben Escoto
#
@@ -34,8 +34,13 @@
exit_val = None
-def get_passphrase():
- """Get passphrase from environment or, failing that, from user"""
+def get_passphrase(n):
+ """Get passphrase from environment or, failing that, from user
+
+ If n=3, a password is requested and verified. If n=2, the current
+ password is verified. If n=1, a password is requested without
+ verification for the time being."""
+
try:
return os.environ['PASSPHRASE']
except KeyError:
@@ -43,13 +48,23 @@
log.Log("PASSPHRASE variable not set, asking user.", 5)
while 1:
- pass1 = getpass.getpass("GnuPG passphrase: ")
- pass2 = getpass.getpass("Retype to confirm: ")
+ if n == 2:
+ pass1 = globals.gpg_profile.passphrase
+ else:
+ pass1 = getpass.getpass("GnuPG passphrase: ")
+
+ if n == 1:
+ pass2 = pass1
+ else:
+ pass2 = getpass.getpass("Retype passphrase to confirm: ")
+
if not pass1 == pass2:
print "First and second passphrases do not match! Please try again."
+ n = 3
continue
if not pass1 and not globals.gpg_profile.recipients:
print "Cannot use empty passphrase with symmetric encryption! Please try again."
+ n = 3
continue
return pass1
@@ -147,6 +162,8 @@
local_sig_filename))
return fh
+def pubkey_only():
+ return not globals.gpg_profile.sign_key and globals.gpg_profile.recipients and globals.encryption
def full_backup(col_stats):
"""Do full backup of directory to backend, using archive_dir"""
@@ -402,9 +419,6 @@
os.umask(077)
# for public key encryption (without signing!), no passphrase is required.
- pubkey_only = (not globals.gpg_profile.sign_key and
- globals.gpg_profile.recipients and
- globals.encryption)
# cases where we do not need to get a passphrase:
# full: with pubkey enc. doesn't depend on old encrypted info
@@ -412,17 +426,16 @@
# with encryption disabled
# listing files: needs a manifest, but the archive dir has that
# collection status only looks at a repository
- if ((action == "full" and pubkey_only) or
- (action == "inc" and pubkey_only and globals.archive_dir) or
- (not globals.encryption) or
+ # NOTE: both full and inc are handled later
+ if ((not globals.encryption) or
(action == "list-current" and globals.archive_dir) or
- action in ["collection-status",
+ action in ["full", "inc", "collection-status",
"remove-older-then",
"remove-all-but-n-full",
]):
globals.gpg_profile.passphrase = ""
else:
- globals.gpg_profile.passphrase = get_passphrase()
+ globals.gpg_profile.passphrase = get_passphrase(1)
if action == "restore":
restore(col_stats)
@@ -441,11 +454,17 @@
else:
assert action == "inc" or action == "full", action
if action == "full":
+ if not pubkey_only():
+ globals.gpg_profile.passphrase = get_passphrase(3)
full_backup(col_stats)
- else:
+ else: # attempt incremental
+ if not (pubkey_only() and globals.archive_dir):
+ globals.gpg_profile.passphrase = get_passphrase(1)
check_last_manifest(col_stats) # not needed for full backup
sig_chain = check_sig_chain(col_stats)
if not sig_chain:
+ if not pubkey_only():
+ globals.gpg_profile.passphrase = get_passphrase(2)
full_backup(col_stats)
else:
incremental_backup(sig_chain)
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/duplicity.1 new/duplicity-0.4.12/duplicity.1
--- old/duplicity-0.4.10/duplicity.1 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/duplicity.1 2008-07-22 17:20:04.000000000 +0200
@@ -1,4 +1,4 @@
-.TH RDIFFDIR 1 "March 2008" "Version 0.4.10" "User Manuals"
+.TH RDIFFDIR 1 "July 2008" "Version 0.4.12" "User Manuals"
.SH NAME
duplicity \- Encrypted backup using rsync algorithm
@@ -131,7 +131,7 @@
password:
.PP
.RS
-FTP_PASSWORD=mypassword; duplicity /local/dir ftp://user@other.host/some_dir
+FTP_PASSWORD=mypassword duplicity /local/dir ftp://user@other.host/some_dir
.SH ACTIONS
.TP
@@ -410,10 +410,18 @@
.BI -t time ", --restore-time " time
When restoring, specify the time to restore to.
.TP
+.BI "--time-separator " char
+Use
+.IR char
+as the time separator in filenames instead of colon (":").
+.TP
.BI -v [0-9] ", --verbosity " [0-9]
Specify verbosity level (0 is total silent, 3 is the default, and 9 is
noisiest).
.TP
+.BI --version
+Print duplicity's version and quit.
+.TP
.BI "--volsize " number
Change the volume size to
.IR number
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/rdiffdir new/duplicity-0.4.12/rdiffdir
--- old/duplicity-0.4.10/rdiffdir 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/rdiffdir 2008-07-22 17:20:04.000000000 +0200
@@ -1,6 +1,6 @@
#!/usr/bin/env python
# rdiffdir -- Extend rdiff functionality to directories
-# Version 0.4.10 released June 30, 2002
+# Version 0.4.12 released June 30, 2002
#
# Copyright (C) 2002 Ben Escoto
#
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/rdiffdir.1 new/duplicity-0.4.12/rdiffdir.1
--- old/duplicity-0.4.10/rdiffdir.1 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/rdiffdir.1 2008-07-22 17:20:04.000000000 +0200
@@ -1,4 +1,4 @@
-.TH RDIFFDIR 1 "March 2008" "Version 0.4.10" "User Manuals"
+.TH RDIFFDIR 1 "July 2008" "Version 0.4.12" "User Manuals"
.SH NAME
rdiffdir \- compute and apply signatures and diffs to directories
.SH SYNOPSIS
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/README new/duplicity-0.4.12/README
--- old/duplicity-0.4.10/README 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/README 2008-07-22 17:20:04.000000000 +0200
@@ -19,7 +19,7 @@
REQUIREMENTS:
- * Python v2.4 or later (http://www.python.org)
+ * Python v2.3 or later (http://www.python.org)
* librsync v0.9.6 or later (http://librsync.sourceforge.net)
* GnuPG for encryption (http://www.gnupg.org)
* GnuPGInterface 0.3.2 or later (http://py-gnupg.sourceforge.net)
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/setup.py new/duplicity-0.4.12/setup.py
--- old/duplicity-0.4.10/setup.py 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/setup.py 2008-07-22 17:20:04.000000000 +0200
@@ -3,10 +3,10 @@
import sys, os, getopt
from distutils.core import setup, Extension
-version_string = "0.4.10"
+version_string = "0.4.12"
-if sys.version_info[:2] < (2,4):
- print "Sorry, duplicity requires version 2.4 or later of python"
+if sys.version_info[:2] < (2,3):
+ print "Sorry, duplicity requires version 2.3 or later of python"
sys.exit(1)
try:
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/src/backends.py new/duplicity-0.4.12/src/backends.py
--- old/duplicity-0.4.10/src/backends.py 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/src/backends.py 2008-07-22 17:20:04.000000000 +0200
@@ -331,7 +331,7 @@
"python-pexpect from your distro's repository.")
# host string of form user@hostname:port
- self.host_string = parsed_url.netloc
+ self.host_string = parsed_url.username + "@" + parsed_url.hostname
# make sure remote_dir is always valid
if parsed_url.path:
# remove leading '/'
@@ -594,8 +594,8 @@
def delete(self, filename_list):
"""Delete files in filename_list"""
for filename in filename_list:
- commandline = "ncftpls -x '' %s -X 'DELE %s' '%s%s'" % \
- (self.flags, filename, self.url_string, filename)
+ commandline = "ncftpls -x '' %s -X 'DELE %s' '%s'" % \
+ (self.flags, filename, self.url_string)
self.popen_persist(commandline)
@@ -700,6 +700,15 @@
from boto.s3.connection import S3Connection
from boto.s3.key import Key
assert hasattr(S3Connection, 'lookup')
+
+ # Newer versions of boto default to using virtual hosting for
+ # buckets. This is bad because it will break backups stored in
+ # buckets that contain upper-case characters in the name.
+ try:
+ from boto.s3.connection import OrdinaryCallingFormat
+ calling_format = OrdinaryCallingFormat()
+ except ImportError:
+ calling_format = None
except ImportError:
log.FatalError("This backend requires boto library, version 0.9d or later, "
"(http://code.google.com/p/boto/).")
@@ -717,6 +726,9 @@
assert parsed_url.scheme == 's3'
self.conn = S3Connection(host=parsed_url.hostname)
+ if hasattr(self.conn, 'calling_format'):
+ self.conn.calling_format = calling_format
+
# This folds the null prefix and all null parts, which means that:
# //MyBucket/ and //MyBucket are equivalent.
# //MyBucket//My///My/Prefix/ and //MyBucket/My/Prefix are equivalent.
@@ -778,6 +790,15 @@
def list(self):
filename_list = []
if self.bucket:
+ # We add a 'd' to the prefix to make sure it is not null (for boto) and
+ # to optimize the listing of our filenames, which always begin with 'd'.
+ # This will cause a failure in the regression tests as below:
+ # FAIL: Test basic backend operations
+ # <tracback snipped>
+ # AssertionError: Got list: []
+ # Wanted: ['testfile']
+ # Because of the need for this optimization, it should be left as is.
+ #for k in self.bucket.list(prefix = self.key_prefix + 'd', delimiter = '/'):
for k in self.bucket.list(prefix = self.key_prefix, delimiter = '/'):
try:
filename = k.key.replace(self.key_prefix, '', 1)
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/src/collections.py new/duplicity-0.4.12/src/collections.py
--- old/duplicity-0.4.10/src/collections.py 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/src/collections.py 2008-07-22 17:20:04.000000000 +0200
@@ -789,6 +789,10 @@
NOTE: n = 1 -> time of latest available chain (n = 0 is not
a valid input). Thus the second-to-last is obtained with n=2
rather than n=1."""
+
+ def mycmp(x, y):
+ return cmp(x.get_first().time, y.get_first().time)
+
assert self.values_set
assert n > 0
@@ -796,9 +800,9 @@
return None
sorted = self.all_backup_chains[:]
- sorted.sort(reverse = True,
- key = lambda chain: chain.get_first().time)
+ sorted.sort(mycmp)
+ sorted.reverse()
return sorted[n - 1]
def get_older_than(self, t):
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/src/commandline.py new/duplicity-0.4.12/src/commandline.py
--- old/duplicity-0.4.10/src/commandline.py 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/src/commandline.py 2008-07-22 17:20:04.000000000 +0200
@@ -329,6 +329,8 @@
--tempdir <directory>
--timeout <seconds>
-t<time>, --restore-time <time>
+ --time-separator <char>
+ --version
--volsize <number>
-v[0-9], --verbosity [0-9]
""" % (globals.version, sys.platform))
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/src/file_naming.py new/duplicity-0.4.12/src/file_naming.py
--- old/duplicity-0.4.10/src/file_naming.py 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/src/file_naming.py 2008-07-22 17:20:04.000000000 +0200
@@ -23,16 +23,19 @@
full_vol_re = re.compile("^duplicity-full\\.(?P<time>.*?)\\.vol(?P<num>[0-9]+)\\.difftar($|\\.)")
full_vol_re_short = re.compile("^df\\.(?P<time>[0-9a-z]+?)\\.(?P<num>[0-9a-z]+)\\.dt($|\\.)")
+
full_manifest_re = re.compile("^duplicity-full\\.(?P<time>.*?)\\.manifest($|\\.)")
full_manifest_re_short = re.compile("^df\\.(?P<time>[0-9a-z]+?)\\.m($|\\.)")
inc_vol_re = re.compile("^duplicity-inc\\.(?P.*?)\\.to\\.(?P.*?)\\.vol(?P<num>[0-9]+)\\.difftar($|\\.)")
inc_vol_re_short = re.compile("^di\\.(?P[0-9a-z]+?)\\.(?P[0-9a-z]+?)\\.(?P<num>[0-9a-z]+)\\.dt($|\\.)")
+
inc_manifest_re = re.compile("^duplicity-inc\\.(?P.*?)\\.to\\.(?P.*?)\\.manifest(\\.|$)")
inc_manifest_re_short = re.compile("^di\\.(?P[0-9a-z]+?)\\.(?P[0-9a-z]+?)\\.m(\\.|$)")
full_sig_re = re.compile("^duplicity-full-signatures\\.(?P<time>.*?)\\.sigtar(\\.|$)")
full_sig_re_short = re.compile("^dfs\\.(?P<time>[0-9a-z]+?)\\.st(\\.|$)")
+
new_sig_re = re.compile("^duplicity-new-signatures\\.(?P.*?)\\.to\\.(?P.*?)\\.sigtar(\\.|$)")
new_sig_re_short = re.compile("^dns\\.(?P[0-9a-z]+?)\\.(?P[0-9a-z]+?)\\.st(\\.|$)")
@@ -190,7 +193,7 @@
if t1 and t2:
if m1:
return ParseResults("inc", start_time = t1,
- end_time = t2, volume_number = get_vol_num(m1.group("num")))
+ end_time = t2, volume_number = get_vol_num(m1.group("num")))
else:
return ParseResults("inc", start_time = t1,
end_time = t2, manifest = 1)
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/src/globals.py new/duplicity-0.4.12/src/globals.py
--- old/duplicity-0.4.10/src/globals.py 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/src/globals.py 2008-07-22 17:20:04.000000000 +0200
@@ -21,7 +21,7 @@
import socket, sys
# The current version of duplicity
-version = "0.4.10"
+version = "0.4.12"
# The name of the current host, or None if it cannot be set
hostname = socket.getfqdn()
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/duplicity-0.4.10/src/urlparse_2_5.py new/duplicity-0.4.12/src/urlparse_2_5.py
--- old/duplicity-0.4.10/src/urlparse_2_5.py 2008-03-26 22:51:36.000000000 +0100
+++ new/duplicity-0.4.12/src/urlparse_2_5.py 2008-07-22 17:20:04.000000000 +0200
@@ -40,6 +40,15 @@
global _parse_cache
_parse_cache = {}
+import string
+def _rsplit(str, delim, numsplit):
+ parts = string.split(str, delim)
+ if len(parts) <= numsplit + 1:
+ return parts
+ else:
+ left = string.join(parts[0:-numsplit], delim)
+ right = string.join(parts[len(parts)-numsplit:], delim)
+ return [left, right]
class BaseResult(tuple):
"""Base class for the parsed result objects.
@@ -55,66 +64,66 @@
# Attributes that access the basic components of the URL:
- @property
- def scheme(self):
+ def get_scheme(self):
return self[0]
+ scheme = property(get_scheme)
- @property
- def netloc(self):
+ def get_netloc(self):
return self[1]
+ netloc = property(get_netloc)
- @property
- def path(self):
+ def get_path(self):
return self[2]
+ path = property(get_path)
- @property
- def query(self):
+ def get_query(self):
return self[-2]
+ query = property(get_query)
- @property
- def fragment(self):
+ def get_fragment(self):
return self[-1]
+ fragment = property(get_fragment)
# Additional attributes that provide access to parsed-out portions
# of the netloc:
- @property
- def username(self):
+ def get_username(self):
netloc = self.netloc
if "@" in netloc:
- userinfo = netloc.rsplit("@", 1)[0]
+ userinfo = _rsplit(netloc, "@", 1)[0]
if ":" in userinfo:
userinfo = userinfo.split(":", 1)[0]
return userinfo
return None
+ username = property(get_username)
- @property
- def password(self):
+ def get_password(self):
netloc = self.netloc
if "@" in netloc:
- userinfo = netloc.rsplit("@", 1)[0]
+ userinfo = _rsplit(netloc, "@", 1)[0]
if ":" in userinfo:
return userinfo.split(":", 1)[1]
return None
+ password = property(get_password)
- @property
- def hostname(self):
+ def get_hostname(self):
netloc = self.netloc
if "@" in netloc:
- netloc = netloc.rsplit("@", 1)[1]
+ netloc = _rsplit(netloc, "@", 1)[1]
if ":" in netloc:
netloc = netloc.split(":", 1)[0]
return netloc.lower() or None
+ hostname = property(get_hostname)
- @property
- def port(self):
+ def get_port(self):
netloc = self.netloc
if "@" in netloc:
- netloc = netloc.rsplit("@", 1)[1]
+ netloc = _rsplit(netloc, "@", 1)[1]
if ":" in netloc:
port = netloc.split(":", 1)[1]
return int(port, 10)
return None
+ port = property(get_port)
class SplitResult(BaseResult):
@@ -137,9 +146,9 @@
return BaseResult.__new__(
cls, (scheme, netloc, path, params, query, fragment))
- @property
- def params(self):
+ def get_params(self):
return self[3]
+ params = property(get_params)
def geturl(self):
return urlunparse(self)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org