@@ -177,7 +177,6 @@ def _spawn(self, operation_id: str) -> None:
177177 sys .executable , "-m" , "loopx.collaboration_mcp" , "--delegation-action" , "worker" , "--runtime-root" , str (self .root ),
178178 "--registry" , str (self .registry ), "--goal-id" , self .goal_id ,
179179 "--agent-id" , self .agent_id , "--execution-config" , str (self .config ), "--operation-id=" + operation_id ,
180- "--workspace" , _read (self .path (operation_id ))["identity" ]["binding" ]["workspace" ],
181180 ], stdin = subprocess .DEVNULL , stdout = subprocess .DEVNULL , stderr = subprocess .DEVNULL ,
182181 start_new_session = True , close_fds = True )
183182
@@ -305,6 +304,7 @@ def _execute(self, path: Path, row: dict, binding: dict) -> None:
305304 request_id = row ["identity" ]["request_id" ]
306305 common = ["--goal-id" , self .goal_id , "--agent-id" , binding ["agent_id" ]]
307306 host = binding ["host_args" ]
307+ # Preserve the journaled validator argv so existing Turns retain their resume identity.
308308 validator = [sys .executable , "-m" , "loopx.collaboration_mcp" , "--delegation-action" , "validate" , "--runtime-root" , str (self .root ),
309309 "--registry" , str (self .registry ), "--goal-id" , self .goal_id ,
310310 "--agent-id" , self .agent_id , "--execution-config" , str (self .config ),
@@ -407,7 +407,7 @@ def main():
407407 parser .add_argument ("--registry" , type = Path , required = True )
408408 parser .add_argument ("--goal-id" , required = True )
409409 parser .add_argument ("--agent-id" , required = True )
410- parser .add_argument ("--workspace" , type = Path , required = True )
410+ parser .add_argument ("--workspace" , type = Path , help = "Required when serving MCP; workers use their pinned binding" )
411411 parser .add_argument ("--execution-config" , type = Path , help = "Explicit operator-owned local execution bindings" )
412412 parser .add_argument ("--delegation-action" , choices = ["worker" , "validate" ],
413413 help = "Run a host-owned delegation action instead of serving MCP" )
@@ -426,6 +426,8 @@ def main():
426426 except LockAcquireTimeoutError :
427427 pass # Another worker still owns the operation after the bounded wait.
428428 return
429+ if args .workspace is None :
430+ parser .error ("--workspace is required when serving MCP" )
429431 create_server (
430432 args .runtime_root .resolve (),
431433 args .registry .resolve (),
0 commit comments