Replies: 2 comments
|
这个 Discussion 把 UI 缺口和更重要的 Host API 缺口分开了:archive 是可见性操作,不等于删除;在没有官方 delete transaction 之前,插件自行删 JSONL 或从 sidebar 移除都不能证明 Session 已安全删除。 我维护的独立 DeepSeek Harness 社区手册有一份对应的 Session archive/trash/delete runbook。在官方 primitive 出现前,建议社区实现至少按以下顺序验收:
如果未来增加 delete API,最好让它成为 Host-owned、带 writer coordination 和可审计结果的事务;UI 的 Rename/Fork/Delete 菜单只是 presentation,不应自行定义生命周期语义。手册为独立社区资料,不代表官方 DeepSeek AI 项目。 |
|
I reproduced the lifecycle failure behind this API gap against exact During a gated provider turn, the current Desktop/plugin sequence removed the Session from The exact versions, code chain, expected transaction, logs, and safe interim are documented in dsh-tauri-plugins #22. The safe conclusion for current plugins is to keep archive/unarchive but disable permanent deletion; a live-registry precheck alone is still racy with resume and cannot prove persistence writers have retired. A Host-owned cancel/quiesce/forget/delete transaction remains the maintainable seam. |
Uh oh!
There was an error while loading. Please reload this page.
Two small session-list UX gaps, plus a related API gap underneath them
1. No "Delete session" in the sidebar's per-session menu
The session row's
⋯menu currently has Rename / Fork session / Archive session. There's no Delete. Given Archive already exists and explicitly keeps the session on disk, Delete feels like the natural missing sibling for someone who actually wants a session gone, not just out of the way.2. Renaming a session takes two steps when it could take one
Today the only way to rename a session is
⋯→ Rename. A double-click on the row to jump straight into the rename dialog (same dialog, just one interaction instead of two) would match a pretty common pattern elsewhere (file managers, browser tabs, etc.).The underlying gap: there's no official "delete a session" primitive at all
While looking into (1), I found that
ISession(@deepseek-ai/dsh-client-runtime) only exposesprompt / cancel / rename / loadOlder / command / updateQueue— nodelete.ctx.workspaces.delete()only removes a workspace from the list (and explicitly keeps the folder and session logs). There doesn't seem to be any official client-side or host-side way to actually delete one session's files.Because of that, community session-manager plugins (e.g.
@dshwp/dsh-session-manager) each have to implement their own custom host route for this from scratch — checking whether the session is currently running, evicting it from memory if it's live, removing it from persistence, etc. That's real business logic that every third-party plugin wanting this feature has to reinvent independently, with no shared, tested implementation to lean on.Even if the two small UI additions above aren't a priority, an official
ISession.delete()(or an equivalent host endpoint) feels like it'd remove a chunk of duplicated, easy-to-get-subtly-wrong logic from the plugin ecosystem.Why a Discussion and not a PR
I put together a working local patch for both UI pieces (against the compiled
dsh-client-ui-workspacepackage, calling a plugin's existing delete route as a stopgap for the missing primitive) to validate the idea end-to-end, but I don't have the monorepo's real TypeScript source / build pipeline set up to turn that into something submittable — so this is more "here's a gap + a rough sketch of the fix" than a ready PR. Happy to share more detail on what I tried if it's useful.All reactions