From 075307804bf66bba10f5bc55cb40e2e6a98a65ee Mon Sep 17 00:00:00 2001 From: DanConwayDev Date: Thu, 8 Jan 2026 10:57:51 +0000 Subject: chore: upgrade nostr-* packages to rev 4767ad13 - Update nostr-relay-builder, nostr-sdk, nostr-lmdb to latest revision - Update grasp-audit nostr-sdk dependency - Fix clippy warnings: - Replace .clone() with std::slice::from_ref() in src/git/sync.rs - Change &PathBuf to &Path in tests/common/git_server.rs - Replace vec![] with array literal in src/purgatory/sync/functions.rs - Update PR_TEST_COMMIT_HASH in grasp-audit due to event generation changes All 249 tests passing, no breaking changes required. --- Cargo.lock | 18 +++++++++--------- Cargo.toml | 6 +++--- grasp-audit/Cargo.toml | 2 +- grasp-audit/src/specs/grasp01/push_authorization.rs | 2 +- src/git/sync.rs | 5 +++-- src/purgatory/sync/functions.rs | 2 +- tests/common/git_server.rs | 2 +- 7 files changed, 19 insertions(+), 18 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 35b96c0..7913672 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -584,9 +584,9 @@ checksum = "52051878f80a721bb68ebfbc930e07b65ba72f2da88968ea5c06fd6ca3d3a127" [[package]] name = "flatbuffers" -version = "25.9.23" +version = "25.12.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09b6620799e7340ebd9968d2e0708eb82cf1971e9a16821e2091b6d6e475eed5" +checksum = "35f6839d7b3b98adde531effaf34f0c2badc6f4735d26fe74709d8e513a96ef3" dependencies = [ "bitflags 2.10.0", "rustc_version", @@ -1469,7 +1469,7 @@ dependencies = [ [[package]] name = "nostr" version = "0.44.1" -source = "git+https://github.com/rust-nostr/nostr?rev=e09c9d82a1778683d2a6b968d09eb2c619883bf3#e09c9d82a1778683d2a6b968d09eb2c619883bf3" +source = "git+https://github.com/rust-nostr/nostr?rev=4767ad13#4767ad138ed47b49584cdc3cea9cccf69f283be5" dependencies = [ "base64 0.22.1", "bech32", @@ -1493,7 +1493,7 @@ dependencies = [ [[package]] name = "nostr-database" version = "0.44.0" -source = "git+https://github.com/rust-nostr/nostr?rev=e09c9d82a1778683d2a6b968d09eb2c619883bf3#e09c9d82a1778683d2a6b968d09eb2c619883bf3" +source = "git+https://github.com/rust-nostr/nostr?rev=4767ad13#4767ad138ed47b49584cdc3cea9cccf69f283be5" dependencies = [ "btreecap", "flatbuffers", @@ -1505,7 +1505,7 @@ dependencies = [ [[package]] name = "nostr-gossip" version = "0.44.0" -source = "git+https://github.com/rust-nostr/nostr?rev=e09c9d82a1778683d2a6b968d09eb2c619883bf3#e09c9d82a1778683d2a6b968d09eb2c619883bf3" +source = "git+https://github.com/rust-nostr/nostr?rev=4767ad13#4767ad138ed47b49584cdc3cea9cccf69f283be5" dependencies = [ "nostr", ] @@ -1513,7 +1513,7 @@ dependencies = [ [[package]] name = "nostr-lmdb" version = "0.44.0" -source = "git+https://github.com/rust-nostr/nostr?rev=e09c9d82a1778683d2a6b968d09eb2c619883bf3#e09c9d82a1778683d2a6b968d09eb2c619883bf3" +source = "git+https://github.com/rust-nostr/nostr?rev=4767ad13#4767ad138ed47b49584cdc3cea9cccf69f283be5" dependencies = [ "async-utility", "flume", @@ -1527,7 +1527,7 @@ dependencies = [ [[package]] name = "nostr-relay-builder" version = "0.44.0" -source = "git+https://github.com/rust-nostr/nostr?rev=e09c9d82a1778683d2a6b968d09eb2c619883bf3#e09c9d82a1778683d2a6b968d09eb2c619883bf3" +source = "git+https://github.com/rust-nostr/nostr?rev=4767ad13#4767ad138ed47b49584cdc3cea9cccf69f283be5" dependencies = [ "async-utility", "async-wsocket", @@ -1544,7 +1544,7 @@ dependencies = [ [[package]] name = "nostr-relay-pool" version = "0.44.0" -source = "git+https://github.com/rust-nostr/nostr?rev=e09c9d82a1778683d2a6b968d09eb2c619883bf3#e09c9d82a1778683d2a6b968d09eb2c619883bf3" +source = "git+https://github.com/rust-nostr/nostr?rev=4767ad13#4767ad138ed47b49584cdc3cea9cccf69f283be5" dependencies = [ "async-utility", "async-wsocket", @@ -1561,7 +1561,7 @@ dependencies = [ [[package]] name = "nostr-sdk" version = "0.44.1" -source = "git+https://github.com/rust-nostr/nostr?rev=e09c9d82a1778683d2a6b968d09eb2c619883bf3#e09c9d82a1778683d2a6b968d09eb2c619883bf3" +source = "git+https://github.com/rust-nostr/nostr?rev=4767ad13#4767ad138ed47b49584cdc3cea9cccf69f283be5" dependencies = [ "async-utility", "nostr", diff --git a/Cargo.toml b/Cargo.toml index 82c2de7..9fcada0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,11 +17,11 @@ hyper-util = { version = "0.1", features = ["tokio", "server", "http1", "http2"] http-body-util = "0.1" # Nostr relay -nostr-relay-builder = { git = "https://github.com/rust-nostr/nostr", rev = "e09c9d82a1778683d2a6b968d09eb2c619883bf3" } +nostr-relay-builder = { git = "https://github.com/rust-nostr/nostr", rev = "4767ad13" } # Nostr -nostr-sdk = { git = "https://github.com/rust-nostr/nostr", rev = "e09c9d82a1778683d2a6b968d09eb2c619883bf3" } -nostr-lmdb = { git = "https://github.com/rust-nostr/nostr", rev = "e09c9d82a1778683d2a6b968d09eb2c619883bf3" } +nostr-sdk = { git = "https://github.com/rust-nostr/nostr", rev = "4767ad13" } +nostr-lmdb = { git = "https://github.com/rust-nostr/nostr", rev = "4767ad13" } # Utilities futures-util = "0.3" diff --git a/grasp-audit/Cargo.toml b/grasp-audit/Cargo.toml index 88f3d60..6c8632e 100644 --- a/grasp-audit/Cargo.toml +++ b/grasp-audit/Cargo.toml @@ -12,7 +12,7 @@ path = "src/bin/grasp-audit.rs" [dependencies] # Nostr -nostr-sdk = { git = "https://github.com/rust-nostr/nostr", rev = "e09c9d82a1778683d2a6b968d09eb2c619883bf3" } +nostr-sdk = { git = "https://github.com/rust-nostr/nostr", rev = "4767ad13" } # Async tokio = { version = "1", features = ["full"] } diff --git a/grasp-audit/src/specs/grasp01/push_authorization.rs b/grasp-audit/src/specs/grasp01/push_authorization.rs index 549ba6f..23eb735 100644 --- a/grasp-audit/src/specs/grasp01/push_authorization.rs +++ b/grasp-audit/src/specs/grasp01/push_authorization.rs @@ -29,7 +29,7 @@ /// /// Run `test_pr_test_commit_hash_discovery` to discover/verify this value. #[allow(dead_code)] -const PR_TEST_COMMIT_HASH: &str = "5d40fb1555a0c28bf4d650515a73aaa54d4d9bfb"; +const PR_TEST_COMMIT_HASH: &str = "8935183ff722bf04e861928c6a7e50868c6ca4a6"; use crate::{ clone_repo, create_commit, create_deterministic_commit_with_variant, try_push, try_push_to_ref, diff --git a/src/git/sync.rs b/src/git/sync.rs index 06013a5..b05e2d0 100644 --- a/src/git/sync.rs +++ b/src/git/sync.rs @@ -1618,7 +1618,8 @@ mod tests { }; // latest should be considered latest - let result = is_latest_authorized_state(&latest, &maintainers, &[older.clone()]); + let result = + is_latest_authorized_state(&latest, &maintainers, std::slice::from_ref(&older)); assert!(result); // older should not be considered latest @@ -1633,7 +1634,7 @@ mod tests { let maintainers = vec![keys.public_key().to_hex()]; // When the state being checked is also in the db_states, it should be considered latest - let result = is_latest_authorized_state(&state, &maintainers, &[state.clone()]); + let result = is_latest_authorized_state(&state, &maintainers, std::slice::from_ref(&state)); assert!(result); } } diff --git a/src/purgatory/sync/functions.rs b/src/purgatory/sync/functions.rs index 370990e..0139ac5 100644 --- a/src/purgatory/sync/functions.rs +++ b/src/purgatory/sync/functions.rs @@ -930,7 +930,7 @@ mod tests { .expect("Should return a second URL"); // Both URLs should be available (one from announcement, one from PR) - let both_urls = vec![first_url, second_url]; + let both_urls = [first_url, second_url]; assert!( both_urls.iter().any(|u| u.contains("github.com")), "Should include announcement URL" diff --git a/tests/common/git_server.rs b/tests/common/git_server.rs index d0d727e..9fb62df 100644 --- a/tests/common/git_server.rs +++ b/tests/common/git_server.rs @@ -282,7 +282,7 @@ fn is_safe_path(path: &Path, repo_path: &Path) -> bool { } /// Guess the content type for a git-related file. -fn guess_content_type(path: &PathBuf) -> &'static str { +fn guess_content_type(path: &Path) -> &'static str { let filename = path.file_name().and_then(|n| n.to_str()).unwrap_or(""); if filename == "info/refs" || filename == "refs" { -- cgit v1.2.3