olsh / dotnet-reqube Goto Github PK
View Code? Open in Web Editor NEW.NET Core global tool that converts ReSharper inspect code report to SonarQube format
License: MIT License
.NET Core global tool that converts ReSharper inspect code report to SonarQube format
License: MIT License
Resharper codeinspect does not generate an XML for all my projects in the solution as some of the projects have no issues. Because of that the upload to SonarQube fails because it expects an generated json in all the project folders. So I get the error failed to read external issues report.
Anyone else who experienced this and knows how to deal with this?
Hi,
I have two questions/suggestions regarding the mapping of severity as defined in "Constants.cs":
{ "ERROR", "BLOCKER" }, { "WARNING", "CRITICAL" }, { "SUGGESTION", "MAJOR" }, { "HINT", "MINOR" }, { "INFO", "INFO" }
According to ReSharpers documentation, it does not use "INFO". So why is there a mapping from INFO to INFO? (https://www.jetbrains.com/help/resharper/Code_Analysis__Code_Inspections.html#severity)
The mapping from WARNING to CRITICAL seems like an escalation to me. R# WARNINGs "represent serious coding inefficiencies" while a SonarQube CRITICAL item might "cause the application to crash or to corrupt stored data". In my humble opinion, MAJOR would be a better fit for WARNING, althought still not 100% exact because of the different semantics behind the two calssifications. (https://docs.sonarqube.org/7.4/user-guide/rules/)
Greetings
PS: Thanks for sharing this useful tool with the public, I really appreciate it.
Hi,
With latest version, I got the following error with my code :
"SonarQube C# Analysis Fails to 'Not a Valid Line Offset for Pointer'"
It looks like the convertion to sonar does not compute correct end of line.
Here is resharper line :
<Issue TypeId="RedundantUsingDirective" File="src\CampaignManagement.api\Controllers\v1\BlacklistController.cs" Offset="174-215" Line="7" Message="Using directive is not required by the code and can be safely removed" />
It is converted to :
"engineId":"R#",
"primaryLocation":{
"filePath":"D:\\Projects\\git\\CampainManagement.api\\src\\CampaignManagement.api\\Controllers\\v1\\BlacklistController.cs",
"message":"Using directive is not required by the code and can be safely removed",
"textRange":{
"endColumn":42,
"endLine":7,
"startColumn":1,
"startLine":7
}
},
"ruleId":"RedundantUsingDirective",
"severity":"MAJOR",
"type":"CODE_SMELL"
}```
End of column should be 41 not 42.
Dear @olsh,
please release the master branch to Nuget in order to use this package with the latest changes (bump .NET version to 6.0).
Thanks in advance!
Unhandled exception. System.ArgumentException: An item with the same key has already been added. Key: ElasticSearchIndexer
at System.Collections.Generic.Dictionary`2.TryInsert(TKey key, TValue value, InsertionBehavior behavior)
at System.Collections.Generic.Dictionary`2.Add(TKey key, TValue value)
at ReQube.SonarConverter.WriteReport(String filePath, ISonarReport sonarReport) in C:\projects\reqube\src\dotnet-reqube\SonarConverter.cs:line 272
at ReQube.SonarConverter.ConvertSolution(Report report, Options options) in C:\projects\reqube\src\dotnet-reqube\SonarConverter.cs:line 198
at ReQube.SonarConverter.Convert() in C:\projects\reqube\src\dotnet-reqube\SonarConverter.cs:line 60
at ReQube.Program.<Run>b__1_0(Options options) in C:\projects\reqube\src\dotnet-reqube\Program.cs:line 24
at CommandLine.ParserResultExtensions.WithParsed[T](ParserResult`1 result, Action`1 action)
at ReQube.Program.Run(String[] args) in C:\projects\reqube\src\dotnet-reqube\Program.cs:line 23
at ReQube.Program.Main(String[] args) in C:\projects\reqube\src\dotnet-reqube\Program.cs:line 19
PS C:\Users\PavelAgejkin\Downloads\jetbrains.com\JetBrains.ReSharper.CommandLineTools.2022.1.2> s
I have solution with two ElasticSearchIndexer projects.
One in folder Services and one in root folder.
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
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.