Repository navigation
fix(checks): exempt a package-root testing-conventions.toml from changelog-gate - #990
Merged
Merged
Conversation
A gate config at a package root is CI configuration, not source: it reaches no user through the maturin wheel or the npm tarball, so no changelog entry can ever follow from editing one. Today changelog-gate counts it as source and demands a fragment, making `skip-changelog:` a standing requirement for a file class that is never changelog-worthy. Red across all three tiers: the colocated predicate test, the integration gate run over a real repo, and the e2e CLI spawn. The companion assertion that a nested or differently-named config still counts as source passes already and must keep passing. Refs #974
…gate The gate now treats a package's own testing-conventions.toml the way it already treats changelog.d/ and e2e-attestations/: CI machinery rather than source. Package root only, so a config nested deeper still counts. The clause is root-agnostic like every other one, so a plugin's config is exempt on the same reasoning. The repo-tooling configs outside packages/ and plugins/ are unaffected -- the gate never scoped them. Fixes #974
thekevinscott
enabled auto-merge
August 20, 2026 20:17
The test comment restated the test name, and the docstring entry had grown an artifact-layout aside the rest of the clause list does without.
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.
Fixes #974
What
changelog_gate/decide.py::_is_exempttreats every non-test file under a package as source, so editingpackages/python/testing-conventions.tomlorpackages/ts/testing-conventions.toml(narrowing an[e2e]scope, nudging a coverage floor) reds the gate unless the author remembers askip-changelog:line — #971 needed exactly that on both commits.Gate config fails the maintainer's ship-in-the-artifact test from #932: the maturin wheel carries only the
dirsqlpackage andpackages/ts/.npmignorekeeps the tarball to built output, so a package-roottesting-conventions.tomlreaches no user and no user-facing change can ever follow from editing one. That puts it withchangelog.d/ande2e-attestations/, both already exempt.One clause in
_is_exempt, plus the docstring sentence that explains it.Deviations from the issue's sketch
Two, both deliberate:
rf"packages/{p}/testing-conventions\.toml", butpkgis already root-qualified (packages/python), so that pattern would only ever matchpackages/packages/python/…. The clause isrf"{p}/testing-conventions\.toml".plugins/dirsql-plugin-embeddings/testing-conventions.tomlis exempt too. Every other clause in_is_exemptis root-agnostic, and the rationale carries: the plugin's config is CI configuration a user never executes. The issue's open question about the sibling repo-tooling configs (internals/checks/testing-conventions.toml, the root one) is untouched — they sit outsidepackages//plugins/, so the gate never sees them.Package-root only, as specified:
packages/python/dirsql/testing-conventions.tomlandpackages/ts/my-testing-conventions.tomlstill count as source, asserted in the same test sounit mutationhas both directions to kill against (it tested 1 mutant on the new line and killed it).Red/green
Red pushed first (4a80067) and observed red in CI for the right reason — unit coverage failed on
false_for_the_package_root_gate_config(assert not True where True = code_touched(['packages/python/testing-conventions.toml'], 'packages/python'), 1 failed / 329 passed) and the integration job onit_passes_when_only_the_package_gate_config_changes(assert 1 == 0, printing the very "no changelog fragment was added" error this issue is about). The e2e-verify red on that commit was the expected stale attestation; refreshed in the last commit. Implementation is 20aaabf.Manual verification
Real
dirsql-checksCLI against a scratch git repo, both directions:E2E Verification
packages/python/e2e-attestation.jsonrefreshed ifpackages/pythonchanged — N/A, package untouchedpackages/ts/e2e-attestation.jsonrefreshed ifpackages/tschanged — N/A, package untoucheduv run --project internals/checks dirsql-checks preflight --conventions .github/workflows/internals-checks-ci.yml(0 failing pairs, 0 skipped — colocated-test, unit-lint, integration-lint, unit-coverage, mutation, e2e-verify, declared-deps);uv run python -m pytest src tests/integration tests/e2e -qininternals/checksinternals/checks/e2e-attestations/cc-nice-lovelace-7db4qt.json) is refreshed as the last commit, ce4aedf.No SDK package changes, so no SDK e2e suite is affected.
Changelog / Migrations
<root>/<pkg>/changelog.d/for each changed package — not required:internals/checkssits outsidepackages/andplugins/, the only roots the gate scopes.<root>/<pkg>/migrations.d/— not required: no public API change.PARITY.mduntouched — no SDK public API surface changes.