From 211f7861849754660240de7904202e9ca179a160 Mon Sep 17 00:00:00 2001 From: ian Date: Tue, 3 Dec 2024 10:37:46 +0800 Subject: [PATCH 1/3] chore: add missing feature macros of tokio --- util/metrics-service/Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/metrics-service/Cargo.toml b/util/metrics-service/Cargo.toml index 8a351a49c2..3cc68975bb 100644 --- a/util/metrics-service/Cargo.toml +++ b/util/metrics-service/Cargo.toml @@ -19,4 +19,4 @@ hyper = { version = "1", features = ["http1", "http2", "server"] } http-body-util = "0.1" hyper-util = { version = "0.1", features = ["server-auto", "server-graceful"] } ckb-stop-handler = { path = "../stop-handler", version = "= 0.120.0-pre" } -tokio = { version = "1", features = ["sync"] } +tokio = { version = "1", features = ["sync", "macros"] } From 3a99b509b70d98bbec6d7b48f7984ab08db2fa86 Mon Sep 17 00:00:00 2001 From: ian Date: Tue, 3 Dec 2024 11:44:36 +0800 Subject: [PATCH 2/3] chore: add missing feature tokio-runtime of cacache --- Cargo.lock | 3 +++ spec/Cargo.toml | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/Cargo.lock b/Cargo.lock index 76598211da..81294b3686 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -468,6 +468,7 @@ checksum = "a61ff12b19d89c752c213316b87fdb4a587f073d219b893cc56974b8c9f39bf7" dependencies = [ "digest", "either", + "futures", "hex", "libc", "memmap2", @@ -481,6 +482,8 @@ dependencies = [ "ssri", "tempfile", "thiserror", + "tokio", + "tokio-stream", "walkdir", ] diff --git a/spec/Cargo.toml b/spec/Cargo.toml index f7694c62a5..9ad6c386de 100644 --- a/spec/Cargo.toml +++ b/spec/Cargo.toml @@ -25,7 +25,10 @@ ckb-traits = { path = "../traits", version = "= 0.120.0-pre" } ckb-logger = { path = "../util/logger", version = "= 0.120.0-pre" } [target.'cfg(not(target_family = "wasm"))'.dependencies] -cacache = { version = "13.0.0", default-features = false, features = ["mmap"] } +cacache = { version = "13.0.0", default-features = false, features = [ + "tokio-runtime", + "mmap", +] } [dev-dependencies] tempfile.workspace = true From 40b3840578653c9e0f029aeb151639dc39dd626e Mon Sep 17 00:00:00 2001 From: ian Date: Tue, 3 Dec 2024 16:05:56 +0800 Subject: [PATCH 3/3] chore: add missing tokio::process for notify --- notify/Cargo.toml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/notify/Cargo.toml b/notify/Cargo.toml index 49a3ff5d81..013ea4c282 100644 --- a/notify/Cargo.toml +++ b/notify/Cargo.toml @@ -10,10 +10,15 @@ repository = "https://github.com/nervosnetwork/ckb" [dependencies] ckb-logger = { path = "../util/logger", version = "= 0.120.0-pre" } -ckb-app-config = { path = "../util/app-config", version = "= 0.120.0-pre" } +ckb-app-config = { path = "../util/app-config", version = "= 0.120.0-pre" } ckb-types = { path = "../util/types", version = "= 0.120.0-pre" } ckb-stop-handler = { path = "../util/stop-handler", version = "= 0.120.0-pre" } ckb-async-runtime = { path = "../util/runtime", version = "= 0.120.0-pre" } + +[target.'cfg(target_family = "wasm")'.dependencies] tokio = { version = "1", features = ["sync"] } +[target.'cfg(not(target_family = "wasm"))'.dependencies] +tokio = { version = "1", features = ["sync", "process"] } + [dev-dependencies]