Thanks to visit codestin.com
Credit goes to github.com

Skip to content

upload-sarif post-action step failed: Input required and not supplied: token #2553

Closed
@jsoref

Description

@jsoref

I'm about to release a new version of check-spelling, and I'm tripping on actions/runner#3514 in this action (github/codeql-action/upload-sarif@v3).

A run of check-spelling using the current github/codeql-action/upload-sarif@v3 triggers:
https://github.com/check-spelling-sandbox/check-spelling/actions/runs/11422357281
image

https://github.com/check-spelling-sandbox/check-spelling/actions/runs/11422357281/job/31780250586#step:9:1

Post check-spelling
Post job cleanup.
Post job cleanup.
Error: upload-sarif post-action step failed: Input required and not supplied: token

The error message is wrong -- the action was called with a token. But actions/runner does not reliably send inputs to actions when they run in post. As of today (until someone fixes actions/runner#3514), each action must save its inputs from the pre or main step using the save-state magic and then retrieve the value from the state environment variable when running in the pre stage instead of using inputs.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions