-
Notifications
You must be signed in to change notification settings - Fork 92
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
remotePathResolve not working on VS Code Windows with a coverage.xml file using Unix paths #400
Comments
@denisrossetre Thanks for the ticket! Are you able to grab more logs from the extension output log area? In terms of extra logging, check out this area, and you could maybe remove the vscode-coverage-gutters/src/coverage-system/coverageservice.ts Lines 101 to 105 in c15ac1a
|
Actually, I solved the problem! The thing is that the path parsing will be done on a Unix path in a Windows system. By changing the value To close this issue, I'd like to write a bit of documentation for the |
I am glad you got it figured out 👍🏻 ! I think the tips and tricks section would be a good fit? It gets great SEO from being on the front page + in the marketplace. |
@denisrossetre I'm encountering the same issue that you were -- I'm using Windows 10, and I have a docker container running Linux, but coverage gutters isn't showing the code coverage in VSC. I tried using your fix, here is my settings.json "coverage-gutters.coverageFileNames": [
"coverage.xml",
"lcov.info",
"cov.xml",
"jacoco.xml"
],
"coverage-gutters.remotePathResolve": [
[
"\\home\\dev\\Mxxxx",
"."
]
] The In the CG log I see this:
so I know that it's picking up my coverage file, but there's just still no visual indication on the file, and the bottom bar still shows "No coverage". Did you end up having to do anything else other than changing this setting, to fix the issue? I'm running Coverage Gutters v2.11.0 |
@ralittl Hmm I think you might want to try one level of array instead? Also, once you get the system working, try out the watch button in the bottom status bar and you should get an output similar to the following:
|
Describe the bug
remotePathResolve does not seem to work when having a
coverage.xml
file with Unix paths and the VS Code Coverage Gutters extension running on Windows.To Reproduce
coverage.xml
file. The coverage file has a line<sources><source>/opt/myproject</source></sources>
and the rest of the paths are relative (in the<package name="src.module">
XML entities)."coverage-gutters.remotePathResolve": ["/opt/local", "c:/Users/myusername/projects/myprojectname"],
in the VS Codesettings.json
file.Note that the extension works when replacing
<sources><source>/opt/myproject</source></sources>
by<sources><source>.</source></sources>
and removing theremotePathResolve
setting.Expected behaviour
Coverage shows.
Screenshots
No screenshots because of nature of the code. I could provide a reproducible example if needed.
Desktop (please complete the following information):
Additional context
I'd be very happy to get extra logs about how the coverage.xml path is interpreted and when/if it is translated by
remotePathResolve
. Right now, I'm debugging in the dark.The text was updated successfully, but these errors were encountered: