Skip to content

Fix error handling in disk attach modal - #3346

Open
david-crespo wants to merge 1 commit into
form-loading-successfrom
split-disk-attach
Open

Fix error handling in disk attach modal#3346
david-crespo wants to merge 1 commit into
form-loading-successfrom
split-disk-attach

Conversation

@david-crespo

Copy link
Copy Markdown
Collaborator

Fixes two bugs found while doing #3345:

  1. Silent attach failure in the create-then-attach flow. In the unlikely event you create a disk from the storage tab and the subsequent attach call fails (e.g., the instance started in the meantime), there was no visible error: the error only rendered inside the attach modal, which isn't open anymore. You'd get the "Disk created" toast but the disk just wouldn't be attached. Now it shows an error toast.

  2. Stale error leaking between modal uses. In that failure scenario, the error stuck to the shared mutation, so the next time you opened the "Attach existing disk" modal, it displayed the old error from the create flow before you'd done anything. Now the attach modal's mutation is its own, created fresh on each open.

Moving the mutation inside its own component means we don't have to do reset()s to avoid holding onto state across different openings of the attach modal.

@vercel

vercel Bot commented Aug 21, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
console Ready Ready Preview Aug 21, 2026 10:21pm

Request Review

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