Skip to content

Commit

Permalink
Still trying to get test-coverage workflow to work on GitHub
Browse files Browse the repository at this point in the history
The step codecov/codecov-action@v4 fails on GitHub with error:

"info - 2025-01-03 19:02:52,761 -- ci service found: github-actions
warning - 2025-01-03 19:02:52,797 -- Branch `main` is protected but no token was provided
warning - 2025-01-03 19:02:52,797 -- For information on Codecov upload tokens, see https://docs.codecov.com/docs/codecov-tokens
info - 2025-01-03 19:02:53,146 -- Process Commit creating complete
error - 2025-01-03 19:02:53,146 -- Commit creating failed: {"message":"Token required because branch is protected"}
Error: Codecov: Failed to properly create commit: The process '/Users/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1"

I don't want to commit to codecov anyways because CSAFE doesn't have an account, so I tried deleting this step.
  • Loading branch information
stephaniereinders committed Jan 3, 2025
1 parent b1e8ad5 commit 8b9d132
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions .github/workflows/test-coverage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,15 +37,6 @@ jobs:
covr::to_cobertura(cov)
shell: Rscript {0}

- uses: codecov/codecov-action@v4
with:
# Fail if error if not on PR, or if on PR and token is given
fail_ci_if_error: ${{ github.event_name != 'pull_request' || secrets.CODECOV_TOKEN }}
file: ./cobertura.xml
plugin: noop
disable_search: true
token: ${{ secrets.CODECOV_TOKEN }}

- name: Show testthat output
if: always()
run: |
Expand Down

0 comments on commit 8b9d132

Please sign in to comment.