This was actually a very good remark It IS a git repository, but TeamCity didn’t create the
.git
folder when checking out the repository. I found out that it was related to checkout settings in TeamCity: msbuild - How do I get TeamCity to create the .git directory when cloning a repo for build? - Stack Overflow
After changing it, the .git
folder is back and the analysis seems to work again. Thanks for that tip!
Anyway, we have never had this .git
folder there, so something must have changed in recent SonarQube/SonarScanner versions that it started to be a problem for the analysis.
I noticed that now, the automatic issues assignation works while it didn’t work before. Apparently, when it was enabled in SonarQube, but there was no .git
folder, it was simply ignored and not performed. Now when it’s enabled, but .git
folder is not present, it results in an error during analysis.