I had the same problem in Bitbucket. It showed Quality Gate 'Failed' even though I had made code changes to fix the problems. The issue was that it was still referencing the old project after changing the package name. The solution for me was to point to the new SonarQube project in the repository settings. Bitbucket: Repository Settings -> Include Code Quality -> SonarQube Projects -> Edit SonarQube Project Mapping -> select project.