[Repo Assist] feat: add FSharp.notifications.backgroundServiceProgress config option#1452
Conversation
Add a new configuration option `FSharp.notifications.backgroundServiceProgress` (default: `false`) that controls whether background analyzer operations send LSP `$/progress` notifications to the client. Background analyzers (unused opens, unused declarations, simplify names, unnecessary parentheses, FSharp analyzers) previously always reported progress, causing notification spam during active editing. Other LSP servers default to less verbose progress reporting, allowing users to opt in. Setting `FSharp.notifications.backgroundServiceProgress: true` restores the previous behavior. Closes #1431 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
✅ Pull request created: #1452 |
|
/pr-fix |
PR Review AnalysisI've reviewed the code changes in PR #1452 and found no issues that need fixing. Here's a summary of the analysis: Code Quality ✅The implementation is correct and minimal:
Functional Behavior ✅
StatusThe PR is blocked due to pending CI checks or required review, not due to code issues. No code changes were necessary.
Warning
|
|
/repo-assist check CI and fix errors |
|
✅ Commit pushed: |
…tate.fs Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
🤖 This is an automated response from Repo Assist. I've checked the CI failures and fixed them. The build was failing because two files needed Fantomas formatting:
I've run
|
Summarise changes merged since v0.83.0: - Fix SourceLink go-to-def on .NET 10 Linux (#1441) - Add backgroundServiceProgress config option (#1452) - Fix { trigger char for interpolated strings (#1454) - Fix non-ASCII URI encoding (#1455) - Fix spurious get/set rename (#1453) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
🤖 This PR was created by Repo Assist, an automated AI assistant.
Closes #1431
Summary
Background analyzer operations (checking unused opens, unused declarations, simplify names, unnecessary parentheses, and custom FSharp analyzers) previously always sent
$/progressLSP notifications to the client. This causes notification spam during active editing — especially in clients like Neovim that display every progress message prominently.This PR adds a new configuration option:
Default:
false— matching the less verbose defaults of other LSP servers, where users must opt in to verbose progress reporting.Setting it to
truerestores the previous behavior.Changes
LspHelpers.fs/LspHelpers.fsi: AddBackgroundServiceProgress: booltoNotificationsConfig(defaultfalse) andBackgroundServiceProgress: bool optiontoNotificationsDtoAdaptiveServerState.fs: Guardprogress.Begin(...)calls incheckUnusedOpens,checkUnusedDeclarations,checkSimplifiedNames,checkUnnecessaryParentheses, andrunAnalyzersbehind the config flagBehavior
false(default)$/progressnotifications senttrueProject loading and type-checking progress notifications are not affected.
Test Status
Build: ✅
dotnet build src/FsAutoComplete/FsAutoComplete.fsproj -c Release -f net8.0— succeeded, 0 warnings, 0 errors.Full test suite was not run (long-running); the change is a minimal config guard on existing code paths with no logic changes to the analysis itself.