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
style: apply rustfmt formatting across core crates
Steven Enamakel8e5a7812d6ad
diff --git a/crates/openhuman-core/src/agent/session_host/prelude_integrations.rs b/crates/openhuman-core/src/agent/session_host/prelude_integrations.rsindex 0638a8a623..6502245496 100644--- a/crates/openhuman-core/src/agent/session_host/prelude_integrations.rs+++ b/crates/openhuman-core/src/agent/session_host/prelude_integrations.rs@@ -386,8 +386,7 @@ async fn load_connected_integrations(match crate::integrations::composio::fetch_connected_integrations_status(config).await {FetchConnectedIntegrationsStatus::Authoritative(connected) => Some((connected, true)),FetchConnectedIntegrationsStatus::Unavailable => {- let stale =- crate::integrations::composio::cached_active_integrations(config);+ let stale = crate::integrations::composio::cached_active_integrations(config);log::warn!("[session] integrations fetch unavailable; using stale snapshot={}",stale.as_ref().map_or(0, Vec::len)diff --git a/crates/openhuman-core/src/agent/tool_policy.rs b/crates/openhuman-core/src/agent/tool_policy.rsindex e6936140a5..4d3401f674 100644--- a/crates/openhuman-core/src/agent/tool_policy.rs+++ b/crates/openhuman-core/src/agent/tool_policy.rs@@ -69,7 +69,6 @@ pub struct ToolPolicyRequest {pub tool_name: String,pub arguments: serde_json::Value,pub context: ToolCallContext,-}impl fmt::Debug for ToolPolicyRequest {diff --git a/crates/openhuman-core/src/channels/runtime/dispatch/routing.rs b/crates/openhuman-core/src/channels/runtime/dispatch/routing.rsindex 3ae1944279..c587dc67b1 100644--- a/crates/openhuman-core/src/channels/runtime/dispatch/routing.rs+++ b/crates/openhuman-core/src/channels/runtime/dispatch/routing.rs@@ -144,10 +144,7 @@ pub(super) async fn resolve_target_agent(channel: &str) -> AgentScoping {// Use the expiry-tolerant read for the fallback: a transient blip that// lands just after the 60s cache TTL must still preserve the last-known// integrations rather than collapse tool-calling to an empty set.- let connected = connected_with_fallback(- fetched,- cached_active_integrations(&config),- );+ let connected = connected_with_fallback(fetched, cached_active_integrations(&config));tracing::debug!(channel = %channel,target_agent = target_id,diff --git a/crates/openhuman-core/src/config/schema/load/parse_tests.rs b/crates/openhuman-core/src/config/schema/load/parse_tests.rsindex 7aebd913ca..caae8fa084 100644--- a/crates/openhuman-core/src/config/schema/load/parse_tests.rs+++ b/crates/openhuman-core/src/config/schema/load/parse_tests.rs@@ -103,20 +103,29 @@ fn a_non_finite_optional_float_is_rejected_not_unset() {#[test]fn legacy_cloud_provider_document_migrates_before_typed_decode_and_keeps_model() {- let config = config_from_toml_str(r#"+ let config = config_from_toml_str(+ r#"schema_version = 13[[cloud_providers]]id = "legacy-anthropic"type = "anthropic"default_model = "claude-sonnet-4"-"#).expect("legacy config parses");+"#,+ )+ .expect("legacy config parses");let provider = &config.cloud_providers[0];assert_eq!(provider.slug, "anthropic");assert_eq!(provider.label, "Anthropic");assert_eq!(provider.endpoint, "https://api.anthropic.com/v1");- assert_eq!(provider.auth_style, crate::config::schema::cloud_providers::AuthStyle::Anthropic);+ assert_eq!(+ provider.auth_style,+ crate::config::schema::cloud_providers::AuthStyle::Anthropic+ );let saved = toml::to_string(&config).unwrap();let reloaded = config_from_toml_str(&saved).unwrap();- assert_eq!(reloaded.cloud_providers[0].default_model.as_deref(), Some("claude-sonnet-4"));+ assert_eq!(+ reloaded.cloud_providers[0].default_model.as_deref(),+ Some("claude-sonnet-4")+ );assert!(!saved.contains("type = \"anthropic\""));}diff --git a/crates/openhuman-core/src/config/schema/local_ai.rs b/crates/openhuman-core/src/config/schema/local_ai.rsindex bc12e1b6a6..535131f943 100644--- a/crates/openhuman-core/src/config/schema/local_ai.rs+++ b/crates/openhuman-core/src/config/schema/local_ai.rs@@ -178,8 +178,6 @@ impl LocalAiConfig {pub fn is_active(&self) -> bool {self.runtime_enabled}--}impl Default for LocalAiConfig {diff --git a/crates/openhuman-core/src/core/runtime/services.rs b/crates/openhuman-core/src/core/runtime/services.rsindex de9e629364..bcb9f13a33 100644--- a/crates/openhuman-core/src/core/runtime/services.rs+++ b/crates/openhuman-core/src/core/runtime/services.rs@@ -160,7 +160,8 @@ pub fn spawn_login_gated_services(embedded_core: bool) -> tokio::task::JoinHandlif already_logged_in {// User has an active session — start all services now.log::info!("[services] existing session found, starting services");- crate::security::credentials::ops::start_credential_gated_services(&config).await;+ crate::security::credentials::ops::start_credential_gated_services(&config)+ .await;} else {log::info!("[services] no active session — deferring service startup until login"diff --git a/crates/openhuman-core/src/flows/tinyflows/caps/ops.rs b/crates/openhuman-core/src/flows/tinyflows/caps/ops.rsindex 16cf876594..17e0d18154 100644--- a/crates/openhuman-core/src/flows/tinyflows/caps/ops.rs+++ b/crates/openhuman-core/src/flows/tinyflows/caps/ops.rs@@ -237,18 +237,16 @@ async fn connected_toolkit_slugs(config: &Config) -> Option<Vec<String>> {let integrations = match fetch_connected_integrations_status(config).await {FetchConnectedIntegrationsStatus::Authoritative(v) => v,- FetchConnectedIntegrationsStatus::Unavailable => {- match cached_active_integrations(config) {- Some(v) => {- tracing::warn!(target: "flows", "[flows] connected-toolkit lookup: backend unavailable — using last-known (possibly stale) cached connections for the tool_call allowlist");- v- }- None => {- tracing::warn!(target: "flows", "[flows] connected-toolkit lookup: backend unavailable and no cached snapshot — connected-toolkit allowlist is empty this call");- return None;- }+ FetchConnectedIntegrationsStatus::Unavailable => match cached_active_integrations(config) {+ Some(v) => {+ tracing::warn!(target: "flows", "[flows] connected-toolkit lookup: backend unavailable — using last-known (possibly stale) cached connections for the tool_call allowlist");+ v}- }+ None => {+ tracing::warn!(target: "flows", "[flows] connected-toolkit lookup: backend unavailable and no cached snapshot — connected-toolkit allowlist is empty this call");+ return None;+ }+ },};Some(diff --git a/crates/openhuman-core/src/integrations/composio/connected_integrations.rs b/crates/openhuman-core/src/integrations/composio/connected_integrations.rsindex b5649f8e55..9076975655 100644--- a/crates/openhuman-core/src/integrations/composio/connected_integrations.rs+++ b/crates/openhuman-core/src/integrations/composio/connected_integrations.rs@@ -16,8 +16,7 @@ mod catalog_description_tests;pub(crate) use cache::sync_cache_with_connections;pub use cache::{- cached_active_integrations, connected_set_hash,- invalidate_connected_integrations_cache,+ cached_active_integrations, connected_set_hash, invalidate_connected_integrations_cache,};#[cfg(test)]pub(crate) use cache::{composio_cache_test_lock, composio_cache_test_lock_async};diff --git a/crates/openhuman-core/src/integrations/composio/mod.rs b/crates/openhuman-core/src/integrations/composio/mod.rsindex e5f8b28d7a..fa14274462 100644--- a/crates/openhuman-core/src/integrations/composio/mod.rs+++ b/crates/openhuman-core/src/integrations/composio/mod.rs@@ -69,9 +69,9 @@ pub use bus::{};pub use identity::connection_identity;pub use ops::{- cached_active_integrations, connected_set_hash,- fetch_connected_integrations, fetch_connected_integrations_status,- invalidate_connected_integrations_cache, FetchConnectedIntegrationsStatus,+ cached_active_integrations, connected_set_hash, fetch_connected_integrations,+ fetch_connected_integrations_status, invalidate_connected_integrations_cache,+ FetchConnectedIntegrationsStatus,};pub use schemas::{all_controller_schemas as all_composio_controller_schemas,diff --git a/crates/openhuman-core/src/integrations/composio/ops/mod.rs b/crates/openhuman-core/src/integrations/composio/ops/mod.rsindex 5eb1c209ca..1c0acebff4 100644--- a/crates/openhuman-core/src/integrations/composio/ops/mod.rs+++ b/crates/openhuman-core/src/integrations/composio/ops/mod.rs@@ -62,9 +62,9 @@ pub(crate) use user_scopes::{// (originally at the bottom of ops.rs)pub use super::connected_integrations::{- cached_active_integrations, connected_set_hash,- fetch_connected_integrations, fetch_connected_integrations_status,- invalidate_connected_integrations_cache, FetchConnectedIntegrationsStatus,+ cached_active_integrations, connected_set_hash, fetch_connected_integrations,+ fetch_connected_integrations_status, invalidate_connected_integrations_cache,+ FetchConnectedIntegrationsStatus,};// ── Type aliases re-exported for callers ──────────────────────────────────diff --git a/crates/openhuman-core/src/security/credentials/ops.rs b/crates/openhuman-core/src/security/credentials/ops.rsindex 4e4ffdfabb..45fdf1088e 100644--- a/crates/openhuman-core/src/security/credentials/ops.rs+++ b/crates/openhuman-core/src/security/credentials/ops.rs@@ -20,9 +20,7 @@ pub use credential::{clear_credential, clear_session, set_credential, store_session, SetCredentialRequest,PENDING_BACKEND_VALIDATION_FIELD,};-pub use gated_services::{- start_credential_gated_services, stop_credential_gated_services,-};+pub use gated_services::{start_credential_gated_services, stop_credential_gated_services};pub use provider_credentials::{list_provider_credentials, list_provider_credentials_by_prefix, remove_provider_credentials,store_provider_credentials,diff --git a/crates/openhuman-core/src/security/credentials/ops/gated_services.rs b/crates/openhuman-core/src/security/credentials/ops/gated_services.rsindex 2009f7e3bb..07233600ee 100644--- a/crates/openhuman-core/src/security/credentials/ops/gated_services.rs+++ b/crates/openhuman-core/src/security/credentials/ops/gated_services.rs@@ -221,4 +221,3 @@ pub async fn stop_credential_gated_services(config: &Config) {log::info!("[services] all login-gated services stopped");}-diff --git a/crates/openhuman-core/src/web_chat/web_tests.rs b/crates/openhuman-core/src/web_chat/web_tests.rsindex 91bb3cfbc8..d08eb51b90 100644--- a/crates/openhuman-core/src/web_chat/web_tests.rs+++ b/crates/openhuman-core/src/web_chat/web_tests.rs@@ -1,5 +1,6 @@use super::{- all_web_channel_controller_schemas, all_web_channel_registered_controllers, channel_web_cancel, channel_web_queue_clear, channel_web_queue_remove,+ all_web_channel_controller_schemas, all_web_channel_registered_controllers, cancel_chat_scoped,+ channel_web_cancel, channel_web_queue_clear, channel_web_queue_remove,channel_web_queue_status, classify_inference_error, drain_queued_turns_for_test,event_session_id_for, generic_inference_error_user_message, in_flight_entries_for_test,inference_budget_exceeded_user_message, is_inference_budget_exceeded_error, key_for,diff --git a/vendor/tinyagents b/vendor/tinyagentsindex d37c6a7255..bec1a33c89 160000--- a/vendor/tinyagents+++ b/vendor/tinyagents@@ -1 +1 @@-Subproject commit d37c6a725561b472e280fa069a10afc4c9540dfe+Subproject commit bec1a33c899cc6fe9eccd94441171950249830bb