dsh-session-delete
Manifest validDelete sessions from the DeepSeek Harness Web sidebar: a menu action plus a confirmation dialog that removes the session log.
dsh-session-delete
Adds the missing Delete session action to the DSH Web sidebar.
Each Session's "…" menu gains a red Delete session row (order 500, after archive). Choosing it opens a confirmation dialog; confirming permanently removes that Session's local data and drops the row from every connected page.
Install
git clone https://github.com/The932/dsh-session-delete
dsh plugin --profile desktop add "link:<repo path>"
Or point the Harness Plugin Manager at the cloned directory (Add → install from
a local package directory) and enable the dsh-session-delete bundle. Restart
the Harness once after installation; then refresh the page if the row does not
appear immediately.
Requirements: the Web profile (dsh Desktop or a Web build) with the shipped
Session Controller, Workspace and Locale plugins — that is the default
composition. Developed and tested on Windows with the Desktop build.
What is deleted
| Data | Location |
|---|---|
| Session log | <sessionPersistence.root>/<project-encoding>/<sessionId>/ (the whole directory) |
| Cached view state | <DSH_HOME>/storages/session_projcache/sessions/<sessionId>.json[*] |
Nothing else is touched. Workspace ordering, pin and archive sets may keep the old id; they are id sets and simply skip an id with no Session.
Behavior
- The action is for the user only. The agent gets no tool for it: deletion is irreversible, so it stays behind an explicit confirmation.
- A running Session is refused with a message; stop it first.
- A Session that is still live in this Host process (for example one opened in this run) is removed from the list immediately, and its log directory is deleted as soon as the Host can release it. A durable tombstone retries every 15 seconds and once more on the next start.
- After a successful delete the sidebar row disappears through the shipped
api-session/removedrelay, and the conversation panel is cleared when it was showing that Session.
Endpoint
POST /dsh-session-delete/api with {"sessionId": "..."}, same-origin, gated by
ctx.connection.requestRejection() (fails closed when the trust fence is
unavailable). Session ids are validated against
^[A-Za-z0-9][A-Za-z0-9._-]{0,199}$ before any path is built, and every removal
is confined to a <root>/<one-level>/<id> path.
Tests
node tests/core.test.mjs
node tests/host.test.mjs
core.test.mjs exercises the storage logic against temporary directories:
identity validation, directory discovery, selective removal, the projection
cache, the outside-the-root refusal, and the tombstone document. host.test.mjs
drives the real request handler through a fake Cordis context: the trust fence,
the request body, every refusal code, storage deletion, tombstone cleanup, the
deferred sweep on activation, and the forwarded removal event.
Run the files directly — node --test spawns child processes, which the
workspace sandbox blocks.
Files
index.js— Host half: the authenticated endpoint and the deferred sweep.client.js— browser half: the menu row, the dialog, and the styles.core.js— path-safe storage operations, shared with the tests.cordis.patch.yml— the bundle patch that inserts the Host row.
Comments
Loading…
Similar plugins
by reverse-PAI
Permanently delete a DeepSeek Harness session: a sidebar session-row "..." menu item plus a hover button, a risk-consent dialog, and an authenticated Host route that removes the session log, its projection-cache row and its archive mark.
★ 1
MIT
JavaScript
Oct 19, 2026
dsh plugin --profile web add dsh-minimal-session-deleteA plugin for DeepSeek Harness (DSH) that adds a permanent "Delete session" action to the sidebar session menu
★ 0
Apache-2.0
JavaScript
dsh plugin --profile web add dsh-delete-sessionsby txlznbzsdj-collab
Adds a "Delete" item to the sidebar session menu with a confirmation dialog, then hard-deletes the session.
★ 0
↓ 283/wk
JavaScript
Aug 18, 2026
dsh plugin --profile web add dsh-session-deleteby jerrywang21-debug
Sidebar delete action for the DeepSeek Harness (DSH) web client: removes a conversation from the Harness and moves its log + projection cache to the system Trash.
★ 0
MIT
JavaScript
Oct 7, 2026
dsh plugin --profile web add @jerrrrrywang/dsh-session-deleteby DDDMUC
Delete sessions from the DSH Web sidebar: adds a Delete action to the session row menu with a risk-consent dialog, then removes the session log, workspace accounting and live session state.
★ 20
↓ 229/wk
MIT
JavaScript
Oct 28, 2026
dsh plugin --profile web add dsh-delete-sessionby rhl88
Deletes a session from the sidebar session menu after a confirmation dialog, removing its log directory, projection-cache record and workspace/pin/archive accounting; registry calls are timeout-guarde
★ 0
MIT
JavaScript
Oct 13, 2026
dsh plugin --profile web add dsh-session-remove