Skip to content

Sync @minecraft/api-docs-generator to published 2.4.0 - #165

Merged
JakeShirley merged 2 commits into
mainfrom
jashir/sync-api-docs-generator-2.4.0
Oct 13, 2026
Merged

JakeShirley merged 2 commits into
mainfrom
jashir/sync-api-docs-generator-2.4.0

Conversation

@JakeShirley

@JakeShirley JakeShirley commented Oct 13, 2026 •

Copy link
Copy Markdown
Member

Fixes the failing Release Changes workflow (e.g. run 38417777682).

What happened

  • The 10/09 release (run 37973462180) published @minecraft/api-docs-generator@2.4.0 to npm.
  • Its postpublish step, which creates the GitHub release, failed with HttpError: Bad credentials because REPO_PAT had expired. The run then failed, so the version bump and change-file cleanup were never pushed to main.
  • Every release since then has tried to publish 2.4.0 again and failed with "Attempting to publish package versions that already exist in the registry".

This change

  • Applies the bump beachball would have committed (npx beachball bump --scope tools/api-docs-generator): version 2.4.0, CHANGELOG entries, and removal of the two api-docs-generator change files.
  • Raises markup-generators-plugin's dev and peer dependency range to ^2.4.0, matching what previous release commits did.
  • api-docs-generator has no changes since 88f54aa, the commit 2.4.0 was published from, so main matches what's on npm.

The markup-generators-plugin change files are kept, so the next release will publish only @minecraft/markup-generators-plugin@2.3.0.

REPO_PAT has already been rotated. The @minecraft/api-docs-generator_v2.4.0 GitHub release/tag is still missing and can be created manually if wanted.

Prevention

  • Adds a Verify REPO_PAT step right after checkout in release-changes.yml. It calls gh api repos/$GITHUB_REPOSITORY with REPO_PAT and fails the run, with a clear error, if the token is invalid or expired or lacks write access. This happens before the build and before anything is published to npm, so a bad token can no longer leave npm ahead of the repo. Failures still go through the existing Handle failure notification.

The 10/09 release published @minecraft/api-docs-generator@2.4.0 to npm, but
postpublish failed (expired REPO_PAT), so the version bump was never pushed
back. Subsequent releases try to re-publish 2.4.0 and fail validation.

Apply the bump beachball would have committed and raise
markup-generators-plugin's dependency range to ^2.4.0.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@JakeShirley
JakeShirley requested a review from rlandav as a code owner October 13, 2026 16:20
Fail the release early if REPO_PAT is invalid, expired, or lacks write
access, before anything is published to npm. Previously an expired PAT
failed postpublish after the npm upload, leaving npm ahead of the repo.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@JakeShirley
JakeShirley merged commit db4bd94 into main Oct 13, 2026
5 of 6 checks passed
@JakeShirley
JakeShirley deleted the jashir/sync-api-docs-generator-2.4.0 branch October 13, 2026 16:31
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.

2 participants