Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

Merge remote-tracking branch 'upstream/main' into main-health-7523

Steven Enamakeld936289866ac
diff --cc crates/openhuman-core/src/modules/connectors.rs
index 2452d53fb6,7d0b3e38b9..86acbba97b
--- a/crates/openhuman-core/src/modules/connectors.rs
+++ b/crates/openhuman-core/src/modules/connectors.rs
@@@ -64,15 -64,24 +64,36 @@@ pub use names::methods
/// loudly rather than silently downgrading to the other route, which would send
/// a user's requests somewhere they did not choose.
pub fn module_config(config: &Config) -> Result<serde_json::Value, String> {
- let mut payload = route_config(config)?;
+ module_config_with_proxy(config, &crate::config::runtime_proxy_config())
+}
+
+/// [`module_config`] against an explicit proxy policy rather than the
+/// process-global runtime one.
+pub(crate) fn module_config_with_proxy(
+ config: &Config,
+ proxy: &crate::config::schema::ProxyConfig,
++) -> Result<serde_json::Value, String> {
++ let mut payload = route_config(config, proxy)?;
+ payload["offered_toolkits"] = offered_toolkits(config);
+ Ok(payload)
+ }
+
+ /// The host's offered-toolkit policy as the module reads it
+ /// (`tinyconnectors_bus::vocabulary::OfferedToolkits`). Also the whole load
+ /// blob when no route can be named, so the policy still applies to the
+ /// capability listings of a signed-out module.
+ #[must_use]
+ pub fn offered_toolkits(config: &Config) -> serde_json::Value {
+ serde_json::json!({
+ "allow": config.composio.offered_toolkits_allow,
+ "deny": config.composio.offered_toolkits_deny,
+ })
+ }
+
-fn route_config(config: &Config) -> Result<serde_json::Value, String> {
++fn route_config(
++ config: &Config,
++ proxy: &crate::config::schema::ProxyConfig,
+) -> Result<serde_json::Value, String> {
let state_dir = config.workspace_dir.join("state");
// A host-pinned credential outranks the mode and the credential store, the
diff --cc scripts/ci/process-statics.json
index 5f5ffc9038,a993635381..bdea1d2a6f
--- a/scripts/ci/process-statics.json
+++ b/scripts/ci/process-statics.json
@@@ -1,12 -1,22 +1,32 @@@
[
+ {
+ "file": "crates/openhuman-core/src/mcp/module_client.rs",
+ "scope": "",
+ "name": "LIFECYCLE_GATE",
+ "type": "tokio::sync::Mutex<()>",
+ "count": 1,
+ "category": "A",
+ "reason": "Serializes TinyMCP open/close transitions, which the module admits one at a time process-wide; it guards no data and carries no tenant state.",
+ "verification": "mcp/module_client_tests.rs: concurrent_workspaces_open_one_at_a_time_through_the_module_lifecycle_gate"
++ },
+ {
+ "file": "crates/openhuman-core/src/tinymemes/callbacks.rs",
+ "scope": "",
+ "name": "REGISTRY",
+ "type": "LazyLock<Mutex<HashMap<String,Entry>>>",
+ "count": 1,
+ "category": "B",
+ "reason": "Keyed by a random per-remix correlation id; each entry holds the registering caller's config, CoreContext and memory identity, which every callback re-enters. Callbacks are accepted only from the module peer (bus name owner) for a live id, and the entry is retired by End, a failed call, or an age sweep.",
+ "verification": "tinymemes/service_tests.rs: only_the_module_may_call_back_and_only_for_a_live_remix; tinymemes/callbacks_tests.rs: callbacks_run_as_the_identity_that_registered_the_remix"
+ },
+ {
+ "file": "crates/openhuman-core/src/tinymemes/service.rs",
+ "scope": "",
+ "name": "FOREGROUND",
+ "type": "std::sync::LazyLock<std::sync::Mutex<std::collections::HashMap<String,std::sync::Arc<tokio::sync::Mutex<()>>>>, >",
+ "count": 1,
+ "category": "B",
+ "reason": "Holds only unit mutexes. The key is the workspace directory plus the acting memory identity, so different scopes never share or wait on a lock and no tenant data is stored.",
+ "verification": "tinymemes/service_tests.rs: foreground_remixes_share_a_lock_per_workspace_and_never_across_workspaces"
}
]