-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Prevent testcov running on public forks #4837
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
We can't retrieve secrets for public forks. Otherwise: Run grafana/shared-workflows/actions/get-vault-secrets@get-vault-secrets/v1.2.1 Run ${GITHUB_ACTION_PATH}/translate-secrets.bash Secrets that will be queried from Vault: ci/data/repo/grafana/k6/CODECOV_TOKEN CODECOV_TOKEN | CODECOV_TOKEN; Run actions/github-script@60a0d83 Error: Error message: Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable at OidcClient.<anonymous> (/home/runner/work/_actions/actions/github-script/60a0d83039c74a4aee543508d2ffcb1c3799cdea/dist/index.js:585:23) at Generator.next (<anonymous>) at /home/runner/work/_actions/actions/github-script/60a0d83039c74a4aee543508d2ffcb1c3799cdea/dist/index.js:522:71 at new Promise (<anonymous>) at __webpack_modules__.8041.__awaiter (/home/runner/work/_actions/actions/github-script/60a0d83039c74a4aee543508d2ffcb1c3799cdea/dist/index.js:518:12) at OidcClient.getIDToken (/home/runner/work/_actions/actions/github-script/60a0d83039c74a4aee543508d2ffcb1c3799cdea/dist/index.js:571:16) at Object.<anonymous> (/home/runner/work/_actions/actions/github-script/60a0d83039c74a4aee543508d2ffcb1c3799cdea/dist/index.js:421:46) at Generator.next (<anonymous>) at /home/runner/work/_actions/actions/github-script/60a0d83039c74a4aee543508d2ffcb1c3799cdea/dist/index.js:133:71 at new Promise (<anonymous>) Error: Unhandled error: Error: Error message: Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable
cecab14
to
786c5db
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Out of curiosity; I see the condition (i.e. if
) is only set for the step to retrieve the token, does that mean that, when this workflow is executed for a fork, the step right after this one (the one that uploads coverage to Codecov) will fail because it will use a blank token?
If so, I guess it would be better if we can skip that one as well and thus prevent confusing errors.
Other than that, it looks good!
What?
CODECOV_TOKEN
for public forks.Why?
We can't retrieve secrets for public forks (example). Otherwise, we see:
Checklist
make check
) and all pass.Checklist: Documentation (only for k6 maintainers and if relevant)
Please do not merge this PR until the following items are filled out.
Related PR(s)/Issue(s)
Updates grafana/k6-cloud#3525