Skip to content

Conversation

@doringeman
Copy link

On self-hosted runners, the tool cache directory persists between runs. When GitHub's cloud cache doesn't have an entry (first run, evicted, etc.), but the local MSI file exists from a previous run, tc.downloadTool() fails with "Destination file path already exists".

This fix checks if the existing MSI has a valid checksum before downloading:

  • If valid: reuse it (skip download)
  • If invalid: delete and re-download

@bradfitz bradfitz requested a review from mpminardi January 14, 2026 15:35
@mpminardi
Copy link
Member

@doringeman thank you for this! Can you run a make build and add the changes under dist to this PR?

On self-hosted runners, the tool cache directory persists between runs.
When GitHub's cloud cache doesn't have an entry (first run, evicted, etc.), but the local MSI file exists from a previous run, tc.downloadTool() fails with "Destination file path already exists".

This fix checks if the existing MSI has a valid checksum before downloading:
- If valid: reuse it (skip download)
- If invalid: delete and re-download

Signed-off-by: Dorin Geman <[email protected]>
@doringeman doringeman force-pushed the fix-windows-msi-download-self-hosted-runners branch from 8bf3174 to 3a91841 Compare January 15, 2026 08:10
@doringeman
Copy link
Author

Hey @mpminardi, updated, thanks! Sorry I missed that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants