Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#1010370: git-buildpackage: export-orig explodes if pristine-tar branch is signed

0 views
Skip to first unread message

наб

unread,
Apr 29, 2022, 12:50:03 PM4/29/22
to
Package: git-buildpackage
Version: 0.9.25
Severity: normal
Tags: patch

Dear Maintainer,

I'd renamed a pristine-tar tarball (from .gz to .xz, unrelated),
which signed the topmost commit; this caused export-orig (as part of
buildpackage) to explode with
gbp:error: revision 'gpg: Signature made Fri 29 Apr 2022 17:52:59
CEST^0' not found

A strace revealed that
[pid 11174] execve("/bin/git", ["git", "show-ref", "--verify",
"refs/heads/pristine-tar"], 0x7fff7efef9b0 /* 39 vars */)
= 0
[pid 11175] execve("/bin/git", ["git", "log", "--pretty=format:%H",
"--no-merges", "--grep=pristine-tar .* neomutt_2"...,
"pristine-tar", "--"], 0x7fff7efef9b0 /* 39 vars */) = 0

Which, trivially, yields
gpg: Signature made Fri 29 Apr 2022 17:52:59 CEST
gpg: using RSA key 7D69474E84028C5CC0C44163BCFD0B018D2658F1
gpg: Good signature from "наб <nabijac...@nabijaczleweli.xyz>" [ultimate]
gpg: aka "наб <nabijac...@gmail.com>" [ultimate]
gpg: aka "nabijaczleweli <nabijac...@gmail.com>" [ultimate]
dc0c16c6849cd4a3c9a69c58c1c06e8aadd06aed
ded2b6420ca3739d536e8ebcba789bc259525ef2
176e4ca911c78e6ed9cfd052a4b7b1058450ae26
[...]

Attached is a patch for grep_log(), which adds --no-show-signature,
fixing this.

This may also facilitate #886157?

Best,
наб

-- System Information:
Debian Release: bookworm/sid
APT prefers unstable-debug
APT policy: (500, 'unstable-debug'), (500, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 5.15.0-2-amd64 (SMP w/8 CPU threads)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages git-buildpackage depends on:
ii devscripts 2.22.1
ii git 1:2.35.1-1
ii man-db 2.10.2-1
ii python3 3.10.4-1
ii python3-dateutil 2.8.1-6
ii python3-pkg-resources 59.6.0-1.2
ii sensible-utils 0.0.17

Versions of packages git-buildpackage recommends:
pn cowbuilder | pbuilder | sbuild <none>
ii pristine-tar 1.49
ii python3-requests 2.27.1+dfsg-1

Versions of packages git-buildpackage suggests:
pn python3-notify2 <none>
ii sudo 1.9.10-3
ii unzip 6.0-26

-- no debconf information
diff
signature.asc

Guido Günther

unread,
May 16, 2022, 5:40:03 AM5/16/22
to
tag 1010370 pending
thanks

Date: Mon May 16 11:23:19 2022 +0200
Author: Guido Günther <a...@sigxcpu.org>
Commit ID: 7717b39249c9a439afae918a9e53f304282ecee5
Commit URL: https://git.sigxcpu.org/cgit/git-buildpackage//commit/?id=7717b39249c9a439afae918a9e53f304282ecee5
Patch URL: https://git.sigxcpu.org/cgit/git-buildpackage//patch/?id=7717b39249c9a439afae918a9e53f304282ecee5

git/repository: Disable signatures when grepping for commits

Otherwise get the signature back as well.

Thanks: наб for the patch

Closes: #1010370


Guido Günther

unread,
May 16, 2022, 5:40:04 AM5/16/22
to
Hi,
Wiggled this on top of the current tree. Thanks!
-- Guido
> diff --git a/git-buildpackage-0.9.25.orig/gbp/git/repository.py b/git-buildpackage-0.9.25/gbp/git/repository.py
> index 48d0053..176be9b 100644
> --- a/git-buildpackage-0.9.25.orig/gbp/git/repository.py
> +++ b/git-buildpackage-0.9.25/gbp/git/repository.py
> @@ -1666,6 +1666,7 @@ class GitRepository(object):
> @type since: C{str}
> """
> args = GitArgs('--pretty=format:%H')
> + args.add("--no-show-signature")
> args.add_false(merges, '--no-merges')
> args.add('--grep=%s' % regex)
> args.add_true(since, since)
0 new messages