fix(integration): make integration test pass on macOS#185
Open
xytan0056 wants to merge 1 commit into
Open
Conversation
The bazel test sandbox strips HOME, which the pinned tools/bazel wrapper (Python bazelisk) requires — on macOS it resolves its cache only via HOME and ignores XDG_CACHE_HOME. The old per-server XDG_CACHE_HOME override also pointed the inner bazel at a cold cache, so on Linux CI two parallel graph computations in GetChangedTargets raced to download the same bazel release (corrupt binary -> exit status 22, then a hang), and on macOS the inner bazel failed with "$HOME is not defined" / SSL cert errors while re-downloading. - Pass HOME through to the sandbox so the inner bazel reuses the release the outer `bazel test` already downloaded (no in-test download, no race). - Set bazel_command to the repo's pinned tools/bazel so inner and outer share the same cache instead of fetching bazelisk from GitHub latest. - Drop the per-server XDG_CACHE_HOME override.
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.
fixes CI
https://github.com/uber/tango/actions/runs/29140659260/job/86512997744#step:3:520
GetChangedTargetscomputes two graphs in parallel; both raced to download the same bazel release, corrupting it (exit status 22) then hanging to the deadline.And mac
the inner bazel failed with
$HOME is not definedand SSL cert errors while re-downloading.Fix:
HOMEthrough to the sandbox so the inner bazel reuses the release the outerbazel testalready downloaded — no in-test download, no race.bazel_commandto the repo's pinnedtools/bazelso inner and outer share one cache instead of fetching bazelisk from GitHublatest.${BAZEL}is alreayd called in makefile rule, so by the time integ test is run, it's already downloadedXDG_CACHE_HOMEoverride.##test
verified
make test-integrationpasses locally on macverified CI