Skip to content

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

refactor(subagent): ignore extra fields in Incomplete status matches

Steven Enamakel2699c0684fba
diff --git a/crates/openhuman-core/src/agent/orchestration/delegation.rs b/crates/openhuman-core/src/agent/orchestration/delegation.rs
index 391d4d72d2..70ad0ea907 100644
--- a/crates/openhuman-core/src/agent/orchestration/delegation.rs
+++ b/crates/openhuman-core/src/agent/orchestration/delegation.rs
@@ -169,7 +169,7 @@ pub(crate) async fn run_subagent_delegation_with_parent_context(
checkpoint.is_some(),
));
}
- SubagentRunStatus::Incomplete { reason } => {
+ SubagentRunStatus::Incomplete { reason, .. } => {
return Err(format!(
"delegation stage {stage:?} stopped incomplete: {reason}"
));
diff --git a/crates/openhuman-core/src/agent/orchestration/ops.rs b/crates/openhuman-core/src/agent/orchestration/ops.rs
index 550d926cdc..44fbcf2826 100644
--- a/crates/openhuman-core/src/agent/orchestration/ops.rs
+++ b/crates/openhuman-core/src/agent/orchestration/ops.rs
@@ -542,7 +542,7 @@ impl AgentOrchestrationSession {
}
}
}
- SubagentRunStatus::Incomplete { reason } => {
+ SubagentRunStatus::Incomplete { reason, .. } => {
let message = format!("sub-agent stopped incomplete: {reason}");
let _ = status_tx.send(ChildState {
status: OrchestrationTaskStatus::Failed,
diff --git a/crates/openhuman-core/src/agent/orchestration/spawn_parallel/workers.rs b/crates/openhuman-core/src/agent/orchestration/spawn_parallel/workers.rs
index 527d42a7f8..6501726383 100644
--- a/crates/openhuman-core/src/agent/orchestration/spawn_parallel/workers.rs
+++ b/crates/openhuman-core/src/agent/orchestration/spawn_parallel/workers.rs
@@ -154,7 +154,7 @@ async fn run_one_parallel_task(
.as_ref()
.map(|path| path.to_string_lossy().to_string()),
),
- SubagentRunStatus::Incomplete { reason } => (
+ SubagentRunStatus::Incomplete { reason, .. } => (
ParallelAgentStatus::Incomplete,
false,
Some(reason.clone()),
diff --git a/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_execute.rs b/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_execute.rs
index e79698f40c..a5cde7a08e 100644
--- a/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_execute.rs
+++ b/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_execute.rs
@@ -495,7 +495,7 @@ impl SpawnAsyncSubagentTool {
.await;
}
}
- SubagentRunStatus::Incomplete { ref reason } => {
+ SubagentRunStatus::Incomplete { ref reason, .. } => {
// Async sub-agent stopped short (stuck halt / iteration
// cap). Mark the session finished and deliver the PARTIAL
// progress back to the parent, framed so it is not
diff --git a/crates/openhuman-core/src/agent/orchestration/tools/spawn_worker_thread.rs b/crates/openhuman-core/src/agent/orchestration/tools/spawn_worker_thread.rs
index 54f4bfdc25..402d1fd5d4 100644
--- a/crates/openhuman-core/src/agent/orchestration/tools/spawn_worker_thread.rs
+++ b/crates/openhuman-core/src/agent/orchestration/tools/spawn_worker_thread.rs
@@ -421,7 +421,7 @@ impl SpawnWorkerThreadTool {
})
)))
}
- crate::agent::subagent_host::SubagentRunStatus::Incomplete { reason } => {
+ crate::agent::subagent_host::SubagentRunStatus::Incomplete { reason, .. } => {
if owns_effects {
crate::agent::orchestration::subagent_events::publish_subagent_completed(
parent_session,
diff --git a/crates/openhuman-core/src/agent/subagent_host/ops_tests_slug_filter_typed_mode_tests.rs b/crates/openhuman-core/src/agent/subagent_host/ops_tests_slug_filter_typed_mode_tests.rs
index c0d47e6681..2bb848f828 100644
--- a/crates/openhuman-core/src/agent/subagent_host/ops_tests_slug_filter_typed_mode_tests.rs
+++ b/crates/openhuman-core/src/agent/subagent_host/ops_tests_slug_filter_typed_mode_tests.rs
@@ -227,7 +227,7 @@ async fn capped_no_progress_subagent_returns_incomplete_status() {
.expect("a cap halt is still Ok (not Err)");
match outcome.status {
- SubagentRunStatus::Incomplete { reason } => assert!(
+ SubagentRunStatus::Incomplete { reason, .. } => assert!(
reason.contains("limit") || reason.contains("tool-call"),
"incomplete reason should describe the cap stop: {reason}"
),