Skip to content

fix: repair the workflow v0.1.7 could not load, and move to client-id - #94

Merged
charlesgreen merged 1 commit into
mainfrom
fix/93-client-id
Jul 31, 2026
Merged

charlesgreen merged 1 commit into
mainfrom
fix/93-client-id

Conversation

@charlesgreen

Copy link
Copy Markdown
Contributor

The actual problem

v0.1.7 shipped a reusable workflow that GitHub will not load.

The comment dispatch fix in a196683 gave the run step a second env: block instead of adding to the existing one. yaml.safe_load accepts duplicate keys and keeps the last, so GH_TOKEN, AZURE_OPENAI_ENDPOINT, and AZURE_OPENAI_API_KEY were all silently discarded. GitHub's parser is stricter and rejects the file outright.

Every run since that merge failed in about a second with no job created and no log:

30594679760  failure  release: prepare v0.1.7        0s
30594644772  failure  Migrate the token action ...   0s
30593270249  failure  docs: fix what the docs ...    0s

That includes the run triggered by filing #93 itself.

Why the gate missed it

The gate parsed workflows with yaml.safe_load, the one parser that accepts the broken file. This is the second workflow defect to pass a gate that only compiles Go, after the conflict markers.

scripts/check-workflows.sh now rejects a duplicate key anywhere in a workflow, template, or the embedded caller. It was written against the real v0.1.7 file and fails on it:

CAUGHT: duplicate key 'env' at line 115

The #93 part

The issue's premise does not hold at create-github-app-token@v3.2.0. main.js line 21 is core.getInput("client-id") || core.getInput("app-id"), and that single value goes straight to createAppAuth({appId}). There is no branch distinguishing them, so the swap was never risky.

The token step now passes only client-id, so no deprecated input is present and the warning is gone. A caller still passing github-app-id keeps working through the fallback. The documented variable is SIMPLYCUBED_GH_APP_CLIENT_ID, already set on this repo, because GitHub is moving that direction.

Verification

  • make check green, including the new duplicate-key check
  • No SIMPLYCUBED_GH_APP_ID references remain outside the deprecated input
  • All 9 caller call sites pass github-app-client-id, matching the declared input
  • No v0.1.7 references remain outside the changelog and the status warning

Closes #93

The v0.1.7 reusable workflow does not run. The comment dispatch fix added a
second `env:` block to the run step rather than adding to the first one.
Duplicate keys are legal to yaml.safe_load, which keeps the last, so GH_TOKEN
and both Azure variables were discarded. GitHub is stricter and refuses to load
the file, so every run since that merge failed in about a second having started
no job at all.

The gate could not see it. It parsed workflows with yaml.safe_load, which is
precisely the parser that accepts the file. It now rejects a duplicate key
anywhere in a workflow, a template, or the embedded caller, and the check was
written against the real v0.1.7 file to confirm it fails on it.

Closes the deprecation warning at the same time, since it touches the same
steps. `create-github-app-token` resolves `client-id || app-id` into a single
value and passes it straight to createAppAuth, so the inputs are interchangeable
in practice at v3.2.0 even though they are not in principle. Callers passing
`github-app-id` keep working; the documented path is now
SIMPLYCUBED_GH_APP_CLIENT_ID.

Closes #93
@codecov

codecov Bot commented Jul 31, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@charlesgreen
charlesgreen merged commit 420a639 into main Jul 31, 2026
3 checks passed
@charlesgreen
charlesgreen deleted the fix/93-client-id branch July 31, 2026 01:11
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.

Migrate the token action from app-id to client-id

1 participant