Skip to content

Commit 00d9e86

Browse files
committed
try to fix isolation
1 parent 426b2e0 commit 00d9e86

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

integration_test.sh

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -154,11 +154,13 @@ for group in "${!BUILD_TARGET_GROUPS[@]}"; do
154154

155155
db_path="${CODEQL_DATABASES_DIR}/${group}_db"
156156
sarif_output="${CODEQL_SARIF_DIR}/${group}.sarif"
157-
157+
current_bazel_output_base="/tmp/codeql_bazel_output_${group}_$(date +%s%N)" # Add timestamp for extra uniqueness
158+
159+
158160
# 1. Clean Bazel to ensure a fresh build for CodeQL tracing
159161
echo "Running 'bazel clean --expunge' and 'bazel shutdown'..."
160-
bazel clean --expunge || { echo "Bazel clean failed for ${group}"; exit 1; }
161-
bazel shutdown || { echo "Bazel shutdown failed for ${group}"; exit 1; }
162+
bazel clean --expunge --output_base="${current_bazel_output_base}" || { echo "Bazel clean failed for ${group}"; exit 1; }
163+
bazel shutdown --output_base="${current_bazel_output_base}" || { echo "Bazel shutdown failed for ${group}"; exit 1; }
162164

163165
# Log build group banner only to stdout/stderr (not into summary table file)
164166
echo "--- Building group: ${group} ---"
@@ -169,6 +171,7 @@ for group in "${!BUILD_TARGET_GROUPS[@]}"; do
169171
set +e
170172

171173
build_command="bazel build \
174+
--output_base=\\\"${current_bazel_output_base}\\\" \
172175
--config '${CONFIG}' \
173176
${targets} \
174177
--verbose_failures \

0 commit comments

Comments
 (0)