test: close the deferred test-hardening items (F7-07, F7-09, F1-08) - #95
Merged
Merged
Conversation
Final tail PR — test/test-infra only, no runtime behavior change. - F7-07: the loop-mode NOTIFY-wakeup tests used min=max=5.0 with a 2s budget (2.5x margin — load/jitter could let a poll deliver). Bumped to 30.0 (15x margin, still under the 60s lease_ttl so no factory warning), so the poll path provably can't meet the 2s budget: a broken NOTIFY now fails the test instead of flaking it. - F7-09: tightened loose telemetry assertions. OTel middleware uses exact counts (== 1, not >= 1 / any()); the OTel acked-histogram test now also asserts messaging.outbox.status == "acked". Prometheus middleware tests SUM matching samples instead of max(...), so a duplicate-series/double-emit regression pushes past 1.0 and fails. - F1-08: extract _claim_fake_row, shared by FakeOutboxClient.fetch and _sync_dispatch, so the lease + deliveries_count increment (the max_deliveries boundary) runs on one path. Eligibility gating (next_attempt_at <= now) stays in fetch only — sync mode deliberately fires future-dated rows immediately, so routing it through fetch verbatim would have broken that; sharing just the claim mechanics preserves it. just test -> 516 passed, 100% coverage; just lint clean. Findings doc: pass-3 fully closed. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
lesnik512
added a commit
that referenced
this pull request
Sep 5, 2026
…e/ (#159) The spec for a change is now its PR body. .github/PULL_REQUEST_TEMPLATE.md carries the shape and is reviewed with the diff, so there is no change file and no lane to pick. Two things outlive the PR, one home each: a rejected alternative becomes an ADR under docs/adr/, and unscheduled work becomes a GitHub issue. architecture/ was 12 capability pages restating what faststream_outbox/ already says. Its invariants were already executable: 32 existing tests now carry an INVARIANT: docstring -- the claim on line 1, what breaks it in the second paragraph -- and only one test is genuinely new. Engine ownership was asserted in CLAUDE.md and pinned by nothing, so a broker that disposed the caller's engine would have passed the whole suite. tests/test_invariant_census.py enforces the docstring shape. planning/ carried forward only its decision records, cut in review from five to two: the metrics-recorder record and free-threading (a merge of two). The doc-code-fence record declined a CI feature never built; the conn-union record's contract already lives in AbstractOutboxClient's docstring. The BrokerUsecase-invariance rationale from planning/lint-suppressions.md is now a one-line comment at each suppression site. The audits were all closed (PRs #61-#95). The open deferred item is #158; the SQLAlchemy cyext workaround is #160. CONTEXT.md is written: 16 terms, each listed only because there is a synonym to reject. CLAUDE.md is compressed against its own admission check. Curated release notes go with the planning tree -- release.yml falls back to GitHub's generated notes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Final tail PR (6 of 6) — test / test-infra only, no runtime behavior change. Closes the three items deferred from #91.
min=max=5.0with a 2s budget (only ~2.5× margin, so load/jitter could let a poll deliver and the test pass even with NOTIFY broken). Bumped the poll interval to30.0(15× margin, still under the 60slease_ttlso no factory warning) — the poll path provably can't meet the 2s budget, so a broken_notify_eventwakeup now fails the test instead of flaking it.== 1, not>= 1/any()); the OTel acked-histogram test now also assertsmessaging.outbox.status == "acked".max(...), so a duplicate-series / double-emit regression pushes the total past1.0and fails (themaxfold hid it)._claim_fake_row, shared byFakeOutboxClient.fetchand_sync_dispatch, so the lease +deliveries_countincrement (themax_deliveriesboundary) runs on one path. Note: routing_sync_dispatchthroughfetchverbatim (as the finding's headline suggested) would gate onnext_attempt_atand break sync-mode's documented "future-dated rows fire immediately" — so I shared only the claim mechanics; eligibility gating stays infetch.Verification
just test→ 516 passed, 100% coveragejust lintclean (ruff + ty)Pass-3 audit: fully closed
With this, every confirmed finding from the 2026-06-14 pass-3 deep audit is resolved, documented, or consciously dropped across PRs #85–#95. The Tail disposition ledger in
planning/audits/2026-06-14-deep-audit-pass3-findings.mdis the authoritative record.🤖 Generated with Claude Code