···4343 # Always assume all markers valid (this is needed because we remove markers; they are non-deterministic).
4444 # Also, don't clean up environment variables (so that NIX_ environment variables are passed to compilers).
4545, enableNixHacks ? false
4646-, version ? "7.0.2",
4646+, version ? "7.1.0",
4747}:
48484949let
···51515252 src = fetchurl {
5353 url = "https://github.com/bazelbuild/bazel/releases/download/${version}/bazel-${version}-dist.zip";
5454- hash = "sha256-3qK5BXXUPvPkHEAvZMJIGETsvwtA+FSLdaIEpNUE4DU=";
5454+ hash = "sha256-HiDQyJ98nRtKOBqMWGtKQ1qWv8Qfu880osKUlOs4Z6E=";
5555 };
56565757 # Use builtins.fetchurl to avoid IFD, in particular on hydra
···11diff --git a/src/main/java/com/google/devtools/build/lib/rules/repository/RepositoryDelegatorFunction.java b/src/main/java/com/google/devtools/build/lib/rules/repository/RepositoryDelegatorFunction.java
22-index 845c8b6aa3..6f07298bd0 100644
22+index 4d8c46f8d5..ed311226f0 100644
33--- a/src/main/java/com/google/devtools/build/lib/rules/repository/RepositoryDelegatorFunction.java
44+++ b/src/main/java/com/google/devtools/build/lib/rules/repository/RepositoryDelegatorFunction.java
55-@@ -171,14 +171,8 @@ public final class RepositoryDelegatorFunction implements SkyFunction {
66-77- DigestWriter digestWriter = new DigestWriter(directories, repositoryName, rule);
88- if (shouldUseCachedRepos(env, handler, repoRoot, rule)) {
99-- // Make sure marker file is up-to-date; correctly describes the current repository state
1010-- byte[] markerHash = digestWriter.areRepositoryAndMarkerFileConsistent(handler, env);
1111-- if (env.valuesMissing()) {
1212-- return null;
1313-- }
1414-- if (markerHash != null) {
1515-- return RepositoryDirectoryValue.builder().setPath(repoRoot).setDigest(markerHash).build();
1616-- }
1717-+ // Nix hack: Always consider cached dirs as up-to-date
1818-+ return RepositoryDirectoryValue.builder().setPath(repoRoot).setDigest(digestWriter.writeMarkerFile()).build();
1919- }
55+@@ -178,18 +178,8 @@ public final class RepositoryDelegatorFunction implements SkyFunction {
66+ }
77+ }
88+ if (shouldUseCachedRepos(env, handler, repoRoot, rule)) {
99+- // Make sure marker file is up-to-date; correctly describes the current repository state
1010+- byte[] markerHash = digestWriter.areRepositoryAndMarkerFileConsistent(handler, env);
1111+- if (env.valuesMissing()) {
1212+- return null;
1313+- }
1414+- if (markerHash != null) { // repo exist & up-to-date
1515+- return RepositoryDirectoryValue.builder()
1616+- .setPath(repoRoot)
1717+- .setDigest(markerHash)
1818+- .setExcludeFromVendoring(shouldExcludeRepoFromVendoring(handler, rule))
1919+- .build();
2020+- }
2121++ // Nix hack: Always consider cached dirs as up-to-date
2222++ return RepositoryDirectoryValue.builder().setPath(repoRoot).setDigest(digestWriter.writeMarkerFile()).build();
2323+ }
20242121- /* At this point: This is a force fetch, a local repository, OR The repository cache is old or
2222-@@ -512,11 +506,12 @@ public final class RepositoryDelegatorFunction implements SkyFunction {
2525+ /* At this point: This is a force fetch, a local repository, OR The repository cache is old or
2626+@@ -610,11 +600,12 @@ public final class RepositoryDelegatorFunction implements SkyFunction {
2327 builder.append(escape(key)).append(" ").append(escape(value)).append("\n");
2428 }
2529 String content = builder.toString();