Skip to content

Commit

Permalink
Updates for new serialization of ids (#569)
Browse files Browse the repository at this point in the history
* Bump p2panda-rs

* Update test values

* Update CHANGELOG
  • Loading branch information
sandreae authored Sep 19, 2023
1 parent 45b70e1 commit 4bd6142
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 25 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Build a byte buffer over paginated pieces when assembling blobs [#547](https://github.com/p2panda/aquadoggo/pull/547)
- Stream blob data in chunks to files to not occupy too much memory [#551](https://github.com/p2panda/aquadoggo/pull/551)
- Remove unused methods from `EntryStore` [#560](https://github.com/p2panda/aquadoggo/pull/560)
- Updates for new hash serialization in p2panda-rs [#569](https://github.com/p2panda/aquadoggo/pull/569)

## Fixed

Expand Down
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions aquadoggo/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,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 = "c0b382c9b31425748bba7c150ec9ad7a784d000c", features = [
p2panda-rs = { git = "https://github.com/p2panda/p2panda", rev = "06b2fee74b40c779d85a0ef3b37bab8386b164ca", features = [
"storage-provider",
] }
rand = "0.8.5"
Expand Down Expand Up @@ -98,7 +98,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 = "c0b382c9b31425748bba7c150ec9ad7a784d000c", features = [
p2panda-rs = { git = "https://github.com/p2panda/p2panda", rev = "06b2fee74b40c779d85a0ef3b37bab8386b164ca", features = [
"test-utils",
"storage-provider",
] }
Expand Down
38 changes: 19 additions & 19 deletions aquadoggo/src/graphql/queries/collection.rs
Original file line number Diff line number Diff line change
Expand Up @@ -407,30 +407,30 @@ mod tests {
"collection": value!({
"hasNextPage": false,
"totalCount": 2,
"endCursor": "24gc7iHafVKTcfRZfVVV8etkSoJMJVsqs1iYJAuHb8oNp32Vi1PcYw6S5GJ8hNhPmHHbP1weVbACYRctHVz4jXjQ",
"endCursor": "32Zn29gCkVQfdCBqnau1WWu4xVKYjmU5F1SPgoZ3sW6GALcbY22EGxEL2K8aNRPQaxppPGfUjSR41Xg9NyayD613",
"documents": [
{
"cursor": "24gZVnL75RPvxMVAiuGT2SgCrHneGZgsvEaiCh5g8qgxGBhcunAffueCUTiyuLDamP1G48KYPmRDBBFG43dh3XJ2",
"cursor": "27ECgmQpeuQwMKtCZxkbJUtCvkZDLuayQKv9zkV5uKx1xMHBeeSBasdhvoZwcgXLC5mnv7QR9HW11gjhH57D1mjs",
"fields": {
"bool": true,
"data": "00010203",
"bool": false,
"data": "04050607",
},
"meta": {
"owner": "2f8e50c2ede6d936ecc3144187ff1c273808185cfbc5ff3d3748d1ff7353fc96",
"documentId": "0020223f123be0f9025c591fba1a5800ca64084e837315521d5b65a870e874ed8b4e",
"viewId": "0020223f123be0f9025c591fba1a5800ca64084e837315521d5b65a870e874ed8b4e",
"documentId": "002015d927155173a6cc09531864d4f95c88a5ac910c5a17bf223f075b1cc438a511",
"viewId": "002015d927155173a6cc09531864d4f95c88a5ac910c5a17bf223f075b1cc438a511",
}
},
{
"cursor": "24gc7iHafVKTcfRZfVVV8etkSoJMJVsqs1iYJAuHb8oNp32Vi1PcYw6S5GJ8hNhPmHHbP1weVbACYRctHVz4jXjQ",
"cursor": "32Zn29gCkVQfdCBqnau1WWu4xVKYjmU5F1SPgoZ3sW6GALcbY22EGxEL2K8aNRPQaxppPGfUjSR41Xg9NyayD613",
"fields": {
"bool": false,
"data": "04050607"
"bool": true,
"data": "00010203"
},
"meta": {
"owner": "2f8e50c2ede6d936ecc3144187ff1c273808185cfbc5ff3d3748d1ff7353fc96",
"documentId": "0020c7dbed85159bbea8f1c44f1d4d7dfbdded6cd43c09ab1a292089e9530964cab9",
"viewId": "0020c7dbed85159bbea8f1c44f1d4d7dfbdded6cd43c09ab1a292089e9530964cab9",
"documentId": "00204ca0609fc55756c2aed7045f72b62bedeff7c96e4900b3aa29f7106f4a70baf1",
"viewId": "00204ca0609fc55756c2aed7045f72b62bedeff7c96e4900b3aa29f7106f4a70baf1",
}
}
]
Expand All @@ -442,7 +442,7 @@ mod tests {
r#"
(
first: 1,
after: "24gc7iHafVKTcfRZfVVV8etkSoJMJVsqs1iYJAuHb8oNp32Vi1PcYw6S5GJ8hNhPmHHbP1weVbACYRctHVz4jXjQ",
after: "27ECgmQpeuQwMKtCZxkbJUtCvkZDLuayQKv9zkV5uKx1xMHBeeSBasdhvoZwcgXLC5mnv7QR9HW11gjhH57D1mjs",
orderBy: DOCUMENT_ID,
orderDirection: ASC,
filter: {
Expand Down Expand Up @@ -475,18 +475,18 @@ mod tests {
"collection": value!({
"hasNextPage": false,
"totalCount": 1,
"endCursor": "24gZVnL75RPvxMVAiuGT2SgCrHneGZgsvEaiCh5g8qgxGBhcunAffueCUTiyuLDamP1G48KYPmRDBBFG43dh3XJ2",
"endCursor": "32Zn29gCkVQfdCBqnau1WWu4xVKYjmU5F1SPgoZ3sW6GALcbY22EGxEL2K8aNRPQaxppPGfUjSR41Xg9NyayD613",
"documents": [
{
"cursor": "24gZVnL75RPvxMVAiuGT2SgCrHneGZgsvEaiCh5g8qgxGBhcunAffueCUTiyuLDamP1G48KYPmRDBBFG43dh3XJ2",
"cursor": "32Zn29gCkVQfdCBqnau1WWu4xVKYjmU5F1SPgoZ3sW6GALcbY22EGxEL2K8aNRPQaxppPGfUjSR41Xg9NyayD613",
"fields": {
"bool": true,
"data": "00010203",
},
"meta": {
"owner": "2f8e50c2ede6d936ecc3144187ff1c273808185cfbc5ff3d3748d1ff7353fc96",
"documentId": "0020223f123be0f9025c591fba1a5800ca64084e837315521d5b65a870e874ed8b4e",
"viewId": "0020223f123be0f9025c591fba1a5800ca64084e837315521d5b65a870e874ed8b4e",
"documentId": "00204ca0609fc55756c2aed7045f72b62bedeff7c96e4900b3aa29f7106f4a70baf1",
"viewId": "00204ca0609fc55756c2aed7045f72b62bedeff7c96e4900b3aa29f7106f4a70baf1",
}
}
]
Expand Down Expand Up @@ -522,12 +522,12 @@ mod tests {
#[case(
r#"(orderBy: HELLO)"#.to_string(),
Value::Null,
vec!["Invalid value for argument \"orderBy\", enumeration type \"schema_name_0020d384b69386867b61acebe6b23d4fac8c1425d5dce339bb3ef7c2218c155b3f9aOrderBy\" does not contain the value \"HELLO\"".to_string()]
vec!["Invalid value for argument \"orderBy\", enumeration type \"schema_name_00202356a8c4da41126b8098084c2a3b653be99d61bfd805f34e967b2970b9b1998dOrderBy\" does not contain the value \"HELLO\"".to_string()]
)]
#[case(
r#"(orderBy: "hello")"#.to_string(),
Value::Null,
vec!["Invalid value for argument \"orderBy\", enumeration type \"schema_name_0020d384b69386867b61acebe6b23d4fac8c1425d5dce339bb3ef7c2218c155b3f9aOrderBy\" does not contain the value \"hello\"".to_string()]
vec!["Invalid value for argument \"orderBy\", enumeration type \"schema_name_00202356a8c4da41126b8098084c2a3b653be99d61bfd805f34e967b2970b9b1998dOrderBy\" does not contain the value \"hello\"".to_string()]
)]
#[case(
r#"(orderDirection: HELLO)"#.to_string(),
Expand All @@ -552,7 +552,7 @@ mod tests {
#[case(
r#"(filter: { hello: { eq: true }})"#.to_string(),
Value::Null,
vec!["Invalid value for argument \"filter\", unknown field \"hello\" of type \"schema_name_0020d384b69386867b61acebe6b23d4fac8c1425d5dce339bb3ef7c2218c155b3f9aFilter\"".to_string()]
vec!["Invalid value for argument \"filter\", unknown field \"hello\" of type \"schema_name_00202356a8c4da41126b8098084c2a3b653be99d61bfd805f34e967b2970b9b1998dFilter\"".to_string()]
)]
#[case(
r#"(filter: { bool: { contains: "hello" }})"#.to_string(),
Expand Down
2 changes: 1 addition & 1 deletion aquadoggo/src/graphql/queries/next_args.rs
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ mod tests {
"nextArgs": {
"logId": "0",
"seqNum": "2",
"backlink": "002098e61a9d946a1f046bd68414bfcc8fec09ddb3954dccaf184eaf7a7f4eb9cd26",
"backlink": "002015f3c7541991918e612be61ab58adf2316c9499a91dbfa012077de77c1620220",
"skiplink": null,
}
})
Expand Down
2 changes: 1 addition & 1 deletion aquadoggo/src/graphql/schema.rs
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ mod test {
// This test uses a fixed private key to allow us to anticipate the schema typename.
let key_pair = key_pair(PRIVATE_KEY);
let type_name =
"schema_name_0020f71816cb258a24bab65d63d42298467cc983670adc0bb2dd35e19f937011fbb2";
"schema_name_00201d89fa3c2ff534179d6e4fbd4d10f0a696d273d79a79f6aeeb4e3b7306a4f46c";

// Check that the schema does not exist yet.
let response = client
Expand Down
2 changes: 1 addition & 1 deletion aquadoggo_cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ figment = { version = "0.10.10", features = ["toml", "env"] }
hex = "0.4.3"
libp2p = "0.52.0"
log = "0.4.20"
p2panda-rs = { git = "https://github.com/p2panda/p2panda", rev = "c0b382c9b31425748bba7c150ec9ad7a784d000c" }
p2panda-rs = { git = "https://github.com/p2panda/p2panda", rev = "06b2fee74b40c779d85a0ef3b37bab8386b164ca" }
path-clean = "1.0.1"
serde = { version = "1.0.185", features = ["serde_derive"] }
tempfile = "3.7.0"
Expand Down

0 comments on commit 4bd6142

Please sign in to comment.