The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.
Rust agent-orchestrationai-agentsai-assistantdesktopllmlocal-firstmcppersonal-aiprivacyrustsecond-braintauri
refactor(runtime): move hosted turn execution logic to tests
Steven Enamakelb3b0485cfc22
diff --git a/crates/openhuman-core/src/channels/runtime/startup/module_providers_hosted_tests.rs b/crates/openhuman-core/src/channels/runtime/startup/module_providers_hosted_tests.rsindex 52f889dc97..de96908b6f 100644--- a/crates/openhuman-core/src/channels/runtime/startup/module_providers_hosted_tests.rs+++ b/crates/openhuman-core/src/channels/runtime/startup/module_providers_hosted_tests.rs@@ -415,49 +415,3 @@ async fn hosted_target_projects_typed_media_and_voice_to_web_and_gateway_once());}}--async fn run_hosted_compiled_turn(- object: &tinybus::module::ModuleObjectClient,- channel: tinychannels_bus::ChannelRef,- conversation: tinychannels_bus::ConversationRef,- turn_id: &str,- text: &str,-) -> ProgressiveResult {- let opened: ProgressiveResult = object- .call_confidential(- tinychannels_bus::methods::EXECUTE_PROGRESSIVE,- (ProgressiveCommand::OpenHostedOutput {- channel,- conversation,- turn_id: turn_id.into(),- lifetime_ms: 30_000,- },),- )- .await- .expect("compiled module should open a hosted output handle");- let ProgressiveResult::Opened { handle } = opened else {- panic!("expected compiled module hosted output handle: {opened:?}");- };- let result: ProgressiveResult = object- .call_confidential(- tinychannels_bus::methods::EXECUTE_PROGRESSIVE,- (ProgressiveCommand::FeedOutput {- handle: handle.clone(),- events: vec![ChannelOutputEvent::FinalMessage {- text: text.into(),- parts: vec![],- receipt: None,- }],- },),- )- .await- .expect("compiled module should return the typed callback outcome");- object- .call_confidential::<ProgressiveResult>(- tinychannels_bus::methods::EXECUTE_PROGRESSIVE,- (ProgressiveCommand::Close { handle },),- )- .await- .expect("compiled module hosted output should close");- result-}diff --git a/crates/openhuman-core/src/channels/runtime/startup/module_providers_tests.rs b/crates/openhuman-core/src/channels/runtime/startup/module_providers_tests.rsindex 81fb40e921..1a05d8e5f2 100644--- a/crates/openhuman-core/src/channels/runtime/startup/module_providers_tests.rs+++ b/crates/openhuman-core/src/channels/runtime/startup/module_providers_tests.rs@@ -408,5 +408,51 @@ async fn compiled_module_hosted_progressive_callback_is_scoped_and_typed() {.expect("hosted module runtime should close after the turn");}+async fn run_hosted_compiled_turn(+ object: &tinybus::module::ModuleObjectClient,+ channel: tinychannels_bus::ChannelRef,+ conversation: tinychannels_bus::ConversationRef,+ turn_id: &str,+ text: &str,+) -> ProgressiveResult {+ let opened: ProgressiveResult = object+ .call_confidential(+ tinychannels_bus::methods::EXECUTE_PROGRESSIVE,+ (ProgressiveCommand::OpenHostedOutput {+ channel,+ conversation,+ turn_id: turn_id.into(),+ lifetime_ms: 30_000,+ },),+ )+ .await+ .expect("compiled module should open a hosted output handle");+ let ProgressiveResult::Opened { handle } = opened else {+ panic!("expected compiled module hosted output handle: {opened:?}");+ };+ let result: ProgressiveResult = object+ .call_confidential(+ tinychannels_bus::methods::EXECUTE_PROGRESSIVE,+ (ProgressiveCommand::FeedOutput {+ handle: handle.clone(),+ events: vec![ChannelOutputEvent::FinalMessage {+ text: text.into(),+ parts: vec![],+ receipt: None,+ }],+ },),+ )+ .await+ .expect("compiled module should return the typed callback outcome");+ object+ .call_confidential::<ProgressiveResult>(+ tinychannels_bus::methods::EXECUTE_PROGRESSIVE,+ (ProgressiveCommand::Close { handle },),+ )+ .await+ .expect("compiled module hosted output should close");+ result+}+#[path = "module_providers_hosted_tests.rs"]mod hosted_tests;