duplicity-team team mailing list archive
-
duplicity-team team
-
Mailing list archive
-
Message #01649
[Merge] lp:~tblue/duplicity/paramiko-1.10.0 into lp:duplicity
Tilman Blumenbach has proposed merging lp:~tblue/duplicity/paramiko-1.10.0 into lp:duplicity.
Requested reviews:
duplicity-team (duplicity-team)
Related bugs:
Bug #1156746 in Duplicity: "Paramiko 1.10.0 breaks Paramiko backend"
https://bugs.launchpad.net/duplicity/+bug/1156746
For more details, see:
https://code.launchpad.net/~tblue/duplicity/paramiko-1.10.0/+merge/161119
This fixes bug #1156746, making the Paramiko backend compatible with Paramiko 1.10.0. It keeps compatibility with older Paramiko versions.
--
https://code.launchpad.net/~tblue/duplicity/paramiko-1.10.0/+merge/161119
Your team duplicity-team is requested to review the proposed merge of lp:~tblue/duplicity/paramiko-1.10.0 into lp:duplicity.
=== modified file 'duplicity/backends/_ssh_paramiko.py'
--- duplicity/backends/_ssh_paramiko.py 2012-09-19 04:55:59 +0000
+++ duplicity/backends/_ssh_paramiko.py 2013-04-26 13:30:42 +0000
@@ -155,8 +155,19 @@
self.config['identityfile'] = keyfilename
## ensure ~ is expanded and identity exists in dictionary
if 'identityfile' in self.config:
- self.config['identityfile'] = os.path.expanduser(
- self.config['identityfile'])
+ if not isinstance(self.config['identityfile'], list):
+ # Paramiko 1.9.0 and earlier do not support multiple
+ # identity files when parsing config files and always
+ # return a string; later versions always return a list,
+ # even if there is only one file given.
+ #
+ # All recent versions seem to support *using* multiple
+ # identity files, though, so to make things easier, we
+ # simply always use a list.
+ self.config['identityfile'] = [self.config['identityfile']]
+
+ self.config['identityfile'] = [os.path.expanduser(i) for i in
+ self.config['identityfile']]
else:
self.config['identityfile'] = None
Follow ups