From 084a00a6a127df6076a63d16bbb814ad3d176cad Mon Sep 17 00:00:00 2001 From: Johannes Schindelin Date: Wed, 10 Jun 2026 19:48:27 +0200 Subject: [PATCH] component-updates: check pacman-repo, not the Azure Blob storage Until recently, Git for Windows uploaded Pacman packages to an Azure Blob Storage container at `wingit.blob.core.windows.net`, and `getMissingDeployments()` verified a package was published by issuing a HEAD request for each expected `.pkg.tar.xz` URL there. Now that we no longer deploy to that container (see https://github.com/git-for-windows/build-extra/commit/5b44c34581782c792de7d5236b7bac6762efe9e4 and the surrounding work), the Azure Blob URLs return 404 for every newly built package, and `/add relnote` always claims the deployment is missing. The first concrete fallout was on https://github.com/git-for-windows/git/issues/6272#issuecomment-4671432007 where the OpenSSL 3.5.7-1 release was reported as undeployed even though the packages had landed at the tip of each arch branch in https://github.com/git-for-windows/pacman-repo. Point the existing HEAD-based probe at the new home. The package files now live at `https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads//`, which serves the file at the branch tip (so blobs that get pruned from a branch's tip will correctly report as missing, matching `pacman -Syu` semantics). The previous `arch.replace(/_/g, '-')` mapped `x86_64` to `x86-64` to match the legacy Azure container naming; pacman-repo's branch is just `x86_64`, so drop the replacement. Assisted-by: Opus 4.7 Signed-off-by: Johannes Schindelin --- GitForWindowsHelper/component-updates.js | 4 ++-- __tests__/component-updates.test.js | 14 +++++++------- __tests__/index.test.js | 4 ++-- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/GitForWindowsHelper/component-updates.js b/GitForWindowsHelper/component-updates.js index 46256e9b..05c6cb7c 100644 --- a/GitForWindowsHelper/component-updates.js +++ b/GitForWindowsHelper/component-updates.js @@ -143,7 +143,7 @@ const guessReleaseNotes = async (context, issue) => { } } -const pacmanRepositoryBaseURL = 'https://wingit.blob.core.windows.net/' +const pacmanRepositoryBaseURL = 'https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads/' const pacmanRepositoryURLs = (package_name, version, architectures) => architectures.map(arch => { @@ -151,7 +151,7 @@ const pacmanRepositoryURLs = (package_name, version, architectures) => ? `${package_name}-${version}-1-${arch}.pkg.tar.xz` : `${package_name.replace(/^mingw-w64/, `$&-${arch === 'aarch64' ? `clang-${arch}` : arch}`)}-${version}-1-any.pkg.tar.xz` - return `${pacmanRepositoryBaseURL}${arch.replace(/_/g, '-')}/${fileName}` + return `${pacmanRepositoryBaseURL}${arch}/${fileName}` }) const getMissingDeployments = async (package_name, version) => { diff --git a/__tests__/component-updates.test.js b/__tests__/component-updates.test.js index d7046957..b05b342e 100644 --- a/__tests__/component-updates.test.js +++ b/__tests__/component-updates.test.js @@ -83,13 +83,13 @@ href="20230616162552.879387-1-corinna-cygwin@cygwin.com/">cygwin 3.4.7-1 [... even more stuff...]` } -const missingURL = 'https://wingit.blob.core.windows.net/x86-64/curl-8.1.2-1-x86_64.pkg.tar.xz' -const missingAarch64URL = 'https://wingit.blob.core.windows.net/aarch64/mingw-w64-clang-aarch64-curl-8.1.2-1-any.pkg.tar.xz' -const missingMinTTYURL = 'https://wingit.blob.core.windows.net/i686/mintty-1~3.6.5-1-i686.pkg.tar.xz' -const bogus32BitMSYS2RuntimeURL = 'https://wingit.blob.core.windows.net/i686/msys2-runtime-3.4.9-1-i686.pkg.tar.xz' -const bogus64BitMSYS2RuntimeURL = 'https://wingit.blob.core.windows.net/x86-64/msys2-runtime-3.3-3.3.7-1-x86_64.pkg.tar.xz' -const missingOpenSSHURL = 'https://wingit.blob.core.windows.net/i686/openssh-9.5p1-1-i686.pkg.tar.xz' -const missingBashURL = 'https://wingit.blob.core.windows.net/x86-64/bash-5.2.020-1-x86_64.pkg.tar.xz' +const missingURL = 'https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads/x86_64/curl-8.1.2-1-x86_64.pkg.tar.xz' +const missingAarch64URL = 'https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads/aarch64/mingw-w64-clang-aarch64-curl-8.1.2-1-any.pkg.tar.xz' +const missingMinTTYURL = 'https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads/i686/mintty-1~3.6.5-1-i686.pkg.tar.xz' +const bogus32BitMSYS2RuntimeURL = 'https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads/i686/msys2-runtime-3.4.9-1-i686.pkg.tar.xz' +const bogus64BitMSYS2RuntimeURL = 'https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads/x86_64/msys2-runtime-3.3-3.3.7-1-x86_64.pkg.tar.xz' +const missingOpenSSHURL = 'https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads/i686/openssh-9.5p1-1-i686.pkg.tar.xz' +const missingBashURL = 'https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads/x86_64/bash-5.2.020-1-x86_64.pkg.tar.xz' const mockDoesURLReturn404 = jest.fn(url => [ missingURL, missingAarch64URL, diff --git a/__tests__/index.test.js b/__tests__/index.test.js index 92de31b2..ae6eb522 100644 --- a/__tests__/index.test.js +++ b/__tests__/index.test.js @@ -731,7 +731,7 @@ The workflow run [was started](dispatched-workflow-build-and-deploy.yml).`) expect(dispatchedWorkflows.map(e => e.payload.inputs.architecture)).toEqual(['i686']) }) -const missingURL = 'https://wingit.blob.core.windows.net/x86-64/mingw-w64-x86_64-git-lfs-3.4.0-1-any.pkg.tar.xz' +const missingURL = 'https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads/x86_64/mingw-w64-x86_64-git-lfs-3.4.0-1-any.pkg.tar.xz' const mockDoesURLReturn404 = jest.fn(url => url === missingURL) jest.mock('../GitForWindowsHelper/https-request', () => { return { doesURLReturn404: mockDoesURLReturn404 } @@ -779,7 +779,7 @@ testIssueComment({ comment: '/add release note', note: 'missing deployment' }, { expect(context.res).toEqual({ body: `The following deployment(s) are missing: -* https://wingit.blob.core.windows.net/x86-64/mingw-w64-x86_64-git-lfs-3.4.0-1-any.pkg.tar.xz`, +* https://raw.githubusercontent.com/git-for-windows/pacman-repo/refs/heads/x86_64/mingw-w64-x86_64-git-lfs-3.4.0-1-any.pkg.tar.xz`, headers: undefined, status: 500 })