Multiline annotations are not correctly displayed.
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 5.9k
- Forks
- 1.8k
- PR merge metrics
- No merged PRs in 30d
Description
Describe the bug
The Command class uses escaping to transform multi-line messages into a single-line annotation:
https://github.com/actions/toolkit/blob/7b617c260dff86f8d044d5ab0425444b29fa0d18/packages/core/src/command.ts#L80-L85
While browsers correctly resolved the %-escaped chars in the past, it seems to fail nowadays as can be seen in this build.
To Reproduce
- Generate a multi-line annotation, e.g. via the escaped output:
echo "::warning::multi%0Aline" - Output generated in build https://github.com/rhaschke/test/actions/runs/5961263674 is:
multi line
Expected behavior
multi
line
Screenshots
Desktop (please complete the following information):
Browser: Google Chrome, version 116.0.5845.110 (Official Build)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in packages/core/src/command.ts at the escaping logic linked in the issue, then reproduce the problem with the shown :⚠️:multi%0Aline command. Done means the annotation renders as two lines rather than a single line in the linked GitHub Actions build.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions, typescript
- Domain
- ci-cd, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 38/100