DSH Session Manager
Permanent session deletion and folder-aware archive management for DeepSeek Harness Web UI.
[!WARNING] Deletion is permanent. This project is an unofficial community extension and currently supports only DeepSeek Harness
0.1.0-rc.6.
Features
- Adds Delete session to each session row's overflow menu, with an explicit irreversible-action confirmation.
- Adds an Archived panel to the sidebar.
- Groups archived sessions by their pre-archive workspace, with an archived-panel-only ungrouped fallback.
- Restores archived sessions to their original workspace grouping.
- Stops and drains the live Agent/Session before deleting durable data, preventing deleted conversations from reappearing in a new main-sidebar “Ungrouped” workspace.
- Removes the persisted session directory, projection cache, workspace membership, and archive membership.
Why three patches?
The original plugin needed two integration patches:
- P1 — workspace unarchive API: adds
WorkspaceRegistry.unarchiveSession(id). - P2 — session row menu slot: exposes a list slot for plugin-provided row menu items.
Deletion initially removed files and cache entries but could leave a live in-memory session. DSH would list that object again as ungrouped, and teardown could flush it back to storage. The fix therefore adds:
- P3 — owned Agent disposal: retains Agent lifecycle handles and exposes
AgentRegistry.dispose(id), allowing deletion to stop and drain the live Agent/Session before removing disk data.
The permanent-deletion order is now:
stop and drain live Agent/Session
-> delete persisted session directory
-> delete projection cache
-> detach workspace membership
-> remove archive membership
Compatibility
| Component | Supported version |
|---|---|
| DeepSeek Harness | 0.1.0-rc.6 |
| Platform installer | Windows PowerShell / PowerShell 7 |
| Manual installation | Other platforms, unverified |
The installer fails before making changes if package versions or patch contexts do not match.
Install on Windows
Close DSH, then run:
git clone https://github.com/6HOLLIS/dsh-session-manager.git
cd dsh-session-manager
pwsh -File .\scripts\install.ps1
If DSH is not discoverable in the npm npx cache, pass the node_modules directory explicitly:
pwsh -File .\scripts\install.ps1 -DshPackageRoot 'C:\path\to\node_modules'
Restart DSH after installation. The installer:
- verifies all affected package versions;
- dry-runs every patch before changing files;
- stores recoverable backups under
~/.dsh/backups/dsh-session-manager/; - installs the plugin in the web profile;
- records exact pre/post-install hashes in an install manifest.
Uninstall
Close DSH, then run:
pwsh -File .\scripts\uninstall.ps1
The uninstaller refuses to overwrite files changed after installation. Review those changes before using -Force.
Troubleshooting
- More than one compatible DSH install found: rerun the installer with the exact
-DshPackageRootshown in the error. The installer never guesses between multiple npx caches. - Version or patch check failed: this release only supports DSH
0.1.0-rc.6; do not force the patches onto another version. - Uninstall says a backup is corrupt or missing: do not use
-Force. It cannot bypass backup-integrity checks. Preserve~/.dsh/backups/dsh-session-manager/and restore from a known-good copy. - Uninstall says an installed file changed: inspect the local edit first.
-Forceonly permits replacing changed installed files after all backups pass integrity checks. - DSH still shows the old sidebar: fully close and restart DSH after installation or removal.
Manual installation
- Apply the three patches in
patches/dsh-0.1.0-rc.6/from the DSHnode_modulesdirectory. - Copy
plugin/to~/.dsh/profiles/web/dsh-session-manage/. - Add
"dsh-session-manage": "file:./dsh-session-manage"to the web profile dependencies. - Add
"dsh-session-manage"todsh.profile.bundles. - Link the plugin into
~/.dsh/profiles/node_modules/dsh-session-manage. - Restart DSH.
Test
npm ci
npm test
npm run check
pwsh -File .\tests\install-roundtrip.test.ps1
The installer round-trip test downloads pristine DSH 0.1.0-rc.6 npm packages into a temporary directory, installs the plugin, uninstalls it, and verifies that every original file hash is restored.
Repository layout
plugin/ DSH host and browser plugin
patches/dsh-0.1.0-rc.6/ minimal versioned vendor patches
scripts/install.ps1 guarded Windows installer
scripts/uninstall.ps1 hash-aware restoration
scripts/verify-patches.ps1 clean-package patch verification
tests/ deletion and installer regression tests
Upgrade notes
DSH upgrades replace patched vendor files. Do not apply these patches to a different version unless they pass review and clean-package verification. Uninstall this project before upgrading DSH, then wait for a compatibility update.
No comments yet. Be the first to write one.