SonarScanner VSTS Extension no longer scanning C#

@mickaelcaro - Were in the progress of getting a new instance setup with that version however it may take a while to setup as we have to speak with other teams internally to get firewall rules applied etc…

Is there anything else in the meantime we can do to try do to troubleshoot further on the current version?

@mickaelcaro - I’m still working on trying to get a build running on a later version - Facing a few other issues not related.

Is there anything else we can try in the meantime on the current version ?

Hi @ArronH

I’m sorry i’m not in full time searching for a solution here, i might be able to work on it end of this week.

I don’t see any obvious workaround of test to do here, i’ll let you know if i find one.

Sorry for the inconvenience !

Mickaël

Hi @mickaelcaro - I’ve ran a build on the SonarQube version you mentioned and it still scans C# so it looks like the latest version of the sonar tfs extension isn’t compatible with the current version of our SonarQube instance. We’ll look to upgrade this.

Thanks for the help.

Hi @ArronH

Glad it works with that version. However i need to know on my side what is causing this. I’m running out of time these day to look at that but i’ll do my best.

Would you be able to send me a reproducer maybe ? That would be super helpful.

Mickaël

Hi @mickaelcaro

It would be good to find out what the issue is and potentially fix/provide a workaround for this SonarQube version as we haven’t upgraded our instance for a while so we’re not fully prepared at the moment to do this on our production instance.

Regarding sending you a reproducer - Can I just check you’re referring to this C++ developers now benefit from more efficient analysis and deeper Core Guidelines coverage ? - If so I’m assuming I should run this on our current version where the code fails to scan C#. How would I enable this , would just adding ’ sonar.cfamily.reproducer=true’ to a the variable within the tfs build be sufficient?

@mickaelcaro - I’m trying now to add that variable. Looks like I should be adding a path to the variable value as suggested here https://jira.sonarsource.com/browse/CPP-850 rather than =true so I’m trying that now however if the step doesn’t fail (which it doesn’t) will this fail to output this file ?

That didn’t seem to output any file when specifying a location on the variable. I’ll await your reply to advise before doing any other actions :slight_smile: - Thanks

Hi @ArronH

No it’s not that, i was just seeking for a sample project that reproduce this issue.

Mickaël

Hi @mickaelcaro - I wouldn’t be able to share our code with you I’m afraid (I think that’s the ask?). Do you have any projects internally that you can use ? I would have thought the issue would occur with any C# projects that use the version of SonarQube we are using (v6.7.4) and the latest tfs extension (v4.17.0).

Yep. No problem, thanks anyway !

Hi @ArronH

I’m currently trying to investigate this issue (finally ! ) Can you please give me the version of the C# analyzer you have currently installed on your SQ 6.7 instance please ?

Thanks !

Hi @mickaelcaro

Were using v6.5 (build 3766). Let me know if you need anything else.

Thanks

Is that a possibility for you to update this analyzer to at least version 6.7 ?

Yeah should be able to. I’ll try get a test instance on the same version today and test it on that. Will keep you updated on my progress :slight_smile:

1 Like

Thanks, on my side i was able to “fix” the issue by upgrading the analyzer version, so i think that’s worth the test.

That sounds promising :slight_smile: - Thanks for investigating. Will let you know the outcome

@mickaelcaro Are you able to send me or provide a link to where I can find v6.7 of that plugin please . I can’t find it at the moment

yep, you can find it here : https://github.com/SonarSource/sonar-dotnet/releases/tag/6.7.0.4267

Download the .jar and replace it in the plugins folder of your SQ instance

Thanks for that. I’ve just ran a build on a test instance using that version and it’s successfully scanned C# code now :slight_smile: - I’ll upgrade the plugin to this version on our production instance.

Thanks for all your help with this !