agents: hard timeout on agent runs (hung model blocked the runner ~1h) #95

Merged
ffaerber merged 1 commits from fix/agent-run-timeout into main 2026-07-06 16:58:20 +02:00
Owner

A stalled local-ollama generate (@intern what is the time, homelab run 869) held the single runner slot for ~1h, queueing all agents. Per-attempt timeout -k 30 1200 around opencode (rc=124 → fail fast, no retry) + job-level timeout-minutes: 45 backstop.

A stalled local-ollama generate (`@intern what is the time`, homelab run 869) held the single runner slot for ~1h, queueing all agents. Per-attempt `timeout -k 30 1200` around opencode (rc=124 → fail fast, no retry) + job-level `timeout-minutes: 45` backstop.
ffaerber added 1 commit 2026-07-06 16:41:50 +02:00
agents: hard timeout on agent runs — a hung model must not block the runner
ci / lint (pull_request) Successful in 10s
ci / lint (push) Skipped
0771d394bd
A stalled local-ollama generate on a trivial @intern question held the single
runner slot for ~1h, queueing every agent run instance-wide (homelab run 869).

- run-agent.sh: each opencode attempt wrapped in `timeout -k 30 $AGENT_TIMEOUT`
  (default 1200s). rc=124 is not retried — a hung backend stays hung; fail fast
  and free the runner.
- agent.yml: job-level timeout-minutes: 45 as backstop.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
ffaerber merged commit 84467f6dfd into main 2026-07-06 16:58:20 +02:00
ffaerber deleted branch fix/agent-run-timeout 2026-07-06 16:58:20 +02:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: gitea/agents#95