We have a dotnet project in an Azure DevOps repository and an integration with SonarCloud.
A few weeks ago, we excluded a few files with sonar.test.exclusions and sonar.exclusions. These files have been excluded from the Sonar analysis (no smell code are detected). Here is our SonarCloud task in our yaml file:
Now, we would like to remove these exclusions, so we tried to remove the line in the yaml, but all the excluded files are still not analyzed by SonarCloud in the next CI run.
We also tried to add exclusion within the SonarCloud exclusion and to remove them and same issue :
At some point we duplicated our repository, removed the exclusion and all code were analyzed! Then we added the exclusion, and the concerned code has not been analyzed as expected.
Then, we removed the exclusions ans the concerned code is still not analyzed.
From our point of view, this is a bug.
Do you guys have the same issue ? Or do you have any solution for that?
Thank you in advance for your help.
Does anyone has any idea about that?
Do you see the code under the Code tab of your project?
I’m having a very similar issue!
I’m attempting to run an initial scan of my code (main branch).
The first analysis I missed a folder that should have been excluded and now every time I run I’m told I’m over my LOC limit.
Any changes I have make to exclude the problem folder don’t appear to take effect. I’ve tried removing all exclusions to scan the entire application and this doesn’t appear to change anything either.
My main concern is that the initial exclusions missed a folder of generated code which has pushed me over the LOC limit for my account so I’m unable to get any analysis done at present.
I can’t scan my main branch so don’t see anything under the Code tab
I have just signed up and I’m still on my 14 day trial and it’s a show stopper for me at the moment as i’m completely unable to use SonarCloud
Is there any update to this?
Indeed we can see the code of the project under the Code tab. In the “Lines of code” column we have “-” for all “ignored” files (which should not be ignored).