feat: add pause and resume buttons to sandbox detail controls#279
feat: add pause and resume buttons to sandbox detail controls#279devin-ai-integration[bot] wants to merge 1 commit intomainfrom
Conversation
Co-Authored-By: vasek <vasek.mlejnsky@gmail.com>
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 52724aac88
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| execute({ | ||
| teamIdOrSlug: team.id, | ||
| sandboxId: sandboxInfo.sandboxID, | ||
| timeout: 60, |
There was a problem hiding this comment.
Avoid forcing a 60s TTL on resume
The resume handler always sends timeout: 60, which makes every resumed sandbox expire after roughly one minute from the resume call instead of preserving its previous/session timeout. Because /sandboxes/{sandboxID}/connect treats timeout as the new expiry window from now, users resuming long-lived sandboxes can have them terminated almost immediately after resuming, which is a functional regression in normal pause→resume workflows.
Useful? React with 👍 / 👎.
Summary
Adds Pause and Resume buttons to the sandbox detail page controls, alongside the existing Kill button.
running— callsPOST /sandboxes/{sandboxID}/pausepaused— callsPOST /sandboxes/{sandboxID}/connect(the non-deprecated resume path)PlayIconSVG added to the icons librarypauseSandboxActionandresumeSandboxActionNeither pause nor resume has a confirmation dialog since both are non-destructive/reversible.
Review & Testing Checklist for Human
timeout: 60seconds. Verify this is the desired default, or whether it should match the sandbox's original timeout / be user-configurable.PausedIcon.Notes
/sandboxes/{sandboxID}/connectinstead of the deprecated/sandboxes/{sandboxID}/resumeendpoint. The connect endpoint also handles already-running sandboxes gracefully (200 vs 201).Link to Devin session: https://app.devin.ai/sessions/8de13379471347a09ce69176acd52c24
Requested by: @mlejva