Skip to content

Conversation

@fernandotonon
Copy link
Owner

Summary

Technical Details

✨ Features

🐛 Bugfixes

@fernandotonon fernandotonon merged commit 3101ef4 into master Nov 12, 2025
10 checks passed
@fernandotonon fernandotonon deleted the fix-sonar branch November 12, 2025 06:04
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 872 to +883
-Dsonar.test.inclusions=**/*_test.cpp,**/test_*.cpp,tests/**/*.cpp \
-Dsonar.exclusions=**/OgreXML/**,**/dependencies/**,**/*_autogen/**,**/CMakeFiles/**,**/ui_files/**,**/moc_*,**/_deps/** \
-Dsonar.coverage.exclusions=**/*_test.cpp,**/test_*.cpp,tests/**/*.cpp,tests/**/*.qml,**/*_autogen/** \
-Dsonar.c.file.suffixes=- \
-Dsonar.cpp.file.suffixes=- \
-Dsonar.objc.file.suffixes=- \
-Dsonar.c.file.suffixes=.c \
-Dsonar.cpp.file.suffixes=.cpp,.cc,.cxx,.c++,.hpp,.hh,.hxx,.h++ \
-Dsonar.objc.file.suffixes=.m,.mm \
-Dsonar.verbose=true"
# Add build-wrapper output if it exists
if [ -d "$BUILD_WRAPPER_OUTPUT" ] && [ -f "$BUILD_WRAPPER_OUTPUT/build-wrapper-output.json" ]; then
echo "Adding build-wrapper output to analysis"
SCANNER_CMD="$SCANNER_CMD -Dsonar.cfamily.build-wrapper-output=$BUILD_WRAPPER_OUTPUT"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Build-wrapper detection looks for non-existent path/file

The build-wrapper step earlier in this workflow runs with --out-dir ${{ env.BUILD_WRAPPER_OUT_DIR }} where the env var is ./, so the wrapper writes its build-wrapper-dump.json directly under the repository root. The new analysis step hardcodes BUILD_WRAPPER_OUTPUT="${{ env.BUILD_WRAPPER_OUT_DIR }}bw-output" and checks for build-wrapper-output.json. Neither the directory nor the file name matches what the wrapper actually produces (build-wrapper-dump.json in ./). As a result the script always skips adding -Dsonar.cfamily.build-wrapper-output, causing SonarCloud’s C/C++ analysis to run without the required compilation database and the scan will fail or be ineffective. The detection should align with the actual output path/name used when running the wrapper.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants