Bug 1439455 - update to duplicity 7.12 breaks gpg agent
Summary: update to duplicity 7.12 breaks gpg agent
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: duplicity
Version: 25
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
Assignee: Gwyn Ciesla
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-04-06 04:05 UTC by Dave Allan
Modified: 2017-05-10 03:59 UTC (History)
2 users (show)

Fixed In Version: duplicity-0.7.12-2.fc26 duplicity-0.7.12-2.fc24 duplicity-0.7.12-2.fc25
Clone Of:
Environment:
Last Closed: 2017-05-05 13:34:01 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Launchpad 1680682 0 None None None 2017-04-07 03:56:35 UTC

Description Dave Allan 2017-04-06 04:05:03 UTC
After updating to duplicity 7.12 my backups are failing with the message:

GPGError: GPG Failed, see log below:
===== Begin GnuPG log =====
gpg: Sorry, we are in batchmode - can't get input
===== End GnuPG log =====

Version-Release number of selected component (if applicable):

duplicity-0.7.12-1.fc25.x86_64

How reproducible:

100%

Steps to Reproduce:

Attempt a backup using a gpg agent:

duplicity --gpg-binary /usr/bin/gpg2 \
--use-agent --sign-key <key ID> --encrypt-key <key ID>

Comment 1 Dave Allan 2017-04-06 18:00:43 UTC
I confirmed today that backups again succeed after downgrading to 7.11, so something in my environment disagrees with 7.12

Comment 2 Dave Allan 2017-04-07 03:57:16 UTC
This appears to be fixed in the most recent upstream bzr code.

Comment 3 Gwyn Ciesla 2017-04-07 12:56:42 UTC
On which branch?

Comment 4 Dave Allan 2017-04-08 00:26:09 UTC
Sorry, I was building a different bzr branch than I thought I was, so not fixed upstream.  I've attached an RFC patch to the upstream bug though.  If you have any thoughts on it, let's discuss upstream.

Comment 5 Dave Allan 2017-04-24 17:09:25 UTC
Upstream has committed a fix, bzr revno: 1278 to the 0.7-series branch based on my RFC patch.  I've tested the upstream fix, and it makes things work as I expect on my system.  I'd be happy to test an updated RPM as well.

Comment 6 Gwyn Ciesla 2017-04-28 13:55:28 UTC
Thank you!  I'll have builds in koji to test shortly.

Comment 7 Gwyn Ciesla 2017-04-28 14:01:08 UTC
I tested before committing, and my deja-dup backup failed with:

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 1521, in do_backup
    check_last_manifest(col_stats)  # not needed for full backup
  File "/usr/bin/duplicity", line 1222, in check_last_manifest
    last_backup_set.check_manifests()
  File "/usr/lib64/python2.7/site-packages/duplicity/collections.py", line 199, in check_manifests
    remote_manifest = self.get_remote_manifest()
  File "/usr/lib64/python2.7/site-packages/duplicity/collections.py", line 234, in get_remote_manifest
    manifest_buffer = self.backend.get_data(self.remote_manifest_name)
  File "/usr/lib64/python2.7/site-packages/duplicity/backend.py", line 677, in get_data
    fin = self.get_fileobj_read(filename, parseresults)
  File "/usr/lib64/python2.7/site-packages/duplicity/backend.py", line 671, in get_fileobj_read
    return tdp.filtered_open_with_delete("rb")
  File "/usr/lib64/python2.7/site-packages/duplicity/dup_temp.py", line 119, in filtered_open_with_delete
    fh = FileobjHooked(path.DupPath.filtered_open(self, mode))
  File "/usr/lib64/python2.7/site-packages/duplicity/path.py", line 778, in filtered_open
    return gpg.GPGFile(False, self, gpg_profile)
  File "/usr/lib64/python2.7/site-packages/duplicity/gpg.py", line 156, in __init__
    raise GPGError("Unsupported GNUPG version, %s" % profile.gpg_version)
TypeError: not all arguments converted during string formatting

Comment 8 Dave Allan 2017-04-28 14:59:05 UTC
Urgh, that version check wasn't part of my original patch.  I should have objected to it post-commit.  I can reproduce what you're seeing with GPG 1.4.21.  Since this reproduces with the upstream tree, let's take this discussion to the upstream bug so Kenneth gets looped in.

Comment 9 Dave Allan 2017-04-28 16:20:04 UTC
I submitted a fix upstream, and it'd be great to have your feedback.

Comment 10 Gwyn Ciesla 2017-05-01 14:58:05 UTC
Sorry for the delay, looks great, but I can't test 100% today.  I'll still commit and build.

Comment 11 Fedora Update System 2017-05-01 15:09:52 UTC
duplicity-0.7.12-2.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2017-26e1afb19f

Comment 12 Fedora Update System 2017-05-01 15:10:00 UTC
duplicity-0.7.12-2.fc25 has been submitted as an update to Fedora 25. https://bodhi.fedoraproject.org/updates/FEDORA-2017-6a31b796c3

Comment 13 Fedora Update System 2017-05-01 15:10:05 UTC
duplicity-0.7.12-2.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-51e2138254

Comment 14 Fedora Update System 2017-05-02 03:30:57 UTC
duplicity-0.7.12-2.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-6a31b796c3

Comment 15 Fedora Update System 2017-05-02 05:05:08 UTC
duplicity-0.7.12-2.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-26e1afb19f

Comment 16 Fedora Update System 2017-05-02 06:37:39 UTC
duplicity-0.7.12-2.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-51e2138254

Comment 17 Dave Allan 2017-05-02 13:07:50 UTC
I've verified that this is fixed on my system and gave karma.

Comment 18 Gwyn Ciesla 2017-05-02 13:13:16 UTC
Excellent, thank you!

Comment 19 Fedora Update System 2017-05-05 13:34:01 UTC
duplicity-0.7.12-2.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.

Comment 20 Fedora Update System 2017-05-10 03:54:31 UTC
duplicity-0.7.12-2.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 21 Fedora Update System 2017-05-10 03:59:36 UTC
duplicity-0.7.12-2.fc25 has been pushed to the Fedora 25 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.