Parser drift.
Workspace and project explorer
Platform spec feature
Workspace and project explorer
Spec standingStandard
-
LSP graph
Context
Decision
Graph via LSP executeCommand.
Consequences
Thin wrappers.
Verification anchors
beskid_lsp handlers.
-
Focus without restart
Context
UX on focus.
Decision
didChangeConfiguration for focus; no LSP restart.
Consequences
Fast focus switch.
Verification anchors
Session invalidation.
- Contracts and edge cases focusedProjectUri, LSP executeCommand JSON schemas, and explorer edge-case rules.
- Decisions record (legacy index) Migration index for workspace and project explorer ADRs.
- Design model Tree item model, focus state, icons, and multi-root labeling for workspace and project explorers.
- Examples Corelib workspace and single-application explorer scenarios.
- Flow and algorithm Activation, LSP init, tree refresh, auto-select, and reveal flows for workspace and project explorers.
0 revisions (git unavailable at build; counts may be empty)
No commits recorded for this path.
| Section id | Required | Found |
|---|---|---|
what-this-feature-specifies | yes | yes |
implementation-anchors | yes | yes |
Full tree: run pnpm verify:platform-spec-layout (writes src/generated/platform-spec-layout-report.json).
What this feature specifies
Tree views and focus coordination for Beskid workspaces and the active Project.proj, backed by LSP executeCommands.
Implementation anchors
beskid_vscode/src/workspace/WorkspaceTreeProvider.ts,ProjectTreeProvider.ts,FocusCoordinator.tsbeskid_vscode/src/workspace/lspProjectApi.tscompiler/crates/beskid_lsp/src/project_explorer_api.rs
Contract statement
The workspace and project explorer exposes two Beskid activity-bar tree views. Workspaces lists every Workspace.proj under open VS Code folders and their declared members. Project shows the focused Project.proj (targets, dependencies, source folders) using LSP graph data—never duplicate manifest parsing in TypeScript.
Inputs and outputs
| Input | Source |
|---|---|
| VS Code workspace folders | Editor |
| Focused project URI | beskid.project.autoSelectFromEditor, tree selection, or beskid.selectProject |
| LSP executeCommands | beskid.listWorkspaces, beskid.getWorkspaceSummary, beskid.getProjectGraph, beskid.getProjectDependencies |
| Output | Consumer |
|---|---|
| Focus change | LSP focusedProjectUri via init options + workspace/didChangeConfiguration |
| Tree labels / commands | VS Code UI |
State model
- Focused project — canonical
file://URI of aProject.proj; persisted in workspace state asbeskid.focusedProjectUri(legacybeskid.selectedProjectUrialias for one release). - Workspace cache — refreshed on
beskid.refreshWorkspaceand file watchers for*.proj,Project.lock,workspace.package.json.
Algorithms and flow
- Extension activates → start LSP with
initializationOptions.focusedProjectUri. - Workspaces view calls
beskid.listWorkspaces→ render members; member click runsbeskid.focusProject. - Project view reads focused URI →
beskid.getProjectDependencies/beskid.getProjectGraphfor children. - Optional auto-select: active editor path → nearest
Project.projwhenbeskid.project.autoSelectFromEditoris true. - Focus change updates configuration without full LSP restart unless server binary settings change.
Decisions
No open decisions. D-TOOL-VSC-0001 (LSP-backed graph), 0002 (focus without LSP restart)—see adr/ and the ADRs tab.
Articles
- LSP graphLSP graph
- Contracts and edge casesfocusedProjectUri, LSP executeCommand JSON schemas, and explorer edge-case rules.
- Decisions record (legacy index)Migration index for workspace and project explorer ADRs.
- Design modelTree item model, focus state, icons, and multi-root labeling for workspace and project explorers.
- ExamplesCorelib workspace and single-application explorer scenarios.
- Flow and algorithmActivation, LSP init, tree refresh, auto-select, and reveal flows for workspace and project explorers.