Skip to content

ci: check release notes on every PR and at release (#305) - #306

Merged
craigmcchesney merged 6 commits into
mainfrom
issue-305-release-notes-checker
Oct 1, 2026
Merged

craigmcchesney merged 6 commits into
mainfrom
issue-305-release-notes-checker

Conversation

@craigmcchesney

@craigmcchesney craigmcchesney commented Oct 1, 2026 •

Copy link
Copy Markdown
Collaborator

Closes #305. Part of osprey-dcs/data-platform#98.

Ports the release-notes checker from osprey-dcs/dp-python-lib#70 to .github/scripts/check-release-notes.py. The file is copied verbatim; only the configuration block differs:

  • REPOSITORY
  • sigstore-python rules off
  • COSIGN_IDENTITY_WORKFLOWS = ("release.yml", "release-image.yml")
  • COSIGN_IMAGE = "ghcr.io/osprey-dcs/dp-service"

Changes

  • Signing identity: in rel-X.Y.Z.md, every --certificate-identity must be exactly this repo's workflow at @refs/tags/<tag>, and the image's :rel- tag must match.
  • ci.yml: a "Check release notes" step runs first in build-and-test (the required check), so a notes problem fails before the long build.
  • release.yml, "Verify release notes exist":
    • A release checks the notes being published, and fails if they're missing or have any problem.
    • A rehearsal now runs the step too. It checks every notes file and only warns. That is a deliberate exception, for this step only, to the file's rule that a rehearsal should fail on a real problem, and the step's comment says so.
    • NOTES_PATH is still set only on a release.
  • Docs: NEXT.md's "Cutting the release" step 4 and CLAUDE.md's "Releases" point at the checker.
  • No new uses:.

Testing

  • Self-test and real notes: pass, on rel-1.14.0.md, rel-1.16.0.md and NEXT.md.
  • Simulated cut: renaming NEXT.md without the cut steps flags the main links, the rel-<version> identities and the image tag.
  • Release step, run under bash: release with good notes passes; release with bad notes and release with notes missing fail; rehearsal with bad notes warns and exits 0; rehearsal with good notes passes.
  • Workflows: the pin check, YAML parse and actionlint are clean.

Not yet verified

CI passing on this PR, and a dry-run dispatch of release.yml that shows the backstop running.

Merge after osprey-dcs/dp-python-lib#73.

🤖 Generated with Claude Code

https://claude.ai/code/session_012nsCzraPATf4LCKVyUStfd

craigmcchesney and others added 4 commits October 1, 2026 11:16
Port osprey-dcs/dp-python-lib's release-notes checker (data-platform#98,
R1-R5 for rel-*.md, N1-N3 for NEXT.md), verbatim apart from its
configuration block: REPOSITORY osprey-dcs/dp-service, no sigstore-python
rules, cosign identities for release.yml and release-image.yml, and the
ghcr.io/osprey-dcs/dp-service image tag.

It lives at .github/scripts/ rather than .dev/tools/, because .dev/ is
gitignored here; the script locates the repo root two levels up, so the
depth is the same and the copy needs no change.

ci.yml runs it as the first step of build-and-test, the required check.
release.yml's "Verify release notes exist" now runs it on the tagged file
as a backstop, and on a rehearsal (which has no tag) over every notes file,
so a dry run shows it and its self-test running. No new actions; the runner's
python3 is enough.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012nsCzraPATf4LCKVyUStfd
…ker (#305)

NEXT.md's "Cutting the release" step 4 now says the checker lists every
link still on main, every leftover placeholder, and every signing identity
or image tag that does not name the release (data-platform#98 step 4).
CLAUDE.md "Releases" says where the checker runs, what it enforces, and
that it is a verbatim copy to be updated by copying, not edited.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012nsCzraPATf4LCKVyUStfd
Re-copy the reference checker verbatim from dp-python-lib (sha256
86b3f628...7f0c); only the configuration block differs. It now finds
the repo root by walking up to .git, and R5 no longer flags a bare
<version>, only rel-<version> and <previous>.

release.yml's "Verify release notes exist" now warns rather than fails
when a rehearsal's checker run finds problems, as all five repos do; a
real release still fails, and NOTES_PATH is still set only on a release.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012nsCzraPATf4LCKVyUStfd
)

R5 no longer flags a bare <version>, so the checklist no longer tells the
cutter to reword generic <version> prose; filling rel-<version> in the
verify commands and image tag stays. CLAUDE.md says rehearsals warn and
drops the note about the old .dev/tools usage line.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012nsCzraPATf4LCKVyUStfd

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

The checker mishandles anchors inside code and trailing punctuation on image tags.

Review effort: Balanced
Findings: 2 Medium severity

Open (2)
What changed in this PR

Adds automated release-note validation to CI and release workflows.

Changes:

  • Adds a self-testing release-note checker.
  • Enforces checks during PR validation and releases.
  • Documents the release-note validation process.
File Description
.github/​scripts/​check-release-notes.py Implements validation and self-tests.
.github/​workflows/​ci.yml Runs validation in CI.
.github/​workflows/​release.yml Adds release-time validation.
doc/​release-notes/​NEXT.md Updates release-cut instructions.
CLAUDE.md Documents checker rules and workflow.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread .github/scripts/check-release-notes.py Outdated
Comment thread .github/scripts/check-release-notes.py
release.yml's notes-step comment said all five repos warn on a rehearsal;
dp-python-lib skips the check on a dispatch instead. CLAUDE.md said
already-released notes get only the form rules; they also get the
identity rules, and skip only the path and anchor checks.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012nsCzraPATf4LCKVyUStfd
craigmcchesney added a commit to osprey-dcs/dp-python-lib that referenced this pull request Oct 1, 2026
…#70)

Found by Copilot on osprey-dcs/dp-service#306.  An unquoted image in
prose ("pull ghcr.io/osprey-dcs/dp-service:rel-2.1.0.") was read as tag
`rel-2.1.0.` and failed correct notes; a trailing comma did the same.
Trailing `.,;:!?` is now stripped from the captured tag, as urls() does,
so a `rel-2.1.0-rc1` tag is still read whole.  Self-tests cover a good
tag followed by a period and by a comma, and an -rc1 tag before a period.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012nsCzraPATf4LCKVyUStfd
Re-copied from osprey-dcs/dp-python-lib@f04d830 (dp-python-lib#73 as merged); only the
configuration block differs.  Picks up the review fixes made there:

- R2/N2 apply only to the five lockstep repos, not every osprey-dcs repo.
- http:// as well as https:// github.com and raw links are checked.
- A reference definition with its destination on the next line is parsed.
- HTML anchors inside code no longer count as link targets.
- A same-document #L... anchor fails R4; a blob link's line anchor is not range-checked.
- A backslash-newline between a signing flag and its value is accepted.
- Trailing sentence punctuation after the image tag is not read as part of it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012nsCzraPATf4LCKVyUStfd
@craigmcchesney
craigmcchesney merged commit 2dd11df into main Oct 1, 2026
1 check passed
@craigmcchesney
craigmcchesney deleted the issue-305-release-notes-checker branch October 1, 2026 20:24
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.

Port the release-notes checker with link rules and cosign identity checks (data-platform#98)

2 participants