diff --git a/Cargo.lock b/Cargo.lock index 2c36be1..21800c5 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3087,8 +3087,8 @@ dependencies = [ [[package]] name = "minotari_app_grpc" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "argon2", "base64 0.13.1", @@ -3117,8 +3117,8 @@ dependencies = [ [[package]] name = "minotari_ledger_wallet_common" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "bs58 0.5.1", ] @@ -3126,7 +3126,7 @@ dependencies = [ [[package]] name = "minotari_node_grpc_client" version = "0.1.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "minotari_app_grpc", ] @@ -4732,7 +4732,7 @@ dependencies = [ [[package]] name = "sha_p2pool" -version = "0.20.6" +version = "0.21.0" dependencies = [ "anyhow", "async-trait", @@ -5103,8 +5103,8 @@ dependencies = [ [[package]] name = "tari_common" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "anyhow", "config", @@ -5127,8 +5127,8 @@ dependencies = [ [[package]] name = "tari_common_sqlite" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "diesel", "diesel_migrations", @@ -5141,8 +5141,8 @@ dependencies = [ [[package]] name = "tari_common_types" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "base64 0.21.7", "bitflags 2.6.0", @@ -5167,8 +5167,8 @@ dependencies = [ [[package]] name = "tari_comms" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "anyhow", "async-trait", @@ -5211,8 +5211,8 @@ dependencies = [ [[package]] name = "tari_comms_dht" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "anyhow", "bitflags 2.6.0", @@ -5246,8 +5246,8 @@ dependencies = [ [[package]] name = "tari_comms_rpc_macros" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "proc-macro2", "quote", @@ -5256,8 +5256,8 @@ dependencies = [ [[package]] name = "tari_core" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "anyhow", "async-trait", @@ -5350,13 +5350,13 @@ dependencies = [ [[package]] name = "tari_features" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" [[package]] name = "tari_hashing" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "borsh", "digest", @@ -5365,8 +5365,8 @@ dependencies = [ [[package]] name = "tari_key_manager" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "argon2", "async-trait", @@ -5398,8 +5398,8 @@ dependencies = [ [[package]] name = "tari_max_size" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "borsh", "serde", @@ -5409,8 +5409,8 @@ dependencies = [ [[package]] name = "tari_mmr" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "borsh", "digest", @@ -5423,8 +5423,8 @@ dependencies = [ [[package]] name = "tari_p2p" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "anyhow", "fs2", @@ -5455,8 +5455,8 @@ dependencies = [ [[package]] name = "tari_script" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "blake2", "borsh", @@ -5473,8 +5473,8 @@ dependencies = [ [[package]] name = "tari_service_framework" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "anyhow", "async-trait", @@ -5488,16 +5488,16 @@ dependencies = [ [[package]] name = "tari_shutdown" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "futures 0.3.30", ] [[package]] name = "tari_storage" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "bincode", "lmdb-zero", @@ -5508,8 +5508,8 @@ dependencies = [ [[package]] name = "tari_test_utils" -version = "1.9.2-pre.0" -source = "git+https://github.com/tari-project/tari.git?rev=98a76e5e36ab056b36d342e2408306ec67c406dc#98a76e5e36ab056b36d342e2408306ec67c406dc" +version = "1.11.0-pre.0" +source = "git+https://github.com/tari-project/tari.git?rev=36ff43680ac9eacada86621aee873149d86175ad#36ff43680ac9eacada86621aee873149d86175ad" dependencies = [ "futures 0.3.30", "rand", diff --git a/Cargo.toml b/Cargo.toml index 0d14edb..19eb378 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,7 +1,7 @@ [package] edition = "2021" name = "sha_p2pool" -version = "0.20.6" +version = "0.21.0" [dependencies] anyhow = "1.0" @@ -43,19 +43,19 @@ libp2p = { version = "0.54.1", features = [ ] } log = { version = "0.4.21", features = ["kv"] } log4rs = "1.3.0" -minotari_app_grpc = { git = "https://github.com/tari-project/tari.git", rev = "98a76e5e36ab056b36d342e2408306ec67c406dc" } -minotari_node_grpc_client = { git = "https://github.com/tari-project/tari.git", rev = "98a76e5e36ab056b36d342e2408306ec67c406dc" } +minotari_app_grpc = { git = "https://github.com/tari-project/tari.git", rev = "36ff43680ac9eacada86621aee873149d86175ad" } +minotari_node_grpc_client = { git = "https://github.com/tari-project/tari.git", rev = "36ff43680ac9eacada86621aee873149d86175ad" } num = { version = "0.4.3", features = ["default", "num-bigint", "serde"] } rand = "0.8.0" serde = "1.0.203" serde_cbor = "0.11.2" serde_json = "1.0.122" -tari_common = { git = "https://github.com/tari-project/tari.git", rev = "98a76e5e36ab056b36d342e2408306ec67c406dc" } -tari_common_types = { git = "https://github.com/tari-project/tari.git", rev = "98a76e5e36ab056b36d342e2408306ec67c406dc" } -tari_core = { git = "https://github.com/tari-project/tari.git", rev = "98a76e5e36ab056b36d342e2408306ec67c406dc" } +tari_common = { git = "https://github.com/tari-project/tari.git", rev = "36ff43680ac9eacada86621aee873149d86175ad" } +tari_common_types = { git = "https://github.com/tari-project/tari.git", rev = "36ff43680ac9eacada86621aee873149d86175ad" } +tari_core = { git = "https://github.com/tari-project/tari.git", rev = "36ff43680ac9eacada86621aee873149d86175ad" } tari_crypto = "0.21.0" -tari_script = { git = "https://github.com/tari-project/tari.git", rev = "98a76e5e36ab056b36d342e2408306ec67c406dc" } -tari_shutdown = { git = "https://github.com/tari-project/tari.git", rev = "98a76e5e36ab056b36d342e2408306ec67c406dc" } +tari_script = { git = "https://github.com/tari-project/tari.git", rev = "36ff43680ac9eacada86621aee873149d86175ad" } +tari_shutdown = { git = "https://github.com/tari-project/tari.git", rev = "36ff43680ac9eacada86621aee873149d86175ad" } tari_utilities = { version = "0.8", features = ["borsh"] } thiserror = "1.0" tokio = { version = "1.41.0", features = ["full"] } diff --git a/src/server/grpc/base_node.rs b/src/server/grpc/base_node.rs index 425df71..d87fa81 100644 --- a/src/server/grpc/base_node.rs +++ b/src/server/grpc/base_node.rs @@ -23,6 +23,8 @@ use minotari_app_grpc::{ GetBlocksRequest, GetHeaderByHashRequest, GetMempoolTransactionsRequest, + GetNetworkStateRequest, + GetNetworkStateResponse, GetNewBlockBlobResult, GetNewBlockResult, GetNewBlockTemplateWithCoinbasesRequest, @@ -218,6 +220,13 @@ impl tari_rpc::base_node_server::BaseNode for TariBaseNodeGrpc { proxy_stream_result!(self, get_blocks, request, GET_BLOCKS_PAGE_SIZE) } + async fn get_network_state( + &self, + request: Request, + ) -> Result, Status> { + proxy_simple_result!(self, get_network_state, request) + } + async fn get_block_timing(&self, request: Request) -> Result, Status> { proxy_simple_result!(self, get_block_timing, request) } diff --git a/src/server/mod.rs b/src/server/mod.rs index 181f831..1f0ec17 100644 --- a/src/server/mod.rs +++ b/src/server/mod.rs @@ -12,4 +12,4 @@ pub mod grpc; pub mod http; pub mod p2p; -pub const PROTOCOL_VERSION: u64 = 30; +pub const PROTOCOL_VERSION: u64 = 31;