Hot-reload settings, enable bare percentages, and add suppress quick fixes - #61
Conversation
|
| Filename | Overview |
|---|---|
| crates/server/src/backend.rs | Introduces runtime settings reload, analyzer/index refresh paths, configurable debounce, and dynamic formatting registration. |
| crates/analysis/src/diagnostics.rs | Adds opt-in handling for bare percentage values and tests the enabled/disabled behavior. |
| crates/analysis/src/actions.rs | Allows suppression quick fixes for error diagnostics while still deduplicating and excluding unknown-suppression. |
| editors/vscode/src/extension.ts | Adds runtime configuration synchronization and a bare-percentage quick fix; the quick fix writes only the global setting and can be shadowed by workspace settings. |
| editors/vscode/package.json | Adds the bare percentage analysis setting to extension configuration metadata. |
| crates/server/tests/e2e.py | Expands LSP e2e coverage for hot-reloaded settings, base roots, schema changes, progress, and dynamic formatting. |
Reviews (1): Last reviewed commit: "feat: hot-reload ZeroSyntax settings" | Re-trigger Greptile
| vscode.commands.registerCommand("zerosyntax.allowBarePercentages", async () => { | ||
| await vscode.workspace | ||
| .getConfiguration("zerosyntax") | ||
| .update(allowBarePercentagesSetting, true, vscode.ConfigurationTarget.Global); |
There was a problem hiding this comment.
Honor workspace overrides
This quick fix always writes zerosyntax.analysis.allowPercentagesWithoutSign to the global target, but workspace or folder settings have higher precedence. If a workspace has this setting explicitly false, running Allow percentages without % leaves the effective value false and the bad-percent diagnostic remains, so the advertised fix does not apply.
Artifacts
Repro: Node harness that loads the real extension activation code and invokes the registered command
- Contains supporting evidence from the run (text/javascript; charset=utf-8).
- Keeps the command output available without making the summary code-heavy.
Repro: generated VS Code extension test for the workspace override scenario
- Contains supporting evidence from the run (text/typescript; charset=utf-8).
Repro: attempted VS Code extension test output showing Electron blocked by missing libgtk-3.so.0
- Keeps the command output available without making the summary code-heavy.
Summary
analysis.allowPercentagesWithoutSignand propagate it through the analyzer.Testing
cargo test -p zerosyntax-analysis --test speccargo test -p zerosyntax-analysiscargo test -p zerosyntax-schemapython crates/server/tests/e2e.py target/debug/zerosyntax-lsp.execargo test