Repository navigation
Upgrade installer silently deletes a workspace that lives inside the install directory (Windows) #10160
Unanswered
AnceriseLeah
asked this question in
Q&A
Replies: 1 comment 1 reply
|
Adding the installer log, with absolute paths redacted. Timeline from the same machine (local time):
Nothing else touched Correction to the post: the retry count above is 10, not ~8. |
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Summary
Severity: permanent data loss — silent, unrecoverable, triggered by the normal upgrade path.
On Windows, upgrading to 0.2.1-rc.2 via the official installer permanently deleted a DSH workspace directory because that workspace happened to live inside the previous install directory. The app was fully closed during the successful upgrade — i.e. the normal, recommended flow (quit the app, run the installer). There was no warning, nothing went to the Recycle Bin, and the data is unrecoverable on an SSD with TRIM enabled.
A workspace is where users keep everything they create with DSH — documents, code, datasets, drafts. Losing it is not recovering from a bad cache; it is losing weeks of work.
Related: #8354 (same Windows installer, false "app cannot be closed" detection).
Environment
<InstallDir><Workspace>=<InstallDir>\work areaWhat happened
The previous version lived in
<InstallDir>(a user-chosen install location). A DSH workspace<InstallDir>\work areawas created and used inside it.A first upgrade attempt produced this log under
%LOCALAPPDATA%\@deepseek-aidsh-desktop-updater\installer-logs\directory-failure-<timestamp>.log:That attempt aborted (installer exit code 2) because DSH was still running. It matters for one reason only: it reveals the installer's upgrade strategy — rename the previous install root to
.old-{GUID}, then remove it.DSH was then fully quit, and the installer was run again. This time it succeeded and installed into
%LOCALAPPDATA%\Programs\DeepSeek Harness.Immediately before that successful run, the workspace still existed — the user confirmed it was intact while quitting the app. After the install,
<InstallDir>— including<Workspace>— was gone: with nothing holding the directory, the rename to.old-{GUID}succeeded silently and the renamed tree was then deleted. No.old-{GUID}remained, nothing appeared in the Recycle Bin, no restore point existed.Every session bound to that workspace then failed with:
and the app recreated
<Workspace>as an empty directory, so it presents as "my project is empty" rather than a loud error.Mechanism (from the project's own documentation)
apps/desktop/README.mddescribes the uninstall behaviour: an uninstaller started with--updatedor/KEEP_APP_DATA— "as electron-builder does for in-place updates and for replacing an older installation from another directory" — retains$DSH_HOME, and the native remover "refuses protected Windows folders and paths overlapping the installation or the home".So user data is protected in exactly one place:
$DSH_HOME(~/.dsh). Anything else that happens to sit inside the installation directory — here, the workspace — is inside the tree being removed, and no rule covers it.That is what makes this a data-loss bug rather than an installer quirk: the protection model covers the app's home directory, not the user's workspace, and nothing warns the user that the difference exists.
Impact
fsutil behavior query DisableDeleteNotify→0), so deleted blocks are already discarded by the drive.winfr/ Recuva find nothing.error: 5episode above is a failed attempt, not a precondition.Why it matters beyond one user
Suggested fixes (in rough order of value)
DeepSeek Harness.exe,resources/,locales/, …). Leave anything else in place.Reproduction outline
<InstallDir>on a non-system drive.<InstallDir>\work area, add files, run sessions.<InstallDir>is removed together with the workspace (no.old-*left behind, no Recycle Bin entry), and sessions in that workspace fail withworking-directory: directory does not exist.中文摘要
All reactions