Thanks for the information, I will get back to you once I have some ideas on how to do it
I assume this might be a problem that has no “one” perfect approach that will work every time ?
Maybe it could be useful if the user could choose the preferred approach via the settings.json ?
Like choosing one of :
- Default behaviour ( First encountered source file sets the Root )
- Setting the Root manually
- Getting the Root from Startup Project
- Getting the Root from the SLN location
- Getting the Root from some defined variable in the SLN
- Possibly some other ways that make sense ?
Just throwing some random ideas around.
Hi. I have been busy with other tasks, so unfortunately did not have time to look into this. On the surface, providing a setting does look like a reasonable workaround, but I also wanted to spend some time exploring more general-case solutions. I can’t give you a timeline at the moment. For now, you can rollback to version 9.6, as that was the one before we made the changes to the file listing and deterministic root calculation
No worries. Not trying to be pushy or anything, just dropping random ideas ![]()
Thanks for all the support ![]()
Hi. Can you check if this works? SLVS-2918 WIP: use absolute paths instead of ide relative paths · SonarSource/sonarlint-visualstudio@7a414c7 · GitHub
I tried it in a few projects and it indeed seems to work in all of them now.
Those where the SLN is on the same drive, and where the SLN is on a different one, now work.
Nice ![]()
Thank you for validating it.
It’s a bit of a tricky change, so it may take some time to validate it doesn’t break anything/make it opt-in at first. Maybe it will be part of the next release in 2 weeks, not sure at the moment.
Hm, i just know that the change to require the SLN to be on the same drive as the Code now breaks SonarQube on all my out of source builds. So SonarQube is a bit unusable for my personal projects atm.
I hope this new fix will make it in sometime, opt-in seems to be a good solution.
Hi. I made some changes to add the opt-in option. It’s better to apply it before opening the project/reopen just after applying it