Skip to content

Fix non-ASCII characters in generated release notes - #2460

Open
Tino Teuber (tino-teuber) wants to merge 1 commit into
microsoft:mainfrom
tino-teuber:fix/release-notes-non-ascii-characters
Open

Tino Teuber (tino-teuber) wants to merge 1 commit into
microsoft:mainfrom
tino-teuber:fix/release-notes-non-ascii-characters

Conversation

@tino-teuber

Copy link
Copy Markdown
Contributor

❔What, Why & How

The release notes generated by Create release lose umlauts and other non-ASCII characters (Prüfung becomes Pr??fung).

GetReleaseNotes returned the InvokeWebRequest response object and its callers piped that object into ConvertFrom-Json. The object is then converted with ToString(), which replaces every non-ASCII character with ? before the text reaches GITHUB_OUTPUT. GitHub sends correct UTF-8 (charset=utf-8); the text is damaged on the AL-Go side.

GetReleaseNotes now returns the response content (.Content), like the other helpers in Github-Helper.psm1 that parse JSON from InvokeWebRequest. Both callers (CreateReleaseNotes.ps1 and BuildReferenceDocumentation.ps1) already pipe the result into ConvertFrom-Json and need no change; the existing CreateReleaseNotes unit tests already mock GetReleaseNotes with a JSON string, so they now match the real return value.

Tests:

  • New unit test GetReleaseNotes in Tests/GitHub-Helper.Test.ps1. It emulates the Windows PowerShell 5.1 ToString() behaviour and asserts that umlauts and typographic quotes survive. It fails without the fix.
  • GitHub-Helper, CreateReleaseNotes and BuildReferenceDocumentation Pester tests pass in Windows PowerShell 5.1 and PowerShell 7.
  • Verified manually that the unmodified GetReleaseNotes of v8.3, v10.0 and current main returns Pr??fung in Windows PowerShell 5.1 against a local server (details in the issue).
  • Not run: end-to-end tests, a real Create release workflow run and the pre-commit hooks.

Related to issue: #2459

✅ Checklist

  • Add tests (E2E, unit tests)
  • Update RELEASENOTES.md
  • Update documentation (e.g. for new settings or scenarios)
  • Add telemetry

🤖 Generated with Claude Code

GetReleaseNotes returned the Invoke-WebRequest response object. Callers piped
it into ConvertFrom-Json, which converts it with ToString() and replaces every
non-ASCII character (umlauts, typographic quotes, ...) with '?'. Return the
response content instead, so CreateReleaseNotes and BuildReferenceDocumentation
get the correctly decoded JSON.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@tino-teuber
Tino Teuber (tino-teuber) requested a review from a team as a code owner November 13, 2026 08:01
Copilot AI balanced review requested due to automatic review settings November 13, 2026 08:01

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.

🟢 Approval recommended

No active review issues remain for the change to preserve non-ASCII characters in generated release notes.

No open issues 🎉

What changed in this PR

Fixes #2459 by preserving non-ASCII characters in generated release notes for Create Release and reference documentation.

Changes:

  • Returns the JSON response content from GetReleaseNotes, avoiding the response-object string conversion that corrupts characters.
  • Adds a regression test covering umlauts and typographic quotes.
  • Documents the fix in the release notes.
File Description
Tests/​GitHub-Helper.Test.ps1 Adds a regression test for non-ASCII release-note content.
RELEASENOTES.md Records the fix for issue #2459.
Actions/​Github-Helper.psm1 Returns .Content from GetReleaseNotes for existing JSON-parsing callers.

Review effort: Balanced

This branch has not been deployed

No deployments
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