Skip to content

feat(qa): wire CHANGELOG gate into §7 verdict algorithm so it actually blocks READY_FOR_MERGE #585

Closed

Description

@admarble

Summary

`/qa` SKILL.md §10a says "Do NOT give READY_FOR_MERGE if CHANGELOG entry missing for user-facing changes" — but §7's verdict-determination algorithm does not include this branch. So the rule is documented in prose and silently ignored when `READY_FOR_MERGE` is otherwise eligible.

Evidence

During `/fullsolve 575` (PR #579), my round-1 /qa marked CHANGELOG verification as N/A on a `fix:` commit affecting `templates/scripts/cleanup-worktree.sh` (a user-facing template script). The verdict was `READY_FOR_MERGE`. The CHANGELOG was empty for #575 until the user surfaced the gap with "any gaps?" — at which point I added the entry on round 2.

The /qa skill's CHANGELOG validation already implements:

  • File detection (`if [ ! -f "CHANGELOG.md" ]; then skip`)
  • User-facing change detection (conventional-commit prefixes `feat:|fix:|perf:|refactor:|docs:`)
  • The rule itself: "Do NOT give READY_FOR_MERGE"

It just isn't wired into the verdict algorithm in §7.

Proposed change

In `templates/skills/qa/SKILL.md` §7 "Determine verdict (in order)", add a new branch alongside existing gates:

```diff

  • ELSE IF execution_evidence == "Incomplete":
    → AC_MET_BUT_NOT_A_PLUS (scripts not verified - cannot be READY_FOR_MERGE)
    • ELSE IF changelog_required AND changelog_missing:
  •  → AC_MET_BUT_NOT_A_PLUS (CHANGELOG entry required for user-facing changes)
    
    • ELSE IF quality_plan_status == "Not Addressed" AND quality_plan_exists:
      → AC_MET_BUT_NOT_A_PLUS (quality dimensions not addressed - flag for review)
      ```

Where `changelog_required` reuses §10a's existing detection (`CHANGELOG.md` exists AND user-facing commit prefix in `git log main..HEAD`) and `changelog_missing` reuses §10a's `[Unreleased]` entry check.

Mirror across all three skill directories: `.claude/skills/qa/SKILL.md`, `skills/qa/SKILL.md`, `templates/skills/qa/SKILL.md`.

Acceptance Criteria

  • AC-1: §7 verdict algorithm includes a `changelog_missing` branch that demotes `READY_FOR_MERGE` to `AC_MET_BUT_NOT_A_PLUS` when `CHANGELOG.md` exists, the feature branch has user-facing commits, and the `[Unreleased]` section lacks an entry for the issue/PR.
  • AC-2: The branch is no-op when `CHANGELOG.md` doesn't exist (graceful degradation for projects without one). Verify by running /qa on a synthetic repo lacking CHANGELOG.md.
  • AC-3: The branch is no-op when no user-facing commit prefix is detected (e.g., `chore:`/`test:`/`ci:` only). Verify by running /qa on a non-user-facing diff.
  • AC-4: Change is mirrored across all three `qa/SKILL.md` files.
  • AC-5: Regression check — existing /qa runs against a recent merged PR with a proper CHANGELOG entry still verdict `READY_FOR_MERGE`.

Notes

  • Caveat to document in SKILL prose: detection requires conventional-commit prefixes. Projects without conventional commits silently skip the gate (failsafe to "off"). Acceptable for sequant's typical user base.
  • This is a "rule already exists, wire it into the algorithm" change. Low risk; high value for repos with active CHANGELOGs.
  • Origin: dogfooded during `/fullsolve 575` round-1 vs round-2 /qa diff.

Activity

  1. added
    enhancement
    cli
    on May 6, 2026
  2. admarble commented on May 8, 2026

    @admarble
    ContributorAuthor

    Plan for #585 — Wire CHANGELOG gate into §7 verdict algorithm

    Acceptance Criteria

    Implementation Plan

    1. Insert new §7 branch in templates/skills/qa/SKILL.md, .claude/skills/qa/SKILL.md, skills/qa/SKILL.md between execution_evidence == "Incomplete" and quality_plan_status == "Not Addressed":
      - ELSE IF changelog_required AND changelog_missing:
          → AC_MET_BUT_NOT_A_PLUS (CHANGELOG entry required for user-facing changes)
      
    2. Add prose caveat near §10a: detection requires conventional-commit prefixes; projects without them silently skip (failsafe-off).
    3. Verify mirroring via diff — expect zero output.
    4. Trace each AC scenario through §7 once.
    5. Add [Unreleased] CHANGELOG entry for feat(qa): wire CHANGELOG gate into §7 verdict algorithm so it actually blocks READY_FOR_MERGE #585 (dogfoods the new gate).

    Key Decisions

    • Reuses §10a's existing changelog_required/changelog_missing rather than duplicating logic in §7. Mirrors §11 (execution_evidence) and §3a (browser_test_missing) patterns.
    • Branch ordering: AFTER hard-blocker causes, BEFORE soft "notes" gates — fires deterministically when CHANGELOG is the actual cause.
    • No settings flag — file-presence detection is the natural opt-out.

    Open Questions

    1. §7 note string verbosity — keep terse, let §10a render remediation. Recommendation: yes.
    2. Per-project disable flag — no; file-presence sufficient.

    Sibling-Site Scan

    Negative. Two other "Do NOT give READY_FOR_MERGE" rules (CI gating line ~804, Script/CLI verification line ~2393) are already wired into §7 via pending_count and execution_evidence. CHANGELOG was the only orphan.

    Recommended Workflow

    spec → exec → qa, quality loop disabled. testgen and /test N/A for a markdown-prose change.

  3. added
    planned
    on May 8, 2026
  4. admarble commented on May 8, 2026

    @admarble
    ContributorAuthor

    /exec Progress Update — #585

    AC Coverage Summary

    AC Description Status Evidence
    AC-1 §7 verdict algorithm includes changelog_missing branch ✅ Implemented templates/skills/qa/SKILL.md:2086-2087 — new ELSE IF changelog_required AND changelog_missing between execution_evidence == "Incomplete" and quality_plan_status == "Not Addressed"
    AC-2 No-op when CHANGELOG.md absent ✅ Implemented :2056 — changelog_required = true IFF CHANGELOG.md exists AND ...; absent file → branch skips
    AC-3 No-op when no user-facing commit prefix ✅ Implemented :2056 — changelog_required requires `feat:
    AC-4 Mirrored across all three qa/SKILL.md files ✅ Implemented diff zero output across templates//.claude//skills/ pairs; check-skill-sync.ts reports synced 3/3 for qa/SKILL.md
    AC-5 Regression — proper [Unreleased] entry still verdicts READY_FOR_MERGE ✅ Implemented (traced) When changelog_required && !changelog_missing, the AND short-circuits, branch falls through

    Files Changed

    Build / Lint / Test Results

    Check Status Notes
    npm run build ✅ Passed tsc — exit 0
    npm run lint ✅ Passed eslint --max-warnings 0 — exit 0
    npx vitest run (targeted) ✅ Passed 95/95 across qa/markdown-only-ci, merge-check/, assess-collision-detect
    check-skill-sync.ts ✅ Passed qa/SKILL.md listed under synced (22 total); changes did not introduce divergence
    lint:skill-calls ✅ Passed No unqualified Skill() collisions

    Test Coverage Analysis

    Changed File Tier Has Tests?
    templates/skills/qa/SKILL.md Critical (skill prose) ⚠️ No direct unit test; verified via 4 SKILL.md-fixture tests (all green)
    .claude/skills/qa/SKILL.md Mirror ⚠️ Same as above
    skills/qa/SKILL.md Mirror ⚠️ Same as above
    CHANGELOG.md Optional - (docs only)

    This is a markdown-prose verdict-algorithm wiring change. AC-1–AC-5 are all "Manual" verification per the spec plan — runtime behavior is determined by /qa reading SKILL.md prose. Manual verdict trace done above.

    Quality Plan Alignment

    N/A — spec plan for #585 did not include a Feature Quality Planning section (markdown-prose-only change, quality-loop disabled).

    CLI Wiring Check

    N/A — no RunOptions/bin/cli.ts changes.

    Pre-PR Confidence Check

    • Weakest part: §7 algorithm ordering — placed the new branch between execution_evidence == "Incomplete" and quality_plan_status == "Not Addressed" per the spec plan, deliberately AFTER hard-blocker causes (skill_verification, execution_evidence) and BEFORE the soft "notes" gates (quality_plan, browser_test_missing, smoke_test). This matches the §10a "Do NOT give READY_FOR_MERGE" intent — same severity as execution_evidence == "Incomplete".
    • Coverage gaps: No direct unit test for §7 prose. Acceptable because (a) §7 is prose interpreted by Claude reading SKILL.md, not parsed code, and (b) the fixture-based tests in markdown-only-ci.test.ts / merge-check.test.ts exercise the surrounding pipeline. The conventional-commit-dependency caveat is documented in §10a prose for projects opting out.

    PR Status

    ✅ PR #601 created — #601

    Documentation Reminder

    /qa SKILL.md is itself the documentation for §7. CHANGELOG entry already added. No README/docs/ updates needed (already verified by /qa skill's docs check.)

    Next Steps

    1. Run /qa 585 to verify the gate-wiring verdict algorithm against the spec.
    2. Post-merge sanity: dry-run /qa against feat(spec): ac-linter — detect title/body verification-method tension #571/feat(run): -q mode silent for entire phase duration — no liveness or stall signal #574/feat(spec): mirror /qa sibling-site scan prompt into /spec planning checklist #580 (recent merged PRs with proper [Unreleased] entries) to confirm AC-5 regression case still produces READY_FOR_MERGE.
  5. admarble commented on May 8, 2026

    @admarble
    ContributorAuthor

    QA Review for Issue #585 (Simple Fix)

    Size Gate

    Check Value
    Diff size 25 lines (threshold: 100)
    package.json changed No
    Security-sensitive paths No
    Decision Inline checks

    AC Coverage

    AC Description Status Notes
    AC-1 §7 algorithm includes changelog_missing branch demoting READY_FOR_MERGE to AC_MET_BUT_NOT_A_PLUS MET Branch present at line 2086–2087; changelog_required and changelog_missing defined at lines 2056–2057. Position matches issue's proposed diff exactly (between execution_evidence == "Incomplete" and quality_plan_status == "Not Addressed").
    AC-2 No-op when CHANGELOG.md is absent MET changelog_required predicates on CHANGELOG.md existence; when absent, condition is false → branch not taken. §10a's existing detection (line 2318–2321) returns early when file missing.
    AC-3 No-op when no user-facing commit prefix detected MET changelog_required requires user-facing prefix; without it, branch is no-op. Caveat documented at §10a (line 2312).
    AC-4 Mirrored across all three qa/SKILL.md files MET diff confirms .claude/skills/qa/SKILL.md, skills/qa/SKILL.md, and templates/skills/qa/SKILL.md are byte-identical.
    AC-5 Regression — proper CHANGELOG entry still verdict READY_FOR_MERGE MET Branch is purely additive (AND changelog_missing); when entry exists, changelog_missing=false, flow continues to lower-priority gates.

    Coverage: 5/5 AC items fully met


    Quality Metrics

    Metric Value Status
    Type issues (any) 0 OK (no TS/JS files changed)
    Deleted tests 0 OK
    Files changed 4 OK
    Lines added +25 -
    Lines deleted -0 -
    Security patterns 0 OK

    Code Review

    Strengths:

    • Branch placement matches issue's proposed diff exactly — clean wiring with no scope creep.
    • Three SKILL.md copies stay byte-identical (verified via diff).
    • Reuses §10a's existing CHANGELOG.md/[Unreleased] checks rather than duplicating logic.
    • New **Wired into §7** and **Caveat** paragraphs at §10a make the cross-reference legible from both directions.
    • Self-dogfood: this PR's own commit follows the convention and adds a corresponding [Unreleased] entry.

    Issues:

    • §10a detection regex silently misses scoped conventional commits (pre-existing, not a regression). The §10a user_facing detection is ^[a-f0-9]+ (feat\|fix\|perf\|refactor\|docs): (line 2328), which matches only unscoped form. Quick audit on this repo: 26/30 recent commits use scoped form (feat(#NNN):), 0/30 use unscoped — i.e. the gate never fires on sequant's own commits, including this PR's own feat(#585): commit. The new §7 wiring is correct; the upstream detection is the gap. AC-3 says "no-op when no user-facing prefix detected" so this technically passes, but the gate effectively cannot trigger on sequant dogfood — undermining the very /fullsolve 575 round-1 motivation cited in the issue body.
    • Caveat text overstates the gap. §10a's caveat says "Projects without conventional commits silently skip this gate," which suggests sequant (a conventional-commit project) is covered. In reality, scoped conventional-commits also silently skip. Worth either tightening the caveat wording or filing a follow-up to broaden the regex to (feat\|fix\|perf\|refactor\|docs)(\([^)]*\))?!?:.

    Suggestions:

    • File a follow-up issue: "Broaden §10a user_facing regex to match scoped conventional-commits (feat(#NNN):, fix(area)!:)" — required for the gate to actually fire on sequant's own commits.

    Test Coverage Analysis

    N/A — prompt-only change; skill markdown is interpreted by an LLM at runtime, no executable code paths to unit-test.


    Anti-Pattern Detection

    No code patterns to scan (markdown-only diff).


    Risk Assessment

    • Likely failure mode: Gate silently no-ops on scoped-conventional-commit repos (sequant included). Wiring correct; upstream detection regex is the bottleneck. No correctness risk — the gate fails open, identical to current behavior, just doesn't deliver new enforcement on sequant's own commits.
    • Not tested: No unit coverage (skill prompt content). Dogfood verification would require either a follow-up regex fix or a test repo with unscoped feat: commits.
    • Sibling sites considered: None — single insertion into §7's verdict ladder, mirrored across the three skill copies (already addressed by AC-4).
    • Sibling-line audit: None — single-call-site fix. Adjacent branches (execution_evidence, quality_plan_status) follow the same ELSE IF X: → AC_MET_BUT_NOT_A_PLUS shape. No intra-file siblings with the same root cause.

    CI Status

    Check State Conclusion
    build (20.x) COMPLETED SUCCESS
    build (22.x) COMPLETED SUCCESS
    typecheck COMPLETED SUCCESS
    validate-skills COMPLETED SUCCESS
    validate-plugin COMPLETED SUCCESS
    Plugin Structure Validation COMPLETED SUCCESS
    Hooks Validation COMPLETED SUCCESS
    Setup Directory Creation COMPLETED SUCCESS

    CI Summary: 8 passed, 0 pending, 0 failed.


    CHANGELOG Verification

    Check Status
    CHANGELOG.md exists ✅ Found
    User-facing changes ✅ Yes (feat(#585): commit)
    [Unreleased] entry ✅ Present under ### Added
    Entry format ✅ Includes (#585); action verb "wires"

    Result: CHANGELOG requirements met for this PR's own commit (regardless of whether §10a's regex would auto-detect it).


    Verdict: AC_MET_BUT_NOT_A_PLUS

    All 5 ACs are literally met and the wiring is correct. CI is green. The PR delivers exactly what the issue's proposed diff specified.

    The non-blocking concern is that §10a's existing detection regex (referenced by the new branch) silently misses sequant's own scoped conventional-commit format — so although the gate is now wired into the verdict algorithm, it effectively cannot fire on sequant's own commits including this very PR. The AC text accepts no-op behavior on undetected prefixes (AC-3), so this is a recommendation, not an unmet AC.

    Documentation

    • CHANGELOG entry added under [Unreleased] / Added with issue ref (#585)
    • §10a SKILL prose updated with wiring cross-reference and caveat
    • N/A — no README/docs changes needed

    Next Steps

    1. Merge as-is — the wiring is correct and uncontroversial; ship it.
    2. File follow-up issue — broaden §10a's user_facing regex from (feat\|fix\|perf\|refactor\|docs): to (feat\|fix\|perf\|refactor\|docs)(\([^)]*\))?!?: so the gate actually fires on scoped conventional commits. Without this, the gate cannot enforce CHANGELOG entries on sequant's own dogfood (the /fullsolve 575 regression case).
    3. Optional: Tighten §10a caveat wording — currently says "projects without conventional commits silently skip"; should say "projects whose conventional commits don't match (feat\|fix\|...): exactly (no scope, no !) silently skip."
  6. added
    needs-improvement
    on May 8, 2026
  7. admarble commented on May 9, 2026

    @admarble
    ContributorAuthor

    /fullsolve Complete

    Issue: #585
    Status: AC_MET_BUT_NOT_A_PLUS → proceeding to PR (per feedback_qa_break_vs_loop)

    Resumption Note

    All phases were already complete on a prior /fullsolve invocation. This run detected the existing state and did not re-execute spec / exec / qa.

    Phase Status Source
    Spec ✅ Complete Plan comment 2026-05-08T02:43Z
    Exec ✅ Complete Commit eaa1b2a
    Test ⊘ Skipped (no UI labels) —
    QA ✅ Complete Verdict AC_MET_BUT_NOT_A_PLUS
    PR ✅ Open as #601 MERGEABLE / CLEAN

    AC Coverage (from prior QA)

    • AC-1: §7 verdict ladder includes changelog_missing branch → MET
    • AC-2: No-op when CHANGELOG.md absent → MET
    • AC-3: No-op when no user-facing prefix detected → MET
    • AC-4: Mirrored across all three qa/SKILL.md copies → MET
    • AC-5: Regression — proper CHANGELOG entry still READY_FOR_MERGE → MET

    Coverage: 5/5

    CI Status

    8/8 checks green (build 20.x/22.x, typecheck, validate-skills, validate-plugin, plugin structure, hooks, setup dirs).

    Risk Assessment (carried from QA)

    • Likely failure mode: §10a's existing detection regex (^[a-f0-9]+ (feat\|fix\|perf\|refactor\|docs):) misses scoped conventional commits like feat(#NNN):, so the newly wired §7 gate cannot fire on sequant's own dogfood. Wiring is correct; upstream detection is the bottleneck.
    • Not tested: Prompt-only change — no executable code paths.

    Recommended Follow-up

    File a separate issue to broaden §10a's user_facing regex from (feat\|fix\|perf\|refactor\|docs): to (feat\|fix\|perf\|refactor\|docs)(\([^)]*\))?!?: so the gate fires on scoped conventional commits. (This is a recommendation, not an unmet AC — explicitly out of scope for #585.)

    PR: #601

    Ready for human merge.

  8. admarble commented on May 9, 2026

    @admarble
    ContributorAuthor

    Follow-up filed: #610

    Per QA's recommendation in PR #601 — filed #610 to broaden §10a's user_facing regex from (feat|fix|perf|refactor|docs): to (feat|fix|perf|refactor|docs)(\([^)]*\))?!?: so the gate wired by this PR actually fires on scoped conventional-commit projects (sequant included). Also covers tightening the §10a caveat wording.

    This PR (#601) ships as-is — its ACs are literally met and the wiring is correct. #610 closes the dogfood gap separately.

  9. added a commit that references this issue on May 9, 2026
  10. added a commit that references this issue on May 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    clienhancementneeds-improvementplanned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions