Skip to content

Add ArkDb, ArkFile, and tree_sitter() query for legacy handlers#1263

Open
lionel- wants to merge 13 commits into
oak/salsa-22-testthatfrom
oak/salsa-23-ark-file
Open

Add ArkDb, ArkFile, and tree_sitter() query for legacy handlers#1263
lionel- wants to merge 13 commits into
oak/salsa-22-testthatfrom
oak/salsa-23-ark-file

Conversation

@lionel-

@lionel- lionel- commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

Branched from #1260
Progress towards #1212

This PR starts migrating legacy Ark handlers to the Oak database so that we get one source of truth and remove redundancy of representations (source, syntax trees) in the LSP to save on memory.

Introduces ArkFile in the process. Note this is meant as a convenient temporary vessel until we fully migrate handlers to Oak.

  • Add ArkFile which bundles an Oak File with some metadata used by Ark handlers (version, wire url, encoding). This is meant to replace Document in a subsequent PR. The LSP <> TS position converters are now methods on ArkFile (previously on Document).

  • Add ArkDb and FileExt as extension traits for Oak.
    The main addition is a tree-sitter query, capped at 128 trees (like the Rowan trees).

  • spawn_blocking() now catches Salsa cancellations when reads on backaground tasks (e.g. diagnostics) are cancelled by a concurrent write.

  • Start migrating a bunch of handlers to that new Oak infra.

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