Skip to content

Add confirmation prompt to workspace update action #557

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

blink-so[bot]
Copy link
Contributor

@blink-so blink-so bot commented Jul 17, 2025

This PR adds a confirmation prompt to the workspace update action to prevent accidental updates that could result in data loss.

Changes:

  • Changed from showInformationMessage to showWarningMessage to better indicate the destructive nature
  • Added explicit warning text: "Updating will restart your workspace and stop any running processes that may result in loss of unsaved data"
  • Added "Cancel" button to provide clear opt-out option

Testing:

  • Linting passes
  • Build completes successfully
  • One unrelated test failure in SSH support (pre-existing)

Fixes the issue where users accidentally trigger workspace updates without understanding the consequences.

Adds a warning dialog with explicit consent before updating workspace.
Includes warning text about workspace restart and potential data loss.

Co-authored-by: kylecarbs <[email protected]>
src/commands.ts Outdated
"Update Workspace",
{
useCustom: true,
modal: true,
detail: `Update ${this.workspace.owner_name}/${this.workspace.name} to the latest version?`,
detail: `Update ${this.workspace.owner_name}/${this.workspace.name} to the latest version?\n\nUpdating will restart your workspace and stop any running processes that may result in loss of unsaved data.`,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
detail: `Update ${this.workspace.owner_name}/${this.workspace.name} to the latest version?\n\nUpdating will restart your workspace and stop any running processes that may result in loss of unsaved data.`,
detail: `Update ${this.workspace.owner_name}/${this.workspace.name} to the latest version?\n\nUpdating will restart your workspace and stop any running processes that may result in loss of unsaved work.`,

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