Mono repo + Windows absolute paths?
dcharkes opened this issue · 3 comments
When generating coverage, the LCOV
files contain absolute paths. How this Coveralls convert these to relative paths?
We have a matrix build that uploads coverage for various builds:
[ ... ]
- name: Upload coverage
uses: coverallsapp/github-action@67662d24394fd74bffcf7b462d1b432814159afd
with:
flag-name: ${{ matrix.package }}-${{ matrix.os }}
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel: true
and in the end we signal we are done:
coverage-finished:
needs: [build]
runs-on: ubuntu-latest
steps:
- name: Upload coverage
uses: coverallsapp/github-action@67662d24394fd74bffcf7b462d1b432814159afd
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel-finished: true
In the coveralls UI, the MacOS/Linux paths are relative to current working directory, but this doesn't seem the case for the Windows build:
An older build seemed to work, but as far as I can see nothing changed in the configuration 🙊
For reference, the GitHub workflow configuration:
Upon inspection, all LCOV files we produce contain absolute paths everywhere.
That must mean there is some logic somewhere within Coveralls to convert these to relative paths. How does that logic work?
Should we be emitting LCOV files with relative paths instead to avoid these kinds of issues?
Or am I doing something else wrong in the configuration?
Feel free to leave a comment on dart-lang/native#16.
I think there's an issue with replacing the CWD in Windows, since data in LCOV contains slashes D:/a/project/path
, but current directory is returned with backslashes D:\a\project\path
. I think we can easily fix that, let me come back in 1-2 hours.
I think I've fixed that with a new release of coverage-reporter. Please, re-run the workflows, now paths should be the same across all OSes.
Sweet! https://coveralls.io/builds/59349527
Thanks for the super quick fix! 🚀