Allow overriding GITHUB_REF via BAZELCI_GITHUB_REF in bazel-testing #2878
All Vouch review confidence checks passed
Residual risk 0.14 = Change Risk (0.35) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.35 · 168 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.307
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #2878"
general
weight: 0.35
fweikert
Allow overriding the CI script branch/ref (
GITHUB_REF) via theBAZELCI_GITHUB_REFenvironment variable when running in thebazel-testingBuildkite organization (THIS_IS_TESTING == True).Motivation
Currently, pipelines in
bazel-testingshare a singletestingbranch inbazelbuild/continuous-integration(get_ci_script_ref()falls back to"testing"wheneverBUILDKITE_REPOis notbazelbuild/continuous-integration). When multiple engineers test CI changes concurrently, pushing totestingrisks overwriting in-flight experiments.Summary of Changes
buildkite/bazelci.py(get_ci_script_ref): Checkos.environ.get("BAZELCI_GITHUB_REF")whenTHIS_IS_TESTINGisTrue(matching existing testing override conventions likeBAZELCI_AGENT_REPOandBAZELCI_AGENT_VERSION). Production and trusted orgs (THIS_IS_TESTING == False) continue to unconditionally return"master".buildkite/culprit_finder.py: Usebazelci.GITHUB_REFwhen constructingSCRIPT_URLsoculprit_finder.pyalso respectsBAZELCI_GITHUB_REF(consistent withbcr_presubmit.pyandbcr_compatibility.py).buildkite/bazelci_test.py(GetCiScriptRefTest): Add unit tests verifying thatBAZELCI_GITHUB_REFoverrides the script ref inbazel-testingand is ignored whenTHIS_IS_TESTINGisFalse.