From 8edc6effb15c1a7dc86950593affd4553f433687 Mon Sep 17 00:00:00 2001 From: Julio Quinteros Pro Date: Thu, 19 Feb 2026 19:45:14 -0300 Subject: [PATCH] fix(ci): fix YAML syntax error in regenerate-poetry-lock workflow A heredoc inside \$() inside a double-quoted string inside a YAML multiline run block breaks the YAML parser at line 60. Replaced with: write the PR body to /tmp/pr-body.md using a standalone heredoc, then pass it via gh pr create --body-file. Co-Authored-By: Claude Sonnet 4.6 --- .github/workflows/regenerate-poetry-lock.yml | 27 +++++++++++--------- 1 file changed, 15 insertions(+), 12 deletions(-) diff --git a/.github/workflows/regenerate-poetry-lock.yml b/.github/workflows/regenerate-poetry-lock.yml index 7e4bac017df..17791f411cf 100644 --- a/.github/workflows/regenerate-poetry-lock.yml +++ b/.github/workflows/regenerate-poetry-lock.yml @@ -54,20 +54,23 @@ jobs: git add poetry.lock git commit -m "chore: regenerate poetry.lock to match pyproject.toml" git push -f origin "$BRANCH" + + # Write body to a temp file to avoid heredoc/quoting issues in YAML + cat > /tmp/pr-body.md << 'BODY' + Automated regeneration of `poetry.lock` after `pyproject.toml` was updated on `main`. + + Fixes the recurring CI failure: + ``` + pyproject.toml changed significantly since poetry.lock was last generated. + Run `poetry lock` to fix the lock file. + ``` + + Regenerated with `poetry lock --no-update` (existing package versions are preserved; only the lock file metadata is updated to match the new constraints). + BODY + gh pr create \ --title "chore: regenerate poetry.lock to match pyproject.toml" \ - --body "$(cat <<'EOF' -Automated regeneration of \`poetry.lock\` after \`pyproject.toml\` was updated on \`main\`. - -Fixes the recurring CI failure: -\`\`\` -pyproject.toml changed significantly since poetry.lock was last generated. -Run \`poetry lock\` to fix the lock file. -\`\`\` - -Regenerated with \`poetry lock --no-update\` (existing package versions are preserved; only the lock file metadata is updated to match the new constraints). -EOF -)" \ + --body-file /tmp/pr-body.md \ --head "$BRANCH" \ --base main env: