Skip to content

chore(release): enforce v* tag-ruleset drift check (flip TAG_RULESET_ENFORCED)#1129

Merged
joeharris76 merged 1 commit into
developfrom
chore/tag-ruleset-enforced-flag-flip
Jul 11, 2026
Merged

chore(release): enforce v* tag-ruleset drift check (flip TAG_RULESET_ENFORCED)#1129
joeharris76 merged 1 commit into
developfrom
chore/tag-ruleset-enforced-flag-flip

Conversation

@joeharris76

Copy link
Copy Markdown
Owner

Pull Request

Description

Flip TAG_RULESET_ENFORCED FalseTrue now that the v* tag-creation
ruleset is live. Admin applied v-tag-restricted (id 18774756) on
2026-07-10: active, conditions.ref_name.include=[refs/tags/v*], a
creation rule, and bypass_actors=[User:57046 (always)] — the
release-finalize identity only, confirmed not a broad Write/Admin role (so
make release-finalize's git push origin v$(VERSION) still succeeds).

The single constant in _project/scripts/ruleset_review_enforcement.py drives
both consumers: the standalone predicate main() and
scripts/ruleset_drift_check.py:tag_creation_findings(), which imports it as
the enforce_tag_rule default. Flipping it turns a missing/incomplete v*
tag ruleset from a non-blocking WARNING into a blocking finding in
release-canary.yml's ruleset-drift job — so a future regression (ruleset
deleted, made inactive, ref narrowed, creation rule dropped, or bypass
emptied) fails CI instead of merely warning.

This does not change enforcement of the tag ruleset itself (GitHub already
enforces it); it arms the drift detector to treat a regression as blocking.

Type of Change

  • Refactor / chore

Testing

  • pytest tests/unit/release/ tests/unit/test_ruleset_drift.py tests/unit/test_release_infrastructure.py — 104 passed.
  • Ran the runbook's live predicate against the actual rulesets with the
    flag flipped: Tag-creation ruleset - OK, exit 0 — confirms the canary
    stays green and enforcement only arms on a future regression.

Public Contract Check

  • I updated docs/reference/public-contracts.md, or this PR does not change
    public, beta-public, deprecated, generated, experimental, or repo-only
    contract surfaces. (No contract surface changed — internal release-tooling flag.)
  • I checked result schema fields, MCP tool parameters, platform support
    status, wrapper facades, adapter subclassing hooks, and generated docs for
    contract-map impact. (None affected.)
  • Any platform/benchmark count claim in docs is generated/checked from
    registry metadata, or explicitly marked editorial/non-authoritative. (N/A.)

Documentation

  • I updated the relevant user-facing docs. (Filled the runbook's tag
    live-state note in docs/operations/repo-admin-settings.md — the
    precondition the flag comment requires before flipping.)
  • I added regression notes for behavior changes. (Runbook note + commit body.)
  • I confirmed API contract wording remains accurate.

Code Quality

  • I ran formatting and lint/type checks. (pre-commit ran on commit.)
  • I reviewed impacted modules for backwards compatibility and migration impact.

Notes for reviewer

🤖 Generated with Claude Code

…ENFORCED)

The v* tag-creation ruleset was applied by admin on 2026-07-10 (id 18774756
`v-tag-restricted`; active, include refs/tags/v*, creation rule, bypass
User:57046 only — the release-finalize identity, confirmed not a broad role).
With the ruleset live and its bypass list confirmed, flip TAG_RULESET_ENFORCED
False->True so a future regression (ruleset deleted/inactive/ref-narrowed/
creation-rule-dropped/bypass-emptied) becomes a BLOCKING drift finding in
release-canary.yml's ruleset-drift job instead of a non-blocking warning.

The single constant drives both layers: ruleset_review_enforcement.main() and
ruleset_drift_check.tag_creation_findings() (which imports it as the
enforce_tag_rule default). Verified against the live rulesets: the predicate
still returns OK / exit 0, so the canary stays green; enforcement only arms on
a future regression.

- Fill the runbook's tag live-state note with the applied ruleset id/conditions
  (the precondition the flag comment requires before flipping).
- Update the three tests that pinned the WARN-until-applied default to the
  enforced default, preserving warn-mode coverage via explicit
  enforce_tag_rule=False / monkeypatched overrides.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@joeharris76
joeharris76 enabled auto-merge (squash) July 10, 2026 23:47
@joeharris76
joeharris76 merged commit 6f09cf8 into develop Jul 11, 2026
22 checks passed
@joeharris76
joeharris76 deleted the chore/tag-ruleset-enforced-flag-flip branch July 11, 2026 00:06
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