Skip to content

CI: fix YAML syntax error in pr-test-builds workflow#11384

Merged
sensei-hacker merged 1 commit intoiNavFlight:maintenance-9.xfrom
sensei-hacker:fix/pr-test-builds-yaml-syntax
Mar 1, 2026
Merged

CI: fix YAML syntax error in pr-test-builds workflow#11384
sensei-hacker merged 1 commit intoiNavFlight:maintenance-9.xfrom
sensei-hacker:fix/pr-test-builds-yaml-syntax

Conversation

@sensei-hacker
Copy link
Member

Summary

Fixes a YAML parse error introduced in #11381 that caused the pr-test-builds workflow to fail on every run with "workflow file issue".

Root cause

The NOTES variable assignment in the "Create PR release" step spanned multiple lines, and the continuation lines (**..., >...) had zero indentation. YAML block scalars require all non-blank content lines to be at least as indented as the block's base level. Lines at column 0 inside a 10-space-indented block scalar are a parse error.

Fix

Replace the multi-line NOTES variable + --notes with printf writing to a temp file + --notes-file. This avoids multi-line strings in the YAML block scalar entirely. The ${{ }} expressions are also moved into env: vars rather than inline in the shell script.

Testing

PR #11383 had all CI checks pass before this fix was available — it can be used to verify the workflow runs correctly once this is merged.

Multi-line shell string in the NOTES variable had unindented continuation
lines (**..., >...) that were less indented than the YAML block scalar
body, causing a parse error on every run.

Replace with printf + --notes-file to avoid multi-line strings in the
YAML block scalar entirely. Also moves ${{ }} expressions into env vars
rather than inline in the shell script.
@qodo-code-review
Copy link
Contributor

Review Summary by Qodo

Fix YAML syntax error in pr-test-builds workflow

🐞 Bug fix

Grey Divider

Walkthroughs

Description
• Fixes YAML syntax error in pr-test-builds workflow caused by unindented continuation lines
• Replaces multi-line NOTES variable with printf writing to temp file
• Moves GitHub expression variables into env section for better maintainability
• Uses --notes-file instead of inline --notes parameter
Diagram
flowchart LR
  A["Multi-line NOTES variable<br/>with unindented lines"] -->|Replace with| B["printf to<br/>release-notes.md"]
  C["Inline ${{ }} expressions"] -->|Move to| D["env section variables"]
  B -->|Use| E["--notes-file parameter"]
  D -->|Reference in| F["Shell script"]
Loading

Grey Divider

File Changes

1. .github/workflows/pr-test-builds.yml 🐞 Bug fix +14/-15

Refactor YAML syntax and variable handling

• Moved GitHub expression variables (PR_NUMBER, SHORT_SHA, HEX_COUNT, HEAD_SHA, REPO) from inline
 shell script to env section
• Replaced multi-line NOTES variable assignment with printf command that writes to release-notes.md
 file
• Changed gh release create command to use --notes-file instead of --notes with inline variable
• Updated file path from hexes directory reference to hexes/*.hex glob pattern

.github/workflows/pr-test-builds.yml


Grey Divider

Qodo Logo

@qodo-code-review
Copy link
Contributor

qodo-code-review bot commented Mar 1, 2026

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)

Grey Divider

Great, no issues found!

Qodo reviewed your code and found no material issues that require review

Grey Divider

ⓘ The new review experience is currently in Beta. Learn more

Grey Divider

Qodo Logo

@sensei-hacker sensei-hacker merged commit b2dd830 into iNavFlight:maintenance-9.x Mar 1, 2026
20 checks passed
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