gitgitgadget / git

GitGitGadget's Git fork. Open Pull Requests here to submit them to the Git mailing list
https://gitgitgadget.github.io/
Other
221 stars 133 forks source link

t7030 is flaky on MacOS #363

Open Denton-L opened 5 years ago

Denton-L commented 5 years ago

See here for more details.

Denton-L commented 5 years ago

Another log here:

Initialized empty Git repository in /Users/denton.liu/projects/git/t/trash directory.t7030-verify-tag.stress-2/.git/
expecting success of 7030.1 'create signed tags': 
    echo 1 >file && git add file &&
    test_tick && git commit -m initial &&
    git tag -s -m initial initial &&
    git branch side &&

    echo 2 >file && test_tick && git commit -a -m second &&
    git tag -s -m second second &&

    git checkout side &&
    echo 3 >elif && git add elif &&
    test_tick && git commit -m "third on side" &&

    git checkout master &&
    test_tick && git merge -S side &&
    git tag -s -m merge merge &&

    echo 4 >file && test_tick && git commit -a -S -m "fourth unsigned" &&
    git tag -a -m fourth-unsigned fourth-unsigned &&

    test_tick && git commit --amend -S -m "fourth signed" &&
    git tag -s -m fourth fourth-signed &&

    echo 5 >file && test_tick && git commit -a -m "fifth" &&
    git tag fifth-unsigned &&

    git config commit.gpgsign true &&
    echo 6 >file && test_tick && git commit -a -m "sixth" &&
    git tag -a -m sixth sixth-unsigned &&

    test_tick && git rebase -f HEAD^^ && git tag -s -m 6th sixth-signed HEAD^ &&
    git tag -m seventh -s seventh-signed &&

    echo 8 >file && test_tick && git commit -a -m eighth &&
    git tag -uB7227189 -m eighth eighth-signed-alt

++ echo 1
++ git add file
++ test_tick
++ test -z ''
++ test_tick=1112911993
++ GIT_COMMITTER_DATE='1112911993 -0700'
++ GIT_AUTHOR_DATE='1112911993 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git commit -m initial
[master (root-commit) 777c62c] initial
 Author: A U Thor <author@example.com>
 1 file changed, 1 insertion(+)
 create mode 100644 file
++ git tag -s -m initial initial
++ git branch side
++ echo 2
++ test_tick
++ test -z set
++ test_tick=1112912053
++ GIT_COMMITTER_DATE='1112912053 -0700'
++ GIT_AUTHOR_DATE='1112912053 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git commit -a -m second
[master 38545ae] second
 Author: A U Thor <author@example.com>
 1 file changed, 1 insertion(+), 1 deletion(-)
++ git tag -s -m second second
++ git checkout side
Switched to branch 'side'
++ echo 3
++ git add elif
++ test_tick
++ test -z set
++ test_tick=1112912113
++ GIT_COMMITTER_DATE='1112912113 -0700'
++ GIT_AUTHOR_DATE='1112912113 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git commit -m 'third on side'
[side 684a8f8] third on side
 Author: A U Thor <author@example.com>
 1 file changed, 1 insertion(+)
 create mode 100644 elif
++ git checkout master
Switched to branch 'master'
++ test_tick
++ test -z set
++ test_tick=1112912173
++ GIT_COMMITTER_DATE='1112912173 -0700'
++ GIT_AUTHOR_DATE='1112912173 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git merge -S side
Merging:
38545ae second
virtual side
found 1 common ancestor:
777c62c initial
Merge made by the 'recursive' strategy.
 elif | 1 +
 1 file changed, 1 insertion(+)
 create mode 100644 elif
++ git tag -s -m merge merge
++ echo 4
++ test_tick
++ test -z set
++ test_tick=1112912233
++ GIT_COMMITTER_DATE='1112912233 -0700'
++ GIT_AUTHOR_DATE='1112912233 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git commit -a -S -m 'fourth unsigned'
[master f07aedb] fourth unsigned
 Author: A U Thor <author@example.com>
 1 file changed, 1 insertion(+), 1 deletion(-)
++ git tag -a -m fourth-unsigned fourth-unsigned
++ test_tick
++ test -z set
++ test_tick=1112912293
++ GIT_COMMITTER_DATE='1112912293 -0700'
++ GIT_AUTHOR_DATE='1112912293 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git commit --amend -S -m 'fourth signed'
[master 7dd1122] fourth signed
 Author: A U Thor <author@example.com>
 Date: Thu Apr 7 15:17:13 2005 -0700
 1 file changed, 1 insertion(+), 1 deletion(-)
++ git tag -s -m fourth fourth-signed
++ echo 5
++ test_tick
++ test -z set
++ test_tick=1112912353
++ GIT_COMMITTER_DATE='1112912353 -0700'
++ GIT_AUTHOR_DATE='1112912353 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git commit -a -m fifth
[master ba8052b] fifth
 Author: A U Thor <author@example.com>
 1 file changed, 1 insertion(+), 1 deletion(-)
++ git tag fifth-unsigned
++ git config commit.gpgsign true
++ echo 6
++ test_tick
++ test -z set
++ test_tick=1112912413
++ GIT_COMMITTER_DATE='1112912413 -0700'
++ GIT_AUTHOR_DATE='1112912413 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git commit -a -m sixth
[master a5a4979] sixth
 Author: A U Thor <author@example.com>
 1 file changed, 1 insertion(+), 1 deletion(-)
++ git tag -a -m sixth sixth-unsigned
++ test_tick
++ test -z set
++ test_tick=1112912473
++ GIT_COMMITTER_DATE='1112912473 -0700'
++ GIT_AUTHOR_DATE='1112912473 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git rebase -f 'HEAD^^'
Current branch master is up to date, rebase forced.
First, rewinding head to replay your work on top of it...
Applying: fifth
Applying: sixth
++ git tag -s -m 6th sixth-signed 'HEAD^'
++ git tag -m seventh -s seventh-signed
++ echo 8
++ test_tick
++ test -z set
++ test_tick=1112912533
++ GIT_COMMITTER_DATE='1112912533 -0700'
++ GIT_AUTHOR_DATE='1112912533 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git commit -a -m eighth
[master a66f6fa] eighth
 Author: A U Thor <author@example.com>
 1 file changed, 1 insertion(+), 1 deletion(-)
++ git tag -uB7227189 -m eighth eighth-signed-alt
ok 1 - create signed tags

expecting success of 7030.2 'create signed tags x509 ': 
    test_config gpg.format x509 &&
    test_config user.signingkey $GIT_COMMITTER_EMAIL &&
    echo 9 >file && test_tick && git commit -a -m "nineth gpgsm-signed" &&
    git tag -s -m nineth nineth-signed-x509

++ test_config gpg.format x509
++ config_dir=
++ test gpg.format = -C
++ test_when_finished 'test_unconfig  '\''gpg.format'\'''
++ test 0 = 0
++ test_cleanup='{ test_unconfig  '\''gpg.format'\''
        } && (exit "$eval_ret"); eval_ret=$?; :'
++ git config gpg.format x509
++ test_config user.signingkey committer@example.com
++ config_dir=
++ test user.signingkey = -C
++ test_when_finished 'test_unconfig  '\''user.signingkey'\'''
++ test 0 = 0
++ test_cleanup='{ test_unconfig  '\''user.signingkey'\''
        } && (exit "$eval_ret"); eval_ret=$?; { test_unconfig  '\''gpg.format'\''
        } && (exit "$eval_ret"); eval_ret=$?; :'
++ git config user.signingkey committer@example.com
++ echo 9
++ test_tick
++ test -z set
++ test_tick=1112912593
++ GIT_COMMITTER_DATE='1112912593 -0700'
++ GIT_AUTHOR_DATE='1112912593 -0700'
++ export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
++ git commit -a -m 'nineth gpgsm-signed'
[master 7eba08f] nineth gpgsm-signed
 Author: A U Thor <author@example.com>
 1 file changed, 1 insertion(+), 1 deletion(-)
++ git tag -s -m nineth nineth-signed-x509
++ test_unconfig user.signingkey
++ config_dir=
++ test user.signingkey = -C
++ git config --unset-all user.signingkey
++ config_status=0
++ case "$config_status" in
++ return 0
++ exit 0
++ eval_ret=0
++ test_unconfig gpg.format
++ config_dir=
++ test gpg.format = -C
++ git config --unset-all gpg.format
++ config_status=0
++ case "$config_status" in
++ return 0
++ exit 0
++ eval_ret=0
++ :
ok 2 - create signed tags x509 

expecting success of 7030.3 'verify and show signatures': 
    (
        for tag in initial second merge fourth-signed sixth-signed seventh-signed
        do
            git verify-tag $tag 2>actual &&
            grep "Good signature from" actual &&
            ! grep "BAD signature from" actual &&
            echo $tag OK || exit 1
        done
    ) &&
    (
        for tag in fourth-unsigned fifth-unsigned sixth-unsigned
        do
            test_must_fail git verify-tag $tag 2>actual &&
            ! grep "Good signature from" actual &&
            ! grep "BAD signature from" actual &&
            echo $tag OK || exit 1
        done
    ) &&
    (
        for tag in eighth-signed-alt
        do
            git verify-tag $tag 2>actual &&
            grep "Good signature from" actual &&
            ! grep "BAD signature from" actual &&
            grep "not certified" actual &&
            echo $tag OK || exit 1
        done
    )

++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag initial
++ grep 'Good signature from' actual
gpg: Good signature from "C O Mitter <committer@example.com>" [ultimate]
++ grep 'BAD signature from' actual
++ echo initial OK
initial OK
++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag second
++ grep 'Good signature from' actual
gpg: Good signature from "C O Mitter <committer@example.com>" [ultimate]
++ grep 'BAD signature from' actual
++ echo second OK
second OK
++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag merge
++ grep 'Good signature from' actual
gpg: Good signature from "C O Mitter <committer@example.com>" [ultimate]
++ grep 'BAD signature from' actual
++ echo merge OK
merge OK
++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag fourth-signed
++ grep 'Good signature from' actual
gpg: Good signature from "C O Mitter <committer@example.com>" [ultimate]
++ grep 'BAD signature from' actual
++ echo fourth-signed OK
fourth-signed OK
++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag sixth-signed
++ grep 'Good signature from' actual
gpg: Good signature from "C O Mitter <committer@example.com>" [ultimate]
++ grep 'BAD signature from' actual
++ echo sixth-signed OK
sixth-signed OK
++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag seventh-signed
++ grep 'Good signature from' actual
gpg: Good signature from "C O Mitter <committer@example.com>" [ultimate]
++ grep 'BAD signature from' actual
++ echo seventh-signed OK
seventh-signed OK
++ for tag in fourth-unsigned fifth-unsigned sixth-unsigned
++ test_must_fail git verify-tag fourth-unsigned
++ case "$1" in
++ _test_ok=
++ git verify-tag fourth-unsigned
++ exit_code=1
++ test 1 -eq 0
++ test_match_signal 13 1
++ test 1 = 141
++ test 1 = 269
++ return 1
++ test 1 -gt 129
++ test 1 -eq 127
++ test 1 -eq 126
++ return 0
++ grep 'Good signature from' actual
++ grep 'BAD signature from' actual
++ echo fourth-unsigned OK
fourth-unsigned OK
++ for tag in fourth-unsigned fifth-unsigned sixth-unsigned
++ test_must_fail git verify-tag fifth-unsigned
++ case "$1" in
++ _test_ok=
++ git verify-tag fifth-unsigned
++ exit_code=1
++ test 1 -eq 0
++ test_match_signal 13 1
++ test 1 = 141
++ test 1 = 269
++ return 1
++ test 1 -gt 129
++ test 1 -eq 127
++ test 1 -eq 126
++ return 0
++ grep 'Good signature from' actual
++ grep 'BAD signature from' actual
++ echo fifth-unsigned OK
fifth-unsigned OK
++ for tag in fourth-unsigned fifth-unsigned sixth-unsigned
++ test_must_fail git verify-tag sixth-unsigned
++ case "$1" in
++ _test_ok=
++ git verify-tag sixth-unsigned
++ exit_code=1
++ test 1 -eq 0
++ test_match_signal 13 1
++ test 1 = 141
++ test 1 = 269
++ return 1
++ test 1 -gt 129
++ test 1 -eq 127
++ test 1 -eq 126
++ return 0
++ grep 'Good signature from' actual
++ grep 'BAD signature from' actual
++ echo sixth-unsigned OK
sixth-unsigned OK
++ for tag in eighth-signed-alt
++ git verify-tag eighth-signed-alt
++ grep 'Good signature from' actual
gpg: Good signature from "Eris Discordia <discord@example.net>" [unknown]
++ grep 'BAD signature from' actual
++ grep 'not certified' actual
gpg: WARNING: This key is not certified with a trusted signature!
++ echo eighth-signed-alt OK
eighth-signed-alt OK
ok 3 - verify and show signatures

expecting success of 7030.4 'verify and show signatures x509': 
    git verify-tag nineth-signed-x509 2>actual &&
    grep "Good signature from" actual &&
    ! grep "BAD signature from" actual &&
    echo nineth-signed-x509 OK

++ git verify-tag nineth-signed-x509
++ grep 'Good signature from' actual
gpgsm: Good signature from "/CN=C O Mitter/O=Example/SN=C O/GN=Mitter"
++ grep 'BAD signature from' actual
++ echo nineth-signed-x509 OK
nineth-signed-x509 OK
ok 4 - verify and show signatures x509

expecting success of 7030.5 'detect fudged signature': 
    git cat-file tag seventh-signed >raw &&
    sed -e "/^tag / s/seventh/7th forged/" raw >forged1 &&
    git hash-object -w -t tag forged1 >forged1.tag &&
    test_must_fail git verify-tag $(cat forged1.tag) 2>actual1 &&
    grep "BAD signature from" actual1 &&
    ! grep "Good signature from" actual1

++ git cat-file tag seventh-signed
++ sed -e '/^tag / s/seventh/7th forged/' raw
++ git hash-object -w -t tag forged1
+++ cat forged1.tag
++ test_must_fail git verify-tag f4455eccdffe94bb64f15351d0b36b260f63f800
++ case "$1" in
++ _test_ok=
++ git verify-tag f4455eccdffe94bb64f15351d0b36b260f63f800
++ exit_code=1
++ test 1 -eq 0
++ test_match_signal 13 1
++ test 1 = 141
++ test 1 = 269
++ return 1
++ test 1 -gt 129
++ test 1 -eq 127
++ test 1 -eq 126
++ return 0
++ grep 'BAD signature from' actual1
gpg: BAD signature from "C O Mitter <committer@example.com>" [ultimate]
++ grep 'Good signature from' actual1
ok 5 - detect fudged signature

expecting success of 7030.6 'verify signatures with --raw': 
    (
        for tag in initial second merge fourth-signed sixth-signed seventh-signed
        do
            git verify-tag --raw $tag 2>actual &&
            grep "GOODSIG" actual &&
            ! grep "BADSIG" actual &&
            echo $tag OK || exit 1
        done
    ) &&
    (
        for tag in fourth-unsigned fifth-unsigned sixth-unsigned
        do
            test_must_fail git verify-tag --raw $tag 2>actual &&
            ! grep "GOODSIG" actual &&
            ! grep "BADSIG" actual &&
            echo $tag OK || exit 1
        done
    ) &&
    (
        for tag in eighth-signed-alt
        do
            git verify-tag --raw $tag 2>actual &&
            grep "GOODSIG" actual &&
            ! grep "BADSIG" actual &&
            grep "TRUST_UNDEFINED" actual &&
            echo $tag OK || exit 1
        done
    )

++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag --raw initial
++ grep GOODSIG actual
[GNUPG:] GOODSIG 13B6F51ECDDE430D C O Mitter <committer@example.com>
++ grep BADSIG actual
++ echo initial OK
initial OK
++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag --raw second
++ grep GOODSIG actual
[GNUPG:] GOODSIG 13B6F51ECDDE430D C O Mitter <committer@example.com>
++ grep BADSIG actual
++ echo second OK
second OK
++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag --raw merge
++ grep GOODSIG actual
[GNUPG:] GOODSIG 13B6F51ECDDE430D C O Mitter <committer@example.com>
++ grep BADSIG actual
++ echo merge OK
merge OK
++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag --raw fourth-signed
++ grep GOODSIG actual
[GNUPG:] GOODSIG 13B6F51ECDDE430D C O Mitter <committer@example.com>
++ grep BADSIG actual
++ echo fourth-signed OK
fourth-signed OK
++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag --raw sixth-signed
++ grep GOODSIG actual
[GNUPG:] GOODSIG 13B6F51ECDDE430D C O Mitter <committer@example.com>
++ grep BADSIG actual
++ echo sixth-signed OK
sixth-signed OK
++ for tag in initial second merge fourth-signed sixth-signed seventh-signed
++ git verify-tag --raw seventh-signed
++ grep GOODSIG actual
[GNUPG:] GOODSIG 13B6F51ECDDE430D C O Mitter <committer@example.com>
++ grep BADSIG actual
++ echo seventh-signed OK
seventh-signed OK
++ for tag in fourth-unsigned fifth-unsigned sixth-unsigned
++ test_must_fail git verify-tag --raw fourth-unsigned
++ case "$1" in
++ _test_ok=
++ git verify-tag --raw fourth-unsigned
++ exit_code=1
++ test 1 -eq 0
++ test_match_signal 13 1
++ test 1 = 141
++ test 1 = 269
++ return 1
++ test 1 -gt 129
++ test 1 -eq 127
++ test 1 -eq 126
++ return 0
++ grep GOODSIG actual
++ grep BADSIG actual
++ echo fourth-unsigned OK
fourth-unsigned OK
++ for tag in fourth-unsigned fifth-unsigned sixth-unsigned
++ test_must_fail git verify-tag --raw fifth-unsigned
++ case "$1" in
++ _test_ok=
++ git verify-tag --raw fifth-unsigned
++ exit_code=1
++ test 1 -eq 0
++ test_match_signal 13 1
++ test 1 = 141
++ test 1 = 269
++ return 1
++ test 1 -gt 129
++ test 1 -eq 127
++ test 1 -eq 126
++ return 0
++ grep GOODSIG actual
++ grep BADSIG actual
++ echo fifth-unsigned OK
fifth-unsigned OK
++ for tag in fourth-unsigned fifth-unsigned sixth-unsigned
++ test_must_fail git verify-tag --raw sixth-unsigned
++ case "$1" in
++ _test_ok=
++ git verify-tag --raw sixth-unsigned
++ exit_code=1
++ test 1 -eq 0
++ test_match_signal 13 1
++ test 1 = 141
++ test 1 = 269
++ return 1
++ test 1 -gt 129
++ test 1 -eq 127
++ test 1 -eq 126
++ return 0
++ grep GOODSIG actual
++ grep BADSIG actual
++ echo sixth-unsigned OK
sixth-unsigned OK
++ for tag in eighth-signed-alt
++ git verify-tag --raw eighth-signed-alt
++ grep GOODSIG actual
[GNUPG:] GOODSIG 65A0EEA02E30CAD7 Eris Discordia <discord@example.net>
++ grep BADSIG actual
++ grep TRUST_UNDEFINED actual
[GNUPG:] TRUST_UNDEFINED 0 pgp
++ echo eighth-signed-alt OK
eighth-signed-alt OK
ok 6 - verify signatures with --raw

expecting success of 7030.7 'verify signatures with --raw x509': 
    git verify-tag --raw nineth-signed-x509 2>actual &&
    grep "GOODSIG" actual &&
    ! grep "BADSIG" actual &&
    echo nineth-signed-x509 OK

++ git verify-tag --raw nineth-signed-x509
error: last command exited with $?=1
not ok 7 - verify signatures with --raw x509
#   
#       git verify-tag --raw nineth-signed-x509 2>actual &&
#       grep "GOODSIG" actual &&
#       ! grep "BADSIG" actual &&
#       echo nineth-signed-x509 OK
#   
dscho commented 5 years ago
expecting success of 7030.7 'verify signatures with --raw x509': 
  git verify-tag --raw nineth-signed-x509 2>actual &&
  grep "GOODSIG" actual &&
  ! grep "BADSIG" actual &&
  echo nineth-signed-x509 OK

++ git verify-tag --raw nineth-signed-x509
error: last command exited with $?=1

Any indication what's in actual after that?

Denton-L commented 5 years ago

Unfortunately not. I was cleaning up some old files in my directory and I found this one so I decided to throw it here. The original actual is long gone.