-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathCargo.toml
More file actions
313 lines (266 loc) · 10.3 KB
/
Cargo.toml
File metadata and controls
313 lines (266 loc) · 10.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
[workspace]
members = [
"crates/*",
"crates/experiments/reconcile-viewer",
]
default-members = ["crates/*", "crates/experiments/reconcile-viewer"]
# Excluded crates require special build toolchains or targets:
# - WASM crates: build with wasm-pack or --target wasm32-unknown-unknown
# - pampa/fuzz: requires nightly Rust + libfuzzer-sys (Linux/macOS only), run via `cargo fuzz`
# crates/experiments is a container directory, not a crate, so we exclude it from crates/* matching.
exclude = [
"crates/wasm-quarto-hub-client",
"crates/wasm-qmd-parser",
"crates/experiments",
"crates/pampa/fuzz",
# WASM-only drop-in replacement for tree-sitter-language; used via
# [patch.crates-io] in wasm-quarto-hub-client. Collides with the
# real tree-sitter-language crate (same `links` key) if both appear
# in the same workspace graph. See
# claude-notes/plans/2026-04-20-wasm-shim-merge.md.
"crates/tree-sitter-language-wasm-shim",
]
resolver = "2"
[workspace.package]
version = "0.1.0"
authors = ["Posit Software, PBC"]
homepage = "https://github.com/posit-dev/quarto-markdown-syntax"
keywords = ["parser"]
categories = ["development-tools"]
license = "MIT"
repository = "https://github.com/posit-dev/quarto-markdown-syntax"
edition = "2024"
[workspace.dependencies]
anyhow = "1.0.101"
quick-xml = "0.39"
ariadne = "0.6"
clap = { version = "4.5", features = ["derive", "cargo", "env"] }
insta = "1.46.3"
memchr = "2.7.6"
once_cell = "1.21"
proc-macro2 = { version = "1.0.106", features = ["span-locations"] }
schemars = "1.2.1"
serde = { version = "1.0.228", features = ["derive"] }
serde_json = "1.0.149"
serde_yaml = "0.9"
thiserror = "2.0"
toml = "0.9.11"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
yaml-rust2 = "0.11"
async-trait = "0.1"
tokio-util = "0.7"
pollster = "0.4"
regex = "1.12"
scraper = "0.26"
grass = "0.13.4"
include_dir = "0.7"
flate2 = "1.1"
uuid = { version = "1", features = ["v4"] }
base64 = "0.22"
walkdir = "2"
syn = { version = "2", features = ["full", "visit", "parsing"] }
# JavaScript runtime (native only, for EJS template rendering)
# Note: deno_core version must match what deno_web depends on
deno_core = "0.376"
deno_web = "0.257"
deno_webidl = "0.226"
serde_v8 = "0.285"
tokio = { version = "1", features = ["rt-multi-thread", "macros"] }
# LSP server dependencies (native only)
tower-lsp = "0.20"
lsp-types = "0.97"
[workspace.dependencies.proc-macro-error2]
version = "2.0.1"
default-features = false
[workspace.dependencies.tests_macros]
path = "./crates/tests_macros"
[workspace.dependencies.tracing]
version = "0.1.44"
features = ["std"]
default-features = false
[workspace.dependencies.tree-sitter]
version = "0.26"
[workspace.dependencies.tree-sitter-highlight]
version = "0.26"
[workspace.dependencies.tree-sitter-qmd]
path = "./crates/tree-sitter-qmd"
[workspace.dependencies.tree-sitter-sexpr]
path = "./crates/tree-sitter-sexpr"
[workspace.dependencies.wasm-qmd-parser]
path = "./crates/wasm-qmd-parser"
[workspace.dependencies.pampa]
path = "./crates/pampa"
default-features = false
[workspace.dependencies.quarto-core]
path = "./crates/quarto-core"
[workspace.dependencies.quarto-util]
path = "./crates/quarto-util"
[workspace.dependencies.quarto-yaml]
path = "./crates/quarto-yaml"
[workspace.dependencies.quarto-yaml-validation]
path = "./crates/quarto-yaml-validation"
[workspace.dependencies.quarto-error-reporting]
path = "./crates/quarto-error-reporting"
[workspace.dependencies.quarto-source-map]
path = "./crates/quarto-source-map"
[workspace.dependencies.quarto-xml]
path = "./crates/quarto-xml"
[workspace.dependencies.quarto-doctemplate]
path = "./crates/quarto-doctemplate"
[workspace.dependencies.quarto-treesitter-ast]
path = "./crates/quarto-treesitter-ast"
[workspace.dependencies.quarto-pandoc-types]
path = "./crates/quarto-pandoc-types"
[workspace.dependencies.quarto-analysis]
path = "./crates/quarto-analysis"
[workspace.dependencies.quarto-ast-reconcile]
path = "./crates/quarto-ast-reconcile"
[workspace.dependencies.quarto-config]
path = "./crates/quarto-config"
[workspace.dependencies.quarto-system-runtime]
path = "./crates/quarto-system-runtime"
[workspace.dependencies.quarto-project-create]
path = "./crates/quarto-project-create"
[workspace.dependencies.quarto-lsp-core]
path = "./crates/quarto-lsp-core"
[workspace.dependencies.quarto-lsp]
path = "./crates/quarto-lsp"
[workspace.dependencies.quarto-sass]
path = "./crates/quarto-sass"
[workspace.dependencies.quarto-highlight]
path = "./crates/quarto-highlight"
[workspace.dependencies.quarto-highlight-encoding]
path = "./crates/quarto-highlight-encoding"
[workspace.dependencies.quarto-hub]
path = "./crates/quarto-hub"
[workspace.dependencies.quarto-navigation]
path = "./crates/quarto-navigation"
[workspace.dependencies.quarto-publish]
path = "./crates/quarto-publish"
[workspace.dependencies.quarto-test]
path = "./crates/quarto-test"
[workspace.dependencies.quarto-trace]
path = "./crates/quarto-trace"
[workspace.dependencies.quarto-trace-server]
path = "./crates/quarto-trace-server"
[workspace.lints.rust]
# coverage_nightly is used by pampa for code coverage instrumentation on nightly Rust
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(coverage_nightly)'] }
[workspace.lints.clippy]
# Architectural issues - fixing these requires significant refactoring
large_enum_variant = "allow" # Would require boxing large enum variants
result_large_err = "allow" # Would require boxing all error types
too_many_arguments = "allow" # Some functions legitimately need many parameters
fn_params_excessive_bools = "allow" # Related to too_many_arguments
wrong_self_convention = "allow" # as_inline(self) intentionally consumes self
type_complexity = "allow" # Complex types are sometimes clearer inline
inherent_to_string = "allow" # OutputBuilder::to_string is intentional naming
ptr_arg = "allow" # &Vec vs &[_] requires API changes
only_used_in_recursion = "allow" # Not a problem
arc_with_non_send_sync = "allow" # May be intentional for single-threaded use
large_stack_arrays = "allow" # May be intentional for performance
enum_variant_names = "allow" # Stylistic preference
items_after_test_module = "allow" # Module organization preference
result_unit_err = "allow" # API design choice
assertions_on_constants = "allow" # Used for test documentation
doc_lazy_continuation = "allow" # Doc formatting preference
doc_overindented_list_items = "allow" # Doc formatting preference
match_like_matches_macro = "allow" # Sometimes match is clearer
suspicious_doc_comments = "allow" # False positives
needless_else = "allow" # Sometimes improves readability
if_same_then_else = "allow" # May be intentional for clarity
assigning_clones = "allow" # Requires many changes for marginal benefit
cloned_ref_to_slice_refs = "allow" # Minor optimization
manual_strip = "allow" # Sometimes clearer than strip_prefix
needless_range_loop = "allow" # Sometimes index access is intentional
const_is_empty = "allow" # False positive in tests
needless_for_each = "allow" # Style preference
# Keep these as warnings
cfg_not_test = "warn"
checked_conversions = "warn"
cloned_instead_of_copied = "warn"
copy_iterator = "warn"
dbg_macro = "warn"
empty_drop = "warn"
empty_enum = "warn"
empty_enum_variants_with_brackets = "warn"
expl_impl_clone_on_copy = "warn"
explicit_into_iter_loop = "warn"
filter_map_next = "warn"
flat_map_option = "warn"
float_cmp_const = "warn"
from_iter_instead_of_collect = "warn"
get_unwrap = "warn"
implicit_clone = "warn"
implicit_hasher = "warn"
index_refutable_slice = "warn"
inefficient_to_string = "warn"
invalid_upcast_comparisons = "warn"
iter_filter_is_ok = "warn"
iter_not_returning_iterator = "warn"
large_types_passed_by_value = "warn"
lossy_float_literal = "warn"
macro_use_imports = "warn"
manual_is_variant_and = "warn"
manual_ok_or = "warn"
manual_string_new = "warn"
map_flatten = "warn"
map_unwrap_or = "warn"
mismatching_type_param_order = "warn"
mut_mut = "warn"
naive_bytecount = "warn"
needless_bitwise_bool = "warn"
needless_continue = "allow" # Sometimes continue is clearer for control flow
no_effect_underscore_binding = "warn"
option_as_ref_cloned = "warn"
rc_buffer = "warn"
rc_mutex = "warn"
ref_binding_to_reference = "warn"
ref_option_ref = "warn"
rest_pat_in_fully_bound_structs = "warn"
single_char_pattern = "warn"
stable_sort_primitive = "warn"
str_split_at_newline = "warn"
string_lit_chars_any = "warn"
unnecessary_box_returns = "warn"
unnecessary_join = "warn"
unnested_or_patterns = "warn"
unreadable_literal = "warn"
verbose_bit_mask = "warn"
verbose_file_reads = "warn"
[patch.crates-io]
lua-src = { path = "crates/lua-src-wasm" }
# Fork of runtimelib that adds venv-aware kernelspec discovery
# (`data_dirs_with_jupyter_paths`, `find_kernelspec_with_jupyter_paths`)
# and threads `searched_paths` through `RuntimeError::KernelNotFound`.
# Pinned to a SHA on cscheid/runtimed; will be removed once the
# upstream PR (bd-875x) lands and a release ships.
runtimelib = { git = "https://github.com/cscheid/runtimed", rev = "fc58eb48139a30cc559ac5973cb6debb00375b88" }
# `runtimelib` depends on `jupyter-protocol` via the runtimed workspace,
# so we must patch jupyter-protocol from the same SHA to avoid pulling
# in two distinct `jupyter_protocol::JupyterMessage` types.
jupyter-protocol = { git = "https://github.com/cscheid/runtimed", rev = "fc58eb48139a30cc559ac5973cb6debb00375b88" }
# Profiles must be set at the workspace level
[profile.dev]
# Tell `rustc` to optimize for small code size to
# work around "too many locals" error from wasm-pack
# https://github.com/wasm-bindgen/wasm-bindgen/issues/3451#issuecomment-1562982835
opt-level = "s"
# CI-only profile (used by `.github/workflows/test-suite.yml`). Strips
# debuginfo to fit GHA disk. Locally, omit `--cargo-profile ci` to get
# full debuginfo via the default `dev` profile.
# See claude-notes/2026-04-28-ci-disk-space-and-profile-ci.md.
[profile.ci]
inherits = "dev"
debug = "line-tables-only"
[profile.ci.package."*"]
debug = false
# Release-like profile with debug info preserved for profilers (samply, etc.).
# Used by perf-harness drivers; see claude-notes/instructions/performance-profiling.md.
[profile.release-perf]
inherits = "release"
debug = true
# samply / perf need unstripped symbols. Also keep inlining info for meaningful
# stacks — release's default `codegen-units` still lets LLVM inline aggressively,
# which is what we want to profile.
strip = false