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
test(channels): migrate proactive fixture to typed send API
Steven Enamakel484ea8c3d989
diff --git a/crates/openhuman-core/src/channels/proactive_tests.rs b/crates/openhuman-core/src/channels/proactive_tests.rsindex 2ea0f7b3e0..0623dce6d5 100644--- a/crates/openhuman-core/src/channels/proactive_tests.rs+++ b/crates/openhuman-core/src/channels/proactive_tests.rs@@ -1,6 +1,6 @@use super::*;use std::sync::atomic::{AtomicUsize, Ordering};-use tinychannels_bus::ChannelMessage;+use tinychannels_bus::{ChannelMessage, ChannelOutboundMessage};use tokio::sync::mpsc;struct MockChannel {@@ -57,17 +57,25 @@ impl Channel for MockChannel {fn proactive_target(&self) -> Option<String> {self.target.clone()}- async fn send(&self, _message: &SendMessage) -> anyhow::Result<()> {+ async fn send_typed(&self, _message: &ChannelOutboundMessage) -> anyhow::Result<()> {self.send_count.fetch_add(1, Ordering::SeqCst);- Ok(())- }- async fn send_idempotent(&self, message: &SendMessage) -> anyhow::Result<()> {self.outbound_intent_count.fetch_add(1, Ordering::SeqCst);- self.send(message).await+ Ok(())}+ #[allow(+ deprecated,+ reason = "TinyChannels v22 still requires the legacy listener method on focused fixtures"+ )]async fn listen(&self, _tx: mpsc::Sender<ChannelMessage>) -> anyhow::Result<()> {Ok(())}+ #[allow(+ deprecated,+ reason = "TinyChannels v22 still requires the legacy send method on focused fixtures"+ )]+ async fn send(&self, _message: &SendMessage) -> anyhow::Result<()> {+ Ok(())+ }}fn proactive_event() -> DomainEvent {diff --git a/crates/openhuman-core/src/channels/runtime/supervision.rs b/crates/openhuman-core/src/channels/runtime/supervision.rsindex 53b33638b6..b239a61c8b 100644--- a/crates/openhuman-core/src/channels/runtime/supervision.rs+++ b/crates/openhuman-core/src/channels/runtime/supervision.rs@@ -52,10 +52,18 @@ impl tinychannels::Channel for LegacyListenerFixture {self.0.name()}+ #[allow(+ deprecated,+ reason = "TinyChannels v22 still requires the legacy send method on its provider trait"+ )]async fn send(&self, message: &traits::SendMessage) -> anyhow::Result<()> {self.0.send(message).await}+ #[allow(+ deprecated,+ reason = "TinyChannels v22 still requires the legacy listener method for test fixtures"+ )]async fn listen(&self,tx: tokio::sync::mpsc::Sender<traits::ChannelMessage>,diff --git a/crates/openhuman-core/src/channels/runtime/supervision_tests.rs b/crates/openhuman-core/src/channels/runtime/supervision_tests.rsindex da61ab1ca9..e8ba8b6590 100644--- a/crates/openhuman-core/src/channels/runtime/supervision_tests.rs+++ b/crates/openhuman-core/src/channels/runtime/supervision_tests.rs@@ -48,10 +48,18 @@ impl Channel for ReconnectOkChannel {"reconnect-ok"}+ #[allow(+ deprecated,+ reason = "TinyChannels v22 still requires the legacy send method on focused listener fixtures"+ )]async fn send(&self, _message: &super::super::super::SendMessage) -> anyhow::Result<()> {Ok(())}+ #[allow(+ deprecated,+ reason = "TinyChannels v22 still requires the legacy listener method on focused fixtures"+ )]async fn listen(&self,_tx: tokio::sync::mpsc::Sender<traits::ChannelMessage>,