SonarScanner dependencies unpack incorrectly Linux

Hi,

I am using sonarscanner on a linux build agent for azure pipelines. My build was failing because the sonarscanner unpacks it’s dependencies incorrectly. The project uses c# with dotnet core 2.2.

Scenario:

  1. The zip files get extracted to /tmp/.sonarscanner/resources/{0, 1, 2, 3}.
  2. The any directories that get extracted use backslashes in their path: “analyzers\dotnet\cs\CodeCracker.Common.dll”
  3. Linux then treats the whole file path as a single file.
  4. The build complains because it can’t find the resources

I’ve currently worked around this by unzipping the archives correctly using the unzip command. However it would be preferred if this wasn’t an issue in the first place.

1 Like

Hi @PythonPlusPlus. Welcome to the community.

You’re using the third-party CodeCracker plugin, is that correct?

If so, I think the problem is with how the plugin jar was created. I’ve created sonarqube-roslyn-sdk issue #128 to track it.

That’s probably correct. If that’s the case I will need to make sure that the installed version of the plugin is up to date.

Thank you for looking into my ticket.