Error processing coverage reports with Jest and Github Action


I just spun up a new project and am uploading JavaScript test coverage reports (generated by Jest) to Codecov using the action for GitHub Actions. In my project I’m not seeing any data, just a generic “There was an error processing coverage reports” error.


(The application being tested is in the frontend directory - I’m suspicious that this is part of the issue, and I’ve tried to fix paths, via the docs on fixing paths, but nothing has worked.


Chrome 78, macOS Mojave, but I doubt this is relevant

More importantly:

Additional Information

Zipfile of the reports generated with Jest:

Codecov GH Actions logs: (inlined below)

Run codecov/codecov-action@v1
bash -n  -F  -y codecov.yml

  _____          _
 / ____|        | |
| |     ___   __| | ___  ___ _____   __
| |    / _ \ / _` |/ _ \/ __/ _ \ \ / /
| |___| (_) | (_| |  __/ (_| (_) \ V /
 \_____\___/ \__,_|\___|\___\___/ \_/

==> GitHub Actions detected.
    project root: .
--> token set from env
    Yaml found at: codecov.yml
sed: can't read ./codecov.yml: No such file or directory
==> Running gcov in . (disable via -X gcov)
==> Python coveragepy not found
==> Searching for coverage reports in:
    + .
    -> Found 3 reports
==> Detecting git/mercurial file structure
==> Reading reports
    + ./coverage/clover.xml bytes=9580
    + ./coverage/coverage-final.json bytes=21994
    + ./coverage/ bytes=4242
==> Appending adjustments
    -> No adjustments found
==> Gzipping contents
==> Uploading reports
    query: branch=frontend&commit=b341efe45de1becb0bfd8eab6c07c47fb302bc82&build=&build_url=&name=&tag=&slug=bjacobel%2Fepstein&service=github-actions&flags=&pr=&job=
    -> Pinging Codecov
    -> Uploading
    -> View reports at

Hi @bjacobel

First, this is a beautiful bug report that has everything I need to be able to help, thank you!

Second, let’s take a look here.

Here’s the raw report you uploaded:

It looks like the uploader wasn’t run in the correct directory since the network section (the files listing) only contains coverage files. Ideally the uploader should be run from the repo root.

Without those files, we can’t match to the coverage report and thus we consider the report empty and fail the processing.

Thanks for the response!

I’ve resolved the issue - I didn’t realize the repository’s source files needed to be on disk during the Codecov upload step (I thought they just were obtained directly from GitHub or something!). My Github Actions step for Codecov was running at a point where the source files had already been removed from the workspace - only the coverage artifacts were present. By reorganizing things to make sure that both source files and coverage assets were present when the upload steps run, it is now working.

1 Like