mirror of
https://github.com/uqbar-dao/nectar.git
synced 2024-11-25 07:07:06 +03:00
fix: kns_indexer, update all packages to process_lib 0.7.0, change default providers
This commit is contained in:
parent
a0e78c1978
commit
cca3133b61
367
Cargo.lock
generated
367
Cargo.lock
generated
@ -78,7 +78,7 @@ name = "alias"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
@ -90,36 +90,85 @@ version = "0.2.18"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5c6cb57a04249c6480766f7f7cef5467412af1490f8d1e243141daddada3264f"
|
||||
|
||||
[[package]]
|
||||
name = "alloy-consensus"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=cad7935#cad7935d69f433e45d190902e58b1c996b35adfa"
|
||||
dependencies = [
|
||||
"alloy-eips 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=cad7935)",
|
||||
"alloy-primitives 0.7.0",
|
||||
"alloy-rlp",
|
||||
"alloy-serde",
|
||||
"c-kzg",
|
||||
"serde",
|
||||
"sha2",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-eips"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-primitives",
|
||||
"alloy-primitives 0.6.4",
|
||||
"alloy-rlp",
|
||||
"serde",
|
||||
"thiserror",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-eips"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=cad7935#cad7935d69f433e45d190902e58b1c996b35adfa"
|
||||
dependencies = [
|
||||
"alloy-primitives 0.7.0",
|
||||
"alloy-rlp",
|
||||
"alloy-serde",
|
||||
"c-kzg",
|
||||
"once_cell",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-genesis"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=cad7935#cad7935d69f433e45d190902e58b1c996b35adfa"
|
||||
dependencies = [
|
||||
"alloy-primitives 0.7.0",
|
||||
"alloy-serde",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-json-rpc"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-primitives",
|
||||
"alloy-primitives 0.6.4",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"thiserror",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-json-rpc"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=cad7935#cad7935d69f433e45d190902e58b1c996b35adfa"
|
||||
dependencies = [
|
||||
"alloy-primitives 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"thiserror",
|
||||
"tracing",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-network"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-eips",
|
||||
"alloy-json-rpc",
|
||||
"alloy-primitives",
|
||||
"alloy-eips 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-json-rpc 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-primitives 0.6.4",
|
||||
"alloy-rlp",
|
||||
"serde",
|
||||
]
|
||||
@ -146,17 +195,39 @@ dependencies = [
|
||||
"tiny-keccak",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-primitives"
|
||||
version = "0.7.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "99bbad0a6b588ef4aec1b5ddbbfdacd9ef04e00b979617765b03174318ee1f3a"
|
||||
dependencies = [
|
||||
"alloy-rlp",
|
||||
"bytes",
|
||||
"cfg-if",
|
||||
"const-hex",
|
||||
"derive_more",
|
||||
"hex-literal",
|
||||
"itoa",
|
||||
"k256",
|
||||
"keccak-asm",
|
||||
"proptest",
|
||||
"rand 0.8.5",
|
||||
"ruint",
|
||||
"serde",
|
||||
"tiny-keccak",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-providers"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-network",
|
||||
"alloy-primitives",
|
||||
"alloy-primitives 0.6.4",
|
||||
"alloy-rpc-client",
|
||||
"alloy-rpc-trace-types",
|
||||
"alloy-rpc-types",
|
||||
"alloy-transport",
|
||||
"alloy-rpc-types 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-transport 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-transport-http",
|
||||
"async-trait",
|
||||
"auto_impl",
|
||||
@ -170,9 +241,9 @@ name = "alloy-pubsub"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-json-rpc",
|
||||
"alloy-primitives",
|
||||
"alloy-transport",
|
||||
"alloy-json-rpc 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-primitives 0.6.4",
|
||||
"alloy-transport 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"bimap",
|
||||
"futures",
|
||||
"serde",
|
||||
@ -209,10 +280,10 @@ name = "alloy-rpc-client"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-json-rpc",
|
||||
"alloy-primitives",
|
||||
"alloy-json-rpc 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-primitives 0.6.4",
|
||||
"alloy-pubsub",
|
||||
"alloy-transport",
|
||||
"alloy-transport 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-transport-http",
|
||||
"alloy-transport-ws",
|
||||
"futures",
|
||||
@ -230,8 +301,8 @@ name = "alloy-rpc-trace-types"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-primitives",
|
||||
"alloy-rpc-types",
|
||||
"alloy-primitives 0.6.4",
|
||||
"alloy-rpc-types 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"serde",
|
||||
"serde_json",
|
||||
]
|
||||
@ -241,7 +312,7 @@ name = "alloy-rpc-types"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-primitives",
|
||||
"alloy-primitives 0.6.4",
|
||||
"alloy-rlp",
|
||||
"itertools 0.12.1",
|
||||
"serde",
|
||||
@ -249,13 +320,41 @@ dependencies = [
|
||||
"thiserror",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-rpc-types"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=cad7935#cad7935d69f433e45d190902e58b1c996b35adfa"
|
||||
dependencies = [
|
||||
"alloy-consensus",
|
||||
"alloy-eips 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=cad7935)",
|
||||
"alloy-genesis",
|
||||
"alloy-primitives 0.7.0",
|
||||
"alloy-rlp",
|
||||
"alloy-serde",
|
||||
"alloy-sol-types 0.7.0",
|
||||
"itertools 0.12.1",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"thiserror",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-serde"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=cad7935#cad7935d69f433e45d190902e58b1c996b35adfa"
|
||||
dependencies = [
|
||||
"alloy-primitives 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-signer"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-network",
|
||||
"alloy-primitives",
|
||||
"alloy-primitives 0.6.4",
|
||||
"async-trait",
|
||||
"auto_impl",
|
||||
"elliptic-curve",
|
||||
@ -278,18 +377,63 @@ dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"syn 2.0.60",
|
||||
"syn-solidity",
|
||||
"syn-solidity 0.6.4",
|
||||
"tiny-keccak",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-sol-macro"
|
||||
version = "0.7.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "452d929748ac948a10481fff4123affead32c553cf362841c5103dd508bdfc16"
|
||||
dependencies = [
|
||||
"alloy-sol-macro-input",
|
||||
"const-hex",
|
||||
"heck 0.4.1",
|
||||
"indexmap",
|
||||
"proc-macro-error",
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"syn 2.0.60",
|
||||
"syn-solidity 0.7.0",
|
||||
"tiny-keccak",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-sol-macro-input"
|
||||
version = "0.7.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "df64e094f6d2099339f9e82b5b38440b159757b6920878f28316243f8166c8d1"
|
||||
dependencies = [
|
||||
"const-hex",
|
||||
"dunce",
|
||||
"heck 0.5.0",
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"syn 2.0.60",
|
||||
"syn-solidity 0.7.0",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-sol-types"
|
||||
version = "0.6.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "ad09ec5853fa700d12d778ad224dcdec636af424d29fad84fb9a2f16a5b0ef09"
|
||||
dependencies = [
|
||||
"alloy-primitives",
|
||||
"alloy-sol-macro",
|
||||
"alloy-primitives 0.6.4",
|
||||
"alloy-sol-macro 0.6.4",
|
||||
"const-hex",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-sol-types"
|
||||
version = "0.7.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "43bc2d6dfc2a19fd56644494479510f98b1ee929e04cf0d4aa45e98baa3e545b"
|
||||
dependencies = [
|
||||
"alloy-primitives 0.7.0",
|
||||
"alloy-sol-macro 0.7.0",
|
||||
"const-hex",
|
||||
"serde",
|
||||
]
|
||||
@ -299,7 +443,7 @@ name = "alloy-transport"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-json-rpc",
|
||||
"alloy-json-rpc 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"base64 0.21.7",
|
||||
"futures-util",
|
||||
"serde",
|
||||
@ -311,13 +455,31 @@ dependencies = [
|
||||
"wasm-bindgen-futures",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-transport"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=cad7935#cad7935d69f433e45d190902e58b1c996b35adfa"
|
||||
dependencies = [
|
||||
"alloy-json-rpc 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=cad7935)",
|
||||
"base64 0.22.0",
|
||||
"futures-util",
|
||||
"futures-utils-wasm",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"thiserror",
|
||||
"tokio",
|
||||
"tower",
|
||||
"url",
|
||||
"wasm-bindgen-futures",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "alloy-transport-http"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-json-rpc",
|
||||
"alloy-transport",
|
||||
"alloy-json-rpc 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-transport 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"reqwest 0.11.27",
|
||||
"serde_json",
|
||||
"tower",
|
||||
@ -330,7 +492,7 @@ version = "0.1.0"
|
||||
source = "git+https://github.com/alloy-rs/alloy?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08"
|
||||
dependencies = [
|
||||
"alloy-pubsub",
|
||||
"alloy-transport",
|
||||
"alloy-transport 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"futures",
|
||||
"http 0.2.12",
|
||||
"serde_json",
|
||||
@ -417,13 +579,13 @@ checksum = "f538837af36e6f6a9be0faa67f9a314f8119e4e4b5867c6ab40ed60360142519"
|
||||
|
||||
[[package]]
|
||||
name = "app_store"
|
||||
version = "0.3.0"
|
||||
version = "0.3.1"
|
||||
dependencies = [
|
||||
"alloy-primitives",
|
||||
"alloy-sol-types",
|
||||
"alloy-primitives 0.7.0",
|
||||
"alloy-sol-types 0.7.0",
|
||||
"anyhow",
|
||||
"bincode",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"rand 0.8.5",
|
||||
"serde",
|
||||
"serde_json",
|
||||
@ -778,6 +940,18 @@ dependencies = [
|
||||
"generic-array 0.14.7",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "blst"
|
||||
version = "0.3.11"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c94087b935a822949d3291a9989ad2b2051ea141eda0fd4e478a75f6aa3e604b"
|
||||
dependencies = [
|
||||
"cc",
|
||||
"glob",
|
||||
"threadpool",
|
||||
"zeroize",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "bumpalo"
|
||||
version = "3.16.0"
|
||||
@ -826,6 +1000,20 @@ dependencies = [
|
||||
"pkg-config",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "c-kzg"
|
||||
version = "1.0.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3130f3d8717cc02e668a896af24984d5d5d4e8bf12e278e982e0f1bd88a0f9af"
|
||||
dependencies = [
|
||||
"blst",
|
||||
"cc",
|
||||
"glob",
|
||||
"hex",
|
||||
"libc",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "cap-fs-ext"
|
||||
version = "3.0.0"
|
||||
@ -908,7 +1096,7 @@ name = "cat"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
@ -966,12 +1154,12 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "chess"
|
||||
version = "0.2.0"
|
||||
version = "0.2.1"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"base64 0.22.0",
|
||||
"bincode",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"pleco",
|
||||
"serde",
|
||||
"serde_json",
|
||||
@ -1683,7 +1871,7 @@ name = "download"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
@ -1714,7 +1902,7 @@ name = "echo"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
@ -1934,7 +2122,7 @@ version = "0.2.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"bincode",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"rand 0.8.5",
|
||||
"serde",
|
||||
"serde_json",
|
||||
@ -2042,6 +2230,12 @@ dependencies = [
|
||||
"slab",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "futures-utils-wasm"
|
||||
version = "0.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "42012b0f064e01aa58b545fe3727f90f7dd4020f4a3ea735b50344965f5a57e9"
|
||||
|
||||
[[package]]
|
||||
name = "fxhash"
|
||||
version = "0.2.1"
|
||||
@ -2088,7 +2282,7 @@ dependencies = [
|
||||
name = "get_block"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
@ -2288,7 +2482,7 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46"
|
||||
name = "hi"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
@ -2314,11 +2508,11 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "homepage"
|
||||
version = "0.1.0"
|
||||
version = "0.1.1"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"bincode",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
@ -2629,7 +2823,7 @@ name = "install"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
@ -2788,17 +2982,17 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "kinode"
|
||||
version = "0.7.0"
|
||||
version = "0.7.1"
|
||||
dependencies = [
|
||||
"aes-gcm",
|
||||
"alloy-primitives",
|
||||
"alloy-primitives 0.6.4",
|
||||
"alloy-providers",
|
||||
"alloy-pubsub",
|
||||
"alloy-rpc-client",
|
||||
"alloy-rpc-types",
|
||||
"alloy-rpc-types 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-signer",
|
||||
"alloy-sol-macro",
|
||||
"alloy-sol-types",
|
||||
"alloy-sol-macro 0.6.4",
|
||||
"alloy-sol-types 0.6.4",
|
||||
"alloy-transport-ws",
|
||||
"anyhow",
|
||||
"async-trait",
|
||||
@ -2861,7 +3055,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "kinode_lib"
|
||||
version = "0.7.0"
|
||||
version = "0.7.1"
|
||||
dependencies = [
|
||||
"lib",
|
||||
]
|
||||
@ -2871,10 +3065,10 @@ name = "kinode_process_lib"
|
||||
version = "0.6.0"
|
||||
source = "git+https://github.com/kinode-dao/process_lib?rev=84b3d84#84b3d84c7c31185f15691a288f1b45dbffb18fe2"
|
||||
dependencies = [
|
||||
"alloy-json-rpc",
|
||||
"alloy-primitives",
|
||||
"alloy-rpc-types",
|
||||
"alloy-transport",
|
||||
"alloy-json-rpc 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-primitives 0.6.4",
|
||||
"alloy-rpc-types 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"alloy-transport 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"anyhow",
|
||||
"bincode",
|
||||
"http 1.1.0",
|
||||
@ -2889,13 +3083,13 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "kinode_process_lib"
|
||||
version = "0.6.1"
|
||||
source = "git+https://github.com/kinode-dao/process_lib?tag=v0.6.1#37a20b0249dc2c86ae6c2c69cfb199fb177f1520"
|
||||
version = "0.7.0"
|
||||
source = "git+https://github.com/kinode-dao/process_lib?tag=v0.7.0#b7c0abee62df683e6c78069c87072a1d52602408"
|
||||
dependencies = [
|
||||
"alloy-json-rpc",
|
||||
"alloy-primitives",
|
||||
"alloy-rpc-types",
|
||||
"alloy-transport",
|
||||
"alloy-json-rpc 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=cad7935)",
|
||||
"alloy-primitives 0.7.0",
|
||||
"alloy-rpc-types 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=cad7935)",
|
||||
"alloy-transport 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=cad7935)",
|
||||
"anyhow",
|
||||
"bincode",
|
||||
"http 1.1.0",
|
||||
@ -2945,14 +3139,14 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "kns_indexer"
|
||||
version = "0.2.0"
|
||||
version = "0.2.1"
|
||||
dependencies = [
|
||||
"alloy-primitives",
|
||||
"alloy-sol-types",
|
||||
"alloy-primitives 0.7.0",
|
||||
"alloy-sol-types 0.7.0",
|
||||
"anyhow",
|
||||
"bincode",
|
||||
"hex",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"rmp-serde",
|
||||
"serde",
|
||||
"serde_json",
|
||||
@ -2979,9 +3173,9 @@ checksum = "884e2677b40cc8c339eaefcb701c32ef1fd2493d71118dc0ca4b6a736c93bd67"
|
||||
|
||||
[[package]]
|
||||
name = "lib"
|
||||
version = "0.7.0"
|
||||
version = "0.7.1"
|
||||
dependencies = [
|
||||
"alloy-rpc-types",
|
||||
"alloy-rpc-types 0.1.0 (git+https://github.com/alloy-rs/alloy?rev=6f8ebb4)",
|
||||
"anyhow",
|
||||
"kit",
|
||||
"lazy_static",
|
||||
@ -3153,7 +3347,7 @@ version = "0.1.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"clap",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"regex",
|
||||
"serde",
|
||||
"serde_json",
|
||||
@ -3285,7 +3479,7 @@ dependencies = [
|
||||
name = "namehash_to_name"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"rmp-serde",
|
||||
"serde",
|
||||
"wit-bindgen",
|
||||
@ -3313,7 +3507,7 @@ dependencies = [
|
||||
name = "net_diagnostics"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"rmp-serde",
|
||||
"serde",
|
||||
"wit-bindgen",
|
||||
@ -3606,7 +3800,7 @@ dependencies = [
|
||||
name = "peer"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"rmp-serde",
|
||||
"serde",
|
||||
"wit-bindgen",
|
||||
@ -3616,7 +3810,7 @@ dependencies = [
|
||||
name = "peers"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"rmp-serde",
|
||||
"serde",
|
||||
"wit-bindgen",
|
||||
@ -4829,7 +5023,7 @@ checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3"
|
||||
name = "state"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
@ -4910,6 +5104,18 @@ dependencies = [
|
||||
"syn 2.0.60",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "syn-solidity"
|
||||
version = "0.7.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "4497156948bd342b52038035a6fa514a89626e37af9d2c52a5e8d8ebcc7ee479"
|
||||
dependencies = [
|
||||
"paste",
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"syn 2.0.60",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "sync_wrapper"
|
||||
version = "0.1.2"
|
||||
@ -4979,11 +5185,11 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "terminal"
|
||||
version = "0.1.0"
|
||||
version = "0.1.1"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"bincode",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"rand 0.8.5",
|
||||
"regex",
|
||||
"serde",
|
||||
@ -4997,7 +5203,7 @@ version = "0.1.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"bincode",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"thiserror",
|
||||
@ -5006,12 +5212,12 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "tester"
|
||||
version = "0.1.0"
|
||||
version = "0.1.1"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"bincode",
|
||||
"indexmap",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"thiserror",
|
||||
@ -5048,6 +5254,15 @@ dependencies = [
|
||||
"once_cell",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "threadpool"
|
||||
version = "1.8.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa"
|
||||
dependencies = [
|
||||
"num_cpus",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "time"
|
||||
version = "0.3.36"
|
||||
@ -5243,7 +5458,7 @@ name = "top"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
@ -5565,7 +5780,7 @@ name = "uninstall"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"kinode_process_lib 0.6.1",
|
||||
"kinode_process_lib 0.7.0",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"wit-bindgen",
|
||||
|
@ -1,7 +1,7 @@
|
||||
[package]
|
||||
name = "kinode_lib"
|
||||
authors = ["KinodeDAO"]
|
||||
version = "0.7.0"
|
||||
version = "0.7.1"
|
||||
edition = "2021"
|
||||
description = "A general-purpose sovereign cloud computing platform"
|
||||
homepage = "https://kinode.org"
|
||||
|
@ -1,7 +1,7 @@
|
||||
[package]
|
||||
name = "kinode"
|
||||
authors = ["KinodeDAO"]
|
||||
version = "0.7.0"
|
||||
version = "0.7.1"
|
||||
edition = "2021"
|
||||
description = "A general-purpose sovereign cloud computing platform"
|
||||
homepage = "https://kinode.org"
|
||||
|
@ -1,17 +1,17 @@
|
||||
[package]
|
||||
name = "app_store"
|
||||
version = "0.3.0"
|
||||
version = "0.3.1"
|
||||
edition = "2021"
|
||||
|
||||
[features]
|
||||
simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
alloy-primitives = "0.6.2"
|
||||
alloy-sol-types = "0.6.2"
|
||||
alloy-primitives = "0.7.0"
|
||||
alloy-sol-types = "0.7.0"
|
||||
anyhow = "1.0"
|
||||
bincode = "1.3.3"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
rand = "0.8"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
|
@ -41,6 +41,7 @@ const ICON: &str = include_str!("icon");
|
||||
|
||||
const CHAIN_ID: u64 = 10; // optimism
|
||||
const CONTRACT_ADDRESS: &str = "0x52185B6a6017E6f079B994452F234f7C2533787B"; // optimism
|
||||
const CONTRACT_FIRST_BLOCK: u64 = 118_590_088;
|
||||
|
||||
const EVENTS: [&str; 3] = [
|
||||
"AppRegistered(uint256,string,bytes,string,bytes32)",
|
||||
|
@ -111,7 +111,7 @@ impl State {
|
||||
crate::print_to_terminal(1, "producing new state");
|
||||
let mut state = State {
|
||||
contract_address,
|
||||
last_saved_block: 1,
|
||||
last_saved_block: crate::CONTRACT_FIRST_BLOCK,
|
||||
package_hashes: HashMap::new(),
|
||||
listed_packages: HashMap::new(),
|
||||
downloaded_packages: HashMap::new(),
|
||||
@ -371,14 +371,16 @@ impl State {
|
||||
.ok_or(anyhow::anyhow!("got log with no block number"))?
|
||||
.try_into()?;
|
||||
|
||||
// let package_hash: alloy_primitives::U256 = log.topics[1].into();
|
||||
// let package_hash = package_hash.to_string();
|
||||
|
||||
match log.topics[0] {
|
||||
match log.topics()[0] {
|
||||
AppRegistered::SIGNATURE_HASH => {
|
||||
let package_hash = log.topics[1];
|
||||
let (package_name, publisher_dnswire, metadata_url, metadata_hash) =
|
||||
AppRegistered::abi_decode_data(&log.data, true)?;
|
||||
let package_hash = log.topics()[1];
|
||||
|
||||
let app = AppRegistered::decode_log_data(log.data(), false)?;
|
||||
let package_name = app.packageName;
|
||||
let publisher_dnswire = app.publisherName;
|
||||
let metadata_url = app.metadataUrl;
|
||||
let metadata_hash = app.metadataHash;
|
||||
|
||||
let package_hash = package_hash.to_string();
|
||||
let metadata_hash = metadata_hash.to_string();
|
||||
|
||||
@ -390,13 +392,14 @@ impl State {
|
||||
),
|
||||
);
|
||||
|
||||
if generate_package_hash(&package_name, publisher_dnswire.as_slice())
|
||||
if generate_package_hash(&package_name, publisher_dnswire.to_vec().as_slice())
|
||||
!= package_hash
|
||||
{
|
||||
return Err(anyhow::anyhow!("got log with mismatched package hash"));
|
||||
}
|
||||
|
||||
let Ok(publisher_name) = dnswire_decode(publisher_dnswire.as_slice()) else {
|
||||
let Ok(publisher_name) = dnswire_decode(publisher_dnswire.to_vec().as_slice())
|
||||
else {
|
||||
return Err(anyhow::anyhow!("got log with invalid publisher name"));
|
||||
};
|
||||
|
||||
@ -430,9 +433,12 @@ impl State {
|
||||
self.insert_listing(package_hash, listing);
|
||||
}
|
||||
AppMetadataUpdated::SIGNATURE_HASH => {
|
||||
let package_hash = log.topics[1].to_string();
|
||||
let (metadata_url, metadata_hash) =
|
||||
AppMetadataUpdated::abi_decode_data(&log.data, false)?;
|
||||
let package_hash = log.topics()[1].to_string();
|
||||
|
||||
let upd = AppMetadataUpdated::decode_log_data(log.data(), false)?;
|
||||
let metadata_url = upd.metadataUrl;
|
||||
let metadata_hash = upd.metadataHash;
|
||||
|
||||
let metadata_hash = metadata_hash.to_string();
|
||||
|
||||
let current_listing = self
|
||||
@ -484,9 +490,9 @@ impl State {
|
||||
}
|
||||
}
|
||||
Transfer::SIGNATURE_HASH => {
|
||||
let from = alloy_primitives::Address::from_word(log.topics[1]);
|
||||
let to = alloy_primitives::Address::from_word(log.topics[2]);
|
||||
let package_hash = log.topics[3].to_string();
|
||||
let from = alloy_primitives::Address::from_word(log.topics()[1]);
|
||||
let to = alloy_primitives::Address::from_word(log.topics()[2]);
|
||||
let package_hash = log.topics()[3].to_string();
|
||||
|
||||
if from == alloy_primitives::Address::ZERO {
|
||||
match self.get_listing_with_hash_mut(&package_hash) {
|
||||
|
@ -8,7 +8,7 @@ simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -9,7 +9,7 @@ simulation-mode = []
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
bincode = "1.3.3"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
rand = "0.8"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
|
@ -8,7 +8,7 @@ simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -4,11 +4,11 @@
|
||||
"image": "",
|
||||
"properties": {
|
||||
"package_name": "app_store",
|
||||
"current_version": "0.3.0",
|
||||
"current_version": "0.3.1",
|
||||
"publisher": "sys",
|
||||
"mirrors": [],
|
||||
"code_hashes": {
|
||||
"0.3.0": ""
|
||||
"0.3.1": ""
|
||||
}
|
||||
},
|
||||
"external_url": "https://kinode.org",
|
||||
|
@ -8,7 +8,7 @@ simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "chess"
|
||||
version = "0.2.0"
|
||||
version = "0.2.1"
|
||||
edition = "2021"
|
||||
|
||||
[features]
|
||||
@ -10,7 +10,7 @@ simulation-mode = []
|
||||
anyhow = "1.0"
|
||||
base64 = "0.22.0"
|
||||
bincode = "1.3.3"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
pleco = "0.5"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
|
@ -4,11 +4,11 @@
|
||||
"image": "",
|
||||
"properties": {
|
||||
"package_name": "chess",
|
||||
"current_version": "0.2.0",
|
||||
"current_version": "0.2.1",
|
||||
"publisher": "sys",
|
||||
"mirrors": [],
|
||||
"code_hashes": {
|
||||
"0.2.0": ""
|
||||
"0.2.1": ""
|
||||
}
|
||||
},
|
||||
"external_url": "https://kinode.org",
|
||||
|
@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "homepage"
|
||||
version = "0.1.0"
|
||||
version = "0.1.1"
|
||||
edition = "2021"
|
||||
|
||||
[features]
|
||||
@ -9,7 +9,7 @@ simulation-mode = []
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
bincode = "1.3.3"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -4,11 +4,11 @@
|
||||
"image": "",
|
||||
"properties": {
|
||||
"package_name": "homepage",
|
||||
"current_version": "0.1.0",
|
||||
"current_version": "0.1.1",
|
||||
"publisher": "sys",
|
||||
"mirrors": [],
|
||||
"code_hashes": {
|
||||
"0.1.0": ""
|
||||
"0.1.1": ""
|
||||
}
|
||||
},
|
||||
"external_url": "https://kinode.org",
|
||||
|
@ -7,7 +7,7 @@ edition = "2021"
|
||||
simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "kns_indexer"
|
||||
version = "0.2.0"
|
||||
version = "0.2.1"
|
||||
edition = "2021"
|
||||
|
||||
[features]
|
||||
@ -8,11 +8,11 @@ simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
alloy-primitives = "0.6.2"
|
||||
alloy-sol-types = "0.6.2"
|
||||
alloy-primitives = "0.7.0"
|
||||
alloy-sol-types = "0.7.0"
|
||||
bincode = "1.3.3"
|
||||
hex = "0.4.3"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
rmp-serde = "1.1.2"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
|
@ -17,6 +17,7 @@ wit_bindgen::generate!({
|
||||
|
||||
// perhaps a constant in process_lib?
|
||||
const KNS_OPTIMISM_ADDRESS: &'static str = "0xca5b5811c0c40aab3295f932b1b5112eb7bb4bd6";
|
||||
const KNS_FIRST_BLOCK: u64 = 114_923_786;
|
||||
|
||||
#[derive(Clone, Debug, Serialize, Deserialize)]
|
||||
struct State {
|
||||
@ -132,7 +133,7 @@ fn init(our: Address) {
|
||||
contract_address,
|
||||
names: HashMap::new(),
|
||||
nodes: HashMap::new(),
|
||||
block: 1,
|
||||
block: KNS_FIRST_BLOCK,
|
||||
}
|
||||
} else {
|
||||
println!("loading in {} persisted PKI entries", s.nodes.len());
|
||||
@ -144,7 +145,7 @@ fn init(our: Address) {
|
||||
contract_address: contract_address.clone(),
|
||||
names: HashMap::new(),
|
||||
nodes: HashMap::new(),
|
||||
block: 1,
|
||||
block: KNS_FIRST_BLOCK,
|
||||
},
|
||||
};
|
||||
|
||||
@ -188,7 +189,12 @@ fn main(our: Address, mut state: State) -> anyhow::Result<()> {
|
||||
match eth_provider.get_logs(&filter) {
|
||||
Ok(logs) => {
|
||||
for log in logs {
|
||||
handle_log(&our, &mut state, &log)?;
|
||||
match handle_log(&our, &mut state, &log) {
|
||||
Ok(_) => {}
|
||||
Err(e) => {
|
||||
println!("log-handling error! {e:?}");
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
@ -345,7 +351,7 @@ fn handle_eth_message(
|
||||
}
|
||||
|
||||
fn handle_log(our: &Address, state: &mut State, log: ð::Log) -> anyhow::Result<()> {
|
||||
let node_id = log.topics[1];
|
||||
let node_id = log.topics()[1];
|
||||
|
||||
let name = match state.names.entry(node_id.to_string()) {
|
||||
Entry::Occupied(o) => o.into_mut(),
|
||||
@ -359,15 +365,15 @@ fn handle_log(our: &Address, state: &mut State, log: ð::Log) -> anyhow::Resul
|
||||
|
||||
let mut send = true;
|
||||
|
||||
match log.topics[0] {
|
||||
match log.topics()[0] {
|
||||
KeyUpdate::SIGNATURE_HASH => {
|
||||
node.public_key = KeyUpdate::abi_decode_data(&log.data, true)
|
||||
node.public_key = KeyUpdate::decode_log_data(log.data(), true)
|
||||
.unwrap()
|
||||
.0
|
||||
.key
|
||||
.to_string();
|
||||
}
|
||||
IpUpdate::SIGNATURE_HASH => {
|
||||
let ip = IpUpdate::abi_decode_data(&log.data, true).unwrap().0;
|
||||
let ip = IpUpdate::decode_log_data(log.data(), true).unwrap().ip;
|
||||
node.ip = format!(
|
||||
"{}.{}.{}.{}",
|
||||
(ip >> 24) & 0xFF,
|
||||
@ -380,15 +386,15 @@ fn handle_log(our: &Address, state: &mut State, log: ð::Log) -> anyhow::Resul
|
||||
node.routers = vec![];
|
||||
}
|
||||
WsUpdate::SIGNATURE_HASH => {
|
||||
node.port = WsUpdate::abi_decode_data(&log.data, true).unwrap().0;
|
||||
node.port = WsUpdate::decode_log_data(log.data(), true).unwrap().port;
|
||||
// when we get port data, we should delete any router data,
|
||||
// since the assignment of port indicates an direct node
|
||||
node.routers = vec![];
|
||||
}
|
||||
RoutingUpdate::SIGNATURE_HASH => {
|
||||
node.routers = RoutingUpdate::abi_decode_data(&log.data, true)
|
||||
node.routers = RoutingUpdate::decode_log_data(log.data(), true)
|
||||
.unwrap()
|
||||
.0
|
||||
.routers
|
||||
.iter()
|
||||
.map(|r| r.to_string())
|
||||
.collect::<Vec<String>>();
|
||||
@ -413,7 +419,7 @@ fn handle_log(our: &Address, state: &mut State, log: ð::Log) -> anyhow::Resul
|
||||
}
|
||||
|
||||
// if new block is > 100 from last block, save state
|
||||
let block = log.block_number.expect("expect").to::<u64>();
|
||||
let block = log.block_number.expect("expect");
|
||||
if block > state.block + 100 {
|
||||
kinode_process_lib::print_to_terminal(
|
||||
1,
|
||||
@ -430,9 +436,12 @@ fn handle_log(our: &Address, state: &mut State, log: ð::Log) -> anyhow::Resul
|
||||
}
|
||||
|
||||
fn get_name(log: ð::Log) -> anyhow::Result<String> {
|
||||
let decoded =
|
||||
NodeRegistered::abi_decode_data(&log.data, true).map_err(|e| anyhow::anyhow!(e))?;
|
||||
dnswire_decode(decoded.0.clone()).map_err(|e| anyhow::anyhow!(e))
|
||||
let decoded = NodeRegistered::decode_log_data(log.data(), false).map_err(|_e| {
|
||||
anyhow::anyhow!(
|
||||
"got event other than NodeRegistered without knowing about existing node name"
|
||||
)
|
||||
})?;
|
||||
dnswire_decode(decoded.name.to_vec()).map_err(|e| anyhow::anyhow!(e))
|
||||
}
|
||||
|
||||
fn dnswire_decode(wire_format_bytes: Vec<u8>) -> Result<String, FromUtf8Error> {
|
||||
|
@ -1,14 +1,14 @@
|
||||
{
|
||||
"name": "KNS Indexer",
|
||||
"description": "Kinode OS pki indexer",
|
||||
"description": "Kinode OS PKI indexer",
|
||||
"image": "",
|
||||
"properties": {
|
||||
"package_name": "kns_indexer",
|
||||
"current_version": "0.1.0",
|
||||
"current_version": "0.2.1",
|
||||
"publisher": "sys",
|
||||
"mirrors": [],
|
||||
"code_hashes": {
|
||||
"0.1.0": ""
|
||||
"0.2.1": ""
|
||||
}
|
||||
},
|
||||
"external_url": "https://kinode.org",
|
||||
|
@ -7,7 +7,7 @@ edition = "2021"
|
||||
simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -8,7 +8,7 @@ simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -8,7 +8,7 @@ simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -8,7 +8,7 @@ simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -7,7 +7,7 @@ edition = "2021"
|
||||
simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -9,7 +9,7 @@ simulation-mode = []
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
clap = "4.4.18"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
regex = "1.10.3"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
|
@ -4,11 +4,11 @@
|
||||
"image": "",
|
||||
"properties": {
|
||||
"package_name": "terminal",
|
||||
"current_version": "0.1.0",
|
||||
"current_version": "0.1.1",
|
||||
"publisher": "sys",
|
||||
"mirrors": [],
|
||||
"code_hashes": {
|
||||
"0.1.0": ""
|
||||
"0.1.1": ""
|
||||
}
|
||||
},
|
||||
"external_url": "https://kinode.org",
|
||||
|
@ -7,7 +7,7 @@ edition = "2021"
|
||||
simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
rmp-serde = "1.1.2"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -7,7 +7,7 @@ edition = "2021"
|
||||
simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
rmp-serde = "1.1.2"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -7,7 +7,7 @@ edition = "2021"
|
||||
simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
rmp-serde = "1.1.2"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -7,7 +7,7 @@ edition = "2021"
|
||||
simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
rmp-serde = "1.1.2"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "terminal"
|
||||
version = "0.1.0"
|
||||
version = "0.1.1"
|
||||
edition = "2021"
|
||||
|
||||
[features]
|
||||
@ -9,7 +9,7 @@ simulation-mode = []
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
bincode = "1.3.3"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
rand = "0.8"
|
||||
regex = "1.10.3"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
|
@ -8,7 +8,7 @@ simulation-mode = []
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
wit-bindgen = "0.24.0"
|
||||
|
@ -4,11 +4,11 @@
|
||||
"image": "",
|
||||
"properties": {
|
||||
"package_name": "tester",
|
||||
"current_version": "0.1.0",
|
||||
"current_version": "0.1.1",
|
||||
"publisher": "sys",
|
||||
"mirrors": [],
|
||||
"code_hashes": {
|
||||
"0.1.0": ""
|
||||
"0.1.1": ""
|
||||
}
|
||||
},
|
||||
"external_url": "https://kinode.org",
|
||||
|
@ -9,7 +9,7 @@ simulation-mode = []
|
||||
[dependencies]
|
||||
anyhow = "1.0"
|
||||
bincode = "1.3.3"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
thiserror = "1.0"
|
||||
|
@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "tester"
|
||||
version = "0.1.0"
|
||||
version = "0.1.1"
|
||||
edition = "2021"
|
||||
|
||||
[features]
|
||||
@ -10,7 +10,7 @@ simulation-mode = []
|
||||
anyhow = "1.0"
|
||||
bincode = "1.3.3"
|
||||
indexmap = "2.1"
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.6.1" }
|
||||
kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.7.0" }
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
thiserror = "1.0"
|
||||
|
@ -1,11 +1,4 @@
|
||||
[
|
||||
{
|
||||
"chain_id": 1,
|
||||
"trusted": false,
|
||||
"provider": {
|
||||
"RpcUrl": "wss://ethereum.publicnode.com"
|
||||
}
|
||||
},
|
||||
{
|
||||
"chain_id": 31337,
|
||||
"trusted": true,
|
||||
@ -13,6 +6,13 @@
|
||||
"RpcUrl": "wss://localhost:8545"
|
||||
}
|
||||
},
|
||||
{
|
||||
"chain_id": 1,
|
||||
"trusted": false,
|
||||
"provider": {
|
||||
"RpcUrl": "wss://ethereum.publicnode.com"
|
||||
}
|
||||
},
|
||||
{
|
||||
"chain_id": 10,
|
||||
"trusted": false,
|
||||
@ -21,18 +21,18 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"chain_id": 10,
|
||||
"chain_id": 1,
|
||||
"trusted": false,
|
||||
"provider": {
|
||||
"Node": {
|
||||
"use_as_provider": true,
|
||||
"kns_update": {
|
||||
"name": "default-router-1.os",
|
||||
"name": "providerfren.os",
|
||||
"owner": "",
|
||||
"node": "0xb35eb347deb896bc3fb6132a07fca1601f83462385ed11e835c24c33ba4ef73d",
|
||||
"public_key": "0xe1f7a266eafe46c79494d4dcce4222d81e5767511b295f1ed26c37221aecb80b",
|
||||
"node": "",
|
||||
"public_key": "",
|
||||
"ip": "147.135.114.167",
|
||||
"port": 9000,
|
||||
"port": 9999,
|
||||
"routers": []
|
||||
}
|
||||
}
|
||||
@ -45,30 +45,12 @@
|
||||
"Node": {
|
||||
"use_as_provider": true,
|
||||
"kns_update": {
|
||||
"name": "default-router-2.os",
|
||||
"name": "providerfren.os",
|
||||
"owner": "",
|
||||
"node": "0xd827ae579fafa604af79fbed977e8abe048497f10885c6473dfd343a3b7b4458",
|
||||
"public_key": "0xcc2752e30ba865ab6baa1b819b0291b71f1136245234274b274df5950c3abcc4",
|
||||
"node": "",
|
||||
"public_key": "",
|
||||
"ip": "147.135.114.167",
|
||||
"port": 9001,
|
||||
"routers": []
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"chain_id": 10,
|
||||
"trusted": false,
|
||||
"provider": {
|
||||
"Node": {
|
||||
"use_as_provider": true,
|
||||
"kns_update": {
|
||||
"name": "default-router-3.os",
|
||||
"owner": "",
|
||||
"node": "0x96e36331c8f0882f2c0c46c13b15d812def04fe8606d503bc0e2be39db26486a",
|
||||
"public_key": "0xe992841b17212206a3929b4cc065ad2854875d48fc7177e260005b9eb8d4f123",
|
||||
"ip": "147.135.114.167",
|
||||
"port": 9005,
|
||||
"port": 9999,
|
||||
"routers": []
|
||||
}
|
||||
}
|
||||
@ -81,48 +63,12 @@
|
||||
"Node": {
|
||||
"use_as_provider": true,
|
||||
"kns_update": {
|
||||
"name": "default-router-3.os",
|
||||
"name": "providerfren.os",
|
||||
"owner": "",
|
||||
"node": "0x96e36331c8f0882f2c0c46c13b15d812def04fe8606d503bc0e2be39db26486a",
|
||||
"public_key": "0xe992841b17212206a3929b4cc065ad2854875d48fc7177e260005b9eb8d4f123",
|
||||
"node": "",
|
||||
"public_key": "",
|
||||
"ip": "147.135.114.167",
|
||||
"port": 9005,
|
||||
"routers": []
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"chain_id": 11155111,
|
||||
"trusted": false,
|
||||
"provider": {
|
||||
"Node": {
|
||||
"use_as_provider": true,
|
||||
"kns_update": {
|
||||
"name": "default-router-2.os",
|
||||
"owner": "",
|
||||
"node": "0xd827ae579fafa604af79fbed977e8abe048497f10885c6473dfd343a3b7b4458",
|
||||
"public_key": "0xcc2752e30ba865ab6baa1b819b0291b71f1136245234274b274df5950c3abcc4",
|
||||
"ip": "147.135.114.167",
|
||||
"port": 9001,
|
||||
"routers": []
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"chain_id": 11155111,
|
||||
"trusted": false,
|
||||
"provider": {
|
||||
"Node": {
|
||||
"use_as_provider": true,
|
||||
"kns_update": {
|
||||
"name": "default-router-1.os",
|
||||
"owner": "",
|
||||
"node": "0xb35eb347deb896bc3fb6132a07fca1601f83462385ed11e835c24c33ba4ef73d",
|
||||
"public_key": "0xe1f7a266eafe46c79494d4dcce4222d81e5767511b295f1ed26c37221aecb80b",
|
||||
"ip": "147.135.114.167",
|
||||
"port": 9000,
|
||||
"port": 9999,
|
||||
"routers": []
|
||||
}
|
||||
}
|
||||
|
@ -177,11 +177,6 @@ pub async fn provider(
|
||||
allow: HashSet::new(),
|
||||
deny: HashSet::new(),
|
||||
};
|
||||
let _ = tokio::fs::write(
|
||||
format!("{}/.eth_access_settings", home_directory_path),
|
||||
serde_json::to_string(&access_settings).unwrap(),
|
||||
)
|
||||
.await;
|
||||
access_settings
|
||||
}
|
||||
};
|
||||
@ -556,10 +551,13 @@ async fn fulfill_request(
|
||||
let Some(mut aps) = providers.get_mut(&chain_id) else {
|
||||
return EthResponse::Err(EthError::NoRpcForChain);
|
||||
};
|
||||
|
||||
// first, try any url providers we have for this chain,
|
||||
// then if we have none or they all fail, go to node provider.
|
||||
// finally, if no provider works, return an error.
|
||||
for url_provider in &mut aps.urls {
|
||||
|
||||
// bump the successful provider to the front of the list for future requests
|
||||
for (index, url_provider) in aps.urls.iter_mut().enumerate() {
|
||||
let pubsub = match &url_provider.pubsub {
|
||||
Some(pubsub) => pubsub,
|
||||
None => {
|
||||
@ -571,16 +569,34 @@ async fn fulfill_request(
|
||||
.await;
|
||||
url_provider.pubsub.as_ref().unwrap()
|
||||
} else {
|
||||
verbose_print(
|
||||
print_tx,
|
||||
&format!("eth: could not activate url provider {}", url_provider.url),
|
||||
)
|
||||
.await;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
};
|
||||
let Ok(value) = pubsub.inner().prepare(method, params.clone()).await else {
|
||||
// this provider failed and needs to be reset
|
||||
url_provider.pubsub = None;
|
||||
continue;
|
||||
};
|
||||
return EthResponse::Response { value };
|
||||
match pubsub.inner().prepare(method, params.clone()).await {
|
||||
Ok(value) => {
|
||||
let successful_provider = aps.urls.remove(index);
|
||||
aps.urls.insert(0, successful_provider);
|
||||
return EthResponse::Response { value };
|
||||
}
|
||||
Err(rpc_error) => {
|
||||
verbose_print(
|
||||
print_tx,
|
||||
&format!(
|
||||
"eth: got error from url provider {}: {}",
|
||||
url_provider.url, rpc_error
|
||||
),
|
||||
)
|
||||
.await;
|
||||
// this provider failed and needs to be reset
|
||||
url_provider.pubsub = None;
|
||||
}
|
||||
}
|
||||
}
|
||||
for node_provider in &mut aps.nodes {
|
||||
let response = forward_to_node_provider(
|
||||
|
@ -1,7 +1,7 @@
|
||||
[package]
|
||||
name = "lib"
|
||||
authors = ["KinodeDAO"]
|
||||
version = "0.7.0"
|
||||
version = "0.7.1"
|
||||
edition = "2021"
|
||||
description = "A general-purpose sovereign cloud computing platform"
|
||||
homepage = "https://kinode.org"
|
||||
|
Loading…
Reference in New Issue
Block a user