docfx icon indicating copy to clipboard operation
docfx copied to clipboard

[Bug] Codecov CI step is silently failed from last week.

Open filzrev opened this issue 10 months ago • 1 comments

Describe the bug

On GitHub Action CI. It seems CodeCov step is silently failed from last week. (https://github.com/dotnet/docfx/actions/runs/8502861596) with following warning.

test (ubuntu-latest) Codecov: Failed to properly create commit: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1

Expected behavior

  • Codecov step is successfully completed.
  • CI error is reported as error if Codecov step is failed. (by enable additional fail_ci_if_error: true option)

filzrev avatar Apr 09 '24 05:04 filzrev

It seems failed because codecov/codecov-action@v4 drop supports for token-less uploads. https://github.com/codecov/feedback/issues/315

It need set to repository secret and explicitly specify CODECOV_TOKEN. And set fail_ci_if_error: true to stop CI.

https://github.com/dotnet/docfx/blob/main/.github/workflows/ci.yml#L46-L47

    - uses: codecov/codecov-action@v4
      if: matrix.os == 'ubuntu-latest'
      with:
        fail_ci_if_error: true
        token: ${{ secrets.CODECOV_TOKEN }}

filzrev avatar May 14 '24 19:05 filzrev