-
-
Notifications
You must be signed in to change notification settings - Fork 79.1k
ACP zombie runs block gateway restart/update after 27 days #88205
Copy link
Copy link
Closed
Labels
P1High-priority user-facing bug, regression, or broken workflow.High-priority user-facing bug, regression, or broken workflow.clawsweeper:needs-live-reproClawSweeper needs live local, crabbox, or manual validation to confirm this issue.ClawSweeper needs live local, crabbox, or manual validation to confirm this issue.impact:crash-loopCrash, hang, restart loop, or process-level availability failure.Crash, hang, restart loop, or process-level availability failure.impact:session-stateSession, memory, transcript, context, or agent state can drift or corrupt.Session, memory, transcript, context, or agent state can drift or corrupt.issue-rating: 🐚 platinum hermitGood issue quality with a plausible reproduction path needing some confirmation.Good issue quality with a plausible reproduction path needing some confirmation.
Metadata
Metadata
Assignees
Labels
P1High-priority user-facing bug, regression, or broken workflow.High-priority user-facing bug, regression, or broken workflow.clawsweeper:needs-live-reproClawSweeper needs live local, crabbox, or manual validation to confirm this issue.ClawSweeper needs live local, crabbox, or manual validation to confirm this issue.impact:crash-loopCrash, hang, restart loop, or process-level availability failure.Crash, hang, restart loop, or process-level availability failure.impact:session-stateSession, memory, transcript, context, or agent state can drift or corrupt.Session, memory, transcript, context, or agent state can drift or corrupt.issue-rating: 🐚 platinum hermitGood issue quality with a plausible reproduction path needing some confirmation.Good issue quality with a plausible reproduction path needing some confirmation.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Bug Description
ACP runs that have been stuck in
runningstatus for 27 days block gateway restart/update. The warningrestart blocked by active background task run(s)preventsopenclaw updatefrom proceeding.Steps to Reproduce
openclaw updateis triggeredrestart blocked by active background task run(s)Expected Behavior
Actual Behavior
5 ACP runs created on 2026-05-03 06:28-06:32 GMT+8 remained in
status=runningfor 27 days:All had
runtime=acp, noended_at, and were referenced by multipletaskIds from the samerunId.Log Evidence
Environment
Root Cause Analysis
The task_runs SQLite database (
~/.openclaw/tasks/runs.sqlite) stores run state. When ACP sessions crash or timeout, their status is never transitioned fromrunningto a terminal state (completed/failed/cancelled). The gateway restart logic checks for anystatus=runningruns and blocks, but there is no TTL or heartbeat check.Suggested Fix
last_event_atis older than TTL, mark asfailedstatus=running AND last_event_at < threshold--force-restartflag that ignores blocked runsWorkaround (Manual Cleanup)
Manually update the SQLite database:
```sql
UPDATE task_runs SET status='failed', ended_at=, error='zombie_terminated'
WHERE status='running' AND last_event_at < ;
```
This is not a sustainable solution for end users.