Schema-diff driven release notes#85
Merged
Merged
Conversation
brianorwhatever
force-pushed
the
schema-diff-release-notes
branch
from
July 15, 2026 19:52
ff0f35d to
7834e8e
Compare
Track the supergraph schema in git and diff it at release time so schema-driven releases get real changelogs: - commit src/resources/schema.graphql (fetch:schema updates it; build now reads the committed copy via copy:schema, making builds reproducible) - add src/scripts/schemaDiff.ts (@graphql-inspector/core) which prints a markdown summary grouped by criticality and emits changed/level outputs - bump.yml fetches the latest schema, commits the update, bumps minor for breaking schema changes (patch otherwise), skips no-op releases, and leads the GitHub Release notes with the schema diff
brianorwhatever
force-pushed
the
schema-diff-release-notes
branch
from
July 15, 2026 20:00
8ec1d10 to
7ffc2ba
Compare
brianorwhatever
marked this pull request as ready for review
July 15, 2026 20:02
brianorwhatever
enabled auto-merge (squash)
July 15, 2026 22:46
brianorwhatever
disabled auto-merge
July 15, 2026 22:46
bradens
approved these changes
Jul 15, 2026
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.
Why
The majority of SDK releases exist because the upstream supergraph schema changed, but the release commit is a one-line
package.jsonbump and the GitHub Release body is just a compare link — the schema is gitignored and fetched at build time, so neither git nor GitHub's release-note generator can see what actually changed. (This also meant the recentCategory.iconUrl/bannerUrlremoval shipped invisibly inside 2.3.12/2.3.13.)What
src/resources/schema.graphqlis now committed.fetch:schemaupdates it;buildreads the committed copy (copy:schema), so published artifacts are reproducible from the tagged commit — previouslyrelease.ymlre-fetched at publish time and what shipped wasn't traceable to any commit.src/scripts/schemaDiff.ts(new, uses@graphql-inspector/core): diffs two SDL files and prints a markdown summary grouped into Breaking / Dangerous / Additions, with noise collapsed (added/removed types roll up their member bullets, directive-usage duplicates dropped, description edits summarized, 100-bullet cap per section). Emitschanged/leveloutputs for CI.bump.yml: fetch latest schema → diff against committed copy → commit the schema update → bump minor if breaking, patch otherwise → tag → GitHub Release whose notes lead with the schema diff (auto-generated PR notes still appended). Skips the release entirely if the schema is unchanged and there are no new commits.Note: the committed generated SDK code (
src/sdk/generated,Subscribe.ts,Query.ts) is intentionally untouched here — it regenerates from the committed schema at build time and will sync up on the next release.Example output
A release after the recent Category deprecations would render:
Schema additions
1 description/documentation change(s).
And if fields are hard-removed, the notes lead with⚠️ Breaking schema changes and the version bump escalates to minor automatically.
Testing
pnpm run buildandpnpm test(25/25) pass; new script is eslint/prettier clean.