Skip to content

Commit cf352d2

Browse files
committed
feat: initial setup for DAP debugger
This commit forms the initial infrastructure for building the DAP service which VS Code can interact with to debug smart contracts within the IDE.
1 parent 07da4f3 commit cf352d2

File tree

7 files changed

+1067
-15
lines changed

7 files changed

+1067
-15
lines changed

Cargo.lock

Lines changed: 27 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 37 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,11 @@ keywords = ["blockstack", "blockchain", "clarity", "smart-contract", "repl"]
1010
exclude = ["examples/**"]
1111
homepage = "https://github.com/hirosystems/clarinet"
1212
repository = "https://github.com/hirosystems/clarinet"
13-
categories = ["command-line-utilities", "development-tools", "development-tools::build-utils"]
13+
categories = [
14+
"command-line-utilities",
15+
"development-tools",
16+
"development-tools::build-utils",
17+
]
1418

1519
[target.'cfg(windows)'.build-dependencies]
1620
winapi = "0.3.9"
@@ -20,7 +24,7 @@ winres = "0.1.11"
2024
clap = { version = "3.1.6", features = ["derive"], optional = true }
2125
clap_generate = { version = "3.0.3", optional = true }
2226
toml = { version = "0.5.6", features = ["preserve_order"] }
23-
serde = "1"
27+
serde = { version = "1", features = ["derive"] }
2428
serde_json = "1"
2529
serde_derive = "1"
2630
deno_core = { path = "./vendor/deno/core", optional = true }
@@ -38,7 +42,7 @@ libsecp256k1 = "0.7.0"
3842
sha2 = "0.10.0"
3943
uuid = { version = "0.8.2", features = ["v4"] }
4044
hmac = "0.12.0"
41-
pbkdf2 = { version = "0.11.0", features=["simple"], default-features = false }
45+
pbkdf2 = { version = "0.11.0", features = ["simple"], default-features = false }
4246
futures = "0.3.12"
4347
tokio = { version = "=1.15.0", features = ["full"] }
4448
lazy_static = "1.4.0"
@@ -54,7 +58,11 @@ pin-project = "1.0.5"
5458
indexmap = { version = "1.6.1", features = ["serde"] }
5559
shell-escape = "0.1.5"
5660
tiny-hderive = "0.3.0"
57-
reqwest = { version = "0.11", default-features = false, features = ["blocking", "json", "rustls-tls"] }
61+
reqwest = { version = "0.11", default-features = false, features = [
62+
"blocking",
63+
"json",
64+
"rustls-tls",
65+
] }
5866
swc_common = { version = "0.10.20", features = ["sourcemap"], optional = true }
5967
bollard = "0.11.0"
6068
rocket = { version = "=0.5.0-rc.1", features = ["json"] }
@@ -73,6 +81,11 @@ mac_address = { version = "1.1.2", optional = true }
7381
tower-lsp = { version = "0.14.0", optional = true }
7482
hex = "0.4.3"
7583
dirs = "4.0.0"
84+
tokio-util = { version = "0.7.1", features = ["codec"] }
85+
httparse = "1.6.0"
86+
bytes = "1.1.0"
87+
log = "0.4.16"
88+
memchr = "2.4.1"
7689

7790
[dependencies.tui]
7891
version = "0.16.0"
@@ -81,7 +94,16 @@ features = ["crossterm"]
8194

8295
[target.'cfg(windows)'.dependencies]
8396
fwdansi = "1.1.0"
84-
winapi = { version = "0.3.9", features = ["knownfolders", "mswsock", "objbase", "shlobj", "tlhelp32", "winbase", "winerror", "winsock2"] }
97+
winapi = { version = "0.3.9", features = [
98+
"knownfolders",
99+
"mswsock",
100+
"objbase",
101+
"shlobj",
102+
"tlhelp32",
103+
"winbase",
104+
"winerror",
105+
"winsock2",
106+
] }
85107

86108
[package.metadata.winres]
87109
OriginalFilename = "clarinet.exe"
@@ -100,7 +122,15 @@ path = "src/bin.rs"
100122

101123
[features]
102124
default = ["cli", "telemetry"]
103-
cli = ["swc_common", "deno", "deno_runtime", "deno_core", "clap", "clap_generate", "tower-lsp"]
125+
cli = [
126+
"swc_common",
127+
"deno",
128+
"deno_runtime",
129+
"deno_core",
130+
"clap",
131+
"clap_generate",
132+
"tower-lsp",
133+
]
104134
telemetry = ["segment", "mac_address"]
105135

106136
[workspace]
@@ -110,5 +140,5 @@ members = [
110140
"vendor/deno/runtime/",
111141
"vendor/deno/core/",
112142
"xtask/",
113-
"node-bindings"
143+
"node-bindings",
114144
]

src/bin.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ mod generate;
2020
mod indexer;
2121
mod integrate;
2222
mod lsp;
23+
mod dap;
2324
mod poke;
2425
mod publish;
2526
mod runnner;

0 commit comments

Comments
 (0)