Closed dbwiddis closed 1 month ago
More useful error:
Warning: Both 'sonar.login' and 'sonar.token' (or the 'SONAR_TOKEN' env variable) are set, but only the latter will be used. [INFO] User cache: /home/runner/.sonar/cache [INFO] Communicating with SonarQube Cloud [INFO] JRE provisioning: os[linux], arch[x86_64] Error: Failed to query JRE metadata: GET https://api.sonarcloud.io/analysis/jres?os=linux&arch=x86_64 failed with HTTP 403. Please check the property sonar.token or the environment variable SONAR_TOKEN.
Sample that maybe we should switch to from command line?
name: My Test Single Project
on:
push:
branches:
- main
pull_request:
types: [opened, synchronize, reopened]
jobs:
sonarqube:
name: SonarQube
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: SonarQubeScan
uses: SonarSource/sonarqube-scan-action@v4
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
resolved. I ran the prior failed build rather than changes I made to sonar.yaml since that one is being ignored until some other code change so please test that again. The real issue is that sonar expires tokens more frequently and its possible it was mine, I revoked all tokens a few weeks ago. Anyway, at least the failed build is up and running, feel free to close once some other change confirms additional changes I made are successful.
confirmed, resolved, closing.
Sonar-maven-plugin is broken since at least 2025-03-22T22:20:08Z. (See Actions.)
Possibly relevant https://community.sonarsource.com/t/403-after-upgrading-sonar-maven-plugin-to-5-0-0-4389/135514/3 but the same version worked for prior builds and we want to be using sonarcloud.