forked from git/git
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
ci(windows): avoid using external gpg by mistake #3463
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
dscho
merged 1 commit into
git-for-windows:main
from
dscho:work-around-ci-failures-with-gpg
Oct 13, 2021
Merged
ci(windows): avoid using external gpg by mistake #3463
dscho
merged 1 commit into
git-for-windows:main
from
dscho:work-around-ci-failures-with-gpg
Oct 13, 2021
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
On the Windows build agents, a lot of programs are installed, and added to the PATH automatically. One such program is Git for Windows, and due to the way it is set up, unfortunately its copy of `gpg.exe` is also reachable via the PATH. This usually does not pose any problems. To the contrary, it even allows us to test the GPG parts of Git's test suite even if `gpg.exe` is not delivered as part of `git-sdk-64-minimal`, the minimal subset of Git for Windows' SDK that we use in the CI builds to compile Git. However, every once in a while we build a new MSYS2 runtime, which means that there is a mismatch between the copy in `git-sdk-64-minimal` and the copy in C:\Program Files\Git\usr\bin. When that happens we hit the dreaded problem where only one `msys-2.0.dll` is expected to be in the PATH, and things start to fail. Let's avoid all of this by restricting the PATH to the minimal set. This is actually done by `git-sdk-64-minimal`'s `/etc/profile`, and we just have to source this file manually (one would expect that it is sourced automatically, but the Bash steps in Azure Pipelines/GitHub workflows are explicitly run using `--noprofile`, hence the need for doing this explicitly). Signed-off-by: Johannes Schindelin <[email protected]>
63c5038
to
cd5242d
Compare
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 13, 2021
ci(windows): avoid using external gpg by mistake
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 13, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Oct 13, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Oct 13, 2021
ci(windows): avoid using external gpg by mistake
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 13, 2021
ci(windows): avoid using external gpg by mistake
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 13, 2021
ci(windows): avoid using external gpg by mistake
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 13, 2021
ci(windows): avoid using external gpg by mistake
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 13, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
to dscho/git
that referenced
this pull request
Oct 13, 2021
…lures-with-gpg ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Oct 13, 2021
ci(windows): avoid using external gpg by mistake
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 13, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Oct 14, 2021
ci(windows): avoid using external gpg by mistake
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 14, 2021
ci(windows): avoid using external gpg by mistake
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 14, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Oct 14, 2021
ci(windows): avoid using external gpg by mistake
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 14, 2021
ci(windows): avoid using external gpg by mistake
git-for-windows-ci
pushed a commit
that referenced
this pull request
Oct 14, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Oct 15, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Oct 15, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Oct 29, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Nov 1, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Nov 4, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Nov 4, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Nov 10, 2021
ci(windows): avoid using external gpg by mistake
dscho
added a commit
that referenced
this pull request
Nov 16, 2021
ci(windows): avoid using external gpg by mistake
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I stumbled over a CI failure this morning when I scrambled to tie up all the loose ends for an unexpected v2.33.1 release. Turns out that the CI picked up the installed Git for Windows'
gpg.exe
, and due to a mismatch in the MSYS2 runtime between the installed Git for Windows and the subset of the Git for Windows SDK used for compiling in the CI runs, it worked just enough to pass the prereq, but then failed the tests.