-
Notifications
You must be signed in to change notification settings - Fork 192
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Re-add support for Coverage reports through codecov.io #3618
Re-add support for Coverage reports through codecov.io #3618
Conversation
3c2364a
to
550072f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks @dev-zero!
I have made a suggested change via a PR to your branch to only run the actions on push to the master
and develop
branches, as well as always for PRs.
Info: I added the secret CODECOV_TOKEN. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good for me, and mergeable when tests succeed.
We're discussing whether this is the right moment to merge this (also this would only show a 9% coverage from the pytests only
cbb076b
to
dd870fc
Compare
@dev-zero will you create an issue in codecov/codecov-action for the failure or maybe reopen codecov/codecov-action#22 ? |
It seems we need to update to |
38c8ec5
to
b4ac7e5
Compare
@CasperWA https://community.codecov.io/t/whitelist-github-action-servers-to-upload-without-a-token/491/5 ... Travis doesn't need a token because Codecov/Coveralls can verify the request via an API, but for GHA there's no API yet |
b4ac7e5
to
6ff1d69
Compare
Short summary: Coverage through codecov or coveralls is not possible until GitHub releases an API to query GitHub Actions such that codecov/coveralls can verify the uploader. Supposed to happen in Q1 2020. The secret token is for obvious reasons not available in a PR, only in builds initiated by direct commits on the repo (currently restricted to We have two options for now: disable coverage upload for pull requests or not fail the CI when uploading to coverage report fails. |
I think it doesn't really matter. |
edf6b5b
to
2aed43e
Compare
Codecov Report
@@ Coverage Diff @@
## develop #3618 +/- ##
==========================================
- Coverage 70.87% 69.2% -1.68%
==========================================
Files 458 458
Lines 33545 33766 +221
==========================================
- Hits 23775 23367 -408
- Misses 9770 10399 +629
Continue to review full report at Codecov.
|
Testing this in the branch As seen in the codecov bot comment here, the total coverage is 70.87 % - it doesn't seem to catch a lot of the database migration files/tests. Furthermore, anything that isn't in the realm of |
Yeah, 0% coverage for both the the django migrations and the sqlalchemy migrations. I wonder why...
Right, there one should be able to run it with something like |
It would be great if we could move forward with this. |
I think it's just because we are asking coverage to omit the whole folder (together with some more) in the Line 3 in 557a6a8
I'm not sure anymore why this was introduced in the first place (in any case, it was introduced when migrations were untested). Maybe we don't need to omit anything? You might want to just push a commit removing the omit line and check how things change. |
Great, thanks a lot - will look into this now |
54049f7
to
8e03e15
Compare
Removing the omissions specified in .coveragerc brings back coverage on migrations. To me, this PR is good to merge - does anybody still want to give another look? Finally, Casper is right that there are still two tests that don't report coverage: I'll have a look into moving the daemon test to pytest (in a separate PR) - that should not be a big deal. |
Good catch on this @giovannipizzi and @ltalirz !
If it's easily done, it wouldn't hurt? But if it doesn't change the coverage, there is no reason to do this. |
It should increase the coverage because for example the |
All right - I'll look into doing this - unless anyone else is already on top of it? (@ltalirz, @dev-zero ...) |
@sphuber Not sure whether what I wrote was clear - I meant I will move the @CasperWA If you prefer to do it instead, go ahead! |
Ah right! Yeah, sure, okay. I've already started some work on it now, so I'll continue, but can surely make a new PR for it. I'll just squash our contributions into 3 separate commits and then you're free to re-approve and merge. |
Only upload coverage for Py3.5
8e03e15
to
42d0cd5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks @CasperWA !
To note: Since codecov still does not support token-less uploads of coverage reports via GitHub Actions CI, the coverage will only be updated for a PR when it is merged (unless it's coming from an |
Yes, that's ok. I let you merge - not sure whether you preferred not to squash here... |
I already squashed (what I intended to squash), but for multiple contributions we usually keep a commit per contributor, right? (Calling @sphuber). |
If the contributions are significant, yes, I typically keep them. Sometimes, if an additional commit is really small though, one can opt to use Edit: to clarify, if you deem these commits worthwhile as being separate, by all means keep them and just rebase-merge 👍 fire away |
I went through them, and they all add the right amount of sugar - so they all stay 😃 |
No description provided.