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

1.0.5+ complains that solution file not exists. (centos 7) #9

Open
redochenzhen opened this issue Mar 16, 2021 · 5 comments
Open

1.0.5+ complains that solution file not exists. (centos 7) #9

redochenzhen opened this issue Mar 16, 2021 · 5 comments
Labels
bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed

Comments

@redochenzhen
Copy link

Here is the error message:
22:17:18 INF] Reading input file ReSharperReport.xml... Unhandled exception. System.IO.FileNotFoundException: Solution file /var/jenkins/workspace/Efficiency-COOP_sonar-test_qa/cop\Cop.sln does not exist

@redochenzhen redochenzhen changed the title 1.2.0+ complains about solution file not exists. 1.0.5+ complains that solution file not exists. (centos 7) Mar 16, 2021
@redochenzhen
Copy link
Author

This error is caused by the path format of my ReSharperReport.xml file.
like this: <Solution>cop/Cop.sln</Solution>

@olsh olsh self-assigned this Mar 17, 2021
@olsh olsh added the bug Something isn't working label Mar 17, 2021
@olsh olsh removed their assignment Mar 20, 2021
@olsh olsh added help wanted Extra attention is needed good first issue Good for newcomers labels Apr 4, 2021
@olsh
Copy link
Owner

olsh commented Apr 4, 2021

Hi @redochenzhen
Thank you for the feedback. I don't use R# CLT on *nix personally, so I'd be happy to accept a PR.

@olsh
Copy link
Owner

olsh commented Apr 21, 2021

Hi @redochenzhen,

I manage to reproduce the issue on WSL2 (Ubuntu).

There is actually a bug in R# CLT like you said here.

This error is caused by the path format of my ReSharperReport.xml file.
like this: cop/Cop.sln

I'd prefer not to fix it. Instead, I created an issue in the JetBrains tracker.
https://youtrack.jetbrains.com/issue/RSRP-484145

As a workaround, you can use -a switch for inspectcode command.
https://www.jetbrains.com/help/resharper/InspectCode.html#auxiliary-parameters

--absolute-paths (-a)— by default, files in InspectCode's report are written with paths relative to the solution file. You can use > this switch to have absolute paths in the report.

This way you'll get the correct directory separators in the R# report file.

Let's keep the issue open until the bug is resolved on the CLT side.

@kreghek
Copy link

kreghek commented Dec 27, 2021

Hi @redochenzhen,

I manage to reproduce the issue on WSL2 (Ubuntu).

There is actually a bug in R# CLT like you said here.

This error is caused by the path format of my ReSharperReport.xml file.
like this: cop/Cop.sln

I'd prefer not to fix it. Instead, I created an issue in the JetBrains tracker. https://youtrack.jetbrains.com/issue/RSRP-484145

As a workaround, you can use -a switch for inspectcode command. https://www.jetbrains.com/help/resharper/InspectCode.html#auxiliary-parameters

--absolute-paths (-a)— by default, files in InspectCode's report are written with paths relative to the solution file. You can use > this switch to have absolute paths in the report.

This way you'll get the correct directory separators in the R# report file.

Let's keep the issue open until the bug is resolved on the CLT side.

This solution leads to a error:
Unhandled exception. System.ArgumentException: Absolute paths are not allowed with -output, when converting a sln.

@olsh
Copy link
Owner

olsh commented Jan 30, 2022

Hi @kreghek
Can't reproduce the issue. I use the following command

./inspectcode.sh /project/path/Project.sln -o="/output/directory/result.xml" --no-build -a

The result.xml contains absolute paths.
JetBrains Inspect Code 2021.3.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants