AcademySoftwareFoundation / AcademySoftwareFoundation/Imath

SonarCloud Analysis broken by recent update to sonar-scanner

Open Beginner friendly
#374 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
488
Forks
161
Avg merge
1d 3h
Merged PRs (30d)
3

Description

SonarCloud analysis for Imath last succeeded in uploading results on 2024-01-13:

https://sonarcloud.io/project/overview?id=AcademySoftwareFoundation_Imath

The issue seems to be caused by the deprecation of the `sonar.login` parameter:

https://github.com/AcademySoftwareFoundation/Imath/actions/runs/7945143614/job/21691431831

```
00:27:48.413 WARN: The property 'sonar.login' is deprecated and will be removed in the future. Please use the 'sonar.token' property instead when passing a token.
```

The [documentation](https://docs.sonarsource.com/sonarcloud/advanced-setup/ci-based-analysis/sonarscanner-cli/) as well as OpenImageIO's analysis workflow indicates that it isn't necessary to set the token on the CLI, it should be sufficient to set the `SONAR_TOKEN` environment variable which `analysis_workflow.yml` already does.

Removing `-Dsonar.login=$SONAR_TOKEN` from the `sonar-scanner` command line should hopefully be sufficient to restore the functionality of uploading results back to the SonarCloud site.

A similar issue exists for OpenEXR, [issue 1646](https://github.com/AcademySoftwareFoundation/openexr/issues/1646).

Contributor guide

Open the contributing guide

Research direction

Open analysis_workflow.yml and inspect the sonar-scanner command and its existing SONAR_TOKEN environment variable. Remove the deprecated CLI parameter as described in the issue, then run the SonarCloud analysis workflow and confirm that results upload successfully.

Written by the indexing model from the issue text.

Assessment

Tech stack
github-actions
Domain
ci-cd
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.