-
-
Notifications
You must be signed in to change notification settings - Fork 25.8k
CI Update codecov uploader to 0.7.1 #28361
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
Conversation
Unfortunately not all codecov step pass, even with this update. For future reference, here is the error message (here for the
So we get a 503 error which hints at a permission problem. But on the same build, we do also get successful codecov uploads such as
So this kind of weird because I don't think we have per-job permission settings that could explain this discrepancy. |
I am guessing this is some random codecov server issues. They seem to happen more often recently i.e. seen at least in this PR and #28348. |
The status page of codecov is all green: and I could not find any issue with the 503 error code in the codecov uploader issue tracker: |
This gave me a lot of headache on We ended up fixing the issue by including the upload token as plain text in the repo / CI config, and then never saw the issue again. Since this token is only used to upload coverage, and w/o the token one can upload coverage anyway, I don't see any security risks in it. |
As far as I can see we are passing the token. Also codecov is used from Azure Pipelines but and the discussion you linked to seems to be specifically about codecov being used inside Github Actions. Not sure what is going on, let's wait and see ... |
The issue AFAIK is that the token used by default reaches limits and upload fails. That's why having a hard coded token works. |
Interesting. Let me try to see if I can generate a new version of the token an update the matching Azure Pipelines secret env variable for |
Ok I did it. I got an error message from codecov the first time I tried to press the "regenerate token" button but it worked after waiting a bit and doing a page refresh. I updated the Azure Pipelines |
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.
I'm happy with updating the uploader in any case. Let see if @ogrisel push is successful.
🤔 looks like there is an issue with the new token? See build log:
|
Maybe I made a mistake when setting up the |
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.
Finally all green!
Not sure about why hard-coding a token in the config file vs passing it as an env variable would avoid this buggy rate limited-related errors. Anyways, it works for now. If it means we need to rotate the token twice a year, I think it's bearable (once you know that those errors can be fixed by rotating the token). |
For me the issue was that I thought the secret was available, but it was empty in PRs, and making them available in GH actions is a pain. |
Alright so this was probably a different issue because here the logs never suggested that the env variable was empty or undefined. |
Co-authored-by: Olivier Grisel <olivier.grisel@ensta.org>
Co-authored-by: Olivier Grisel <olivier.grisel@ensta.org>
Co-authored-by: Olivier Grisel <olivier.grisel@ensta.org>
This may get rid of some codecov upload issues that we see from time to time.
For example retry is done in more cases here codecov/uploader#1203, which is released in 0.6.3 and we use 0.4.1.
The kind of errors that were seen in #28348: