Skip to content

fix: resolve 106 remaining SonarQube LOW severity issues#559

Merged
rygel merged 2 commits intodevelopfrom
fix/sonarqube-low-remaining
Apr 16, 2026
Merged

fix: resolve 106 remaining SonarQube LOW severity issues#559
rygel merged 2 commits intodevelopfrom
fix/sonarqube-low-remaining

Conversation

@rygel
Copy link
Copy Markdown
Owner

@rygel rygel commented Apr 16, 2026

Summary

  • S1075 (35 issues): Extract hardcoded URIs/paths to const fields across 16 provider and service files. ProviderEndpoints.cs suppressed with #pragma warning disable S1075 since it is already a centralized constants file.
  • S1192 (57 issues): Extract repeated string literals (3+ occurrences) to const string fields across 15 files, including 28 theme names in App.Themes.cs, JSON property names in CodexProvider.cs and OpenAIProvider.cs, SQL table names in DatabaseMigrationService.cs, and status strings across Monitor client files.
  • S2325 (7 issues): Make non-instance methods static in ProviderUsageProcessingPipeline, App.Screenshots, SettingsWindow.Providers, ProviderRefreshConfigSelector, and Index.cshtml.
  • S6664 (7 issues): Consolidate excessive debug logging calls in ZaiProvider, GitHubUpdateChecker, Program.cs (3 blocks), ProviderRefreshConfigLoadingService, and WebApplicationPipelineExtensions.
  • S1481 (1 issue): False positive - the version variable in _Layout.cshtml is used in the Razor template footer.

Changes

  • 35 files modified, ~1,300 lines touched
  • No behavioral changes - only refactoring to satisfy SonarQube rules

Test plan

  • dotnet build AIUsageTracker.sln - 0 errors
  • dotnet test all 3 test projects - 1,491 passed, 0 failed
  • Merge conflicts with develop resolved

- S1075: Extract 35 hardcoded URIs/paths to const fields
- S1192: Extract 57 repeated string literals to const fields
- S2325: Make 7 non-instance methods static
- S6664: Consolidate excessive debug logging in 7 blocks
- S1481: 1 false positive (Razor variable used in template)
@github-actions
Copy link
Copy Markdown
Contributor

⚠️ Large PR Detected

This PR contains 1301 lines changed across 35 files.

Details:

  • 📁 Files changed: 35
  • ➕ Insertions: 694
  • ➖ Deletions: 607
  • 📊 Total: 1301 lines

Recommendation:
Consider splitting this PR into smaller, focused changes to make review easier and faster. PRs under 500 lines are ideal for thorough code review.


This is an automated message. Feel free to ignore if this PR is intentionally large.

@rygel rygel merged commit df168a9 into develop Apr 16, 2026
20 checks passed
@rygel rygel deleted the fix/sonarqube-low-remaining branch April 16, 2026 16:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants