$ duplicity -t 7D --file-to-restore folderIWantToRestore file:///my/backup/location target_directory
Synchronizing remote metadata to local cache...
GnuPG passphrase:
Copying duplicity-full-signatures.20160402T183617Z.sigtar.gpg to local cache.
Copying duplicity-full-signatures.20160708T041150Z.sigtar.gpg to local cache.
Copying duplicity-full-signatures.20161006T101852Z.sigtar.gpg to local cache.
Copying duplicity-full.20160402T183617Z.manifest.gpg to local cache.
Copying duplicity-full.20160708T041150Z.manifest.gpg to local cache.
Copying duplicity-full.20161006T101852Z.manifest.gpg to local cache.
Copying duplicity-inc.20160402T183617Z.to.20160421T101839Z.manifest.gpg to local cache.
Copying duplicity-inc.20160421T101839Z.to.20160506T054020Z.manifest.gpg to local cache.
Copying duplicity-inc.20160506T054020Z.to.20160512T101918Z.manifest.gpg to local cache.
Copying duplicity-inc.20160512T101918Z.to.20160519T102000Z.manifest.gpg to local cache.
Copying duplicity-inc.20160519T102000Z.to.20160603T030556Z.manifest.gpg to local cache.
Copying duplicity-inc.20160603T030556Z.to.20160611T044724Z.manifest.gpg to local cache.
Copying duplicity-inc.20160611T044724Z.to.20160701T061452Z.manifest.gpg to local cache.
Copying duplicity-inc.20160708T041150Z.to.20160714T101926Z.manifest.gpg to local cache.
Copying duplicity-inc.20160714T101926Z.to.20160721T101823Z.manifest.gpg to local cache.
Copying duplicity-inc.20160721T101823Z.to.20160728T101920Z.manifest.gpg to local cache.
Copying duplicity-inc.20160728T101920Z.to.20160804T101832Z.manifest.gpg to local cache.
Copying duplicity-inc.20160804T101832Z.to.20160811T101925Z.manifest.gpg to local cache.
Copying duplicity-inc.20160811T101925Z.to.20160818T101907Z.manifest.gpg to local cache.
Copying duplicity-inc.20160818T101907Z.to.20160825T101928Z.manifest.gpg to local cache.
Copying duplicity-inc.20160825T101928Z.to.20160901T101914Z.manifest.gpg to local cache.
Copying duplicity-inc.20160901T101914Z.to.20160908T101828Z.manifest.gpg to local cache.
Copying duplicity-inc.20160908T101828Z.to.20160915T101847Z.manifest.gpg to local cache.
Copying duplicity-inc.20160915T101847Z.to.20160922T101825Z.manifest.gpg to local cache.
Copying duplicity-inc.20160922T101825Z.to.20160929T101858Z.manifest.gpg to local cache.
Copying duplicity-inc.20161006T101852Z.to.20161013T101740Z.manifest.gpg to local cache.
Copying duplicity-inc.20161013T101740Z.to.20161020T101817Z.manifest.gpg to local cache.
Copying duplicity-inc.20161020T101817Z.to.20161027T101934Z.manifest.gpg to local cache.
Copying duplicity-inc.20161027T101934Z.to.20161103T101934Z.manifest.gpg to local cache.
Copying duplicity-inc.20161103T101934Z.to.20161110T102658Z.manifest.gpg to local cache.
Copying duplicity-inc.20161110T102658Z.to.20161117T102532Z.manifest.gpg to local cache.
Copying duplicity-new-signatures.20160402T183617Z.to.20160421T101839Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160421T101839Z.to.20160506T054020Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160506T054020Z.to.20160512T101918Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160512T101918Z.to.20160519T102000Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160519T102000Z.to.20160603T030556Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160603T030556Z.to.20160611T044724Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160611T044724Z.to.20160701T061452Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160708T041150Z.to.20160714T101926Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160714T101926Z.to.20160721T101823Z.sigtar.gpg to local cache.
Cleanup of temporary directory /tmp/duplicity-LmurBX-tempdir failed - this is probably a bug.
Traceback (most recent call last):
File "/usr/bin/duplicity", line 1546, in <module>
with_tempdir(main)
File "/usr/bin/duplicity", line 1540, in with_tempdir
fn()
File "/usr/bin/duplicity", line 1391, in main
do_backup(action)
File "/usr/bin/duplicity", line 1412, in do_backup
sync_archive(decrypt)
File "/usr/bin/duplicity", line 1199, in sync_archive
copy_to_local(fn)
File "/usr/bin/duplicity", line 1146, in copy_to_local
tdp.move(globals.archive_dir.append(loc_name))
File "/usr/lib64/python2.7/site-packages/duplicity/path.py", line 636, in move
self.copy(new_path)
File "/usr/lib64/python2.7/site-packages/duplicity/path.py", line 462, in copy
self.copy_attribs(other)
File "/usr/lib64/python2.7/site-packages/duplicity/path.py", line 467, in copy_attribs
util.maybe_ignore_errors(lambda: os.chown(other.name, self.stat.st_uid, self.stat.st_gid))
File "/usr/lib64/python2.7/site-packages/duplicity/util.py", line 93, in maybe_ignore_errors
return fn()
File "/usr/lib64/python2.7/site-packages/duplicity/path.py", line 467, in <lambda>
util.maybe_ignore_errors(lambda: os.chown(other.name, self.stat.st_uid, self.stat.st_gid))
AttributeError: 'NoneType' object has no attribute 'st_uid'
When I modified line path.py:467
if self.stat is not None:
util.maybe_ignore_errors(lambda: os.chown(other.name, self.stat.st_uid, self.stat.st_gid))
the command successfully completed.
$ duplicity -t 7D --file-to-restore folderIWantToRestore file:///my/backup/location target_directory
Synchronizing remote metadata to local cache...
GnuPG passphrase:
Copying duplicity-new-signatures.20160714T101926Z.to.20160721T101823Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160721T101823Z.to.20160728T101920Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160728T101920Z.to.20160804T101832Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160804T101832Z.to.20160811T101925Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160811T101925Z.to.20160818T101907Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160818T101907Z.to.20160825T101928Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160825T101928Z.to.20160901T101914Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160901T101914Z.to.20160908T101828Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160908T101828Z.to.20160915T101847Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160915T101847Z.to.20160922T101825Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20160922T101825Z.to.20160929T101858Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20161006T101852Z.to.20161013T101740Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20161013T101740Z.to.20161020T101817Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20161020T101817Z.to.20161027T101934Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20161027T101934Z.to.20161103T101934Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20161103T101934Z.to.20161110T102658Z.sigtar.gpg to local cache.
Copying duplicity-new-signatures.20161110T102658Z.to.20161117T102532Z.sigtar.gpg to local cache.
Last full backup date: Thu Oct 6 03:18:52 2016
folderIWantToRestore not found in archive - no files restored.
Thanks for creating this software btw! :-)
This might fix bug #1290852.