Bug: cloud sandbox resume returns 409 when checkpoint is not yet available
Description
When a sandbox is suspended, attempting to resume it with agentuity cloud sandbox resume can return a 409 Conflict error if the checkpoint has not yet been fully created/persisted.
Steps to Reproduce
- Have a running sandbox that gets suspended
- Immediately attempt to resume it:
agentuity cloud sandbox resume sbx_<id> --org-id <org_id>
- Observe a 409 error response:
sessionId: 'sess_8a205f6491595ffb85ae1a54413bca86',
status: 409,
url: 'https://catalyst-usc.agentuity.cloud/sandbox/sbx_558180614bc2b3b361d940aefcf...'
Expected Behavior
The resume command should either:
- Wait/retry until the checkpoint is available before attempting to resume, or
- Return a clear, descriptive error message indicating the checkpoint is not yet ready (e.g., "Sandbox checkpoint is still being created. Please try again shortly."), or
- Implement a polling mechanism that waits for the checkpoint to become available before issuing the resume request
Actual Behavior
A raw 409 status code is returned with no indication that this is a transient/timing issue. The user has no way to know they should simply wait and retry.
Additional Context
- This appears to be a race condition: after a sandbox is suspended, it takes some time for the checkpoint to be fully persisted. If the resume is attempted before the checkpoint exists, the API returns 409.
- Trying another sandbox that had been suspended for longer worked fine, confirming it's a timing issue.
- The fix could be applied at the CLI level (retry logic with backoff), the API level (queue the resume until checkpoint is ready), or both.
Environment
- CLI command:
agentuity cloud sandbox resume
- Catalyst endpoint:
catalyst-usc.agentuity.cloud
Bug:
cloud sandbox resumereturns 409 when checkpoint is not yet availableDescription
When a sandbox is suspended, attempting to resume it with
agentuity cloud sandbox resumecan return a 409 Conflict error if the checkpoint has not yet been fully created/persisted.Steps to Reproduce
Expected Behavior
The resume command should either:
Actual Behavior
A raw 409 status code is returned with no indication that this is a transient/timing issue. The user has no way to know they should simply wait and retry.
Additional Context
Environment
agentuity cloud sandbox resumecatalyst-usc.agentuity.cloud