Static schemas (tasks, snippets, jsonc, keymap, action/*, tsconfig, package_json, inspector_style) are now computed once on first access using LazyLock and returned immediately via Task::ready(). These schemas never change at runtime because: - tasks, snippets, jsonc, inspector_style are derived from static Rust types - tsconfig, package_json are bundled JSON files (include_str!) - keymap and action/* depend only on registered actions, which are collected at compile/link time via the inventory crate (extensions cannot add actions) This eliminates foreground thread blocking for these schema requests. **New functions added to KeymapFile:** - `generate_json_schema_from_inventory()`: generates keymap schema without App context - `get_action_schema_by_name()`: looks up single action schema without App context Release Notes: - N/A --------- Co-authored-by: Ben Kunkle <ben@zed.dev>
35 lines
672 B
TOML
35 lines
672 B
TOML
[package]
|
|
name = "json_schema_store"
|
|
version = "0.1.0"
|
|
edition.workspace = true
|
|
publish.workspace = true
|
|
license = "GPL-3.0-or-later"
|
|
|
|
[lints]
|
|
workspace = true
|
|
|
|
[lib]
|
|
path = "src/json_schema_store.rs"
|
|
|
|
[features]
|
|
default = []
|
|
|
|
[dependencies]
|
|
anyhow.workspace = true
|
|
collections.workspace = true
|
|
dap.workspace = true
|
|
parking_lot.workspace = true
|
|
extension.workspace = true
|
|
gpui.workspace = true
|
|
language.workspace = true
|
|
paths.workspace = true
|
|
project.workspace = true
|
|
schemars.workspace = true
|
|
serde_json.workspace = true
|
|
serde.workspace = true
|
|
settings.workspace = true
|
|
snippet_provider.workspace = true
|
|
task.workspace = true
|
|
theme.workspace = true
|
|
util.workspace = true
|