Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: update marine sdk's, configs and sqlite connector #129

Merged
merged 7 commits into from
Dec 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,297 changes: 845 additions & 452 deletions Cargo.lock

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions distro/Config.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
modules_dir = "."
total_memory_limit = "Infinity"

[[module]]
name = "sqlite3"
Expand Down
2 changes: 1 addition & 1 deletion keypair/rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[toolchain]
channel = "nightly-2022-08-30"
channel = "nightly-2023-12-06"
targets = [ "x86_64-apple-darwin", "x86_64-unknown-linux-gnu" ]
2 changes: 1 addition & 1 deletion rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[toolchain]
channel = "nightly-2022-12-06"
channel = "nightly-2023-12-06"
targets = [ "x86_64-apple-darwin", "wasm32-wasi", "wasm32-unknown-unknown", "x86_64-unknown-linux-gnu" ]
components = [ "rustfmt", "clippy" ]
8 changes: 4 additions & 4 deletions service/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ path = "src/main.rs"
[dependencies]
trust-graph = { version = "0.4.7", path = "../trust-graph" }
fluence-keypair = { version = "0.10.3", path = "../keypair" }
marine-rs-sdk = { version = "0.7.1", features = ["logger"] }
marine-sqlite-connector = "0.8.0"
marine-rs-sdk = { version = "0.10.2", features = ["logger"] }
marine-sqlite-connector = "0.9.2"

libp2p-identity = { workspace = true }

Expand All @@ -29,8 +29,8 @@ bincode = "1.3.1"
thiserror = "1.0.23"

[dev-dependencies]
marine-rs-sdk-test = "0.9.1"
marine-rs-sdk-test = "0.12.1"
rusqlite = "0.28.0"

[build-dependencies]
marine-rs-sdk-test = "0.9.1"
marine-rs-sdk-test = "0.12.1"
1 change: 1 addition & 0 deletions service/Config.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
modules_dir = "artifacts/"
total_memory_limit = "Infinity"

[[module]]
name = "sqlite3"
Expand Down
2 changes: 1 addition & 1 deletion service/rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[toolchain]
channel = "nightly-2022-12-06"
channel = "nightly-2023-12-06"
targets = [ "x86_64-apple-darwin", "wasm32-wasi", "wasm32-unknown-unknown", "x86_64-unknown-linux-gnu" ]
2 changes: 1 addition & 1 deletion service/src/misc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ pub(crate) fn check_timestamp_tetraplets(
.get(arg_number)
.ok_or_else(|| InvalidTimestampTetraplet(format!("{:?}", call_parameters.tetraplets)))?;
let tetraplet = tetraplets
.get(0)
.first()
.ok_or_else(|| InvalidTimestampTetraplet(format!("{:?}", call_parameters.tetraplets)))?;
(TRUSTED_TIMESTAMP.eq(&(&tetraplet.service_id, &tetraplet.function_name))
&& tetraplet.peer_pk == call_parameters.host_id)
Expand Down
2 changes: 1 addition & 1 deletion trust-graph/src/public_key_hashable.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ use std::{
#[repr(transparent)]
pub struct PublicKeyHashable(PublicKey);

#[allow(clippy::derive_hash_xor_eq)]
#[allow(clippy::derived_hash_with_manual_eq)]
impl Hash for PublicKeyHashable {
fn hash<H: Hasher>(&self, state: &mut H) {
state.write(&self.0.encode());
Expand Down
2 changes: 1 addition & 1 deletion trust-graph/src/trust_graph.rs
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ where
C: Borrow<Certificate>,
{
let chain = &cert.borrow().chain;
let mut issued_by = chain.get(0).ok_or(EmptyChain)?.issued_for.clone();
let mut issued_by = chain.first().ok_or(EmptyChain)?.issued_for.clone();

// TODO: optimize to check only root weight
for trust in chain {
Expand Down
Loading