fix(agents): let an agent keep saving its record after a failed delete

The delete RPC fences the record against writes before closing the agent.
Since a failed history delete now leaves the record in place, the fence
stayed up for the rest of the process, so a later rename reported success
and never reached disk. The fence now ends when the delete aborts.
This commit is contained in:
Mohamed Boudra
2026-11-25 16:31:25 +01:00
parent 49715f0eae
commit a3c1ca6dba
4 changed files with 32 additions and 5 deletions
+2 -2
View File
@@ -49,8 +49,8 @@ deleting the agent, or a provider removing one of its own children, deletes hist
without its provider. Opening a stored agent that has no provider session to resume starts its
first session on the same history.
- **Delete** removes the agent's history and every child's, retired ones included, before the
agent record. If the history cannot be removed, the request fails and the agent stays listed, so
the user can delete it again.
agent record. If the history cannot be removed, the request fails and the agent stays listed. The
user can keep using it and delete it again.
`epoch` is the stored history's identity, minted once when the history is created.