Skip to content

fix(workflows): escape literal ${{ }} in run-block comments#11

Merged
k2kite-megankim merged 1 commit into
mainfrom
fix/comment-escape
May 3, 2026
Merged

fix(workflows): escape literal ${{ }} in run-block comments#11
k2kite-megankim merged 1 commit into
mainfrom
fix/comment-escape

Conversation

@k2kite-megankim
Copy link
Copy Markdown
Contributor

요약

PR #10 의 `marketplace-publish.yml` 이 lvis-plugin-local-indexer 의 v0.1.23 / v0.1.24 / v0.1.25 publish 시도에서 모두 workflow-load 단계 fail. 원인: `run:` heredoc 안의 shell `#` 코멘트에 literal `${{ }}` 가 들어있어서 GitHub Actions expression parser 가 빈 expression 으로 해석 시도 → "unexpected end of input" 에러.

`actionlint` 로 발견:
```
yml:311:189: unexpected end of input while parsing variable access...
```

수정

두 코멘트 라인의 `${{ }}` placeholder → `` 로 교체. 의미는 그대로 보존.

  • line 176: resolver step 의 SECURITY 코멘트 블록
  • line 314: zip step 의 run-block 코멘트

영향

Public API (inputs / secrets / 런타임 동작) 무변. v1 floating-tag eligible — 머지 후 v1 태그를 이 커밋으로 force-update 해야 lvis-plugin-local-indexer 재발행 가능.

Test plan

  • `actionlint` 통과 (oracle runner label 만 false-positive 로 남음)
  • 머지 + v1 tag force-update → pageindex v0.1.26 tag → reusable workflow 정상 publish

GitHub Actions evaluates `\${{ }}` expressions inside `run:` heredoc
content unconditionally — even when the bracket pair appears inside a
shell `#` comment, the expression parser still tries to resolve it.
An empty `\${{ }}` substitution fails with "unexpected end of input"
at workflow-load time, surfacing as `referenced_workflows: []` with 0
jobs ever started — the symptom seen on lvis-plugin-local-indexer
v0.1.23 / v0.1.24 / v0.1.25 publish attempts.

Two comment lines documented the security rationale by literally
showing the `\${{ }}` syntax (saying "no `\${{ }}` shell injection
sink"). Replaced with `<expr>` placeholder which conveys the same
meaning without triggering the expression parser.

Locations:
- line 176 (in resolver step's SECURITY comment block)
- line 314 (in zip step's run-block comment)

Detected by `actionlint` — the v0.1.25 publish run on
lvis-plugin-local-indexer surfaced this issue cleanly.

This is a v1 floating-tag-eligible fix — the public API (inputs,
secrets, runtime behavior) is unchanged. The tag should be
force-updated to point at this commit after merge.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@k2kite-megankim k2kite-megankim merged commit d935e29 into main May 3, 2026
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