From: Patrick Steinhardt Date: Thu, 24 Sep 2026 14:09:16 GMT Subject: [PATCH 7/7] gitlab-ci: fix hanging MSVC jobs Message-ID: <20260924-pks-meson-improvements-v1-7-90b7f79f1c4e@pks.im> In-Reply-To: <20260924-pks-meson-improvements-v1-0-90b7f79f1c4e@pks.im> Starting with GitLab Runner 19.x, the runner executes `git credential reject` in its cleanup stage. This has bad interactions with our build environment because we install our own version of PortableGit, and the runner picks up that version of Git. The consequence is that we invoke PortableGit's default credential manager, which is Git Credential Manager for Windows. GCM then tries to use Windows Credential Manager, but it cannot and thus the job hangs in its cleanup phase forever. Fix this hang by unsetting the credential helper after installing PortableGit. This means that `git credential reject` becomes a no-op, and thus the cleanup succeeds again. Signed-off-by: Patrick Steinhardt --- ci/install-dependencies.ps1 | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/ci/install-dependencies.ps1 b/ci/install-dependencies.ps1 index e3b367fa54..2ceb5dd99a 100755 --- a/ci/install-dependencies.ps1 +++ b/ci/install-dependencies.ps1 @@ -53,3 +53,11 @@ Invoke-Installer msiexec.exe @('/i', $mesonMsi, 'INSTALLDIR=C:\Meson', '/quiet', $rustMsi = Get-Installer "rust.msi" ` "https://static.rust-lang.org/dist/rust-$RustVersion-x86_64-pc-windows-msvc.msi" Invoke-Installer msiexec.exe @('/i', $rustMsi, 'INSTALLDIR=C:\Rust', 'ADDLOCAL=Rustc,Cargo,Std', '/quiet', '/norestart') + +# Disable Git Credential Manager, which is auto-configured by PortableGit. +# GitLab's runner picks up this Git in its cleanup stage and runs `git +# credential reject`, which hangs in GCM and makes the job time out. +& "C:\Program Files\Git\bin\git.exe" config unset --all --system credential.helper +if ($LASTEXITCODE -ne 0 -and $LASTEXITCODE -ne 5) { + throw "Failed to unset credential.helper with exit code $LASTEXITCODE" +} -- 2.56.0.rc2.329.gd58861e689.dirty