A Crash Is the Loud Failure: The Retried Tool Call Is the Silent One
For the solo founder or small-team operator — or the one platform engineer — putting an agent into production against real systems: payments, ticketing, email, GitHub, internal records. Anyone evaluating a managed or "durable" agent runtime precisely because it survives crashes, and who reads "survives crashes" as "reliable." This piece is about the half of that promise the runtime cannot keep for you.
---
The first screen: the pitch is "survives crashes," and the vendor's own docs say a tool can run twice
Mistral opened Managed Agents and the Agents SDK in public preview in November 2026. The one-line pitch is the operator's dream: "Build autonomous agents that work for hours or days, survive crashes and stay under your control." The launch framing is sharper still — your agent in prod at 3am: crashes silently. Managed Agents are built for that part. (Mistral Docs, Agents; Mistral, Build with Studio.)
Durability here is real and it is at step granularity. Deploy the agent and the session lives server-side, so "each finished model call and tool call is recorded, and the session outlives the worker. When the worker stops during a turn, the turn usually resumes from its last finished step once a worker is back." Your app can exit and come back for the result; an approval waits an hour by default and outlives the process that asked for it. You host no database. (Mistral Docs, Run modes.)
Now read the section of the same page titled "What durability buys you," because it names the other half in two sentences:
"Work that was running when the worker stopped has an unknown outcome. A model call is made again. A tool call is not: about a minute later the model gets an error for it, and it may call the tool again. So a tool with side effects can run twice, and must be idempotent: a repeated call with the same input has the same effect as one call. A hook can run again too, so keep hooks idempotent."
And it pre-empts the obvious fix on the same page: "A plain 'was this done?' check is not enough: two calls running at once can both pass it." (Mistral Docs, Run modes.)
Read those two artifacts together and you have the whole piece. The vendor selling "reliable production agents" is the same source stating that its durability can double an external effect — a refund sent twice, a ticket opened twice, an email fired twice — and that the naive guard against it does not hold. The crash is the loud failure you fear and can see. The re-driven tool call is the quiet one the feature introduces, and the more reliable the runtime becomes, the more the failure moves into the quiet half.
By the end you have two things you can use before you deploy:
- The reframe.* "Survives crashes" is a claim about uptime, not about effects. Durable execution guarantees a step is observed once, never that it executed* once. That is not a Mistral defect — it is the definition of at-least-once, and Temporal says the same in its own docs. Uptime was solved for you; exactly-once side effects were handed to you.
- The repeatable-side-effect audit.** A per-tool classification — read-only, idempotent write, non-idempotent write — with a specific action for each, plus one rule for verifying an effect happened once when the agent's own session record is not a reliable witness.
Here is where we are going:
- The claim as operators repeat it** — and the two mistakes it hides.
- What the evidence actually says** — the mechanism of at-least-once recovery, and why the obvious fix fails.
- Where the claim is right, and where it falls apart** — including the part that is genuinely good news.
- A better version of the claim** — uptime was solved; effects are yours.
- What changes if you act on it** — the repeatable-side-effect audit, run per tool.
---
1. The claim as operators repeat it
The claim arrives in two forms, and both are the same mistake wearing different clothes.
The first form: "it's a managed runtime, so production is handled." You are choosing between running your own worker and letting the vendor run it. You read "survives crashes," "session outlives the worker," "approvals wait an hour while your process is closed," and you conclude that the operational burden of a long-running agent is now someone else's problem. The obvious move is to deploy with the defaults and move on.
The second form: "if the run recovered, it's fine." A turn crashed overnight. You come back, the session shows the turn resumed from its last finished step, the history reads complete, the job finished. You conclude the run happened once. The obvious move is to trust the recovery.
Name the mistake precisely: the operator reads "durable" as "safe," and reads a recovered session as proof that each step ran exactly once. Both readings are correct observations of what the runtime promises — and both answer a different question than the one that decides whether you have a duplicate charge on your hands.
The gap is not hidden. It is in the vendor's own documentation, in the sentence that tells you to make your tools idempotent. The reason it stays invisible is structural: the failure it produces does not announce itself. A crash logs an error. A duplicate refund, a double-sent email, a second ticket — those succeed. There is no stack trace for "it happened twice."
2. What the evidence actually says
Start with the mechanism, because everything follows from it and it is not specific to Mistral.
Durable execution gives at-least-once, never exactly-once, for steps with external effects. The runtime can only record a step as finished after it returns and reports back. A crash between "the effect happened on the outside world" and "the result was saved" leaves a step with an unknown outcome — and recovery re-drives it. Temporal, the system that defined the category, states it exactly: "Temporal guarantees that the Activity will be observed as completed exactly once. However, the Activity may be executed multiple times and may even partially complete more than once during this process ... If an Activity fails to report to the server at all, it will be retried." (Temporal Docs, Activity Definition.) Temporal's own worked example for this is duplicate charges in payment processing, avoided with idempotency keys enforced by the called service. (Temporal Docs, Durable execution.)
Mistral's page is the same property, in product language: work in flight at the crash has an unknown outcome, a model call is simply made again, and a tool call is not automatically re-made — the model gets an error and may call the tool again. "So a tool with side effects can run twice, and must be idempotent." (Mistral Docs, Run modes.)
This is not one vendor's quirk. The same guidance is shipping across the durable-agent tool class. A Mastra docs commit adds a "Make tools safe to repeat" section describing exactly this — a tool or workflow step "can run again if a worker stops before saving its result," recovery "re-issues LLM calls and re-executes tool calls, so tools must be idempotent," and the worked example is "sending the same refund twice." (Mastra commit 9d1fc55.)
Why more persistence cannot fix it. The tempting conclusion is that the runtime should just save the result sooner. It cannot, and the reason is the whole point: you cannot persist a fact before it is true. The record can only be written after the effect returns. Any window between the effect landing in the outside world and the record landing in the store is a window where a crash produces an unknown outcome. That window cannot be closed from the runtime side. It is closed from the tool side — by making the operation safe to run twice — which is exactly why the requirement lands on you.
Why the obvious guard fails. The natural fix is a check: before charging the card, look up whether this charge already happened. Mistral's docs rule it out in one line: "A plain 'was this done?' check is not enough: two calls running at once can both pass it." (Mistral Docs, Run modes.) A read-then-write check has a race: both the original attempt and the recovery can read "not done," both proceed, and you get two effects. The fix has to be atomic — a real idempotency key derived from the request (the order id for a refund) and enforced by the called service, or a unique constraint in a store that lets only one insert win. Anything a tool keeps in the worker's own memory is lost with the worker, which is the very thing that crashed.
And the gate that would catch the retry is open by default. The permission model has a permission_mode, and the default is "auto", which "follows the permission_policy, or runs when the Agent has none." With no policy attached, every tool call the model decides to make executes without approval. (Mistral Docs, Approvals.) Mistral's own example pattern — auto-approve read-only calls, route everything else to a person — is a pattern you adopt, not what ships out of the box. So the same convenience that makes the first call frictionless makes the retry frictionless too, which is precisely the call that should have stopped for a human.
3. Where the claim is right, and where it falls apart
Be fair to the pitch, because most of it holds.
Where "it's a managed runtime" is right. Crash recovery is real, and it is a genuine advance. An overnight job now survives a worker restart; the session outlives the app that started it; an approval waits an hour while your process is closed; you host no database. That is the easy half of production agents, and it is finally solved — by the vendor, for you. The claim is not a misreading of durability. It is a correct reading of durability used to answer a question durability cannot answer.
Where it falls apart. "Durable" is a claim about the session, not about effects. Every operator who reads it as "production is handled" is pricing one guarantee — the agent stays up — and silently taking on a second one the runtime explicitly does not provide: that an effect happened exactly once. The reflex that follows — deploy with the defaults, trust the recovery — moves your reliability work to exactly the place it cannot be delegated. And the failure it produces is the quiet one, because a duplicated side effect raises no error.
Where "if it recovered, it's fine" is right. The recovery is not fake. The turn usually does resume from its last finished step, and the finished steps really did finish. The session record is accurate about what it recorded.
Where it falls apart. The session record is not a witness to what happened outside it. A step with an unknown outcome may have run on the outside world and not be recorded as finished. Worse, the record can be actively misleading in a different direction: Mistral's docs note that a refused or denied call is compiled to a skipped hook that writes no tool_call and no tool_result entry — "so list_history() does not show that a call was refused." (Mistral Docs, Approvals.) Read that together with the unknown-outcome step and you get the rule: "read the session and confirm it ran once" is not a verification path. A call that never ran and a call whose outcome is unknown can both be absent or error-only in history. The external system is the only honest witness.
Three honest gaps in the evidence, named because they bound how far you can push this:
- No source here shows a duplicate charge, ticket, or email actually happening in production on any of these systems.* The double-effect is a documented structural hazard and a canonical worked example (Temporal's payment scenario, Mistral's and Mastra's vendor warnings) — not an observed incident with a post-mortem. Treat it as a failure mode the design permits*, not a report of one that happened.
- This is not an "AI vendor messes up" story.* The idempotency requirement is Mistral handling the problem responsibly and pushing it to the operator, and its other defaults fail closed — an agent has no code execution unless you give it an environment, and the unisolated local sandbox needs an explicit opt-in. The point is that the requirement exists for any* durable runtime, not that this one is worse.
- The exact launch date is unconfirmed, and the product is in public preview.** Secondary coverage gives two different November 2026 dates, and the docs state the API, behavior, and limits can change and "an update can require changes to your code." Any specific default — the permission mode, timeout values, idempotency behavior — may move before GA. The product and its documented behavior are the load-bearing evidence, not the birthday.
4. A better version of the claim
The popular claim is about reliability: the managed runtime makes production reliable.
The version the evidence supports is about two different problems: durability solves uptime; it does not solve exactly-once effects. A durable runtime can guarantee that a crashed turn resumes and that each step is observed exactly once. It cannot guarantee that a step with an external effect executed exactly once — because it cannot record the result before the effect exists, and the window between the two is where the duplicate is born. Uptime is now the vendor's problem. Effects are yours.
That reframe has a rule attached, and the rule is the point: "recovered" means "resumed," never "ran once." Stop reading a durable runtime as a safety guarantee; start reading it as a persistence guarantee — the thing that makes the agent stay up — and treat every externally-effecting action as something you must make safe to repeat, or gate.
This is not the same argument as "durable execution is broken," and it is worth saying why, because the two get confused. At-least-once is the correct design for the category — you cannot do better without the ability to save a fact before it is true. The lesson is not to avoid durable runtimes; it is that the reliability you bought is not the reliability you need for side effects, and the second one has to be built. And it is not the same argument as "the GUI lost the contract" — that piece (clicking-is-not-calling) is about the interface between an agent and a screen, where idempotency is one guarantee a click discards. This piece is about the runtime that resumes a crashed turn and turns a visible crash into an invisible duplicate. Different actor (the runtime, not the screen), different failure (at-least-once re-drive, not end-state drift).
5. What changes if you act on it: the repeatable-side-effect audit
Here is the reusable object. Run it per tool — not once for the whole agent — because what you are classifying is an action, not a runtime. Do it before you deploy, and re-run it whenever you add a tool.
Step 1 — Classify each tool by what it does to the outside world.
- Read-only.** The tool fetches, queries, or looks something up and changes nothing. It is safe to run twice by construction. This is the one class worth keeping auto-approved — a repeated read costs you a few tokens, not a duplicate.
- Idempotent write.* The tool changes state, but a repeat with the same input lands in the same place — an upsert keyed on an id, a "set status to X," a "create-or-update." It is nearly* safe, and step 2 makes it actually safe.
- Non-idempotent write.* The tool's effect accumulates* on repeat: charge, pay, send, post, delete, provision, increment. A second call with identical input produces a second effect. This is the class that turns a recovered turn into a duplicate.
Step 2 — Put a real key on the idempotent and non-idempotent writes. The key must be derived from the request (the order id for a refund, the invoice id for a payment, a hash of the message for an outbound send) and enforced by the called service, or recorded in a store with a unique constraint where only the first insert wins. Two rules that make or break this:
- The check must be atomic.** A read-then-write "was this done?" check is not enough — two calls running at once can both pass it. Use the service's own idempotency key, or a unique constraint that rejects the second insert, so the race resolves to one effect no matter how the two calls interleave.
- The key cannot live in the worker's memory.** Anything the tool holds in process state is lost with the worker — the exact event you are defending against. The key belongs in the called service or in a durable store, not in the agent.
Step 3 — For a non-idempotent write that cannot be keyed, gate every attempt. Some external services accept no idempotency key. Mistral's docs concede the harder case: the operator must build the dedupe record themselves — "a table with a unique constraint ... and act only when your record is new." When even that is impossible, the control that remains is a human: put an approval on the tool, and put it on every attempt, not just the first. The first attempt is the one you expected; the retry is the one nobody is watching.
Step 4 — Never verify "once" from the agent's session. A refused call and an unknown-outcome call can both be absent or error-only in history. Confirm the effect by querying the external system — the ledger, the payments dashboard, the ticket queue, the sent-mail log — not by reading the agent's recovered session. The session tells you what the agent recorded; only the outside world tells you what happened.
Step 5 — Set permission_mode deliberately before you ship. Do not deploy on the "auto" default. Adopt the pattern the vendor documents: auto-approve the read-only class, route everything that writes to a policy — and make sure the policy's answer for the non-idempotent class is a human, on every attempt.
Worked example, kept small. A tool that issues refunds. Step 1: it is a non-idempotent write — a repeat refunds twice. Step 2: you pass the order id as the idempotency key, and the payment provider's API enforces it, so a retry with the same order id returns the original refund rather than issuing a second. If the provider has no such key: Step 3 — you keep a refunds table with a unique constraint on order_id, insert before calling, and only call the provider when the insert is new; if even that is unavailable, you gate the refund behind a human approval on every attempt. Step 4 — after a crash-and-resume, you verify by listing the provider's refunds for that order, not by reading the agent's history. Step 5 — you set a policy that routes any refund above a threshold to a person. Now a recovered turn cannot double-refund, and you have a witness outside the agent.
Where you will get stuck here: you will classify a tool as "idempotent" because its name sounds safe, or because a repeat usually looks fine. Ask the atomic question instead — if this exact call runs twice at the same instant, do I get one effect or two? If the answer is "two, or I'm not sure," it is not idempotent, whatever the docstring says.
Where you will get stuck
- You will read "survives crashes" as "reliable."** It is a claim about uptime. It says nothing about effects. The retried tool call is the failure it introduces, not the one it prevents.
- You will trust the recovered session.** The record can be missing a refused call and can't vouch for an unknown-outcome step. Verify from the external system.
- You will reach for a "was this done?" check.** Two calls running at once can both pass it. The guard must be atomic — a service-enforced key or a unique constraint.
- You will keep the key in the worker.** Anything in the worker's memory dies with the worker, which is the event you are defending against.
- You will gate the first attempt and forget the retry.** The retry is the call nobody is watching, and it fires against the same payment API or outbound email. Gate every attempt.
- You will leave
permission_modeat"auto".** With no policy attached, every tool call the model decides to make runs without approval — including the one re-driven by recovery. - You will assume this is a Mistral problem.** It is the definition of durable execution. Temporal and Mastra document the same gap. Switching runtimes does not close it.
What to do first
Do one thing: list every tool your agent can call, and tag each one read-only, idempotent write, or non-idempotent write. That single pass tells you where the risk is. The read-only tools are fine. The idempotent ones need a key you may already have. The non-idempotent ones — the charges, sends, posts, deletes, provisions — are the ones that decide whether a 3am crash costs you a restart or a duplicate. For each of those, write down the idempotency key, or the unique-constraint store, or the human gate, or admit you have none of the three and put one in place before you deploy. Then set permission_mode deliberately, and stop treating "the run recovered" as evidence that it ran once.
The compressed ending
Remember it in four beats:
- Durable is not safe.* A managed runtime can guarantee a crashed turn resumes and each step is observed once. It cannot guarantee a step executed* once. That is at-least-once, and it is the definition of the category — Temporal says it too.
- The crash is loud; the duplicate is quiet.** A crash logs an error. A re-driven charge, email, or ticket succeeds. The more reliable the runtime, the more the failure moves into the half you cannot see.
- The fix is idempotency, not persistence.** You cannot save a result before it exists. Make the action safe to repeat — a request-derived key enforced by the service, or a unique constraint — and a "was this done?" check is not enough, because two calls can both pass it.
- Verify from the outside.** A recovered session is not a witness. The external system is. And set the permission gate before you deploy — the default leaves it open.
The vendor sold you uptime, and it delivered. The effects that happen exactly once were always going to be your job. "Recovered" means "resumed," never "ran once."
---
Sources
- Mistral Docs — Agents overview — the pitch ("work for hours or days, survive crashes and stay under your control"); durability at step granularity ("the turn continues from its last finished model call or tool call"); sessions stored server-side; the one-hour approval window that outlives the calling app.
- Mistral Docs — Run modes — the load-bearing page: "each finished model call and tool call is recorded, and the session outlives the worker"; "Work that was running when the worker stopped has an unknown outcome ... a tool with side effects can run twice, and must be idempotent"; "A plain 'was this done?' check is not enough: two calls running at once can both pass it"; the self-hosted vs managed trace default.
- Mistral Docs — Serve (self-hosted workers) — worker/session routing context for the run modes.
- Mistral Docs — Approvals —
permission_modedefault"auto"("follows the permission_policy, or runs when the Agent has none"); the auto-approve-read-only example pattern; a refused call is compiled to a skipped hook and writes notool_call/tool_resultentry. - Mistral Docs — Permission capability — the permission policy surface behind the gate.
- Mistral — Build with Studio — the launch framing ("your agent in prod at 3am: crashes silently. Managed Agents are built for that part").
- Temporal Docs — Activity Definition, Idempotency — "observed as completed exactly once ... may be executed multiple times"; the duplicate-charge worked example and the idempotency-key fix.
- Temporal Docs — Durable execution — the at-least-once property of the category.
- Mastra — commit 9d1fc55 — "Make tools safe to repeat": a tool or workflow step can run again if a worker stops before saving its result; recovery "re-issues LLM calls and re-executes tool calls, so tools must be idempotent"; the "sending the same refund twice" example.
Precision notes. (a) This is a documented structural hazard, not an observed incident. No source here shows a duplicate charge, ticket, or email occurring in production on Mistral, Temporal, or Mastra. The double-effect is a design property (at-least-once recovery) plus a canonical worked example (Temporal's payment scenario) and a vendor warning (Mistral, Mastra) — frame it as a failure mode the design permits, not a report of one that happened. (b) Not an "AI vendor messes up" story. Mistral names the requirement clearly and pushes idempotency to the operator; its other defaults fail closed (no code execution without an environment; the unisolated local sandbox needs an explicit opt-in). The requirement exists for any durable runtime, not because this one is worse. (c) Launch date unconfirmed. Secondary coverage gives two different November 2026 dates and the release-notes index opened here runs only through late October; treat the exact date as unverified and the product plus its docs as the evidence. (d) Public preview, moving defaults. The docs state the API, behavior, and limits can change and "an update can require changes to your code"; any specific default (permission mode, timeouts, idempotency behavior) may move before GA. (e) Idempotency keys are not always available. The docs concede the harder case — where the external service takes no key, the operator must build the dedupe store ("a table with a unique constraint ... act only when your record is new"); no source measures how often that is possible, and the piece says so at Step 3. (f) The duplicate is a hazard, not a measured rate. No source here measures how common non-idempotent production tools are, or what fraction of operators deploy on the default "auto" permission mode; the operator-population claims are inference, flagged as such. (g) A second tension in the same release is deliberately not the spine. Self-hosted deployments still send session state and traces to Mistral by default (per the run-modes tracing row) — a data-boundary story owned by other pieces, noted only as a possible second X post.
---
X entryway list (from the approved angle)
Distribution entryways named in the angle brief. Hooks are not yet written as posts — this names each post's type, the one claim or mechanism it carries, and whether it links.
- Hook type: surprising proof.** The vendor selling "reliable production agents" says the quiet part in its own docs: "a tool with side effects can run twice, and must be idempotent." And it rules out the obvious fix: "A plain 'was this done?' check is not enough: two calls running at once can both pass it." → Links to the article (the two quotes are the shock and stand alone; the article supplies the mechanism — why at-least-once makes the duplicate possible — and the audit that acts on it).
- Hook type: mechanism.** Durable execution is at-least-once. Temporal's own wording: the Activity "will be observed as completed exactly once" but "may be executed multiple times." Recovery re-drives the step whose outcome is unknown — so the fix is idempotency (safe to repeat), never more persistence (you cannot save a result before it exists). → Links to the article (the mechanism is self-contained; the article carries the two-problem reframe and the per-tool audit).
- Hook type: workflow.** The repeatable-side-effect audit: classify each tool read-only / idempotent-write / non-idempotent-write; key the writes, gate the un-keyable ones on every attempt, and verify "once" from the external system — not from the recovered session. → Links to the article (the workflow is the actionable core; the article is the reasoning behind each step and the worked refund example).
- Hook type: risk.** You deployed the managed agent, left
permission_modeat its"auto"default, and never wrote a permission policy — so when a crashed turn resumes, the retried tool call can fire against your payment API or outbound email with no approval and no error, and the session history will look clean. → Links to the article (names the trap in one line; the article shows why the history is not a witness and gives the gate-and-key controls that close it).
- Hook type: result.** The genuine good news, stated fairly: crash recovery is real and it works — an overnight job now survives a worker restart, the session outlives your app, and approvals wait an hour while your process is closed. That is the easy half, and it is finally solved. The hard half — effects that happen exactly once — is still yours. → Links to the article (the reframe is the post's own claim; the article develops what "the hard half is yours" means concretely).
Hook-type map: 1 = proof; 2 = mechanism; 3 = workflow; 4 = risk; 5 = result. All five link, and each link is a bonus — every post carries a claim that stands on its own. These are the five entryways the angle brief named; none was invented, and no entryway repeats another's hook. A sixth candidate the angle brief kept as an optional second X post (the self-hosted trace default, a data-boundary story) is deliberately not included here — it belongs to other pieces.