From ac9bf8ef739122c35f6106d2a379f95337cc81e1 Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Wed, 14 Aug 2024 19:11:20 -0700 Subject: [PATCH 01/13] new: replace template vars with literals and change parsing --- build.rs | 14 +- src/new/mod.rs | 45 +- ...lisher}-v0.wit => chat:template.os-v0.wit} | 6 +- .../{{package_name} => chat}/package.json | 4 +- .../chat/{{package_name} => chat}/src/lib.js | 12 +- .../javascript/no-ui/chat/metadata.json | 6 +- .../javascript/no-ui/chat/pkg/manifest.json | 4 +- .../javascript/no-ui/chat/pkg/scripts.json | 4 +- .../javascript/no-ui/chat/send/Cargo.lock | 2083 +++++++++++++++++ .../chat/send/{Cargo.toml_ => Cargo.toml} | 0 .../javascript/no-ui/chat/send/src/lib.rs | 12 +- .../{package_name} => echo/echo}/package.json | 4 +- .../echo/{{package_name} => echo}/src/lib.js | 6 +- .../javascript/no-ui/echo/metadata.json | 6 +- .../javascript/no-ui/echo/pkg/manifest.json | 4 +- .../fibonacci}/package.json | 4 +- .../{{package_name} => fibonacci}/src/lib.js | 8 +- .../javascript/no-ui/fibonacci/metadata.json | 6 +- .../no-ui/fibonacci/pkg/manifest.json | 4 +- ...lisher}-v0.wit => chat:template.os-v0.wit} | 6 +- .../chat/{{package_name} => chat}/src/lib.py | 14 +- .../templates/python/no-ui/chat/metadata.json | 6 +- .../python/no-ui/chat/pkg/manifest.json | 4 +- .../python/no-ui/chat/pkg/scripts.json | 4 +- .../python/no-ui/chat/send/src/lib.py | 10 +- .../echo/{{package_name} => echo}/src/lib.py | 6 +- .../templates/python/no-ui/echo/metadata.json | 6 +- .../python/no-ui/echo/pkg/manifest.json | 4 +- .../{{package_name} => fibonacci}/src/lib.py | 8 +- .../python/no-ui/fibonacci/metadata.json | 6 +- .../python/no-ui/fibonacci/pkg/manifest.json | 4 +- .../no-ui/blank/{Cargo.toml_ => Cargo.toml} | 2 +- .../Cargo.toml_ => blank/Cargo.toml} | 2 +- .../{{package_name} => blank}/src/lib.rs | 0 .../templates/rust/no-ui/blank/metadata.json | 6 +- .../rust/no-ui/blank/pkg/manifest.json | 4 +- .../no-ui/chat/{Cargo.toml_ => Cargo.toml} | 2 +- ...lisher}-v0.wit => chat:template.os-v0.wit} | 6 +- .../Cargo.toml_ => chat/chat/Cargo.toml} | 2 +- .../chat/{{package_name} => chat}/src/lib.rs | 6 +- .../templates/rust/no-ui/chat/metadata.json | 6 +- .../rust/no-ui/chat/pkg/manifest.json | 4 +- .../rust/no-ui/chat/pkg/scripts.json | 4 +- .../chat/send/{Cargo.toml_ => Cargo.toml} | 0 .../templates/rust/no-ui/chat/send/src/lib.rs | 12 +- .../no-ui/echo/{Cargo.toml_ => Cargo.toml} | 2 +- .../Cargo.toml_ => echo/Cargo.toml} | 2 +- .../echo/{{package_name} => echo}/src/lib.rs | 0 .../templates/rust/no-ui/echo/metadata.json | 6 +- .../rust/no-ui/echo/pkg/manifest.json | 4 +- .../fibonacci/{Cargo.toml_ => Cargo.toml} | 2 +- ...r}-v0.wit => fibonacci:template.os-v0.wit} | 6 +- .../Cargo.toml_ => fibonacci/Cargo.toml} | 2 +- .../{{package_name} => fibonacci}/src/lib.rs | 4 +- .../rust/no-ui/fibonacci/metadata.json | 6 +- .../number/{Cargo.toml_ => Cargo.toml} | 0 .../rust/no-ui/fibonacci/number/src/lib.rs | 10 +- .../rust/no-ui/fibonacci/pkg/manifest.json | 4 +- .../rust/no-ui/fibonacci/pkg/scripts.json | 4 +- .../file_transfer/{Cargo.toml_ => Cargo.toml} | 2 +- ...0.wit => file_transfer:template.os-v0.wit} | 6 +- .../download/{Cargo.toml_ => Cargo.toml} | 0 .../no-ui/file_transfer/download/src/lib.rs | 8 +- .../file_transfer/Cargo.toml} | 2 +- .../src/lib.rs | 4 +- .../{Cargo.toml_ => Cargo.toml} | 0 .../file_transfer_worker/src/lib.rs | 2 +- .../{Cargo.toml_ => Cargo.toml} | 0 .../list_files/{Cargo.toml_ => Cargo.toml} | 0 .../no-ui/file_transfer/list_files/src/lib.rs | 8 +- .../rust/no-ui/file_transfer/metadata.json | 8 +- .../no-ui/file_transfer/pkg/manifest.json | 4 +- .../rust/no-ui/file_transfer/pkg/scripts.json | 8 +- .../rust/ui/chat/{Cargo.toml_ => Cargo.toml} | 2 +- .../Cargo.toml_ => chat/Cargo.toml} | 2 +- .../chat/{{package_name} => chat}/src/lib.rs | 2 +- src/new/templates/rust/ui/chat/metadata.json | 6 +- .../templates/rust/ui/chat/pkg/manifest.json | 4 +- .../Cargo.toml_ => chat_test/Cargo.toml} | 2 +- .../api/chat_test:template.os-v0.wit | 5 + .../chat_test/Cargo.toml} | 2 +- .../chat_test}/src/lib.rs | 24 +- .../chat_test}/src/tester_lib.rs | 0 .../metadata.json | 10 +- .../test/chat/chat_test/pkg/manifest.json | 15 + src/new/templates/test/chat/tests.toml | 2 +- .../{package_name}_test:{publisher}-v0.wit | 5 - .../{package_name}_test/pkg/manifest.json | 15 - .../templates/test/echo/echo_test/Cargo.toml | 10 + .../api/echo_test:template.os-v0.wit | 4 + .../echo_test/Cargo.toml} | 2 +- .../echo_test}/src/lib.rs | 16 +- .../echo_test}/src/tester_lib.rs | 0 .../metadata.json | 8 +- .../test/echo/echo_test/pkg/manifest.json | 15 + src/new/templates/test/echo/tests.toml | 2 +- .../test/echo/{package_name}_test/Cargo.toml_ | 10 - .../{package_name}_test:{publisher}-v0.wit | 4 - .../{package_name}_test/pkg/manifest.json | 15 - .../test/fibonacci/fibonacci_test/Cargo.toml | 10 + .../api/fibonacci_test:template.os-v0.wit | 5 + .../fibonacci_test/Cargo.toml} | 2 +- .../fibonacci_test}/src/lib.rs | 24 +- .../fibonacci_test}/src/tester_lib.rs | 0 .../metadata.json | 10 +- .../fibonacci_test/pkg/manifest.json | 15 + src/new/templates/test/fibonacci/tests.toml | 2 +- .../fibonacci/{package_name}_test/Cargo.toml_ | 10 - .../{package_name}_test:{publisher}-v0.wit | 5 - .../{package_name}_test/pkg/manifest.json | 15 - .../file_transfer_test/Cargo.toml | 10 + .../api/file_transfer_test:template.os-v0.wit | 5 + .../file_transfer_test/Cargo.toml} | 2 +- .../file_transfer_test}/src/lib.rs | 32 +- .../file_transfer_test}/src/tester_lib.rs | 0 .../file_transfer_test/metadata.json | 21 + .../file_transfer_test/pkg/manifest.json | 15 + .../templates/test/file_transfer/tests.toml | 2 +- .../{package_name}_test/Cargo.toml_ | 10 - .../{package_name}_test/api/tester:sys-v0.wit | 27 - .../api/{package_name}:{publisher}-v0.wit | 53 - .../{package_name}_test:{publisher}-v0.wit | 5 - .../{package_name}_test/metadata.json | 17 - .../{package_name}_test/pkg/manifest.json | 15 - 124 files changed, 2496 insertions(+), 468 deletions(-) rename src/new/templates/javascript/no-ui/chat/api/{{package_name}:{publisher}-v0.wit => chat:template.os-v0.wit} (76%) rename src/new/templates/javascript/no-ui/chat/{{package_name} => chat}/package.json (81%) rename src/new/templates/javascript/no-ui/chat/{{package_name} => chat}/src/lib.js (90%) create mode 100644 src/new/templates/javascript/no-ui/chat/send/Cargo.lock rename src/new/templates/javascript/no-ui/chat/send/{Cargo.toml_ => Cargo.toml} (100%) rename src/new/templates/javascript/no-ui/{fibonacci/{package_name} => echo/echo}/package.json (81%) rename src/new/templates/javascript/no-ui/echo/{{package_name} => echo}/src/lib.js (88%) rename src/new/templates/javascript/no-ui/{echo/{package_name} => fibonacci/fibonacci}/package.json (81%) rename src/new/templates/javascript/no-ui/fibonacci/{{package_name} => fibonacci}/src/lib.js (89%) rename src/new/templates/python/no-ui/chat/api/{{package_name}:{publisher}-v0.wit => chat:template.os-v0.wit} (76%) rename src/new/templates/python/no-ui/chat/{{package_name} => chat}/src/lib.py (84%) rename src/new/templates/python/no-ui/echo/{{package_name} => echo}/src/lib.py (86%) rename src/new/templates/python/no-ui/fibonacci/{{package_name} => fibonacci}/src/lib.py (88%) rename src/new/templates/rust/no-ui/blank/{Cargo.toml_ => Cargo.toml} (82%) rename src/new/templates/rust/no-ui/blank/{{package_name}/Cargo.toml_ => blank/Cargo.toml} (91%) rename src/new/templates/rust/no-ui/blank/{{package_name} => blank}/src/lib.rs (100%) rename src/new/templates/rust/no-ui/chat/{Cargo.toml_ => Cargo.toml} (83%) rename src/new/templates/rust/no-ui/chat/api/{{package_name}:{publisher}-v0.wit => chat:template.os-v0.wit} (76%) rename src/new/templates/rust/no-ui/{file_transfer/{package_name}/Cargo.toml_ => chat/chat/Cargo.toml} (94%) rename src/new/templates/rust/no-ui/chat/{{package_name} => chat}/src/lib.rs (91%) rename src/new/templates/rust/no-ui/chat/send/{Cargo.toml_ => Cargo.toml} (100%) rename src/new/templates/rust/no-ui/echo/{Cargo.toml_ => Cargo.toml} (82%) rename src/new/templates/rust/no-ui/echo/{{package_name}/Cargo.toml_ => echo/Cargo.toml} (95%) rename src/new/templates/rust/no-ui/echo/{{package_name} => echo}/src/lib.rs (100%) rename src/new/templates/rust/no-ui/fibonacci/{Cargo.toml_ => Cargo.toml} (84%) rename src/new/templates/rust/no-ui/fibonacci/api/{{package_name}:{publisher}-v0.wit => fibonacci:template.os-v0.wit} (61%) rename src/new/templates/rust/no-ui/fibonacci/{{package_name}/Cargo.toml_ => fibonacci/Cargo.toml} (95%) rename src/new/templates/rust/no-ui/fibonacci/{{package_name} => fibonacci}/src/lib.rs (94%) rename src/new/templates/rust/no-ui/fibonacci/number/{Cargo.toml_ => Cargo.toml} (100%) rename src/new/templates/rust/no-ui/file_transfer/{Cargo.toml_ => Cargo.toml} (89%) rename src/new/templates/rust/no-ui/file_transfer/api/{{package_name}:{publisher}-v0.wit => file_transfer:template.os-v0.wit} (93%) rename src/new/templates/rust/no-ui/file_transfer/download/{Cargo.toml_ => Cargo.toml} (100%) rename src/new/templates/rust/no-ui/{chat/{package_name}/Cargo.toml_ => file_transfer/file_transfer/Cargo.toml} (94%) rename src/new/templates/rust/no-ui/file_transfer/{{package_name} => file_transfer}/src/lib.rs (96%) rename src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/{Cargo.toml_ => Cargo.toml} (100%) rename src/new/templates/rust/no-ui/file_transfer/file_transfer_worker_api/{Cargo.toml_ => Cargo.toml} (100%) rename src/new/templates/rust/no-ui/file_transfer/list_files/{Cargo.toml_ => Cargo.toml} (100%) rename src/new/templates/rust/ui/chat/{Cargo.toml_ => Cargo.toml} (82%) rename src/new/templates/rust/ui/chat/{{package_name}/Cargo.toml_ => chat/Cargo.toml} (93%) rename src/new/templates/rust/ui/chat/{{package_name} => chat}/src/lib.rs (98%) rename src/new/templates/test/chat/{{package_name}_test/Cargo.toml_ => chat_test/Cargo.toml} (79%) create mode 100644 src/new/templates/test/chat/chat_test/api/chat_test:template.os-v0.wit rename src/new/templates/test/chat/{{package_name}_test/{package_name}_test/Cargo.toml_ => chat_test/chat_test/Cargo.toml} (94%) rename src/new/templates/test/chat/{{package_name}_test/{package_name}_test => chat_test/chat_test}/src/lib.rs (75%) rename src/new/templates/test/chat/{{package_name}_test/{package_name}_test => chat_test/chat_test}/src/tester_lib.rs (100%) rename src/new/templates/test/chat/{{package_name}_test => chat_test}/metadata.json (59%) create mode 100644 src/new/templates/test/chat/chat_test/pkg/manifest.json delete mode 100644 src/new/templates/test/chat/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit delete mode 100644 src/new/templates/test/chat/{package_name}_test/pkg/manifest.json create mode 100644 src/new/templates/test/echo/echo_test/Cargo.toml create mode 100644 src/new/templates/test/echo/echo_test/api/echo_test:template.os-v0.wit rename src/new/templates/test/echo/{{package_name}_test/{package_name}_test/Cargo.toml_ => echo_test/echo_test/Cargo.toml} (94%) rename src/new/templates/test/echo/{{package_name}_test/{package_name}_test => echo_test/echo_test}/src/lib.rs (78%) rename src/new/templates/test/echo/{{package_name}_test/{package_name}_test => echo_test/echo_test}/src/tester_lib.rs (100%) rename src/new/templates/test/echo/{{package_name}_test => echo_test}/metadata.json (64%) create mode 100644 src/new/templates/test/echo/echo_test/pkg/manifest.json delete mode 100644 src/new/templates/test/echo/{package_name}_test/Cargo.toml_ delete mode 100644 src/new/templates/test/echo/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit delete mode 100644 src/new/templates/test/echo/{package_name}_test/pkg/manifest.json create mode 100644 src/new/templates/test/fibonacci/fibonacci_test/Cargo.toml create mode 100644 src/new/templates/test/fibonacci/fibonacci_test/api/fibonacci_test:template.os-v0.wit rename src/new/templates/test/fibonacci/{{package_name}_test/{package_name}_test/Cargo.toml_ => fibonacci_test/fibonacci_test/Cargo.toml} (94%) rename src/new/templates/test/fibonacci/{{package_name}_test/{package_name}_test => fibonacci_test/fibonacci_test}/src/lib.rs (78%) rename src/new/templates/test/fibonacci/{{package_name}_test/{package_name}_test => fibonacci_test/fibonacci_test}/src/tester_lib.rs (100%) rename src/new/templates/test/fibonacci/{{package_name}_test => fibonacci_test}/metadata.json (59%) create mode 100644 src/new/templates/test/fibonacci/fibonacci_test/pkg/manifest.json delete mode 100644 src/new/templates/test/fibonacci/{package_name}_test/Cargo.toml_ delete mode 100644 src/new/templates/test/fibonacci/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit delete mode 100644 src/new/templates/test/fibonacci/{package_name}_test/pkg/manifest.json create mode 100644 src/new/templates/test/file_transfer/file_transfer_test/Cargo.toml create mode 100644 src/new/templates/test/file_transfer/file_transfer_test/api/file_transfer_test:template.os-v0.wit rename src/new/templates/test/file_transfer/{{package_name}_test/{package_name}_test/Cargo.toml_ => file_transfer_test/file_transfer_test/Cargo.toml} (94%) rename src/new/templates/test/file_transfer/{{package_name}_test/{package_name}_test => file_transfer_test/file_transfer_test}/src/lib.rs (75%) rename src/new/templates/test/file_transfer/{{package_name}_test/{package_name}_test => file_transfer_test/file_transfer_test}/src/tester_lib.rs (100%) create mode 100644 src/new/templates/test/file_transfer/file_transfer_test/metadata.json create mode 100644 src/new/templates/test/file_transfer/file_transfer_test/pkg/manifest.json delete mode 100644 src/new/templates/test/file_transfer/{package_name}_test/Cargo.toml_ delete mode 100644 src/new/templates/test/file_transfer/{package_name}_test/api/tester:sys-v0.wit delete mode 100644 src/new/templates/test/file_transfer/{package_name}_test/api/{package_name}:{publisher}-v0.wit delete mode 100644 src/new/templates/test/file_transfer/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit delete mode 100644 src/new/templates/test/file_transfer/{package_name}_test/metadata.json delete mode 100644 src/new/templates/test/file_transfer/{package_name}_test/pkg/manifest.json diff --git a/build.rs b/build.rs index 7baf0ddc..7d77c6d0 100644 --- a/build.rs +++ b/build.rs @@ -2,8 +2,9 @@ use std::fs; use std::io::{self, Write}; use std::path::Path; -const NEW_DIR: &str = "src/new"; const TEMPLATES_DIR: &str = "src/new/templates"; +const TARGET_DIR: &str = "target"; +const INCLUDES: &str = "includes.rs"; fn visit_dirs(dir: &Path, output_buffer: &mut Vec) -> io::Result<()> { if dir.is_dir() { @@ -20,7 +21,8 @@ fn visit_dirs(dir: &Path, output_buffer: &mut Vec) -> io::Result<()> { let relative_path = path.strip_prefix(TEMPLATES_DIR).unwrap(); let path_str = relative_path.to_str().unwrap().replace("\\", "/"); - let relative_path_from_includes = path.strip_prefix(NEW_DIR).unwrap(); + let relative_path_from_includes = Path::new("..").join(path); + //let relative_path_from_includes = path.strip_prefix(NEW_DIR).unwrap(); let path_str_from_includes = relative_path_from_includes .to_str() .unwrap() @@ -67,15 +69,19 @@ fn main() -> anyhow::Result<()> { writeln!( output_buffer, " (\"{}\", include_str!(\"{}\")),", - "componentize.mjs", "componentize.mjs", + "componentize.mjs", "../src/new/componentize.mjs", )?; visit_dirs(Path::new(TEMPLATES_DIR), &mut output_buffer)?; writeln!(&mut output_buffer, "];")?; - let output_path = Path::new(NEW_DIR).join("includes.rs"); + let target_dir = Path::new(TARGET_DIR); + let output_path = target_dir.join(INCLUDES); // create includes.rs if it does not exist + if !target_dir.exists() { + fs::create_dir_all(target_dir)?; + } if !output_path.exists() { fs::write(&output_path, &output_buffer)?; } else { diff --git a/src/new/mod.rs b/src/new/mod.rs index abf59b2d..7d0f6a0c 100644 --- a/src/new/mod.rs +++ b/src/new/mod.rs @@ -7,7 +7,7 @@ use color_eyre::{eyre::eyre, Result}; use fs_err as fs; use tracing::instrument; -include!("includes.rs"); +include!("../../target/includes.rs"); #[derive(Clone)] pub enum Language { @@ -109,23 +109,31 @@ fn replace_dots(input: &str) -> (String, String) { } } -fn replace_vars(input: &str, package_name: &str, publisher: &str) -> String { +fn replace_vars( + input: &str, + template_package_name: &str, + package_name: &str, + publisher: &str, +) -> String { + let template_package_name_kebab = template_package_name.replace("_", "-"); + let template_package_name_upper_camel = snake_to_upper_camel_case(template_package_name); + let package_name_kebab = package_name.replace("_", "-"); - let (publisher_dotted_snake, publisher_dotted_kebab) = replace_dots(publisher); let package_name_upper_camel = snake_to_upper_camel_case(package_name); + + let (publisher_dotted_snake, publisher_dotted_kebab) = replace_dots(publisher); let publisher_dotted_upper_camel = snake_to_upper_camel_case(&publisher_dotted_snake); input - .replace("{package_name}", package_name) - .replace("{package_name_kebab}", &package_name_kebab) - .replace("{package_name_upper_camel}", &package_name_upper_camel) - .replace("{publisher}", publisher) - .replace("{publisher_dotted_snake}", &publisher_dotted_snake) - .replace("{publisher_dotted_kebab}", &publisher_dotted_kebab) + .replace(template_package_name, package_name) + .replace(&template_package_name_kebab, &package_name_kebab) .replace( - "{publisher_dotted_upper_camel}", - &publisher_dotted_upper_camel, + &template_package_name_upper_camel, + &package_name_upper_camel, ) - .replace("Cargo.toml_", "Cargo.toml") + .replace("template.os", publisher) + .replace("template_dot_os", &publisher_dotted_snake) + .replace("template-dot-os", &publisher_dotted_kebab) + .replace("TemplateDotOs", &publisher_dotted_upper_camel) .to_string() } @@ -234,8 +242,10 @@ pub fn execute( } }) .and_then(|stripped| { - let modified_path = replace_vars(&stripped, &package_name, &publisher); - let modified_content = replace_vars(content, &package_name, &publisher); + let modified_path = + replace_vars(&stripped, &template.to_string(), &package_name, &publisher); + let modified_content = + replace_vars(content, &template.to_string(), &package_name, &publisher); Some((modified_path, modified_content)) }) }) @@ -269,7 +279,12 @@ pub fn execute( Language::Javascript => { path_to_content.insert( format!("{}/{}", package_name, PATH_TO_CONTENT[0].0), - replace_vars(PATH_TO_CONTENT[0].1, &package_name, &publisher), + replace_vars( + PATH_TO_CONTENT[0].1, + &template.to_string(), + &package_name, + &publisher, + ), ); } _ => {} diff --git a/src/new/templates/javascript/no-ui/chat/api/{package_name}:{publisher}-v0.wit b/src/new/templates/javascript/no-ui/chat/api/chat:template.os-v0.wit similarity index 76% rename from src/new/templates/javascript/no-ui/chat/api/{package_name}:{publisher}-v0.wit rename to src/new/templates/javascript/no-ui/chat/api/chat:template.os-v0.wit index 32cee559..9adc12ec 100644 --- a/src/new/templates/javascript/no-ui/chat/api/{package_name}:{publisher}-v0.wit +++ b/src/new/templates/javascript/no-ui/chat/api/chat:template.os-v0.wit @@ -1,4 +1,4 @@ -interface {package_name_kebab} { +interface chat { variant request { send(send-request), /// history of chat with given node @@ -21,7 +21,7 @@ interface {package_name_kebab} { } } -world {package_name_kebab}-{publisher_dotted_kebab}-v0 { - import {package_name_kebab}; +world chat-template-dot-os-v0 { + import chat; include process; } diff --git a/src/new/templates/javascript/no-ui/chat/{package_name}/package.json b/src/new/templates/javascript/no-ui/chat/chat/package.json similarity index 81% rename from src/new/templates/javascript/no-ui/chat/{package_name}/package.json rename to src/new/templates/javascript/no-ui/chat/chat/package.json index 6f723492..7c38cb64 100644 --- a/src/new/templates/javascript/no-ui/chat/{package_name}/package.json +++ b/src/new/templates/javascript/no-ui/chat/chat/package.json @@ -1,12 +1,12 @@ { - "name": "{package_name}", + "name": "chat", "version": "0.1.0", "description": "", "main": "index.js", "scripts": { "test": "echo \"Error: no test specified\" && exit 1" }, - "author": "{publisher}", + "author": "template.os", "license": "MIT", "dependencies": { "@bytecodealliance/componentize-js": "0.5.0" diff --git a/src/new/templates/javascript/no-ui/chat/{package_name}/src/lib.js b/src/new/templates/javascript/no-ui/chat/chat/src/lib.js similarity index 90% rename from src/new/templates/javascript/no-ui/chat/{package_name}/src/lib.js rename to src/new/templates/javascript/no-ui/chat/chat/src/lib.js index fe9c171d..70b9846f 100644 --- a/src/new/templates/javascript/no-ui/chat/{package_name}/src/lib.js +++ b/src/new/templates/javascript/no-ui/chat/chat/src/lib.js @@ -47,7 +47,7 @@ function handleMessage(ourNode, messageArchive) { if (body.Send) { const { target, message: messageText } = body.Send; if (target === ourNode) { - printToTerminal(0, `{package_name}|${source.node}: ${messageText}`); + printToTerminal(0, `chat|${source.node}: ${messageText}`); messageArchive = addToArchive( source.node, source.node, @@ -59,9 +59,9 @@ function handleMessage(ourNode, messageArchive) { { node: target, process: { - processName: "{package_name}", - packageName: "{package_name}", - publisherNode: "{publisher}" + processName: "chat", + packageName: "chat", + publisherNode: "template.os" } }, { @@ -106,7 +106,7 @@ function handleMessage(ourNode, messageArchive) { } export function init(our) { - printToTerminal(0, `{package_name}: begin (javascript)`); + printToTerminal(0, `chat: begin (javascript)`); const { node: ourNode } = parseAddress(our); let messageArchive = {}; @@ -115,7 +115,7 @@ export function init(our) { try { messageArchive = handleMessage(ourNode, messageArchive); } catch (error) { - printToTerminal(0, `{package_name}: got error ${error}`); + printToTerminal(0, `chat: got error ${error}`); } } } diff --git a/src/new/templates/javascript/no-ui/chat/metadata.json b/src/new/templates/javascript/no-ui/chat/metadata.json index 944b2bb4..2a864fd5 100644 --- a/src/new/templates/javascript/no-ui/chat/metadata.json +++ b/src/new/templates/javascript/no-ui/chat/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "chat", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "chat", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/javascript/no-ui/chat/pkg/manifest.json b/src/new/templates/javascript/no-ui/chat/pkg/manifest.json index f71144aa..3da591df 100644 --- a/src/new/templates/javascript/no-ui/chat/pkg/manifest.json +++ b/src/new/templates/javascript/no-ui/chat/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "chat", + "process_wasm_path": "/chat.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/javascript/no-ui/chat/pkg/scripts.json b/src/new/templates/javascript/no-ui/chat/pkg/scripts.json index ba63df9e..e89b6733 100644 --- a/src/new/templates/javascript/no-ui/chat/pkg/scripts.json +++ b/src/new/templates/javascript/no-ui/chat/pkg/scripts.json @@ -4,10 +4,10 @@ "public": false, "request_networking": false, "request_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "chat:chat:template.os" ], "grant_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "chat:chat:template.os" ] } } diff --git a/src/new/templates/javascript/no-ui/chat/send/Cargo.lock b/src/new/templates/javascript/no-ui/chat/send/Cargo.lock new file mode 100644 index 00000000..d9190e77 --- /dev/null +++ b/src/new/templates/javascript/no-ui/chat/send/Cargo.lock @@ -0,0 +1,2083 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "addr2line" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" +dependencies = [ + "gimli", +] + +[[package]] +name = "adler" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" + +[[package]] +name = "alloy-json-rpc" +version = "0.1.0" +source = "git+https://github.com/alloy-rs/alloy.git?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08" +dependencies = [ + "alloy-primitives", + "serde", + "serde_json", + "thiserror", +] + +[[package]] +name = "alloy-primitives" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "600d34d8de81e23b6d909c094e23b3d357e01ca36b78a8c5424c501eedbe86f0" +dependencies = [ + "alloy-rlp", + "bytes", + "cfg-if", + "const-hex", + "derive_more", + "hex-literal", + "itoa", + "k256", + "keccak-asm", + "proptest", + "rand", + "ruint", + "serde", + "tiny-keccak", +] + +[[package]] +name = "alloy-rlp" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26154390b1d205a4a7ac7352aa2eb4f81f391399d4e2f546fb81a2f8bb383f62" +dependencies = [ + "alloy-rlp-derive", + "arrayvec", + "bytes", +] + +[[package]] +name = "alloy-rlp-derive" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d0f2d905ebd295e7effec65e5f6868d153936130ae718352771de3e7d03c75c" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.74", +] + +[[package]] +name = "alloy-rpc-types" +version = "0.1.0" +source = "git+https://github.com/alloy-rs/alloy.git?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "itertools 0.12.1", + "serde", + "serde_json", + "thiserror", +] + +[[package]] +name = "alloy-transport" +version = "0.1.0" +source = "git+https://github.com/alloy-rs/alloy.git?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08" +dependencies = [ + "alloy-json-rpc", + "base64", + "futures-util", + "serde", + "serde_json", + "thiserror", + "tokio", + "tower", + "url", + "wasm-bindgen-futures", +] + +[[package]] +name = "anyhow" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" + +[[package]] +name = "ark-ff" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b3235cc41ee7a12aaaf2c575a2ad7b46713a8a50bda2fc3b003a04845c05dd6" +dependencies = [ + "ark-ff-asm 0.3.0", + "ark-ff-macros 0.3.0", + "ark-serialize 0.3.0", + "ark-std 0.3.0", + "derivative", + "num-bigint", + "num-traits", + "paste", + "rustc_version 0.3.3", + "zeroize", +] + +[[package]] +name = "ark-ff" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec847af850f44ad29048935519032c33da8aa03340876d351dfab5660d2966ba" +dependencies = [ + "ark-ff-asm 0.4.2", + "ark-ff-macros 0.4.2", + "ark-serialize 0.4.2", + "ark-std 0.4.0", + "derivative", + "digest 0.10.7", + "itertools 0.10.5", + "num-bigint", + "num-traits", + "paste", + "rustc_version 0.4.0", + "zeroize", +] + +[[package]] +name = "ark-ff-asm" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db02d390bf6643fb404d3d22d31aee1c4bc4459600aef9113833d17e786c6e44" +dependencies = [ + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-asm" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ed4aa4fe255d0bc6d79373f7e31d2ea147bcf486cba1be5ba7ea85abdb92348" +dependencies = [ + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-macros" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db2fd794a08ccb318058009eefdf15bcaaaaf6f8161eb3345f907222bac38b20" +dependencies = [ + "num-bigint", + "num-traits", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-macros" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" +dependencies = [ + "num-bigint", + "num-traits", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-serialize" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d6c2b318ee6e10f8c2853e73a83adc0ccb88995aa978d8a3408d492ab2ee671" +dependencies = [ + "ark-std 0.3.0", + "digest 0.9.0", +] + +[[package]] +name = "ark-serialize" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "adb7b85a02b83d2f22f89bd5cac66c9c89474240cb6207cb1efc16d098e822a5" +dependencies = [ + "ark-std 0.4.0", + "digest 0.10.7", + "num-bigint", +] + +[[package]] +name = "ark-std" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1df2c09229cbc5a028b1d70e00fdb2acee28b1055dfb5ca73eea49c5a25c4e7c" +dependencies = [ + "num-traits", + "rand", +] + +[[package]] +name = "ark-std" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185" +dependencies = [ + "num-traits", + "rand", +] + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "auto_impl" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c87f3f15e7794432337fc718554eaa4dc8f04c9677a950ffe366f20a162ae42" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.74", +] + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "backtrace" +version = "0.3.73" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" +dependencies = [ + "addr2line", + "cc", + "cfg-if", + "libc", + "miniz_oxide", + "object", + "rustc-demangle", +] + +[[package]] +name = "base16ct" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c7f02d4ea65f2c1853089ffd8d2787bdbc63de2f0d29dedbcf8ccdfa0ccd4cf" + +[[package]] +name = "base64" +version = "0.21.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" + +[[package]] +name = "base64ct" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" + +[[package]] +name = "bincode" +version = "1.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b1f45e9417d87227c7a56d22e471c6206462cba514c7590c09aff4cf6d1ddcad" +dependencies = [ + "serde", +] + +[[package]] +name = "bit-set" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0700ddab506f33b20a03b13996eccd309a48e5ff77d0d95926aa0210fb4e95f1" +dependencies = [ + "bit-vec", +] + +[[package]] +name = "bit-vec" +version = "0.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "349f9b6a179ed607305526ca489b34ad0a41aed5f7980fa90eb03160b69598fb" + +[[package]] +name = "bitflags" +version = "2.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" + +[[package]] +name = "bitvec" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bc2832c24239b0141d5674bb9174f9d68a8b5b3f2753311927c172ca46f7e9c" +dependencies = [ + "funty", + "radium", + "tap", + "wyz", +] + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "bumpalo" +version = "3.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" + +[[package]] +name = "byte-slice-cast" +version = "1.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3ac9f8b63eca6fd385229b3675f6cc0dc5c8a5c8a54a59d4f52ffd670d87b0c" + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "bytes" +version = "1.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8318a53db07bb3f8dca91a600466bdb3f2eaadeedfdbcf02e1accbad9271ba50" +dependencies = [ + "serde", +] + +[[package]] +name = "cc" +version = "1.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5fb8dd288a69fc53a1996d7ecfbf4a20d59065bff137ce7e56bbd620de191189" +dependencies = [ + "shlex", +] + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "const-hex" +version = "1.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94fb8a24a26d37e1ffd45343323dc9fe6654ceea44c12f2fcb3d7ac29e610bc6" +dependencies = [ + "cfg-if", + "cpufeatures", + "hex", + "proptest", + "serde", +] + +[[package]] +name = "const-oid" +version = "0.9.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" + +[[package]] +name = "convert_case" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" + +[[package]] +name = "cpufeatures" +version = "0.2.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" +dependencies = [ + "libc", +] + +[[package]] +name = "crunchy" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" + +[[package]] +name = "crypto-bigint" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0dc92fb57ca44df6db8059111ab3af99a63d5d0f8375d9972e319a379c6bab76" +dependencies = [ + "generic-array", + "rand_core", + "subtle", + "zeroize", +] + +[[package]] +name = "crypto-common" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "der" +version = "0.7.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f55bf8e7b65898637379c1b74eb1551107c8294ed26d855ceb9fd1a09cfc9bc0" +dependencies = [ + "const-oid", + "zeroize", +] + +[[package]] +name = "derivative" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "derive_more" +version = "0.99.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f33878137e4dafd7fa914ad4e259e18a4e8e532b9617a2d0150262bf53abfce" +dependencies = [ + "convert_case", + "proc-macro2", + "quote", + "rustc_version 0.4.0", + "syn 2.0.74", +] + +[[package]] +name = "digest" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" +dependencies = [ + "generic-array", +] + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer", + "const-oid", + "crypto-common", + "subtle", +] + +[[package]] +name = "ecdsa" +version = "0.16.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee27f32b5c5292967d2d4a9d7f1e0b0aed2c15daded5a60300e4abb9d8020bca" +dependencies = [ + "der", + "digest 0.10.7", + "elliptic-curve", + "rfc6979", + "signature", + "spki", +] + +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + +[[package]] +name = "elliptic-curve" +version = "0.13.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b5e6043086bf7973472e0c7dff2142ea0b680d30e18d9cc40f267efbf222bd47" +dependencies = [ + "base16ct", + "crypto-bigint", + "digest 0.10.7", + "ff", + "generic-array", + "group", + "pkcs8", + "rand_core", + "sec1", + "subtle", + "zeroize", +] + +[[package]] +name = "equivalent" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "errno" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "fastrand" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" + +[[package]] +name = "fastrlp" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "139834ddba373bbdd213dffe02c8d110508dcf1726c2be27e8d1f7d7e1856418" +dependencies = [ + "arrayvec", + "auto_impl", + "bytes", +] + +[[package]] +name = "ff" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ded41244b729663b1e574f1b4fb731469f69f79c17667b5d776b16cda0479449" +dependencies = [ + "rand_core", + "subtle", +] + +[[package]] +name = "fixed-hash" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "835c052cb0c08c1acf6ffd71c022172e18723949c8282f2b9f27efbc51e64534" +dependencies = [ + "byteorder", + "rand", + "rustc-hex", + "static_assertions", +] + +[[package]] +name = "fnv" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" + +[[package]] +name = "form_urlencoded" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "funty" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" + +[[package]] +name = "futures-core" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" + +[[package]] +name = "futures-macro" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.74", +] + +[[package]] +name = "futures-task" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" + +[[package]] +name = "futures-util" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" +dependencies = [ + "futures-core", + "futures-macro", + "futures-task", + "pin-project-lite", + "pin-utils", + "slab", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", + "zeroize", +] + +[[package]] +name = "getrandom" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" +dependencies = [ + "cfg-if", + "libc", + "wasi", +] + +[[package]] +name = "gimli" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" + +[[package]] +name = "group" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" +dependencies = [ + "ff", + "rand_core", + "subtle", +] + +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" + +[[package]] +name = "heck" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +dependencies = [ + "unicode-segmentation", +] + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" +dependencies = [ + "serde", +] + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "hmac" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "http" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" +dependencies = [ + "bytes", + "fnv", + "itoa", +] + +[[package]] +name = "id-arena" +version = "2.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "25a2bc672d1148e28034f176e01fffebb08b35768468cc954630da77a1449005" + +[[package]] +name = "idna" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" +dependencies = [ + "unicode-bidi", + "unicode-normalization", +] + +[[package]] +name = "impl-codec" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba6a270039626615617f3f36d15fc827041df3b78c439da2cadfa47455a77f2f" +dependencies = [ + "parity-scale-codec", +] + +[[package]] +name = "impl-trait-for-tuples" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "11d7a9f6330b71fea57921c9b61c47ee6e84f72d394754eff6163ae67e7395eb" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "indexmap" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93ead53efc7ea8ed3cfb0c79fc8023fbb782a5432b52830b6518941cebe6505c" +dependencies = [ + "equivalent", + "hashbrown", + "serde", +] + +[[package]] +name = "itertools" +version = "0.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" +dependencies = [ + "either", +] + +[[package]] +name = "itertools" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" +dependencies = [ + "either", +] + +[[package]] +name = "itoa" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" + +[[package]] +name = "js-sys" +version = "0.3.70" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1868808506b929d7b0cfa8f75951347aa71bb21144b7791bae35d9bccfcfe37a" +dependencies = [ + "wasm-bindgen", +] + +[[package]] +name = "k256" +version = "0.13.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "956ff9b67e26e1a6a866cb758f12c6f8746208489e3e4a4b5580802f2f0a587b" +dependencies = [ + "cfg-if", + "ecdsa", + "elliptic-curve", + "once_cell", + "sha2", + "signature", +] + +[[package]] +name = "keccak-asm" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "422fbc7ff2f2f5bdffeb07718e5a5324dca72b0c9293d50df4026652385e3314" +dependencies = [ + "digest 0.10.7", + "sha3-asm", +] + +[[package]] +name = "kinode_process_lib" +version = "0.6.0" +source = "git+https://github.com/kinode-dao/process_lib?rev=84b3d84#84b3d84c7c31185f15691a288f1b45dbffb18fe2" +dependencies = [ + "alloy-json-rpc", + "alloy-primitives", + "alloy-rpc-types", + "alloy-transport", + "anyhow", + "bincode", + "http", + "mime_guess", + "rand", + "serde", + "serde_json", + "thiserror", + "url", + "wit-bindgen", +] + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" + +[[package]] +name = "leb128" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "884e2677b40cc8c339eaefcb701c32ef1fd2493d71118dc0ca4b6a736c93bd67" + +[[package]] +name = "libc" +version = "0.2.155" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" + +[[package]] +name = "libm" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" + +[[package]] +name = "linux-raw-sys" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" + +[[package]] +name = "log" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" + +[[package]] +name = "memchr" +version = "2.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" + +[[package]] +name = "mime" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" + +[[package]] +name = "mime_guess" +version = "2.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f7c44f8e672c00fe5308fa235f821cb4198414e1c77935c1ab6948d3fd78550e" +dependencies = [ + "mime", + "unicase", +] + +[[package]] +name = "miniz_oxide" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" +dependencies = [ + "adler", +] + +[[package]] +name = "num-bigint" +version = "0.4.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" +dependencies = [ + "num-integer", + "num-traits", +] + +[[package]] +name = "num-integer" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" +dependencies = [ + "num-traits", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", + "libm", +] + +[[package]] +name = "object" +version = "0.36.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "27b64972346851a39438c60b341ebc01bba47464ae329e55cf343eb93964efd9" +dependencies = [ + "memchr", +] + +[[package]] +name = "once_cell" +version = "1.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" + +[[package]] +name = "parity-scale-codec" +version = "3.6.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "306800abfa29c7f16596b5970a588435e3d5b3149683d00c12b699cc19f895ee" +dependencies = [ + "arrayvec", + "bitvec", + "byte-slice-cast", + "impl-trait-for-tuples", + "parity-scale-codec-derive", + "serde", +] + +[[package]] +name = "parity-scale-codec-derive" +version = "3.6.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d830939c76d294956402033aee57a6da7b438f2294eb94864c37b0569053a42c" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "paste" +version = "1.0.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" + +[[package]] +name = "percent-encoding" +version = "2.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" + +[[package]] +name = "pest" +version = "2.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cd53dff83f26735fdc1ca837098ccf133605d794cdae66acfc2bfac3ec809d95" +dependencies = [ + "memchr", + "thiserror", + "ucd-trie", +] + +[[package]] +name = "pin-project" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.74", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" + +[[package]] +name = "pin-utils" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" + +[[package]] +name = "pkcs8" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" +dependencies = [ + "der", + "spki", +] + +[[package]] +name = "ppv-lite86" +version = "0.2.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04" +dependencies = [ + "zerocopy", +] + +[[package]] +name = "primitive-types" +version = "0.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b34d9fd68ae0b74a41b21c03c2f62847aa0ffea044eee893b4c140b37e244e2" +dependencies = [ + "fixed-hash", + "impl-codec", + "uint", +] + +[[package]] +name = "proc-macro-crate" +version = "3.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6d37c51ca738a55da99dc0c4a34860fd675453b8b36209178c2249bb13651284" +dependencies = [ + "toml_edit", +] + +[[package]] +name = "proc-macro2" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "proptest" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b4c2511913b88df1637da85cc8d96ec8e43a3f8bb8ccb71ee1ac240d6f3df58d" +dependencies = [ + "bit-set", + "bit-vec", + "bitflags", + "lazy_static", + "num-traits", + "rand", + "rand_chacha", + "rand_xorshift", + "regex-syntax", + "rusty-fork", + "tempfile", + "unarray", +] + +[[package]] +name = "quick-error" +version = "1.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radium" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" + +[[package]] +name = "rand" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +dependencies = [ + "libc", + "rand_chacha", + "rand_core", +] + +[[package]] +name = "rand_chacha" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" +dependencies = [ + "ppv-lite86", + "rand_core", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" +dependencies = [ + "getrandom", +] + +[[package]] +name = "rand_xorshift" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" +dependencies = [ + "rand_core", +] + +[[package]] +name = "regex-syntax" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" + +[[package]] +name = "rfc6979" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" +dependencies = [ + "hmac", + "subtle", +] + +[[package]] +name = "rlp" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb919243f34364b6bd2fc10ef797edbfa75f33c252e7998527479c6d6b47e1ec" +dependencies = [ + "bytes", + "rustc-hex", +] + +[[package]] +name = "ruint" +version = "1.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c3cc4c2511671f327125da14133d0c5c5d137f006a1017a16f557bc85b16286" +dependencies = [ + "alloy-rlp", + "ark-ff 0.3.0", + "ark-ff 0.4.2", + "bytes", + "fastrlp", + "num-bigint", + "num-traits", + "parity-scale-codec", + "primitive-types", + "proptest", + "rand", + "rlp", + "ruint-macro", + "serde", + "valuable", + "zeroize", +] + +[[package]] +name = "ruint-macro" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48fd7bd8a6377e15ad9d42a8ec25371b94ddc67abe7c8b9127bec79bebaaae18" + +[[package]] +name = "rustc-demangle" +version = "0.1.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" + +[[package]] +name = "rustc-hex" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6" + +[[package]] +name = "rustc_version" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0dfe2087c51c460008730de8b57e6a320782fbfb312e1f4d520e6c6fae155ee" +dependencies = [ + "semver 0.11.0", +] + +[[package]] +name = "rustc_version" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +dependencies = [ + "semver 1.0.23", +] + +[[package]] +name = "rustix" +version = "0.38.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" +dependencies = [ + "bitflags", + "errno", + "libc", + "linux-raw-sys", + "windows-sys 0.52.0", +] + +[[package]] +name = "rusty-fork" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb3dcc6e454c328bb824492db107ab7c0ae8fcffe4ad210136ef014458c1bc4f" +dependencies = [ + "fnv", + "quick-error", + "tempfile", + "wait-timeout", +] + +[[package]] +name = "ryu" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" + +[[package]] +name = "sec1" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3e97a565f76233a6003f9f5c54be1d9c5bdfa3eccfb189469f11ec4901c47dc" +dependencies = [ + "base16ct", + "der", + "generic-array", + "pkcs8", + "subtle", + "zeroize", +] + +[[package]] +name = "semver" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f301af10236f6df4160f7c3f04eec6dbc70ace82d23326abad5edee88801c6b6" +dependencies = [ + "semver-parser", +] + +[[package]] +name = "semver" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" + +[[package]] +name = "semver-parser" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0bef5b7f9e0df16536d3961cfb6e84331c065b4066afb39768d0e319411f7" +dependencies = [ + "pest", +] + +[[package]] +name = "send" +version = "0.1.0" +dependencies = [ + "anyhow", + "kinode_process_lib", + "serde", + "serde_json", + "wit-bindgen", +] + +[[package]] +name = "serde" +version = "1.0.207" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5665e14a49a4ea1b91029ba7d3bca9f299e1f7cfa194388ccc20f14743e784f2" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.207" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6aea2634c86b0e8ef2cfdc0c340baede54ec27b1e46febd7f80dffb2aa44a00e" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.74", +] + +[[package]] +name = "serde_json" +version = "1.0.124" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "66ad62847a56b3dba58cc891acd13884b9c61138d330c0d7b6181713d4fce38d" +dependencies = [ + "itoa", + "memchr", + "ryu", + "serde", +] + +[[package]] +name = "sha2" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" +dependencies = [ + "cfg-if", + "cpufeatures", + "digest 0.10.7", +] + +[[package]] +name = "sha3-asm" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57d79b758b7cb2085612b11a235055e485605a5103faccdd633f35bd7aee69dd" +dependencies = [ + "cc", + "cfg-if", +] + +[[package]] +name = "shlex" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" + +[[package]] +name = "signature" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de" +dependencies = [ + "digest 0.10.7", + "rand_core", +] + +[[package]] +name = "slab" +version = "0.4.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" +dependencies = [ + "autocfg", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "spdx" +version = "0.10.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "47317bbaf63785b53861e1ae2d11b80d6b624211d42cb20efcd210ee6f8a14bc" +dependencies = [ + "smallvec", +] + +[[package]] +name = "spki" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d91ed6c858b01f942cd56b37a94b3e0a1798290327d1236e4d9cf4eaca44d29d" +dependencies = [ + "base64ct", + "der", +] + +[[package]] +name = "static_assertions" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" + +[[package]] +name = "subtle" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" + +[[package]] +name = "syn" +version = "1.0.109" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "syn" +version = "2.0.74" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fceb41e3d546d0bd83421d3409b1460cc7444cd389341a4c880fe7a042cb3d7" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "tap" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" + +[[package]] +name = "tempfile" +version = "3.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "04cbcdd0c794ebb0d4cf35e88edd2f7d2c4c3e9a5a6dab322839b321c6a87a64" +dependencies = [ + "cfg-if", + "fastrand", + "once_cell", + "rustix", + "windows-sys 0.59.0", +] + +[[package]] +name = "thiserror" +version = "1.0.63" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c0342370b38b6a11b6cc11d6a805569958d54cfa061a29969c3b5ce2ea405724" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.63" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4558b58466b9ad7ca0f102865eccc95938dca1a74a856f2b57b6629050da261" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.74", +] + +[[package]] +name = "tiny-keccak" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237" +dependencies = [ + "crunchy", +] + +[[package]] +name = "tinyvec" +version = "1.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "445e881f4f6d382d5f27c034e25eb92edd7c784ceab92a0937db7f2e9471b938" +dependencies = [ + "tinyvec_macros", +] + +[[package]] +name = "tinyvec_macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" + +[[package]] +name = "tokio" +version = "1.39.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "daa4fb1bc778bd6f04cbfc4bb2d06a7396a8f299dc33ea1900cedaa316f467b1" +dependencies = [ + "backtrace", + "pin-project-lite", +] + +[[package]] +name = "toml_datetime" +version = "0.6.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0dd7358ecb8fc2f8d014bf86f6f638ce72ba252a2c3a2572f2a795f1d23efb41" + +[[package]] +name = "toml_edit" +version = "0.21.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a8534fd7f78b5405e860340ad6575217ce99f38d4d5c8f2442cb5ecb50090e1" +dependencies = [ + "indexmap", + "toml_datetime", + "winnow", +] + +[[package]] +name = "tower" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +dependencies = [ + "futures-core", + "futures-util", + "pin-project", + "pin-project-lite", + "tower-layer", + "tower-service", + "tracing", +] + +[[package]] +name = "tower-layer" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" + +[[package]] +name = "tower-service" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" + +[[package]] +name = "tracing" +version = "0.1.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" +dependencies = [ + "log", + "pin-project-lite", + "tracing-core", +] + +[[package]] +name = "tracing-core" +version = "0.1.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" +dependencies = [ + "once_cell", +] + +[[package]] +name = "typenum" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" + +[[package]] +name = "ucd-trie" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed646292ffc8188ef8ea4d1e0e0150fb15a5c2e12ad9b8fc191ae7a8a7f3c4b9" + +[[package]] +name = "uint" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76f64bba2c53b04fcab63c01a7d7427eadc821e3bc48c34dc9ba29c501164b52" +dependencies = [ + "byteorder", + "crunchy", + "hex", + "static_assertions", +] + +[[package]] +name = "unarray" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" + +[[package]] +name = "unicase" +version = "2.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f7d2d4dafb69621809a81864c9c1b864479e1235c0dd4e199924b9742439ed89" +dependencies = [ + "version_check", +] + +[[package]] +name = "unicode-bidi" +version = "0.3.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unicode-normalization" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a56d1686db2308d901306f92a263857ef59ea39678a5458e7cb17f01415101f5" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "unicode-segmentation" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" + +[[package]] +name = "unicode-xid" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" + +[[package]] +name = "url" +version = "2.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" +dependencies = [ + "form_urlencoded", + "idna", + "percent-encoding", +] + +[[package]] +name = "valuable" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" + +[[package]] +name = "version_check" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" + +[[package]] +name = "wait-timeout" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f200f5b12eb75f8c1ed65abd4b2db8a6e1b138a20de009dacee265a2498f3f6" +dependencies = [ + "libc", +] + +[[package]] +name = "wasi" +version = "0.11.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" + +[[package]] +name = "wasm-bindgen" +version = "0.2.93" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a82edfc16a6c469f5f44dc7b571814045d60404b55a0ee849f9bcfa2e63dd9b5" +dependencies = [ + "cfg-if", + "once_cell", + "wasm-bindgen-macro", +] + +[[package]] +name = "wasm-bindgen-backend" +version = "0.2.93" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9de396da306523044d3302746f1208fa71d7532227f15e347e2d93e4145dd77b" +dependencies = [ + "bumpalo", + "log", + "once_cell", + "proc-macro2", + "quote", + "syn 2.0.74", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.43" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61e9300f63a621e96ed275155c108eb6f843b6a26d053f122ab69724559dc8ed" +dependencies = [ + "cfg-if", + "js-sys", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.93" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "585c4c91a46b072c92e908d99cb1dcdf95c5218eeb6f3bf1efa991ee7a68cccf" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.93" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "afc340c74d9005395cf9dd098506f7f44e38f2b4a21c6aaacf9a105ea5e1e836" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.74", + "wasm-bindgen-backend", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.93" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c62a0a307cb4a311d3a07867860911ca130c3494e8c2719593806c08bc5d0484" + +[[package]] +name = "wasm-encoder" +version = "0.202.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfd106365a7f5f7aa3c1916a98cbb3ad477f5ff96ddb130285a91c6e7429e67a" +dependencies = [ + "leb128", +] + +[[package]] +name = "wasm-metadata" +version = "0.202.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "094aea3cb90e09f16ee25a4c0e324b3e8c934e7fd838bfa039aef5352f44a917" +dependencies = [ + "anyhow", + "indexmap", + "serde", + "serde_derive", + "serde_json", + "spdx", + "wasm-encoder", + "wasmparser", +] + +[[package]] +name = "wasmparser" +version = "0.202.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d6998515d3cf3f8b980ef7c11b29a9b1017d4cf86b99ae93b546992df9931413" +dependencies = [ + "bitflags", + "indexmap", + "semver 1.0.23", +] + +[[package]] +name = "web-sys" +version = "0.3.70" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26fdeaafd9bd129f65e7c031593c24d62186301e0c72c8978fa1678be7d532c0" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets", +] + +[[package]] +name = "windows-sys" +version = "0.59.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" +dependencies = [ + "windows-targets", +] + +[[package]] +name = "windows-targets" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" +dependencies = [ + "windows_aarch64_gnullvm", + "windows_aarch64_msvc", + "windows_i686_gnu", + "windows_i686_gnullvm", + "windows_i686_msvc", + "windows_x86_64_gnu", + "windows_x86_64_gnullvm", + "windows_x86_64_msvc", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" + +[[package]] +name = "windows_i686_gnu" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" + +[[package]] +name = "windows_i686_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" + +[[package]] +name = "winnow" +version = "0.5.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" +dependencies = [ + "memchr", +] + +[[package]] +name = "wit-bindgen" +version = "0.24.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fb4e7653763780be47e38f479e9aa83c768aa6a3b2ed086dc2826fdbbb7e7f5" +dependencies = [ + "wit-bindgen-rt", + "wit-bindgen-rust-macro", +] + +[[package]] +name = "wit-bindgen-core" +version = "0.24.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b67e11c950041849a10828c7600ea62a4077c01e8af72e8593253575428f91b" +dependencies = [ + "anyhow", + "wit-parser", +] + +[[package]] +name = "wit-bindgen-rt" +version = "0.24.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b0780cf7046630ed70f689a098cd8d56c5c3b22f2a7379bbdb088879963ff96" +dependencies = [ + "bitflags", +] + +[[package]] +name = "wit-bindgen-rust" +version = "0.24.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "30acbe8fb708c3a830a33c4cb705df82659bf831b492ec6ca1a17a369cfeeafb" +dependencies = [ + "anyhow", + "heck", + "indexmap", + "wasm-metadata", + "wit-bindgen-core", + "wit-component", +] + +[[package]] +name = "wit-bindgen-rust-macro" +version = "0.24.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b1b06eae85feaecdf9f2854f7cac124e00d5a6e5014bfb02eb1ecdeb5f265b9" +dependencies = [ + "anyhow", + "proc-macro2", + "quote", + "syn 2.0.74", + "wit-bindgen-core", + "wit-bindgen-rust", +] + +[[package]] +name = "wit-component" +version = "0.202.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c836b1fd9932de0431c1758d8be08212071b6bba0151f7bac826dbc4312a2a9" +dependencies = [ + "anyhow", + "bitflags", + "indexmap", + "log", + "serde", + "serde_derive", + "serde_json", + "wasm-encoder", + "wasm-metadata", + "wasmparser", + "wit-parser", +] + +[[package]] +name = "wit-parser" +version = "0.202.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "744237b488352f4f27bca05a10acb79474415951c450e52ebd0da784c1df2bcc" +dependencies = [ + "anyhow", + "id-arena", + "indexmap", + "log", + "semver 1.0.23", + "serde", + "serde_derive", + "serde_json", + "unicode-xid", + "wasmparser", +] + +[[package]] +name = "wyz" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05f360fc0b24296329c78fda852a1e9ae82de9cf7b27dae4b7f62f118f77b9ed" +dependencies = [ + "tap", +] + +[[package]] +name = "zerocopy" +version = "0.7.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" +dependencies = [ + "byteorder", + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.74", +] + +[[package]] +name = "zeroize" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" +dependencies = [ + "zeroize_derive", +] + +[[package]] +name = "zeroize_derive" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.74", +] diff --git a/src/new/templates/javascript/no-ui/chat/send/Cargo.toml_ b/src/new/templates/javascript/no-ui/chat/send/Cargo.toml similarity index 100% rename from src/new/templates/javascript/no-ui/chat/send/Cargo.toml_ rename to src/new/templates/javascript/no-ui/chat/send/Cargo.toml diff --git a/src/new/templates/javascript/no-ui/chat/send/src/lib.rs b/src/new/templates/javascript/no-ui/chat/send/src/lib.rs index 508f8b28..e819550a 100644 --- a/src/new/templates/javascript/no-ui/chat/send/src/lib.rs +++ b/src/new/templates/javascript/no-ui/chat/send/src/lib.rs @@ -1,11 +1,11 @@ -use crate::kinode::process::{package_name}::{Request as ChatRequest, Response as ChatResponse, SendRequest}; +use crate::kinode::process::chat::{Request as ChatRequest, Response as ChatResponse, SendRequest}; use kinode_process_lib::{ await_next_message_body, call_init, println, Address, Message, Request, }; wit_bindgen::generate!({ path: "target/wit", - world: "{package_name}-{publisher_dotted_kebab}-v0", + world: "chat-template-dot-os-v0", generate_unused_types: true, additional_derives: [serde::Deserialize, serde::Serialize], }); @@ -20,12 +20,12 @@ fn init(our: Address) { let args = String::from_utf8(body).unwrap_or_default(); let Some((target, message)) = args.split_once(" ") else { - println!("usage:\nsend:{package_name}:{publisher} target message"); + println!("usage:\nsend:chat:template.os target message"); return; }; let Ok(Ok(Message::Response { body, .. })) = - Request::to((our.node(), ("{package_name}", "{package_name}", "{publisher}"))) + Request::to((our.node(), ("chat", "chat", "template.os"))) .body( serde_json::to_vec(&ChatRequest::Send(SendRequest { target: target.into(), @@ -35,12 +35,12 @@ fn init(our: Address) { ) .send_and_await_response(5) else { - println!("did not receive expected Response from {package_name}:{package_name}:{publisher}"); + println!("did not receive expected Response from chat:chat:template.os"); return; }; let Ok(ChatResponse::Send) = serde_json::from_slice(&body) else { - println!("did not receive expected Ack from {package_name}:{package_name}:{publisher}"); + println!("did not receive expected Ack from chat:chat:template.os"); return; }; } diff --git a/src/new/templates/javascript/no-ui/fibonacci/{package_name}/package.json b/src/new/templates/javascript/no-ui/echo/echo/package.json similarity index 81% rename from src/new/templates/javascript/no-ui/fibonacci/{package_name}/package.json rename to src/new/templates/javascript/no-ui/echo/echo/package.json index 6f723492..ee1ed38c 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/{package_name}/package.json +++ b/src/new/templates/javascript/no-ui/echo/echo/package.json @@ -1,12 +1,12 @@ { - "name": "{package_name}", + "name": "echo", "version": "0.1.0", "description": "", "main": "index.js", "scripts": { "test": "echo \"Error: no test specified\" && exit 1" }, - "author": "{publisher}", + "author": "template.os", "license": "MIT", "dependencies": { "@bytecodealliance/componentize-js": "0.5.0" diff --git a/src/new/templates/javascript/no-ui/echo/{package_name}/src/lib.js b/src/new/templates/javascript/no-ui/echo/echo/src/lib.js similarity index 88% rename from src/new/templates/javascript/no-ui/echo/{package_name}/src/lib.js rename to src/new/templates/javascript/no-ui/echo/echo/src/lib.js index 6c11d676..8a8bef76 100644 --- a/src/new/templates/javascript/no-ui/echo/{package_name}/src/lib.js +++ b/src/new/templates/javascript/no-ui/echo/echo/src/lib.js @@ -31,7 +31,7 @@ function handleMessage(ourNode, messageArchive) { const { bytes: bodyBytes, string: body0 } = inputBytesToString(message.val.body) const body = JSON.parse(body0); const encoder = new TextEncoder(); - printToTerminal(0, `{package_name}: got message ${JSON.stringify(body)}`); + printToTerminal(0, `echo: got message ${JSON.stringify(body)}`); sendResponse( { inherit: false, @@ -45,7 +45,7 @@ function handleMessage(ourNode, messageArchive) { } export function init(our) { - printToTerminal(0, `{package_name}: begin (javascript)`); + printToTerminal(0, `echo: begin (javascript)`); const { node: ourNode } = parseAddress(our); @@ -53,7 +53,7 @@ export function init(our) { try { handleMessage(ourNode); } catch (error) { - printToTerminal(0, `{package_name}: got error ${error}`); + printToTerminal(0, `echo: got error ${error}`); } } } diff --git a/src/new/templates/javascript/no-ui/echo/metadata.json b/src/new/templates/javascript/no-ui/echo/metadata.json index 944b2bb4..232e5343 100644 --- a/src/new/templates/javascript/no-ui/echo/metadata.json +++ b/src/new/templates/javascript/no-ui/echo/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "echo", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "echo", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/javascript/no-ui/echo/pkg/manifest.json b/src/new/templates/javascript/no-ui/echo/pkg/manifest.json index f71144aa..7fc7826e 100644 --- a/src/new/templates/javascript/no-ui/echo/pkg/manifest.json +++ b/src/new/templates/javascript/no-ui/echo/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "echo", + "process_wasm_path": "/echo.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/javascript/no-ui/echo/{package_name}/package.json b/src/new/templates/javascript/no-ui/fibonacci/fibonacci/package.json similarity index 81% rename from src/new/templates/javascript/no-ui/echo/{package_name}/package.json rename to src/new/templates/javascript/no-ui/fibonacci/fibonacci/package.json index 6f723492..1856b5b7 100644 --- a/src/new/templates/javascript/no-ui/echo/{package_name}/package.json +++ b/src/new/templates/javascript/no-ui/fibonacci/fibonacci/package.json @@ -1,12 +1,12 @@ { - "name": "{package_name}", + "name": "fibonacci", "version": "0.1.0", "description": "", "main": "index.js", "scripts": { "test": "echo \"Error: no test specified\" && exit 1" }, - "author": "{publisher}", + "author": "template.os", "license": "MIT", "dependencies": { "@bytecodealliance/componentize-js": "0.5.0" diff --git a/src/new/templates/javascript/no-ui/fibonacci/{package_name}/src/lib.js b/src/new/templates/javascript/no-ui/fibonacci/fibonacci/src/lib.js similarity index 89% rename from src/new/templates/javascript/no-ui/fibonacci/{package_name}/src/lib.js rename to src/new/templates/javascript/no-ui/fibonacci/fibonacci/src/lib.js index d7a4c386..084d7ab9 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/{package_name}/src/lib.js +++ b/src/new/templates/javascript/no-ui/fibonacci/fibonacci/src/lib.js @@ -44,7 +44,7 @@ function handleMessage(ourNode) { const start = Date.now(); const result = fibonacci(number); const duration = (Date.now() - start) * 1000000; - printToTerminal(0, `{package_name}: fibonacci(${number}) = ${result}; ${duration}ns`); + printToTerminal(0, `fibonacci: fibonacci(${number}) = ${result}; ${duration}ns`); sendResponse( { inherit: false, @@ -70,7 +70,7 @@ function handleMessage(ourNode) { .reduce((sum, item) => sum + item, 0) / numberTrials; printToTerminal( 0, - `{package_name}: fibonacci(${number}) = ${result}; ${mean}±${absoluteDeviation}ns averaged over ${numberTrials} trials`, + `fibonacci: fibonacci(${number}) = ${result}; ${mean}±${absoluteDeviation}ns averaged over ${numberTrials} trials`, ); sendResponse( { @@ -88,7 +88,7 @@ function handleMessage(ourNode) { } export function init(our) { - printToTerminal(0, `{package_name}: begin (javascript)`); + printToTerminal(0, `fibonacci: begin (javascript)`); const { node: ourNode } = parseAddress(our); @@ -96,7 +96,7 @@ export function init(our) { try { handleMessage(ourNode); } catch (error) { - printToTerminal(0, `{package_name}: got error ${error}`); + printToTerminal(0, `fibonacci: got error ${error}`); } } } diff --git a/src/new/templates/javascript/no-ui/fibonacci/metadata.json b/src/new/templates/javascript/no-ui/fibonacci/metadata.json index 944b2bb4..b5157157 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/metadata.json +++ b/src/new/templates/javascript/no-ui/fibonacci/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "fibonacci", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "fibonacci", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/javascript/no-ui/fibonacci/pkg/manifest.json b/src/new/templates/javascript/no-ui/fibonacci/pkg/manifest.json index f71144aa..b621d87d 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/pkg/manifest.json +++ b/src/new/templates/javascript/no-ui/fibonacci/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "fibonacci", + "process_wasm_path": "/fibonacci.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/python/no-ui/chat/api/{package_name}:{publisher}-v0.wit b/src/new/templates/python/no-ui/chat/api/chat:template.os-v0.wit similarity index 76% rename from src/new/templates/python/no-ui/chat/api/{package_name}:{publisher}-v0.wit rename to src/new/templates/python/no-ui/chat/api/chat:template.os-v0.wit index 32cee559..9adc12ec 100644 --- a/src/new/templates/python/no-ui/chat/api/{package_name}:{publisher}-v0.wit +++ b/src/new/templates/python/no-ui/chat/api/chat:template.os-v0.wit @@ -1,4 +1,4 @@ -interface {package_name_kebab} { +interface chat { variant request { send(send-request), /// history of chat with given node @@ -21,7 +21,7 @@ interface {package_name_kebab} { } } -world {package_name_kebab}-{publisher_dotted_kebab}-v0 { - import {package_name_kebab}; +world chat-template-dot-os-v0 { + import chat; include process; } diff --git a/src/new/templates/python/no-ui/chat/{package_name}/src/lib.py b/src/new/templates/python/no-ui/chat/chat/src/lib.py similarity index 84% rename from src/new/templates/python/no-ui/chat/{package_name}/src/lib.py rename to src/new/templates/python/no-ui/chat/chat/src/lib.py index 45beadbc..68b47104 100644 --- a/src/new/templates/python/no-ui/chat/{package_name}/src/lib.py +++ b/src/new/templates/python/no-ui/chat/chat/src/lib.py @@ -1,7 +1,7 @@ import json -import {package_name}_{publisher_dotted_snake}_v0 -from {package_name}_{publisher_dotted_snake}_v0.imports.standard import ( +import chat_template_dot_os_v0 +from chat_template_dot_os_v0.imports.standard import ( Address, MessageRequest, MessageResponse, @@ -13,7 +13,7 @@ send_and_await_response, send_response, ) -from {package_name}_{publisher_dotted_snake}_v0.types import Err +from chat_template_dot_os_v0.types import Err def parse_address(address_string): node, _, rest = address_string.partition("@") @@ -59,7 +59,7 @@ def handle_message(our_node, message_archive): send_and_await_response( Address( target, - ProcessId("{package_name}", "{package_name}", "{publisher}"), + ProcessId("chat", "chat", "template.os"), ), Request(False, 5, message.value.body, None, []), None, @@ -90,9 +90,9 @@ def handle_message(our_node, message_archive): return message_archive -class {package_name_upper_camel}{publisher_dotted_upper_camel}V0({package_name}_{publisher_dotted_snake}_v0.{package_name_upper_camel}{publisher_dotted_upper_camel}V0): +class ChatTemplateDotOsV0(chat_template_dot_os_v0.ChatTemplateDotOsV0): def init(self, our): - print_to_terminal(0, "{package_name}: begin (python)") + print_to_terminal(0, "chat: begin (python)") our_node, _, _, _ = parse_address(our) message_archive = {} @@ -101,4 +101,4 @@ def init(self, our): try: message_archive = handle_message(our_node, message_archive) except Exception as e: - print_to_terminal(0, f"{package_name}: error: {e}") + print_to_terminal(0, f"chat: error: {e}") diff --git a/src/new/templates/python/no-ui/chat/metadata.json b/src/new/templates/python/no-ui/chat/metadata.json index 944b2bb4..2a864fd5 100644 --- a/src/new/templates/python/no-ui/chat/metadata.json +++ b/src/new/templates/python/no-ui/chat/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "chat", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "chat", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/python/no-ui/chat/pkg/manifest.json b/src/new/templates/python/no-ui/chat/pkg/manifest.json index f71144aa..3da591df 100644 --- a/src/new/templates/python/no-ui/chat/pkg/manifest.json +++ b/src/new/templates/python/no-ui/chat/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "chat", + "process_wasm_path": "/chat.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/python/no-ui/chat/pkg/scripts.json b/src/new/templates/python/no-ui/chat/pkg/scripts.json index ba63df9e..e89b6733 100644 --- a/src/new/templates/python/no-ui/chat/pkg/scripts.json +++ b/src/new/templates/python/no-ui/chat/pkg/scripts.json @@ -4,10 +4,10 @@ "public": false, "request_networking": false, "request_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "chat:chat:template.os" ], "grant_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "chat:chat:template.os" ] } } diff --git a/src/new/templates/python/no-ui/chat/send/src/lib.py b/src/new/templates/python/no-ui/chat/send/src/lib.py index d441f955..9e9a7ddb 100644 --- a/src/new/templates/python/no-ui/chat/send/src/lib.py +++ b/src/new/templates/python/no-ui/chat/send/src/lib.py @@ -1,7 +1,7 @@ import json -import {package_name}_{publisher_dotted_snake}_v0 -from {package_name}_{publisher_dotted_snake}_v0.imports.standard import ( +import chat_template_dot_os_v0 +from chat_template_dot_os_v0.imports.standard import ( Address, MessageRequest, MessageResponse, @@ -10,7 +10,7 @@ receive, send_and_await_response, ) -from {package_name}_{publisher_dotted_snake}_v0.types import Err +from chat_template_dot_os_v0.types import Err def parse_address(address_string): node, _, rest = address_string.partition("@") @@ -20,7 +20,7 @@ def parse_address(address_string): return node, process, package, publisher -class {package_name_upper_camel}{publisher_dotted_upper_camel}V0({package_name}_{publisher_dotted_snake}_v0.{package_name_upper_camel}{publisher_dotted_upper_camel}V0): +class ChatTemplateDotOsV0(chat_template_dot_os_v0.ChatTemplateDotOsV0): def init(self, our): our_node, _, _, _ = parse_address(our) result = receive() @@ -44,7 +44,7 @@ def init(self, our): response = send_and_await_response( Address( our_node, - ProcessId("{package_name}", "{package_name}", "{publisher}"), + ProcessId("chat", "chat", "template.os"), ), Request(False, 5, json.dumps(request).encode("utf-8"), None, []), None, diff --git a/src/new/templates/python/no-ui/echo/{package_name}/src/lib.py b/src/new/templates/python/no-ui/echo/echo/src/lib.py similarity index 86% rename from src/new/templates/python/no-ui/echo/{package_name}/src/lib.py rename to src/new/templates/python/no-ui/echo/echo/src/lib.py index c1743d79..c0ea98d2 100644 --- a/src/new/templates/python/no-ui/echo/{package_name}/src/lib.py +++ b/src/new/templates/python/no-ui/echo/echo/src/lib.py @@ -31,7 +31,7 @@ def handle_message(our_node): raise Exception(f"unexpected Response: {message}") case MessageRequest(): body = json.loads(message.value.body.decode("utf-8")) - print_to_terminal(0, f"{package_name}: got message {body}") + print_to_terminal(0, f"echo: got message {body}") send_response( Response( False, @@ -44,7 +44,7 @@ def handle_message(our_node): class Process(process.Process): def init(self, our): - print_to_terminal(0, "{package_name}: begin (python)") + print_to_terminal(0, "echo: begin (python)") our_node, _, _, _ = parse_address(our) @@ -52,4 +52,4 @@ def init(self, our): try: handle_message(our_node) except Exception as e: - print_to_terminal(0, f"{package_name}: error: {e}") + print_to_terminal(0, f"echo: error: {e}") diff --git a/src/new/templates/python/no-ui/echo/metadata.json b/src/new/templates/python/no-ui/echo/metadata.json index 944b2bb4..232e5343 100644 --- a/src/new/templates/python/no-ui/echo/metadata.json +++ b/src/new/templates/python/no-ui/echo/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "echo", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "echo", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/python/no-ui/echo/pkg/manifest.json b/src/new/templates/python/no-ui/echo/pkg/manifest.json index f71144aa..7fc7826e 100644 --- a/src/new/templates/python/no-ui/echo/pkg/manifest.json +++ b/src/new/templates/python/no-ui/echo/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "echo", + "process_wasm_path": "/echo.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/python/no-ui/fibonacci/{package_name}/src/lib.py b/src/new/templates/python/no-ui/fibonacci/fibonacci/src/lib.py similarity index 88% rename from src/new/templates/python/no-ui/fibonacci/{package_name}/src/lib.py rename to src/new/templates/python/no-ui/fibonacci/fibonacci/src/lib.py index 16932a54..257fc4f3 100644 --- a/src/new/templates/python/no-ui/fibonacci/{package_name}/src/lib.py +++ b/src/new/templates/python/no-ui/fibonacci/fibonacci/src/lib.py @@ -48,7 +48,7 @@ def handle_message(our_node): duration = time.perf_counter_ns() - start print_to_terminal( 0, - f"{package_name}: fibonacci({number}) = {result}; {duration}ns", + f"fibonacci: fibonacci({number}) = {result}; {duration}ns", ) send_response( Response(False, json.dumps({"Number": result}).encode("utf-8"), None, []), @@ -66,7 +66,7 @@ def handle_message(our_node): absolute_deviation = sum(abs(item - mean) for item in durations) / number_trials print_to_terminal( 0, - f"{package_name}: fibonacci({number}) = {result}; {duration}±{absolute_deviation}ns averaged over {number_trials} trials", + f"fibonacci: fibonacci({number}) = {result}; {duration}±{absolute_deviation}ns averaged over {number_trials} trials", ) send_response( Response( @@ -82,7 +82,7 @@ def handle_message(our_node): class Process(process.Process): def init(self, our): - print_to_terminal(0, "{package_name}: begin (python)") + print_to_terminal(0, "fibonacci: begin (python)") our_node, _, _, _ = parse_address(our) @@ -90,4 +90,4 @@ def init(self, our): try: handle_message(our_node) except Exception as e: - print_to_terminal(0, f"{package_name}: error: {e}") + print_to_terminal(0, f"fibonacci: error: {e}") diff --git a/src/new/templates/python/no-ui/fibonacci/metadata.json b/src/new/templates/python/no-ui/fibonacci/metadata.json index 944b2bb4..b5157157 100644 --- a/src/new/templates/python/no-ui/fibonacci/metadata.json +++ b/src/new/templates/python/no-ui/fibonacci/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "fibonacci", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "fibonacci", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/python/no-ui/fibonacci/pkg/manifest.json b/src/new/templates/python/no-ui/fibonacci/pkg/manifest.json index f71144aa..b621d87d 100644 --- a/src/new/templates/python/no-ui/fibonacci/pkg/manifest.json +++ b/src/new/templates/python/no-ui/fibonacci/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "fibonacci", + "process_wasm_path": "/fibonacci.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/rust/no-ui/blank/Cargo.toml_ b/src/new/templates/rust/no-ui/blank/Cargo.toml similarity index 82% rename from src/new/templates/rust/no-ui/blank/Cargo.toml_ rename to src/new/templates/rust/no-ui/blank/Cargo.toml index 31d65e6d..a90ed6c7 100644 --- a/src/new/templates/rust/no-ui/blank/Cargo.toml_ +++ b/src/new/templates/rust/no-ui/blank/Cargo.toml @@ -1,7 +1,7 @@ [workspace] resolver = "2" members = [ - "{package_name}", + "blank", ] [profile.release] diff --git a/src/new/templates/rust/no-ui/blank/{package_name}/Cargo.toml_ b/src/new/templates/rust/no-ui/blank/blank/Cargo.toml similarity index 91% rename from src/new/templates/rust/no-ui/blank/{package_name}/Cargo.toml_ rename to src/new/templates/rust/no-ui/blank/blank/Cargo.toml index 1ad787f6..635edccb 100644 --- a/src/new/templates/rust/no-ui/blank/{package_name}/Cargo.toml_ +++ b/src/new/templates/rust/no-ui/blank/blank/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "{package_name}" +name = "blank" version = "0.1.0" edition = "2021" diff --git a/src/new/templates/rust/no-ui/blank/{package_name}/src/lib.rs b/src/new/templates/rust/no-ui/blank/blank/src/lib.rs similarity index 100% rename from src/new/templates/rust/no-ui/blank/{package_name}/src/lib.rs rename to src/new/templates/rust/no-ui/blank/blank/src/lib.rs diff --git a/src/new/templates/rust/no-ui/blank/metadata.json b/src/new/templates/rust/no-ui/blank/metadata.json index 940b56a7..013b3109 100644 --- a/src/new/templates/rust/no-ui/blank/metadata.json +++ b/src/new/templates/rust/no-ui/blank/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "blank", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "blank", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/rust/no-ui/blank/pkg/manifest.json b/src/new/templates/rust/no-ui/blank/pkg/manifest.json index bf0b8a3c..15deded5 100644 --- a/src/new/templates/rust/no-ui/blank/pkg/manifest.json +++ b/src/new/templates/rust/no-ui/blank/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "blank", + "process_wasm_path": "/blank.wasm", "on_exit": "Restart", "request_networking": false, "request_capabilities": [], diff --git a/src/new/templates/rust/no-ui/chat/Cargo.toml_ b/src/new/templates/rust/no-ui/chat/Cargo.toml similarity index 83% rename from src/new/templates/rust/no-ui/chat/Cargo.toml_ rename to src/new/templates/rust/no-ui/chat/Cargo.toml index b1993b8b..ba357d04 100644 --- a/src/new/templates/rust/no-ui/chat/Cargo.toml_ +++ b/src/new/templates/rust/no-ui/chat/Cargo.toml @@ -1,7 +1,7 @@ [workspace] resolver = "2" members = [ - "{package_name}", + "chat", "send", ] diff --git a/src/new/templates/rust/no-ui/chat/api/{package_name}:{publisher}-v0.wit b/src/new/templates/rust/no-ui/chat/api/chat:template.os-v0.wit similarity index 76% rename from src/new/templates/rust/no-ui/chat/api/{package_name}:{publisher}-v0.wit rename to src/new/templates/rust/no-ui/chat/api/chat:template.os-v0.wit index c6eb7c36..d883229b 100644 --- a/src/new/templates/rust/no-ui/chat/api/{package_name}:{publisher}-v0.wit +++ b/src/new/templates/rust/no-ui/chat/api/chat:template.os-v0.wit @@ -1,4 +1,4 @@ -interface {package_name_kebab} { +interface chat { variant request { send(send-request), /// history of chat with given node @@ -21,7 +21,7 @@ interface {package_name_kebab} { } } -world {package_name_kebab}-{publisher_dotted_kebab}-v0 { - import {package_name_kebab}; +world chat-template-dot-os-v0 { + import chat; include process-v0; } diff --git a/src/new/templates/rust/no-ui/file_transfer/{package_name}/Cargo.toml_ b/src/new/templates/rust/no-ui/chat/chat/Cargo.toml similarity index 94% rename from src/new/templates/rust/no-ui/file_transfer/{package_name}/Cargo.toml_ rename to src/new/templates/rust/no-ui/chat/chat/Cargo.toml index eff3bb6a..83b7c6bc 100644 --- a/src/new/templates/rust/no-ui/file_transfer/{package_name}/Cargo.toml_ +++ b/src/new/templates/rust/no-ui/chat/chat/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "{package_name}" +name = "chat" version = "0.1.0" edition = "2021" diff --git a/src/new/templates/rust/no-ui/chat/{package_name}/src/lib.rs b/src/new/templates/rust/no-ui/chat/chat/src/lib.rs similarity index 91% rename from src/new/templates/rust/no-ui/chat/{package_name}/src/lib.rs rename to src/new/templates/rust/no-ui/chat/chat/src/lib.rs index 6b64b14f..493dae2a 100644 --- a/src/new/templates/rust/no-ui/chat/{package_name}/src/lib.rs +++ b/src/new/templates/rust/no-ui/chat/chat/src/lib.rs @@ -1,11 +1,11 @@ use std::collections::HashMap; -use crate::kinode::process::{package_name}::{ChatMessage, Request as ChatRequest, Response as ChatResponse, SendRequest}; +use crate::kinode::process::chat::{ChatMessage, Request as ChatRequest, Response as ChatResponse, SendRequest}; use kinode_process_lib::{await_message, call_init, println, Address, Message, Request, Response}; wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-{publisher_dotted_kebab}-v0", + world: "chat-template-dot-os-v0", generate_unused_types: true, additional_derives: [serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); @@ -42,7 +42,7 @@ fn handle_message( let _ = Request::new() .target(Address { node: target.clone(), - process: "{package_name}:{package_name}:{publisher}".parse()?, + process: "chat:chat:template.os".parse()?, }) .body(body) .send_and_await_response(5)? diff --git a/src/new/templates/rust/no-ui/chat/metadata.json b/src/new/templates/rust/no-ui/chat/metadata.json index 940b56a7..267211d6 100644 --- a/src/new/templates/rust/no-ui/chat/metadata.json +++ b/src/new/templates/rust/no-ui/chat/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "chat", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "chat", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/rust/no-ui/chat/pkg/manifest.json b/src/new/templates/rust/no-ui/chat/pkg/manifest.json index f71144aa..3da591df 100644 --- a/src/new/templates/rust/no-ui/chat/pkg/manifest.json +++ b/src/new/templates/rust/no-ui/chat/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "chat", + "process_wasm_path": "/chat.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/rust/no-ui/chat/pkg/scripts.json b/src/new/templates/rust/no-ui/chat/pkg/scripts.json index ba63df9e..e89b6733 100644 --- a/src/new/templates/rust/no-ui/chat/pkg/scripts.json +++ b/src/new/templates/rust/no-ui/chat/pkg/scripts.json @@ -4,10 +4,10 @@ "public": false, "request_networking": false, "request_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "chat:chat:template.os" ], "grant_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "chat:chat:template.os" ] } } diff --git a/src/new/templates/rust/no-ui/chat/send/Cargo.toml_ b/src/new/templates/rust/no-ui/chat/send/Cargo.toml similarity index 100% rename from src/new/templates/rust/no-ui/chat/send/Cargo.toml_ rename to src/new/templates/rust/no-ui/chat/send/Cargo.toml diff --git a/src/new/templates/rust/no-ui/chat/send/src/lib.rs b/src/new/templates/rust/no-ui/chat/send/src/lib.rs index 0496bf49..e819550a 100644 --- a/src/new/templates/rust/no-ui/chat/send/src/lib.rs +++ b/src/new/templates/rust/no-ui/chat/send/src/lib.rs @@ -1,11 +1,11 @@ -use crate::kinode::process::{package_name}::{Request as ChatRequest, Response as ChatResponse, SendRequest}; +use crate::kinode::process::chat::{Request as ChatRequest, Response as ChatResponse, SendRequest}; use kinode_process_lib::{ await_next_message_body, call_init, println, Address, Message, Request, }; wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-{publisher_dotted_kebab}-v0", + world: "chat-template-dot-os-v0", generate_unused_types: true, additional_derives: [serde::Deserialize, serde::Serialize], }); @@ -20,12 +20,12 @@ fn init(our: Address) { let args = String::from_utf8(body).unwrap_or_default(); let Some((target, message)) = args.split_once(" ") else { - println!("usage:\nsend:{package_name}:{publisher} target message"); + println!("usage:\nsend:chat:template.os target message"); return; }; let Ok(Ok(Message::Response { body, .. })) = - Request::to((our.node(), ("{package_name}", "{package_name}", "{publisher}"))) + Request::to((our.node(), ("chat", "chat", "template.os"))) .body( serde_json::to_vec(&ChatRequest::Send(SendRequest { target: target.into(), @@ -35,12 +35,12 @@ fn init(our: Address) { ) .send_and_await_response(5) else { - println!("did not receive expected Response from {package_name}:{package_name}:{publisher}"); + println!("did not receive expected Response from chat:chat:template.os"); return; }; let Ok(ChatResponse::Send) = serde_json::from_slice(&body) else { - println!("did not receive expected Ack from {package_name}:{package_name}:{publisher}"); + println!("did not receive expected Ack from chat:chat:template.os"); return; }; } diff --git a/src/new/templates/rust/no-ui/echo/Cargo.toml_ b/src/new/templates/rust/no-ui/echo/Cargo.toml similarity index 82% rename from src/new/templates/rust/no-ui/echo/Cargo.toml_ rename to src/new/templates/rust/no-ui/echo/Cargo.toml index 31d65e6d..c645c207 100644 --- a/src/new/templates/rust/no-ui/echo/Cargo.toml_ +++ b/src/new/templates/rust/no-ui/echo/Cargo.toml @@ -1,7 +1,7 @@ [workspace] resolver = "2" members = [ - "{package_name}", + "echo", ] [profile.release] diff --git a/src/new/templates/rust/no-ui/echo/{package_name}/Cargo.toml_ b/src/new/templates/rust/no-ui/echo/echo/Cargo.toml similarity index 95% rename from src/new/templates/rust/no-ui/echo/{package_name}/Cargo.toml_ rename to src/new/templates/rust/no-ui/echo/echo/Cargo.toml index e4c3c320..ee2d8283 100644 --- a/src/new/templates/rust/no-ui/echo/{package_name}/Cargo.toml_ +++ b/src/new/templates/rust/no-ui/echo/echo/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "{package_name}" +name = "echo" version = "0.1.0" edition = "2021" diff --git a/src/new/templates/rust/no-ui/echo/{package_name}/src/lib.rs b/src/new/templates/rust/no-ui/echo/echo/src/lib.rs similarity index 100% rename from src/new/templates/rust/no-ui/echo/{package_name}/src/lib.rs rename to src/new/templates/rust/no-ui/echo/echo/src/lib.rs diff --git a/src/new/templates/rust/no-ui/echo/metadata.json b/src/new/templates/rust/no-ui/echo/metadata.json index 940b56a7..1c6395fe 100644 --- a/src/new/templates/rust/no-ui/echo/metadata.json +++ b/src/new/templates/rust/no-ui/echo/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "echo", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "echo", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/rust/no-ui/echo/pkg/manifest.json b/src/new/templates/rust/no-ui/echo/pkg/manifest.json index f71144aa..7fc7826e 100644 --- a/src/new/templates/rust/no-ui/echo/pkg/manifest.json +++ b/src/new/templates/rust/no-ui/echo/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "echo", + "process_wasm_path": "/echo.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/rust/no-ui/fibonacci/Cargo.toml_ b/src/new/templates/rust/no-ui/fibonacci/Cargo.toml similarity index 84% rename from src/new/templates/rust/no-ui/fibonacci/Cargo.toml_ rename to src/new/templates/rust/no-ui/fibonacci/Cargo.toml index ff34e3e1..0302299b 100644 --- a/src/new/templates/rust/no-ui/fibonacci/Cargo.toml_ +++ b/src/new/templates/rust/no-ui/fibonacci/Cargo.toml @@ -1,7 +1,7 @@ [workspace] resolver = "2" members = [ - "{package_name}", + "fibonacci", "number", ] diff --git a/src/new/templates/rust/no-ui/fibonacci/api/{package_name}:{publisher}-v0.wit b/src/new/templates/rust/no-ui/fibonacci/api/fibonacci:template.os-v0.wit similarity index 61% rename from src/new/templates/rust/no-ui/fibonacci/api/{package_name}:{publisher}-v0.wit rename to src/new/templates/rust/no-ui/fibonacci/api/fibonacci:template.os-v0.wit index 73615f3f..c1bf5012 100644 --- a/src/new/templates/rust/no-ui/fibonacci/api/{package_name}:{publisher}-v0.wit +++ b/src/new/templates/rust/no-ui/fibonacci/api/fibonacci:template.os-v0.wit @@ -1,4 +1,4 @@ -interface {package_name_kebab} { +interface fibonacci { variant request { number(u32), numbers(tuple), @@ -10,7 +10,7 @@ interface {package_name_kebab} { } } -world {package_name_kebab}-{publisher_dotted_kebab}-v0 { - import {package_name_kebab}; +world fibonacci-template-dot-os-v0 { + import fibonacci; include process-v0; } diff --git a/src/new/templates/rust/no-ui/fibonacci/{package_name}/Cargo.toml_ b/src/new/templates/rust/no-ui/fibonacci/fibonacci/Cargo.toml similarity index 95% rename from src/new/templates/rust/no-ui/fibonacci/{package_name}/Cargo.toml_ rename to src/new/templates/rust/no-ui/fibonacci/fibonacci/Cargo.toml index e4c3c320..a2c20aa1 100644 --- a/src/new/templates/rust/no-ui/fibonacci/{package_name}/Cargo.toml_ +++ b/src/new/templates/rust/no-ui/fibonacci/fibonacci/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "{package_name}" +name = "fibonacci" version = "0.1.0" edition = "2021" diff --git a/src/new/templates/rust/no-ui/fibonacci/{package_name}/src/lib.rs b/src/new/templates/rust/no-ui/fibonacci/fibonacci/src/lib.rs similarity index 94% rename from src/new/templates/rust/no-ui/fibonacci/{package_name}/src/lib.rs rename to src/new/templates/rust/no-ui/fibonacci/fibonacci/src/lib.rs index 17cd1cac..80f84091 100644 --- a/src/new/templates/rust/no-ui/fibonacci/{package_name}/src/lib.rs +++ b/src/new/templates/rust/no-ui/fibonacci/fibonacci/src/lib.rs @@ -1,9 +1,9 @@ -use crate::kinode::process::{package_name}::{Request as FibonacciRequest, Response as FibonacciResponse}; +use crate::kinode::process::fibonacci::{Request as FibonacciRequest, Response as FibonacciResponse}; use kinode_process_lib::{await_message, call_init, println, Address, Message, Response}; wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-{publisher_dotted_kebab}-v0", + world: "fibonacci-template-dot-os-v0", generate_unused_types: true, additional_derives: [serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); diff --git a/src/new/templates/rust/no-ui/fibonacci/metadata.json b/src/new/templates/rust/no-ui/fibonacci/metadata.json index 940b56a7..7f1b5264 100644 --- a/src/new/templates/rust/no-ui/fibonacci/metadata.json +++ b/src/new/templates/rust/no-ui/fibonacci/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "fibonacci", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "fibonacci", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/rust/no-ui/fibonacci/number/Cargo.toml_ b/src/new/templates/rust/no-ui/fibonacci/number/Cargo.toml similarity index 100% rename from src/new/templates/rust/no-ui/fibonacci/number/Cargo.toml_ rename to src/new/templates/rust/no-ui/fibonacci/number/Cargo.toml diff --git a/src/new/templates/rust/no-ui/fibonacci/number/src/lib.rs b/src/new/templates/rust/no-ui/fibonacci/number/src/lib.rs index 324f5cdf..b5ea141f 100644 --- a/src/new/templates/rust/no-ui/fibonacci/number/src/lib.rs +++ b/src/new/templates/rust/no-ui/fibonacci/number/src/lib.rs @@ -1,11 +1,11 @@ -use crate::kinode::process::{package_name}::{Request as FibonacciRequest, Response as FibonacciResponse}; +use crate::kinode::process::fibonacci::{Request as FibonacciRequest, Response as FibonacciResponse}; use kinode_process_lib::{ await_next_message_body, call_init, println, Address, Message, Request, }; wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-{publisher_dotted_kebab}-v0", + world: "fibonacci-template-dot-os-v0", generate_unused_types: true, additional_derives: [serde::Deserialize, serde::Serialize], }); @@ -23,16 +23,16 @@ fn init(our: Address) { .unwrap_or_default(); let Ok(Ok(Message::Response { body, .. })) = - Request::to((our.node(), ("{package_name}", "{package_name}", "{publisher}"))) + Request::to((our.node(), ("fibonacci", "fibonacci", "template.os"))) .body(serde_json::to_vec(&FibonacciRequest::Number(number)).unwrap()) .send_and_await_response(5) else { - println!("did not receive expected Response from {package_name}:{package_name}:{publisher}"); + println!("did not receive expected Response from fibonacci:fibonacci:template.os"); return; }; let Ok(FibonacciResponse::Number(_number)) = serde_json::from_slice(&body) else { - println!("did not receive expected Ack from {package_name}:{package_name}:{publisher}"); + println!("did not receive expected Ack from fibonacci:fibonacci:template.os"); return; }; diff --git a/src/new/templates/rust/no-ui/fibonacci/pkg/manifest.json b/src/new/templates/rust/no-ui/fibonacci/pkg/manifest.json index f71144aa..b621d87d 100644 --- a/src/new/templates/rust/no-ui/fibonacci/pkg/manifest.json +++ b/src/new/templates/rust/no-ui/fibonacci/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "fibonacci", + "process_wasm_path": "/fibonacci.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/rust/no-ui/fibonacci/pkg/scripts.json b/src/new/templates/rust/no-ui/fibonacci/pkg/scripts.json index 7ecc1275..521fcac8 100644 --- a/src/new/templates/rust/no-ui/fibonacci/pkg/scripts.json +++ b/src/new/templates/rust/no-ui/fibonacci/pkg/scripts.json @@ -4,10 +4,10 @@ "public": false, "request_networking": false, "request_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "fibonacci:fibonacci:template.os" ], "grant_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "fibonacci:fibonacci:template.os" ] } } diff --git a/src/new/templates/rust/no-ui/file_transfer/Cargo.toml_ b/src/new/templates/rust/no-ui/file_transfer/Cargo.toml similarity index 89% rename from src/new/templates/rust/no-ui/file_transfer/Cargo.toml_ rename to src/new/templates/rust/no-ui/file_transfer/Cargo.toml index 0a734fee..918afe14 100644 --- a/src/new/templates/rust/no-ui/file_transfer/Cargo.toml_ +++ b/src/new/templates/rust/no-ui/file_transfer/Cargo.toml @@ -1,7 +1,7 @@ [workspace] resolver = "2" members = [ - "{package_name}", + "file_transfer", "file_transfer_worker_api", "file_transfer_worker", "download", diff --git a/src/new/templates/rust/no-ui/file_transfer/api/{package_name}:{publisher}-v0.wit b/src/new/templates/rust/no-ui/file_transfer/api/file_transfer:template.os-v0.wit similarity index 93% rename from src/new/templates/rust/no-ui/file_transfer/api/{package_name}:{publisher}-v0.wit rename to src/new/templates/rust/no-ui/file_transfer/api/file_transfer:template.os-v0.wit index e0e1a9d1..3f5a3ed2 100644 --- a/src/new/templates/rust/no-ui/file_transfer/api/{package_name}:{publisher}-v0.wit +++ b/src/new/templates/rust/no-ui/file_transfer/api/file_transfer:template.os-v0.wit @@ -1,4 +1,4 @@ -interface {package_name_kebab} { +interface file-transfer { variant request { list-files, } @@ -72,8 +72,8 @@ world file-transfer-worker-api-v0 { export file-transfer-worker; } -world {package_name_kebab}-{publisher_dotted_kebab}-v0 { - import {package_name_kebab}; +world file-transfer-template-dot-os-v0 { + import file-transfer; import file-transfer-worker; include process-v0; } diff --git a/src/new/templates/rust/no-ui/file_transfer/download/Cargo.toml_ b/src/new/templates/rust/no-ui/file_transfer/download/Cargo.toml similarity index 100% rename from src/new/templates/rust/no-ui/file_transfer/download/Cargo.toml_ rename to src/new/templates/rust/no-ui/file_transfer/download/Cargo.toml diff --git a/src/new/templates/rust/no-ui/file_transfer/download/src/lib.rs b/src/new/templates/rust/no-ui/file_transfer/download/src/lib.rs index b728e452..5ce579d4 100644 --- a/src/new/templates/rust/no-ui/file_transfer/download/src/lib.rs +++ b/src/new/templates/rust/no-ui/file_transfer/download/src/lib.rs @@ -6,7 +6,7 @@ use kinode_process_lib::{ wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-{publisher_dotted_kebab}-v0", + world: "file-transfer-template-dot-os-v0", generate_unused_types: true, additional_derives: [serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); @@ -39,14 +39,14 @@ fn init(our: Address) { let args = String::from_utf8(body).unwrap_or_default(); let Some((name, who)) = args.split_once(" ") else { - println!("usage: download:{package_name}:{publisher} file_name who"); + println!("usage: download:file_transfer:template.os file_name who"); return; }; - let our: Address = format!("{}@{package_name}:{package_name}:{publisher}", our.node()) + let our: Address = format!("{}@file_transfer:file_transfer:template.os", our.node()) .parse() .unwrap(); - let target: Address = format!("{}@{package_name}:{package_name}:{publisher}", who) + let target: Address = format!("{}@file_transfer:file_transfer:template.os", who) .parse() .unwrap(); diff --git a/src/new/templates/rust/no-ui/chat/{package_name}/Cargo.toml_ b/src/new/templates/rust/no-ui/file_transfer/file_transfer/Cargo.toml similarity index 94% rename from src/new/templates/rust/no-ui/chat/{package_name}/Cargo.toml_ rename to src/new/templates/rust/no-ui/file_transfer/file_transfer/Cargo.toml index eff3bb6a..a511ca85 100644 --- a/src/new/templates/rust/no-ui/chat/{package_name}/Cargo.toml_ +++ b/src/new/templates/rust/no-ui/file_transfer/file_transfer/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "{package_name}" +name = "file_transfer" version = "0.1.0" edition = "2021" diff --git a/src/new/templates/rust/no-ui/file_transfer/{package_name}/src/lib.rs b/src/new/templates/rust/no-ui/file_transfer/file_transfer/src/lib.rs similarity index 96% rename from src/new/templates/rust/no-ui/file_transfer/{package_name}/src/lib.rs rename to src/new/templates/rust/no-ui/file_transfer/file_transfer/src/lib.rs index 1f3c7879..155dfcbb 100644 --- a/src/new/templates/rust/no-ui/file_transfer/{package_name}/src/lib.rs +++ b/src/new/templates/rust/no-ui/file_transfer/file_transfer/src/lib.rs @@ -1,6 +1,6 @@ use crate::kinode::process::standard::{Address as WitAddress, ProcessId as WitProcessId}; use crate::kinode::process::file_transfer_worker::{start_download, Request as WorkerRequest, Response as WorkerResponse, DownloadRequest, ProgressRequest}; -use crate::kinode::process::{package_name}::{Request as TransferRequest, Response as TransferResponse, FileInfo}; +use crate::kinode::process::file_transfer::{Request as TransferRequest, Response as TransferResponse, FileInfo}; use kinode_process_lib::{ await_message, call_init, println, vfs::{create_drive, metadata, open_dir, Directory, FileType}, @@ -9,7 +9,7 @@ use kinode_process_lib::{ wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-{publisher_dotted_kebab}-v0", + world: "file-transfer-template-dot-os-v0", generate_unused_types: true, additional_derives: [serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); diff --git a/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/Cargo.toml_ b/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/Cargo.toml similarity index 100% rename from src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/Cargo.toml_ rename to src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/Cargo.toml diff --git a/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/src/lib.rs b/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/src/lib.rs index f5dc1ed9..9a918630 100644 --- a/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/src/lib.rs +++ b/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/src/lib.rs @@ -11,7 +11,7 @@ use kinode_process_lib::{ wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-{publisher_dotted_kebab}-v0", + world: "file-transfer-template-dot-os-v0", generate_unused_types: true, additional_derives: [serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); diff --git a/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker_api/Cargo.toml_ b/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker_api/Cargo.toml similarity index 100% rename from src/new/templates/rust/no-ui/file_transfer/file_transfer_worker_api/Cargo.toml_ rename to src/new/templates/rust/no-ui/file_transfer/file_transfer_worker_api/Cargo.toml diff --git a/src/new/templates/rust/no-ui/file_transfer/list_files/Cargo.toml_ b/src/new/templates/rust/no-ui/file_transfer/list_files/Cargo.toml similarity index 100% rename from src/new/templates/rust/no-ui/file_transfer/list_files/Cargo.toml_ rename to src/new/templates/rust/no-ui/file_transfer/list_files/Cargo.toml diff --git a/src/new/templates/rust/no-ui/file_transfer/list_files/src/lib.rs b/src/new/templates/rust/no-ui/file_transfer/list_files/src/lib.rs index 81ce611e..6f14cbc5 100644 --- a/src/new/templates/rust/no-ui/file_transfer/list_files/src/lib.rs +++ b/src/new/templates/rust/no-ui/file_transfer/list_files/src/lib.rs @@ -1,11 +1,11 @@ -use crate::kinode::process::{package_name}::{Request as TransferRequest, Response as TransferResponse}; +use crate::kinode::process::file_transfer::{Request as TransferRequest, Response as TransferResponse}; use kinode_process_lib::{ await_next_message_body, call_init, println, Address, Message, Request, }; wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-{publisher_dotted_kebab}-v0", + world: "file-transfer-template-dot-os-v0", generate_unused_types: true, additional_derives: [serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); @@ -19,11 +19,11 @@ fn init(_our: Address) { let who = String::from_utf8(body).unwrap_or_default(); if who.is_empty() { - println!("usage: list_files:{package_name}:{publisher} who"); + println!("usage: list_files:file_transfer:template.os who"); return; } - let target: Address = format!("{}@{package_name}:{package_name}:{publisher}", who) + let target: Address = format!("{}@file_transfer:file_transfer:template.os", who) .parse() .unwrap(); diff --git a/src/new/templates/rust/no-ui/file_transfer/metadata.json b/src/new/templates/rust/no-ui/file_transfer/metadata.json index 259d2a1e..ce2ffac6 100644 --- a/src/new/templates/rust/no-ui/file_transfer/metadata.json +++ b/src/new/templates/rust/no-ui/file_transfer/metadata.json @@ -1,18 +1,18 @@ { - "name": "{package_name}", + "name": "file_transfer", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "file_transfer", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" }, "wit_version": 0, "dependencies": [ - "{package_name}:{publisher}" + "file_transfer:template.os" ] }, "external_url": "", diff --git a/src/new/templates/rust/no-ui/file_transfer/pkg/manifest.json b/src/new/templates/rust/no-ui/file_transfer/pkg/manifest.json index 44c7d1e8..c6a3c81a 100644 --- a/src/new/templates/rust/no-ui/file_transfer/pkg/manifest.json +++ b/src/new/templates/rust/no-ui/file_transfer/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "file_transfer", + "process_wasm_path": "/file_transfer.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/rust/no-ui/file_transfer/pkg/scripts.json b/src/new/templates/rust/no-ui/file_transfer/pkg/scripts.json index 5b67bc76..381b699e 100644 --- a/src/new/templates/rust/no-ui/file_transfer/pkg/scripts.json +++ b/src/new/templates/rust/no-ui/file_transfer/pkg/scripts.json @@ -4,10 +4,10 @@ "public": false, "request_networking": false, "request_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "file_transfer:file_transfer:template.os" ], "grant_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "file_transfer:file_transfer:template.os" ], "wit_version": 0 }, @@ -16,10 +16,10 @@ "public": false, "request_networking": true, "request_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "file_transfer:file_transfer:template.os" ], "grant_capabilities": [ - "{package_name}:{package_name}:{publisher}" + "file_transfer:file_transfer:template.os" ], "wit_version": 0 } diff --git a/src/new/templates/rust/ui/chat/Cargo.toml_ b/src/new/templates/rust/ui/chat/Cargo.toml similarity index 82% rename from src/new/templates/rust/ui/chat/Cargo.toml_ rename to src/new/templates/rust/ui/chat/Cargo.toml index 31d65e6d..ffd3e3f2 100644 --- a/src/new/templates/rust/ui/chat/Cargo.toml_ +++ b/src/new/templates/rust/ui/chat/Cargo.toml @@ -1,7 +1,7 @@ [workspace] resolver = "2" members = [ - "{package_name}", + "chat", ] [profile.release] diff --git a/src/new/templates/rust/ui/chat/{package_name}/Cargo.toml_ b/src/new/templates/rust/ui/chat/chat/Cargo.toml similarity index 93% rename from src/new/templates/rust/ui/chat/{package_name}/Cargo.toml_ rename to src/new/templates/rust/ui/chat/chat/Cargo.toml index c73909b5..42cb0fee 100644 --- a/src/new/templates/rust/ui/chat/{package_name}/Cargo.toml_ +++ b/src/new/templates/rust/ui/chat/chat/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "{package_name}" +name = "chat" version = "0.1.0" edition = "2021" diff --git a/src/new/templates/rust/ui/chat/{package_name}/src/lib.rs b/src/new/templates/rust/ui/chat/chat/src/lib.rs similarity index 98% rename from src/new/templates/rust/ui/chat/{package_name}/src/lib.rs rename to src/new/templates/rust/ui/chat/chat/src/lib.rs index 5522ece5..687b0520 100644 --- a/src/new/templates/rust/ui/chat/{package_name}/src/lib.rs +++ b/src/new/templates/rust/ui/chat/chat/src/lib.rs @@ -152,7 +152,7 @@ fn handle_chat_request( Request::new() .target(Address { node: target.clone(), - process: ProcessId::from_str("{package_name}:{package_name}:{publisher}")?, + process: ProcessId::from_str("chat:chat:template.os")?, }) .body(body) .send_and_await_response(5)??; diff --git a/src/new/templates/rust/ui/chat/metadata.json b/src/new/templates/rust/ui/chat/metadata.json index 940b56a7..267211d6 100644 --- a/src/new/templates/rust/ui/chat/metadata.json +++ b/src/new/templates/rust/ui/chat/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name}", + "name": "chat", "description": "", "image": "", "properties": { - "package_name": "{package_name}", + "package_name": "chat", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/rust/ui/chat/pkg/manifest.json b/src/new/templates/rust/ui/chat/pkg/manifest.json index 44c7d1e8..0e55daa8 100644 --- a/src/new/templates/rust/ui/chat/pkg/manifest.json +++ b/src/new/templates/rust/ui/chat/pkg/manifest.json @@ -1,7 +1,7 @@ [ { - "process_name": "{package_name}", - "process_wasm_path": "/{package_name}.wasm", + "process_name": "chat", + "process_wasm_path": "/chat.wasm", "on_exit": "Restart", "request_networking": true, "request_capabilities": [ diff --git a/src/new/templates/test/chat/{package_name}_test/Cargo.toml_ b/src/new/templates/test/chat/chat_test/Cargo.toml similarity index 79% rename from src/new/templates/test/chat/{package_name}_test/Cargo.toml_ rename to src/new/templates/test/chat/chat_test/Cargo.toml index 6c797c34..7021d14c 100644 --- a/src/new/templates/test/chat/{package_name}_test/Cargo.toml_ +++ b/src/new/templates/test/chat/chat_test/Cargo.toml @@ -1,7 +1,7 @@ [workspace] resolver = "2" members = [ - "{package_name}_test", + "chat_test", ] [profile.release] diff --git a/src/new/templates/test/chat/chat_test/api/chat_test:template.os-v0.wit b/src/new/templates/test/chat/chat_test/api/chat_test:template.os-v0.wit new file mode 100644 index 00000000..c87f01eb --- /dev/null +++ b/src/new/templates/test/chat/chat_test/api/chat_test:template.os-v0.wit @@ -0,0 +1,5 @@ +world chat-test-template-dot-os-v0 { + import chat; + import tester; + include process-v0; +} diff --git a/src/new/templates/test/chat/{package_name}_test/{package_name}_test/Cargo.toml_ b/src/new/templates/test/chat/chat_test/chat_test/Cargo.toml similarity index 94% rename from src/new/templates/test/chat/{package_name}_test/{package_name}_test/Cargo.toml_ rename to src/new/templates/test/chat/chat_test/chat_test/Cargo.toml index c8717be6..905155d1 100644 --- a/src/new/templates/test/chat/{package_name}_test/{package_name}_test/Cargo.toml_ +++ b/src/new/templates/test/chat/chat_test/chat_test/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "{package_name}_test" +name = "chat_test" version = "0.1.0" edition = "2021" diff --git a/src/new/templates/test/chat/{package_name}_test/{package_name}_test/src/lib.rs b/src/new/templates/test/chat/chat_test/chat_test/src/lib.rs similarity index 75% rename from src/new/templates/test/chat/{package_name}_test/{package_name}_test/src/lib.rs rename to src/new/templates/test/chat/chat_test/chat_test/src/lib.rs index c0637710..40e55a74 100644 --- a/src/new/templates/test/chat/{package_name}_test/{package_name}_test/src/lib.rs +++ b/src/new/templates/test/chat/chat_test/chat_test/src/lib.rs @@ -1,4 +1,4 @@ -use crate::kinode::process::{package_name}::{ChatMessage, Request as ChatRequest, Response as ChatResponse, SendRequest}; +use crate::kinode::process::chat::{ChatMessage, Request as ChatRequest, Response as ChatResponse, SendRequest}; use crate::kinode::process::tester::{Request as TesterRequest, Response as TesterResponse, RunRequest, FailResponse}; use kinode_process_lib::{await_message, call_init, print_to_terminal, println, Address, ProcessId, Request, Response}; @@ -7,7 +7,7 @@ mod tester_lib; wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-test-{publisher_dotted_kebab}-v0", + world: "chat-test-template-dot-os-v0", generate_unused_types: true, additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); @@ -29,7 +29,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { input_node_names: node_names, .. }) = message.body().try_into()?; - print_to_terminal(0, "{package_name}_test: a"); + print_to_terminal(0, "chat_test: a"); assert!(node_names.len() >= 2); if our.node != node_names[0] { // we are not master node: return @@ -44,15 +44,15 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { let our_chat_address = Address { node: our.node.clone(), - process: ProcessId::new(Some("{package_name}"), "{package_name}", "{publisher}"), + process: ProcessId::new(Some("chat"), "chat", "template.os"), }; let their_chat_address = Address { node: node_names[1].clone(), - process: ProcessId::new(Some("{package_name}"), "{package_name}", "{publisher}"), + process: ProcessId::new(Some("chat"), "chat", "template.os"), }; // Send - print_to_terminal(0, "{package_name}_test: b"); + print_to_terminal(0, "chat_test: b"); let message: String = "hello".into(); let _ = Request::new() .target(our_chat_address.clone()) @@ -63,14 +63,14 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { .send_and_await_response(15)?.unwrap(); // Get history from receiver & test - print_to_terminal(0, "{package_name}_test: c"); + print_to_terminal(0, "chat_test: c"); let response = Request::new() .target(their_chat_address.clone()) .body(ChatRequest::History(our.node.clone())) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("{package_name}_test"); }; + if response.is_request() { fail!("chat_test"); }; let ChatResponse::History(messages) = response.body().try_into()? else { - fail!("{package_name}_test"); + fail!("chat_test"); }; let expected_messages = vec![ChatMessage { author: our.node.clone(), @@ -79,7 +79,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { if messages != expected_messages { println!("{messages:?} != {expected_messages:?}"); - fail!("{package_name}_test"); + fail!("chat_test"); } Response::new() @@ -98,9 +98,9 @@ fn init(our: Address) { match handle_message(&our) { Ok(()) => {}, Err(e) => { - print_to_terminal(0, format!("{package_name}_test: error: {e:?}").as_str()); + print_to_terminal(0, format!("chat_test: error: {e:?}").as_str()); - fail!("{package_name}_test"); + fail!("chat_test"); }, }; } diff --git a/src/new/templates/test/chat/{package_name}_test/{package_name}_test/src/tester_lib.rs b/src/new/templates/test/chat/chat_test/chat_test/src/tester_lib.rs similarity index 100% rename from src/new/templates/test/chat/{package_name}_test/{package_name}_test/src/tester_lib.rs rename to src/new/templates/test/chat/chat_test/chat_test/src/tester_lib.rs diff --git a/src/new/templates/test/chat/{package_name}_test/metadata.json b/src/new/templates/test/chat/chat_test/metadata.json similarity index 59% rename from src/new/templates/test/chat/{package_name}_test/metadata.json rename to src/new/templates/test/chat/chat_test/metadata.json index 41269fed..8161d7d6 100644 --- a/src/new/templates/test/chat/{package_name}_test/metadata.json +++ b/src/new/templates/test/chat/chat_test/metadata.json @@ -1,18 +1,18 @@ { - "name": "{package_name} Test", - "description": "A test for {package_name}.", + "name": "chat Test", + "description": "A test for chat.", "image": "", "properties": { - "package_name": "{package_name}_test", + "package_name": "chat_test", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" }, "wit_version": 0, "dependencies": [ - "{package_name}:{publisher}", + "chat:template.os", "tester:sys" ] }, diff --git a/src/new/templates/test/chat/chat_test/pkg/manifest.json b/src/new/templates/test/chat/chat_test/pkg/manifest.json new file mode 100644 index 00000000..b6c7f2ab --- /dev/null +++ b/src/new/templates/test/chat/chat_test/pkg/manifest.json @@ -0,0 +1,15 @@ +[ + { + "process_name": "chat_test", + "process_wasm_path": "/chat_test.wasm", + "on_exit": "Restart", + "request_networking": false, + "request_capabilities": [ + "chat:chat:template.os" + ], + "grant_capabilities": [ + "chat:chat:template.os" + ], + "public": true + } +] diff --git a/src/new/templates/test/chat/tests.toml b/src/new/templates/test/chat/tests.toml index c706fc49..36aa5241 100644 --- a/src/new/templates/test/chat/tests.toml +++ b/src/new/templates/test/chat/tests.toml @@ -10,7 +10,7 @@ setup_packages = [ { path = "..", run = true } ] setup_scripts = [] -test_package_paths = ["{package_name}_test"] +test_package_paths = ["chat_test"] test_scripts = [] timeout_secs = 5 fakechain_router = 8545 diff --git a/src/new/templates/test/chat/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit b/src/new/templates/test/chat/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit deleted file mode 100644 index 79c71980..00000000 --- a/src/new/templates/test/chat/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit +++ /dev/null @@ -1,5 +0,0 @@ -world {package_name_kebab}-test-{publisher_dotted_kebab}-v0 { - import {package_name_kebab}; - import tester; - include process-v0; -} diff --git a/src/new/templates/test/chat/{package_name}_test/pkg/manifest.json b/src/new/templates/test/chat/{package_name}_test/pkg/manifest.json deleted file mode 100644 index d3a222a9..00000000 --- a/src/new/templates/test/chat/{package_name}_test/pkg/manifest.json +++ /dev/null @@ -1,15 +0,0 @@ -[ - { - "process_name": "{package_name}_test", - "process_wasm_path": "/{package_name}_test.wasm", - "on_exit": "Restart", - "request_networking": false, - "request_capabilities": [ - "{package_name}:{package_name}:{publisher}" - ], - "grant_capabilities": [ - "{package_name}:{package_name}:{publisher}" - ], - "public": true - } -] diff --git a/src/new/templates/test/echo/echo_test/Cargo.toml b/src/new/templates/test/echo/echo_test/Cargo.toml new file mode 100644 index 00000000..08be60d0 --- /dev/null +++ b/src/new/templates/test/echo/echo_test/Cargo.toml @@ -0,0 +1,10 @@ +[workspace] +resolver = "2" +members = [ + "echo_test", +] + +[profile.release] +panic = "abort" +opt-level = "s" +lto = true diff --git a/src/new/templates/test/echo/echo_test/api/echo_test:template.os-v0.wit b/src/new/templates/test/echo/echo_test/api/echo_test:template.os-v0.wit new file mode 100644 index 00000000..c4b22457 --- /dev/null +++ b/src/new/templates/test/echo/echo_test/api/echo_test:template.os-v0.wit @@ -0,0 +1,4 @@ +world echo-test-template-dot-os-v0 { + import tester; + include process-v0; +} diff --git a/src/new/templates/test/echo/{package_name}_test/{package_name}_test/Cargo.toml_ b/src/new/templates/test/echo/echo_test/echo_test/Cargo.toml similarity index 94% rename from src/new/templates/test/echo/{package_name}_test/{package_name}_test/Cargo.toml_ rename to src/new/templates/test/echo/echo_test/echo_test/Cargo.toml index c8717be6..bae839cc 100644 --- a/src/new/templates/test/echo/{package_name}_test/{package_name}_test/Cargo.toml_ +++ b/src/new/templates/test/echo/echo_test/echo_test/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "{package_name}_test" +name = "echo_test" version = "0.1.0" edition = "2021" diff --git a/src/new/templates/test/echo/{package_name}_test/{package_name}_test/src/lib.rs b/src/new/templates/test/echo/echo_test/echo_test/src/lib.rs similarity index 78% rename from src/new/templates/test/echo/{package_name}_test/{package_name}_test/src/lib.rs rename to src/new/templates/test/echo/echo_test/echo_test/src/lib.rs index bdd36456..e1362078 100644 --- a/src/new/templates/test/echo/{package_name}_test/{package_name}_test/src/lib.rs +++ b/src/new/templates/test/echo/echo_test/echo_test/src/lib.rs @@ -10,7 +10,7 @@ mod tester_lib; wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-test-{publisher_dotted_kebab}-v0", + world: "echo-test-template-dot-os-v0", generate_unused_types: true, additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); @@ -32,26 +32,26 @@ fn handle_message(our: &Address) -> anyhow::Result<()> { input_node_names: node_names, .. }) = message.body().try_into()?; - print_to_terminal(0, "{package_name}_test: a"); + print_to_terminal(0, "echo_test: a"); assert!(node_names.len() == 1); let our_echo_address = Address { node: our.node.clone(), - process: ProcessId::new(Some("{package_name}"), "{package_name}", "{publisher}"), + process: ProcessId::new(Some("echo"), "echo", "template.os"), }; // Send - print_to_terminal(0, "{package_name}_test: b"); + print_to_terminal(0, "echo_test: b"); let response = Request::new() .target(our_echo_address) .body(serde_json::to_vec("test")?) .send_and_await_response(15)? .unwrap(); if response.is_request() { - fail!("{package_name}_test"); + fail!("echo_test"); }; if serde_json::json!("Ack") != serde_json::from_slice::(response.body())? { - fail!("{package_name}_test"); + fail!("echo_test"); }; Response::new() @@ -70,9 +70,9 @@ fn init(our: Address) { match handle_message(&our) { Ok(()) => {} Err(e) => { - print_to_terminal(0, format!("{package_name}_test: error: {e:?}").as_str()); + print_to_terminal(0, format!("echo_test: error: {e:?}").as_str()); - fail!("{package_name}_test"); + fail!("echo_test"); } }; } diff --git a/src/new/templates/test/echo/{package_name}_test/{package_name}_test/src/tester_lib.rs b/src/new/templates/test/echo/echo_test/echo_test/src/tester_lib.rs similarity index 100% rename from src/new/templates/test/echo/{package_name}_test/{package_name}_test/src/tester_lib.rs rename to src/new/templates/test/echo/echo_test/echo_test/src/tester_lib.rs diff --git a/src/new/templates/test/echo/{package_name}_test/metadata.json b/src/new/templates/test/echo/echo_test/metadata.json similarity index 64% rename from src/new/templates/test/echo/{package_name}_test/metadata.json rename to src/new/templates/test/echo/echo_test/metadata.json index 52706c6d..11c67227 100644 --- a/src/new/templates/test/echo/{package_name}_test/metadata.json +++ b/src/new/templates/test/echo/echo_test/metadata.json @@ -1,11 +1,11 @@ { - "name": "{package_name} Test", - "description": "A test for {package_name}.", + "name": "echo Test", + "description": "A test for echo.", "image": "", "properties": { - "package_name": "{package_name}_test", + "package_name": "echo_test", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" diff --git a/src/new/templates/test/echo/echo_test/pkg/manifest.json b/src/new/templates/test/echo/echo_test/pkg/manifest.json new file mode 100644 index 00000000..5448a0b4 --- /dev/null +++ b/src/new/templates/test/echo/echo_test/pkg/manifest.json @@ -0,0 +1,15 @@ +[ + { + "process_name": "echo_test", + "process_wasm_path": "/echo_test.wasm", + "on_exit": "Restart", + "request_networking": false, + "request_capabilities": [ + "echo:echo:template.os" + ], + "grant_capabilities": [ + "echo:echo:template.os" + ], + "public": true + } +] diff --git a/src/new/templates/test/echo/tests.toml b/src/new/templates/test/echo/tests.toml index 55423eab..f7b06e8f 100644 --- a/src/new/templates/test/echo/tests.toml +++ b/src/new/templates/test/echo/tests.toml @@ -10,7 +10,7 @@ setup_packages = [ { path = "..", run = true } ] setup_scripts = [] -test_package_paths = ["{package_name}_test"] +test_package_paths = ["echo_test"] test_scripts = [] timeout_secs = 5 fakechain_router = 8545 diff --git a/src/new/templates/test/echo/{package_name}_test/Cargo.toml_ b/src/new/templates/test/echo/{package_name}_test/Cargo.toml_ deleted file mode 100644 index 6c797c34..00000000 --- a/src/new/templates/test/echo/{package_name}_test/Cargo.toml_ +++ /dev/null @@ -1,10 +0,0 @@ -[workspace] -resolver = "2" -members = [ - "{package_name}_test", -] - -[profile.release] -panic = "abort" -opt-level = "s" -lto = true diff --git a/src/new/templates/test/echo/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit b/src/new/templates/test/echo/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit deleted file mode 100644 index 34ab50b7..00000000 --- a/src/new/templates/test/echo/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit +++ /dev/null @@ -1,4 +0,0 @@ -world {package_name_kebab}-test-{publisher_dotted_kebab}-v0 { - import tester; - include process-v0; -} diff --git a/src/new/templates/test/echo/{package_name}_test/pkg/manifest.json b/src/new/templates/test/echo/{package_name}_test/pkg/manifest.json deleted file mode 100644 index d3a222a9..00000000 --- a/src/new/templates/test/echo/{package_name}_test/pkg/manifest.json +++ /dev/null @@ -1,15 +0,0 @@ -[ - { - "process_name": "{package_name}_test", - "process_wasm_path": "/{package_name}_test.wasm", - "on_exit": "Restart", - "request_networking": false, - "request_capabilities": [ - "{package_name}:{package_name}:{publisher}" - ], - "grant_capabilities": [ - "{package_name}:{package_name}:{publisher}" - ], - "public": true - } -] diff --git a/src/new/templates/test/fibonacci/fibonacci_test/Cargo.toml b/src/new/templates/test/fibonacci/fibonacci_test/Cargo.toml new file mode 100644 index 00000000..08be60d0 --- /dev/null +++ b/src/new/templates/test/fibonacci/fibonacci_test/Cargo.toml @@ -0,0 +1,10 @@ +[workspace] +resolver = "2" +members = [ + "echo_test", +] + +[profile.release] +panic = "abort" +opt-level = "s" +lto = true diff --git a/src/new/templates/test/fibonacci/fibonacci_test/api/fibonacci_test:template.os-v0.wit b/src/new/templates/test/fibonacci/fibonacci_test/api/fibonacci_test:template.os-v0.wit new file mode 100644 index 00000000..5eb0b3a7 --- /dev/null +++ b/src/new/templates/test/fibonacci/fibonacci_test/api/fibonacci_test:template.os-v0.wit @@ -0,0 +1,5 @@ +world echo-test-template-dot-os-v0 { + import echo; + import tester; + include process-v0; +} diff --git a/src/new/templates/test/fibonacci/{package_name}_test/{package_name}_test/Cargo.toml_ b/src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/Cargo.toml similarity index 94% rename from src/new/templates/test/fibonacci/{package_name}_test/{package_name}_test/Cargo.toml_ rename to src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/Cargo.toml index c8717be6..bae839cc 100644 --- a/src/new/templates/test/fibonacci/{package_name}_test/{package_name}_test/Cargo.toml_ +++ b/src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "{package_name}_test" +name = "echo_test" version = "0.1.0" edition = "2021" diff --git a/src/new/templates/test/fibonacci/{package_name}_test/{package_name}_test/src/lib.rs b/src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/src/lib.rs similarity index 78% rename from src/new/templates/test/fibonacci/{package_name}_test/{package_name}_test/src/lib.rs rename to src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/src/lib.rs index 7e33be91..c022a247 100644 --- a/src/new/templates/test/fibonacci/{package_name}_test/{package_name}_test/src/lib.rs +++ b/src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/src/lib.rs @@ -1,4 +1,4 @@ -use crate::kinode::process::{package_name}::{Request as FibRequest, Response as FibResponse}; +use crate::kinode::process::echo::{Request as FibRequest, Response as FibResponse}; use crate::kinode::process::tester::{Request as TesterRequest, Response as TesterResponse, RunRequest, FailResponse}; use kinode_process_lib::{await_message, call_init, print_to_terminal, Address, ProcessId, Request, Response}; @@ -7,7 +7,7 @@ mod tester_lib; wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-test-{publisher_dotted_kebab}-v0", + world: "echo-test-template-dot-os-v0", generate_unused_types: true, additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); @@ -17,9 +17,9 @@ fn test_number(n: u32, address: &Address) -> anyhow::Result { .target(address) .body(FibRequest::Number(n)) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("{package_name}_test"); }; + if response.is_request() { fail!("echo_test"); }; let FibResponse::Number(fib_number) = response.body().try_into()? else { - fail!("{package_name}_test"); + fail!("echo_test"); }; Ok(fib_number) } @@ -29,9 +29,9 @@ fn test_numbers(n: u32, n_trials: u32, address: &Address) -> anyhow::Result .target(address) .body(FibRequest::Numbers((n, n_trials))) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("{package_name}_test"); }; + if response.is_request() { fail!("echo_test"); }; let FibResponse::Numbers((fib_number, _)) = response.body().try_into()? else { - fail!("{package_name}_test"); + fail!("echo_test"); }; Ok(fib_number) } @@ -53,12 +53,12 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { input_node_names: node_names, .. }) = message.body().try_into()?; - print_to_terminal(0, "{package_name}_test: a"); + print_to_terminal(0, "echo_test: a"); assert!(node_names.len() == 1); let our_fib_address = Address { node: our.node.clone(), - process: ProcessId::new(Some("{package_name}"), "{package_name}", "{publisher}"), + process: ProcessId::new(Some("echo"), "echo", "template.os"), }; let numbers = vec![0, 1, 2, 5, 10, 20, 30, 47]; @@ -66,7 +66,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { for (number, expected) in numbers.iter().zip(expecteds.iter()) { let result = test_number(number.clone(), &our_fib_address)?; if &result != expected { - fail!("{package_name}_test"); + fail!("echo_test"); } } @@ -75,7 +75,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { for (number, expected) in numbers.iter().zip(expecteds.iter()) { let result = test_numbers(number.clone(), 5, &our_fib_address)?; if &result != expected { - fail!("{package_name}_test"); + fail!("echo_test"); } } @@ -95,9 +95,9 @@ fn init(our: Address) { match handle_message(&our) { Ok(()) => {}, Err(e) => { - print_to_terminal(0, format!("{package_name}_test: error: {e:?}").as_str()); + print_to_terminal(0, format!("echo_test: error: {e:?}").as_str()); - fail!("{package_name}_test"); + fail!("echo_test"); }, }; } diff --git a/src/new/templates/test/fibonacci/{package_name}_test/{package_name}_test/src/tester_lib.rs b/src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/src/tester_lib.rs similarity index 100% rename from src/new/templates/test/fibonacci/{package_name}_test/{package_name}_test/src/tester_lib.rs rename to src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/src/tester_lib.rs diff --git a/src/new/templates/test/fibonacci/{package_name}_test/metadata.json b/src/new/templates/test/fibonacci/fibonacci_test/metadata.json similarity index 59% rename from src/new/templates/test/fibonacci/{package_name}_test/metadata.json rename to src/new/templates/test/fibonacci/fibonacci_test/metadata.json index 41269fed..4ea09898 100644 --- a/src/new/templates/test/fibonacci/{package_name}_test/metadata.json +++ b/src/new/templates/test/fibonacci/fibonacci_test/metadata.json @@ -1,18 +1,18 @@ { - "name": "{package_name} Test", - "description": "A test for {package_name}.", + "name": "echo Test", + "description": "A test for echo.", "image": "", "properties": { - "package_name": "{package_name}_test", + "package_name": "echo_test", "current_version": "0.1.0", - "publisher": "{publisher}", + "publisher": "template.os", "mirrors": [], "code_hashes": { "0.1.0": "" }, "wit_version": 0, "dependencies": [ - "{package_name}:{publisher}", + "echo:template.os", "tester:sys" ] }, diff --git a/src/new/templates/test/fibonacci/fibonacci_test/pkg/manifest.json b/src/new/templates/test/fibonacci/fibonacci_test/pkg/manifest.json new file mode 100644 index 00000000..5448a0b4 --- /dev/null +++ b/src/new/templates/test/fibonacci/fibonacci_test/pkg/manifest.json @@ -0,0 +1,15 @@ +[ + { + "process_name": "echo_test", + "process_wasm_path": "/echo_test.wasm", + "on_exit": "Restart", + "request_networking": false, + "request_capabilities": [ + "echo:echo:template.os" + ], + "grant_capabilities": [ + "echo:echo:template.os" + ], + "public": true + } +] diff --git a/src/new/templates/test/fibonacci/tests.toml b/src/new/templates/test/fibonacci/tests.toml index 29ba4576..b77cede8 100644 --- a/src/new/templates/test/fibonacci/tests.toml +++ b/src/new/templates/test/fibonacci/tests.toml @@ -10,7 +10,7 @@ setup_packages = [ { path = "..", run = true } ] setup_scripts = [] -test_package_paths = ["{package_name}_test"] +test_package_paths = ["echo_test"] test_scripts = [] timeout_secs = 5 fakechain_router = 8545 diff --git a/src/new/templates/test/fibonacci/{package_name}_test/Cargo.toml_ b/src/new/templates/test/fibonacci/{package_name}_test/Cargo.toml_ deleted file mode 100644 index 6c797c34..00000000 --- a/src/new/templates/test/fibonacci/{package_name}_test/Cargo.toml_ +++ /dev/null @@ -1,10 +0,0 @@ -[workspace] -resolver = "2" -members = [ - "{package_name}_test", -] - -[profile.release] -panic = "abort" -opt-level = "s" -lto = true diff --git a/src/new/templates/test/fibonacci/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit b/src/new/templates/test/fibonacci/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit deleted file mode 100644 index 79c71980..00000000 --- a/src/new/templates/test/fibonacci/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit +++ /dev/null @@ -1,5 +0,0 @@ -world {package_name_kebab}-test-{publisher_dotted_kebab}-v0 { - import {package_name_kebab}; - import tester; - include process-v0; -} diff --git a/src/new/templates/test/fibonacci/{package_name}_test/pkg/manifest.json b/src/new/templates/test/fibonacci/{package_name}_test/pkg/manifest.json deleted file mode 100644 index d3a222a9..00000000 --- a/src/new/templates/test/fibonacci/{package_name}_test/pkg/manifest.json +++ /dev/null @@ -1,15 +0,0 @@ -[ - { - "process_name": "{package_name}_test", - "process_wasm_path": "/{package_name}_test.wasm", - "on_exit": "Restart", - "request_networking": false, - "request_capabilities": [ - "{package_name}:{package_name}:{publisher}" - ], - "grant_capabilities": [ - "{package_name}:{package_name}:{publisher}" - ], - "public": true - } -] diff --git a/src/new/templates/test/file_transfer/file_transfer_test/Cargo.toml b/src/new/templates/test/file_transfer/file_transfer_test/Cargo.toml new file mode 100644 index 00000000..b2063929 --- /dev/null +++ b/src/new/templates/test/file_transfer/file_transfer_test/Cargo.toml @@ -0,0 +1,10 @@ +[workspace] +resolver = "2" +members = [ + "file_transfer_test", +] + +[profile.release] +panic = "abort" +opt-level = "s" +lto = true diff --git a/src/new/templates/test/file_transfer/file_transfer_test/api/file_transfer_test:template.os-v0.wit b/src/new/templates/test/file_transfer/file_transfer_test/api/file_transfer_test:template.os-v0.wit new file mode 100644 index 00000000..99b62ce1 --- /dev/null +++ b/src/new/templates/test/file_transfer/file_transfer_test/api/file_transfer_test:template.os-v0.wit @@ -0,0 +1,5 @@ +world file-transfer-test-template-dot-os-v0 { + import file-transfer; + import tester; + include process-v0; +} diff --git a/src/new/templates/test/file_transfer/{package_name}_test/{package_name}_test/Cargo.toml_ b/src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/Cargo.toml similarity index 94% rename from src/new/templates/test/file_transfer/{package_name}_test/{package_name}_test/Cargo.toml_ rename to src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/Cargo.toml index c8717be6..65b5f70f 100644 --- a/src/new/templates/test/file_transfer/{package_name}_test/{package_name}_test/Cargo.toml_ +++ b/src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "{package_name}_test" +name = "file_transfer_test" version = "0.1.0" edition = "2021" diff --git a/src/new/templates/test/file_transfer/{package_name}_test/{package_name}_test/src/lib.rs b/src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/src/lib.rs similarity index 75% rename from src/new/templates/test/file_transfer/{package_name}_test/{package_name}_test/src/lib.rs rename to src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/src/lib.rs index c8672e78..a8f8c302 100644 --- a/src/new/templates/test/file_transfer/{package_name}_test/{package_name}_test/src/lib.rs +++ b/src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/src/lib.rs @@ -1,5 +1,5 @@ use crate::kinode::process::standard::{ProcessId as WitProcessId}; -use crate::kinode::process::{package_name}::{Address as WitAddress, Request as TransferRequest, Response as TransferResponse, WorkerRequest, DownloadRequest, ProgressRequest, FileInfo, InitializeRequest}; +use crate::kinode::process::file_transfer::{Address as WitAddress, Request as TransferRequest, Response as TransferResponse, WorkerRequest, DownloadRequest, ProgressRequest, FileInfo, InitializeRequest}; use crate::kinode::process::tester::{Request as TesterRequest, Response as TesterResponse, RunRequest, FailResponse}; use kinode_process_lib::{await_message, call_init, print_to_terminal, println, Address, ProcessId, Request, Response}; @@ -8,7 +8,7 @@ mod tester_lib; wit_bindgen::generate!({ path: "target/wit", - world: "{package_name_kebab}-test-{publisher_dotted_kebab}-v0", + world: "file-transfer-test-template-dot-os-v0", generate_unused_types: true, additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); @@ -18,9 +18,9 @@ fn test_list_files(address: &Address) -> anyhow::Result> { .target(address) .body(TransferRequest::ListFiles) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("{package_name}_test"); }; + if response.is_request() { fail!("file_transfer_test"); }; let TransferResponse::ListFiles(files) = response.body().try_into()? else { - fail!("{package_name}_test"); + fail!("file_transfer_test"); }; Ok(files) } @@ -33,9 +33,9 @@ fn test_download(name: String, our: &Address, address: &Address) -> anyhow::Resu target: address, })) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("{package_name}_test"); }; + if response.is_request() { fail!("file_transfer_test"); }; let TransferResponse::Download = response.body().try_into()? else { - fail!("{package_name}_test"); + fail!("file_transfer_test"); }; Ok(()) } @@ -57,7 +57,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { input_node_names: node_names, .. }) = message.body().try_into()?; - print_to_terminal(0, "{package_name}_test: a"); + print_to_terminal(0, "file_transfer_test: a"); assert!(node_names.len() >= 2); if our.node != node_names[0] { // we are not master node: return @@ -72,15 +72,15 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { let our_ft_address = Address { node: our.node.clone(), - process: ProcessId::new(Some("{package_name}"), "{package_name}", "{publisher}"), + process: ProcessId::new(Some("file_transfer"), "file_transfer", "template.os"), }; let their_ft_address = Address { node: node_names[1].clone(), - process: ProcessId::new(Some("{package_name}"), "{package_name}", "{publisher}"), + process: ProcessId::new(Some("file_transfer"), "file_transfer", "template.os"), }; // Send - print_to_terminal(0, "{package_name}_test: b"); + print_to_terminal(0, "file_transfer_test: b"); let message: String = "hello".into(); let _ = Request::new() .target(our_ft_address.clone()) @@ -91,14 +91,14 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { .send_and_await_response(15)?.unwrap(); // Get history from receiver & test - print_to_terminal(0, "{package_name}_test: c"); + print_to_terminal(0, "file_transfer_test: c"); let response = Request::new() .target(their_ft_address.clone()) .body(ChatRequest::History(our.node.clone())) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("{package_name}_test"); }; + if response.is_request() { fail!("file_transfer_test"); }; let ChatResponse::History(messages) = response.body().try_into()? else { - fail!("{package_name}_test"); + fail!("file_transfer_test"); }; let expected_messages = vec![ChatMessage { author: our.node.clone(), @@ -107,7 +107,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { if messages != expected_messages { println!("{messages:?} != {expected_messages:?}"); - fail!("{package_name}_test"); + fail!("file_transfer_test"); } Response::new() @@ -126,9 +126,9 @@ fn init(our: Address) { match handle_message(&our) { Ok(()) => {}, Err(e) => { - print_to_terminal(0, format!("{package_name}_test: error: {e:?}").as_str()); + print_to_terminal(0, format!("file_transfer_test: error: {e:?}").as_str()); - fail!("{package_name}_test"); + fail!("file_transfer_test"); }, }; } diff --git a/src/new/templates/test/file_transfer/{package_name}_test/{package_name}_test/src/tester_lib.rs b/src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/src/tester_lib.rs similarity index 100% rename from src/new/templates/test/file_transfer/{package_name}_test/{package_name}_test/src/tester_lib.rs rename to src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/src/tester_lib.rs diff --git a/src/new/templates/test/file_transfer/file_transfer_test/metadata.json b/src/new/templates/test/file_transfer/file_transfer_test/metadata.json new file mode 100644 index 00000000..79571af1 --- /dev/null +++ b/src/new/templates/test/file_transfer/file_transfer_test/metadata.json @@ -0,0 +1,21 @@ +{ + "name": "file_transfer Test", + "description": "A test for file_transfer.", + "image": "", + "properties": { + "package_name": "file_transfer_test", + "current_version": "0.1.0", + "publisher": "template.os", + "mirrors": [], + "code_hashes": { + "0.1.0": "" + }, + "wit_version": 0, + "dependencies": [ + "file_transfer:template.os", + "tester:sys" + ] + }, + "external_url": "", + "animation_url": "" +} diff --git a/src/new/templates/test/file_transfer/file_transfer_test/pkg/manifest.json b/src/new/templates/test/file_transfer/file_transfer_test/pkg/manifest.json new file mode 100644 index 00000000..7b732b23 --- /dev/null +++ b/src/new/templates/test/file_transfer/file_transfer_test/pkg/manifest.json @@ -0,0 +1,15 @@ +[ + { + "process_name": "file_transfer_test", + "process_wasm_path": "/file_transfer_test.wasm", + "on_exit": "Restart", + "request_networking": false, + "request_capabilities": [ + "file_transfer:file_transfer:template.os" + ], + "grant_capabilities": [ + "file_transfer:file_transfer:template.os" + ], + "public": true + } +] diff --git a/src/new/templates/test/file_transfer/tests.toml b/src/new/templates/test/file_transfer/tests.toml index 5b1ee6d6..3343f18b 100644 --- a/src/new/templates/test/file_transfer/tests.toml +++ b/src/new/templates/test/file_transfer/tests.toml @@ -9,7 +9,7 @@ setup_packages = [ { path = "..", run = true } ] setup_scripts = [] -test_package_paths = ["{package_name}_test"] +test_package_paths = ["file_transfer_test"] test_scripts = [] timeout_secs = 5 fakechain_router = 8545 diff --git a/src/new/templates/test/file_transfer/{package_name}_test/Cargo.toml_ b/src/new/templates/test/file_transfer/{package_name}_test/Cargo.toml_ deleted file mode 100644 index 6c797c34..00000000 --- a/src/new/templates/test/file_transfer/{package_name}_test/Cargo.toml_ +++ /dev/null @@ -1,10 +0,0 @@ -[workspace] -resolver = "2" -members = [ - "{package_name}_test", -] - -[profile.release] -panic = "abort" -opt-level = "s" -lto = true diff --git a/src/new/templates/test/file_transfer/{package_name}_test/api/tester:sys-v0.wit b/src/new/templates/test/file_transfer/{package_name}_test/api/tester:sys-v0.wit deleted file mode 100644 index 7fe0574b..00000000 --- a/src/new/templates/test/file_transfer/{package_name}_test/api/tester:sys-v0.wit +++ /dev/null @@ -1,27 +0,0 @@ -interface tester { - variant request { - run(run-request), - } - - variant response { - run(result<_, fail-response>) - } - - record run-request { - input-node-names: list, - test-names: list, - test-timeout: u64, - } - - record fail-response { - test: string, - file: string, - line: u32, - column: u32, - } -} - -world tester-sys-v0 { - import tester; - include process-v0; -} diff --git a/src/new/templates/test/file_transfer/{package_name}_test/api/{package_name}:{publisher}-v0.wit b/src/new/templates/test/file_transfer/{package_name}_test/api/{package_name}:{publisher}-v0.wit deleted file mode 100644 index 3ae9a97c..00000000 --- a/src/new/templates/test/file_transfer/{package_name}_test/api/{package_name}:{publisher}-v0.wit +++ /dev/null @@ -1,53 +0,0 @@ -interface {package_name_kebab} { - use standard.{address}; - - variant request { - list-files, - download(download-request), - progress(progress-request), - } - - variant response { - list-files(list), - download, - done, - started, - } - - variant worker-request { - initialize(initialize-request), - chunk(chunk-request), - size(u64), - } - - record download-request { - name: string, - target: address, - } - - record progress-request { - name: string, - progress: u64, - } - - record file-info { - name: string, - size: u64, - } - - record initialize-request { - name: string, - target-worker: option
, - } - - record chunk-request { - name: string, - offset: u64, - length: u64, - } -} - -world {package_name_kebab}-{publisher_dotted_kebab}-v0 { - import {package_name_kebab}; - include process-v0; -} diff --git a/src/new/templates/test/file_transfer/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit b/src/new/templates/test/file_transfer/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit deleted file mode 100644 index 79c71980..00000000 --- a/src/new/templates/test/file_transfer/{package_name}_test/api/{package_name}_test:{publisher}-v0.wit +++ /dev/null @@ -1,5 +0,0 @@ -world {package_name_kebab}-test-{publisher_dotted_kebab}-v0 { - import {package_name_kebab}; - import tester; - include process-v0; -} diff --git a/src/new/templates/test/file_transfer/{package_name}_test/metadata.json b/src/new/templates/test/file_transfer/{package_name}_test/metadata.json deleted file mode 100644 index cea44761..00000000 --- a/src/new/templates/test/file_transfer/{package_name}_test/metadata.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "{package_name} Test", - "description": "A test for {package_name}.", - "image": "", - "properties": { - "package_name": "{package_name}_test", - "current_version": "0.1.0", - "publisher": "{publisher}", - "mirrors": [], - "code_hashes": { - "0.1.0": "" - }, - "wit_version": 0 - }, - "external_url": "", - "animation_url": "" -} diff --git a/src/new/templates/test/file_transfer/{package_name}_test/pkg/manifest.json b/src/new/templates/test/file_transfer/{package_name}_test/pkg/manifest.json deleted file mode 100644 index d3a222a9..00000000 --- a/src/new/templates/test/file_transfer/{package_name}_test/pkg/manifest.json +++ /dev/null @@ -1,15 +0,0 @@ -[ - { - "process_name": "{package_name}_test", - "process_wasm_path": "/{package_name}_test.wasm", - "on_exit": "Restart", - "request_networking": false, - "request_capabilities": [ - "{package_name}:{package_name}:{publisher}" - ], - "grant_capabilities": [ - "{package_name}:{package_name}:{publisher}" - ], - "public": true - } -] From 662fd00fb84a874c48e33a924088b6d825993936 Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Wed, 14 Aug 2024 19:21:37 -0700 Subject: [PATCH 02/13] remove a commented-out line --- build.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/build.rs b/build.rs index 7d77c6d0..ffe83584 100644 --- a/build.rs +++ b/build.rs @@ -22,7 +22,6 @@ fn visit_dirs(dir: &Path, output_buffer: &mut Vec) -> io::Result<()> { let path_str = relative_path.to_str().unwrap().replace("\\", "/"); let relative_path_from_includes = Path::new("..").join(path); - //let relative_path_from_includes = path.strip_prefix(NEW_DIR).unwrap(); let path_str_from_includes = relative_path_from_includes .to_str() .unwrap() From ec2399cde24b9e7581251a163f5d23ca6bc25403 Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Wed, 14 Aug 2024 19:25:32 -0700 Subject: [PATCH 03/13] remove a Cargo.lock --- .../javascript/no-ui/chat/send/Cargo.lock | 2083 ----------------- 1 file changed, 2083 deletions(-) delete mode 100644 src/new/templates/javascript/no-ui/chat/send/Cargo.lock diff --git a/src/new/templates/javascript/no-ui/chat/send/Cargo.lock b/src/new/templates/javascript/no-ui/chat/send/Cargo.lock deleted file mode 100644 index d9190e77..00000000 --- a/src/new/templates/javascript/no-ui/chat/send/Cargo.lock +++ /dev/null @@ -1,2083 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "addr2line" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "alloy-json-rpc" -version = "0.1.0" -source = "git+https://github.com/alloy-rs/alloy.git?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08" -dependencies = [ - "alloy-primitives", - "serde", - "serde_json", - "thiserror", -] - -[[package]] -name = "alloy-primitives" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "600d34d8de81e23b6d909c094e23b3d357e01ca36b78a8c5424c501eedbe86f0" -dependencies = [ - "alloy-rlp", - "bytes", - "cfg-if", - "const-hex", - "derive_more", - "hex-literal", - "itoa", - "k256", - "keccak-asm", - "proptest", - "rand", - "ruint", - "serde", - "tiny-keccak", -] - -[[package]] -name = "alloy-rlp" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26154390b1d205a4a7ac7352aa2eb4f81f391399d4e2f546fb81a2f8bb383f62" -dependencies = [ - "alloy-rlp-derive", - "arrayvec", - "bytes", -] - -[[package]] -name = "alloy-rlp-derive" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d0f2d905ebd295e7effec65e5f6868d153936130ae718352771de3e7d03c75c" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.74", -] - -[[package]] -name = "alloy-rpc-types" -version = "0.1.0" -source = "git+https://github.com/alloy-rs/alloy.git?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08" -dependencies = [ - "alloy-primitives", - "alloy-rlp", - "itertools 0.12.1", - "serde", - "serde_json", - "thiserror", -] - -[[package]] -name = "alloy-transport" -version = "0.1.0" -source = "git+https://github.com/alloy-rs/alloy.git?rev=6f8ebb4#6f8ebb45afca1a201a11d421ec46db0f7a1d8d08" -dependencies = [ - "alloy-json-rpc", - "base64", - "futures-util", - "serde", - "serde_json", - "thiserror", - "tokio", - "tower", - "url", - "wasm-bindgen-futures", -] - -[[package]] -name = "anyhow" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" - -[[package]] -name = "ark-ff" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b3235cc41ee7a12aaaf2c575a2ad7b46713a8a50bda2fc3b003a04845c05dd6" -dependencies = [ - "ark-ff-asm 0.3.0", - "ark-ff-macros 0.3.0", - "ark-serialize 0.3.0", - "ark-std 0.3.0", - "derivative", - "num-bigint", - "num-traits", - "paste", - "rustc_version 0.3.3", - "zeroize", -] - -[[package]] -name = "ark-ff" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec847af850f44ad29048935519032c33da8aa03340876d351dfab5660d2966ba" -dependencies = [ - "ark-ff-asm 0.4.2", - "ark-ff-macros 0.4.2", - "ark-serialize 0.4.2", - "ark-std 0.4.0", - "derivative", - "digest 0.10.7", - "itertools 0.10.5", - "num-bigint", - "num-traits", - "paste", - "rustc_version 0.4.0", - "zeroize", -] - -[[package]] -name = "ark-ff-asm" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db02d390bf6643fb404d3d22d31aee1c4bc4459600aef9113833d17e786c6e44" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ark-ff-asm" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ed4aa4fe255d0bc6d79373f7e31d2ea147bcf486cba1be5ba7ea85abdb92348" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ark-ff-macros" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db2fd794a08ccb318058009eefdf15bcaaaaf6f8161eb3345f907222bac38b20" -dependencies = [ - "num-bigint", - "num-traits", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ark-ff-macros" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" -dependencies = [ - "num-bigint", - "num-traits", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ark-serialize" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d6c2b318ee6e10f8c2853e73a83adc0ccb88995aa978d8a3408d492ab2ee671" -dependencies = [ - "ark-std 0.3.0", - "digest 0.9.0", -] - -[[package]] -name = "ark-serialize" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adb7b85a02b83d2f22f89bd5cac66c9c89474240cb6207cb1efc16d098e822a5" -dependencies = [ - "ark-std 0.4.0", - "digest 0.10.7", - "num-bigint", -] - -[[package]] -name = "ark-std" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1df2c09229cbc5a028b1d70e00fdb2acee28b1055dfb5ca73eea49c5a25c4e7c" -dependencies = [ - "num-traits", - "rand", -] - -[[package]] -name = "ark-std" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185" -dependencies = [ - "num-traits", - "rand", -] - -[[package]] -name = "arrayvec" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" - -[[package]] -name = "auto_impl" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c87f3f15e7794432337fc718554eaa4dc8f04c9677a950ffe366f20a162ae42" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.74", -] - -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - -[[package]] -name = "backtrace" -version = "0.3.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - -[[package]] -name = "base16ct" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c7f02d4ea65f2c1853089ffd8d2787bdbc63de2f0d29dedbcf8ccdfa0ccd4cf" - -[[package]] -name = "base64" -version = "0.21.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" - -[[package]] -name = "base64ct" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" - -[[package]] -name = "bincode" -version = "1.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1f45e9417d87227c7a56d22e471c6206462cba514c7590c09aff4cf6d1ddcad" -dependencies = [ - "serde", -] - -[[package]] -name = "bit-set" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0700ddab506f33b20a03b13996eccd309a48e5ff77d0d95926aa0210fb4e95f1" -dependencies = [ - "bit-vec", -] - -[[package]] -name = "bit-vec" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "349f9b6a179ed607305526ca489b34ad0a41aed5f7980fa90eb03160b69598fb" - -[[package]] -name = "bitflags" -version = "2.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" - -[[package]] -name = "bitvec" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bc2832c24239b0141d5674bb9174f9d68a8b5b3f2753311927c172ca46f7e9c" -dependencies = [ - "funty", - "radium", - "tap", - "wyz", -] - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "bumpalo" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" - -[[package]] -name = "byte-slice-cast" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3ac9f8b63eca6fd385229b3675f6cc0dc5c8a5c8a54a59d4f52ffd670d87b0c" - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8318a53db07bb3f8dca91a600466bdb3f2eaadeedfdbcf02e1accbad9271ba50" -dependencies = [ - "serde", -] - -[[package]] -name = "cc" -version = "1.1.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5fb8dd288a69fc53a1996d7ecfbf4a20d59065bff137ce7e56bbd620de191189" -dependencies = [ - "shlex", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "const-hex" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8a24a26d37e1ffd45343323dc9fe6654ceea44c12f2fcb3d7ac29e610bc6" -dependencies = [ - "cfg-if", - "cpufeatures", - "hex", - "proptest", - "serde", -] - -[[package]] -name = "const-oid" -version = "0.9.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "cpufeatures" -version = "0.2.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" -dependencies = [ - "libc", -] - -[[package]] -name = "crunchy" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" - -[[package]] -name = "crypto-bigint" -version = "0.5.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0dc92fb57ca44df6db8059111ab3af99a63d5d0f8375d9972e319a379c6bab76" -dependencies = [ - "generic-array", - "rand_core", - "subtle", - "zeroize", -] - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "der" -version = "0.7.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f55bf8e7b65898637379c1b74eb1551107c8294ed26d855ceb9fd1a09cfc9bc0" -dependencies = [ - "const-oid", - "zeroize", -] - -[[package]] -name = "derivative" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "derive_more" -version = "0.99.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f33878137e4dafd7fa914ad4e259e18a4e8e532b9617a2d0150262bf53abfce" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version 0.4.0", - "syn 2.0.74", -] - -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer", - "const-oid", - "crypto-common", - "subtle", -] - -[[package]] -name = "ecdsa" -version = "0.16.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee27f32b5c5292967d2d4a9d7f1e0b0aed2c15daded5a60300e4abb9d8020bca" -dependencies = [ - "der", - "digest 0.10.7", - "elliptic-curve", - "rfc6979", - "signature", - "spki", -] - -[[package]] -name = "either" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" - -[[package]] -name = "elliptic-curve" -version = "0.13.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6043086bf7973472e0c7dff2142ea0b680d30e18d9cc40f267efbf222bd47" -dependencies = [ - "base16ct", - "crypto-bigint", - "digest 0.10.7", - "ff", - "generic-array", - "group", - "pkcs8", - "rand_core", - "sec1", - "subtle", - "zeroize", -] - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "fastrand" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" - -[[package]] -name = "fastrlp" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "139834ddba373bbdd213dffe02c8d110508dcf1726c2be27e8d1f7d7e1856418" -dependencies = [ - "arrayvec", - "auto_impl", - "bytes", -] - -[[package]] -name = "ff" -version = "0.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ded41244b729663b1e574f1b4fb731469f69f79c17667b5d776b16cda0479449" -dependencies = [ - "rand_core", - "subtle", -] - -[[package]] -name = "fixed-hash" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "835c052cb0c08c1acf6ffd71c022172e18723949c8282f2b9f27efbc51e64534" -dependencies = [ - "byteorder", - "rand", - "rustc-hex", - "static_assertions", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "form_urlencoded" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "funty" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" - -[[package]] -name = "futures-core" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" - -[[package]] -name = "futures-macro" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.74", -] - -[[package]] -name = "futures-task" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" - -[[package]] -name = "futures-util" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" -dependencies = [ - "futures-core", - "futures-macro", - "futures-task", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", - "zeroize", -] - -[[package]] -name = "getrandom" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" -dependencies = [ - "cfg-if", - "libc", - "wasi", -] - -[[package]] -name = "gimli" -version = "0.29.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" - -[[package]] -name = "group" -version = "0.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" -dependencies = [ - "ff", - "rand_core", - "subtle", -] - -[[package]] -name = "hashbrown" -version = "0.14.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" - -[[package]] -name = "heck" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" -dependencies = [ - "serde", -] - -[[package]] -name = "hex-literal" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" - -[[package]] -name = "hmac" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "http" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - -[[package]] -name = "id-arena" -version = "2.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25a2bc672d1148e28034f176e01fffebb08b35768468cc954630da77a1449005" - -[[package]] -name = "idna" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "impl-codec" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba6a270039626615617f3f36d15fc827041df3b78c439da2cadfa47455a77f2f" -dependencies = [ - "parity-scale-codec", -] - -[[package]] -name = "impl-trait-for-tuples" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11d7a9f6330b71fea57921c9b61c47ee6e84f72d394754eff6163ae67e7395eb" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "indexmap" -version = "2.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93ead53efc7ea8ed3cfb0c79fc8023fbb782a5432b52830b6518941cebe6505c" -dependencies = [ - "equivalent", - "hashbrown", - "serde", -] - -[[package]] -name = "itertools" -version = "0.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" -dependencies = [ - "either", -] - -[[package]] -name = "itertools" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" -dependencies = [ - "either", -] - -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - -[[package]] -name = "js-sys" -version = "0.3.70" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1868808506b929d7b0cfa8f75951347aa71bb21144b7791bae35d9bccfcfe37a" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "k256" -version = "0.13.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "956ff9b67e26e1a6a866cb758f12c6f8746208489e3e4a4b5580802f2f0a587b" -dependencies = [ - "cfg-if", - "ecdsa", - "elliptic-curve", - "once_cell", - "sha2", - "signature", -] - -[[package]] -name = "keccak-asm" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "422fbc7ff2f2f5bdffeb07718e5a5324dca72b0c9293d50df4026652385e3314" -dependencies = [ - "digest 0.10.7", - "sha3-asm", -] - -[[package]] -name = "kinode_process_lib" -version = "0.6.0" -source = "git+https://github.com/kinode-dao/process_lib?rev=84b3d84#84b3d84c7c31185f15691a288f1b45dbffb18fe2" -dependencies = [ - "alloy-json-rpc", - "alloy-primitives", - "alloy-rpc-types", - "alloy-transport", - "anyhow", - "bincode", - "http", - "mime_guess", - "rand", - "serde", - "serde_json", - "thiserror", - "url", - "wit-bindgen", -] - -[[package]] -name = "lazy_static" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" - -[[package]] -name = "leb128" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "884e2677b40cc8c339eaefcb701c32ef1fd2493d71118dc0ca4b6a736c93bd67" - -[[package]] -name = "libc" -version = "0.2.155" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" - -[[package]] -name = "libm" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" - -[[package]] -name = "linux-raw-sys" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" - -[[package]] -name = "log" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" - -[[package]] -name = "memchr" -version = "2.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "mime_guess" -version = "2.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7c44f8e672c00fe5308fa235f821cb4198414e1c77935c1ab6948d3fd78550e" -dependencies = [ - "mime", - "unicase", -] - -[[package]] -name = "miniz_oxide" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" -dependencies = [ - "adler", -] - -[[package]] -name = "num-bigint" -version = "0.4.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" -dependencies = [ - "num-integer", - "num-traits", -] - -[[package]] -name = "num-integer" -version = "0.1.46" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" -dependencies = [ - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", - "libm", -] - -[[package]] -name = "object" -version = "0.36.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "27b64972346851a39438c60b341ebc01bba47464ae329e55cf343eb93964efd9" -dependencies = [ - "memchr", -] - -[[package]] -name = "once_cell" -version = "1.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" - -[[package]] -name = "parity-scale-codec" -version = "3.6.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "306800abfa29c7f16596b5970a588435e3d5b3149683d00c12b699cc19f895ee" -dependencies = [ - "arrayvec", - "bitvec", - "byte-slice-cast", - "impl-trait-for-tuples", - "parity-scale-codec-derive", - "serde", -] - -[[package]] -name = "parity-scale-codec-derive" -version = "3.6.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d830939c76d294956402033aee57a6da7b438f2294eb94864c37b0569053a42c" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "paste" -version = "1.0.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" - -[[package]] -name = "percent-encoding" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" - -[[package]] -name = "pest" -version = "2.7.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd53dff83f26735fdc1ca837098ccf133605d794cdae66acfc2bfac3ec809d95" -dependencies = [ - "memchr", - "thiserror", - "ucd-trie", -] - -[[package]] -name = "pin-project" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" -dependencies = [ - "pin-project-internal", -] - -[[package]] -name = "pin-project-internal" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.74", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkcs8" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" -dependencies = [ - "der", - "spki", -] - -[[package]] -name = "ppv-lite86" -version = "0.2.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04" -dependencies = [ - "zerocopy", -] - -[[package]] -name = "primitive-types" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b34d9fd68ae0b74a41b21c03c2f62847aa0ffea044eee893b4c140b37e244e2" -dependencies = [ - "fixed-hash", - "impl-codec", - "uint", -] - -[[package]] -name = "proc-macro-crate" -version = "3.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d37c51ca738a55da99dc0c4a34860fd675453b8b36209178c2249bb13651284" -dependencies = [ - "toml_edit", -] - -[[package]] -name = "proc-macro2" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "proptest" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4c2511913b88df1637da85cc8d96ec8e43a3f8bb8ccb71ee1ac240d6f3df58d" -dependencies = [ - "bit-set", - "bit-vec", - "bitflags", - "lazy_static", - "num-traits", - "rand", - "rand_chacha", - "rand_xorshift", - "regex-syntax", - "rusty-fork", - "tempfile", - "unarray", -] - -[[package]] -name = "quick-error" -version = "1.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" - -[[package]] -name = "quote" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "radium" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha", - "rand_core", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom", -] - -[[package]] -name = "rand_xorshift" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" -dependencies = [ - "rand_core", -] - -[[package]] -name = "regex-syntax" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" - -[[package]] -name = "rfc6979" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" -dependencies = [ - "hmac", - "subtle", -] - -[[package]] -name = "rlp" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb919243f34364b6bd2fc10ef797edbfa75f33c252e7998527479c6d6b47e1ec" -dependencies = [ - "bytes", - "rustc-hex", -] - -[[package]] -name = "ruint" -version = "1.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c3cc4c2511671f327125da14133d0c5c5d137f006a1017a16f557bc85b16286" -dependencies = [ - "alloy-rlp", - "ark-ff 0.3.0", - "ark-ff 0.4.2", - "bytes", - "fastrlp", - "num-bigint", - "num-traits", - "parity-scale-codec", - "primitive-types", - "proptest", - "rand", - "rlp", - "ruint-macro", - "serde", - "valuable", - "zeroize", -] - -[[package]] -name = "ruint-macro" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48fd7bd8a6377e15ad9d42a8ec25371b94ddc67abe7c8b9127bec79bebaaae18" - -[[package]] -name = "rustc-demangle" -version = "0.1.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" - -[[package]] -name = "rustc-hex" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6" - -[[package]] -name = "rustc_version" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0dfe2087c51c460008730de8b57e6a320782fbfb312e1f4d520e6c6fae155ee" -dependencies = [ - "semver 0.11.0", -] - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver 1.0.23", -] - -[[package]] -name = "rustix" -version = "0.38.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" -dependencies = [ - "bitflags", - "errno", - "libc", - "linux-raw-sys", - "windows-sys 0.52.0", -] - -[[package]] -name = "rusty-fork" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb3dcc6e454c328bb824492db107ab7c0ae8fcffe4ad210136ef014458c1bc4f" -dependencies = [ - "fnv", - "quick-error", - "tempfile", - "wait-timeout", -] - -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - -[[package]] -name = "sec1" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3e97a565f76233a6003f9f5c54be1d9c5bdfa3eccfb189469f11ec4901c47dc" -dependencies = [ - "base16ct", - "der", - "generic-array", - "pkcs8", - "subtle", - "zeroize", -] - -[[package]] -name = "semver" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f301af10236f6df4160f7c3f04eec6dbc70ace82d23326abad5edee88801c6b6" -dependencies = [ - "semver-parser", -] - -[[package]] -name = "semver" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" - -[[package]] -name = "semver-parser" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0bef5b7f9e0df16536d3961cfb6e84331c065b4066afb39768d0e319411f7" -dependencies = [ - "pest", -] - -[[package]] -name = "send" -version = "0.1.0" -dependencies = [ - "anyhow", - "kinode_process_lib", - "serde", - "serde_json", - "wit-bindgen", -] - -[[package]] -name = "serde" -version = "1.0.207" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5665e14a49a4ea1b91029ba7d3bca9f299e1f7cfa194388ccc20f14743e784f2" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.207" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6aea2634c86b0e8ef2cfdc0c340baede54ec27b1e46febd7f80dffb2aa44a00e" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.74", -] - -[[package]] -name = "serde_json" -version = "1.0.124" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66ad62847a56b3dba58cc891acd13884b9c61138d330c0d7b6181713d4fce38d" -dependencies = [ - "itoa", - "memchr", - "ryu", - "serde", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha3-asm" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57d79b758b7cb2085612b11a235055e485605a5103faccdd633f35bd7aee69dd" -dependencies = [ - "cc", - "cfg-if", -] - -[[package]] -name = "shlex" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" - -[[package]] -name = "signature" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de" -dependencies = [ - "digest 0.10.7", - "rand_core", -] - -[[package]] -name = "slab" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" - -[[package]] -name = "spdx" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47317bbaf63785b53861e1ae2d11b80d6b624211d42cb20efcd210ee6f8a14bc" -dependencies = [ - "smallvec", -] - -[[package]] -name = "spki" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d91ed6c858b01f942cd56b37a94b3e0a1798290327d1236e4d9cf4eaca44d29d" -dependencies = [ - "base64ct", - "der", -] - -[[package]] -name = "static_assertions" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" - -[[package]] -name = "subtle" -version = "2.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" - -[[package]] -name = "syn" -version = "1.0.109" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "2.0.74" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fceb41e3d546d0bd83421d3409b1460cc7444cd389341a4c880fe7a042cb3d7" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "tap" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" - -[[package]] -name = "tempfile" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04cbcdd0c794ebb0d4cf35e88edd2f7d2c4c3e9a5a6dab322839b321c6a87a64" -dependencies = [ - "cfg-if", - "fastrand", - "once_cell", - "rustix", - "windows-sys 0.59.0", -] - -[[package]] -name = "thiserror" -version = "1.0.63" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0342370b38b6a11b6cc11d6a805569958d54cfa061a29969c3b5ce2ea405724" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.63" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4558b58466b9ad7ca0f102865eccc95938dca1a74a856f2b57b6629050da261" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.74", -] - -[[package]] -name = "tiny-keccak" -version = "2.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237" -dependencies = [ - "crunchy", -] - -[[package]] -name = "tinyvec" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "445e881f4f6d382d5f27c034e25eb92edd7c784ceab92a0937db7f2e9471b938" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.39.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "daa4fb1bc778bd6f04cbfc4bb2d06a7396a8f299dc33ea1900cedaa316f467b1" -dependencies = [ - "backtrace", - "pin-project-lite", -] - -[[package]] -name = "toml_datetime" -version = "0.6.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0dd7358ecb8fc2f8d014bf86f6f638ce72ba252a2c3a2572f2a795f1d23efb41" - -[[package]] -name = "toml_edit" -version = "0.21.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a8534fd7f78b5405e860340ad6575217ce99f38d4d5c8f2442cb5ecb50090e1" -dependencies = [ - "indexmap", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower" -version = "0.4.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" -dependencies = [ - "futures-core", - "futures-util", - "pin-project", - "pin-project-lite", - "tower-layer", - "tower-service", - "tracing", -] - -[[package]] -name = "tower-layer" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" - -[[package]] -name = "tower-service" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" - -[[package]] -name = "tracing" -version = "0.1.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" -dependencies = [ - "log", - "pin-project-lite", - "tracing-core", -] - -[[package]] -name = "tracing-core" -version = "0.1.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" -dependencies = [ - "once_cell", -] - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "ucd-trie" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed646292ffc8188ef8ea4d1e0e0150fb15a5c2e12ad9b8fc191ae7a8a7f3c4b9" - -[[package]] -name = "uint" -version = "0.9.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76f64bba2c53b04fcab63c01a7d7427eadc821e3bc48c34dc9ba29c501164b52" -dependencies = [ - "byteorder", - "crunchy", - "hex", - "static_assertions", -] - -[[package]] -name = "unarray" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" - -[[package]] -name = "unicase" -version = "2.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7d2d4dafb69621809a81864c9c1b864479e1235c0dd4e199924b9742439ed89" -dependencies = [ - "version_check", -] - -[[package]] -name = "unicode-bidi" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "unicode-normalization" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a56d1686db2308d901306f92a263857ef59ea39678a5458e7cb17f01415101f5" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" - -[[package]] -name = "unicode-xid" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" - -[[package]] -name = "url" -version = "2.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", -] - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[package]] -name = "version_check" -version = "0.9.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" - -[[package]] -name = "wait-timeout" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f200f5b12eb75f8c1ed65abd4b2db8a6e1b138a20de009dacee265a2498f3f6" -dependencies = [ - "libc", -] - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.93" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a82edfc16a6c469f5f44dc7b571814045d60404b55a0ee849f9bcfa2e63dd9b5" -dependencies = [ - "cfg-if", - "once_cell", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.93" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9de396da306523044d3302746f1208fa71d7532227f15e347e2d93e4145dd77b" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn 2.0.74", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.43" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61e9300f63a621e96ed275155c108eb6f843b6a26d053f122ab69724559dc8ed" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.93" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "585c4c91a46b072c92e908d99cb1dcdf95c5218eeb6f3bf1efa991ee7a68cccf" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.93" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "afc340c74d9005395cf9dd098506f7f44e38f2b4a21c6aaacf9a105ea5e1e836" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.74", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.93" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c62a0a307cb4a311d3a07867860911ca130c3494e8c2719593806c08bc5d0484" - -[[package]] -name = "wasm-encoder" -version = "0.202.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfd106365a7f5f7aa3c1916a98cbb3ad477f5ff96ddb130285a91c6e7429e67a" -dependencies = [ - "leb128", -] - -[[package]] -name = "wasm-metadata" -version = "0.202.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "094aea3cb90e09f16ee25a4c0e324b3e8c934e7fd838bfa039aef5352f44a917" -dependencies = [ - "anyhow", - "indexmap", - "serde", - "serde_derive", - "serde_json", - "spdx", - "wasm-encoder", - "wasmparser", -] - -[[package]] -name = "wasmparser" -version = "0.202.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6998515d3cf3f8b980ef7c11b29a9b1017d4cf86b99ae93b546992df9931413" -dependencies = [ - "bitflags", - "indexmap", - "semver 1.0.23", -] - -[[package]] -name = "web-sys" -version = "0.3.70" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26fdeaafd9bd129f65e7c031593c24d62186301e0c72c8978fa1678be7d532c0" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "windows-sys" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" -dependencies = [ - "windows-targets", -] - -[[package]] -name = "windows-sys" -version = "0.59.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" -dependencies = [ - "windows-targets", -] - -[[package]] -name = "windows-targets" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" -dependencies = [ - "windows_aarch64_gnullvm", - "windows_aarch64_msvc", - "windows_i686_gnu", - "windows_i686_gnullvm", - "windows_i686_msvc", - "windows_x86_64_gnu", - "windows_x86_64_gnullvm", - "windows_x86_64_msvc", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" - -[[package]] -name = "windows_i686_gnu" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" - -[[package]] -name = "windows_i686_gnullvm" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" - -[[package]] -name = "windows_i686_msvc" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" - -[[package]] -name = "winnow" -version = "0.5.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" -dependencies = [ - "memchr", -] - -[[package]] -name = "wit-bindgen" -version = "0.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fb4e7653763780be47e38f479e9aa83c768aa6a3b2ed086dc2826fdbbb7e7f5" -dependencies = [ - "wit-bindgen-rt", - "wit-bindgen-rust-macro", -] - -[[package]] -name = "wit-bindgen-core" -version = "0.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b67e11c950041849a10828c7600ea62a4077c01e8af72e8593253575428f91b" -dependencies = [ - "anyhow", - "wit-parser", -] - -[[package]] -name = "wit-bindgen-rt" -version = "0.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b0780cf7046630ed70f689a098cd8d56c5c3b22f2a7379bbdb088879963ff96" -dependencies = [ - "bitflags", -] - -[[package]] -name = "wit-bindgen-rust" -version = "0.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30acbe8fb708c3a830a33c4cb705df82659bf831b492ec6ca1a17a369cfeeafb" -dependencies = [ - "anyhow", - "heck", - "indexmap", - "wasm-metadata", - "wit-bindgen-core", - "wit-component", -] - -[[package]] -name = "wit-bindgen-rust-macro" -version = "0.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b1b06eae85feaecdf9f2854f7cac124e00d5a6e5014bfb02eb1ecdeb5f265b9" -dependencies = [ - "anyhow", - "proc-macro2", - "quote", - "syn 2.0.74", - "wit-bindgen-core", - "wit-bindgen-rust", -] - -[[package]] -name = "wit-component" -version = "0.202.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c836b1fd9932de0431c1758d8be08212071b6bba0151f7bac826dbc4312a2a9" -dependencies = [ - "anyhow", - "bitflags", - "indexmap", - "log", - "serde", - "serde_derive", - "serde_json", - "wasm-encoder", - "wasm-metadata", - "wasmparser", - "wit-parser", -] - -[[package]] -name = "wit-parser" -version = "0.202.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "744237b488352f4f27bca05a10acb79474415951c450e52ebd0da784c1df2bcc" -dependencies = [ - "anyhow", - "id-arena", - "indexmap", - "log", - "semver 1.0.23", - "serde", - "serde_derive", - "serde_json", - "unicode-xid", - "wasmparser", -] - -[[package]] -name = "wyz" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05f360fc0b24296329c78fda852a1e9ae82de9cf7b27dae4b7f62f118f77b9ed" -dependencies = [ - "tap", -] - -[[package]] -name = "zerocopy" -version = "0.7.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" -dependencies = [ - "byteorder", - "zerocopy-derive", -] - -[[package]] -name = "zerocopy-derive" -version = "0.7.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.74", -] - -[[package]] -name = "zeroize" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.74", -] From 2b4c78dfcefd5dbb09d2c7097d904095b36941da Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Thu, 15 Aug 2024 19:40:30 -0700 Subject: [PATCH 04/13] new: move tests into appropriate templates --- .gitignore | 5 +- build.rs | 58 ++++++---- src/new/mod.rs | 5 +- .../no-ui/chat/test}/chat_test/Cargo.toml | 0 .../api/chat_test:template.os-v0.wit | 0 .../chat/test}/chat_test/chat_test/Cargo.toml | 0 .../chat/test}/chat_test/chat_test/src/lib.rs | 0 .../chat_test/chat_test/src/tester_lib.rs | 0 .../no-ui/chat/test}/chat_test/metadata.json | 0 .../chat/test}/chat_test/pkg/manifest.json | 0 .../no-ui/chat/test}/tests.toml | 0 .../no-ui/echo/test}/echo_test/Cargo.toml | 0 .../api/echo_test:template.os-v0.wit | 0 .../echo/test}/echo_test/echo_test/Cargo.toml | 0 .../echo/test}/echo_test/echo_test/src/lib.rs | 0 .../echo_test/echo_test/src/tester_lib.rs | 0 .../no-ui/echo/test}/echo_test/metadata.json | 0 .../echo/test}/echo_test/pkg/manifest.json | 0 .../no-ui/echo/test}/tests.toml | 0 .../fibonacci/test}/fibonacci_test/Cargo.toml | 0 .../api/fibonacci_test:template.os-v0.wit | 0 .../fibonacci_test/fibonacci_test/Cargo.toml | 0 .../fibonacci_test/fibonacci_test/src/lib.rs | 0 .../fibonacci_test/src/tester_lib.rs | 0 .../test}/fibonacci_test/metadata.json | 0 .../test}/fibonacci_test/pkg/manifest.json | 0 .../no-ui/fibonacci/test}/tests.toml | 0 .../no-ui/chat/test/chat_test/Cargo.toml | 10 ++ .../api/chat_test:template.os-v0.wit | 5 + .../chat/test/chat_test/chat_test/Cargo.toml | 21 ++++ .../chat/test/chat_test/chat_test/src/lib.rs | 107 ++++++++++++++++++ .../chat_test/chat_test}/src/tester_lib.rs | 0 .../no-ui/chat/test/chat_test/metadata.json | 21 ++++ .../chat/test/chat_test/pkg/manifest.json | 15 +++ .../python/no-ui/chat/test/tests.toml | 28 +++++ .../no-ui/echo/test/echo_test/Cargo.toml | 10 ++ .../api/echo_test:template.os-v0.wit | 4 + .../echo/test/echo_test/echo_test/Cargo.toml | 21 ++++ .../echo/test/echo_test/echo_test/src/lib.rs | 79 +++++++++++++ .../echo_test/echo_test/src/tester_lib.rs | 30 +++++ .../no-ui/echo/test/echo_test/metadata.json | 20 ++++ .../echo/test/echo_test/pkg/manifest.json | 15 +++ .../python/no-ui/echo/test/tests.toml | 22 ++++ .../fibonacci/test/fibonacci_test/Cargo.toml | 10 ++ .../api/fibonacci_test:template.os-v0.wit | 5 + .../fibonacci_test/fibonacci_test/Cargo.toml | 21 ++++ .../fibonacci_test/fibonacci_test/src/lib.rs | 104 +++++++++++++++++ .../fibonacci_test/src/tester_lib.rs | 30 +++++ .../test/fibonacci_test/metadata.json | 21 ++++ .../test/fibonacci_test/pkg/manifest.json | 15 +++ .../python/no-ui/fibonacci/test/tests.toml | 22 ++++ .../rust/no-ui/chat/test/chat_test/Cargo.toml | 10 ++ .../api/chat_test:template.os-v0.wit | 5 + .../chat/test/chat_test/chat_test/Cargo.toml | 21 ++++ .../chat/test/chat_test/chat_test/src/lib.rs | 107 ++++++++++++++++++ .../chat_test/chat_test/src/tester_lib.rs | 30 +++++ .../no-ui/chat/test/chat_test/metadata.json | 21 ++++ .../chat/test/chat_test/pkg/manifest.json | 15 +++ .../templates/rust/no-ui/chat/test/tests.toml | 28 +++++ .../rust/no-ui/echo/test/echo_test/Cargo.toml | 10 ++ .../api/echo_test:template.os-v0.wit | 4 + .../echo/test/echo_test/echo_test/Cargo.toml | 21 ++++ .../echo/test/echo_test/echo_test/src/lib.rs | 79 +++++++++++++ .../echo_test/echo_test/src/tester_lib.rs | 30 +++++ .../no-ui/echo/test/echo_test/metadata.json | 20 ++++ .../echo/test/echo_test/pkg/manifest.json | 15 +++ .../templates/rust/no-ui/echo/test/tests.toml | 22 ++++ .../fibonacci/test/fibonacci_test/Cargo.toml | 10 ++ .../api/fibonacci_test:template.os-v0.wit | 5 + .../fibonacci_test/fibonacci_test/Cargo.toml | 21 ++++ .../fibonacci_test/fibonacci_test/src/lib.rs | 104 +++++++++++++++++ .../fibonacci_test/src/tester_lib.rs | 30 +++++ .../test/fibonacci_test/metadata.json | 21 ++++ .../test/fibonacci_test/pkg/manifest.json | 15 +++ .../rust/no-ui/fibonacci/test/tests.toml | 22 ++++ .../test}/file_transfer_test/Cargo.toml | 0 .../api/file_transfer_test:template.os-v0.wit | 0 .../file_transfer_test/Cargo.toml | 0 .../file_transfer_test/src/lib.rs | 0 .../file_transfer_test/src/tester_lib.rs | 30 +++++ .../test}/file_transfer_test/metadata.json | 0 .../file_transfer_test/pkg/manifest.json | 0 .../no-ui/file_transfer/test}/tests.toml | 0 83 files changed, 1372 insertions(+), 28 deletions(-) rename src/new/templates/{test/chat => javascript/no-ui/chat/test}/chat_test/Cargo.toml (100%) rename src/new/templates/{test/chat => javascript/no-ui/chat/test}/chat_test/api/chat_test:template.os-v0.wit (100%) rename src/new/templates/{test/chat => javascript/no-ui/chat/test}/chat_test/chat_test/Cargo.toml (100%) rename src/new/templates/{test/chat => javascript/no-ui/chat/test}/chat_test/chat_test/src/lib.rs (100%) rename src/new/templates/{test/chat => javascript/no-ui/chat/test}/chat_test/chat_test/src/tester_lib.rs (100%) rename src/new/templates/{test/chat => javascript/no-ui/chat/test}/chat_test/metadata.json (100%) rename src/new/templates/{test/chat => javascript/no-ui/chat/test}/chat_test/pkg/manifest.json (100%) rename src/new/templates/{test/chat => javascript/no-ui/chat/test}/tests.toml (100%) rename src/new/templates/{test/echo => javascript/no-ui/echo/test}/echo_test/Cargo.toml (100%) rename src/new/templates/{test/echo => javascript/no-ui/echo/test}/echo_test/api/echo_test:template.os-v0.wit (100%) rename src/new/templates/{test/echo => javascript/no-ui/echo/test}/echo_test/echo_test/Cargo.toml (100%) rename src/new/templates/{test/echo => javascript/no-ui/echo/test}/echo_test/echo_test/src/lib.rs (100%) rename src/new/templates/{test/echo => javascript/no-ui/echo/test}/echo_test/echo_test/src/tester_lib.rs (100%) rename src/new/templates/{test/echo => javascript/no-ui/echo/test}/echo_test/metadata.json (100%) rename src/new/templates/{test/echo => javascript/no-ui/echo/test}/echo_test/pkg/manifest.json (100%) rename src/new/templates/{test/echo => javascript/no-ui/echo/test}/tests.toml (100%) rename src/new/templates/{test/fibonacci => javascript/no-ui/fibonacci/test}/fibonacci_test/Cargo.toml (100%) rename src/new/templates/{test/fibonacci => javascript/no-ui/fibonacci/test}/fibonacci_test/api/fibonacci_test:template.os-v0.wit (100%) rename src/new/templates/{test/fibonacci => javascript/no-ui/fibonacci/test}/fibonacci_test/fibonacci_test/Cargo.toml (100%) rename src/new/templates/{test/fibonacci => javascript/no-ui/fibonacci/test}/fibonacci_test/fibonacci_test/src/lib.rs (100%) rename src/new/templates/{test/fibonacci => javascript/no-ui/fibonacci/test}/fibonacci_test/fibonacci_test/src/tester_lib.rs (100%) rename src/new/templates/{test/fibonacci => javascript/no-ui/fibonacci/test}/fibonacci_test/metadata.json (100%) rename src/new/templates/{test/fibonacci => javascript/no-ui/fibonacci/test}/fibonacci_test/pkg/manifest.json (100%) rename src/new/templates/{test/fibonacci => javascript/no-ui/fibonacci/test}/tests.toml (100%) create mode 100644 src/new/templates/python/no-ui/chat/test/chat_test/Cargo.toml create mode 100644 src/new/templates/python/no-ui/chat/test/chat_test/api/chat_test:template.os-v0.wit create mode 100644 src/new/templates/python/no-ui/chat/test/chat_test/chat_test/Cargo.toml create mode 100644 src/new/templates/python/no-ui/chat/test/chat_test/chat_test/src/lib.rs rename src/new/templates/{test/file_transfer/file_transfer_test/file_transfer_test => python/no-ui/chat/test/chat_test/chat_test}/src/tester_lib.rs (100%) create mode 100644 src/new/templates/python/no-ui/chat/test/chat_test/metadata.json create mode 100644 src/new/templates/python/no-ui/chat/test/chat_test/pkg/manifest.json create mode 100644 src/new/templates/python/no-ui/chat/test/tests.toml create mode 100644 src/new/templates/python/no-ui/echo/test/echo_test/Cargo.toml create mode 100644 src/new/templates/python/no-ui/echo/test/echo_test/api/echo_test:template.os-v0.wit create mode 100644 src/new/templates/python/no-ui/echo/test/echo_test/echo_test/Cargo.toml create mode 100644 src/new/templates/python/no-ui/echo/test/echo_test/echo_test/src/lib.rs create mode 100644 src/new/templates/python/no-ui/echo/test/echo_test/echo_test/src/tester_lib.rs create mode 100644 src/new/templates/python/no-ui/echo/test/echo_test/metadata.json create mode 100644 src/new/templates/python/no-ui/echo/test/echo_test/pkg/manifest.json create mode 100644 src/new/templates/python/no-ui/echo/test/tests.toml create mode 100644 src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/Cargo.toml create mode 100644 src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit create mode 100644 src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml create mode 100644 src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs create mode 100644 src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/tester_lib.rs create mode 100644 src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/metadata.json create mode 100644 src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json create mode 100644 src/new/templates/python/no-ui/fibonacci/test/tests.toml create mode 100644 src/new/templates/rust/no-ui/chat/test/chat_test/Cargo.toml create mode 100644 src/new/templates/rust/no-ui/chat/test/chat_test/api/chat_test:template.os-v0.wit create mode 100644 src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/Cargo.toml create mode 100644 src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/src/lib.rs create mode 100644 src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/src/tester_lib.rs create mode 100644 src/new/templates/rust/no-ui/chat/test/chat_test/metadata.json create mode 100644 src/new/templates/rust/no-ui/chat/test/chat_test/pkg/manifest.json create mode 100644 src/new/templates/rust/no-ui/chat/test/tests.toml create mode 100644 src/new/templates/rust/no-ui/echo/test/echo_test/Cargo.toml create mode 100644 src/new/templates/rust/no-ui/echo/test/echo_test/api/echo_test:template.os-v0.wit create mode 100644 src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/Cargo.toml create mode 100644 src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/src/lib.rs create mode 100644 src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/src/tester_lib.rs create mode 100644 src/new/templates/rust/no-ui/echo/test/echo_test/metadata.json create mode 100644 src/new/templates/rust/no-ui/echo/test/echo_test/pkg/manifest.json create mode 100644 src/new/templates/rust/no-ui/echo/test/tests.toml create mode 100644 src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/Cargo.toml create mode 100644 src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit create mode 100644 src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml create mode 100644 src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs create mode 100644 src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/tester_lib.rs create mode 100644 src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/metadata.json create mode 100644 src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json create mode 100644 src/new/templates/rust/no-ui/fibonacci/test/tests.toml rename src/new/templates/{test/file_transfer => rust/no-ui/file_transfer/test}/file_transfer_test/Cargo.toml (100%) rename src/new/templates/{test/file_transfer => rust/no-ui/file_transfer/test}/file_transfer_test/api/file_transfer_test:template.os-v0.wit (100%) rename src/new/templates/{test/file_transfer => rust/no-ui/file_transfer/test}/file_transfer_test/file_transfer_test/Cargo.toml (100%) rename src/new/templates/{test/file_transfer => rust/no-ui/file_transfer/test}/file_transfer_test/file_transfer_test/src/lib.rs (100%) create mode 100644 src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/src/tester_lib.rs rename src/new/templates/{test/file_transfer => rust/no-ui/file_transfer/test}/file_transfer_test/metadata.json (100%) rename src/new/templates/{test/file_transfer => rust/no-ui/file_transfer/test}/file_transfer_test/pkg/manifest.json (100%) rename src/new/templates/{test/file_transfer => rust/no-ui/file_transfer/test}/tests.toml (100%) diff --git a/.gitignore b/.gitignore index f8b6c2db..b2c30b0a 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,7 @@ -/target +**/target *.swp my_package/ src/new/includes.rs +src/new/templates/**/Cargo.lock +src/new/templates/**/*.wasm +src/new/templates/**/*.zip diff --git a/build.rs b/build.rs index ffe83584..901aa27f 100644 --- a/build.rs +++ b/build.rs @@ -7,31 +7,41 @@ const TARGET_DIR: &str = "target"; const INCLUDES: &str = "includes.rs"; fn visit_dirs(dir: &Path, output_buffer: &mut Vec) -> io::Result<()> { - if dir.is_dir() { - for entry in fs::read_dir(dir)? { - let entry = entry?; - let path = entry.path(); - if path.is_dir() { - visit_dirs(&path, output_buffer)?; - } else { - if path.extension().and_then(|s| s.to_str()) == Some("swp") { - continue; - } - - let relative_path = path.strip_prefix(TEMPLATES_DIR).unwrap(); - let path_str = relative_path.to_str().unwrap().replace("\\", "/"); - - let relative_path_from_includes = Path::new("..").join(path); - let path_str_from_includes = relative_path_from_includes - .to_str() - .unwrap() - .replace("\\", "/"); - writeln!( - output_buffer, - " (\"{}\", include_str!(\"{}\")),", - path_str, path_str_from_includes, - )?; + if !dir.is_dir() { + return Ok(()); + } + for entry in fs::read_dir(dir)? { + let entry = entry?; + let path = entry.path(); + if path.is_dir() { + let dir_name = path.file_name().and_then(|s| s.to_str()); + if dir_name == Some("home") || dir_name == Some("target") { + continue; + } + visit_dirs(&path, output_buffer)?; + } else { + let ext = path.extension().and_then(|s| s.to_str()); + if ext == Some("swp") || ext == Some("wasm") || ext == Some("zip") { + continue; } + let file_name = path.file_name().and_then(|s| s.to_str()); + if file_name == Some("Cargo.lock") { + continue; + } + + let relative_path = path.strip_prefix(TEMPLATES_DIR).unwrap(); + let path_str = relative_path.to_str().unwrap().replace("\\", "/"); + + let relative_path_from_includes = Path::new("..").join(path); + let path_str_from_includes = relative_path_from_includes + .to_str() + .unwrap() + .replace("\\", "/"); + writeln!( + output_buffer, + " (\"{}\", include_str!(\"{}\")),", + path_str, path_str_from_includes, + )?; } } Ok(()) diff --git a/src/new/mod.rs b/src/new/mod.rs index 7d0f6a0c..58b8ec26 100644 --- a/src/new/mod.rs +++ b/src/new/mod.rs @@ -225,15 +225,14 @@ pub fn execute( ui_infix, template.to_string(), ); - let ui_prefix = format!("{}/{}/", ui_infix, template.to_string(),); - let test_prefix = format!("test/{}/", template.to_string(),); + let ui_prefix = format!("{}/{}/", ui_infix, template.to_string()); + let test_prefix = format!("test/{}/", template.to_string()); let mut path_to_content: HashMap = PATH_TO_CONTENT .iter() .filter_map(|(path, content)| { path.strip_prefix(&template_prefix) .map(|p| p.to_string()) .or_else(|| path.strip_prefix(&ui_prefix).map(|p| p.to_string())) - .or_else(|| path.strip_prefix(&test_prefix).map(|p| format!("test/{p}"))) .or_else(|| { if path.starts_with(&test_prefix) { Some(path.to_string()) diff --git a/src/new/templates/test/chat/chat_test/Cargo.toml b/src/new/templates/javascript/no-ui/chat/test/chat_test/Cargo.toml similarity index 100% rename from src/new/templates/test/chat/chat_test/Cargo.toml rename to src/new/templates/javascript/no-ui/chat/test/chat_test/Cargo.toml diff --git a/src/new/templates/test/chat/chat_test/api/chat_test:template.os-v0.wit b/src/new/templates/javascript/no-ui/chat/test/chat_test/api/chat_test:template.os-v0.wit similarity index 100% rename from src/new/templates/test/chat/chat_test/api/chat_test:template.os-v0.wit rename to src/new/templates/javascript/no-ui/chat/test/chat_test/api/chat_test:template.os-v0.wit diff --git a/src/new/templates/test/chat/chat_test/chat_test/Cargo.toml b/src/new/templates/javascript/no-ui/chat/test/chat_test/chat_test/Cargo.toml similarity index 100% rename from src/new/templates/test/chat/chat_test/chat_test/Cargo.toml rename to src/new/templates/javascript/no-ui/chat/test/chat_test/chat_test/Cargo.toml diff --git a/src/new/templates/test/chat/chat_test/chat_test/src/lib.rs b/src/new/templates/javascript/no-ui/chat/test/chat_test/chat_test/src/lib.rs similarity index 100% rename from src/new/templates/test/chat/chat_test/chat_test/src/lib.rs rename to src/new/templates/javascript/no-ui/chat/test/chat_test/chat_test/src/lib.rs diff --git a/src/new/templates/test/chat/chat_test/chat_test/src/tester_lib.rs b/src/new/templates/javascript/no-ui/chat/test/chat_test/chat_test/src/tester_lib.rs similarity index 100% rename from src/new/templates/test/chat/chat_test/chat_test/src/tester_lib.rs rename to src/new/templates/javascript/no-ui/chat/test/chat_test/chat_test/src/tester_lib.rs diff --git a/src/new/templates/test/chat/chat_test/metadata.json b/src/new/templates/javascript/no-ui/chat/test/chat_test/metadata.json similarity index 100% rename from src/new/templates/test/chat/chat_test/metadata.json rename to src/new/templates/javascript/no-ui/chat/test/chat_test/metadata.json diff --git a/src/new/templates/test/chat/chat_test/pkg/manifest.json b/src/new/templates/javascript/no-ui/chat/test/chat_test/pkg/manifest.json similarity index 100% rename from src/new/templates/test/chat/chat_test/pkg/manifest.json rename to src/new/templates/javascript/no-ui/chat/test/chat_test/pkg/manifest.json diff --git a/src/new/templates/test/chat/tests.toml b/src/new/templates/javascript/no-ui/chat/test/tests.toml similarity index 100% rename from src/new/templates/test/chat/tests.toml rename to src/new/templates/javascript/no-ui/chat/test/tests.toml diff --git a/src/new/templates/test/echo/echo_test/Cargo.toml b/src/new/templates/javascript/no-ui/echo/test/echo_test/Cargo.toml similarity index 100% rename from src/new/templates/test/echo/echo_test/Cargo.toml rename to src/new/templates/javascript/no-ui/echo/test/echo_test/Cargo.toml diff --git a/src/new/templates/test/echo/echo_test/api/echo_test:template.os-v0.wit b/src/new/templates/javascript/no-ui/echo/test/echo_test/api/echo_test:template.os-v0.wit similarity index 100% rename from src/new/templates/test/echo/echo_test/api/echo_test:template.os-v0.wit rename to src/new/templates/javascript/no-ui/echo/test/echo_test/api/echo_test:template.os-v0.wit diff --git a/src/new/templates/test/echo/echo_test/echo_test/Cargo.toml b/src/new/templates/javascript/no-ui/echo/test/echo_test/echo_test/Cargo.toml similarity index 100% rename from src/new/templates/test/echo/echo_test/echo_test/Cargo.toml rename to src/new/templates/javascript/no-ui/echo/test/echo_test/echo_test/Cargo.toml diff --git a/src/new/templates/test/echo/echo_test/echo_test/src/lib.rs b/src/new/templates/javascript/no-ui/echo/test/echo_test/echo_test/src/lib.rs similarity index 100% rename from src/new/templates/test/echo/echo_test/echo_test/src/lib.rs rename to src/new/templates/javascript/no-ui/echo/test/echo_test/echo_test/src/lib.rs diff --git a/src/new/templates/test/echo/echo_test/echo_test/src/tester_lib.rs b/src/new/templates/javascript/no-ui/echo/test/echo_test/echo_test/src/tester_lib.rs similarity index 100% rename from src/new/templates/test/echo/echo_test/echo_test/src/tester_lib.rs rename to src/new/templates/javascript/no-ui/echo/test/echo_test/echo_test/src/tester_lib.rs diff --git a/src/new/templates/test/echo/echo_test/metadata.json b/src/new/templates/javascript/no-ui/echo/test/echo_test/metadata.json similarity index 100% rename from src/new/templates/test/echo/echo_test/metadata.json rename to src/new/templates/javascript/no-ui/echo/test/echo_test/metadata.json diff --git a/src/new/templates/test/echo/echo_test/pkg/manifest.json b/src/new/templates/javascript/no-ui/echo/test/echo_test/pkg/manifest.json similarity index 100% rename from src/new/templates/test/echo/echo_test/pkg/manifest.json rename to src/new/templates/javascript/no-ui/echo/test/echo_test/pkg/manifest.json diff --git a/src/new/templates/test/echo/tests.toml b/src/new/templates/javascript/no-ui/echo/test/tests.toml similarity index 100% rename from src/new/templates/test/echo/tests.toml rename to src/new/templates/javascript/no-ui/echo/test/tests.toml diff --git a/src/new/templates/test/fibonacci/fibonacci_test/Cargo.toml b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/Cargo.toml similarity index 100% rename from src/new/templates/test/fibonacci/fibonacci_test/Cargo.toml rename to src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/Cargo.toml diff --git a/src/new/templates/test/fibonacci/fibonacci_test/api/fibonacci_test:template.os-v0.wit b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit similarity index 100% rename from src/new/templates/test/fibonacci/fibonacci_test/api/fibonacci_test:template.os-v0.wit rename to src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit diff --git a/src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/Cargo.toml b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml similarity index 100% rename from src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/Cargo.toml rename to src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml diff --git a/src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/src/lib.rs b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs similarity index 100% rename from src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/src/lib.rs rename to src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs diff --git a/src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/src/tester_lib.rs b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/tester_lib.rs similarity index 100% rename from src/new/templates/test/fibonacci/fibonacci_test/fibonacci_test/src/tester_lib.rs rename to src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/tester_lib.rs diff --git a/src/new/templates/test/fibonacci/fibonacci_test/metadata.json b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/metadata.json similarity index 100% rename from src/new/templates/test/fibonacci/fibonacci_test/metadata.json rename to src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/metadata.json diff --git a/src/new/templates/test/fibonacci/fibonacci_test/pkg/manifest.json b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json similarity index 100% rename from src/new/templates/test/fibonacci/fibonacci_test/pkg/manifest.json rename to src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json diff --git a/src/new/templates/test/fibonacci/tests.toml b/src/new/templates/javascript/no-ui/fibonacci/test/tests.toml similarity index 100% rename from src/new/templates/test/fibonacci/tests.toml rename to src/new/templates/javascript/no-ui/fibonacci/test/tests.toml diff --git a/src/new/templates/python/no-ui/chat/test/chat_test/Cargo.toml b/src/new/templates/python/no-ui/chat/test/chat_test/Cargo.toml new file mode 100644 index 00000000..7021d14c --- /dev/null +++ b/src/new/templates/python/no-ui/chat/test/chat_test/Cargo.toml @@ -0,0 +1,10 @@ +[workspace] +resolver = "2" +members = [ + "chat_test", +] + +[profile.release] +panic = "abort" +opt-level = "s" +lto = true diff --git a/src/new/templates/python/no-ui/chat/test/chat_test/api/chat_test:template.os-v0.wit b/src/new/templates/python/no-ui/chat/test/chat_test/api/chat_test:template.os-v0.wit new file mode 100644 index 00000000..c87f01eb --- /dev/null +++ b/src/new/templates/python/no-ui/chat/test/chat_test/api/chat_test:template.os-v0.wit @@ -0,0 +1,5 @@ +world chat-test-template-dot-os-v0 { + import chat; + import tester; + include process-v0; +} diff --git a/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/Cargo.toml b/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/Cargo.toml new file mode 100644 index 00000000..905155d1 --- /dev/null +++ b/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/Cargo.toml @@ -0,0 +1,21 @@ +[package] +name = "chat_test" +version = "0.1.0" +edition = "2021" + +[dependencies] +anyhow = "1.0" +bincode = "1.3" +kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.8.3" } +process_macros = { git = "https://github.com/kinode-dao/process_macros", rev = "626e501" } +rmp-serde = "1.1" +serde = { version = "1.0", features = ["derive"] } +serde_json = "1.0" +thiserror = "1.0" +wit-bindgen = "0.24.0" + +[lib] +crate-type = ["cdylib"] + +[package.metadata.component] +package = "kinode:process" diff --git a/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/src/lib.rs b/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/src/lib.rs new file mode 100644 index 00000000..40e55a74 --- /dev/null +++ b/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/src/lib.rs @@ -0,0 +1,107 @@ +use crate::kinode::process::chat::{ChatMessage, Request as ChatRequest, Response as ChatResponse, SendRequest}; +use crate::kinode::process::tester::{Request as TesterRequest, Response as TesterResponse, RunRequest, FailResponse}; + +use kinode_process_lib::{await_message, call_init, print_to_terminal, println, Address, ProcessId, Request, Response}; + +mod tester_lib; + +wit_bindgen::generate!({ + path: "target/wit", + world: "chat-test-template-dot-os-v0", + generate_unused_types: true, + additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], +}); + +fn handle_message (our: &Address) -> anyhow::Result<()> { + let message = await_message().unwrap(); + + if !message.is_request() { + unimplemented!(); + } + let source = message.source(); + if our.node != source.node { + return Err(anyhow::anyhow!( + "rejecting foreign Message from {:?}", + source, + )); + } + let TesterRequest::Run(RunRequest { + input_node_names: node_names, + .. + }) = message.body().try_into()?; + print_to_terminal(0, "chat_test: a"); + assert!(node_names.len() >= 2); + if our.node != node_names[0] { + // we are not master node: return + Response::new() + .body(TesterResponse::Run(Ok(()))) + .send() + .unwrap(); + return Ok(()); + } + + // we are master node + + let our_chat_address = Address { + node: our.node.clone(), + process: ProcessId::new(Some("chat"), "chat", "template.os"), + }; + let their_chat_address = Address { + node: node_names[1].clone(), + process: ProcessId::new(Some("chat"), "chat", "template.os"), + }; + + // Send + print_to_terminal(0, "chat_test: b"); + let message: String = "hello".into(); + let _ = Request::new() + .target(our_chat_address.clone()) + .body(ChatRequest::Send(SendRequest { + target: node_names[1].clone(), + message: message.clone(), + })) + .send_and_await_response(15)?.unwrap(); + + // Get history from receiver & test + print_to_terminal(0, "chat_test: c"); + let response = Request::new() + .target(their_chat_address.clone()) + .body(ChatRequest::History(our.node.clone())) + .send_and_await_response(15)?.unwrap(); + if response.is_request() { fail!("chat_test"); }; + let ChatResponse::History(messages) = response.body().try_into()? else { + fail!("chat_test"); + }; + let expected_messages = vec![ChatMessage { + author: our.node.clone(), + content: message, + }]; + + if messages != expected_messages { + println!("{messages:?} != {expected_messages:?}"); + fail!("chat_test"); + } + + Response::new() + .body(TesterResponse::Run(Ok(()))) + .send() + .unwrap(); + + Ok(()) +} + +call_init!(init); +fn init(our: Address) { + print_to_terminal(0, "begin"); + + loop { + match handle_message(&our) { + Ok(()) => {}, + Err(e) => { + print_to_terminal(0, format!("chat_test: error: {e:?}").as_str()); + + fail!("chat_test"); + }, + }; + } +} diff --git a/src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/src/tester_lib.rs b/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/src/tester_lib.rs similarity index 100% rename from src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/src/tester_lib.rs rename to src/new/templates/python/no-ui/chat/test/chat_test/chat_test/src/tester_lib.rs diff --git a/src/new/templates/python/no-ui/chat/test/chat_test/metadata.json b/src/new/templates/python/no-ui/chat/test/chat_test/metadata.json new file mode 100644 index 00000000..8161d7d6 --- /dev/null +++ b/src/new/templates/python/no-ui/chat/test/chat_test/metadata.json @@ -0,0 +1,21 @@ +{ + "name": "chat Test", + "description": "A test for chat.", + "image": "", + "properties": { + "package_name": "chat_test", + "current_version": "0.1.0", + "publisher": "template.os", + "mirrors": [], + "code_hashes": { + "0.1.0": "" + }, + "wit_version": 0, + "dependencies": [ + "chat:template.os", + "tester:sys" + ] + }, + "external_url": "", + "animation_url": "" +} diff --git a/src/new/templates/python/no-ui/chat/test/chat_test/pkg/manifest.json b/src/new/templates/python/no-ui/chat/test/chat_test/pkg/manifest.json new file mode 100644 index 00000000..b6c7f2ab --- /dev/null +++ b/src/new/templates/python/no-ui/chat/test/chat_test/pkg/manifest.json @@ -0,0 +1,15 @@ +[ + { + "process_name": "chat_test", + "process_wasm_path": "/chat_test.wasm", + "on_exit": "Restart", + "request_networking": false, + "request_capabilities": [ + "chat:chat:template.os" + ], + "grant_capabilities": [ + "chat:chat:template.os" + ], + "public": true + } +] diff --git a/src/new/templates/python/no-ui/chat/test/tests.toml b/src/new/templates/python/no-ui/chat/test/tests.toml new file mode 100644 index 00000000..36aa5241 --- /dev/null +++ b/src/new/templates/python/no-ui/chat/test/tests.toml @@ -0,0 +1,28 @@ +runtime = { FetchVersion = "latest" } +# runtime = { RepoPath = "~/git/kinode" } +persist_home = false +runtime_build_release = false + + +[[tests]] +dependency_package_paths = [".."] +setup_packages = [ + { path = "..", run = true } +] +setup_scripts = [] +test_package_paths = ["chat_test"] +test_scripts = [] +timeout_secs = 5 +fakechain_router = 8545 + +[[tests.nodes]] +port = 8080 +home = "home/first" +fake_node_name = "first.dev" +runtime_verbosity = 2 + +[[tests.nodes]] +port = 8081 +home = "home/second" +fake_node_name = "second.dev" +runtime_verbosity = 2 diff --git a/src/new/templates/python/no-ui/echo/test/echo_test/Cargo.toml b/src/new/templates/python/no-ui/echo/test/echo_test/Cargo.toml new file mode 100644 index 00000000..08be60d0 --- /dev/null +++ b/src/new/templates/python/no-ui/echo/test/echo_test/Cargo.toml @@ -0,0 +1,10 @@ +[workspace] +resolver = "2" +members = [ + "echo_test", +] + +[profile.release] +panic = "abort" +opt-level = "s" +lto = true diff --git a/src/new/templates/python/no-ui/echo/test/echo_test/api/echo_test:template.os-v0.wit b/src/new/templates/python/no-ui/echo/test/echo_test/api/echo_test:template.os-v0.wit new file mode 100644 index 00000000..c4b22457 --- /dev/null +++ b/src/new/templates/python/no-ui/echo/test/echo_test/api/echo_test:template.os-v0.wit @@ -0,0 +1,4 @@ +world echo-test-template-dot-os-v0 { + import tester; + include process-v0; +} diff --git a/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/Cargo.toml b/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/Cargo.toml new file mode 100644 index 00000000..bae839cc --- /dev/null +++ b/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/Cargo.toml @@ -0,0 +1,21 @@ +[package] +name = "echo_test" +version = "0.1.0" +edition = "2021" + +[dependencies] +anyhow = "1.0" +bincode = "1.3" +kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.8.3" } +process_macros = { git = "https://github.com/kinode-dao/process_macros", rev = "626e501" } +rmp-serde = "1.1" +serde = { version = "1.0", features = ["derive"] } +serde_json = "1.0" +thiserror = "1.0" +wit-bindgen = "0.24.0" + +[lib] +crate-type = ["cdylib"] + +[package.metadata.component] +package = "kinode:process" diff --git a/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/src/lib.rs b/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/src/lib.rs new file mode 100644 index 00000000..e1362078 --- /dev/null +++ b/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/src/lib.rs @@ -0,0 +1,79 @@ +use crate::kinode::process::tester::{ + FailResponse, Request as TesterRequest, Response as TesterResponse, RunRequest, +}; + +use kinode_process_lib::{ + await_message, call_init, print_to_terminal, Address, ProcessId, Request, Response, +}; + +mod tester_lib; + +wit_bindgen::generate!({ + path: "target/wit", + world: "echo-test-template-dot-os-v0", + generate_unused_types: true, + additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], +}); + +fn handle_message(our: &Address) -> anyhow::Result<()> { + let message = await_message().unwrap(); + + if !message.is_request() { + unimplemented!(); + } + let source = message.source(); + if our.node != source.node { + return Err(anyhow::anyhow!( + "rejecting foreign Message from {:?}", + source, + )); + } + let TesterRequest::Run(RunRequest { + input_node_names: node_names, + .. + }) = message.body().try_into()?; + print_to_terminal(0, "echo_test: a"); + assert!(node_names.len() == 1); + + let our_echo_address = Address { + node: our.node.clone(), + process: ProcessId::new(Some("echo"), "echo", "template.os"), + }; + + // Send + print_to_terminal(0, "echo_test: b"); + let response = Request::new() + .target(our_echo_address) + .body(serde_json::to_vec("test")?) + .send_and_await_response(15)? + .unwrap(); + if response.is_request() { + fail!("echo_test"); + }; + if serde_json::json!("Ack") != serde_json::from_slice::(response.body())? { + fail!("echo_test"); + }; + + Response::new() + .body(TesterResponse::Run(Ok(()))) + .send() + .unwrap(); + + Ok(()) +} + +call_init!(init); +fn init(our: Address) { + print_to_terminal(0, "begin"); + + loop { + match handle_message(&our) { + Ok(()) => {} + Err(e) => { + print_to_terminal(0, format!("echo_test: error: {e:?}").as_str()); + + fail!("echo_test"); + } + }; + } +} diff --git a/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/src/tester_lib.rs b/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/src/tester_lib.rs new file mode 100644 index 00000000..8fb7ae19 --- /dev/null +++ b/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/src/tester_lib.rs @@ -0,0 +1,30 @@ +#[allow(unused_imports)] +use crate::kinode::process::tester::{FailResponse, Response as TesterResponse}; + +#[macro_export] +macro_rules! fail { + ($test:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: file!().into(), + line: line!(), + column: column!(), + }))) + .send() + .unwrap(); + panic!("") + }; + ($test:expr, $file:expr, $line:expr, $column:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: $file.into(), + line: $line, + column: $column, + }))) + .send() + .unwrap(); + panic!("") + }; +} diff --git a/src/new/templates/python/no-ui/echo/test/echo_test/metadata.json b/src/new/templates/python/no-ui/echo/test/echo_test/metadata.json new file mode 100644 index 00000000..11c67227 --- /dev/null +++ b/src/new/templates/python/no-ui/echo/test/echo_test/metadata.json @@ -0,0 +1,20 @@ +{ + "name": "echo Test", + "description": "A test for echo.", + "image": "", + "properties": { + "package_name": "echo_test", + "current_version": "0.1.0", + "publisher": "template.os", + "mirrors": [], + "code_hashes": { + "0.1.0": "" + }, + "wit_version": 0, + "dependencies": [ + "tester:sys" + ] + }, + "external_url": "", + "animation_url": "" +} diff --git a/src/new/templates/python/no-ui/echo/test/echo_test/pkg/manifest.json b/src/new/templates/python/no-ui/echo/test/echo_test/pkg/manifest.json new file mode 100644 index 00000000..5448a0b4 --- /dev/null +++ b/src/new/templates/python/no-ui/echo/test/echo_test/pkg/manifest.json @@ -0,0 +1,15 @@ +[ + { + "process_name": "echo_test", + "process_wasm_path": "/echo_test.wasm", + "on_exit": "Restart", + "request_networking": false, + "request_capabilities": [ + "echo:echo:template.os" + ], + "grant_capabilities": [ + "echo:echo:template.os" + ], + "public": true + } +] diff --git a/src/new/templates/python/no-ui/echo/test/tests.toml b/src/new/templates/python/no-ui/echo/test/tests.toml new file mode 100644 index 00000000..f7b06e8f --- /dev/null +++ b/src/new/templates/python/no-ui/echo/test/tests.toml @@ -0,0 +1,22 @@ +runtime = { FetchVersion = "latest" } +# runtime = { RepoPath = "~/git/kinode" } +persist_home = false +runtime_build_release = false + + +[[tests]] +dependency_package_paths = [] +setup_packages = [ + { path = "..", run = true } +] +setup_scripts = [] +test_package_paths = ["echo_test"] +test_scripts = [] +timeout_secs = 5 +fakechain_router = 8545 + +[[tests.nodes]] +port = 8080 +home = "home/first" +fake_node_name = "first.dev" +runtime_verbosity = 2 diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/Cargo.toml b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/Cargo.toml new file mode 100644 index 00000000..08be60d0 --- /dev/null +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/Cargo.toml @@ -0,0 +1,10 @@ +[workspace] +resolver = "2" +members = [ + "echo_test", +] + +[profile.release] +panic = "abort" +opt-level = "s" +lto = true diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit new file mode 100644 index 00000000..5eb0b3a7 --- /dev/null +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit @@ -0,0 +1,5 @@ +world echo-test-template-dot-os-v0 { + import echo; + import tester; + include process-v0; +} diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml new file mode 100644 index 00000000..bae839cc --- /dev/null +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml @@ -0,0 +1,21 @@ +[package] +name = "echo_test" +version = "0.1.0" +edition = "2021" + +[dependencies] +anyhow = "1.0" +bincode = "1.3" +kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.8.3" } +process_macros = { git = "https://github.com/kinode-dao/process_macros", rev = "626e501" } +rmp-serde = "1.1" +serde = { version = "1.0", features = ["derive"] } +serde_json = "1.0" +thiserror = "1.0" +wit-bindgen = "0.24.0" + +[lib] +crate-type = ["cdylib"] + +[package.metadata.component] +package = "kinode:process" diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs new file mode 100644 index 00000000..c022a247 --- /dev/null +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs @@ -0,0 +1,104 @@ +use crate::kinode::process::echo::{Request as FibRequest, Response as FibResponse}; +use crate::kinode::process::tester::{Request as TesterRequest, Response as TesterResponse, RunRequest, FailResponse}; + +use kinode_process_lib::{await_message, call_init, print_to_terminal, Address, ProcessId, Request, Response}; + +mod tester_lib; + +wit_bindgen::generate!({ + path: "target/wit", + world: "echo-test-template-dot-os-v0", + generate_unused_types: true, + additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], +}); + +fn test_number(n: u32, address: &Address) -> anyhow::Result { + let response = Request::new() + .target(address) + .body(FibRequest::Number(n)) + .send_and_await_response(15)?.unwrap(); + if response.is_request() { fail!("echo_test"); }; + let FibResponse::Number(fib_number) = response.body().try_into()? else { + fail!("echo_test"); + }; + Ok(fib_number) +} + +fn test_numbers(n: u32, n_trials: u32, address: &Address) -> anyhow::Result { + let response = Request::new() + .target(address) + .body(FibRequest::Numbers((n, n_trials))) + .send_and_await_response(15)?.unwrap(); + if response.is_request() { fail!("echo_test"); }; + let FibResponse::Numbers((fib_number, _)) = response.body().try_into()? else { + fail!("echo_test"); + }; + Ok(fib_number) +} + +fn handle_message (our: &Address) -> anyhow::Result<()> { + let message = await_message().unwrap(); + + if !message.is_request() { + unimplemented!(); + } + let source = message.source(); + if our.node != source.node { + return Err(anyhow::anyhow!( + "rejecting foreign Message from {:?}", + source, + )); + } + let TesterRequest::Run(RunRequest { + input_node_names: node_names, + .. + }) = message.body().try_into()?; + print_to_terminal(0, "echo_test: a"); + assert!(node_names.len() == 1); + + let our_fib_address = Address { + node: our.node.clone(), + process: ProcessId::new(Some("echo"), "echo", "template.os"), + }; + + let numbers = vec![0, 1, 2, 5, 10, 20, 30, 47]; + let expecteds = vec![0, 1, 1, 5, 55, 6_765, 832_040, 2_971_215_073]; + for (number, expected) in numbers.iter().zip(expecteds.iter()) { + let result = test_number(number.clone(), &our_fib_address)?; + if &result != expected { + fail!("echo_test"); + } + } + + let numbers = vec![0, 1, 2, 5, 10, 20, 30, 47]; + let expecteds = vec![0, 1, 1, 5, 55, 6_765, 832_040, 2_971_215_073]; + for (number, expected) in numbers.iter().zip(expecteds.iter()) { + let result = test_numbers(number.clone(), 5, &our_fib_address)?; + if &result != expected { + fail!("echo_test"); + } + } + + Response::new() + .body(TesterResponse::Run(Ok(()))) + .send() + .unwrap(); + + Ok(()) +} + +call_init!(init); +fn init(our: Address) { + print_to_terminal(0, "begin"); + + loop { + match handle_message(&our) { + Ok(()) => {}, + Err(e) => { + print_to_terminal(0, format!("echo_test: error: {e:?}").as_str()); + + fail!("echo_test"); + }, + }; + } +} diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/tester_lib.rs b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/tester_lib.rs new file mode 100644 index 00000000..8fb7ae19 --- /dev/null +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/tester_lib.rs @@ -0,0 +1,30 @@ +#[allow(unused_imports)] +use crate::kinode::process::tester::{FailResponse, Response as TesterResponse}; + +#[macro_export] +macro_rules! fail { + ($test:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: file!().into(), + line: line!(), + column: column!(), + }))) + .send() + .unwrap(); + panic!("") + }; + ($test:expr, $file:expr, $line:expr, $column:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: $file.into(), + line: $line, + column: $column, + }))) + .send() + .unwrap(); + panic!("") + }; +} diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/metadata.json b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/metadata.json new file mode 100644 index 00000000..4ea09898 --- /dev/null +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/metadata.json @@ -0,0 +1,21 @@ +{ + "name": "echo Test", + "description": "A test for echo.", + "image": "", + "properties": { + "package_name": "echo_test", + "current_version": "0.1.0", + "publisher": "template.os", + "mirrors": [], + "code_hashes": { + "0.1.0": "" + }, + "wit_version": 0, + "dependencies": [ + "echo:template.os", + "tester:sys" + ] + }, + "external_url": "", + "animation_url": "" +} diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json new file mode 100644 index 00000000..5448a0b4 --- /dev/null +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json @@ -0,0 +1,15 @@ +[ + { + "process_name": "echo_test", + "process_wasm_path": "/echo_test.wasm", + "on_exit": "Restart", + "request_networking": false, + "request_capabilities": [ + "echo:echo:template.os" + ], + "grant_capabilities": [ + "echo:echo:template.os" + ], + "public": true + } +] diff --git a/src/new/templates/python/no-ui/fibonacci/test/tests.toml b/src/new/templates/python/no-ui/fibonacci/test/tests.toml new file mode 100644 index 00000000..b77cede8 --- /dev/null +++ b/src/new/templates/python/no-ui/fibonacci/test/tests.toml @@ -0,0 +1,22 @@ +runtime = { FetchVersion = "latest" } +# runtime = { RepoPath = "~/git/kinode" } +persist_home = false +runtime_build_release = false + + +[[tests]] +dependency_package_paths = [".."] +setup_packages = [ + { path = "..", run = true } +] +setup_scripts = [] +test_package_paths = ["echo_test"] +test_scripts = [] +timeout_secs = 5 +fakechain_router = 8545 + +[[tests.nodes]] +port = 8080 +home = "home/first" +fake_node_name = "first.dev" +runtime_verbosity = 2 diff --git a/src/new/templates/rust/no-ui/chat/test/chat_test/Cargo.toml b/src/new/templates/rust/no-ui/chat/test/chat_test/Cargo.toml new file mode 100644 index 00000000..7021d14c --- /dev/null +++ b/src/new/templates/rust/no-ui/chat/test/chat_test/Cargo.toml @@ -0,0 +1,10 @@ +[workspace] +resolver = "2" +members = [ + "chat_test", +] + +[profile.release] +panic = "abort" +opt-level = "s" +lto = true diff --git a/src/new/templates/rust/no-ui/chat/test/chat_test/api/chat_test:template.os-v0.wit b/src/new/templates/rust/no-ui/chat/test/chat_test/api/chat_test:template.os-v0.wit new file mode 100644 index 00000000..c87f01eb --- /dev/null +++ b/src/new/templates/rust/no-ui/chat/test/chat_test/api/chat_test:template.os-v0.wit @@ -0,0 +1,5 @@ +world chat-test-template-dot-os-v0 { + import chat; + import tester; + include process-v0; +} diff --git a/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/Cargo.toml b/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/Cargo.toml new file mode 100644 index 00000000..905155d1 --- /dev/null +++ b/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/Cargo.toml @@ -0,0 +1,21 @@ +[package] +name = "chat_test" +version = "0.1.0" +edition = "2021" + +[dependencies] +anyhow = "1.0" +bincode = "1.3" +kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.8.3" } +process_macros = { git = "https://github.com/kinode-dao/process_macros", rev = "626e501" } +rmp-serde = "1.1" +serde = { version = "1.0", features = ["derive"] } +serde_json = "1.0" +thiserror = "1.0" +wit-bindgen = "0.24.0" + +[lib] +crate-type = ["cdylib"] + +[package.metadata.component] +package = "kinode:process" diff --git a/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/src/lib.rs b/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/src/lib.rs new file mode 100644 index 00000000..40e55a74 --- /dev/null +++ b/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/src/lib.rs @@ -0,0 +1,107 @@ +use crate::kinode::process::chat::{ChatMessage, Request as ChatRequest, Response as ChatResponse, SendRequest}; +use crate::kinode::process::tester::{Request as TesterRequest, Response as TesterResponse, RunRequest, FailResponse}; + +use kinode_process_lib::{await_message, call_init, print_to_terminal, println, Address, ProcessId, Request, Response}; + +mod tester_lib; + +wit_bindgen::generate!({ + path: "target/wit", + world: "chat-test-template-dot-os-v0", + generate_unused_types: true, + additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], +}); + +fn handle_message (our: &Address) -> anyhow::Result<()> { + let message = await_message().unwrap(); + + if !message.is_request() { + unimplemented!(); + } + let source = message.source(); + if our.node != source.node { + return Err(anyhow::anyhow!( + "rejecting foreign Message from {:?}", + source, + )); + } + let TesterRequest::Run(RunRequest { + input_node_names: node_names, + .. + }) = message.body().try_into()?; + print_to_terminal(0, "chat_test: a"); + assert!(node_names.len() >= 2); + if our.node != node_names[0] { + // we are not master node: return + Response::new() + .body(TesterResponse::Run(Ok(()))) + .send() + .unwrap(); + return Ok(()); + } + + // we are master node + + let our_chat_address = Address { + node: our.node.clone(), + process: ProcessId::new(Some("chat"), "chat", "template.os"), + }; + let their_chat_address = Address { + node: node_names[1].clone(), + process: ProcessId::new(Some("chat"), "chat", "template.os"), + }; + + // Send + print_to_terminal(0, "chat_test: b"); + let message: String = "hello".into(); + let _ = Request::new() + .target(our_chat_address.clone()) + .body(ChatRequest::Send(SendRequest { + target: node_names[1].clone(), + message: message.clone(), + })) + .send_and_await_response(15)?.unwrap(); + + // Get history from receiver & test + print_to_terminal(0, "chat_test: c"); + let response = Request::new() + .target(their_chat_address.clone()) + .body(ChatRequest::History(our.node.clone())) + .send_and_await_response(15)?.unwrap(); + if response.is_request() { fail!("chat_test"); }; + let ChatResponse::History(messages) = response.body().try_into()? else { + fail!("chat_test"); + }; + let expected_messages = vec![ChatMessage { + author: our.node.clone(), + content: message, + }]; + + if messages != expected_messages { + println!("{messages:?} != {expected_messages:?}"); + fail!("chat_test"); + } + + Response::new() + .body(TesterResponse::Run(Ok(()))) + .send() + .unwrap(); + + Ok(()) +} + +call_init!(init); +fn init(our: Address) { + print_to_terminal(0, "begin"); + + loop { + match handle_message(&our) { + Ok(()) => {}, + Err(e) => { + print_to_terminal(0, format!("chat_test: error: {e:?}").as_str()); + + fail!("chat_test"); + }, + }; + } +} diff --git a/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/src/tester_lib.rs b/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/src/tester_lib.rs new file mode 100644 index 00000000..8fb7ae19 --- /dev/null +++ b/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/src/tester_lib.rs @@ -0,0 +1,30 @@ +#[allow(unused_imports)] +use crate::kinode::process::tester::{FailResponse, Response as TesterResponse}; + +#[macro_export] +macro_rules! fail { + ($test:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: file!().into(), + line: line!(), + column: column!(), + }))) + .send() + .unwrap(); + panic!("") + }; + ($test:expr, $file:expr, $line:expr, $column:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: $file.into(), + line: $line, + column: $column, + }))) + .send() + .unwrap(); + panic!("") + }; +} diff --git a/src/new/templates/rust/no-ui/chat/test/chat_test/metadata.json b/src/new/templates/rust/no-ui/chat/test/chat_test/metadata.json new file mode 100644 index 00000000..8161d7d6 --- /dev/null +++ b/src/new/templates/rust/no-ui/chat/test/chat_test/metadata.json @@ -0,0 +1,21 @@ +{ + "name": "chat Test", + "description": "A test for chat.", + "image": "", + "properties": { + "package_name": "chat_test", + "current_version": "0.1.0", + "publisher": "template.os", + "mirrors": [], + "code_hashes": { + "0.1.0": "" + }, + "wit_version": 0, + "dependencies": [ + "chat:template.os", + "tester:sys" + ] + }, + "external_url": "", + "animation_url": "" +} diff --git a/src/new/templates/rust/no-ui/chat/test/chat_test/pkg/manifest.json b/src/new/templates/rust/no-ui/chat/test/chat_test/pkg/manifest.json new file mode 100644 index 00000000..b6c7f2ab --- /dev/null +++ b/src/new/templates/rust/no-ui/chat/test/chat_test/pkg/manifest.json @@ -0,0 +1,15 @@ +[ + { + "process_name": "chat_test", + "process_wasm_path": "/chat_test.wasm", + "on_exit": "Restart", + "request_networking": false, + "request_capabilities": [ + "chat:chat:template.os" + ], + "grant_capabilities": [ + "chat:chat:template.os" + ], + "public": true + } +] diff --git a/src/new/templates/rust/no-ui/chat/test/tests.toml b/src/new/templates/rust/no-ui/chat/test/tests.toml new file mode 100644 index 00000000..36aa5241 --- /dev/null +++ b/src/new/templates/rust/no-ui/chat/test/tests.toml @@ -0,0 +1,28 @@ +runtime = { FetchVersion = "latest" } +# runtime = { RepoPath = "~/git/kinode" } +persist_home = false +runtime_build_release = false + + +[[tests]] +dependency_package_paths = [".."] +setup_packages = [ + { path = "..", run = true } +] +setup_scripts = [] +test_package_paths = ["chat_test"] +test_scripts = [] +timeout_secs = 5 +fakechain_router = 8545 + +[[tests.nodes]] +port = 8080 +home = "home/first" +fake_node_name = "first.dev" +runtime_verbosity = 2 + +[[tests.nodes]] +port = 8081 +home = "home/second" +fake_node_name = "second.dev" +runtime_verbosity = 2 diff --git a/src/new/templates/rust/no-ui/echo/test/echo_test/Cargo.toml b/src/new/templates/rust/no-ui/echo/test/echo_test/Cargo.toml new file mode 100644 index 00000000..08be60d0 --- /dev/null +++ b/src/new/templates/rust/no-ui/echo/test/echo_test/Cargo.toml @@ -0,0 +1,10 @@ +[workspace] +resolver = "2" +members = [ + "echo_test", +] + +[profile.release] +panic = "abort" +opt-level = "s" +lto = true diff --git a/src/new/templates/rust/no-ui/echo/test/echo_test/api/echo_test:template.os-v0.wit b/src/new/templates/rust/no-ui/echo/test/echo_test/api/echo_test:template.os-v0.wit new file mode 100644 index 00000000..c4b22457 --- /dev/null +++ b/src/new/templates/rust/no-ui/echo/test/echo_test/api/echo_test:template.os-v0.wit @@ -0,0 +1,4 @@ +world echo-test-template-dot-os-v0 { + import tester; + include process-v0; +} diff --git a/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/Cargo.toml b/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/Cargo.toml new file mode 100644 index 00000000..bae839cc --- /dev/null +++ b/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/Cargo.toml @@ -0,0 +1,21 @@ +[package] +name = "echo_test" +version = "0.1.0" +edition = "2021" + +[dependencies] +anyhow = "1.0" +bincode = "1.3" +kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.8.3" } +process_macros = { git = "https://github.com/kinode-dao/process_macros", rev = "626e501" } +rmp-serde = "1.1" +serde = { version = "1.0", features = ["derive"] } +serde_json = "1.0" +thiserror = "1.0" +wit-bindgen = "0.24.0" + +[lib] +crate-type = ["cdylib"] + +[package.metadata.component] +package = "kinode:process" diff --git a/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/src/lib.rs b/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/src/lib.rs new file mode 100644 index 00000000..e1362078 --- /dev/null +++ b/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/src/lib.rs @@ -0,0 +1,79 @@ +use crate::kinode::process::tester::{ + FailResponse, Request as TesterRequest, Response as TesterResponse, RunRequest, +}; + +use kinode_process_lib::{ + await_message, call_init, print_to_terminal, Address, ProcessId, Request, Response, +}; + +mod tester_lib; + +wit_bindgen::generate!({ + path: "target/wit", + world: "echo-test-template-dot-os-v0", + generate_unused_types: true, + additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], +}); + +fn handle_message(our: &Address) -> anyhow::Result<()> { + let message = await_message().unwrap(); + + if !message.is_request() { + unimplemented!(); + } + let source = message.source(); + if our.node != source.node { + return Err(anyhow::anyhow!( + "rejecting foreign Message from {:?}", + source, + )); + } + let TesterRequest::Run(RunRequest { + input_node_names: node_names, + .. + }) = message.body().try_into()?; + print_to_terminal(0, "echo_test: a"); + assert!(node_names.len() == 1); + + let our_echo_address = Address { + node: our.node.clone(), + process: ProcessId::new(Some("echo"), "echo", "template.os"), + }; + + // Send + print_to_terminal(0, "echo_test: b"); + let response = Request::new() + .target(our_echo_address) + .body(serde_json::to_vec("test")?) + .send_and_await_response(15)? + .unwrap(); + if response.is_request() { + fail!("echo_test"); + }; + if serde_json::json!("Ack") != serde_json::from_slice::(response.body())? { + fail!("echo_test"); + }; + + Response::new() + .body(TesterResponse::Run(Ok(()))) + .send() + .unwrap(); + + Ok(()) +} + +call_init!(init); +fn init(our: Address) { + print_to_terminal(0, "begin"); + + loop { + match handle_message(&our) { + Ok(()) => {} + Err(e) => { + print_to_terminal(0, format!("echo_test: error: {e:?}").as_str()); + + fail!("echo_test"); + } + }; + } +} diff --git a/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/src/tester_lib.rs b/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/src/tester_lib.rs new file mode 100644 index 00000000..8fb7ae19 --- /dev/null +++ b/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/src/tester_lib.rs @@ -0,0 +1,30 @@ +#[allow(unused_imports)] +use crate::kinode::process::tester::{FailResponse, Response as TesterResponse}; + +#[macro_export] +macro_rules! fail { + ($test:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: file!().into(), + line: line!(), + column: column!(), + }))) + .send() + .unwrap(); + panic!("") + }; + ($test:expr, $file:expr, $line:expr, $column:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: $file.into(), + line: $line, + column: $column, + }))) + .send() + .unwrap(); + panic!("") + }; +} diff --git a/src/new/templates/rust/no-ui/echo/test/echo_test/metadata.json b/src/new/templates/rust/no-ui/echo/test/echo_test/metadata.json new file mode 100644 index 00000000..11c67227 --- /dev/null +++ b/src/new/templates/rust/no-ui/echo/test/echo_test/metadata.json @@ -0,0 +1,20 @@ +{ + "name": "echo Test", + "description": "A test for echo.", + "image": "", + "properties": { + "package_name": "echo_test", + "current_version": "0.1.0", + "publisher": "template.os", + "mirrors": [], + "code_hashes": { + "0.1.0": "" + }, + "wit_version": 0, + "dependencies": [ + "tester:sys" + ] + }, + "external_url": "", + "animation_url": "" +} diff --git a/src/new/templates/rust/no-ui/echo/test/echo_test/pkg/manifest.json b/src/new/templates/rust/no-ui/echo/test/echo_test/pkg/manifest.json new file mode 100644 index 00000000..5448a0b4 --- /dev/null +++ b/src/new/templates/rust/no-ui/echo/test/echo_test/pkg/manifest.json @@ -0,0 +1,15 @@ +[ + { + "process_name": "echo_test", + "process_wasm_path": "/echo_test.wasm", + "on_exit": "Restart", + "request_networking": false, + "request_capabilities": [ + "echo:echo:template.os" + ], + "grant_capabilities": [ + "echo:echo:template.os" + ], + "public": true + } +] diff --git a/src/new/templates/rust/no-ui/echo/test/tests.toml b/src/new/templates/rust/no-ui/echo/test/tests.toml new file mode 100644 index 00000000..f7b06e8f --- /dev/null +++ b/src/new/templates/rust/no-ui/echo/test/tests.toml @@ -0,0 +1,22 @@ +runtime = { FetchVersion = "latest" } +# runtime = { RepoPath = "~/git/kinode" } +persist_home = false +runtime_build_release = false + + +[[tests]] +dependency_package_paths = [] +setup_packages = [ + { path = "..", run = true } +] +setup_scripts = [] +test_package_paths = ["echo_test"] +test_scripts = [] +timeout_secs = 5 +fakechain_router = 8545 + +[[tests.nodes]] +port = 8080 +home = "home/first" +fake_node_name = "first.dev" +runtime_verbosity = 2 diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/Cargo.toml b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/Cargo.toml new file mode 100644 index 00000000..08be60d0 --- /dev/null +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/Cargo.toml @@ -0,0 +1,10 @@ +[workspace] +resolver = "2" +members = [ + "echo_test", +] + +[profile.release] +panic = "abort" +opt-level = "s" +lto = true diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit new file mode 100644 index 00000000..5eb0b3a7 --- /dev/null +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit @@ -0,0 +1,5 @@ +world echo-test-template-dot-os-v0 { + import echo; + import tester; + include process-v0; +} diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml new file mode 100644 index 00000000..bae839cc --- /dev/null +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml @@ -0,0 +1,21 @@ +[package] +name = "echo_test" +version = "0.1.0" +edition = "2021" + +[dependencies] +anyhow = "1.0" +bincode = "1.3" +kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.8.3" } +process_macros = { git = "https://github.com/kinode-dao/process_macros", rev = "626e501" } +rmp-serde = "1.1" +serde = { version = "1.0", features = ["derive"] } +serde_json = "1.0" +thiserror = "1.0" +wit-bindgen = "0.24.0" + +[lib] +crate-type = ["cdylib"] + +[package.metadata.component] +package = "kinode:process" diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs new file mode 100644 index 00000000..c022a247 --- /dev/null +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs @@ -0,0 +1,104 @@ +use crate::kinode::process::echo::{Request as FibRequest, Response as FibResponse}; +use crate::kinode::process::tester::{Request as TesterRequest, Response as TesterResponse, RunRequest, FailResponse}; + +use kinode_process_lib::{await_message, call_init, print_to_terminal, Address, ProcessId, Request, Response}; + +mod tester_lib; + +wit_bindgen::generate!({ + path: "target/wit", + world: "echo-test-template-dot-os-v0", + generate_unused_types: true, + additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], +}); + +fn test_number(n: u32, address: &Address) -> anyhow::Result { + let response = Request::new() + .target(address) + .body(FibRequest::Number(n)) + .send_and_await_response(15)?.unwrap(); + if response.is_request() { fail!("echo_test"); }; + let FibResponse::Number(fib_number) = response.body().try_into()? else { + fail!("echo_test"); + }; + Ok(fib_number) +} + +fn test_numbers(n: u32, n_trials: u32, address: &Address) -> anyhow::Result { + let response = Request::new() + .target(address) + .body(FibRequest::Numbers((n, n_trials))) + .send_and_await_response(15)?.unwrap(); + if response.is_request() { fail!("echo_test"); }; + let FibResponse::Numbers((fib_number, _)) = response.body().try_into()? else { + fail!("echo_test"); + }; + Ok(fib_number) +} + +fn handle_message (our: &Address) -> anyhow::Result<()> { + let message = await_message().unwrap(); + + if !message.is_request() { + unimplemented!(); + } + let source = message.source(); + if our.node != source.node { + return Err(anyhow::anyhow!( + "rejecting foreign Message from {:?}", + source, + )); + } + let TesterRequest::Run(RunRequest { + input_node_names: node_names, + .. + }) = message.body().try_into()?; + print_to_terminal(0, "echo_test: a"); + assert!(node_names.len() == 1); + + let our_fib_address = Address { + node: our.node.clone(), + process: ProcessId::new(Some("echo"), "echo", "template.os"), + }; + + let numbers = vec![0, 1, 2, 5, 10, 20, 30, 47]; + let expecteds = vec![0, 1, 1, 5, 55, 6_765, 832_040, 2_971_215_073]; + for (number, expected) in numbers.iter().zip(expecteds.iter()) { + let result = test_number(number.clone(), &our_fib_address)?; + if &result != expected { + fail!("echo_test"); + } + } + + let numbers = vec![0, 1, 2, 5, 10, 20, 30, 47]; + let expecteds = vec![0, 1, 1, 5, 55, 6_765, 832_040, 2_971_215_073]; + for (number, expected) in numbers.iter().zip(expecteds.iter()) { + let result = test_numbers(number.clone(), 5, &our_fib_address)?; + if &result != expected { + fail!("echo_test"); + } + } + + Response::new() + .body(TesterResponse::Run(Ok(()))) + .send() + .unwrap(); + + Ok(()) +} + +call_init!(init); +fn init(our: Address) { + print_to_terminal(0, "begin"); + + loop { + match handle_message(&our) { + Ok(()) => {}, + Err(e) => { + print_to_terminal(0, format!("echo_test: error: {e:?}").as_str()); + + fail!("echo_test"); + }, + }; + } +} diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/tester_lib.rs b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/tester_lib.rs new file mode 100644 index 00000000..8fb7ae19 --- /dev/null +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/tester_lib.rs @@ -0,0 +1,30 @@ +#[allow(unused_imports)] +use crate::kinode::process::tester::{FailResponse, Response as TesterResponse}; + +#[macro_export] +macro_rules! fail { + ($test:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: file!().into(), + line: line!(), + column: column!(), + }))) + .send() + .unwrap(); + panic!("") + }; + ($test:expr, $file:expr, $line:expr, $column:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: $file.into(), + line: $line, + column: $column, + }))) + .send() + .unwrap(); + panic!("") + }; +} diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/metadata.json b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/metadata.json new file mode 100644 index 00000000..4ea09898 --- /dev/null +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/metadata.json @@ -0,0 +1,21 @@ +{ + "name": "echo Test", + "description": "A test for echo.", + "image": "", + "properties": { + "package_name": "echo_test", + "current_version": "0.1.0", + "publisher": "template.os", + "mirrors": [], + "code_hashes": { + "0.1.0": "" + }, + "wit_version": 0, + "dependencies": [ + "echo:template.os", + "tester:sys" + ] + }, + "external_url": "", + "animation_url": "" +} diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json new file mode 100644 index 00000000..5448a0b4 --- /dev/null +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json @@ -0,0 +1,15 @@ +[ + { + "process_name": "echo_test", + "process_wasm_path": "/echo_test.wasm", + "on_exit": "Restart", + "request_networking": false, + "request_capabilities": [ + "echo:echo:template.os" + ], + "grant_capabilities": [ + "echo:echo:template.os" + ], + "public": true + } +] diff --git a/src/new/templates/rust/no-ui/fibonacci/test/tests.toml b/src/new/templates/rust/no-ui/fibonacci/test/tests.toml new file mode 100644 index 00000000..b77cede8 --- /dev/null +++ b/src/new/templates/rust/no-ui/fibonacci/test/tests.toml @@ -0,0 +1,22 @@ +runtime = { FetchVersion = "latest" } +# runtime = { RepoPath = "~/git/kinode" } +persist_home = false +runtime_build_release = false + + +[[tests]] +dependency_package_paths = [".."] +setup_packages = [ + { path = "..", run = true } +] +setup_scripts = [] +test_package_paths = ["echo_test"] +test_scripts = [] +timeout_secs = 5 +fakechain_router = 8545 + +[[tests.nodes]] +port = 8080 +home = "home/first" +fake_node_name = "first.dev" +runtime_verbosity = 2 diff --git a/src/new/templates/test/file_transfer/file_transfer_test/Cargo.toml b/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/Cargo.toml similarity index 100% rename from src/new/templates/test/file_transfer/file_transfer_test/Cargo.toml rename to src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/Cargo.toml diff --git a/src/new/templates/test/file_transfer/file_transfer_test/api/file_transfer_test:template.os-v0.wit b/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/api/file_transfer_test:template.os-v0.wit similarity index 100% rename from src/new/templates/test/file_transfer/file_transfer_test/api/file_transfer_test:template.os-v0.wit rename to src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/api/file_transfer_test:template.os-v0.wit diff --git a/src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/Cargo.toml b/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/Cargo.toml similarity index 100% rename from src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/Cargo.toml rename to src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/Cargo.toml diff --git a/src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/src/lib.rs b/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/src/lib.rs similarity index 100% rename from src/new/templates/test/file_transfer/file_transfer_test/file_transfer_test/src/lib.rs rename to src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/src/lib.rs diff --git a/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/src/tester_lib.rs b/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/src/tester_lib.rs new file mode 100644 index 00000000..8fb7ae19 --- /dev/null +++ b/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/src/tester_lib.rs @@ -0,0 +1,30 @@ +#[allow(unused_imports)] +use crate::kinode::process::tester::{FailResponse, Response as TesterResponse}; + +#[macro_export] +macro_rules! fail { + ($test:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: file!().into(), + line: line!(), + column: column!(), + }))) + .send() + .unwrap(); + panic!("") + }; + ($test:expr, $file:expr, $line:expr, $column:expr) => { + Response::new() + .body(TesterResponse::Run(Err(FailResponse { + test: $test.into(), + file: $file.into(), + line: $line, + column: $column, + }))) + .send() + .unwrap(); + panic!("") + }; +} diff --git a/src/new/templates/test/file_transfer/file_transfer_test/metadata.json b/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/metadata.json similarity index 100% rename from src/new/templates/test/file_transfer/file_transfer_test/metadata.json rename to src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/metadata.json diff --git a/src/new/templates/test/file_transfer/file_transfer_test/pkg/manifest.json b/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/pkg/manifest.json similarity index 100% rename from src/new/templates/test/file_transfer/file_transfer_test/pkg/manifest.json rename to src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/pkg/manifest.json diff --git a/src/new/templates/test/file_transfer/tests.toml b/src/new/templates/rust/no-ui/file_transfer/test/tests.toml similarity index 100% rename from src/new/templates/test/file_transfer/tests.toml rename to src/new/templates/rust/no-ui/file_transfer/test/tests.toml From 11c34201747433eccdab0dc9e564a315d21ed628 Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Fri, 16 Aug 2024 13:53:05 -0700 Subject: [PATCH 05/13] update reqwest dep --- Cargo.lock | 929 ++++++++++++++++++++++++----------------------------- Cargo.toml | 2 +- 2 files changed, 429 insertions(+), 502 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index cec0f776..82276a76 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -88,9 +88,9 @@ dependencies = [ [[package]] name = "alloy-primitives" -version = "0.7.6" +version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f783611babedbbe90db3478c120fb5f5daacceffc210b39adc0af4fe0da70bad" +checksum = "ccb3ead547f4532bc8af961649942f0b9c16ee9226e26caa3f38420651cc0bf4" dependencies = [ "alloy-rlp", "bytes", @@ -110,9 +110,9 @@ dependencies = [ [[package]] name = "alloy-rlp" -version = "0.3.5" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b155716bab55763c95ba212806cf43d05bcc70e5f35b02bad20cf5ec7fe11fed" +checksum = "26154390b1d205a4a7ac7352aa2eb4f81f391399d4e2f546fb81a2f8bb383f62" dependencies = [ "alloy-rlp-derive", "arrayvec", @@ -121,13 +121,13 @@ dependencies = [ [[package]] name = "alloy-rlp-derive" -version = "0.3.5" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8037e03c7f462a063f28daec9fda285a9a89da003c552f8637a80b9c8fd96241" +checksum = "4d0f2d905ebd295e7effec65e5f6868d153936130ae718352771de3e7d03c75c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] @@ -160,23 +160,23 @@ dependencies = [ [[package]] name = "alloy-sol-macro" -version = "0.7.6" +version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bad41a7c19498e3f6079f7744656328699f8ea3e783bdd10d85788cd439f572" +checksum = "2b40397ddcdcc266f59f959770f601ce1280e699a91fc1862f29cef91707cd09" dependencies = [ "alloy-sol-macro-expander", "alloy-sol-macro-input", "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] name = "alloy-sol-macro-expander" -version = "0.7.6" +version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd9899da7d011b4fe4c406a524ed3e3f963797dbc93b45479d60341d3a27b252" +checksum = "867a5469d61480fea08c7333ffeca52d5b621f5ca2e44f271b117ec1fc9a0525" dependencies = [ "alloy-sol-macro-input", "const-hex", @@ -185,31 +185,31 @@ dependencies = [ "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", "syn-solidity", "tiny-keccak", ] [[package]] name = "alloy-sol-macro-input" -version = "0.7.6" +version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d32d595768fdc61331a132b6f65db41afae41b9b97d36c21eb1b955c422a7e60" +checksum = "2e482dc33a32b6fadbc0f599adea520bd3aaa585c141a80b404d0a3e3fa72528" dependencies = [ "const-hex", "dunce", "heck 0.5.0", "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", "syn-solidity", ] [[package]] name = "alloy-sol-types" -version = "0.7.6" +version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a49042c6d3b66a9fe6b2b5a8bf0d39fc2ae1ee0310a2a26ffedd79fb097878dd" +checksum = "a91ca40fa20793ae9c3841b83e74569d1cc9af29a2f5237314fd3452d51e38c7" dependencies = [ "alloy-primitives", "alloy-sol-macro", @@ -236,9 +236,9 @@ dependencies = [ [[package]] name = "anstream" -version = "0.6.14" +version = "0.6.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" +checksum = "64e15c1ab1f89faffbf04a634d5e1962e9074f2741eef6d97f3c4e322426d526" dependencies = [ "anstyle", "anstyle-parse", @@ -251,33 +251,33 @@ dependencies = [ [[package]] name = "anstyle" -version = "1.0.7" +version = "1.0.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" +checksum = "1bec1de6f59aedf83baf9ff929c98f2ad654b97c9510f4e70cf6f661d49fd5b1" [[package]] name = "anstyle-parse" -version = "0.2.4" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" +checksum = "eb47de1e80c2b463c735db5b217a0ddc39d612e7ac9e2e96a5aed1f57616c1cb" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.1.0" +version = "1.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" +checksum = "6d36fc52c7f6c869915e99412912f22093507da8d9e942ceaf66fe4b7c14422a" dependencies = [ "windows-sys 0.52.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.3" +version = "3.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" +checksum = "5bf74e1b6e971609db8ca7a9ce79fd5768ab6ae46441c572e46cf596f59e57f8" dependencies = [ "anstyle", "windows-sys 0.52.0", @@ -419,6 +419,12 @@ version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + [[package]] name = "auto_impl" version = "1.2.0" @@ -427,7 +433,7 @@ checksum = "3c87f3f15e7794432337fc718554eaa4dc8f04c9677a950ffe366f20a162ae42" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] @@ -507,9 +513,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "bitvec" @@ -534,9 +540,9 @@ dependencies = [ [[package]] name = "blst" -version = "0.3.12" +version = "0.3.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62dc83a094a71d43eeadd254b1ec2d24cb6a0bb6cadce00df51f0db594711a32" +checksum = "4378725facc195f1a538864863f6de233b500a8862747e7f165078a419d5e874" dependencies = [ "cc", "glob", @@ -564,9 +570,9 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.6.0" +version = "1.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" +checksum = "8318a53db07bb3f8dca91a600466bdb3f2eaadeedfdbcf02e1accbad9271ba50" dependencies = [ "serde", ] @@ -608,13 +614,13 @@ dependencies = [ [[package]] name = "cc" -version = "1.0.99" +version = "1.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96c51067fd44124faa7f870b4b1c969379ad32b2ba805aa959430ceaa384f695" +checksum = "72db2f7947ecee9b03b510377e8bb9077afa27176fdbff55c51027e976fdcc48" dependencies = [ "jobserver", "libc", - "once_cell", + "shlex", ] [[package]] @@ -635,18 +641,18 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.7" +version = "4.5.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5db83dced34638ad474f39f250d7fea9598bdd239eaced1bdf45d597da0f433f" +checksum = "ed6719fffa43d0d87e5fd8caeab59be1554fb028cd30edc88fc4369b17971019" dependencies = [ "clap_builder", ] [[package]] name = "clap_builder" -version = "4.5.7" +version = "4.5.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7e204572485eb3fbf28f871612191521df159bc3e15a9f5064c66dba3a8c05f" +checksum = "216aec2b177652e3846684cbfe25c9964d18ec45234f0f5da5157b207ed1aab6" dependencies = [ "anstream", "anstyle", @@ -656,9 +662,9 @@ dependencies = [ [[package]] name = "clap_lex" -version = "0.7.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" +checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" [[package]] name = "color-eyre" @@ -689,9 +695,9 @@ dependencies = [ [[package]] name = "colorchoice" -version = "1.0.1" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" +checksum = "d3fd119d74b830634cea2a0f58bbd0d54540518a14397557951e79340abc28c0" [[package]] name = "const-hex" @@ -736,15 +742,15 @@ dependencies = [ [[package]] name = "core-foundation-sys" -version = "0.8.6" +version = "0.8.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" +checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b" [[package]] name = "cpufeatures" -version = "0.2.12" +version = "0.2.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" +checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" dependencies = [ "libc", ] @@ -833,15 +839,15 @@ dependencies = [ [[package]] name = "derive_more" -version = "0.99.17" +version = "0.99.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" +checksum = "5f33878137e4dafd7fa914ad4e259e18a4e8e532b9617a2d0150262bf53abfce" dependencies = [ "convert_case", "proc-macro2", "quote", "rustc_version 0.4.0", - "syn 1.0.109", + "syn 2.0.74", ] [[package]] @@ -886,22 +892,11 @@ dependencies = [ "windows-sys 0.48.0", ] -[[package]] -name = "displaydoc" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.66", -] - [[package]] name = "dunce" -version = "1.0.4" +version = "1.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56ce8c6da7551ec6c462cbaf3bfbc75131ebbfa1c944aeaa9dab51ca1c5f0c3b" +checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813" [[package]] name = "ecdsa" @@ -919,9 +914,9 @@ dependencies = [ [[package]] name = "either" -version = "1.12.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dca9240753cf90908d7e4aac30f630662b02aebaa1b58a3cadabdb23385b58b" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "elliptic-curve" @@ -1018,9 +1013,9 @@ dependencies = [ [[package]] name = "flate2" -version = "1.0.30" +version = "1.0.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" +checksum = "7f211bbe8e69bbd0cfdea405084f128ae8b4aaa6b0b522fc8f2b009084797920" dependencies = [ "crc32fast", "miniz_oxide", @@ -1094,7 +1089,7 @@ checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] @@ -1163,7 +1158,7 @@ version = "0.18.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "232e6a7bfe35766bf715e55a88b39a700596c0ccfd88cd3680b4cdb40d66ef70" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "libc", "libgit2-sys", "log", @@ -1191,16 +1186,16 @@ dependencies = [ [[package]] name = "h2" -version = "0.3.26" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81fe527a889e1532da5c525686d96d4c2e74cdd345badf8dfef9f6b39dd5f5e8" +checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" dependencies = [ + "atomic-waker", "bytes", "fnv", "futures-core", "futures-sink", - "futures-util", - "http 0.2.12", + "http", "indexmap", "slab", "tokio", @@ -1261,9 +1256,9 @@ dependencies = [ [[package]] name = "http" -version = "0.2.12" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "601cbb57e577e2f5ef5be8e7b83f0f63994f25aa94d673e54a92d5c516d101f1" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" dependencies = [ "bytes", "fnv", @@ -1271,192 +1266,105 @@ dependencies = [ ] [[package]] -name = "http" -version = "1.1.0" +name = "http-body" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" +checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184" dependencies = [ "bytes", - "fnv", - "itoa", + "http", ] [[package]] -name = "http-body" -version = "0.4.6" +name = "http-body-util" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ceab25649e9960c0311ea418d17bee82c0dcec1bd053b5f9a66e265a693bed2" +checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" dependencies = [ "bytes", - "http 0.2.12", + "futures-util", + "http", + "http-body", "pin-project-lite", ] [[package]] name = "httparse" -version = "1.9.2" +version = "1.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f3935c160d00ac752e09787e6e6bfc26494c2183cc922f1bc678a60d4733bc2" - -[[package]] -name = "httpdate" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" [[package]] name = "hyper" -version = "0.14.29" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f361cde2f109281a220d4307746cdfd5ee3f410da58a70377762396775634b33" +checksum = "50dfd22e0e76d0f662d429a5f80fcaf3855009297eab6a0a9f8543834744ba05" dependencies = [ "bytes", "futures-channel", - "futures-core", "futures-util", "h2", - "http 0.2.12", + "http", "http-body", "httparse", - "httpdate", "itoa", "pin-project-lite", - "socket2", + "smallvec", "tokio", - "tower-service", - "tracing", "want", ] [[package]] -name = "hyper-tls" -version = "0.5.0" +name = "hyper-rustls" +version = "0.27.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" +checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" dependencies = [ - "bytes", + "futures-util", + "http", "hyper", - "native-tls", + "hyper-util", + "rustls", + "rustls-pki-types", "tokio", - "tokio-native-tls", -] - -[[package]] -name = "icu_collections" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db2fa452206ebee18c4b5c2274dbf1de17008e874b4dc4f0aea9d01ca79e4526" -dependencies = [ - "displaydoc", - "yoke", - "zerofrom", - "zerovec", -] - -[[package]] -name = "icu_locid" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13acbb8371917fc971be86fc8057c41a64b521c184808a698c02acc242dbf637" -dependencies = [ - "displaydoc", - "litemap", - "tinystr", - "writeable", - "zerovec", -] - -[[package]] -name = "icu_locid_transform" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01d11ac35de8e40fdeda00d9e1e9d92525f3f9d887cdd7aa81d727596788b54e" -dependencies = [ - "displaydoc", - "icu_locid", - "icu_locid_transform_data", - "icu_provider", - "tinystr", - "zerovec", -] - -[[package]] -name = "icu_locid_transform_data" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fdc8ff3388f852bede6b579ad4e978ab004f139284d7b28715f773507b946f6e" - -[[package]] -name = "icu_normalizer" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19ce3e0da2ec68599d193c93d088142efd7f9c5d6fc9b803774855747dc6a84f" -dependencies = [ - "displaydoc", - "icu_collections", - "icu_normalizer_data", - "icu_properties", - "icu_provider", - "smallvec", - "utf16_iter", - "utf8_iter", - "write16", - "zerovec", -] - -[[package]] -name = "icu_normalizer_data" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8cafbf7aa791e9b22bec55a167906f9e1215fd475cd22adfcf660e03e989516" - -[[package]] -name = "icu_properties" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f8ac670d7422d7f76b32e17a5db556510825b29ec9154f235977c9caba61036" -dependencies = [ - "displaydoc", - "icu_collections", - "icu_locid_transform", - "icu_properties_data", - "icu_provider", - "tinystr", - "zerovec", + "tokio-rustls", + "tower-service", ] [[package]] -name = "icu_properties_data" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67a8effbc3dd3e4ba1afa8ad918d5684b8868b3b26500753effea8d2eed19569" - -[[package]] -name = "icu_provider" -version = "1.5.0" +name = "hyper-tls" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ed421c8a8ef78d3e2dbc98a973be2f3770cb42b606e3ab18d6237c4dfde68d9" +checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" dependencies = [ - "displaydoc", - "icu_locid", - "icu_provider_macros", - "stable_deref_trait", - "tinystr", - "writeable", - "yoke", - "zerofrom", - "zerovec", + "bytes", + "http-body-util", + "hyper", + "hyper-util", + "native-tls", + "tokio", + "tokio-native-tls", + "tower-service", ] [[package]] -name = "icu_provider_macros" -version = "1.5.0" +name = "hyper-util" +version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ec89e9337638ecdc08744df490b221a7399bf8d164eb52a665454e60e075ad6" +checksum = "cde7055719c54e36e95e8719f95883f22072a48ede39db7fc17a4e1d5281e9b9" dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.66", + "bytes", + "futures-channel", + "futures-util", + "http", + "http-body", + "hyper", + "pin-project-lite", + "socket2", + "tokio", + "tower", + "tower-service", + "tracing", ] [[package]] @@ -1467,14 +1375,12 @@ checksum = "25a2bc672d1148e28034f176e01fffebb08b35768468cc954630da77a1449005" [[package]] name = "idna" -version = "1.0.0" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4716a3a0933a1d01c2f72450e89596eb51dd34ef3c211ccd875acdf1f8fe47ed" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" dependencies = [ - "icu_normalizer", - "icu_properties", - "smallvec", - "utf8_iter", + "unicode-bidi", + "unicode-normalization", ] [[package]] @@ -1505,9 +1411,9 @@ checksum = "ce23b50ad8242c51a442f3ff322d56b02f08852c77e4c0b4d3fd684abc89c683" [[package]] name = "indexmap" -version = "2.2.6" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" +checksum = "93ead53efc7ea8ed3cfb0c79fc8023fbb782a5432b52830b6518941cebe6505c" dependencies = [ "equivalent", "hashbrown", @@ -1531,9 +1437,9 @@ checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" [[package]] name = "is_terminal_polyfill" -version = "1.70.0" +version = "1.70.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" +checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" [[package]] name = "itertools" @@ -1561,18 +1467,18 @@ checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" [[package]] name = "jobserver" -version = "0.1.31" +version = "0.1.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2b099aaa34a9751c5bf0878add70444e1ed2dd73f347be99003d4577277de6e" +checksum = "48d1dbcbbeb6a7fec7e059840aa538bd62aaccf972c7346c4d9d2059312853d0" dependencies = [ "libc", ] [[package]] name = "js-sys" -version = "0.3.69" +version = "0.3.70" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" +checksum = "1868808506b929d7b0cfa8f75951347aa71bb21144b7791bae35d9bccfcfe37a" dependencies = [ "wasm-bindgen", ] @@ -1592,9 +1498,9 @@ dependencies = [ [[package]] name = "keccak-asm" -version = "0.1.1" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47a3633291834c4fbebf8673acbc1b04ec9d151418ff9b8e26dcd79129928758" +checksum = "422fbc7ff2f2f5bdffeb07718e5a5324dca72b0c9293d50df4026652385e3314" dependencies = [ "digest 0.10.7", "sha3-asm", @@ -1611,7 +1517,7 @@ dependencies = [ "alloy-transport", "anyhow", "bincode", - "http 1.1.0", + "http", "mime_guess", "rand", "rmp-serde", @@ -1655,9 +1561,9 @@ dependencies = [ [[package]] name = "lazy_static" -version = "1.4.0" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" [[package]] name = "leb128" @@ -1667,9 +1573,9 @@ checksum = "884e2677b40cc8c339eaefcb701c32ef1fd2493d71118dc0ca4b6a736c93bd67" [[package]] name = "libc" -version = "0.2.155" +version = "0.2.156" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" +checksum = "a5f43f184355eefb8d17fc948dbecf6c13be3c141f20d834ae842193a448c72a" [[package]] name = "libgit2-sys" @@ -1697,7 +1603,7 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "libc", ] @@ -1717,9 +1623,9 @@ dependencies = [ [[package]] name = "libz-sys" -version = "1.1.18" +version = "1.1.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c15da26e5af7e25c90b37a2d75cdbf940cf4a55316de9d84c679c9b8bfabf82e" +checksum = "fdc53a7799a7496ebc9fd29f31f7df80e83c9bda5299768af5f9e59eeea74647" dependencies = [ "cc", "libc", @@ -1733,17 +1639,11 @@ version = "0.4.14" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" -[[package]] -name = "litemap" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "643cb0b8d4fcc284004d5fd0d67ccf61dfffadb7f75e1e71bc420f4688a3a704" - [[package]] name = "log" -version = "0.4.21" +version = "0.4.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" [[package]] name = "matchers" @@ -1756,9 +1656,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.7.2" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "mime" @@ -1768,9 +1668,9 @@ checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" [[package]] name = "mime_guess" -version = "2.0.4" +version = "2.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4192263c238a5f0d0c6bfd21f336a313a4ce1c450542449ca191bb657b4642ef" +checksum = "f7c44f8e672c00fe5308fa235f821cb4198414e1c77935c1ab6948d3fd78550e" dependencies = [ "mime", "unicase", @@ -1778,22 +1678,23 @@ dependencies = [ [[package]] name = "miniz_oxide" -version = "0.7.3" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87dfd01fe195c66b572b37921ad8803d010623c0aca821bea2302239d155cdae" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" dependencies = [ "adler", ] [[package]] name = "mio" -version = "0.8.11" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" +checksum = "80e04d1dcff3aae0704555fe5fee3bcfaf3d1fdf8a7e521d5b9d2b42acb52cec" dependencies = [ + "hermit-abi", "libc", "wasi", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -1819,7 +1720,7 @@ version = "0.27.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "cfg-if", "libc", ] @@ -1836,9 +1737,9 @@ dependencies = [ [[package]] name = "num-bigint" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" +checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" dependencies = [ "num-integer", "num-traits", @@ -1896,11 +1797,11 @@ checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" [[package]] name = "openssl" -version = "0.10.64" +version = "0.10.66" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" +checksum = "9529f4786b70a3e8c61e11179af17ab6188ad8d0ded78c5529441ed39d4bd9c1" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "cfg-if", "foreign-types", "libc", @@ -1917,7 +1818,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] @@ -1928,9 +1829,9 @@ checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" [[package]] name = "openssl-sys" -version = "0.9.102" +version = "0.9.103" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" +checksum = "7f9e8deee91df40a943c71b917e5874b951d32a802526c85721ce3b776c929d6" dependencies = [ "cc", "libc", @@ -2019,9 +1920,9 @@ checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" [[package]] name = "pest" -version = "2.7.10" +version = "2.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "560131c633294438da9f7c4b08189194b20946c8274c6b9e38881a7874dc8ee8" +checksum = "cd53dff83f26735fdc1ca837098ccf133605d794cdae66acfc2bfac3ec809d95" dependencies = [ "memchr", "thiserror", @@ -2045,7 +1946,7 @@ checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] @@ -2084,9 +1985,12 @@ checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" [[package]] name = "ppv-lite86" -version = "0.2.17" +version = "0.2.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" +checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04" +dependencies = [ + "zerocopy", +] [[package]] name = "primitive-types" @@ -2134,22 +2038,22 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.85" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22244ce15aa966053a896d1accb3a6e68469b97c7f33f284b99f0d576879fc23" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] [[package]] name = "proptest" -version = "1.4.0" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31b476131c3c86cb68032fdc5cb6d5a1045e3e42d96b69fa599fd77701e1f5bf" +checksum = "b4c2511913b88df1637da85cc8d96ec8e43a3f8bb8ccb71ee1ac240d6f3df58d" dependencies = [ "bit-set", "bit-vec", - "bitflags 2.5.0", + "bitflags 2.6.0", "lazy_static", "num-traits", "rand", @@ -2234,9 +2138,9 @@ dependencies = [ [[package]] name = "regex" -version = "1.10.5" +version = "1.10.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" +checksum = "4219d74c6b67a3654a9fbebc4b419e22126d13d2f3c4a07ee0cb61ff79a79619" dependencies = [ "aho-corasick", "memchr", @@ -2278,20 +2182,23 @@ checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" [[package]] name = "reqwest" -version = "0.11.27" +version = "0.12.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd67538700a17451e7cba03ac727fb961abb7607553461627b97de0b89cf4a62" +checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" dependencies = [ - "base64 0.21.7", + "base64 0.22.1", "bytes", "encoding_rs", "futures-core", "futures-util", "h2", - "http 0.2.12", + "http", "http-body", + "http-body-util", "hyper", + "hyper-rustls", "hyper-tls", + "hyper-util", "ipnet", "js-sys", "log", @@ -2326,6 +2233,21 @@ dependencies = [ "subtle", ] +[[package]] +name = "ring" +version = "0.17.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" +dependencies = [ + "cc", + "cfg-if", + "getrandom", + "libc", + "spin", + "untrusted", + "windows-sys 0.52.0", +] + [[package]] name = "rlp" version = "0.5.2" @@ -2424,20 +2346,51 @@ version = "0.38.34" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "errno", "libc", "linux-raw-sys", "windows-sys 0.52.0", ] +[[package]] +name = "rustls" +version = "0.23.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c58f8c84392efc0a126acce10fa59ff7b3d2ac06ab451a33f2741989b806b044" +dependencies = [ + "once_cell", + "rustls-pki-types", + "rustls-webpki", + "subtle", + "zeroize", +] + [[package]] name = "rustls-pemfile" -version = "1.0.4" +version = "2.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c" +checksum = "196fe16b00e106300d3e45ecfcb764fa292a535d7326a29a5875c579c7417425" dependencies = [ - "base64 0.21.7", + "base64 0.22.1", + "rustls-pki-types", +] + +[[package]] +name = "rustls-pki-types" +version = "1.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc0a2ce646f8655401bb81e7927b812614bd5d91dbc968696be50603510fcaf0" + +[[package]] +name = "rustls-webpki" +version = "0.102.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e6b52d4fda176fd835fdc55a835d4a89b8499cad995885a21149d5ad62f852e" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", ] [[package]] @@ -2492,11 +2445,11 @@ dependencies = [ [[package]] name = "security-framework" -version = "2.11.0" +version = "2.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" +checksum = "897b2245f0b511c87893af39b033e5ca9cce68824c4d7e7630b5a1d339658d02" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "core-foundation", "core-foundation-sys", "libc", @@ -2505,9 +2458,9 @@ dependencies = [ [[package]] name = "security-framework-sys" -version = "2.11.0" +version = "2.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" +checksum = "75da29fe9b9b08fe9d6b22b5b4bcbc75d8db3aa31e639aa56bb62e9d46bfceaf" dependencies = [ "core-foundation-sys", "libc", @@ -2539,40 +2492,41 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.203" +version = "1.0.208" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" +checksum = "cff085d2cb684faa248efb494c39b68e522822ac0de72ccf08109abde717cfb2" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.203" +version = "1.0.208" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" +checksum = "24008e81ff7613ed8e5ba0cfaf24e2c2f1e5b8a0495711e44fcd4882fca62bcf" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] name = "serde_json" -version = "1.0.117" +version = "1.0.125" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3" +checksum = "83c8e735a073ccf5be70aa8066aa984eaf2fa000db6c8d0100ae605b366d31ed" dependencies = [ "itoa", + "memchr", "ryu", "serde", ] [[package]] name = "serde_spanned" -version = "0.6.6" +version = "0.6.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" +checksum = "eb5b1b31579f3811bf615c144393417496f152e12ac8b7663bf664f4a815306d" dependencies = [ "serde", ] @@ -2613,9 +2567,9 @@ dependencies = [ [[package]] name = "sha3-asm" -version = "0.1.1" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9b57fd861253bff08bb1919e995f90ba8f4889de2726091c8876f3a4e823b40" +checksum = "57d79b758b7cb2085612b11a235055e485605a5103faccdd633f35bd7aee69dd" dependencies = [ "cc", "cfg-if", @@ -2630,6 +2584,12 @@ dependencies = [ "lazy_static", ] +[[package]] +name = "shlex" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" + [[package]] name = "signal-hook-registry" version = "1.4.2" @@ -2683,6 +2643,12 @@ dependencies = [ "smallvec", ] +[[package]] +name = "spin" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" + [[package]] name = "spki" version = "0.7.3" @@ -2693,12 +2659,6 @@ dependencies = [ "der", ] -[[package]] -name = "stable_deref_trait" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" - [[package]] name = "static_assertions" version = "1.1.0" @@ -2713,9 +2673,9 @@ checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" [[package]] name = "subtle" -version = "2.5.0" +version = "2.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" [[package]] name = "syn" @@ -2730,9 +2690,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.66" +version = "2.0.74" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c42f3f41a2de00b01c0aaad383c5a45241efc8b2d1eda5661812fda5f3cdcff5" +checksum = "1fceb41e3d546d0bd83421d3409b1460cc7444cd389341a4c880fe7a042cb3d7" dependencies = [ "proc-macro2", "quote", @@ -2741,32 +2701,21 @@ dependencies = [ [[package]] name = "syn-solidity" -version = "0.7.6" +version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d71e19bca02c807c9faa67b5a47673ff231b6e7449b251695188522f1dc44b2" +checksum = "c837dc8852cb7074e46b444afb81783140dab12c58867b49fb3898fbafedf7ea" dependencies = [ "paste", "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] name = "sync_wrapper" -version = "0.1.2" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" - -[[package]] -name = "synstructure" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.66", -] +checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" [[package]] name = "system-configuration" @@ -2797,34 +2746,35 @@ checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" [[package]] name = "tempfile" -version = "3.10.1" +version = "3.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" +checksum = "04cbcdd0c794ebb0d4cf35e88edd2f7d2c4c3e9a5a6dab322839b321c6a87a64" dependencies = [ "cfg-if", "fastrand", + "once_cell", "rustix", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "thiserror" -version = "1.0.61" +version = "1.0.63" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" +checksum = "c0342370b38b6a11b6cc11d6a805569958d54cfa061a29969c3b5ce2ea405724" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.61" +version = "1.0.63" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" +checksum = "a4558b58466b9ad7ca0f102865eccc95938dca1a74a856f2b57b6629050da261" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] @@ -2887,42 +2837,46 @@ dependencies = [ ] [[package]] -name = "tinystr" -version = "0.7.6" +name = "tinyvec" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9117f5d4db391c1cf6927e7bea3db74b9a1c1add8f7eda9ffd5364f40f57b82f" +checksum = "445e881f4f6d382d5f27c034e25eb92edd7c784ceab92a0937db7f2e9471b938" dependencies = [ - "displaydoc", - "zerovec", + "tinyvec_macros", ] +[[package]] +name = "tinyvec_macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" + [[package]] name = "tokio" -version = "1.38.0" +version = "1.39.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" +checksum = "daa4fb1bc778bd6f04cbfc4bb2d06a7396a8f299dc33ea1900cedaa316f467b1" dependencies = [ "backtrace", "bytes", "libc", "mio", - "num_cpus", "pin-project-lite", "signal-hook-registry", "socket2", "tokio-macros", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] name = "tokio-macros" -version = "2.3.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" +checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] @@ -2935,6 +2889,17 @@ dependencies = [ "tokio", ] +[[package]] +name = "tokio-rustls" +version = "0.26.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" +dependencies = [ + "rustls", + "rustls-pki-types", + "tokio", +] + [[package]] name = "tokio-util" version = "0.7.11" @@ -2950,21 +2915,21 @@ dependencies = [ [[package]] name = "toml" -version = "0.8.14" +version = "0.8.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" +checksum = "a1ed1f98e3fdc28d6d910e6737ae6ab1a93bf1985935a1193e68f93eeb68d24e" dependencies = [ "serde", "serde_spanned", "toml_datetime", - "toml_edit 0.22.14", + "toml_edit 0.22.20", ] [[package]] name = "toml_datetime" -version = "0.6.6" +version = "0.6.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" +checksum = "0dd7358ecb8fc2f8d014bf86f6f638ce72ba252a2c3a2572f2a795f1d23efb41" dependencies = [ "serde", ] @@ -2982,15 +2947,15 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.22.14" +version = "0.22.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" +checksum = "583c44c02ad26b0c3f3066fe629275e50627026c51ac2e595cca4c230ce1ce1d" dependencies = [ "indexmap", "serde", "serde_spanned", "toml_datetime", - "winnow 0.6.13", + "winnow 0.6.18", ] [[package]] @@ -3003,6 +2968,7 @@ dependencies = [ "futures-util", "pin-project", "pin-project-lite", + "tokio", "tower-layer", "tower-service", "tracing", @@ -3010,15 +2976,15 @@ dependencies = [ [[package]] name = "tower-layer" -version = "0.3.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" +checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" [[package]] name = "tower-service" -version = "0.3.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" +checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" [[package]] name = "tracing" @@ -3052,7 +3018,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] @@ -3162,12 +3128,27 @@ dependencies = [ "version_check", ] +[[package]] +name = "unicode-bidi" +version = "0.3.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" + [[package]] name = "unicode-ident" version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unicode-normalization" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a56d1686db2308d901306f92a263857ef59ea39678a5458e7cb17f01415101f5" +dependencies = [ + "tinyvec", +] + [[package]] name = "unicode-segmentation" version = "1.11.0" @@ -3180,29 +3161,23 @@ version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" +[[package]] +name = "untrusted" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" + [[package]] name = "url" -version = "2.5.1" +version = "2.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7c25da092f0a868cdf09e8674cd3b7ef3a7d92a24253e663a2fb85e2496de56" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" dependencies = [ "form_urlencoded", "idna", "percent-encoding", ] -[[package]] -name = "utf16_iter" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8232dd3cdaed5356e0f716d285e4b40b932ac434100fe9b7e0e8e935b9e6246" - -[[package]] -name = "utf8_iter" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be" - [[package]] name = "utf8parse" version = "0.2.2" @@ -3223,9 +3198,9 @@ checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" [[package]] name = "version_check" -version = "0.9.4" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" [[package]] name = "wait-timeout" @@ -3263,34 +3238,35 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.92" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" +checksum = "a82edfc16a6c469f5f44dc7b571814045d60404b55a0ee849f9bcfa2e63dd9b5" dependencies = [ "cfg-if", + "once_cell", "wasm-bindgen-macro", ] [[package]] name = "wasm-bindgen-backend" -version = "0.2.92" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" +checksum = "9de396da306523044d3302746f1208fa71d7532227f15e347e2d93e4145dd77b" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.42" +version = "0.4.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" +checksum = "61e9300f63a621e96ed275155c108eb6f843b6a26d053f122ab69724559dc8ed" dependencies = [ "cfg-if", "js-sys", @@ -3300,9 +3276,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.92" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" +checksum = "585c4c91a46b072c92e908d99cb1dcdf95c5218eeb6f3bf1efa991ee7a68cccf" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -3310,22 +3286,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.92" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" +checksum = "afc340c74d9005395cf9dd098506f7f44e38f2b4a21c6aaacf9a105ea5e1e836" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.92" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" +checksum = "c62a0a307cb4a311d3a07867860911ca130c3494e8c2719593806c08bc5d0484" [[package]] name = "wasm-encoder" @@ -3358,16 +3334,16 @@ version = "0.202.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d6998515d3cf3f8b980ef7c11b29a9b1017d4cf86b99ae93b546992df9931413" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "indexmap", "semver 1.0.23", ] [[package]] name = "web-sys" -version = "0.3.69" +version = "0.3.70" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" +checksum = "26fdeaafd9bd129f65e7c031593c24d62186301e0c72c8978fa1678be7d532c0" dependencies = [ "js-sys", "wasm-bindgen", @@ -3391,11 +3367,11 @@ checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" [[package]] name = "winapi-util" -version = "0.1.8" +version = "0.1.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" +checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb" dependencies = [ - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -3419,7 +3395,16 @@ version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" dependencies = [ - "windows-targets 0.52.5", + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-sys" +version = "0.59.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" +dependencies = [ + "windows-targets 0.52.6", ] [[package]] @@ -3439,18 +3424,18 @@ dependencies = [ [[package]] name = "windows-targets" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" dependencies = [ - "windows_aarch64_gnullvm 0.52.5", - "windows_aarch64_msvc 0.52.5", - "windows_i686_gnu 0.52.5", + "windows_aarch64_gnullvm 0.52.6", + "windows_aarch64_msvc 0.52.6", + "windows_i686_gnu 0.52.6", "windows_i686_gnullvm", - "windows_i686_msvc 0.52.5", - "windows_x86_64_gnu 0.52.5", - "windows_x86_64_gnullvm 0.52.5", - "windows_x86_64_msvc 0.52.5", + "windows_i686_msvc 0.52.6", + "windows_x86_64_gnu 0.52.6", + "windows_x86_64_gnullvm 0.52.6", + "windows_x86_64_msvc 0.52.6", ] [[package]] @@ -3461,9 +3446,9 @@ checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" [[package]] name = "windows_aarch64_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" +checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" [[package]] name = "windows_aarch64_msvc" @@ -3473,9 +3458,9 @@ checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" [[package]] name = "windows_aarch64_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" +checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" [[package]] name = "windows_i686_gnu" @@ -3485,15 +3470,15 @@ checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" [[package]] name = "windows_i686_gnu" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" +checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" [[package]] name = "windows_i686_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" +checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" [[package]] name = "windows_i686_msvc" @@ -3503,9 +3488,9 @@ checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" [[package]] name = "windows_i686_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" +checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" [[package]] name = "windows_x86_64_gnu" @@ -3515,9 +3500,9 @@ checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" [[package]] name = "windows_x86_64_gnu" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" +checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" [[package]] name = "windows_x86_64_gnullvm" @@ -3527,9 +3512,9 @@ checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" [[package]] name = "windows_x86_64_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" +checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" [[package]] name = "windows_x86_64_msvc" @@ -3539,9 +3524,9 @@ checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" [[package]] name = "windows_x86_64_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" +checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "winnow" @@ -3554,18 +3539,18 @@ dependencies = [ [[package]] name = "winnow" -version = "0.6.13" +version = "0.6.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" +checksum = "68a9bda4691f099d435ad181000724da8e5899daa10713c2d432552b9ccd3a6f" dependencies = [ "memchr", ] [[package]] name = "winreg" -version = "0.50.0" +version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "524e57b2c537c0f9b1e69f1965311ec12182b4122e45035b1508cd24d2adadb1" +checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" dependencies = [ "cfg-if", "windows-sys 0.48.0", @@ -3597,7 +3582,7 @@ version = "0.24.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3b0780cf7046630ed70f689a098cd8d56c5c3b22f2a7379bbdb088879963ff96" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", ] [[package]] @@ -3623,7 +3608,7 @@ dependencies = [ "anyhow", "proc-macro2", "quote", - "syn 2.0.66", + "syn 2.0.74", "wit-bindgen-core", "wit-bindgen-rust", ] @@ -3635,7 +3620,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0c836b1fd9932de0431c1758d8be08212071b6bba0151f7bac826dbc4312a2a9" dependencies = [ "anyhow", - "bitflags 2.5.0", + "bitflags 2.6.0", "indexmap", "log", "serde", @@ -3665,18 +3650,6 @@ dependencies = [ "wasmparser", ] -[[package]] -name = "write16" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1890f4022759daae28ed4fe62859b1236caebfc61ede2f63ed4e695f3f6d936" - -[[package]] -name = "writeable" -version = "0.5.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e9df38ee2d2c3c5948ea468a8406ff0db0b29ae1ffde1bcf20ef305bcc95c51" - [[package]] name = "wyz" version = "0.5.1" @@ -3687,48 +3660,24 @@ dependencies = [ ] [[package]] -name = "yoke" -version = "0.7.4" +name = "zerocopy" +version = "0.7.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c5b1314b079b0930c31e3af543d8ee1757b1951ae1e1565ec704403a7240ca5" +checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" dependencies = [ - "serde", - "stable_deref_trait", - "yoke-derive", - "zerofrom", -] - -[[package]] -name = "yoke-derive" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28cc31741b18cb6f1d5ff12f5b7523e3d6eb0852bbbad19d73905511d9849b95" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.66", - "synstructure", -] - -[[package]] -name = "zerofrom" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91ec111ce797d0e0784a1116d0ddcdbea84322cd79e5d5ad173daeba4f93ab55" -dependencies = [ - "zerofrom-derive", + "byteorder", + "zerocopy-derive", ] [[package]] -name = "zerofrom-derive" -version = "0.1.4" +name = "zerocopy-derive" +version = "0.7.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ea7b4a3637ea8669cedf0f1fd5c286a17f3de97b8dd5a70a6c167a1730e63a5" +checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", - "synstructure", + "syn 2.0.74", ] [[package]] @@ -3748,29 +3697,7 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.66", -] - -[[package]] -name = "zerovec" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb2cc8827d6c0994478a15c53f374f46fbd41bea663d809b14744bc42e6b109c" -dependencies = [ - "yoke", - "zerofrom", - "zerovec-derive", -] - -[[package]] -name = "zerovec-derive" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97cf56601ee5052b4417d90c8755c6683473c926039908196cf35d99f893ebe7" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.66", + "syn 2.0.74", ] [[package]] @@ -3814,9 +3741,9 @@ dependencies = [ [[package]] name = "zstd-sys" -version = "2.0.10+zstd.1.5.6" +version = "2.0.13+zstd.1.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c253a4914af5bafc8fa8c86ee400827e83cf6ec01195ec1f1ed8441bf00d65aa" +checksum = "38ff0f21cfee8f97d94cef41359e0c89aa6113028ab0291aa8ca0038995a95aa" dependencies = [ "cc", "pkg-config", diff --git a/Cargo.toml b/Cargo.toml index a71e37a9..9f12fdb8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,7 +17,7 @@ hex = "0.4" kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib.git", rev = "7eb3a04" } nix = { version = "0.27", features = ["process", "signal", "term"] } regex = "1" -reqwest = { version = "0.11", features = ["json"] } +reqwest = { version = "0.12", features = ["json"] } semver = "1.0" serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" From 507b5529a43ee89ef4aedfb1d22dde73bddc3c4e Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Fri, 16 Aug 2024 14:08:17 -0700 Subject: [PATCH 06/13] add excluded workspaces --- Cargo.toml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/Cargo.toml b/Cargo.toml index 9f12fdb8..df00d342 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -39,6 +39,25 @@ walkdir = "2.4" wit-bindgen = "0.24.0" zip = "0.6" +[workspace] +members = [] +exclude = [ + "src/new/templates/rust/no-ui/blank/blank", + "src/new/templates/rust/no-ui/chat/chat", + "src/new/templates/rust/no-ui/chat/send", + "src/new/templates/rust/no-ui/chat/test/chat_test", + "src/new/templates/rust/no-ui/echo/echo", + "src/new/templates/rust/no-ui/echo/test/echo_test", + "src/new/templates/rust/no-ui/fibonacci/fibonacci", + "src/new/templates/rust/no-ui/fibonacci/number", + "src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test", + "src/new/templates/rust/no-ui/file_transfer/file_transfer", + "src/new/templates/rust/no-ui/file_transfer/download", + "src/new/templates/rust/no-ui/file_transfer/list_files", + "src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test", +] +resolver = "2" + [[bin]] name = "kit" path = "src/main.rs" From f705e0002b3d4ce2006a4049a6c6baa1306b1988 Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Fri, 16 Aug 2024 14:16:55 -0700 Subject: [PATCH 07/13] add another workspace tweak --- Cargo.toml | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index df00d342..f890503d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -42,19 +42,20 @@ zip = "0.6" [workspace] members = [] exclude = [ - "src/new/templates/rust/no-ui/blank/blank", - "src/new/templates/rust/no-ui/chat/chat", - "src/new/templates/rust/no-ui/chat/send", - "src/new/templates/rust/no-ui/chat/test/chat_test", - "src/new/templates/rust/no-ui/echo/echo", - "src/new/templates/rust/no-ui/echo/test/echo_test", - "src/new/templates/rust/no-ui/fibonacci/fibonacci", - "src/new/templates/rust/no-ui/fibonacci/number", - "src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test", - "src/new/templates/rust/no-ui/file_transfer/file_transfer", - "src/new/templates/rust/no-ui/file_transfer/download", - "src/new/templates/rust/no-ui/file_transfer/list_files", - "src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test", + "src/new/templates/*", + #"src/new/templates/rust/no-ui/blank/blank", + #"src/new/templates/rust/no-ui/chat/chat", + #"src/new/templates/rust/no-ui/chat/send", + #"src/new/templates/rust/no-ui/chat/test/chat_test", + #"src/new/templates/rust/no-ui/echo/echo", + #"src/new/templates/rust/no-ui/echo/test/echo_test", + #"src/new/templates/rust/no-ui/fibonacci/fibonacci", + #"src/new/templates/rust/no-ui/fibonacci/number", + #"src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test", + #"src/new/templates/rust/no-ui/file_transfer/file_transfer", + #"src/new/templates/rust/no-ui/file_transfer/download", + #"src/new/templates/rust/no-ui/file_transfer/list_files", + #"src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test", ] resolver = "2" From c98b6e653eb470ccc9f31192d13786e3f2a1423a Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Fri, 16 Aug 2024 15:14:55 -0700 Subject: [PATCH 08/13] try another thing to stop the warnings --- Cargo.toml | 17 +---------------- .../templates/rust/no-ui/chat/chat/Cargo.toml | 1 + 2 files changed, 2 insertions(+), 16 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index f890503d..dd830ccb 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -41,22 +41,7 @@ zip = "0.6" [workspace] members = [] -exclude = [ - "src/new/templates/*", - #"src/new/templates/rust/no-ui/blank/blank", - #"src/new/templates/rust/no-ui/chat/chat", - #"src/new/templates/rust/no-ui/chat/send", - #"src/new/templates/rust/no-ui/chat/test/chat_test", - #"src/new/templates/rust/no-ui/echo/echo", - #"src/new/templates/rust/no-ui/echo/test/echo_test", - #"src/new/templates/rust/no-ui/fibonacci/fibonacci", - #"src/new/templates/rust/no-ui/fibonacci/number", - #"src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test", - #"src/new/templates/rust/no-ui/file_transfer/file_transfer", - #"src/new/templates/rust/no-ui/file_transfer/download", - #"src/new/templates/rust/no-ui/file_transfer/list_files", - #"src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test", -] +exclude = ["src/new/templates/*"] resolver = "2" [[bin]] diff --git a/src/new/templates/rust/no-ui/chat/chat/Cargo.toml b/src/new/templates/rust/no-ui/chat/chat/Cargo.toml index 83b7c6bc..7c684d8c 100644 --- a/src/new/templates/rust/no-ui/chat/chat/Cargo.toml +++ b/src/new/templates/rust/no-ui/chat/chat/Cargo.toml @@ -2,6 +2,7 @@ name = "chat" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" From 39de43e2f250f59474393f9b5e442ca863ef7067 Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Fri, 16 Aug 2024 15:22:50 -0700 Subject: [PATCH 09/13] fix installation warnings --- src/new/templates/rust/no-ui/blank/blank/Cargo.toml | 1 + src/new/templates/rust/no-ui/chat/send/Cargo.toml | 1 + .../rust/no-ui/chat/test/chat_test/chat_test/Cargo.toml | 1 + src/new/templates/rust/no-ui/echo/echo/Cargo.toml | 1 + .../rust/no-ui/echo/test/echo_test/echo_test/Cargo.toml | 1 + src/new/templates/rust/no-ui/fibonacci/fibonacci/Cargo.toml | 1 + src/new/templates/rust/no-ui/fibonacci/number/Cargo.toml | 1 + .../fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml | 1 + src/new/templates/rust/no-ui/file_transfer/download/Cargo.toml | 1 + .../templates/rust/no-ui/file_transfer/file_transfer/Cargo.toml | 1 + .../rust/no-ui/file_transfer/file_transfer_worker/Cargo.toml | 1 + .../rust/no-ui/file_transfer/file_transfer_worker_api/Cargo.toml | 1 + src/new/templates/rust/no-ui/file_transfer/list_files/Cargo.toml | 1 + .../test/file_transfer_test/file_transfer_test/Cargo.toml | 1 + 14 files changed, 14 insertions(+) diff --git a/src/new/templates/rust/no-ui/blank/blank/Cargo.toml b/src/new/templates/rust/no-ui/blank/blank/Cargo.toml index 635edccb..503b41ec 100644 --- a/src/new/templates/rust/no-ui/blank/blank/Cargo.toml +++ b/src/new/templates/rust/no-ui/blank/blank/Cargo.toml @@ -2,6 +2,7 @@ name = "blank" version = "0.1.0" edition = "2021" +publish = false [dependencies] kinode_process_lib = "0.8.5" diff --git a/src/new/templates/rust/no-ui/chat/send/Cargo.toml b/src/new/templates/rust/no-ui/chat/send/Cargo.toml index c208c510..9ed24313 100644 --- a/src/new/templates/rust/no-ui/chat/send/Cargo.toml +++ b/src/new/templates/rust/no-ui/chat/send/Cargo.toml @@ -2,6 +2,7 @@ name = "send" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/Cargo.toml b/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/Cargo.toml index 905155d1..7c5126db 100644 --- a/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/Cargo.toml +++ b/src/new/templates/rust/no-ui/chat/test/chat_test/chat_test/Cargo.toml @@ -2,6 +2,7 @@ name = "chat_test" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/echo/echo/Cargo.toml b/src/new/templates/rust/no-ui/echo/echo/Cargo.toml index ee2d8283..887c131f 100644 --- a/src/new/templates/rust/no-ui/echo/echo/Cargo.toml +++ b/src/new/templates/rust/no-ui/echo/echo/Cargo.toml @@ -2,6 +2,7 @@ name = "echo" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/Cargo.toml b/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/Cargo.toml index bae839cc..f0207b23 100644 --- a/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/Cargo.toml +++ b/src/new/templates/rust/no-ui/echo/test/echo_test/echo_test/Cargo.toml @@ -2,6 +2,7 @@ name = "echo_test" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/fibonacci/fibonacci/Cargo.toml b/src/new/templates/rust/no-ui/fibonacci/fibonacci/Cargo.toml index a2c20aa1..c1cbf336 100644 --- a/src/new/templates/rust/no-ui/fibonacci/fibonacci/Cargo.toml +++ b/src/new/templates/rust/no-ui/fibonacci/fibonacci/Cargo.toml @@ -2,6 +2,7 @@ name = "fibonacci" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/fibonacci/number/Cargo.toml b/src/new/templates/rust/no-ui/fibonacci/number/Cargo.toml index a7313dd9..e51908c2 100644 --- a/src/new/templates/rust/no-ui/fibonacci/number/Cargo.toml +++ b/src/new/templates/rust/no-ui/fibonacci/number/Cargo.toml @@ -2,6 +2,7 @@ name = "number" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml index bae839cc..f0207b23 100644 --- a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml @@ -2,6 +2,7 @@ name = "echo_test" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/file_transfer/download/Cargo.toml b/src/new/templates/rust/no-ui/file_transfer/download/Cargo.toml index 32567295..f542889a 100644 --- a/src/new/templates/rust/no-ui/file_transfer/download/Cargo.toml +++ b/src/new/templates/rust/no-ui/file_transfer/download/Cargo.toml @@ -2,6 +2,7 @@ name = "download" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/file_transfer/file_transfer/Cargo.toml b/src/new/templates/rust/no-ui/file_transfer/file_transfer/Cargo.toml index a511ca85..745330e6 100644 --- a/src/new/templates/rust/no-ui/file_transfer/file_transfer/Cargo.toml +++ b/src/new/templates/rust/no-ui/file_transfer/file_transfer/Cargo.toml @@ -2,6 +2,7 @@ name = "file_transfer" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/Cargo.toml b/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/Cargo.toml index ec9836f6..3df989c0 100644 --- a/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/Cargo.toml +++ b/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker/Cargo.toml @@ -2,6 +2,7 @@ name = "file_transfer_worker" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker_api/Cargo.toml b/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker_api/Cargo.toml index 2e75c860..86d3aee3 100644 --- a/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker_api/Cargo.toml +++ b/src/new/templates/rust/no-ui/file_transfer/file_transfer_worker_api/Cargo.toml @@ -2,6 +2,7 @@ name = "file_transfer_worker_api" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/file_transfer/list_files/Cargo.toml b/src/new/templates/rust/no-ui/file_transfer/list_files/Cargo.toml index 6c6ca8fb..2f5f70c0 100644 --- a/src/new/templates/rust/no-ui/file_transfer/list_files/Cargo.toml +++ b/src/new/templates/rust/no-ui/file_transfer/list_files/Cargo.toml @@ -2,6 +2,7 @@ name = "list_files" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/Cargo.toml b/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/Cargo.toml index 65b5f70f..ba4cc936 100644 --- a/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/Cargo.toml +++ b/src/new/templates/rust/no-ui/file_transfer/test/file_transfer_test/file_transfer_test/Cargo.toml @@ -2,6 +2,7 @@ name = "file_transfer_test" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" From 4303449c8d58749b1cb73cd37b998123b49bad98 Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Fri, 16 Aug 2024 15:26:33 -0700 Subject: [PATCH 10/13] add some more straggelers --- .../javascript/no-ui/chat/test/chat_test/chat_test/Cargo.toml | 1 + .../javascript/no-ui/echo/test/echo_test/echo_test/Cargo.toml | 1 + .../fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml | 1 + .../python/no-ui/chat/test/chat_test/chat_test/Cargo.toml | 1 + .../python/no-ui/echo/test/echo_test/echo_test/Cargo.toml | 1 + .../fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml | 1 + 6 files changed, 6 insertions(+) diff --git a/src/new/templates/javascript/no-ui/chat/test/chat_test/chat_test/Cargo.toml b/src/new/templates/javascript/no-ui/chat/test/chat_test/chat_test/Cargo.toml index 905155d1..7c5126db 100644 --- a/src/new/templates/javascript/no-ui/chat/test/chat_test/chat_test/Cargo.toml +++ b/src/new/templates/javascript/no-ui/chat/test/chat_test/chat_test/Cargo.toml @@ -2,6 +2,7 @@ name = "chat_test" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/javascript/no-ui/echo/test/echo_test/echo_test/Cargo.toml b/src/new/templates/javascript/no-ui/echo/test/echo_test/echo_test/Cargo.toml index bae839cc..f0207b23 100644 --- a/src/new/templates/javascript/no-ui/echo/test/echo_test/echo_test/Cargo.toml +++ b/src/new/templates/javascript/no-ui/echo/test/echo_test/echo_test/Cargo.toml @@ -2,6 +2,7 @@ name = "echo_test" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml index bae839cc..f0207b23 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml +++ b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml @@ -2,6 +2,7 @@ name = "echo_test" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/Cargo.toml b/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/Cargo.toml index 905155d1..7c5126db 100644 --- a/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/Cargo.toml +++ b/src/new/templates/python/no-ui/chat/test/chat_test/chat_test/Cargo.toml @@ -2,6 +2,7 @@ name = "chat_test" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/Cargo.toml b/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/Cargo.toml index bae839cc..f0207b23 100644 --- a/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/Cargo.toml +++ b/src/new/templates/python/no-ui/echo/test/echo_test/echo_test/Cargo.toml @@ -2,6 +2,7 @@ name = "echo_test" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml index bae839cc..f0207b23 100644 --- a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml @@ -2,6 +2,7 @@ name = "echo_test" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" From 6939d0ce9f9de9afcf195736a96cd7185b727c3c Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Fri, 16 Aug 2024 15:27:20 -0700 Subject: [PATCH 11/13] add final straggeler --- src/new/templates/javascript/no-ui/chat/send/Cargo.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/src/new/templates/javascript/no-ui/chat/send/Cargo.toml b/src/new/templates/javascript/no-ui/chat/send/Cargo.toml index efa24945..5dcbe593 100644 --- a/src/new/templates/javascript/no-ui/chat/send/Cargo.toml +++ b/src/new/templates/javascript/no-ui/chat/send/Cargo.toml @@ -2,6 +2,7 @@ name = "send" version = "0.1.0" edition = "2021" +publish = false [dependencies] anyhow = "1.0" From b0cf224417dfa564af787400bc6e294bcdf8c239 Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Fri, 16 Aug 2024 15:38:57 -0700 Subject: [PATCH 12/13] new: fix incorrect package name on fibonacci --- .../fibonacci/test/fibonacci_test/Cargo.toml | 2 +- .../api/fibonacci_test:template.os-v0.wit | 4 ++-- .../fibonacci_test/fibonacci_test/Cargo.toml | 5 +--- .../fibonacci_test/fibonacci_test/src/lib.rs | 24 +++++++++---------- .../test/fibonacci_test/metadata.json | 8 +++---- .../test/fibonacci_test/pkg/manifest.json | 8 +++---- .../rust/no-ui/fibonacci/test/tests.toml | 2 +- 7 files changed, 25 insertions(+), 28 deletions(-) diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/Cargo.toml b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/Cargo.toml index 08be60d0..a743c053 100644 --- a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/Cargo.toml +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/Cargo.toml @@ -1,7 +1,7 @@ [workspace] resolver = "2" members = [ - "echo_test", + "fibonacci_test", ] [profile.release] diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit index 5eb0b3a7..bef06257 100644 --- a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit @@ -1,5 +1,5 @@ -world echo-test-template-dot-os-v0 { - import echo; +world fibonacci-test-template-dot-os-v0 { + import fibonacci; import tester; include process-v0; } diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml index f0207b23..5485e2e1 100644 --- a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml @@ -1,18 +1,15 @@ [package] -name = "echo_test" +name = "fibonacci_test" version = "0.1.0" edition = "2021" publish = false [dependencies] anyhow = "1.0" -bincode = "1.3" kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.8.3" } process_macros = { git = "https://github.com/kinode-dao/process_macros", rev = "626e501" } -rmp-serde = "1.1" serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" -thiserror = "1.0" wit-bindgen = "0.24.0" [lib] diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs index c022a247..60fef67c 100644 --- a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs @@ -1,4 +1,4 @@ -use crate::kinode::process::echo::{Request as FibRequest, Response as FibResponse}; +use crate::kinode::process::fibonacci::{Request as FibRequest, Response as FibResponse}; use crate::kinode::process::tester::{Request as TesterRequest, Response as TesterResponse, RunRequest, FailResponse}; use kinode_process_lib::{await_message, call_init, print_to_terminal, Address, ProcessId, Request, Response}; @@ -7,7 +7,7 @@ mod tester_lib; wit_bindgen::generate!({ path: "target/wit", - world: "echo-test-template-dot-os-v0", + world: "fibonacci-test-template-dot-os-v0", generate_unused_types: true, additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); @@ -17,9 +17,9 @@ fn test_number(n: u32, address: &Address) -> anyhow::Result { .target(address) .body(FibRequest::Number(n)) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("echo_test"); }; + if response.is_request() { fail!("fibonacci_test"); }; let FibResponse::Number(fib_number) = response.body().try_into()? else { - fail!("echo_test"); + fail!("fibonacci_test"); }; Ok(fib_number) } @@ -29,9 +29,9 @@ fn test_numbers(n: u32, n_trials: u32, address: &Address) -> anyhow::Result .target(address) .body(FibRequest::Numbers((n, n_trials))) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("echo_test"); }; + if response.is_request() { fail!("fibonacci_test"); }; let FibResponse::Numbers((fib_number, _)) = response.body().try_into()? else { - fail!("echo_test"); + fail!("fibonacci_test"); }; Ok(fib_number) } @@ -53,12 +53,12 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { input_node_names: node_names, .. }) = message.body().try_into()?; - print_to_terminal(0, "echo_test: a"); + print_to_terminal(0, "fibonacci_test: a"); assert!(node_names.len() == 1); let our_fib_address = Address { node: our.node.clone(), - process: ProcessId::new(Some("echo"), "echo", "template.os"), + process: ProcessId::new(Some("fibonacci"), "fibonacci", "template.os"), }; let numbers = vec![0, 1, 2, 5, 10, 20, 30, 47]; @@ -66,7 +66,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { for (number, expected) in numbers.iter().zip(expecteds.iter()) { let result = test_number(number.clone(), &our_fib_address)?; if &result != expected { - fail!("echo_test"); + fail!("fibonacci_test"); } } @@ -75,7 +75,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { for (number, expected) in numbers.iter().zip(expecteds.iter()) { let result = test_numbers(number.clone(), 5, &our_fib_address)?; if &result != expected { - fail!("echo_test"); + fail!("fibonacci_test"); } } @@ -95,9 +95,9 @@ fn init(our: Address) { match handle_message(&our) { Ok(()) => {}, Err(e) => { - print_to_terminal(0, format!("echo_test: error: {e:?}").as_str()); + print_to_terminal(0, format!("fibonacci_test: error: {e:?}").as_str()); - fail!("echo_test"); + fail!("fibonacci_test"); }, }; } diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/metadata.json b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/metadata.json index 4ea09898..daeaff69 100644 --- a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/metadata.json +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/metadata.json @@ -1,9 +1,9 @@ { - "name": "echo Test", - "description": "A test for echo.", + "name": "fibonacci Test", + "description": "A test for fibonacci.", "image": "", "properties": { - "package_name": "echo_test", + "package_name": "fibonacci_test", "current_version": "0.1.0", "publisher": "template.os", "mirrors": [], @@ -12,7 +12,7 @@ }, "wit_version": 0, "dependencies": [ - "echo:template.os", + "fibonacci:template.os", "tester:sys" ] }, diff --git a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json index 5448a0b4..2e0253aa 100644 --- a/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json +++ b/src/new/templates/rust/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json @@ -1,14 +1,14 @@ [ { - "process_name": "echo_test", - "process_wasm_path": "/echo_test.wasm", + "process_name": "fibonacci_test", + "process_wasm_path": "/fibonacci_test.wasm", "on_exit": "Restart", "request_networking": false, "request_capabilities": [ - "echo:echo:template.os" + "fibonacci:fibonacci:template.os" ], "grant_capabilities": [ - "echo:echo:template.os" + "fibonacci:fibonacci:template.os" ], "public": true } diff --git a/src/new/templates/rust/no-ui/fibonacci/test/tests.toml b/src/new/templates/rust/no-ui/fibonacci/test/tests.toml index b77cede8..b851fba3 100644 --- a/src/new/templates/rust/no-ui/fibonacci/test/tests.toml +++ b/src/new/templates/rust/no-ui/fibonacci/test/tests.toml @@ -10,7 +10,7 @@ setup_packages = [ { path = "..", run = true } ] setup_scripts = [] -test_package_paths = ["echo_test"] +test_package_paths = ["fibonacci_test"] test_scripts = [] timeout_secs = 5 fakechain_router = 8545 From aa64115484b409ae85b6af112b6d7a925215e607 Mon Sep 17 00:00:00 2001 From: hosted-fornet Date: Fri, 16 Aug 2024 15:59:30 -0700 Subject: [PATCH 13/13] new: fix more tests --- .../fibonacci/test/fibonacci_test/Cargo.toml | 2 +- .../api/fibonacci_test:template.os-v0.wit | 4 ++-- .../fibonacci_test/fibonacci_test/Cargo.toml | 5 +--- .../fibonacci_test/fibonacci_test/src/lib.rs | 24 +++++++++---------- .../test/fibonacci_test/metadata.json | 8 +++---- .../test/fibonacci_test/pkg/manifest.json | 8 +++---- .../no-ui/fibonacci/test/tests.toml | 2 +- .../fibonacci/test/fibonacci_test/Cargo.toml | 2 +- .../api/fibonacci_test:template.os-v0.wit | 4 ++-- .../fibonacci_test/fibonacci_test/Cargo.toml | 5 +--- .../fibonacci_test/fibonacci_test/src/lib.rs | 24 +++++++++---------- .../test/fibonacci_test/metadata.json | 8 +++---- .../test/fibonacci_test/pkg/manifest.json | 8 +++---- .../python/no-ui/fibonacci/test/tests.toml | 2 +- 14 files changed, 50 insertions(+), 56 deletions(-) diff --git a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/Cargo.toml b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/Cargo.toml index 08be60d0..a743c053 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/Cargo.toml +++ b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/Cargo.toml @@ -1,7 +1,7 @@ [workspace] resolver = "2" members = [ - "echo_test", + "fibonacci_test", ] [profile.release] diff --git a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit index 5eb0b3a7..bef06257 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit +++ b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit @@ -1,5 +1,5 @@ -world echo-test-template-dot-os-v0 { - import echo; +world fibonacci-test-template-dot-os-v0 { + import fibonacci; import tester; include process-v0; } diff --git a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml index f0207b23..5485e2e1 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml +++ b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml @@ -1,18 +1,15 @@ [package] -name = "echo_test" +name = "fibonacci_test" version = "0.1.0" edition = "2021" publish = false [dependencies] anyhow = "1.0" -bincode = "1.3" kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.8.3" } process_macros = { git = "https://github.com/kinode-dao/process_macros", rev = "626e501" } -rmp-serde = "1.1" serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" -thiserror = "1.0" wit-bindgen = "0.24.0" [lib] diff --git a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs index c022a247..60fef67c 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs +++ b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs @@ -1,4 +1,4 @@ -use crate::kinode::process::echo::{Request as FibRequest, Response as FibResponse}; +use crate::kinode::process::fibonacci::{Request as FibRequest, Response as FibResponse}; use crate::kinode::process::tester::{Request as TesterRequest, Response as TesterResponse, RunRequest, FailResponse}; use kinode_process_lib::{await_message, call_init, print_to_terminal, Address, ProcessId, Request, Response}; @@ -7,7 +7,7 @@ mod tester_lib; wit_bindgen::generate!({ path: "target/wit", - world: "echo-test-template-dot-os-v0", + world: "fibonacci-test-template-dot-os-v0", generate_unused_types: true, additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); @@ -17,9 +17,9 @@ fn test_number(n: u32, address: &Address) -> anyhow::Result { .target(address) .body(FibRequest::Number(n)) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("echo_test"); }; + if response.is_request() { fail!("fibonacci_test"); }; let FibResponse::Number(fib_number) = response.body().try_into()? else { - fail!("echo_test"); + fail!("fibonacci_test"); }; Ok(fib_number) } @@ -29,9 +29,9 @@ fn test_numbers(n: u32, n_trials: u32, address: &Address) -> anyhow::Result .target(address) .body(FibRequest::Numbers((n, n_trials))) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("echo_test"); }; + if response.is_request() { fail!("fibonacci_test"); }; let FibResponse::Numbers((fib_number, _)) = response.body().try_into()? else { - fail!("echo_test"); + fail!("fibonacci_test"); }; Ok(fib_number) } @@ -53,12 +53,12 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { input_node_names: node_names, .. }) = message.body().try_into()?; - print_to_terminal(0, "echo_test: a"); + print_to_terminal(0, "fibonacci_test: a"); assert!(node_names.len() == 1); let our_fib_address = Address { node: our.node.clone(), - process: ProcessId::new(Some("echo"), "echo", "template.os"), + process: ProcessId::new(Some("fibonacci"), "fibonacci", "template.os"), }; let numbers = vec![0, 1, 2, 5, 10, 20, 30, 47]; @@ -66,7 +66,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { for (number, expected) in numbers.iter().zip(expecteds.iter()) { let result = test_number(number.clone(), &our_fib_address)?; if &result != expected { - fail!("echo_test"); + fail!("fibonacci_test"); } } @@ -75,7 +75,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { for (number, expected) in numbers.iter().zip(expecteds.iter()) { let result = test_numbers(number.clone(), 5, &our_fib_address)?; if &result != expected { - fail!("echo_test"); + fail!("fibonacci_test"); } } @@ -95,9 +95,9 @@ fn init(our: Address) { match handle_message(&our) { Ok(()) => {}, Err(e) => { - print_to_terminal(0, format!("echo_test: error: {e:?}").as_str()); + print_to_terminal(0, format!("fibonacci_test: error: {e:?}").as_str()); - fail!("echo_test"); + fail!("fibonacci_test"); }, }; } diff --git a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/metadata.json b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/metadata.json index 4ea09898..daeaff69 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/metadata.json +++ b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/metadata.json @@ -1,9 +1,9 @@ { - "name": "echo Test", - "description": "A test for echo.", + "name": "fibonacci Test", + "description": "A test for fibonacci.", "image": "", "properties": { - "package_name": "echo_test", + "package_name": "fibonacci_test", "current_version": "0.1.0", "publisher": "template.os", "mirrors": [], @@ -12,7 +12,7 @@ }, "wit_version": 0, "dependencies": [ - "echo:template.os", + "fibonacci:template.os", "tester:sys" ] }, diff --git a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json index 5448a0b4..2e0253aa 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json +++ b/src/new/templates/javascript/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json @@ -1,14 +1,14 @@ [ { - "process_name": "echo_test", - "process_wasm_path": "/echo_test.wasm", + "process_name": "fibonacci_test", + "process_wasm_path": "/fibonacci_test.wasm", "on_exit": "Restart", "request_networking": false, "request_capabilities": [ - "echo:echo:template.os" + "fibonacci:fibonacci:template.os" ], "grant_capabilities": [ - "echo:echo:template.os" + "fibonacci:fibonacci:template.os" ], "public": true } diff --git a/src/new/templates/javascript/no-ui/fibonacci/test/tests.toml b/src/new/templates/javascript/no-ui/fibonacci/test/tests.toml index b77cede8..b851fba3 100644 --- a/src/new/templates/javascript/no-ui/fibonacci/test/tests.toml +++ b/src/new/templates/javascript/no-ui/fibonacci/test/tests.toml @@ -10,7 +10,7 @@ setup_packages = [ { path = "..", run = true } ] setup_scripts = [] -test_package_paths = ["echo_test"] +test_package_paths = ["fibonacci_test"] test_scripts = [] timeout_secs = 5 fakechain_router = 8545 diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/Cargo.toml b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/Cargo.toml index 08be60d0..a743c053 100644 --- a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/Cargo.toml +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/Cargo.toml @@ -1,7 +1,7 @@ [workspace] resolver = "2" members = [ - "echo_test", + "fibonacci_test", ] [profile.release] diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit index 5eb0b3a7..bef06257 100644 --- a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/api/fibonacci_test:template.os-v0.wit @@ -1,5 +1,5 @@ -world echo-test-template-dot-os-v0 { - import echo; +world fibonacci-test-template-dot-os-v0 { + import fibonacci; import tester; include process-v0; } diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml index f0207b23..5485e2e1 100644 --- a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/Cargo.toml @@ -1,18 +1,15 @@ [package] -name = "echo_test" +name = "fibonacci_test" version = "0.1.0" edition = "2021" publish = false [dependencies] anyhow = "1.0" -bincode = "1.3" kinode_process_lib = { git = "https://github.com/kinode-dao/process_lib", tag = "v0.8.3" } process_macros = { git = "https://github.com/kinode-dao/process_macros", rev = "626e501" } -rmp-serde = "1.1" serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" -thiserror = "1.0" wit-bindgen = "0.24.0" [lib] diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs index c022a247..60fef67c 100644 --- a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/fibonacci_test/src/lib.rs @@ -1,4 +1,4 @@ -use crate::kinode::process::echo::{Request as FibRequest, Response as FibResponse}; +use crate::kinode::process::fibonacci::{Request as FibRequest, Response as FibResponse}; use crate::kinode::process::tester::{Request as TesterRequest, Response as TesterResponse, RunRequest, FailResponse}; use kinode_process_lib::{await_message, call_init, print_to_terminal, Address, ProcessId, Request, Response}; @@ -7,7 +7,7 @@ mod tester_lib; wit_bindgen::generate!({ path: "target/wit", - world: "echo-test-template-dot-os-v0", + world: "fibonacci-test-template-dot-os-v0", generate_unused_types: true, additional_derives: [PartialEq, serde::Deserialize, serde::Serialize, process_macros::SerdeJsonInto], }); @@ -17,9 +17,9 @@ fn test_number(n: u32, address: &Address) -> anyhow::Result { .target(address) .body(FibRequest::Number(n)) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("echo_test"); }; + if response.is_request() { fail!("fibonacci_test"); }; let FibResponse::Number(fib_number) = response.body().try_into()? else { - fail!("echo_test"); + fail!("fibonacci_test"); }; Ok(fib_number) } @@ -29,9 +29,9 @@ fn test_numbers(n: u32, n_trials: u32, address: &Address) -> anyhow::Result .target(address) .body(FibRequest::Numbers((n, n_trials))) .send_and_await_response(15)?.unwrap(); - if response.is_request() { fail!("echo_test"); }; + if response.is_request() { fail!("fibonacci_test"); }; let FibResponse::Numbers((fib_number, _)) = response.body().try_into()? else { - fail!("echo_test"); + fail!("fibonacci_test"); }; Ok(fib_number) } @@ -53,12 +53,12 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { input_node_names: node_names, .. }) = message.body().try_into()?; - print_to_terminal(0, "echo_test: a"); + print_to_terminal(0, "fibonacci_test: a"); assert!(node_names.len() == 1); let our_fib_address = Address { node: our.node.clone(), - process: ProcessId::new(Some("echo"), "echo", "template.os"), + process: ProcessId::new(Some("fibonacci"), "fibonacci", "template.os"), }; let numbers = vec![0, 1, 2, 5, 10, 20, 30, 47]; @@ -66,7 +66,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { for (number, expected) in numbers.iter().zip(expecteds.iter()) { let result = test_number(number.clone(), &our_fib_address)?; if &result != expected { - fail!("echo_test"); + fail!("fibonacci_test"); } } @@ -75,7 +75,7 @@ fn handle_message (our: &Address) -> anyhow::Result<()> { for (number, expected) in numbers.iter().zip(expecteds.iter()) { let result = test_numbers(number.clone(), 5, &our_fib_address)?; if &result != expected { - fail!("echo_test"); + fail!("fibonacci_test"); } } @@ -95,9 +95,9 @@ fn init(our: Address) { match handle_message(&our) { Ok(()) => {}, Err(e) => { - print_to_terminal(0, format!("echo_test: error: {e:?}").as_str()); + print_to_terminal(0, format!("fibonacci_test: error: {e:?}").as_str()); - fail!("echo_test"); + fail!("fibonacci_test"); }, }; } diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/metadata.json b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/metadata.json index 4ea09898..daeaff69 100644 --- a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/metadata.json +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/metadata.json @@ -1,9 +1,9 @@ { - "name": "echo Test", - "description": "A test for echo.", + "name": "fibonacci Test", + "description": "A test for fibonacci.", "image": "", "properties": { - "package_name": "echo_test", + "package_name": "fibonacci_test", "current_version": "0.1.0", "publisher": "template.os", "mirrors": [], @@ -12,7 +12,7 @@ }, "wit_version": 0, "dependencies": [ - "echo:template.os", + "fibonacci:template.os", "tester:sys" ] }, diff --git a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json index 5448a0b4..2e0253aa 100644 --- a/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json +++ b/src/new/templates/python/no-ui/fibonacci/test/fibonacci_test/pkg/manifest.json @@ -1,14 +1,14 @@ [ { - "process_name": "echo_test", - "process_wasm_path": "/echo_test.wasm", + "process_name": "fibonacci_test", + "process_wasm_path": "/fibonacci_test.wasm", "on_exit": "Restart", "request_networking": false, "request_capabilities": [ - "echo:echo:template.os" + "fibonacci:fibonacci:template.os" ], "grant_capabilities": [ - "echo:echo:template.os" + "fibonacci:fibonacci:template.os" ], "public": true } diff --git a/src/new/templates/python/no-ui/fibonacci/test/tests.toml b/src/new/templates/python/no-ui/fibonacci/test/tests.toml index b77cede8..b851fba3 100644 --- a/src/new/templates/python/no-ui/fibonacci/test/tests.toml +++ b/src/new/templates/python/no-ui/fibonacci/test/tests.toml @@ -10,7 +10,7 @@ setup_packages = [ { path = "..", run = true } ] setup_scripts = [] -test_package_paths = ["echo_test"] +test_package_paths = ["fibonacci_test"] test_scripts = [] timeout_secs = 5 fakechain_router = 8545