Skip to content

fix plugin properties#421

Merged
theshadowco merged 2 commits intodevelopfrom
feature/fixProps
Mar 23, 2026
Merged

fix plugin properties#421
theshadowco merged 2 commits intodevelopfrom
feature/fixProps

Conversation

@theshadowco
Copy link
Copy Markdown
Member

No description provided.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Mar 23, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 6d13e4ea-296b-4e2a-a7e9-d1c93474d2f8

📥 Commits

Reviewing files that changed from the base of the PR and between d67ae68 and e110438.

📒 Files selected for processing (1)
  • src/main/java/com/github/_1c_syntax/bsl/sonar/BSLCommunityProperties.java

Прохождение

Добавлены ограничения конфигурационных областей (.onlyOnConfigScopes(...)) к определениям PropertyDefinition в двух Java-файлах: диагностическая настройка ограничена APP и PROJECT; остальные свойства — преимущественно PROJECT; в Reporter добавлен импорт PropertyDefinition и ограничения для UI-свойств (APP / APP+PROJECT).

Изменения

Когорта / Файлы Резюме
Ограничения области видимости свойств языкового сервера
src/main/java/com/github/_1c_syntax/bsl/sonar/BSLCommunityProperties.java
Добавлены вызовы .onlyOnConfigScopes(...) к нескольким PropertyDefinition: диагностический язык — APP, PROJECT; свойства enabled, skipSupport, overrideConfiguration, configurationPath, включ/исключение подсистем, fileSuffixes, externalReportPaths — ограничены PROJECT.
Ограничения области видимости свойств UI-расширений
src/main/java/com/github/_1c_syntax/bsl/sonar/ext_issues/Reporter.java
В addExtension добавлены .onlyOnConfigScopes(...) для свойств: enabledAPP; create-external-issuesAPP,PROJECT; rules-paths (multi) — APP. Добавлен импорт org.sonar.api.config.PropertyDefinition.

Оценка сложности проверки кода

🎯 2 (Simple) | ⏱️ ~10 minutes

Стихотворение

🐰 Прыг-скок, я рад, конфиг стал стройней,
APP и PROJECT в порядке теперь идей.
Свойства на местах, порядок как в саду,
Яркий код прыгает — и пусть будет так всегда! ✨

🚥 Pre-merge checks | ✅ 1 | ❌ 2

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Description check ❓ Inconclusive Описание не было предоставлено автором, поэтому оценка невозможна по предусмотренным критериям. Добавьте описание pull request, объясняющее причины и цель изменения конфигурационных областей свойств.
✅ Passed checks (1 passed)
Check name Status Explanation
Title check ✅ Passed Заголовок 'fix plugin properties' напрямую отражает основное изменение в коде — ограничение конфигурационных областей для свойств плагина.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/fixProps

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 and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/main/java/com/github/_1c_syntax/bsl/sonar/BSLCommunityProperties.java (1)

112-117: ⚠️ Potential issue | 🟡 Minor

Добавьте onlyOnConfigScopes(PROJECT) для LANG_SERVER_SUBSYSTEM_FILTER_EXCLUDE_KEY.

Сейчас exclude остался без ограничения scope, в отличие от парного include (Line 106-111). Это создаёт несогласованность в настройках фильтра подсистем.

Предлагаемый патч
       PropertyDefinitionUtils.newPropertyBuilderBSL(6,
           LANG_SERVER_SUBSYSTEM_FILTER_EXCLUDE_KEY,
           "subsystemfilter.exclude",
           "")
         .multiValues(true)
+        .onlyOnConfigScopes(PropertyDefinition.ConfigScope.PROJECT)
         .build(),
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/main/java/com/github/_1c_syntax/bsl/sonar/BSLCommunityProperties.java`
around lines 112 - 117, The LANG_SERVER_SUBSYSTEM_FILTER_EXCLUDE_KEY property is
missing a scope restriction and should match the include counterpart; update the
PropertyDefinitionUtils.newPropertyBuilderBSL(...) call that builds
LANG_SERVER_SUBSYSTEM_FILTER_EXCLUDE_KEY to add onlyOnConfigScopes(PROJECT) into
the builder chain (i.e., call
.multiValues(true).onlyOnConfigScopes(PROJECT).build()) so the exclude setting
is limited to project config like the include setting.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Outside diff comments:
In `@src/main/java/com/github/_1c_syntax/bsl/sonar/BSLCommunityProperties.java`:
- Around line 112-117: The LANG_SERVER_SUBSYSTEM_FILTER_EXCLUDE_KEY property is
missing a scope restriction and should match the include counterpart; update the
PropertyDefinitionUtils.newPropertyBuilderBSL(...) call that builds
LANG_SERVER_SUBSYSTEM_FILTER_EXCLUDE_KEY to add onlyOnConfigScopes(PROJECT) into
the builder chain (i.e., call
.multiValues(true).onlyOnConfigScopes(PROJECT).build()) so the exclude setting
is limited to project config like the include setting.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 09e97871-6d77-450d-b028-7d55e7eb8ab0

📥 Commits

Reviewing files that changed from the base of the PR and between e9f8a37 and d67ae68.

📒 Files selected for processing (2)
  • src/main/java/com/github/_1c_syntax/bsl/sonar/BSLCommunityProperties.java
  • src/main/java/com/github/_1c_syntax/bsl/sonar/ext_issues/Reporter.java

@sonarqubecloud
Copy link
Copy Markdown

@theshadowco theshadowco merged commit df1cf76 into develop Mar 23, 2026
18 checks passed
@theshadowco theshadowco deleted the feature/fixProps branch March 23, 2026 08:45
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