Skip to content

Commit

Permalink
chore: wasms update is life
Browse files Browse the repository at this point in the history
  • Loading branch information
zeeshanlakhani committed Nov 29, 2023
1 parent aa1d673 commit 14d7dc2
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 15 deletions.
4 changes: 4 additions & 0 deletions homestar-runtime/src/worker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,10 @@ where

let stored_receipt =
Db::commit_receipt(self.workflow_info.cid, receipt, &mut self.db.conn()?)?;
debug!(
cid = self.workflow_info.cid.to_string(),
"commited to database"
);

let _ = self
.event_sender
Expand Down
2 changes: 1 addition & 1 deletion homestar-runtime/src/workflow/settings.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ impl Default for Settings {
retry_max_delay: Duration::new(1, 0),
retry_initial_delay: Duration::from_millis(50),
p2p_timeout: Duration::from_millis(10),
timeout: Duration::from_secs(90),
timeout: Duration::from_secs(3600),
}
}
}
11 changes: 2 additions & 9 deletions homestar-runtime/tests/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,6 @@ fn test_server_serial() -> Result<()> {
Ok(())
}

#[cfg(feature = "test-utils")]
#[test]
#[file_serial]
fn test_workflow_run_serial() -> Result<()> {
Expand Down Expand Up @@ -206,10 +205,7 @@ fn test_workflow_run_serial() -> Result<()> {
.assert()
.success()
.stdout(predicate::str::contains(
"ipfs://bafybeiczefaiu7464ehupezpzulnti5jvcwnvdalqrdliugnnwcdz6ljia",
))
.stdout(predicate::str::contains(
"ipfs://bafkreihxcyjgyrz437ewzi7md55uqt2zf6yr3zn7xrfi4orc34xdc5jgrm",
"ipfs://bafkreidgxzucs63ums2yhzs4unin5a3vjemapc373rypon63kdp5xoqlzm",
))
.stdout(predicate::str::contains("num_tasks"))
.stdout(predicate::str::contains("progress_count"));
Expand All @@ -224,10 +220,7 @@ fn test_workflow_run_serial() -> Result<()> {
.assert()
.success()
.stdout(predicate::str::contains(
"ipfs://bafybeiczefaiu7464ehupezpzulnti5jvcwnvdalqrdliugnnwcdz6ljia",
))
.stdout(predicate::str::contains(
"ipfs://bafkreihxcyjgyrz437ewzi7md55uqt2zf6yr3zn7xrfi4orc34xdc5jgrm",
"ipfs://bafkreidgxzucs63ums2yhzs4unin5a3vjemapc373rypon63kdp5xoqlzm",
))
.stdout(predicate::str::contains("num_tasks"))
.stdout(predicate::str::contains("progress_count"));
Expand Down
6 changes: 3 additions & 3 deletions homestar-runtime/tests/fixtures/test-workflow-add-one.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
},
"nnc": "",
"op": "wasm/run",
"rsc": "ipfs://bafkreihxcyjgyrz437ewzi7md55uqt2zf6yr3zn7xrfi4orc34xdc5jgrm"
"rsc": "ipfs://bafkreidgxzucs63ums2yhzs4unin5a3vjemapc373rypon63kdp5xoqlzm"
}
},
{
Expand All @@ -33,15 +33,15 @@
"args": [
{
"await/ok": {
"/": "bafyrmibiw5at3dsnpqqi36c2ped3lwsdaijpkwntiouou7yhztjdjfhd4e"
"/": "bafyrmigpbec3fpc64hxkehxkszctb5f5roylk5ej2t2qgfylf64gpdn54m"
}
}
],
"func": "add_one"
},
"nnc": "",
"op": "wasm/run",
"rsc": "ipfs://bafybeiczefaiu7464ehupezpzulnti5jvcwnvdalqrdliugnnwcdz6ljia"
"rsc": "ipfs://bafkreidgxzucs63ums2yhzs4unin5a3vjemapc373rypon63kdp5xoqlzm"
}
}
]
Expand Down
Binary file modified homestar-wasm/fixtures/example_add.wasm
Binary file not shown.
Binary file modified homestar-wasm/fixtures/example_add_component.wasm
Binary file not shown.
4 changes: 2 additions & 2 deletions homestar-wasm/fixtures/example_add_component.wat
Original file line number Diff line number Diff line change
Expand Up @@ -3691,8 +3691,8 @@
(export "__data_end" (global 1))
(export "__heap_base" (global 2))
(@producers
(processed-by "wit-component" "0.16.0")
(processed-by "wit-bindgen-rust" "0.13.0")
(processed-by "wit-component" "0.17.0")
(processed-by "wit-bindgen-rust" "0.13.2")
)
)
(core instance (;0;) (instantiate 0))
Expand Down

0 comments on commit 14d7dc2

Please sign in to comment.