Skip to content

Commit 40d227a

Browse files
committed
fix: restore local governance guards
1 parent 6a3e5d5 commit 40d227a

2 files changed

Lines changed: 18 additions & 5 deletions

File tree

tests/unit/test_test_system_round2_audit.py

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -459,8 +459,16 @@ def test_local_fast_and_standard_prepush_align_with_ci_core_gates() -> None:
459459
'step fast-lane bash "$ROOT/gates/local_quality_gate.sh" fast',
460460
"pre-push strict fast lane",
461461
)
462-
assert "check_upstream_verification_freshness.py" not in local_quality_gate
463-
assert "check_upstream_receipts.py" not in local_quality_gate
462+
_assert_contains(
463+
local_quality_gate,
464+
"check_upstream_verification_freshness.py",
465+
"local upstream freshness guard",
466+
)
467+
_assert_contains(
468+
local_quality_gate,
469+
"check_upstream_receipts.py",
470+
"local upstream receipts guard",
471+
)
464472
_assert_contains(
465473
local_quality_gate,
466474
"check_gate_log_correlation.py",

tooling/gates/local_quality_gate.sh

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,10 @@ set -euo pipefail
1515
# - Runs targeted checks on changed files only
1616
# - Falls back to full check if detection fails
1717
#
18-
# Receipt-driven governance checks stay in tooling/gates/quality_gate.sh after
19-
# summary generation. Keeping them out of fast/prepush-lite preserves the
20-
# advertised local-burn envelope and avoids false reds on clean local clones.
18+
# Summary-dependent receipt synthesis still belongs to tooling/gates/quality_gate.sh.
19+
# The local lanes keep the cheaper closeout guards that validate upstream freshness,
20+
# upstream receipts, and gate-log correlation without forcing the full quality-gate
21+
# summary pipeline on every routine local run.
2122

2223
DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
2324
ROOT="$(dirname "$DIR")"
@@ -346,6 +347,8 @@ run_fast() {
346347
run_parallel_step upstream-drift "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_drift.py" --root "$REPO_ROOT"
347348
run_parallel_step upstream-registry "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_registry_completeness.py" --root "$REPO_ROOT"
348349
run_parallel_step upstream-compat "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_compat_matrix.py" --root "$REPO_ROOT"
350+
run_parallel_step upstream-freshness "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_verification_freshness.py" --root "$REPO_ROOT"
351+
run_parallel_step upstream-receipts "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_receipts.py" --root "$REPO_ROOT"
349352
run_parallel_step upstream-host-capabilities "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_host_capabilities.py" --root "$REPO_ROOT"
350353
run_parallel_step upstream-fetch "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_fetch_surfaces.py" --root "$REPO_ROOT"
351354
run_parallel_step private-upstream-coupling "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_no_private_upstream_coupling.py" --root "$REPO_ROOT"
@@ -472,6 +475,8 @@ run_prepush_lite() {
472475
run_parallel_step upstream-drift "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_drift.py" --root "$REPO_ROOT"
473476
run_parallel_step upstream-registry "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_registry_completeness.py" --root "$REPO_ROOT"
474477
run_parallel_step upstream-compat "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_compat_matrix.py" --root "$REPO_ROOT"
478+
run_parallel_step upstream-freshness "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_verification_freshness.py" --root "$REPO_ROOT"
479+
run_parallel_step upstream-receipts "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_receipts.py" --root "$REPO_ROOT"
475480
run_parallel_step upstream-host-capabilities "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_host_capabilities.py" --root "$REPO_ROOT"
476481
run_parallel_step upstream-fetch "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_upstream_fetch_surfaces.py" --root "$REPO_ROOT"
477482
run_parallel_step private-upstream-coupling "$VENV/bin/python" "$REPO_ROOT/tooling/scripts/check_no_private_upstream_coupling.py" --root "$REPO_ROOT"

0 commit comments

Comments
 (0)