Static Analysis fails only for certain part

SonarQube : 7.7, Sonar C# 7.17
We want to resolve static analysis fails only for certain subdirectories of the whole.
I’ll try to update Sonar C# 7.11 to 7.17, But Nothing better.
The error log is below.
WARN: File ‘D:…\Backup\A.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:…\Backup\B.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:…\Backup\C.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context

Is there anything I can check?

Hi,

You should consider upgrading at least to the SonarQube LTS (7.9.3) as well.

Are you using the Scanner for MS Build? Would you be willing to post a full log of your analysis?

1 Like

Thank you for response!

Yes We are using on Scanner for MS Build(In Developer Edition).
Now You can check it (as below)
It is strange that only the backup part fails.

SonarScanner for MSBuild 4.6.2
Using the .NET Framework version of the Scanner for MSBuild
Post-processing started.
Calling the SonarQube Scanner…
INFO: Scanner configuration file: D:…\sonar-scanner-3.3.0.1492\bin..\conf\sonar-scanner.properties
INFO: Project root configuration file: D:...sonarqube\out\sonar-project.properties
INFO: SonarQube Scanner 3.3.0.1492
INFO: Java 1.8.0_162 Oracle Corporation (64-bit)
INFO: Windows Server 2016 10.0 amd64
INFO: User cache: C:\Windows\system32\config\systemprofile.sonar\cache
INFO: SonarQube server 7.7.0
INFO: Default locale: “ko_KR”, source code encoding: “x-windows-949” (analysis is platform dependent)
INFO: Load global settings
INFO: Load global settings (done) | time=62ms
INFO: Server id: 92D88F0A-AW2o86wRNbWiP-xM7Ams
INFO: User cache: C:\Windows\system32\config\systemprofile.sonar\cache
INFO: Load/download plugins
INFO: Load plugins index
INFO: Load plugins index (done) | time=37ms
INFO: Load/download plugins (done) | time=471ms
INFO: Loaded core extensions: developer-scanner
INFO: Process project properties
INFO: Execute project builders
INFO: Execute project builders (done) | time=57ms
INFO: Project key: Project
INFO: Base dir: D:\Project
INFO: Working dir: D:\Project.sonarqube\out.sonar
INFO: Load project settings for component key: ‘Project’
INFO: Load project settings for component key: ‘Project’ (done) | time=10ms
INFO: Load project branches
INFO: Load project branches (done) | time=17ms
INFO: Load project pull requests
INFO: Load project pull requests (done) | time=7ms
INFO: Load branch configuration
INFO: Load branch configuration (done) | time=2ms
INFO: Load project repositories
INFO: Load project repositories (done) | time=62ms
INFO: Load quality profiles
INFO: Load quality profiles (done) | time=22ms
INFO: Load active rules
INFO: Load active rules (done) | time=376ms
INFO: Indexing files…
INFO: Project configuration:
INFO: Base dir:
INFO: Source paths: Backup/xx.cs, Backup/yy…
INFO: Indexing files of module ‘Test.Project’

INFO: 1348 files indexed
INFO: 0 files ignored because of scm ignore settings
INFO: Quality profile for cs: Sonar
INFO: Quality profile for vbnet: Sonar way
INFO: ------------- Run sensors on module SubProject
INFO: Sensor C# Properties [csharp]
INFO: Sensor C# Properties [csharp] (done) | time=0ms
INFO: Sensor JavaXmlSensor [java]
INFO: Sensor JavaXmlSensor [java] (done) | time=1ms
INFO: Sensor HTML [web]
INFO: Sensor HTML [web] (done) | time=0ms
INFO: Sensor VB.NET Properties [vbnet]
WARN: Property missing: ‘sonar.vbnet.analyzer.projectOutPaths’. No protobuf files will be loaded for this project.
WARN: No Roslyn issues report found for this project.
INFO: Sensor VB.NET Properties [vbnet] (done) | time=0ms
INFO: Sensor JaCoCo XML Report Importer [jacoco]
INFO: Sensor JaCoCo XML Report Importer [jacoco] (done) | time=0ms

INFO: Sensor C# [csharp]
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\8\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\11\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\19\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\13\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\20\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\29\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\15\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\28\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\24\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\17\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\26\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\7\output-cs’
WARN: File ‘D:\Project\Backup\xx.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\bb.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\cc.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\dd.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\ee.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\ff.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\gg.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\af.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\as.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\df.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\asd.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\gf.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\sdf.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\asdf.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\sdf.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\gd.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\fg.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\hf.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\gg.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\Backup\qq.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\31\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\21\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\2\output-cs’
INFO: Importing 31 Roslyn reports
INFO: Sensor C# [csharp] (done) | time=3183ms
INFO: Sensor C# Tests Coverage Report Import [csharp]
INFO: Parsing the OpenCover report D:\Project.\opencover.xml
INFO: Adding this code coverage report to the cache for later reuse: D:\Project.\opencover.xml
INFO: Sensor C# Tests Coverage Report Import [csharp] (done) | time=7ms
INFO: Sensor Sonargraph Integration [sonargraphintegration]
INFO: Sonargraph Integration: Processing SonarQube project ‘Project’
WARN: Sonargraph Integration: XML report file ‘D:\Project\target\sonargraph\sonargraph-sonarqube-report.xml’ not found
INFO: Sonargraph Integration: Finished processing SonarQube project ‘Project’
INFO: Sensor Sonargraph Integration [sonargraphintegration] (done) | time=1ms
INFO: Sensor VB.NET [vbnet]
INFO: Sensor VB.NET [vbnet] (done) | time=1ms
INFO: Sensor JavaSecuritySensor [security]
INFO: Reading type hierarchy from: D:\Project.sonarqube\out.sonar\ucfg2\java
INFO: Read 0 type definitions
INFO: Reading UCFGs from: D:\Project.sonarqube\out.sonar\ucfg2\java
INFO: 09:52:02.244 Building Type propagation graph
INFO: 09:52:02.246 Running Tarjan on 0 nodes
INFO: 09:52:02.247 Tarjan found 0 components
INFO: 09:52:02.247 Variable type analysis: done
INFO: No UCFGs have been included for analysis.
INFO: Sensor JavaSecuritySensor [security] (done) | time=6ms
INFO: Sensor CSharpSecuritySensor [security]
INFO: Reading type hierarchy from: D:\Project.sonarqube\out\ucfg_cs2
INFO: Read 1545 type definitions
INFO: Reading UCFGs from: D:\Project.sonarqube\out\ucfg_cs2
INFO: 09:52:03.199 Building Type propagation graph
INFO: 09:52:03.289 Running Tarjan on 38006 nodes
INFO: 09:52:03.352 Tarjan found 37728 components
INFO: 09:52:03.464 Variable type analysis: done
INFO: Analyzing 6001 ucfgs to detect vulnerabilities.
INFO: All rules entrypoints : 7 Retained UCFGs : 66
INFO: rule: S5131, entrypoints: 0
INFO: Visited 0 ucfgs in 0 ms, 0 steps
INFO: rule: S5131 done
INFO: rule: S3649, entrypoints: 0
INFO: Visited 0 ucfgs in 0 ms, 0 steps
INFO: rule: S3649 done
INFO: rule: S2076, entrypoints: 0
INFO: Visited 0 ucfgs in 0 ms, 0 steps
INFO: rule: S2076 done
INFO: rule: S2091, entrypoints: 0
INFO: Visited 0 ucfgs in 0 ms, 0 steps
INFO: rule: S2091 done
INFO: rule: S2078, entrypoints: 0
INFO: Visited 0 ucfgs in 0 ms, 0 steps
INFO: rule: S2078 done
INFO: rule: S2631, entrypoints: 0
INFO: Visited 0 ucfgs in 0 ms, 0 steps
INFO: rule: S2631 done
INFO: rule: S2083, entrypoints: 7
INFO: Visited 66 ucfgs in 174 ms, 2990 steps
INFO: rule: S2083 done
INFO: rule: S5167, entrypoints: 0
INFO: Visited 0 ucfgs in 0 ms, 0 steps
INFO: rule: S5167 done
INFO: rule: S5144, entrypoints: 0
INFO: Visited 0 ucfgs in 0 ms, 0 steps
INFO: rule: S5144 done
INFO: rule: S5145, entrypoints: 0
INFO: Visited 0 ucfgs in 0 ms, 0 steps
INFO: rule: S5145 done
INFO: rule: S5146, entrypoints: 0
INFO: Visited 0 ucfgs in 0 ms, 0 steps
INFO: rule: S5146 done
INFO: Sensor CSharpSecuritySensor [security] (done) | time=6102ms
INFO: Sensor PhpSecuritySensor [security]
INFO: Reading type hierarchy from: D:\Project.sonarqube\out.sonar\ucfg2\php
INFO: Read 0 type definitions
INFO: Reading UCFGs from: D:\Project.sonarqube\out.sonar\ucfg2\php
INFO: 09:52:08.349 Building Type propagation graph
INFO: 09:52:08.349 Running Tarjan on 0 nodes
INFO: 09:52:08.349 Tarjan found 0 components
INFO: 09:52:08.349 Variable type analysis: done
INFO: No UCFGs have been included for analysis.
INFO: Sensor PhpSecuritySensor [security] (done) | time=0ms
INFO: ------------- Run sensors on project
INFO: Sensor Zero Coverage Sensor
INFO: Sensor Zero Coverage Sensor (done) | time=178ms
INFO: 116 files had no CPD blocks
INFO: Calculating CPD for 681 files
INFO: CPD calculation finished
INFO: Analysis report generated in 792ms, dir size=7 MB
INFO: Analysis report compressed in 24461ms, zip size=3 MB
INFO: Analysis report uploaded in 302ms
INFO: ANALYSIS SUCCESSFUL …
INFO: ------------------------------------------------------------------------
INFO: EXECUTION SUCCESS
INFO: ------------------------------------------------------------------------
INFO: Total time: 46.463s
INFO: Final Memory: 63M/3797M
INFO: ------------------------------------------------------------------------
The SonarQube Scanner has finished

Could you check this issue?
As your advise, We are considering an update 7.9.3 (is it easy to migration?)
Thank you for information!!

It appears these are only warnings, while the overall analysis is a success. I think you can safely ignore these warnings unless you’re not receiving some results you’re expecting in SonarQube.

Upgrading from 7.7 to 7.9.3 is quite easy. Simply download the new software, copy your configuration (sonar.properties) to the new folder, and start up the 7.9.3 instance. Details are here in our upgrade guide.

1 Like

Thank you for your response!!
We’ve been maintained specific sonarqube rule in sonarqube 7.7.
Is it possible to maintain the rule even if we update product (to 7.9.3)?
As I know, as the version goes up, I know the rules are added or deprecated.

I suggest you launch SonarQube 7.9.3 first without connection to your database so that you can preview the UI and use the Rules tab to look for any rules you’re concerned about and confirm they are still there. Unless the rule was already marked deprecated in 7.7, it’s unlikely to have disappeared.

1 Like

Thank you!
But, The update was performed, static analysis of the Backup directory still failed.
I also update sonar C# latest version. But The problem still comes out.

INFO: Sensor C# [csharp]
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\8\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\11\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\19\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\13\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\20\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\29\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\15\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\28\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\24\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\17\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\26\output-cs’
WARN: File ‘D:\Project\tests\Test.SI.E.MCS.DMS\DMSClient\Backup\BackupServiceTest.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\tests\Test.SI.E.MCS.DMS\DMSClient\Backup\BackupServiceTest.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\22\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\12\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\14\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\3\output-cs’
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.CMM\DB\Migrations\Configuration.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.CMM\DB\Migrations\Configuration.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.CMM\DB\Migrations\Configuration.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.CMM\DB\Migrations\Configuration.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\4\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\18\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\30\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\25\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\5\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\27\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\9\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\1\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\23\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\16\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\6\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\10\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\7\output-cs’
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\SubViewBackupProgress.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\BackupService.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\MainViewBackup.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\ViewBackupHistory.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\ViewBackup.cs’ referenced by the protobuf ‘MetricsInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\SubViewBackupProgress.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\BackupService.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\MainViewBackup.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\ViewBackupHistory.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\ViewBackup.cs’ referenced by the protobuf ‘TokenTypeInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\SubViewBackupProgress.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\BackupService.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\MainViewBackup.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\ViewBackupHistory.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\ViewBackup.cs’ referenced by the protobuf ‘SymbolReferenceInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\SubViewBackupProgress.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\BackupService.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\MainViewBackup.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\ViewBackupHistory.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
WARN: File ‘D:\Project\src\SI.E.MCS\SI.E.MCS.DMS\SI.E.MCS.DMS.DMSClient\Backup\ViewBackup.cs’ referenced by the protobuf ‘CopyPasteTokenInfo’ does not exist in the analysis context
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\31\output-cs’
INFO: Importing results from 5 proto files in ‘D:\Project.sonarqube\out\21\output-cs’

It’s a full log, What is the problems?

Again, it appears to me like these are warnings regarding generated/configuration files and you can safely disregard these.

Jeff, What I would like to say is that the part of the code that caused the warning in the log was not actually analyzed. We didn’t apply the exclude condition, but some of the code we want static analysis is not being analyzed. It’s not about the warning itself.

The problem is that the actual static analysis is not performed in the part where the warning occurs.
We want static analysis of the Backup directory.

Ah, okay thank you for clarifying.

I think your issue is similar to this one encountered by another user and is likely due to using Jenkins on Windows with multiple drives.

Thanks for information, But We’ve been installed Jenkins without symlinks. Is there something to consider in this case as well?
In our case, I think all cs files are not failing static analysis.(Currently The point is that some cs files have been successfully analyzed.)

At first, I thought there was an exclude condition or an analysis restriction directory, But I don’t think so.
So wouldn’t it require a different approach?
Or maybe switching to debug mode, Can I get some more clue?

Jeff! I found the reason.
“Backup” Directory is exclude in sonar analysis. I don’t know why exclude.
“Backup” Directory is original exclude directory?

1 Like

I’m not certain either. I don’t see any sign that you’ve configured it to be excluded. If you had, you’d see it reflected in your scanner output like

INFO: Indexing files…
INFO: Project configuration:
INFO: Excluded sources: Backup/**

So it must be getting excluded automatically. I wonder, does the .csproj that covers the scope of the Backup directory have test assemblies linked? If so, as in this post you’ll need to add a property to the project to avoid having SonarQube automatically excluding it.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.