From 7126d61ca2c988a7d25e1212c810e1796a9e9108 Mon Sep 17 00:00:00 2001 From: Andreas Herrmann Date: Fri, 12 Jun 2020 11:31:29 +0200 Subject: [PATCH] Increment Windows cache URL We've seen a series of failures of the form ``` ERROR: D:/a/1/s/daml-assistant/integration-tests/BUILD.bazel:162:1: output 'daml-assistant/integration-tests/create-daml-app-tests.exe' was not created ERROR: D:/a/1/s/daml-assistant/integration-tests/BUILD.bazel:162:1: not all outputs were created or valid ``` across multiple machines. We suspect cache poisoning as the cause. This increments the cache URL to effectively clear the cache. changelog_begin changelog_end --- build.ps1 | 2 ++ ci/configure-bazel.sh | 2 +- compatibility/build-release-artifacts-windows.ps1 | 1 + compatibility/test-windows.ps1 | 1 + 4 files changed, 5 insertions(+), 1 deletion(-) diff --git a/build.ps1 b/build.ps1 index 062a4e22e090..c815dbc9dd1d 100644 --- a/build.ps1 +++ b/build.ps1 @@ -49,6 +49,8 @@ function bazel() { # which is a workaround for this problem. bazel shutdown +bazel clean --expunge + # Prefetch nodejs_dev_env to avoid permission denied errors on external/nodejs_dev_env/nodejs_dev_env/node.exe # It isn’t clear where exactly those errors are coming from. bazel fetch @nodejs_dev_env//... diff --git a/ci/configure-bazel.sh b/ci/configure-bazel.sh index 779145d13e54..77fb6b2e7f24 100755 --- a/ci/configure-bazel.sh +++ b/ci/configure-bazel.sh @@ -74,7 +74,7 @@ if is_windows; then SUFFIX="${SUFFIX:0:3}" echo "Platform suffix: $SUFFIX" # We include an extra version at the end that we can bump manually. - CACHE_SUFFIX="$SUFFIX-v2" + CACHE_SUFFIX="$SUFFIX-v3" CACHE_URL="$CACHE_URL/$CACHE_SUFFIX" echo "build:windows-ci --remote_http_cache=https://bazel-cache.da-ext.net/$CACHE_SUFFIX" >> .bazelrc.local fi diff --git a/compatibility/build-release-artifacts-windows.ps1 b/compatibility/build-release-artifacts-windows.ps1 index ed0facae8fce..b3045c9fa1d0 100644 --- a/compatibility/build-release-artifacts-windows.ps1 +++ b/compatibility/build-release-artifacts-windows.ps1 @@ -37,6 +37,7 @@ function bazel() { bazel shutdown +bazel clean --expunge bazel fetch @nodejs_dev_env//... bazel build ` `-`-experimental_execution_log_file ${ARTIFACT_DIRS}/build_execution_windows.log ` diff --git a/compatibility/test-windows.ps1 b/compatibility/test-windows.ps1 index e7b274d6a038..adcaca6ce6d3 100644 --- a/compatibility/test-windows.ps1 +++ b/compatibility/test-windows.ps1 @@ -45,6 +45,7 @@ cd compatibility cp ../.bazelrc .bazelrc bazel shutdown +bazel clean --expunge bazel fetch @nodejs_dev_env//... bazel build //... bazel shutdown