DSH Plugins Marketplace

DSH Plugins

Plugins

/

dsh-neverdie

p

dsh-neverdie

Discovered

DeepSeek Harness (DSH) host plugin — auto-revives sessions whose turn was killed by a process exit ('Task stopped') after restart, and re-arms their active goals

Neverdie

Platform: DSH Host plugin License: MIT

Neverdie icon — a rising flame with a heartbeat cut out

Automatically revives DeepSeek Harness (DSH) sessions whose turn was killed by a process exit. When the host dies mid-turn, every session that was working ends up frozen behind a "Task stopped — The DSH process exited before this turn finished…" banner, dead until a human types something. Neverdie removes the human from that loop: after DSH restarts, the killed sessions come back to life on their own and keep working — and their active goals get re-armed so autonomous goal rounds continue.

Why

A DSH process that is killed, crashes, or times out during shutdown takes every running session down with it, and the cut-short turn shows up two different ways depending on how the process went:

  • Hard crash (SIGKILL, OOM) — the log ends inside an open turn; restart recovery synthesizes a turn/end closer with reason interrupted.
  • Graceful exit / restart — the dying process gets to close the running turn itself, as reason aborted with cause disposed; the aborted tool call leaves an "Error: tool call aborted" message as the visible tail of the conversation.

Either way the session sits idle, dead until a human types something — even though the durable session log, the workspace, and the model context are all intact. All the work was interrupted, not lost. Long-running jobs (overnight builds, multi-hour agent tasks, goal-driven rounds) deserved better than "click Send again in the morning".

Neverdie is a host-side Cordis plugin that scans once after every boot, finds exactly the sessions that were mid-turn when the previous process died, and re-prompts them with a short configurable message so the agent resumes where it stopped.

Features

  • Precise corpse detection — a session is revived only when the tail of its balanced log is a turn/end closed interrupted (hard crash) or aborted with cause disposed (graceful exit / restart). Deliberate stops (aborted cause user/parent/hook), sessions that ended normally, and sessions that already have newer input are never touched — matching on the abort cause rather than the visible "Error: tool call aborted" text is what keeps user-stopped sessions dead
  • Survives restart bookkeeping — the tail walker skips generation markers (e.g. session/end-seed) that DSH appends after a restart, and synthesizes the interrupted closers in memory for cold logs, so detection works whether or not the session was reopened first
  • Live-but-idle counts as dead — the reconnecting web client resumes a session's log without resuming its work; neverdie treats that idle state as a corpse too
  • Goal re-arm — goal activation is process-local, so the restart that killed the turn also disarmed the session's goal. Neverdie re-arms active goals through the supported goals.resume path, so automatic continuation rounds keep running. Paused, blocked, complete, or round-exhausted goals are respected as-is
  • Crash-loop guard — at most maxRevives consecutive neverdie revives per session since the last genuine user message; a host that keeps dying cannot burn tokens forever, and one real user message resets the budget
  • Auditable — every revive is a normal user message tagged with the merge-extensible source kind neverdie, visible in the transcript and countable from the session log, plus a [neverdie] line in the host journal

How it works

  1. The host process dies mid-turn. The plugin dies with it — nothing can act at the moment of death.
  2. Whatever supervises DSH (e.g. systemd Restart=on-failure) starts a new process; the plugin arms and waits delaySeconds for boot to settle.
  3. One scan: list sessions cheaply, then fully read the balanced log of each fresh, non-archived, root candidate.
  4. A backward walker finds the log's last turn end; only an interrupted one or an aborted-with-disposed-cause one, with no newer turn, message, or pending inbox input, qualifies.
  5. For each corpse: resolveAgent (resumes the cold session), re-arm its active goal if disarmed, queue the revive message, flush to durable storage.
  6. The agent continues the interrupted task. If the host dies again, the next boot repeats the cycle within the revive budget.

Configuration

OptionTypeDefaultDescription
enabledbooleantrueMaster switch
delaySecondsnumber10Wait after host start before the startup scan (0–600)
maxAgeMinutesnumber60Only revive sessions whose interrupted turn is younger than this (1–1440)
maxRevivesnumber5Max consecutive neverdie revives per session without genuine user input (0–10)
reviveMessagestring(see below)The message injected to revive a session
resumeGoalsbooleantrueRe-arm active-but-disarmed goals during revival

Default revive message:

[neverdie] The DSH process exited before the previous turn could finish, so that turn was closed. Continue the interrupted task from where it stopped. Tool calls that were cut off have unknown outcomes — inspect their effects before retrying them.

Notes & limitations

  • Restart must come from outside. Neverdie revives sessions after the host is back; it cannot restart the host itself. Pair it with a supervisor such as systemd (Restart=on-failure).
  • A literal empty prompt is not possible. The harness rejects whitespace-only prompt content, so revival sends a real (short, configurable) message instead.
  • Root conversations only. Subagent children are left to their parent sessions, which the parent's own revival reconciles.
  • Freshness bounded. Corpses older than maxAgeMinutes stay dead — raise the window if your host can be down for a long time.

License

MIT © pinion05

Comments

Loading…

Similar plugins

dsh-recovery-resume

by flandre2233

Auto-resumes DSH turns interrupted by a host restart

Tools & CapabilitiesDevelopment & InfrastructureSessions & MessagesManifest valid

★ 1

↓ 352/wk

MIT

JavaScript

Sep 24, 2026

dsh plugin --profile web add dsh-recovery-resume

by Eason-22

DeepSeek Harness plugin: restart without losing work, with an idle-aware graceful restart and automatic session resume after the host comes back. Built-in restart supports the Windows desktop app only

Tools & CapabilitiesTerminal & ClientsSessions & MessagesManifest valid

★ 2

MIT

JavaScript

Nov 9, 2026

dsh plugin --profile web add dsh-autorestart

by Harzva

Adds confirmed DSH restart actions and durable automatic continuation for eligible top-level sessions through an existing compatible dsh-restart Host provider.

Terminal & ClientsSessions & MessagesManifest valid

★ 0

MIT

JavaScript

Aug 29, 2026

dsh plugin --profile web add @harzva/dsh-restart-autoresume

by davidgereb

Restart your ongoing agent sessions once on server restart in DeepSeek Harness.

Manifest valid

★ 0

MIT

JavaScript

Aug 15, 2026

dsh plugin --profile web add dsh-plugin-watchdog

by 534056668

DeepSeek Harness plugin: a restart row in Settings -> General that ends the host gracefully and lets the systemd unit's Restart=always bring it back. No detached helper, so KillMode=control-group cann

Terminal & ClientsManifest valid

★ 0

MIT

JavaScript

Oct 25, 2026

dsh plugin --profile web add dsh-systemd-restart

by LucienLL

DeepSeek Harness plugin: restart/status of the DSH web service with a detached self-healing watchdog, second-confirmation, and login autostart

Manifest valid

★ 0

MIT

JavaScript

Oct 28, 2026

dsh plugin --profile web add dsh-service-watchdog