SonarQube Cloud Automatic Analysis repeatedly fails for AI_STOCK_ANALYZER

emplate for a good new topic, formatted with Markdown:

  • ALM used (GitHub, Bitbucket Cloud, Azure DevOps)
  • CI system used (Bitbucket Cloud, Azure DevOps, Travis CI, Circle CI
  • Scanner command used when applicable (private details masked)
  • Languages of the repository
  • Only if the SonarCloud project is public, the URL
    • And if you need help with pull request decoration, then the URL to the PR too
  • Error observed (wrap logs/code around with triple quotes ``` for proper formatting)
  • Steps to reproduce
  • Potential workaround

Do not share screenshots of logs – share the text itself (bonus points for being well-formatted)!

Hello SonarQube Cloud team,

Automatic Analysis is failing for my GitHub repository:

GitHub CI (Python 3.13) and Cloud Validation have passed, but SonarCloud Code Analysis is cancelled or reported as failed.

I have merged PR #504, which updates .sonarcloud.properties to configure Python 3.13, UTF-8 encoding, and the test scope.

Could you please investigate the failing analysis and advise whether this is a configuration problem or an Automatic Analysis/report-processing issue?

Thank you.

Hi @Ramchandra-Murthy, welcome to the Community!

I found the cause of the failed check on PR #503. It isn’t a configuration problem, and your PR #504 changes didn’t cause it.

You pushed twice, about 3 seconds apart: first 103bf07, then 4c366c2. Each push started its own Automatic Analysis run. Automatic Analysis scans whatever the PR’s head is at the moment it starts, and the run triggered by the 103bf07 push started after 4c366c2 had landed, so both runs scanned 4c366c2.

SonarQube Cloud processed the first analysis and rejected the second as a duplicate. So actually, a valid analysis of 4c366c2 was processed successfully, so the PR has up-to-date results. The failed status is only the rejected duplicate.

What to do:

  • Push another commit to PR #503. The next analysis should replace the failed status.
  • Avoid pushing multiple times within a few seconds. I guess maybe you’re using an AI agent which is pushing in quick succession.