Add timestamp suffix to Nix repos and build name for test isolation#3562
Merged
Conversation
NixLocalRepo, NixRemoteRepo, NixVirtualRepo and NixBuildName were missing from AddTimestampToGlobalVars, so every Nix integration test run used the literal names cli-nix-local / cli-nix-remote / cli-nix-virtual / cli-nix-build while every other package manager's repos and build name receive the unique "-<runId>-<timestamp>" suffix. This is invisible in CI here because each job runs against its own ephemeral local Artifactory. But when multiple Nix test runs execute concurrently against a shared Artifactory instance, InitBuildToolsTests -> cleanUpOldRepositories deletes another run's just-created cli-nix-* repositories, so initNixTest's isRepoExist checks fail with "Nix test virtual repository doesn't exist". Adding the suffix makes each run's Nix repos and build name unique, matching how every other package manager is already handled (mirrors the earlier UvBuildName fix).
naveenku-jfrog
approved these changes
Jun 21, 2026
fluxxBot
approved these changes
Jun 21, 2026
Contributor
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
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.

Problem
NixLocalRepo,NixRemoteRepo,NixVirtualRepoandNixBuildNameare missing fromAddTimestampToGlobalVars()inutils/tests/utils.go. Every other package manager's repositories and build name receive the unique-<runId>-<timestamp>suffix, but the Nix ones stay literal (cli-nix-local,cli-nix-remote,cli-nix-virtual,cli-nix-build).This is invisible in this repo's CI because each job runs against its own ephemeral local Artifactory. But when multiple Nix test runs execute concurrently against a shared Artifactory instance, they all create and clean up the same repositories:
InitBuildToolsTests→createRequiredRepos()createscli-nix-virtualInitBuildToolsTests→cleanUpOldRepositories()deletescli-nix-virtualinitNixTest→isRepoExist(cli-nix-virtual)→ false →require.Truefails with "Nix test virtual repository doesn't exist."Observed: 14 of 15 concurrent Nix runs failed this way; the repos are created unsuffixed and then deleted out from under each other.
Fix
Add the four Nix globals to
AddTimestampToGlobalVars()so each run's repositories and build name are unique and isolated — matching how every other package manager is already handled (and mirroring the earlierUvBuildNamefix).Testing
go vet ./utils/tests/passes.