lsp: a forward-only file contract for hosts without a file system (SCRIPT-RECEIVERS slice 6) #516

Open
opened 2026-10-26 21:47:22 +00:00 by orion · 4 comments
Collaborator

Slice 6 of docs/design/SCRIPT-RECEIVERS.md section 12 (the design record landed with PR #519). Part of epic #518.

Forward-only file contract for hosts without a file system (section 8). The client side (a browser view of the forge) is not in this repo.

Scope

  • Client capability experimental.files: the server reads no disk.
  • torbscript/wantFiles (server -> client notification): {files, directories}, only forward from held text.
  • torbscript/files (client -> server notification): {files: [{path, text} | {path, missing}], directories: [{path, entries}]}, treated as a file change.
  • A run that misses a file answers what it has and marks it incomplete.

Acceptance

  • A tests/lsp/ session with no disk opens config.trb of config-dsl (mapped), answers the wants and gets typed hover; an unmapped script opened the same way stays untyped (notMatched).
  • The server never asks for a file that no held text names (asserted in the session).
  • Contract documented in LANGUAGE-SERVER.md and docs/tooling/torb-lsp.md.

Amended 2026-10-26 (owner): the scripts mapping is optional; unmapped scripts stay valid and are typed by inference from literal Sandbox.load calls, else untyped (SCRIPT-RECEIVERS.md sections 1, 5, 6).

Slice 6 of `docs/design/SCRIPT-RECEIVERS.md` section 12 (the design record landed with PR #519). Part of epic #518. Forward-only file contract for hosts without a file system (section 8). The client side (a browser view of the forge) is not in this repo. Scope - Client capability `experimental.files`: the server reads no disk. - `torbscript/wantFiles` (server -> client notification): `{files, directories}`, only forward from held text. - `torbscript/files` (client -> server notification): `{files: [{path, text} | {path, missing}], directories: [{path, entries}]}`, treated as a file change. - A run that misses a file answers what it has and marks it incomplete. Acceptance - [ ] A `tests/lsp/` session with no disk opens `config.trb` of config-dsl (mapped), answers the wants and gets typed hover; an unmapped script opened the same way stays untyped (`notMatched`). - [ ] The server never asks for a file that no held text names (asserted in the session). - [ ] Contract documented in LANGUAGE-SERVER.md and `docs/tooling/torb-lsp.md`. Amended 2026-10-26 (owner): the `scripts` mapping is optional; unmapped scripts stay valid and are typed by inference from literal `Sandbox.load` calls, else untyped (SCRIPT-RECEIVERS.md sections 1, 5, 6).
Author
Collaborator

Design PR: #519 · Epic: #518

Design PR: https://git.torb.dev/torbscript/language/pulls/519 · Epic: https://git.torb.dev/torbscript/language/issues/518
Author
Collaborator

[loop:torbscript] intake: in scope (author orion, label loop), no duplicate, no collision with a design record (SCRIPT-RECEIVERS.md section 8 landed via #519), no owner question. Part of epic #518; builds on the slices 2-4 (#513 in review). next: refine

[loop:torbscript] intake: in scope (author orion, label loop), no duplicate, no collision with a design record (SCRIPT-RECEIVERS.md section 8 landed via #519), no owner question. Part of epic #518; builds on the slices 2-4 (#513 in review). next: refine
orion changed title from Script receivers 5/6: forward-only file contract for hosts without a file system to lsp: a forward-only file contract for hosts without a file system (SCRIPT-RECEIVERS slice 6) 2026-11-07 22:32:33 +00:00
Author
Collaborator

[loop:torbscript] re-sweep: renamed to the area: ... form with the slice number of SCRIPT-RECEIVERS.md section 12 (the old "N/6" count did not match the slice numbers of the design record), and replaced the reference to the design branch, which is merged (PR #519), with the epic link. Also removed a reference to a private tracker; the client side is simply out of this repo.

[loop:torbscript] re-sweep: renamed to the `area: ...` form with the slice number of SCRIPT-RECEIVERS.md section 12 (the old "N/6" count did not match the slice numbers of the design record), and replaced the reference to the design branch, which is merged (PR #519), with the epic link. Also removed a reference to a private tracker; the client side is simply out of this repo.
Author
Collaborator

[loop:torbscript] refine: next: waiting (the ready buffer is full, 12 issues are ready against a refine threshold of 4, and 8 pull requests are open against a cap of 8; refine resumes when ready items have been picked up)

[loop:torbscript] refine: next: waiting (the ready buffer is full, 12 issues are ready against a refine threshold of 4, and 8 pull requests are open against a cap of 8; refine resumes when ready items have been picked up)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
torbscript/language#516
No description provided.