Skip to content
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

codecov-action doesn't upload the report from windows jobs with Cygwin #84

Closed
webknjaz opened this issue Oct 20, 2022 · 26 comments · Fixed by codecov/codecov-cli#390
Closed
Assignees
Labels
bug For issues and unexpected behaviors

Comments

@webknjaz
Copy link

Describe the bug

Despite this happening in an action, it feels like the source of the problem is somewhere in the uploader. It isn't clear why, though. It says that it failed to find a report file.
I've added a debug action, connected via SSH and verified that it's there. Adding an absolute path via files: doesn't help either.
I've got an impression that the uploader gets lost in the file system and can't figure out what is the working directory currently.

To Reproduce

Not sure, but maybe this is influenced by the fact that cygwin/cygwin-install-action@v1 was used. See: https://github.com/webknjaz/setuptools/actions/runs/3286018301/workflow#L98.

Expected behavior

The coverage report should be found and uploaded.

Screenshots

https://github.com/webknjaz/setuptools/actions/runs/3286018301/jobs/5413676087#step:7:25

@webknjaz webknjaz added the bug For issues and unexpected behaviors label Oct 20, 2022
@webknjaz
Copy link
Author

@drazisil-codecov could you take a look? 🙏
I'm a bit lost here.

@webknjaz
Copy link
Author

webknjaz commented Dec 1, 2022

Hey @thomasrockhu-codecov! Is there any chance somebody could check this? I know you must have your hands full right now, but it's a bummer that codecov is mafunctioning under Cygwin...

@thomasrockhu-codecov
Copy link
Contributor

Hi @webknjaz, do you mind opening a topic in our community boards? We track that much more closely.

@webknjaz
Copy link
Author

@thomasrockhu-codecov I opened it but now I see that "Community board archiving" banner. If I'm supposed to use that feedback repo, could you re-open this issue and perform an issue transfer there?

@thomasrockhu-codecov thomasrockhu-codecov transferred this issue from codecov/uploader Sep 26, 2023
@covecod covecod bot moved this to Waiting for: Product Owner in GitHub Issues with 👀 Sep 26, 2023
@joseph-sentry
Copy link

It looks to me like this issue was fixed by codecov/uploader#1099 being included in 0.6.3 of the uploader. For example: https://github.com/pypa/setuptools/actions/runs/6509597578/job/17681443663 was able to find the coverage file.

@webknjaz
Copy link
Author

@joseph-sentry that job uses files: ${{ github.workspace }}\coverage.xml. We should probably check if auto-detection works too...

@webknjaz
Copy link
Author

Made pypa/setuptools#4092 to verify this.

@webknjaz
Copy link
Author

@joseph-sentry
Copy link

@webknjaz thanks for verifying this, I can see that the auto-detection is broken in that example run, I'll reopen this issue

@webknjaz
Copy link
Author

@joseph-sentry yep, was about to post the link to this line: https://github.com/pypa/setuptools/actions/runs/6646525754/job/18060155444?pr=4092#step:7:32.

Posting the log excerpt, since old logs tend to get garbage-collected over time and that link will return 404 at some point.

Run codecov/codecov-action@v3
  with:
    flags: CI-GHA, test_cygwin, OS-Windows, VM-windows-latest, Py-3.9.16
  env:
    FORCE_COLOR: 1
    PIP_DISABLE_PIP_VERSION_CHECK: true
    PIP_NO_PYTHON_VERSION_WARNING: true
    PIP_NO_WARN_SCRIPT_LOCATION: true
    TOX_OVERRIDE: testenv.pass_env+=GITHUB_*,FORCE_COLOR
==> windows OS detected
https://uploader.codecov.io/latest/windows/codecov.exe.SHA256SUM
==> SHASUM file signed by key id 806bb28aed779869
==> Uploader SHASUM verified (a443ec64c6c44e3b4fe6244418ef635abe044db490abbd161d7f2872cdd4c447  codecov.exe)
==> Running version latest
==> Running version v0.7.1
D:\a\_actions\codecov\codecov-action\v3\dist\codecov.exe -n "" -Q github-action-3.1.4 -F CI-GHA -F test_cygwin -F OS-Windows -F VM-windows-latest -F Py-3.9.16 -C 3aaf00b34ba860edff61ab968d4687345fd4ab1e
[2023-10-25T22:12:53.774Z] ['info'] 
     _____          _
    / ____|        | |
   | |     ___   __| | ___  ___ _____   __
   | |    / _ \ / _` |/ _ \/ __/ _ \ \ / /
   | |___| (_) | (_| |  __/ (_| (_) \ V /
    \_____\___/ \__,_|\___|\___\___/ \_/

  Codecov report uploader 0.7.1
[2023-10-25T22:12:53.806Z] ['info'] => Project root located at: /cygdrive/d/a/setuptools/setuptools
[2023-10-25T22:12:53.807Z] ['info'] -> No token specified or token is empty
[2023-10-25T22:12:53.841Z] ['info'] Searching for coverage files...
[2023-10-25T22:12:53.856Z] ['info'] Warning: Some files located via search were excluded from upload.
[2023-10-25T22:12:53.856Z] ['error'] There was an error running the uploader: No coverage files located, please try use `-f`, or change the project root with `-R`
[2023-10-25T22:12:53.856Z] ['info'] If Codecov did not locate your files, please review https://docs.codecov.com/docs/supported-report-formats

@webknjaz
Copy link
Author

@joseph-sentry that https://github.com/apps/codecov-hooky bot keeps auto-closing the issue. Does it need a special label or something to remain open?

@trent-codecov trent-codecov reopened this Oct 26, 2023
@trent-codecov
Copy link

@webknjaz We use GitHub projects for organization of issues. Hooky is configured to close issues that are marked done. Probably room for improvement in the aggressiveness off the closing. @joseph-sentry moved it back to Todo so it will remain open now.

@webknjaz
Copy link
Author

webknjaz commented Feb 2, 2024

@thomasrockhu-codecov no, that problem was because of a missing comma and the log not making it obvious: aio-libs/multidict@49212ce.

But there's another problem with the config file discovery.

@thomasrockhu-codecov
Copy link
Contributor

@webknjaz I am still skeptical that it's just the missing comma. I was able to reproduce your issue locally, and after moving it to another folder it was fine.

Config file discovery is a known issue we are fixing.

@webknjaz
Copy link
Author

webknjaz commented Feb 2, 2024

@thomasrockhu-codecov thomasrockhu-codecov self-assigned this Feb 2, 2024
@webknjaz
Copy link
Author

webknjaz commented Feb 3, 2024

FTR the original issue wasn't related to .tox, only the last one is.

@thomasrockhu-codecov
Copy link
Contributor

thomasrockhu-codecov commented Feb 27, 2024

@webknjaz a possible workaround is to do

  directory: .tox

You can see the action picking up the files here

I'm trying to understand still what is happening and why it's not working as intended

@webknjaz
Copy link
Author

it's still failing: https://github.com/aio-libs/multidict/actions/runs/7749429694/job/21133959885#step:8:63.

Verified that restarting that job succeeded detecting the reports and uploading them.

@thomasrockhu
Copy link

@webknjaz awesome, thanks for your patience on this one. Glad to get it fixed for you.

@webknjaz
Copy link
Author

webknjaz commented Feb 28, 2024

@thomasrockhu so I also attempted verifying the original problem @ pypa/setuptools#4092 and it revealed another issue. The discovery and upload succeeds now: https://github.com/pypa/setuptools/actions/runs/8074076353/job/22058819583?pr=4092#step:7:54

However, this time, the Codecov service claims that it can't process said report — https://app.codecov.io/github/pypa/setuptools/commit/0bfc2bbd028aa2a38f4c7c832e562350f7e05713.

@thomasrockhu-codecov mind taking a look to see where it's corrupted?

@drazisil-codecov
Copy link

@thomasrockhu-codecov I think knowing that codecov/engineering-team#1112 exists might save you some time in this case

@thomasrockhu-codecov
Copy link
Contributor

@webknjaz sorry for the delay here. I took a look at a newer commit here and didn't notice the processing issue on any of the uploads for the commit. Are you still running into the issue?

@thomasrockhu-codecov
Copy link
Contributor

@webknjaz going to close out for now, please open if you need support or create a new issue.

webknjaz added a commit to webknjaz/setuptools that referenced this issue Apr 16, 2024
webknjaz added a commit to webknjaz/setuptools that referenced this issue Apr 19, 2024
webknjaz added a commit to webknjaz/setuptools that referenced this issue Apr 28, 2024
webknjaz added a commit to webknjaz/setuptools that referenced this issue Apr 29, 2024
webknjaz added a commit to webknjaz/setuptools that referenced this issue Jun 26, 2024
@webknjaz
Copy link
Author

webknjaz commented Jun 26, 2024

UPD: I finally found time to check again and pypa/setuptools#4092 finally works! (https://github.com/pypa/setuptools/actions/runs/9684258424/job/26721584269?pr=4092#step:7:58) Not sure when exactly it got fixed, though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug For issues and unexpected behaviors
Projects
Status: Waiting for: Product Owner
Development

Successfully merging a pull request may close this issue.

6 participants