Skip to content

fix(release): keep ReleaseNotes within the Gallery's limit - #57

Merged
fadwen merged 1 commit into
mainfrom
fix/release-notes-length
Sep 29, 2026
Merged

fadwen merged 1 commit into
mainfrom
fix/release-notes-length

Conversation

@fadwen

@fadwen fadwen commented Sep 29, 2026

Copy link
Copy Markdown
Owner

Summary

The PowerShell Gallery refused the 1.5.0 package on upload:

The package is invalid. The error encountered was: 'A package's ReleaseNotes property extracted from the PowerShell manifest may not be more than 10600 characters long.'

The manifest's ReleaseNotes was 12,699 characters. Each release from 1.0.0 to 1.5.0 had prepended its paragraph and none had removed one, so the field grew by a release every time. The limit is enforced only on upload, so every earlier gate passed: the unit suite, Publish-Module.ps1 -WhatIf, and the release workflow up to the publish step. The Gallery still lists 1.4.0 as the latest version; nothing was published as 1.5.0.

Changes

  • TestEnvironment.psd1: ReleaseNotes carries the 1.5.0 paragraph only, followed by a link to CHANGELOG.md, which already describes every release in more detail. It is now 2,200 characters. A comment above the field records why it holds one release.
  • Build/Publish-Module.ps1: a manifest whose ReleaseNotes exceeds 10,600 characters, or whose Description exceeds 4,000 (NuGet's package description limit), is refused with a message naming the field and its length. The check runs in the manifest section, before staging, so it also stops a -WhatIf rehearsal.
  • Tests/Unit/Module.Contract.Tests.ps1: a new test holds the manifest to both limits, so a pull request fails rather than the tag-driven release.
  • CHANGELOG.md: the 1.5.0 entry records the fix.

The version stays 1.5.0, because that number has not been consumed on the Gallery.

Verification

  • The new check against the manifest as merged in feat: add OneLogin as the seventh provider #56: refused with "The manifest's ReleaseNotes is 12699 characters; the Gallery refuses more than 10600."
  • The contract suite: 1341 passed, 0 failed.
  • Windows PowerShell 5.1: Test-ModuleManifest reads version 1.5.0 with 2,200 characters of release notes. The manifest keeps its UTF-8 byte order mark.
  • ./Build/Publish-Module.ps1 -WhatIf: stages and verifies TestEnvironment 1.5.0 -> PSGallery.

Releasing after merge

Tag v1.5.0 currently points at the merge commit of #56, which carries the oversized manifest. Re-running the release from that tag would fail the same way. Once this is merged, the tag needs to point at the new merge commit:

git checkout main
git pull
git tag -d v1.5.0
git push origin :refs/tags/v1.5.0
git tag v1.5.0
git push origin v1.5.0

The alternative is to leave v1.5.0 where it is and release as 1.5.1, which means bumping ModuleVersion and the changelog heading first.

The PowerShell Gallery refused the 1.5.0 upload: the manifest's ReleaseNotes
was 12699 characters and the Gallery accepts at most 10600. Every release
since 1.0.0 had prepended a paragraph and none had removed one. Nothing was
published under 1.5.0.

ReleaseNotes now carries the current release only, with a link to
CHANGELOG.md, which already holds every release in more detail.

Publish-Module.ps1 now refuses a manifest whose ReleaseNotes exceeds 10600
characters or whose Description exceeds 4000, before it stages anything, and
a contract test holds the manifest to both limits so a pull request fails
rather than the tag-driven release.
@fadwen
fadwen merged commit f2a348c into main Sep 29, 2026
4 checks passed
@fadwen
fadwen deleted the fix/release-notes-length branch September 29, 2026 19:21
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