updated all apps to latest process_lib

This commit is contained in:
Drew Tada 2024-01-05 16:59:23 -06:00
parent b34883c462
commit 54d467abb3
17 changed files with 48 additions and 33 deletions

View File

@ -448,7 +448,7 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c"
[[package]]
name = "uqbar_process_lib"
version = "0.4.0"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=54dd9b7#54dd9b75b82512d722f038ede30d1cc751acdd7d"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=c3c8c5c#c3c8c5cd306995e41cc09b61bc5127261c6864d2"
dependencies = [
"anyhow",
"bincode",

View File

@ -15,7 +15,7 @@ rand = "0.8"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
sha2 = "0.10.8"
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "54dd9b7" }
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "c3c8c5c" }
wit-bindgen = { git = "https://github.com/bytecodealliance/wit-bindgen", rev = "efcc759" }
[lib]

View File

@ -382,7 +382,7 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c"
[[package]]
name = "uqbar_process_lib"
version = "0.4.0"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=54dd9b7#54dd9b75b82512d722f038ede30d1cc751acdd7d"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=c3c8c5c#c3c8c5cd306995e41cc09b61bc5127261c6864d2"
dependencies = [
"anyhow",
"bincode",

View File

@ -16,7 +16,7 @@ bincode = "1.3.3"
rand = "0.8"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "54dd9b7" }
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "c3c8c5c" }
wit-bindgen = { git = "https://github.com/bytecodealliance/wit-bindgen", rev = "efcc759" }
[lib]

View File

@ -657,7 +657,7 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c"
[[package]]
name = "uqbar_process_lib"
version = "0.4.0"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=54dd9b7#54dd9b75b82512d722f038ede30d1cc751acdd7d"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=c3c8c5c#c3c8c5cd306995e41cc09b61bc5127261c6864d2"
dependencies = [
"anyhow",
"bincode",

View File

@ -16,7 +16,7 @@ pleco = "0.5"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
url = "*"
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "54dd9b7" }
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "c3c8c5c" }
wit-bindgen = { git = "https://github.com/bytecodealliance/wit-bindgen", rev = "efcc759" }
[lib]

View File

@ -381,7 +381,7 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c"
[[package]]
name = "uqbar_process_lib"
version = "0.4.0"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=54dd9b7#54dd9b75b82512d722f038ede30d1cc751acdd7d"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=c3c8c5c#c3c8c5cd306995e41cc09b61bc5127261c6864d2"
dependencies = [
"anyhow",
"bincode",

View File

@ -15,7 +15,7 @@ anyhow = "1.0"
bincode = "1.3.3"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "54dd9b7" }
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "c3c8c5c" }
wit-bindgen = { git = "https://github.com/bytecodealliance/wit-bindgen", rev = "efcc759" }
[lib]

View File

@ -782,7 +782,7 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c"
[[package]]
name = "uqbar_process_lib"
version = "0.4.0"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=54dd9b7#54dd9b75b82512d722f038ede30d1cc751acdd7d"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=c3c8c5c#c3c8c5cd306995e41cc09b61bc5127261c6864d2"
dependencies = [
"anyhow",
"bincode",

View File

@ -19,7 +19,7 @@ hex = "0.4.3"
rmp-serde = "1.1.2"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "54dd9b7" }
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "c3c8c5c" }
wit-bindgen = { git = "https://github.com/bytecodealliance/wit-bindgen", rev = "efcc759" }
[lib]

View File

@ -381,7 +381,7 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c"
[[package]]
name = "uqbar_process_lib"
version = "0.4.0"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=54dd9b7#54dd9b75b82512d722f038ede30d1cc751acdd7d"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=c3c8c5c#c3c8c5cd306995e41cc09b61bc5127261c6864d2"
dependencies = [
"anyhow",
"bincode",

View File

@ -15,7 +15,7 @@ anyhow = "1.0"
bincode = "1.3.3"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "54dd9b7" }
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "c3c8c5c" }
wit-bindgen = { git = "https://github.com/bytecodealliance/wit-bindgen", rev = "efcc759" }
[lib]

View File

@ -382,7 +382,7 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c"
[[package]]
name = "uqbar_process_lib"
version = "0.4.0"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=54dd9b7#54dd9b75b82512d722f038ede30d1cc751acdd7d"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=c3c8c5c#c3c8c5cd306995e41cc09b61bc5127261c6864d2"
dependencies = [
"anyhow",
"bincode",

View File

@ -16,7 +16,7 @@ bincode = "1.3.3"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
thiserror = "1.0"
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "54dd9b7" }
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "c3c8c5c" }
wit-bindgen = { git = "https://github.com/bytecodealliance/wit-bindgen", rev = "efcc759" }
[lib]

View File

@ -383,7 +383,7 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c"
[[package]]
name = "uqbar_process_lib"
version = "0.4.0"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=54dd9b7#54dd9b75b82512d722f038ede30d1cc751acdd7d"
source = "git+ssh://git@github.com/uqbar-dao/process_lib.git?rev=c3c8c5c#c3c8c5cd306995e41cc09b61bc5127261c6864d2"
dependencies = [
"anyhow",
"bincode",

View File

@ -17,7 +17,7 @@ indexmap = "2.1"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
thiserror = "1.0"
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "54dd9b7" }
uqbar_process_lib = { git = "ssh://git@github.com/uqbar-dao/process_lib.git", rev = "c3c8c5c" }
wit-bindgen = { git = "https://github.com/bytecodealliance/wit-bindgen", rev = "efcc759" }
[lib]

View File

@ -1,7 +1,8 @@
use serde::{Serialize, Deserialize};
use serde::{Deserialize, Serialize};
use std::collections::HashMap;
use uqbar_process_lib::{Address, Response};
use uqbar_process_lib::kernel_types as kt;
use uqbar_process_lib::{Address, Response};
// use uqbar_process_lib::uqbar::process::standard as wit;
type Rsvp = Option<Address>;
@ -14,12 +15,15 @@ pub struct KernelMessage {
pub rsvp: Rsvp,
pub message: kt::Message,
pub payload: Option<kt::Payload>,
pub signed_capabilities: Option<Vec<kt::SignedCapability>>,
pub signed_capabilities: HashMap<kt::Capability, Vec<u8>>,
}
#[derive(Debug, Serialize, Deserialize)]
pub enum TesterRequest {
Run { input_node_names: Vec<String>, test_timeout: u64 },
Run {
input_node_names: Vec<String>,
test_timeout: u64,
},
KernelMessage(KernelMessage),
GetFullMessage(kt::Message),
}
@ -35,7 +39,12 @@ pub struct TesterFail {
#[derive(Debug, Serialize, Deserialize)]
pub enum TesterResponse {
Pass,
Fail { test: String, file: String, line: u32, column: u32 },
Fail {
test: String,
file: String,
line: u32,
column: u32,
},
GetFullMessage(Option<KernelMessage>),
}
@ -53,24 +62,30 @@ pub enum TesterError {
macro_rules! fail {
($test:expr) => {
Response::new()
.ipc(serde_json::to_vec(&tt::TesterResponse::Fail {
test: $test.into(),
file: file!().into(),
line: line!(),
column: column!(),
}).unwrap())
.ipc(
serde_json::to_vec(&tt::TesterResponse::Fail {
test: $test.into(),
file: file!().into(),
line: line!(),
column: column!(),
})
.unwrap(),
)
.send()
.unwrap();
panic!("")
};
($test:expr, $file:expr, $line:expr, $column:expr) => {
Response::new()
.ipc(serde_json::to_vec(&tt::TesterResponse::Fail {
test: $test.into(),
file: $file.into(),
line: $line,
column: $column,
}).unwrap())
.ipc(
serde_json::to_vec(&tt::TesterResponse::Fail {
test: $test.into(),
file: $file.into(),
line: $line,
column: $column,
})
.unwrap(),
)
.send()
.unwrap();
panic!("")