fatiando / harmonica

Forward modeling, inversion, and processing gravity and magnetic data
https://www.fatiando.org/harmonica
BSD 3-Clause "New" or "Revised" License
205 stars 66 forks source link

Move codecov push to its own job in Actions workflow #502

Closed santisoler closed 1 month ago

santisoler commented 2 months ago

Remove the push to codecov step from the test job into a new job that depends on the test job. Upload the coverage reports as artifacts after testing, and reuse the artifacts in the new job. Upload all coverage reports in a single push to Codecov to minimize the number of hits.

Relevant issues/PRs:

Related to fatiando/community#151

santisoler commented 2 months ago

I think we can. We would just have to name each artifact differently and then download them all and pushed them all in a single job. Does it make sense?

leouieda commented 2 months ago

👍🏾

santisoler commented 2 months ago

Done! Now all runners upload the coverage.xml file as a separate artifact, and the codecov-upload job downloads them all and pushes them all together to Codecov in a single run (lowering the hits to their servers).

Let me know if you like it. I'm looking forward to try this out on a PR opened from a fork.