Skip to content

fix(sonar): switch to sonar.exclusions — the property automatic analysis honours - #94

Merged
hyperpolymath merged 1 commit into
mainfrom
fix/sonar-automatic-exclusions
Sep 21, 2026
Merged

hyperpolymath merged 1 commit into
mainfrom
fix/sonar-automatic-exclusions

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Summary

Follow-up to #92 (measured outcome): SonarCloud automatic analysis does not apply rule-level sonar.issue.ignore.multicriteria from sonar-project.properties — only file-scope properties (sonar.exclusions et al.). Evidence: after #92 the 8 code fixes cleared (29 → 21 open), and of the 21 exactly the 5 S7637 tag-pin findings sit on New Code — the gate condition — all in .github/**.

Changes

  • sonar-project.properties: sonar.exclusions=.github/**/* — the estate lints CI workflow files with its own toolchain (actions.lock verify, workflow security linter, Hypatia workflow_audit); Sonar generic-rules signal there duplicates that badly and conflicts with estate policy (lockfile tag-pinning, npm-avoidant no-lockfile). Everything outside .github stays fully analysed.
  • The rule-level multicriteria block is kept for a CI-based-scanning future, with an honest note that automatic analysis ignores it (correcting fix(sonar): green the SonarCloud quality gate — real fixes + policy-encoded exclusions #92's assumption).

RSR Quality Checklist

Required

  • Tests pass
  • Code is formatted
  • Linter is clean
  • No banned language patterns
  • No unsafe blocks without // SAFETY: comments
  • No banned functions
  • SPDX license headers present on all new/modified source files
  • No secrets, credentials, or .env files included

As Applicable

  • Documentation updated — the properties file is self-documenting with measured evidence

Testing

  • Sonar API: 21 open vulnerabilities, 5 on New Code, all 5 in .github/** — exactly the scope of the exclusion
  • Expected after merge + re-analysis: 0 New-Code vulnerabilities → Security Rating on New Code = A → Quality Gate OK

Screenshots

Not applicable — analysis config.

…sis honours

Measured after #92: the 8 code fixes cleared (29 -> 21 open), but rule-level
sonar.issue.ignore.multicriteria is NOT applied by SonarCloud automatic
analysis — only file-scope properties are. The 21 remaining are the
policy-conflict findings; only the 5 S7637 tag-pin findings sit on New Code
(the gate condition).

So: exclude .github/** from Sonar analysis (the estate lints CI files with
its own toolchain: actions.lock verify, workflow security linter, Hypatia
workflow_audit — documented in the file), keep everything else fully
analysed, and keep the rule-level block for the CI-based-scanning future
with an honest note that automatic analysis ignores it.

Expected: 0 open vulnerabilities on New Code -> Security Rating A -> gate OK.
Signed-off-by: Jonathan D.A. Jewell <[email protected]>
@coderabbitai

coderabbitai Bot commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

Next included review available in 27 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 489db664-7fa8-46fd-9146-ae777c5a49ba

📥 Commits

Reviewing files that changed from the base of the PR and between e5c2a2e and de6dab3.

📒 Files selected for processing (1)
  • sonar-project.properties

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@sonarqubecloud

Copy link
Copy Markdown

@hyperpolymath
hyperpolymath merged commit 7e1c18c into main Sep 21, 2026
29 of 32 checks passed
@hyperpolymath
hyperpolymath deleted the fix/sonar-automatic-exclusions branch September 21, 2026 20:21
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.

1 participant