Any way to avoid doing unshallow fetch?

Must-share information (formatted with Markdown):

  • which versions are you using (SonarQube, Scanner, Plugin, and any relevant extension)
    Developer Edition Version 8.9.1 (build 44547)

  • how is SonarQube deployed: zip, Docker, Helm:
    Docker

  • what are you trying to achieve
    Sonar requires us to do a git fetch --unshallow which takes us 9 min to finish as our repo is quite large. I wonder if there is any way to reduce the time of running Sonar.

  • what have you tried so far to achieve this
    I have tried to make a shallow fetch with a depth of 50, but Sonar is showing warnings and not reporting the precise new issues.

Hi,

Welcome to the community!

Analysis requires an unshallow fetch for proper detection of new code. Without that, as you’ve experienced, new code detection and reporting of which issues are new isn’t accurate.

 
Ann