From 06ef472defcdf73d4ad07a72b8e6736ed60f5e2b Mon Sep 17 00:00:00 2001 From: Zhengchao An Date: Sun, 23 Aug 2026 20:20:01 +0800 Subject: [PATCH] fix(ci): make Warp ABBA evidence bounded and complete (#6417) --- .github/workflows/performance-ab.yml | 12 ++- scripts/hotpath_warp_ab_gate.sh | 85 +++++++++++----- scripts/run_hotpath_warp_abba.sh | 57 +++++------ scripts/run_object_batch_bench_enhanced.sh | 94 +++++++++++------- .../security/check_performance_ab_workflow.sh | 4 +- scripts/test_hotpath_warp_ab_gate.sh | 8 ++ scripts/test_hotpath_warp_abba.sh | 18 +++- scripts/test_object_batch_bench_enhanced.sh | 96 ++++++++++++++++++- 8 files changed, 274 insertions(+), 100 deletions(-) diff --git a/.github/workflows/performance-ab.yml b/.github/workflows/performance-ab.yml index de4986388..61a8eed41 100644 --- a/.github/workflows/performance-ab.yml +++ b/.github/workflows/performance-ab.yml @@ -121,14 +121,14 @@ jobs: candidate_sha="$(git rev-parse HEAD)" if [[ "${{ github.event_name }}" == "schedule" ]]; then baseline_sha="${SCHEDULED_BASELINE_SHA:-$candidate_sha}" - if ! git merge-base --is-ancestor "$baseline_sha" "$candidate_sha"; then - echo "::error::scheduled baseline $baseline_sha is not an ancestor of candidate $candidate_sha" >&2 - exit 1 - fi else baseline_sha="$(git rev-parse origin/main)" fi git cat-file -e "${baseline_sha}^{commit}" + if ! git merge-base --is-ancestor "$baseline_sha" "$candidate_sha"; then + echo "::error::baseline $baseline_sha is not an ancestor of candidate $candidate_sha; update the selected ref before comparing" >&2 + exit 1 + fi echo "baseline_sha=$baseline_sha" >> "$GITHUB_OUTPUT" echo "candidate_sha=$candidate_sha" >> "$GITHUB_OUTPUT" echo "baseline commit: $baseline_sha" @@ -342,6 +342,10 @@ jobs: if: always() run: | status="${{ steps.ab.outputs.status }}" + if [[ -z "$status" ]]; then + echo "::error::warp A/B setup failed before the rig ran. Check the first failed workflow step." >&2 + exit 1 + fi if [[ "$status" != "0" ]]; then echo "::error::warp A/B budget gate failed (exit $status). See the step summary / gate.md artifact." >&2 exit "$status" diff --git a/scripts/hotpath_warp_ab_gate.sh b/scripts/hotpath_warp_ab_gate.sh index d184661d6..ec2e839f9 100755 --- a/scripts/hotpath_warp_ab_gate.sh +++ b/scripts/hotpath_warp_ab_gate.sh @@ -30,12 +30,16 @@ REQUIRE_TAIL_ERROR="false" MARKDOWN_OUT="" EXEMPTION_REASON="deliberate correctness tradeoff" declare -a COMPARE_CSVS=() +declare -a COMPARE_LABELS=() usage() { cat <<'USAGE' Usage: hotpath_warp_ab_gate.sh --compare-csv [--compare-csv ...] [options] --compare-csv baseline_compare.csv to evaluate (repeatable). + --labeled-compare-csv