Skip to content

chore(gates,docs): align ruff hook with CI and remove the broken AWS hook - #28

Open
Yosoyepa wants to merge 1 commit into
mainfrom
codex/chore-gate-and-log-hygiene
Open

chore(gates,docs): align ruff hook with CI and remove the broken AWS hook#28
Yosoyepa wants to merge 1 commit into
mainfrom
codex/chore-gate-and-log-hygiene

Conversation

@Yosoyepa

@Yosoyepa Yosoyepa commented Aug 6, 2026

Copy link
Copy Markdown
Owner

Two audit-visible inconsistencies found while scoping phase 12. No source, test, eval case or public contract changed.

1. The local gate was weaker than CI, and one hook could only fail

.pre-commit-config.yaml pinned ruff-pre-commit at v0.11.0 while pyproject.toml requires ruff>=0.16.1 (locked at 0.16.1). Both read the same phase-10 select list, but 0.11.0 did not implement 30 of the rules those families now cover — 13 of them stable rather than preview-gated (B912, ISC004, PLR1708, UP050, RUF060/061/063/064/068/076, RUF102/103/104).

Verified by probe rather than by reading changelogs: a value in [] body passes the old hook and trips RUF060 under the new one. Moved to the canonical ruff-check id, since the bare ruff id is now published as a legacy alias.

detect-aws-credentials is removed outright. The project has no AWS surface — no SDK dependency, no deployment target, no credential to leak — so the hook could only ever fire on a false positive. With no credentials file present it exited nonzero on their absence rather than on a finding, failing the whole pre-commit run --all-files gate for a non-finding. This retires the R-04 risk phase 09 accepted.

Repository secret scanning stays with gitleaks in the required security job, which covers AKIA/ASIA key ids among every other pattern — so this drops a broken check, not a layer of protection. maintainer-workflow.md no longer claims the hook exists.

2. Stale phase logs

Logs 05, 07 and 08 still carried PULL REQUEST OPEN / IN_PROGRESS headers with <pendiente> PR and merge fields although their PRs are merged; 07 also left wave-1 slots at PENDING, and 09 left A4/A5 IN_PROGRESS with an unrecorded rollback rehearsal.

Every PR number, merge SHA and slot commit recorded here was read back from git history, not inferred. Phase 06's Release becomes UNRELEASED rather than a tag it does not belong to, and phase 05's prerelease is left explicitly unclaimed because it could not be verified from this checkout. The phase-09 evidence table keeps its original PARCIAL record: it describes what that run actually saw.

Gates

uv lock --check (76 packages, no change) · ruff check . · mypy src (118 files) · pytest against PostgreSQL 16 — 853 passed, 3 allowlisted skips, 58 subtests · coverage 92% (threshold 85) · L1 eval suite 299/299 · compileall · uv build · pip-audit · pre-commit run --all-files 4/4 all green · git diff --check.

diff-cover reports no coverage-bearing lines in the diff, as expected for a config-and-docs change.

🤖 Generated with Claude Code

Two audit-visible inconsistencies found while scoping phase 12.

1. `.pre-commit-config.yaml` pinned `ruff-pre-commit` at `v0.11.0` while
   `pyproject.toml` requires `ruff>=0.16.1` (locked at 0.16.1). Both read the
   same phase-10 `select` list, but 0.11.0 did not implement 30 of the rules
   those families now cover, 13 of them stable rather than preview-gated. The
   local gate was therefore strictly weaker than `uv run ruff check .` in CI.
   Verified by probe: a `value in []` body passes the old hook and trips RUF060
   under the new one. Also moved to the canonical `ruff-check` id, since the
   bare `ruff` id is now published as a legacy alias.

   `detect-aws-credentials` is removed outright. The project has no AWS surface
   -- no SDK dependency, no deployment target, no credential to leak -- so the
   hook could only ever fire on a false positive, and with no credentials file
   present it exited nonzero on their absence rather than on a finding, failing
   the whole `pre-commit run --all-files` gate for a non-finding. This retires
   the R-04 risk phase 09 accepted. Repository secret scanning stays with
   gitleaks in the required `security` job, which covers `AKIA`/`ASIA` key ids
   among every other pattern, so this drops a broken check rather than a layer
   of protection. `maintainer-workflow.md` no longer claims the hook exists.

2. Phase logs 05, 07 and 08 still carried `PULL REQUEST OPEN` / `IN_PROGRESS`
   headers with `<pendiente>` PR and merge fields although their PRs are
   merged; phase 07 also left wave-1 slots at `PENDING` and phase 09 left A4/A5
   `IN_PROGRESS` with an unrecorded rollback rehearsal. Every PR number, merge
   SHA and slot commit recorded here was read back from git history, not
   inferred. Phase 06's `Release` becomes `UNRELEASED` rather than a tag it does
   not belong to, and phase 05's prerelease is explicitly left unclaimed
   because it could not be verified from this checkout. The phase-09 evidence
   table keeps its original `PARCIAL` record: it describes what that run saw.

No source, test, eval case or public contract changed.

Gates: uv lock --check, ruff check, mypy (118 files), compileall, uv build,
pytest against PostgreSQL 16.14 (853 passed, 3 allowlisted skips, 58 subtests),
coverage 92% (threshold 85), L1 eval suite 299/299, pip-audit, pre-commit
(4/4, all green), git diff --check. diff-cover reports no coverage-bearing
lines in the diff, as expected for a config-and-docs change.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@Yosoyepa Yosoyepa closed this Aug 6, 2026
@Yosoyepa Yosoyepa reopened this Aug 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant