Skip to content

[fix][evaluation] await sandbox cleanup before experiment deletion - #690

Draft
bitholic wants to merge 1 commit into
mainfrom
fix/sandbox-lifecycle-source-cleanup
Draft

bitholic wants to merge 1 commit into
mainfrom
fix/sandbox-lifecycle-source-cleanup

Conversation

@bitholic

@bitholic bitholic commented Oct 15, 2026 •

Copy link
Copy Markdown
Collaborator

Deleting a SandboxAgent experiment could remove the experiment before its existing sandbox cleanup completed. Single and batch deletion now resolve the existing incomplete-item cleanup references and wait for the existing Destroy retry result before deleting. A lookup or cleanup failure returns an error and leaves the experiment undeleted.

The wait path reuses the existing ten-second retry budget. Existing non-deletion callers retain the default asynchronous cleanup behavior; the source-space routing and authorization remain unchanged.

Validation:

  • 57 related test/subtest passes across 14 top-level race-tested cases, with no failures or skips.
  • Combined compilation passed for the downstream agent-studio/evaluation modules and both service entrypoints using the isolated core changes.

@codecov

codecov Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 83.56164% with 12 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
...d/modules/evaluation/domain/service/target_impl.go 82.97% 5 Missing and 3 partials ⚠️
...ation/domain/service/expt_manage_execution_impl.go 75.00% 1 Missing and 1 partial ⚠️
...ules/evaluation/domain/service/expt_manage_impl.go 88.88% 1 Missing and 1 partial ⚠️

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #690      +/-   ##
==========================================
- Coverage   78.92%   78.91%   -0.01%     
==========================================
  Files         707      707              
  Lines       88041    88086      +45     
==========================================
+ Hits        69484    69515      +31     
- Misses      14575    14583       +8     
- Partials     3982     3988       +6     
Flag Coverage Δ
unittests 78.91% <83.56%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...ation/domain/service/expt_manage_execution_impl.go 83.90% <75.00%> (-0.15%) ⬇️
...ules/evaluation/domain/service/expt_manage_impl.go 66.94% <88.88%> (+0.37%) ⬆️
...d/modules/evaluation/domain/service/target_impl.go 84.81% <82.97%> (-0.46%) ⬇️

... and 2 files with indirect coverage changes


Continue to review full report in Codecov by Harness.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9f275be...67d08af. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@bitholic
bitholic force-pushed the fix/sandbox-lifecycle-source-cleanup branch from 9ed5741 to 67d08af Compare October 15, 2026 16:51
@bitholic bitholic changed the title [fix][evaluation] preserve sandbox cleanup on completion and deletion [fix][evaluation] await sandbox cleanup before experiment deletion Oct 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant