I have at least a few files that have the same name in different folders, codecov is having trouble opening it I guess, I have a lot of “cannot open source file” in the log file. I feel that this might be a bug, please move the post if it isn’t.
It’s possible to see the file in the github folder, but it does not appear in the report at all, this happens in a few other folders of the project and it always happens with this file (aap.cpp) that has the same name but the code is obviously different.
I tried to do this fix
but it didn’t work, can anyone help me please? thanks!
I ran with -X gcov but I didn’t undestand what you mean by SHA after… our last commit is:
dc17e12f519a2023a787cfd2a56c18f82b0abfda
I get this message when I run with -X gcov
No CI provider detected.
Testing inside Docker? Testing with Docker
Testing with Tox? Python
project root: .
./codecov.sh: line 887: hg: command not found
Yaml not found, that’s ok! Learn more at About the Codecov YAML
==> gcov disabled
==> Python coveragepy not found
==> Searching for coverage reports in:
+ .
→ No coverage report found.
Please visit Codecov uploader and supported languages
There some other odd issues, this file in the image bellow is at the root of the project in the codecov dashboard, but it’s actually located in a completely different folder (I would show with more pictures, but I can’t post more than 1 picture yet). If I click on the link, I get a 404 page.
The only thing in common with all those issues is that those files have the same/similar name, this sl_be.cpp actually has a SL_BE.cpp file (just the case is different) that is located in the root… the lowercase sl_be.cpp is inside the folder “adhoc_utilities/sl_be/”.
yes, the reports do exist, I can see them in the log like this:
2020-01-22T16:02:28.8275921Z File ‘aap.cpp’
2020-01-22T16:02:28.8276195Z Lines executed:85.92% of 4027
2020-01-22T16:02:28.8276292Z Branches executed:92.23% of 10496
2020-01-22T16:02:28.8276548Z Taken at least once:51.86% of 10496
2020-01-22T16:02:28.8276640Z Calls executed:88.76% of 5923
2020-01-22T16:02:28.8276861Z Creating ‘aap.cpp.gcov’
Similar lines for the other files with the same name are also in the log, so I imagine that the app.cpp.gcov is being created as expected.
The part where we run the bash upload is a separate job.
I think that’s why you were getting the file errors before. I don’t personally use it, but I believe the gcov tool needs to match the reports against the files to generate the coverage report needed. I would ask if you can take out the -X gcov flag and try running the uploader in a job that has both the reports and source code to see if you still have errors.