Skip to content

Commit

Permalink
[7.0.1] Fix output materialized as symlink when building without the …
Browse files Browse the repository at this point in the history
…bytes.

This appears to have worked in 6.2.x, got broken in 6.3.x, and is working
again at head. The divergence is too great at this point, so it's not possible
to cherry-pick the necessary changes from head. Instead, I've written a
targeted fix that falls back to downloading every target output if at least
one of the outputs was materialized as a symlink.

Fixes bazelbuild#19143.
  • Loading branch information
Gormo committed Jan 24, 2024
1 parent ff36d87 commit 5bb893f
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1291,6 +1291,11 @@ private boolean shouldDownload(RemoteActionResult result, PathFragment execPath)
if (result.getExitCode() != 0) {
return true;
}
// An output materialized as a symlink might point to one of the other outputs.
if (!result.getOutputSymlinks().isEmpty() || !result.getOutputFileSymlinks().isEmpty()
|| !result.getOutputDirectorySymlinks().isEmpty()) {
return true;
}
return remoteOutputChecker.shouldDownloadOutput(execPath);
}

Expand Down

0 comments on commit 5bb893f

Please sign in to comment.