From 7cbf5f5a48681f5ee75e3d7baa2f3823eaf628f3 Mon Sep 17 00:00:00 2001 From: adz Date: Wed, 6 Sep 2023 11:10:29 +0200 Subject: [PATCH] Use correct MAX_BLOB_PIECE_LENGTH from p2panda_rs --- Cargo.lock | 2 +- aquadoggo/Cargo.toml | 4 ++-- aquadoggo/src/http/api.rs | 4 +--- aquadoggo_cli/Cargo.toml | 2 +- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 862c46b7c..6114c450e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3117,7 +3117,7 @@ checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" [[package]] name = "p2panda-rs" version = "0.7.1" -source = "git+https://github.com/p2panda/p2panda?rev=17f4fcb1dcf7cebabd6d9b5a824399e9384d96b2#17f4fcb1dcf7cebabd6d9b5a824399e9384d96b2" +source = "git+https://github.com/p2panda/p2panda?rev=8377056617b64e898e9980e8ad84d258ca0442a1#8377056617b64e898e9980e8ad84d258ca0442a1" dependencies = [ "arrayvec 0.5.2", "async-trait", diff --git a/aquadoggo/Cargo.toml b/aquadoggo/Cargo.toml index 6e16211dd..9b1f72b13 100644 --- a/aquadoggo/Cargo.toml +++ b/aquadoggo/Cargo.toml @@ -56,7 +56,7 @@ lipmaa-link = "0.2.2" log = "0.4.19" once_cell = "1.18.0" openssl-probe = "0.1.5" -p2panda-rs = { git = "https://github.com/p2panda/p2panda", rev = "17f4fcb1dcf7cebabd6d9b5a824399e9384d96b2", features = [ +p2panda-rs = { git = "https://github.com/p2panda/p2panda", rev = "8377056617b64e898e9980e8ad84d258ca0442a1", features = [ "storage-provider", ] } rand = "0.8.5" @@ -97,7 +97,7 @@ http = "0.2.9" hyper = "0.14.19" libp2p-swarm-test = "0.2.0" once_cell = "1.17.0" -p2panda-rs = { git = "https://github.com/p2panda/p2panda", rev = "17f4fcb1dcf7cebabd6d9b5a824399e9384d96b2", features = [ +p2panda-rs = { git = "https://github.com/p2panda/p2panda", rev = "8377056617b64e898e9980e8ad84d258ca0442a1", features = [ "test-utils", "storage-provider", ] } diff --git a/aquadoggo/src/http/api.rs b/aquadoggo/src/http/api.rs index f94c8c94b..cab488964 100644 --- a/aquadoggo/src/http/api.rs +++ b/aquadoggo/src/http/api.rs @@ -181,6 +181,7 @@ mod tests { use http::{header, StatusCode}; use p2panda_rs::document::DocumentId; use p2panda_rs::identity::KeyPair; + use p2panda_rs::schema::validate::MAX_BLOB_PIECE_LENGTH; use p2panda_rs::test_utils::fixtures::key_pair; use rstest::rstest; @@ -188,9 +189,6 @@ mod tests { use crate::materializer::TaskInput; use crate::test_utils::{add_blob, http_test_client, test_runner, update_blob, TestNode}; - // @TODO: Would be nice if this would come out of p2panda_rs - const MAX_BLOB_PIECE_LENGTH: usize = 256; - #[rstest] fn responds_with_blob_in_http_body(key_pair: KeyPair) { test_runner(|mut node: TestNode| async move { diff --git a/aquadoggo_cli/Cargo.toml b/aquadoggo_cli/Cargo.toml index a84e1e907..c60207e19 100644 --- a/aquadoggo_cli/Cargo.toml +++ b/aquadoggo_cli/Cargo.toml @@ -31,7 +31,7 @@ libp2p = "0.52.0" log = "0.4.20" path-clean = "1.0.1" serde = { version = "1.0.185", features = ["serde_derive"] } -p2panda-rs = { git = "https://github.com/p2panda/p2panda", rev = "17f4fcb1dcf7cebabd6d9b5a824399e9384d96b2" } +p2panda-rs = { git = "https://github.com/p2panda/p2panda", rev = "8377056617b64e898e9980e8ad84d258ca0442a1" } tokio = { version = "1.28.2", features = ["full"] } toml = "0.7.6"