-
Notifications
You must be signed in to change notification settings - Fork 43
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
[BUG] Uploading test results from GitHub Actions CI/CD fails (in some repos) #486
Comments
The repo in question is now public, and the uploads are still failing the same way: https://github.com/ansible/awx-plugins/actions/runs/10581340011/job/29318439675#step:23:47. @thomasrockhu-codecov any chance you could take a look? The token is set in the config file rather than a secret. The coverage upload succeeds, the tests upload fails. |
UPD: I tried it out locally with an editable installation of this repo. I added an entry point to https://github.com/codecov/codecov-cli/blob/ae3fc7e/codecov_cli/helpers/request.py#L160 and it succeeded! $ some-venv-py313/bin/codecovcli do-upload -f .tox/.tmp/.test-results/pytest-3.13/test.xml -F local-debugging --report-type test_results
info - 2024-08-27 18:24:31,788 -- ci service found: local
info - 2024-08-27 18:24:32,481 -- Found 1 test_results files to report
info - 2024-08-27 18:24:32,481 -- > ~/src/github/ansible/awx-plugins/.tox/.tmp/.test-results/pytest-3.13/test.xml
info - 2024-08-27 18:24:33,794 -- Process Upload complete The obvious difference in the log is - info - 2024-08-20 20:25:50,370 -- ci service found: github-actions
+ info - 2024-08-27 18:24:31,788 -- ci service found: local which leaves me puzzled... What could influence the process @ GHA env that's not present locally? |
Extra observation: the job is in a reusable workflow and does not have a Git checkout (the source is coming from an sdist file). |
hi @webknjaz, i'm looking into this, I think you're right that this issue is due to something going wrong on the backend. I think I have a fix for it here: codecov/codecov-api#779 explanation: I was using the "git_service" arg of the upload instead of the "ci_service" param, ci_service is usually automatically set, i think git_service depends on you uploading from a git repo. This should at least fix the current |
Got it, thanks! |
I don't actually know if it's because the repo is private, that's just a wild guess.
Here's the log:
I'm not reporting the bug against the action repo because I see in the log that it fails within codecov-cli. The junit file is produced by pytest and is found correctly. However, uploading fails with a
This field may not be null.
which suspiciously reminds me of errors Django would generate when working with the DB.So my assumption is that the error is coming from the backend, which isn't something I'd be able to debug myself.
Hopefully, this gives you a good starting point. Let me know if you want some additional repro details!
The text was updated successfully, but these errors were encountered: