Issue with "Open in IDE" Feature in .Net Framework Solution on SonarQube

I recently analyzed a new .Net Framework solution using our self-hosted SonarQube server. While trying to use the “Open in IDE” feature to navigate to issues within Visual Studio, I encountered the following problems:

  1. Error: Value cannot be null For some issues, Visual Studio fails to open the corresponding file. In the Visual Studio output window, the following error is displayed:
Bringing IDE to front...
[Open in IDE] Unable to convert issue data: Value cannot be null.
Parameter name: text
  1. Incorrect File Path For other issues, Visual Studio reports that the file cannot be found. Upon investigation, I noticed that SonarQube is looking for the file in the wrong directory. Here’s an example:
  • Path in SonarQube Server:
    Audit\Audit\Action\ReportComposition.cs
  • Path Visual Studio Looks For:
    E:\Audit\Audit\Action\ReportComposition.cs
  • Actual File Path:
    E:\Projects\flirt\Audit\Audit\Action\ReportComposition.csIt appears that SonarQube is calculating the file path incorrectly, omitting the first two parent folders.

The solution file is located in E:\Projects\flirt\

Steps to Reproduce:

  1. Analyze a .Net Framework solution using a self-hosted SonarQube server.
  2. Open an issue in the SonarQube UI.
  3. Click the “Open in IDE” option for the issue.
  4. Observe the following:
  • For some issues, the error: Value cannot be null. Parameter name: text appears.
  • For other issues, Visual Studio fails to locate the file because the file path is incorrect.

Expected Behavior:

  • Visual Studio should successfully open the issue file in the correct location without errors.
  • SonarQube should calculate the file path correctly based on the actual project structure.

Environment Details:

  • SonarQube Version: Developer Edition 10.8 and v2025.1
  • Sonar Scanner Version: 9.0.2
  • Visual Studio Version: 17.12.4
  • SonarQube Deployment Method: Deployed from ZIP

Hello @Fiplan!

First of all, welcome to our community! :sonar:

To be able to dig deeper into the problem, could you please provide us with some more information:

  • What version of SonarQube for Visual Studio (formerly SonarLint) are you using?
    You can find that by navigating to SonarQube for Visual Studio -> Help -> About SonarQube for VisualStudio menu.

  • What issue in particular are you trying to open? In SonarQube Server you can see that at the top, in the issue page:
    image

  • Could you provide us the verbose logs?

Hello Gabriela,

The version of SonarQube for Visual Studio 8.10.0.11758

For the issue “Unable to convert issue data: Value cannot be null”

Issue type:

Make sure using a dynamically formatted SQL query is safe here.
Formatting SQL queries is security-sensitive csharpsquid:S2077

Log:

[DEBUG] [ThreadId 99] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] Assist connection and binding if needed for project Flirt and server http://appserver09:9000
[DEBUG] [ThreadId 99] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] GET 200 http://appserver09:9000/api/system/status | response time=30ms
[DEBUG] [ThreadId 99] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] Downloaded server infos in 30ms
[DEBUG] [ThreadId 90] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] GET 200 http://appserver09:9000/api/hotspots/show.protobuf?hotspot=e61f86a1-1d3f-4dce-972d-09de3ffb7958 | response time=31ms
[DEBUG] [ThreadId 104] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] GET 404 http://appserver09:9000/api/sources/raw?key=Flirt%3AAudit%2FFiplan.Audit.DB%2FConcrete%2FNLSSettings.cs | response time=22ms
[DEBUG] [ThreadId 104] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] Unable to fetch source code of 'Flirt:Audit/Fiplan.Audit.DB/Concrete/NLSSettings.cs'
[DEBUG] [ThreadId 104] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] org.sonarsource.sonarlint.core.serverapi.exception.NotFoundException: Error 404 on http://appserver09:9000/api/sources/raw?key=Flirt%3AAudit%2FFiplan.Audit.DB%2FConcrete%2FNLSSettings.cs
	at org.sonarsource.sonarlint.core.serverapi.ServerApiHelper.handleError(ServerApiHelper.java:148)
	at org.sonarsource.sonarlint.core.serverapi.ServerApiHelper.get(ServerApiHelper.java:74)
	at org.sonarsource.sonarlint.core.serverapi.source.SourceApi.getRawSourceCode(SourceApi.java:47)
	at org.sonarsource.sonarlint.core.serverapi.hotspot.HotspotApi.fetch(HotspotApi.java:192)
	at org.sonarsource.sonarlint.core.embedded.server.ShowHotspotRequestHandler.tryFetchHotspot(ShowHotspotRequestHandler.java:113)
	at org.sonarsource.sonarlint.core.embedded.server.ShowHotspotRequestHandler.showHotspotForScope(ShowHotspotRequestHandler.java:98)
	at org.sonarsource.sonarlint.core.embedded.server.ShowHotspotRequestHandler.lambda$handle$0(ShowHotspotRequestHandler.java:89)
	at org.sonarsource.sonarlint.core.embedded.server.RequestHandlerBindingAssistant.assistBindingIfNeeded(RequestHandlerBindingAssistant.java:172)
	at org.sonarsource.sonarlint.core.embedded.server.RequestHandlerBindingAssistant.assistConnectionAndBindingIfNeeded(RequestHandlerBindingAssistant.java:123)
	at org.sonarsource.sonarlint.core.embedded.server.RequestHandlerBindingAssistant.lambda$assistConnectionAndBindingIfNeededAsync$1(RequestHandlerBindingAssistant.java:92)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
	at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
	at java.base/java.lang.Thread.run(Unknown Source)

[ThreadId 104] [Open in IDE] Processing request. Configuration scope: FLIRT .NET pack, Key: e61f86a1-1d3f-4dce-972d-09de3ffb7958, Type: Hotspot
[ThreadId 104] Bringing IDE to front...
[DEBUG] [ThreadId 104] SetForegroundWindow call failed. Last error code: 0
[DEBUG] [ThreadId 104] Issue: HotspotDetailsDto { key = e61f86a1-1d3f-4dce-972d-09de3ffb7958, message = Make sure using a dynamically formatted SQL query is safe here., ideFilePath = Audit\Fiplan.Audit.DB\Concrete\NLSSettings.cs, textRange = TextRangeDto { startLine = 40, startLineOffset = 16, endLine = 40, endLineOffset = 31 }, author = a.s.marchouk@hotmail.com, status = REVIEWED, resolution = SAFE, rule = HotspotRuleDto { key = csharpsquid:S2077, name = Formatting SQL queries is security-sensitive, securityCategory = sql-injection, vulnerabilityProbability = HIGH, riskDescription = <p>Formatted SQL queries can be difficult to maintain, debug and can increase the risk of SQL injection when concatenating untrusted values into the
query. However, this rule doesn’t detect SQL injections (unlike rule {rule:csharpsquid:S3649}), the goal is only to highlight complex/formatted
queries.</p>
, vulnerabilityDescription = <h2>Ask Yourself Whether</h2>
<ul>
  <li> Some parts of the query come from untrusted values (like user inputs). </li>
  <li> The query is repeated/duplicated in other parts of the code. </li>
  <li> The application must support different types of relational databases. </li>
</ul>
<p>There is a risk if you answered yes to any of those questions.</p>
<h2>Sensitive Code Example</h2>
<pre>
public void Foo(DbContext context, string query, string param)
{
    string sensitiveQuery = string.Concat(query, param);
    context.Database.ExecuteSqlCommand(sensitiveQuery); // Sensitive
    context.Query&lt;User&gt;().FromSql(sensitiveQuery); // Sensitive

    context.Database.ExecuteSqlCommand($"SELECT * FROM mytable WHERE mycol={value}", param); // Sensitive, the FormattableString is evaluated and converted to RawSqlString
    string query = $"SELECT * FROM mytable WHERE mycol={param}";
    context.Database.ExecuteSqlCommand(query); // Sensitive, the FormattableString has already been evaluated, it won't be converted to a parametrized query.
}

public void Bar(SqlConnection connection, string param)
{
    SqlCommand command;
    string sensitiveQuery = string.Format("INSERT INTO Users (name) VALUES (\"{0}\")", param);
    command = new SqlCommand(sensitiveQuery); // Sensitive

    command.CommandText = sensitiveQuery; // Sensitive

    SqlDataAdapter adapter;
    adapter = new SqlDataAdapter(sensitiveQuery, connection); // Sensitive
}
</pre>
, fixRecommendations = <h2>Recommended Secure Coding Practices</h2>
<ul>
  <li> Use <a href="https://cheatsheetseries.owasp.org/cheatsheets/Query_Parameterization_Cheat_Sheet.html">parameterized queries, prepared
  statements, or stored procedures</a> and bind variables to SQL query parameters. </li>
  <li> Consider using ORM frameworks if there is a need to have an abstract layer to access data. </li>
</ul>
<h2>Compliant Solution</h2>
<pre>
public void Foo(DbContext context, string query, string param)
{
    context.Database.ExecuteSqlCommand("SELECT * FROM mytable WHERE mycol=@p0", param); // Compliant, it's a parametrized safe query
}
</pre>
<h2>See</h2>
<ul>
  <li> OWASP - <a href="https://owasp.org/Top10/A03_2021-Injection/">Top 10 2021 Category A3 - Injection</a> </li>
  <li> OWASP - <a href="https://owasp.org/www-project-top-ten/2017/A1_2017-Injection">Top 10 2017 Category A1 - Injection</a> </li>
  <li> CWE - <a href="https://cwe.mitre.org/data/definitions/20">CWE-20 - Improper Input Validation</a> </li>
  <li> CWE - <a href="https://cwe.mitre.org/data/definitions/89">CWE-89 - Improper Neutralization of Special Elements used in an SQL Command</a> </li>
  <li> Derived from FindSecBugs rules <a href="https://h3xstream.github.io/find-sec-bugs/bugs.htm#SQL_INJECTION_JPA">Potential SQL/JPQL Injection
  (JPA)</a>, <a href="https://h3xstream.github.io/find-sec-bugs/bugs.htm#SQL_INJECTION_JDO">Potential SQL/JDOQL Injection (JDO)</a>, <a
  href="https://h3xstream.github.io/find-sec-bugs/bugs.htm#SQL_INJECTION_HIBERNATE">Potential SQL/HQL Injection (Hibernate)</a> </li>
</ul> }, codeSnippet = , Key = e61f86a1-1d3f-4dce-972d-09de3ffb7958, Type = Hotspot }, Root: E:\
[ThreadId 104] [Open in IDE] Unable to convert issue data: Value cannot be null.
Parameter name: text

For the wrong base path:

Issue type:

Remove this unread private field 'plugin' or refactor the code to use its value.
Unread "private" fields should be removedcsharpsquid:S4487 

Log:

[DEBUG] [ThreadId 88] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] Assist connection and binding if needed for project Flirt and server http://appserver09:9000
[DEBUG] [ThreadId 88] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] GET 200 http://appserver09:9000/api/system/status | response time=15ms
[DEBUG] [ThreadId 88] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] Downloaded server infos in 15ms
[DEBUG] [ThreadId 88] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] GET 200 http://appserver09:9000/api/issues/search.protobuf?issues=588dce08-1460-4433-8bb1-2ffe600b81d0&componentKeys=Flirt&ps=1&p=1&branch=FLIRT_pack_Dev | response time=61ms
[DEBUG] [ThreadId 88] [SLCore] [sonarlint > Show Issue or Hotspot Request Handler] GET 200 http://appserver09:9000/api/sources/raw?key=Flirt%3AAudit%2FAudit%2FAction%2FApplicationMenu.cs&branch=FLIRT_pack_Dev | response time=22ms
[ThreadId 53] [Open in IDE] Processing request. Configuration scope: FLIRT .NET pack, Key: 588dce08-1460-4433-8bb1-2ffe600b81d0, Type: Issue
[ThreadId 53] Bringing IDE to front...
[DEBUG] [ThreadId 53] SetForegroundWindow call failed. Last error code: 0
[DEBUG] [ThreadId 53] Issue: IssueDetailDto { issueKey = 588dce08-1460-4433-8bb1-2ffe600b81d0, ruleKey = csharpsquid:S4487, ideFilePath = Audit\Audit\Action\ApplicationMenu.cs, message = Remove this unread private field 'plugin' or refactor the code to use its value., creationDate = 2017-10-11T18:34:58+0200, codeSnippet = plugin, isTaint = False, flows = System.Collections.Generic.List`1[SonarLint.VisualStudio.SLCore.Listener.Visualization.Models.FlowDto], textRange = TextRangeDto { startLine = 15, startLineOffset = 51, endLine = 15, endLineOffset = 57 }, Key = 588dce08-1460-4433-8bb1-2ffe600b81d0, Type = Issue }, Root: E:\
[ThreadId 53] Error opening file 'E:\Audit\Audit\Action\ApplicationMenu.cs': The system cannot find the path specified. (Exception from HRESULT: 0x80070003)
[ThreadId 53] [Open in IDE] Could not find the location at File: E:\Audit\Audit\Action\ApplicationMenu.cs, Start Line: 15, Start Position: 51

Thank you for the logs and the provided details, @Fiplan!

I would need other logs that provide clues about where problem is. For this purpose, could you please follow these steps: open the affected solution and then open the file where the S4487 is present (which will trigger an analysis).

I would be interested the log that contains [SLCore] [sonarlint > sonarlint-path-translation] Matched paths for config scope, which contains the path to the solution, and in the log that contains [SLCoreAnalyzer] Analyzing, which specifies the absolute path to the file being analyzed.

Hi Gabriela,

I have not found sonarlint-path-translation in SonarQube for Visual studio logs. But I at least this I see when I open the file in visual studio:

[DEBUG] [ThreadId 42] [SLCore] [sonarlint > FLIRT .NET pack > SonarLint Server RPC request executor] Triggering analysis with configuration: [
  baseDir: D:\Projects\Flirt\Audit\Audit\Action
  extraProperties: {sonar.updatecenter.cache.ttl=3600000, sonaranalyzer-cs.nuget.packageVersion=10.4.0.108396, sonaranalyzer.security.cs.pluginVersion=10.11.0.34915, sonar.auth.bitbucket.allowUsersToSignUp=true, sonar.cs.ignoreHeaderComments=true, sonar.c.file.suffixes=.c,.h, sonar.typescript.file.suffixes=.ts,.tsx,.cts,.mts, sonar.auth.github.enabled=false, sonar.python.coverage.reportPaths=coverage-reports/*coverage-*.xml, sonar.text.activate=true, sonaranalyzer-vbnet.nuget.packageVersion=10.4.0.108396, provisioning.gitlab.enabled=false, sonar.go.file.suffixes=.go, sonar.cs.analyzeRazorCode=true, sonar.auth.saml.applicationId=sonarqube, sonar.python.xunit.skipDetails=false, sonar.ipynb.file.suffixes=ipynb, sonar.dbcleaner.weeksBeforeKeepingOnlyAnalysesWithVersion=104, sonar.plsql.jdbc.driver.class=oracle.jdbc.OracleDriver, sonar.qualitygate.ignoreSmallChanges=true, sonar.auth.saml.signature.enabled=false, sonar.autodetect.ai.code=true, sonar.go.exclusions=**/vendor/**, sonar.php.exclusions=**/vendor/**, sonar.terraform.file.suffixes=.tf, sonar.forceAuthentication=true, sonar.notifications.delay=60, sonar.cpp.file.suffixes=.cc,.cpp,.cxx,.c++,.hh,.hpp,.hxx,.h++,.ipp,.ixx,.mxx,.cppm,.ccm,.cxxm,.c++m, sonar.swift.file.suffixes=.swift, sonar.vbnet.roslyn.ignoreIssues=false, sonar.plsql.ignoreHeaderComments=false, sonar.flex.file.suffixes=as, sonar.multi-quality-mode.enabled=true, sonaranalyzer.security.cs.nuget.packageVersion=10.11.0.34915, sonar.filesize.limit=20, sonar.auth.gitlab.groupsSync=true, sonar.auth.github.apiUrl=https://api.github.com/, sonar.ruby.file.suffixes=.rb, sonaranalyzer-cs.ruleNamespace=SonarAnalyzer.Enterprise.CSharp, sonar.auth.github.allowUsersToSignUp=true, sonar.cs.analyzeGeneratedCode=false, sonar.azureresourcemanager.file.identifier=https://schema.management.azure.com/schemas/,http://schema.management.azure.com/schemas/, sonar.python.xunit.reportPath=xunit-reports/xunit-result-*.xml, sonar.java.jvmframeworkconfig.file.patterns=**/src/main/resources/**/*app*.properties,**/src/main/resources/**/*app*.yaml,**/src/main/resources/**/*app*.yml, sonar.builtInQualityProfiles.disableNotificationOnUpdate=false, sonar.javascript.globals=angular,goog,google,OpenLayers,d3,dojo,dojox,dijit,Backbone,moment,casper,_,sap, sonar.dbcleaner.hoursBeforeKeepingOnlyOneSnapshotByDay=24, sonar.yaml.file.suffixes=.yaml,.yml, sonar.dbcleaner.daysBeforeDeletingInactiveBranchesAndPRs=30, sonar.auth.bitbucket.enabled=false, sonar.terraform.activate=true, sonar.dependencyCheck.htmlReportPath=${WORKSPACE}/dependency-check-report.html, sonar.css.file.suffixes=.css,.less,.scss,.sass, sonar.cpd.abap.minimumTokens=100, sonar.docker.file.patterns=Dockerfile,*.dockerfile, sonar.auth.github.webUrl=https://github.com/, sonar.dbcleaner.branchesToKeepWhenInactive=main,master,develop,trunk, sonar.dependencyCheck.useFilePath=false, sonar.html.file.suffixes=.html,.xhtml,.cshtml,.vbhtml,.aspx,.ascx,.rhtml,.erb,.shtm,.shtml,.cmp,.twig, sonaranalyzer-vbnet.nuget.packageId=SonarAnalyzer.Enterprise.VisualBasic, sonar.php.frameworkDetection=true, sonar.auth.gitlab.enabled=false, sonar.cpd.cross_project=false, sonar.cs.analyzer.dotnet.pluginVersion=10.4.0.108396, sonaranalyzer-vbnet.pluginVersion=10.4.0.108396, sonar.dependencyCheck.summarize=false, sonar.vbnet.ignoreHeaderComments=true, sonaranalyzer.security.cs.analyzerId=SonarAnalyzer.Security, sonaranalyzer.security.cs.nuget.packageId=SonarAnalyzer.Security, sonar.auth.github.groupsSync=false, sonar.dbcleaner.weeksBeforeKeepingOnlyOneSnapshotByWeek=4, sonar.vbnet.analyzer.dotnet.pluginKey=vbnetenterprise, sonaranalyzer-vbnet.analyzerId=SonarAnalyzer.Enterprise.VisualBasic, sonar.scala.file.suffixes=.scala, sonar.auth.gitlab.allowedGroups=, sonar.cs.roslyn.ignoreIssues=false, sonar.cloudformation.activate=true, sonaranalyzer-cs.pluginKey=csharpenterprise, sonar.kubernetes.activate=true, sonar.java.ignoreUnnamedModuleForSplitPackage=False, sonar.vbnet.analyzer.dotnet.staticResourceName=SonarAnalyzer-vbnetenterprise-10.4.0.108396.zip, sonar.json.file.suffixes=.json, sonaranalyzer.security.cs.pluginKey=securitycsharpfrontend, sonaranalyzer-vbnet.ruleNamespace=SonarAnalyzer.Enterprise.VisualBasic, sonar.cloudformation.file.identifier=AWSTemplateFormatVersion, sonar.auth.saml.providerName=SAML, provisioning.github.project.visibility.enabled=true, sonar.dbcleaner.daysBeforeDeletingAnticipatedTransitions=30, sonar.javascript.ignoreHeaderComments=true, sonar.dbcleaner.daysBeforeDeletingClosedIssues=30, sonar.dependencyCheck.severity.high=7.0, sonar.java.enablePreview=False, sonar.dbcleaner.weeksBeforeKeepingOnlyOneSnapshotByMonth=52, sonar.lf.gravatarServerUrl=https://secure.gravatar.com/avatar/{EMAIL_MD5}.jpg?s={SIZE}&d=identicon, sonar.dependencyCheck.skip=false, sonar.core.serverBaseURL=http://appserver09:9000, sonar.objc.file.suffixes=.m, sonar.text.inclusions=**/*.sh,**/*.bash,**/*.zsh,**/*.ksh,**/*.ps1,**/*.properties,**/*.conf,**/*.pem,**/*.config,.env,.aws/config, sonar.ruby.coverage.reportPaths=coverage/.resultset.json, sonar.qualityProfiles.allowDisableInheritedRules=true, sonaranalyzer-cs.staticResourceName=SonarAnalyzer-csharpenterprise-10.4.0.108396.zip, sonar.notifications.runningDelayBeforeReportingStatus=600, sonar.auth.gitlab.allowUsersToSignUp=false, sonar.projectCreation.mainBranchName=main, sonar.jsp.file.suffixes=.jsp,.jspf,.jspx, sonar.cs.analyzer.dotnet.staticResourceName=SonarAnalyzer-csharpenterprise-10.4.0.108396.zip, sonar.javascript.maxFileSize=1000, sonaranalyzer-cs.nuget.packageId=SonarAnalyzer.Enterprise.CSharp, sonar.javascript.environments=amd,applescript,atomtest,browser,commonjs,embertest,greasemonkey,jasmine,jest,jquery,meteor,mocha,mongo,nashorn,node,phantomjs,prototypejs,protractor,qunit,serviceworker,shared-node-browser,shelljs,webextensions,worker, sonar.authenticator.downcase=false, sonar.scm.disabled=false, sonar.ruby.exclusions=**/vendor/**, sonar.dart.file.suffixes=.dart, sonar.ansible.activate=true, sonar.auth.saml.enabled=false, sonar.vbnet.file.suffixes=.vb, sonaranalyzer-cs.analyzerId=SonarAnalyzer.Enterprise.CSharp, sonar.core.id=41330257-AZPPjZTvQ98wGaYo2N4r, sonar.exclusions=**/*.config,**/*.xml,**/BillingAPSimulation/**,**/ScheduleAP/**,**/SpecEditorGUI/**,**/LegacyProjects/**,**/Database/**,**/InnoSetup/**,**/Outdated/**,**/*Test*/**,**/Build/**,**/Config/**,**/Icons/**,**/Images/**,**/Templates/**,**/*.settings,**/*pack*/**,**/ReportAPF/**,**/*XmlRender*/**,**/*KUL*/**,**/ReportGenerator/**,**/FlirtGUI/**, sonar.dependencyCheck.jsonReportPath=${WORKSPACE}/dependency-check-report.json, sonar.dependencyCheck.severity.medium=4.0, sonar.cs.analyzer.dotnet.pluginKey=csharpenterprise, sonar.cfamily.generateComputedConfig=false, sonar.abap.file.suffixes=.abap,.ab4,.flow,.asprog, sonar.global.exclusions=**/*.Designer.cs,**/*.g.cs,**/*.g.i.cs,**/*_Reference.cs,**/*.AssemblyInfo.cs,**/AssemblyInfo.cs, sonar.cfamily.ignoreHeaderComments=true, sonar.technicalDebt.ratingGrid=0.05,0.1,0.2,0.5, sonar.vbnet.analyzer.dotnet.pluginVersion=10.4.0.108396, sonar.technicalDebt.developmentCost=30, sonar.lf.enableGravatar=false, sonar.validateWebhooks=true, sonar.docker.activate=true, sonar.python.file.suffixes=py, sonaranalyzer-cs.pluginVersion=10.4.0.108396, sonaranalyzer.security.cs.staticResourceName=SonarAnalyzer.Security-10.11.0.34915.zip, sonar.cs.file.suffixes=.cs,.razor, sonar.developerAggregatedInfo.disabled=false, sonar.plsql.file.suffixes=sql,pks,pkb, sonaranalyzer.security.cs.ruleNamespace=SonarAnalyzer.Security, sonar.plugins.downloadOnlyRequired=true, sonar.azureresourcemanager.file.suffixes=.bicep, sonar.javascript.file.suffixes=.js,.jsx,.cjs,.mjs,.vue, sonar.cpd.abap.minimumLines=20, sonar.allowPermissionManagementForProjectAdmins=true, sonar.text.inclusions.activate=true, sonaranalyzer-vbnet.staticResourceName=SonarAnalyzer-vbnetenterprise-10.4.0.108396.zip, sonar.dependencyCheck.securityHotspot=false, sonar.vbnet.analyzeGeneratedCode=false, sonar.java.file.suffixes=.java,.jav, sonar.kotlin.file.suffixes=.kt,.kts, sonar.plugins.risk.consent=ACCEPTED, sonar.php.file.suffixes=php,php3,php4,php5,phtml,inc, sonar.auth.gitlab.url=http://gitlab.fiplan.local/, sonar.scanner.skipNodeProvisioning=false, sonar.xml.file.suffixes=.xml,.xsd,.xsl,.config, sonar.dbcleaner.weeksBeforeDeletingAllSnapshots=260, sonaranalyzer-vbnet.pluginKey=vbnetenterprise, sonar.azureresourcemanager.activate=true, sonar.java.jvmframeworkconfig.activate=true, sonar.dependencyCheck.severity.low=0.0, sonar.updatecenter.url=https://downloads.sonarsource.com/sonarqube/update/update-center.properties, sonar.tsql.file.suffixes=.tsql, sonar.core.startTime=2025-01-28T19:59:35+0100}
  activeRules: [448 cpp, 24 css, 208 c, 317 typescript, 121 secrets, 315 javascript]
  inputFiles: [
    file:///D:/Projects/Flirt/Audit/Audit/Action/ApplicationMenu.cs (UTF-8)
  ]
]

[DEBUG] [ThreadId 42] [SLCore] [sonarlint > FLIRT .NET pack > SonarLint Server RPC request executor] Restoring previous known findings database from C:\Users\Dima\AppData\Local\SLVS_SLOOP\storageRoot\known_findings_backup.tar.gz
[DEBUG] [ThreadId 6] [SLCore] [sonarlint > FLIRT .NET pack > SonarLint Server RPC request executor] Starting known findings database from C:\Users\Dima\.sonarlint\known-findings-store5912192016436713063
[DEBUG] [ThreadId 34] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Start analysis
[DEBUG] [ThreadId 42] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Index files
[DEBUG] [ThreadId 42] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Language of file "file:///D:/Projects/Flirt/Audit/Audit/Action/ApplicationMenu.cs" is detected to be "CS"
[DEBUG] [ThreadId 42] [SLCore] [sonarlint > FLIRT .NET pack > Report about progress of file indexation] 1 file indexed
[DEBUG] [ThreadId 32] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Loading C:\Users\Dima\AppData\Local\Temp\sonarsource-cfamily-jni12251531871283874744.dll
[DEBUG] [ThreadId 5] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Added 317 checks for language='ts', repository='typescript'
[DEBUG] [ThreadId 33] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Added 315 checks for language='js', repository='javascript'
[DEBUG] [ThreadId 58] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] No registered JsAnalysisConsumer.
[DEBUG] [ThreadId 26] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] 'JavaScript/TypeScript analysis' skipped because there are no related files in the current project
[DEBUG] [ThreadId 26] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] 'JavaScript inside YAML analysis' skipped because there are no related files in the current project
[DEBUG] [ThreadId 26] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] 'JavaScript inside HTML analysis' skipped because there are no related files in the current project
[DEBUG] [ThreadId 26] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Execute Sensor: CSS Rules
[DEBUG] [ThreadId 26] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] No CSS, PHP, HTML or VueJS files are found in the project. CSS analysis is skipped.
[DEBUG] [ThreadId 26] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] 'CFamily' skipped because there are no related files in the current project
[DEBUG] [ThreadId 26] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Execute Sensor: DeveloperTextAndSecretsSensor
[DEBUG] [ThreadId 26] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Available processors: 8
[DEBUG] [ThreadId 26] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Using 8 threads for analysis.
[DEBUG] [ThreadId 13] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Analyzing all except non binary files
[DEBUG] [ThreadId 13] [SLCore] [sonarlint > FLIRT .NET pack > Progress of the text and secrets analysis] 1 source file to be analyzed
[DEBUG] [ThreadId 13] [SLCore] [sonarlint > FLIRT .NET pack > Progress of the text and secrets analysis] 1/1 source file has been analyzed
[DEBUG] [ThreadId 13] [SLCore] [sonarlint > FLIRT .NET pack > sonarlint-analysis-engine] Analysis detected 0 issues and 0 Security Hotspots in 3590ms
[ThreadId 58] [SLCoreAnalyzer] Finished analyzing D:\Projects\Flirt\Audit\Audit\Action\ApplicationMenu.cs with id 58473dd2-efe2-4b7d-832c-39c83b9007aa, analysis time: 3,64s
[ThreadId 13] [SLCoreAnalyzer] Found 0 issue(s) in D:\Projects\Flirt\Audit\Audit\Action\ApplicationMenu.cs [id: 58473dd2-efe2-4b7d-832c-39c83b9007aa, final: True]
[ThreadId 13] [SLCoreAnalyzer] Found 0 hotspot(s) in D:\Projects\Flirt\Audit\Audit\Action\ApplicationMenu.cs [id: 58473dd2-efe2-4b7d-832c-39c83b9007aa, final: True]
[DEBUG] [ThreadId 13] Looking up implementation of 'IGetNotificationsRequest' for version '2025.1.0.102418' on thread '13'
[DEBUG] [ThreadId 13] Created request of type 'SonarQube.Client.Api.V6_60.GetNotificationsRequest'.
[DEBUG] [ThreadId 13] Sending Http request:
[DEBUG] [ThreadId 13] Method: GET, RequestUri: 'api/developers/search_events?projects=Flirt&from=2025-01-30T12%3A46%3A37%2B0100', Version: 1.1, Content: <null>, Headers:
{
}
[DEBUG] [ThreadId 18] Response with HTTP status code 'OK' received.
[DEBUG] [ThreadId 18] {"events":[]}
[DEBUG] [ThreadId 8] Looking up implementation of 'IGetNotificationsRequest' for version '2025.1.0.102418' on thread '8'
[DEBUG] [ThreadId 8] Created request of type 'SonarQube.Client.Api.V6_60.GetNotificationsRequest'.
[DEBUG] [ThreadId 8] Sending Http request:
[DEBUG] [ThreadId 8] Method: GET, RequestUri: 'api/developers/search_events?projects=Flirt&from=2025-01-30T12%3A46%3A37%2B0100', Version: 1.1, Content: <null>, Headers:
{
}
[DEBUG] [ThreadId 18] Response with HTTP status code 'OK' received.
[DEBUG] [ThreadId 18] {"events":[]}
[DEBUG] [ThreadId 71] [SSESession] Failed to handle events: System.IO.IOException: Unable to read data from the transport connection: A blocking operation was interrupted by a call to WSACancelBlockingCall. ---> System.Net.Sockets.SocketException: A blocking operation was interrupted by a call to WSACancelBlockingCall
   at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   --- End of inner exception stack trace ---
   at System.Net.ConnectStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   at System.Net.Http.HttpClientHandler.WebExceptionWrapperStream.Read(Byte[] buffer, Int32 offset, Int32 count)
   at System.IO.StreamReader.ReadBuffer()
   at System.IO.StreamReader.get_EndOfStream()
   at SonarQube.Client.Models.ServerSentEvents.ServerContract.SqSSEStreamReader.<ReadAsync>d__5.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at SonarQube.Client.Models.ServerSentEvents.SSEStreamReader.<ReadNextEventAsync>d__5.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at SonarQube.Client.Models.ServerSentEvents.SSEStreamReader.<ReadAsync>d__4.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at SonarLint.VisualStudio.ConnectedMode.ServerSentEvents.SSESessionFactory.SSESession.<PumpAllAsync>d__10.MoveNext()
[DEBUG] [ThreadId 71] [SSESessionManager] Session failed: 23750039
[DEBUG] [ThreadId 71] [SSESession] Disposing session: 23750039
[DEBUG] [ThreadId 71] Response with HTTP status code 'OK' received.
[DEBUG] [ThreadId 71] {"total":0,"p":1,"ps":500,"paging":{"pageIndex":1,"pageSize":500,"total":0},"effortTotal":0,"issues":[],"components":[],"facets":[]}
[DEBUG] [ThreadId 71] Received 0 items.
[DEBUG] [ThreadId 71] Sending Http request:
[DEBUG] [ThreadId 71] Method: GET, RequestUri: 'api/issues/search?projects=Flirt&statuses=RESOLVED&branch=master&types=BUG&p=1&ps=500', Version: 1.1, Content: <null>, Headers:
{
}
[DEBUG] [ThreadId 71] Response with HTTP status code 'OK' received.
[DEBUG] [ThreadId 71] {"total":0,"p":1,"ps":500,"paging":{"pageIndex":1,"pageSize":500,"total":0},"effortTotal":0,"issues":[],"components":[],"facets":[]}
[DEBUG] [ThreadId 71] Received 0 items.
[ThreadId 71] [ServerIssueStore] Raising change event...
[ThreadId 71] [Suppressions] Finished fetching all suppressions
[DEBUG] [ThreadId 16] [SSESessionManager] Ending current session...
[DEBUG] [ThreadId 16] [SSESessionManager] Disposing current session: 23750039
[DEBUG] [ThreadId 16] [SSESession] Disposing session: 23750039
[DEBUG] [ThreadId 16] [SSESessionManager] In connected mode, creating session...
[DEBUG] [ThreadId 16] [SSESessionManager] Created session: 24272916
[DEBUG] [ThreadId 16] Looking up implementation of 'IGetSonarLintEventStream' for version '2025.1.0.102418' on thread '16'
[DEBUG] [ThreadId 16] Created request of type 'SonarQube.Client.Api.V9_4.GetSonarLintEventStream'.
[DEBUG] [ThreadId 16] Sending Http request:
[DEBUG] [ThreadId 16] Method: GET, RequestUri: 'api/push/sonarlint_events?languages=cs%2Cvbnet%2Ccpp%2Cc%2Cjs%2Cts%2Csecrets%2Ccss&projectKeys=Flirt', Version: 1.1, Content: <null>, Headers:
{
  Accept: text/event-stream
}
[DEBUG] [ThreadId 16] [SSESessionManager] Session started
[DEBUG] [ThreadId 16] [SSESessionManager] Finished handling session failure
[DEBUG] [ThreadId 71] Response with HTTP status code 'OK' received.
[DEBUG] [ThreadId 32] Looking up implementation of 'IGetNotificationsRequest' for version '2025.1.0.102418' on thread '32'
[DEBUG] [ThreadId 32] Created request of type 'SonarQube.Client.Api.V6_60.GetNotificationsRequest'.
[DEBUG] [ThreadId 32] Sending Http request:
[DEBUG] [ThreadId 32] Method: GET, RequestUri: 'api/developers/search_events?projects=Flirt&from=2025-01-30T12%3A46%3A37%2B0100', Version: 1.1, Content: <null>, Headers:
{
}
[DEBUG] [ThreadId 63] Response with HTTP status code 'OK' received.
[DEBUG] [ThreadId 63] {"events":[]}
[DEBUG] [ThreadId 71] [SSESession] Failed to handle events: System.IO.IOException: The read operation failed, see inner exception. ---> System.Net.WebException: The request was aborted: The request was canceled.
   at System.Net.ConnectStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   at System.Net.Http.HttpClientHandler.WebExceptionWrapperStream.Read(Byte[] buffer, Int32 offset, Int32 count)
   --- End of inner exception stack trace ---
   at System.Net.Http.HttpClientHandler.WebExceptionWrapperStream.Read(Byte[] buffer, Int32 offset, Int32 count)
   at System.IO.StreamReader.ReadBuffer()
   at System.IO.StreamReader.get_EndOfStream()
   at SonarQube.Client.Models.ServerSentEvents.ServerContract.SqSSEStreamReader.<ReadAsync>d__5.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at SonarQube.Client.Models.ServerSentEvents.SSEStreamReader.<ReadNextEventAsync>d__5.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at SonarQube.Client.Models.ServerSentEvents.SSEStreamReader.<ReadAsync>d__4.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at SonarLint.VisualStudio.ConnectedMode.ServerSentEvents.SSESessionFactory.SSESession.<PumpAllAsync>d__10.MoveNext()
[DEBUG] [ThreadId 71] [SSESessionManager] Session failed: 24272916
[DEBUG] [ThreadId 71] [SSESession] Disposing session: 24272916
[DEBUG] [ThreadId 36] [SSESessionManager] Ending current session...
[DEBUG] [ThreadId 36] [SSESessionManager] Disposing current session: 24272916
[DEBUG] [ThreadId 36] [SSESession] Disposing session: 24272916
[DEBUG] [ThreadId 36] [SSESessionManager] In connected mode, creating session...
[DEBUG] [ThreadId 36] [SSESessionManager] Created session: 25466626
[DEBUG] [ThreadId 36] Looking up implementation of 'IGetSonarLintEventStream' for version '2025.1.0.102418' on thread '36'
[DEBUG] [ThreadId 36] Created request of type 'SonarQube.Client.Api.V9_4.GetSonarLintEventStream'.
[DEBUG] [ThreadId 36] Sending Http request:
[DEBUG] [ThreadId 36] Method: GET, RequestUri: 'api/push/sonarlint_events?languages=cs%2Cvbnet%2Ccpp%2Cc%2Cjs%2Cts%2Csecrets%2Ccss&projectKeys=Flirt', Version: 1.1, Content: <null>, Headers:
{
  Accept: text/event-stream
}
[DEBUG] [ThreadId 36] [SSESessionManager] Session started
[DEBUG] [ThreadId 36] [SSESessionManager] Finished handling session failure
[DEBUG] [ThreadId 63] Response with HTTP status code 'OK' received.
[DEBUG] [ThreadId 8] Looking up implementation of 'IGetNotificationsRequest' for version '2025.1.0.102418' on thread '8'
[DEBUG] [ThreadId 8] Created request of type 'SonarQube.Client.Api.V6_60.GetNotificationsRequest'.
[DEBUG] [ThreadId 8] Sending Http request:
[DEBUG] [ThreadId 8] Method: GET, RequestUri: 'api/developers/search_events?projects=Flirt&from=2025-01-30T12%3A46%3A37%2B0100', Version: 1.1, Content: <null>, Headers:
{
}
[DEBUG] [ThreadId 71] Response with HTTP status code 'OK' received.
[DEBUG] [ThreadId 71] {"events":[]}
[DEBUG] [ThreadId 26] Looking up implementation of 'IGetNotificationsRequest' for version '2025.1.0.102418' on thread '26'
[DEBUG] [ThreadId 26] Created request of type 'SonarQube.Client.Api.V6_60.GetNotificationsRequest'.
[DEBUG] [ThreadId 26] Sending Http request:
[DEBUG] [ThreadId 26] Method: GET, RequestUri: 'api/developers/search_events?projects=Flirt&from=2025-01-30T12%3A46%3A37%2B0100', Version: 1.1, Content: <null>, Headers:
{
}
[DEBUG] [ThreadId 66] Response with HTTP status code 'OK' received.
[DEBUG] [ThreadId 66] {"events":[]}
[DEBUG] [ThreadId 63] [SSESession] Failed to handle events: System.IO.IOException: The read operation failed, see inner exception. ---> System.Net.WebException: The request was aborted: The request was canceled.
   at System.Net.ConnectStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   at System.Net.Http.HttpClientHandler.WebExceptionWrapperStream.Read(Byte[] buffer, Int32 offset, Int32 count)
   --- End of inner exception stack trace ---
   at System.Net.Http.HttpClientHandler.WebExceptionWrapperStream.Read(Byte[] buffer, Int32 offset, Int32 count)
   at System.IO.StreamReader.ReadBuffer()
   at System.IO.StreamReader.get_EndOfStream()
   at SonarQube.Client.Models.ServerSentEvents.ServerContract.SqSSEStreamReader.<ReadAsync>d__5.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at SonarQube.Client.Models.ServerSentEvents.SSEStreamReader.<ReadNextEventAsync>d__5.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at SonarQube.Client.Models.ServerSentEvents.SSEStreamReader.<ReadAsync>d__4.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at SonarLint.VisualStudio.ConnectedMode.ServerSentEvents.SSESessionFactory.SSESession.<PumpAllAsync>d__10.MoveNext()
[DEBUG] [ThreadId 63] [SSESessionManager] Session failed: 25466626
[DEBUG] [ThreadId 63] [SSESession] Disposing session: 25466626
[DEBUG] [ThreadId 20] [SSESessionManager] Ending current session...
[DEBUG] [ThreadId 20] [SSESessionManager] Disposing current session: 25466626
[DEBUG] [ThreadId 20] [SSESession] Disposing session: 25466626
[DEBUG] [ThreadId 20] [SSESessionManager] In connected mode, creating session...
[DEBUG] [ThreadId 20] [SSESessionManager] Created session: 28019441
[DEBUG] [ThreadId 20] Looking up implementation of 'IGetSonarLintEventStream' for version '2025.1.0.102418' on thread '20'
[DEBUG] [ThreadId 20] Created request of type 'SonarQube.Client.Api.V9_4.GetSonarLintEventStream'.
[DEBUG] [ThreadId 20] Sending Http request:
[DEBUG] [ThreadId 20] Method: GET, RequestUri: 'api/push/sonarlint_events?languages=cs%2Cvbnet%2Ccpp%2Cc%2Cjs%2Cts%2Csecrets%2Ccss&projectKeys=Flirt', Version: 1.1, Content: <null>, Headers:
{
  Accept: text/event-stream
}

Please let me know if it helps or I need to provide other information.

In the attached document there is a complete log from the solution opening until the unsuccessful attempt to open the file with the issue. It contains sonarlint-path-translation event. I hope it will help.

SonarLog.txt (160.1 KB)

1 Like

Thank you for the logs, @Fiplan! They are useful indeed!

I just have a question: is it possible that the file mentioned was moved into a sub-folder after the last analysis on SonarQube Server? Could you check when was the last project analysis triggered in SonarQube Server (by going to the Your Project → Activity page) and, if it is an outdated analysis, would it be possible to re-scan your project and see if the problem still occurs?

Hello Gabriela,

  1. The .CS files have not been moved since the beginning.
  2. But solution file was moved. Initially, the solution file was located at \Crystal\Net.Forms\FLIRT .NET pack\FLIRT .NET pack.sln. After discovering the problem with files opening in IDE, we moved the solution to the repository root. Since then, we have reanalyzed the solution multiple times across different branches, but the same issues with openning persist everywhere.
  3. Unfortunately, our trial version has expired, and we cannot continue using the Developer Edition for analysis at the moment.