fix: archive workspace without delete dialog or dropping DB rows - #394
Open
Ziinc wants to merge 4 commits into
Open
fix: archive workspace without delete dialog or dropping DB rows#394Ziinc wants to merge 4 commits into
Ziinc wants to merge 4 commits into
Conversation
Archiving now forgets the jj workspace and removes the directory while keeping the local.db record marked archived. Sidebar archive actions no longer reuse the delete confirmation flow. Co-authored-by: ty <ty@tzeyiing.com>
Use jj-lib to assert forgotten workspaces, cargo-fmt local_db helpers, and add a screenshot spec for the archive success toast. Co-authored-by: ty <ty@tzeyiing.com>
Contributor
|
🚀 Web preview: https://preview-394.treq-9zy.pages.dev |
Co-authored-by: ty <ty@tzeyiing.com>
Co-authored-by: ty <ty@tzeyiing.com>
Ziinc
marked this pull request as ready for review
August 30, 2026 18:41
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Sidebar Archive Workspace (and bulk archive) previously reused the delete-workspace confirmation and
delete_workspacecommand, which removed the SQLite row.Archive now:
.treq/workspaces/…workspacesrow witharchived = 1get_workspaces/ sidebaraskis not called)sync_workspacesfrom pruning archived records (they are excluded from the active list)True Delete Workspace (command palette / header menu) is unchanged.
Test plan
cargo test --manifest-path src-tauri/Cargo.toml --test core_workspaces_archive_workspace_testcargo test --manifest-path src-tauri/Cargo.toml test_archive_workspace_keeps_db_entry --libtest/integration/sidebar.test.tsxarchives via context menu, asserts no delete dialog, directory gone,archived=1in sqlitescripts/screenshot/specs/workspace-archive-no-delete-dialog.spec.tsx(toast “Workspace Archived”, workspace row gone, no delete dialog)