Skip to content

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

feat(memory): defer import resume when peer run holds workspace

Steven Enamakel2c1a41114aee
diff --git a/crates/openhuman-core/src/memory/import.rs b/crates/openhuman-core/src/memory/import.rs
index ac10d3e1a1..1fd494a851 100644
--- a/crates/openhuman-core/src/memory/import.rs
+++ b/crates/openhuman-core/src/memory/import.rs
@@ -273,6 +273,19 @@ async fn launch(
started: false,
});
}
+ if paused.is_some() {
+ // An automatic resume that meets a peer run (layout migration or
+ // conversation backfill) defers: the checkpoint stays resumable
+ // and the next resume attempt retries, instead of recording the
+ // contention as a failed resume.
+ tracing::debug!(
+ "[memory:import] peer run holds the workspace; deferring the interrupted-import resume"
+ );
+ return Ok(LaunchOutcome {
+ state: status(config),
+ started: false,
+ });
+ }
let action = match mode {
Mode::Import => "import",
Mode::Retry | Mode::ResumeRetry => "retry",