deniz.in

Markets

Weather

Loading weather

· via Vercel blog

Vercel open-sources durable-harness to keep coding agents alive after crashes

Vercel's new open-source durable-harness package brings crash recovery to coding agent harnesses like Claude Code, Codex, OpenCode and Pi, so long-running agent turns can resume on the platform or on self-hosted infrastructure.

Vercel open-sources durable-harness to keep coding agents alive after crashes

Vercel ships durable-harness for crash-proof coding agents

On 20 October 2026, Vercel released durable-harness, an open-source package that adds crash recovery to coding agent harnesses such as Pi, OpenCode, Codex and Claude Code. According to the Vercel blog, the package reuses the machinery behind the company's Workflow SDK, so an agent turn interrupted by a crashed function or a timeout can be handed to a fresh function and continued. Vercel's own harnesses, eve and fx, already run this way; the new package extends the same guarantees to third-party harnesses without modifying them.

Why cloud harnesses break

Most developers still run coding agents on their own machines, and as the Vercel blog points out, keeping an agent at work around the clock means keeping a laptop open and awake — the constraint behind the laptop-lid jokes and the run on Mac minis as always-on agent machines. Harness workloads are nonetheless moving to the cloud: individuals deploying persistent agent workflows, projects like OpenWork and HanaAgent using open-source harnesses as engines, and engineers building harness products of their own.

Durability is the missing piece. Locally, a harness sits beside its workspace and session history on the same disk, so resuming interrupted work is just another prompt. A cloud VM with persistent storage can imitate that layout, but per Vercel it tracks neither which model and tool calls already completed nor how to resume a turn cut off mid-flight, so a failed call or network error loses the work. Vercel also notes that not every agent task needs a sandbox — database queries and API calls can run in functions, keeping credentials out of the sandbox entirely.

Logs, queues and Worlds

durable-harness records each step of a turn in a durable log: before a model or tool call executes it writes an intent, and once the call finishes it writes the outcome. Every turn is also backed by a queue message, so if its function dies, the queue passes the turn to a replacement function that reads the log and carries on.

The payoff, as Vercel describes it:

  • Finished calls never repeat — results are read from the log, so a completed model call is not billed a second time.
  • The model keeps its memory of earlier calls instead of redoing them.
  • Interrupted tools flagged as replay-safe run again automatically; anything else comes back to the model as possibly run, and the model decides whether to verify.
  • Harnesses with their own session records — Claude Code's transcript, Codex's rollout, OpenCode's event store — have those records mirrored into the log, so a new function or Sandbox can rebuild the session.

The log, queue and streaming machinery sit behind a single interface Vercel calls a World. On Vercel the default is the Vercel World; in local development it is plain files; on your own servers it can be Postgres, MongoDB, Redis or Turso. Vercel says redirecting every durable-harness agent to Postgres takes two environment variables.

Tools declare their own replay rules

Every tool handed to an agent specifies what happens if a crash interrupts it. A read-only lookup can be marked safe to run again; a refund or a pull-request comment can be marked never, meaning it will not execute twice — the model is instead told the call may already have happened so it can check first. In Vercel's example of an agent adding a pricing page, file reads and CI status checks are safe, while PR comments are never, which prevents duplicate posts.

File handling without a VM

Vercel cautions against running shells and file operations directly on a shared serverless host, since several sessions can share one function and its filesystem is not guaranteed to persist between invocations. durable-harness offers alternatives: a virtual filesystem stored inside the session log, paired with a bash-compatible shell that cannot reach the host's files or the network, suited to short tasks and small workspaces; an in-memory variant wiped at the end of each turn for scratch work; and a dedicated Vercel Sandbox per session for heavier jobs.

Watching resumed sessions

Vercel's Agent Runs view shows a trace for each session, covering every model and tool call. Turns that resumed after a crash land in the same trace, making it visible where work stopped and where it picked back up.

Why it matters

Reliability is what separates agent demos from agents trusted with unattended work, and durable-harness treats durability as a wrapper concern rather than something every harness must reimplement. Two details stand out. On cost, replaying completed calls wastes tokens, and deduplicating them from a log removes that penalty — a direct saving for anyone running hours-long agent tasks. On lock-in, the package is a Vercel product but the World abstraction targets Postgres, Redis, MongoDB and Turso, so the same agent can be self-hosted with modest configuration. The broader signal is that agent harnesses are becoming infrastructure, with crash recovery shifting from a differentiator to a baseline expectation.

  • #vercel
  • #coding-agents
  • #open-source
  • #developer-tools
  • #cloud

Related posts