Skip to content

test_gate_controls: a count below MAX_UNPROVEN warns instead of failing (main red, #8995) - #8997

Merged
squid-shepherd[bot] merged 1 commit into
mainfrom
churn/8995-20261122T0652Z
Nov 22, 2026
Merged

squid-shepherd[bot] merged 1 commit into
mainfrom
churn/8995-20261122T0652Z

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

What

Main's GitGalaxy Smoke Tests went red at 085bb1c67 on one test: test_gate_controls.py::test_the_unproven_count_only_goes_down ("7 unproven now, so lower MAX_UNPROVEN to 7"; the committed limit was 10). Sibling "Gate controls" PRs each lowered the limit against their own base and left it above the real count once merged. HEAD already agrees (4 == 4), so the red had healed, but the same race recurs on the next pair of control PRs.

The ceiling (n <= MAX_UNPROVEN) stays a hard failure. The "count is below the limit" half now emits a warning instead of failing main. A new test pins both directions.

Refs #8995

Class / sibling sweep

Class: an exact-equality ratchet on a committed constant that two concurrent PRs can each satisfy against their own base but not after merging. Siblings (time_ratchet, the *_audit baselines) use <= / --write-baseline flows and are not affected; no other "lower ... to" equality assertion exists in tests/.

Lessons for agents

A ratchet test that fails on "better than the limit" turns main red when two PRs lower the same constant concurrently. Fail only on the worse direction.

Facts checked

  • Failing run 44993937253: 1 failed, 6968 passed; the failure is the test above, not infrastructure.
  • At HEAD b7802adbf: len(gate_controls.unproven()) == MAX_UNPROVEN == 4.
  • pytest tests/tools/test_gate_controls.py from /tmp: 18 passed. ruff format --check clean; ruff_audit --ci: no new findings.

Decision for the reviewer

Softening the equality half lets the limit drift above the real count until the next control PR lowers it. Ratchet strength is unchanged (the count still cannot rise).

🤖 Generated with Claude Code

…ng (main red, #8995)

Concurrent control PRs each lowered the limit against their own base and
left it above the real count after merging; the equality half failed main.
The ceiling stays a hard failure.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@squid-protocol squid-protocol added the shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md label Nov 22, 2026
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

@squid-shepherd
squid-shepherd Bot marked this pull request as ready for review November 22, 2026 06:58
@squid-shepherd
squid-shepherd Bot enabled auto-merge (squash) November 22, 2026 07:01
@squid-shepherd
squid-shepherd Bot merged commit 5c2e96e into main Nov 22, 2026
57 checks passed
@squid-shepherd
squid-shepherd Bot deleted the churn/8995-20261122T0652Z branch November 22, 2026 07:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant