fix: ensure AgentRun workspace root before hydration#2220
fix: ensure AgentRun workspace root before hydration#2220guslegend0510 wants to merge 2 commits into
Conversation
AgentScopeJavaBot
left a comment
There was a problem hiding this comment.
🤖 AI Review
This PR fixes issue #2216 where AgentRun sandbox hydration could fail with a tar extraction error because the workspace root directory was never created beforehand. The fix implements doSetupWorkspace() with a real mkdir -p + exit-code check, adds defensive ensureWorkspaceRoot() inside doHydrateWorkspace() for callers that bypass start(), and introduces an AgentRunExecutor inner interface to decouple AgentRunSandbox from the concrete AgentRunMcpChannel, enabling unit tests. The change is focused, well-tested, and consistent with patterns used in DaytonaSandbox and E2bSandbox.
(inline comments could not be attached — line numbers fell outside PR hunks. See archived report.)
AgentScopeJavaBot
left a comment
There was a problem hiding this comment.
🤖 AI Review
This PR fixes issue #2216 where AgentRun sandbox hydration could fail with a tar extraction error because the workspace root directory was never created beforehand. The fix implements doSetupWorkspace() with a real mkdir -p + exit-code check, adds defensive ensureWorkspaceRoot() inside doHydrateWorkspace() for callers that bypass start(), and introduces an AgentRunExecutor inner interface to decouple AgentRunSandbox from the concrete AgentRunMcpChannel, enabling unit tests. The change is focused, well-tested, and consistent with patterns used in DaytonaSandbox and E2bSandbox.
(inline comments could not be attached — line numbers fell outside PR hunks. See archived report.)
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Fixes #2216
Summary
Tests