When I run the SonarQube job in Gitlab with the sonarsource/sonar-scanner-cli:latest docker image, no code smells except the ones generated by ESLint are reported.
15:25:16.871 DEBUG: Files which didn't change will be part of UCFG generation only, other rules will not be executed
...
15:25:17.932 INFO: Analyzed 5 file(s) with current program
15:25:17.938 INFO: 5/5 source files have been analyzed
15:25:17.938 INFO: Hit the cache for 5 out of 5
15:25:17.939 INFO: Miss the cache for 0 out of 5
15:25:17.939 INFO: Sensor TypeScript analysis [javascript] (done) | time=5316ms
Is there really nothing displayed when you view the main branch in SonarQube (putting aside what you see in Gitlab)?
This might just be a red herring, but it doesn’t sound like there’s no analysis of the main branch.
Ok, this is very strange, it seems it has the code in SonarQube under the main branch, which is not the case. That code has never been in the main branch and only exists in the branch we made the MR for.