Code issue count changed when scanning python code 2 times

  • Versions used (SonarQube, Scanner, Plugin, and any relevant extension)
    SonarQube Enterprise Edition Version 8.9 (build 43852)
    Scanner: 4.6.1.2450-linux
  • Error observed (wrap logs/code around triple quote ``` for proper formatting)
    with the same source code:
    for the 1st code scan: sonar-scanner found 70 issues
    for the 2nd code scan: sonar-scanner found 65 issues
  • Steps to reproduce
    as above step
  • Potential workaround
  • Scanner command used when applicable (private details masked)
    it can be:
    sonar-scanner-4.6.1.2450-linux/bin/sonar-scanner
    -Dsonar.projectKey=xxx
    -Dsonar.sources=xxx
    -Dsonar.cfamily.build-wrapper-output=output
    -Dsonar.branch.name=feature/specific_bin
    -Dsonar.host.url=xxx
    -Dsonar.login=xxx
    -Dsonar.projectVersion=yyyy_yyyyy

Hi @rubin ,
With the provided information we’re not able to reproduce the problem mentioned.
Can you please post a small reproducer (providing python code) when the issue count is not consistent between analysis?