From: Junio C Hamano <gitster@pobox.com>
To: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Todd Zullinger <tmz@pobox.com>,
git@vger.kernel.org, Kousik Sanagavarapu <five231003@gmail.com>,
brian m. carlson <sandals@crustytoothpaste.net>
Subject: Re: [PATCH 0/2] t/lib-gpg: ensure GNUPGHOME is created as needed
Date: Mon, 27 Oct 2025 10:38:39 -0700 [thread overview]
Message-ID: <xmqqqzuoi6sg.fsf@gitster.g> (raw)
In-Reply-To: <87zf9c8glu.fsf@email.froward.int.ebiederm.org> (Eric W. Biederman's message of "Mon, 27 Oct 2025 11:16:45 -0500")
"Eric W. Biederman" <ebiederm@xmission.com> writes:
>> I am tempted to do this in the meantime, but I'd really prefer not
>> to have to do so, assuming that these tests, when fixed, would be
>> materially contributing to the health of our codebase.
>
> I just dug into this a little and hopefully I have paged enough
> state back to understand this.
>
> In my testing a missing GNUPGHOME appears enough to prevent the
> prerequisite from succeeding. So let's fix that. Todd Zullinger's sent
> some nice patches to do that (up-thread), or you can take use my minimal
> version.
Sorry, but I am confused. The above "tempted to do this" was meant
to come on top of Todd's patches. IOW, I was seeing flakyness with
Todd's patches that fixed the missing GNUPGHOME.
> The only possible source of flakiness in the tests I can see is the
> possibility of t/t1016/gpg not getting called (which uses a fixed
> timestamp). It appears you just fixed that problem in commit
> 516bf45749bb ("t1016: make sure to use specified GPG").
I think that one also is in 'seen', and yet we saw t1016 flaky X-<.
Let me isolate the relevant topics and test them again, i.e.
$ git checkout --detach v2.51.0
$ git merge --no-ff jc/t1016-setup-fix ;# 516bf45749
$ git merge --no-ff tz/test-prepare-gnupghome~1 ;# 6cd8369ef3
$ git log --no-merges --oneline v2.51.0..
516bf45749 (jc/t1016-setup-fix) t1016: make sure to use specified GPG
6cd8369ef3 t/lib-gpg: call prepare_gnupghome() in GPG2 prereq
a35952b493 t/lib-gpg: add prepare_gnupghome() to create GNUPGHOME dir
$ make
$ cd t && ./t1016-*.sh --stress
FAIL 10.1
FAIL 5.1
FAIL 34.1
...
++ eval 'diff -u' '"$@"'
+++ diff -u signedcommit3_sha1 signedcommit3_sha1_expected
--- signedcommit3_sha1 2025-10-27 17:34:58.237496945 +0000
+++ signedcommit3_sha1_expected 2025-10-27 17:34:58.145497051 +0000
@@ -1 +1 @@
-de9cabc2419f97eb665452c198ed93e890a7ef87
+c87cd5157461a81b60ef6d3c47562c12b328ef54
error: last command exited with $?=1
not ok 163 - Verify commit signedcommit3's sha1 oid
#
# git --git-dir=repo-sha256/.git rev-parse --output-object-format=sha1 ${sha256_oid} >${name}_sha1 &&
# test_cmp ${name}_sha1 ${name}_sha1_expected
#
1..163
> With that commit reverted I can reproduce the flakiness locally
> by just running the test manually a few times.
The above is with all three patches mentioned.
FWIW, "gpg --version | head -2" says
gpg (GnuPG) 2.4.8
libgcrypt 1.11.2
Hmmmm.....
> I believe I used the GPG2 prereq because I don't have the older version
> of GPG to test with. So I don't know if t1016 would work on the older
> version of GPG or not.
>
>
> diff --git a/t/lib-gpg.sh b/t/lib-gpg.sh
> index 937b876bd052..c4bbedfe081e 100644
> --- a/t/lib-gpg.sh
> +++ b/t/lib-gpg.sh
> @@ -62,6 +62,8 @@ test_lazy_prereq GPG2 '
> exit 1
> ;;
> *)
> + mkdir "$GNUPGHOME" &&
> + chmod 0700 "$GNUPGHOME" &&
> (gpgconf --kill all || : ) &&
> gpg --homedir "${GNUPGHOME}" --import \
> "$TEST_DIRECTORY"/lib-gpg/keyring.gpg &&
>
>
> Eric
next prev parent reply other threads:[~2025-10-27 17:38 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-03 15:37 [PATCH 0/2] t/lib-gpg: ensure GNUPGHOME is created as needed Todd Zullinger
2024-07-03 15:37 ` [PATCH 1/2] t/lib-gpg: add prepare_gnupghome() to create GNUPGHOME dir Todd Zullinger
2024-07-03 15:37 ` [PATCH 2/2] t/lib-gpg: call prepare_gnupghome() in GPG2 prereq Todd Zullinger
2024-07-03 16:29 ` [PATCH 0/2] t/lib-gpg: ensure GNUPGHOME is created as needed Todd Zullinger
2025-02-28 15:26 ` Todd Zullinger
2025-10-26 1:25 ` Junio C Hamano
2025-10-27 16:16 ` Eric W. Biederman
2025-10-27 17:38 ` Junio C Hamano [this message]
2025-10-27 19:03 ` Eric W. Biederman
2025-10-27 19:32 ` Eric W. Biederman
2025-10-27 20:32 ` Junio C Hamano
2025-10-28 16:01 ` [PATCH] t1016-compatObjectFormat: Really freeze time for reproduciblity Eric W. Biederman
2025-10-28 17:15 ` Junio C Hamano
2025-10-29 3:05 ` Todd Zullinger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqqzuoi6sg.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=ebiederm@xmission.com \
--cc=five231003@gmail.com \
--cc=git@vger.kernel.org \
--cc=sandals@crustytoothpaste.net \
--cc=tmz@pobox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.