ci: pass CODECOV_TOKEN explicitly to codecov-action#21
Merged
Conversation
codecov-action@v4 was not picking up CODECOV_TOKEN from env automatically in this workflow (log shows 'no token was provided' even though the secret is configured in repo settings). Pass it explicitly via the token input to make uploads reliable. Also add: - files: ./coverage.xml - explicit report path - fail_ci_if_error: false - coverage upload failures shouldn't break the CI run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Previous CI runs #27811830168 and #27812924596 both completed but Codecov upload failed with:
The
CODECOV_TOKENsecret IS configured in repo settings (gh secret listshows it), butcodecov-action@v4is not picking it up from env in this workflow.Fix
Pass the token explicitly via the action's
tokeninput. Also pin the report file path and disable hard-fail on upload error so a Codecov outage doesn't block CI.Verification
After merge, the next CI run should:
==> token set(or similar) in the codecov step