Skip to content

Stop durable approval waits during daemon drain - #2208

Open
Aaronontheweb wants to merge 2 commits into
plan/shorten-daemon-restartsfrom
feat/shorten-approval-drain
Open

Aaronontheweb wants to merge 2 commits into
plan/shorten-daemon-restartsfrom
feat/shorten-approval-drain

Conversation

@Aaronontheweb

Copy link
Copy Markdown
Collaborator

Change

  • Stop the current tool task when every unfinished call waits for a durable approval.
  • Wait for the task to stop before the session acknowledges drain.
  • Keep journaled approvals, sibling results, and original turn authority for cold recovery.
  • Keep the current bounded drain path for active siblings and accepted buffered input.
  • Update SPEC-011, the session-resume OpenSpec contract, and the operations skill.

Evidence

  • The new actor test timed out against the baseline, then passed after this change.
  • The actor project passed: 4,022 passed, six skipped.
  • The Spark2 Skill Discovery eval passed: 8/8 cases, one run each.
  • Slopwatch found zero issues. Header verification and OpenSpec validation passed.

Scope

The actor still uses the current drain limit for active model calls and other tool states. The later input recovery PR addresses those states. No live daemon restart took place.

Stack

This PR targets the approved plan in #2201.

This PR replaces #2202 so GitHub can link the same-repository branches as a stack.

@Aaronontheweb
Aaronontheweb added this pull request to stack #2212 September 19, 2026 13:58
@Aaronontheweb
Aaronontheweb marked this pull request as ready for review September 19, 2026 14:16
@Aaronontheweb Aaronontheweb added sessions LLM session actor, turn lifecycle, pipelines reliability Retries, resilience, graceful degradation labels Sep 19, 2026
Comment on lines +5019 to +5022
catch (Exception ex)
{
actor.Tell(new ToolPipelineStoppedForRestart(generation, ex));
}
Comment on lines +102 to +111
foreach (var callId in _expectedCallIds)
{
if (_completedCallIds.Contains(callId))
continue;

if (!hasDurableApproval(callId))
return false;

hasUnfinishedApproval = true;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

reliability Retries, resilience, graceful degradation sessions LLM session actor, turn lifecycle, pipelines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant