← Back to team overview

duplicity-team team mailing list archive

[Merge] lp:~dawgfoto/duplicity/fixup1252 into lp:duplicity

 

Martin Nowak has proposed merging lp:~dawgfoto/duplicity/fixup1252 into lp:duplicity.

Commit message:
* only check decryptable remote manifests
  - fixup of revision 1252 which introduces a non-fatal error message (see #1729796)
  - for backups the GPG private key and/or it's password are typically not available
  - also avoid interactive password queries through e.g. gpg agent


Requested reviews:
  duplicity-team (duplicity-team)

For more details, see:
https://code.launchpad.net/~dawgfoto/duplicity/fixup1252/+merge/343816

fixup of https://bazaar.launchpad.net/~duplicity-team/duplicity/0.8-series/revision/1252 properly fixing https://bugs.launchpad.net/duplicity/+bug/1729796
-- 
Your team duplicity-team is requested to review the proposed merge of lp:~dawgfoto/duplicity/fixup1252 into lp:duplicity.
=== modified file 'bin/duplicity'
--- bin/duplicity	2017-12-21 21:35:52 +0000
+++ bin/duplicity	2018-04-23 13:25:12 +0000
@@ -1327,8 +1327,7 @@
     @rtype: void
     @return: void
     """
-    if not col_stats.all_backup_chains:
-        return
+    assert col_stats.all_backup_chains
     last_backup_set = col_stats.all_backup_chains[-1].get_last()
     last_backup_set.check_manifests()
 
@@ -1630,7 +1629,9 @@
                     # only ask for a passphrase if there was a previous backup
                     if col_stats.all_backup_chains:
                         globals.gpg_profile.passphrase = get_passphrase(1, action)
-                    check_last_manifest(col_stats)  # not needed for full backup
+                        # check last manifest only if we can decrypt it (see #1729796)
+                        if not globals.encryption or globals.gpg_profile.passphrase:
+                            check_last_manifest(col_stats)
                 incremental_backup(sig_chain)
     globals.backend.close()
     log.shutdown()


Follow ups