Repository navigation
fix: Restore the patterns gate and reconcile its baselines with reality - #5065
Conversation
Two PRs, each green on its own, were red once both had landed. #5056 added `logging.getLogger` to `sources/retained_acquisition.py` for the ZIP member-skip warning; #5059 recorded the `legacy-stdlib-logger` baseline at 23 entries. Neither PR's CI saw the other's change, so master ended up scanning 24 matches against a 23-entry baseline and `gate patterns` began blocking every PR opened afterwards, including ones touching neither file. Convert that site to `source.zip.members_refused`. No new allowlist field is needed: `path` and `skipped` are registered, and the refused-member list rides in `error_detail`, the one existing quarantined field. Also prune 22 stale baseline entries whose sites no longer exist, several of them naming the long-deleted `storage/repair.py`. Pruning shrinks the ratchet, which is the permitted direction; silencing the gate by adding an entry is the forbidden one. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01DYUNBGoE652b3nfmq3CtqK
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Warning Review limit reachedNext included review available in 1 minute. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (4)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01DYUNBGoE652b3nfmq3CtqK
Summary
devtools gate patternsis red on master, blocking every PR opened since, including ones that touch neither implicated file. This restores it and makes the baselines honest.Problem
Two PRs, each green on its own, red once both had landed:
logger = logging.getLogger(__name__)topolylogue/sources/retained_acquisition.pyfor the ZIP-member-skip warning.legacy-stdlib-loggerratchet baseline at 23 entries.Neither PR's CI ever saw the other's change. After both merged, master scanned 24 matches against a 23-entry baseline, so the gate reported a new match and set
blocking: true. PRs #5061, #5062, #5063 and #5064 all failed for this inherited reason.Separately, the baselines carried 22 stale entries whose sites no longer exist — several naming
polylogue/storage/repair.py, a file deleted some time ago.Solution
Convert the one blocking site to a structured event,
source.zip.members_refused. No new allowlist field was needed:pathandskippedare already registered, and the refused-member list rides inerror_detail, the single existing quarantined field.Prune the 22 stale entries. Pruning shrinks the ratchet, which is the permitted direction; adding an entry to silence the gate is the forbidden one.
Verification
Baselines now match the scan exactly in both directions. Before this change the same command reported 1 new match and 22 stale entries. No test asserts on the old warning text, so no test changes were required.
Note for the ratchet's owner — not addressed here
A structural gap surfaced while fixing this.
legacy-stdlib-loggermatcheslogging.getLogger(...), but the form most of the tree actually uses is thepolylogue.logging.get_loggerwrapper, which the rule does not match. A concurrent conversion of 90 prose sites acrossdaemon/cli.pyanddaemon/http.pytherefore eliminated zero baseline entries — the gate meant to enforce "no legacy logging" is blind to the dominant legacy form.Widening the existing rule would grow its baseline by roughly 140 modules, which the ratchet forbids. The coherent route is a second rule with its own baseline at the true remaining count: a new ratchet may start wherever reality is, while an existing one may only shrink. That is a deliberate decision and belongs in its own change.
🤖 Generated with Claude Code
https://claude.ai/code/session_01DYUNBGoE652b3nfmq3CtqK