openclaw - 💡(How to fix) Fix feat: make embedded Pi LLM-request timeout configurable [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#60123Fetched 2026-04-08 02:36:00
View on GitHub
Comments
0
Participants
1
Timeline
3
Reactions
3
Author
Participants
Timeline (top)
subscribed ×3

Error Message

The error message suggests increasing agents.defaults.timeoutSeconds, but that config has no effect on the embedded path.

Fix Action

Fix / Workaround

Current workaround

Code Example

embedded run failover decision: ... decision=surface_error reason=timeout provider=anthropic/claude-sonnet-4-6

---

{
  "agents": {
    "defaults": {
      "embeddedPi": {
        "timeoutMs": 60000
      }
    }
  }
}
RAW_BUFFERClick to expand / collapse

Problem

Embedded Pi agent (cron jobs, sub-agents, compaction) has a hardcoded ~15s timeout for LLM HTTP requests. This is separate from agents.defaults.timeoutSeconds which has no effect on embedded runs.

When using Claude via MAX subscription (which routes through a proxy with additional latency), the 15s limit is too tight — causing all cron jobs to fail with:

embedded run failover decision: ... decision=surface_error reason=timeout provider=anthropic/claude-sonnet-4-6

The error message suggests increasing agents.defaults.timeoutSeconds, but that config has no effect on the embedded path.

Current workaround

Switch cron job models to faster providers (e.g., google/gemini-3-flash via openclaw cron edit --model) that respond within 15s. This works but forces users off their preferred model for background tasks.

Proposed solution

Add a configurable timeout for embedded Pi LLM requests:

{
  "agents": {
    "defaults": {
      "embeddedPi": {
        "timeoutMs": 60000
      }
    }
  }
}

Note: PR #34673 proposed this exact fix but was closed without merge on 2026-03-06.

Environment

  • OpenClaw v2026.4.2 (Docker, Linux)
  • Provider: anthropic/claude-sonnet-4-6 via Claude MAX
  • Affected: all cron jobs, heartbeat embedded runs
  • Network is fine (curl to api.anthropic.com: 0.25s from container)

Related: #34644, #44795, #52353, #59598

extent analysis

TL;DR

Increase the timeout for embedded Pi LLM requests by adding a configurable timeout setting, such as "timeoutMs": 60000, to the agents.defaults.embeddedPi configuration.

Guidance

  • Review the proposed solution in PR #34673, which suggests adding a configurable timeout for embedded Pi LLM requests, to understand the potential fix.
  • Consider testing the proposed configuration change to verify its effectiveness in resolving the timeout issue.
  • Evaluate the current workaround of switching to faster provider models, such as google/gemini-3-flash, to determine if it is a viable temporary solution.
  • Investigate the network latency introduced by the Claude MAX proxy to determine if there are any other potential optimizations or fixes.

Example

{
  "agents": {
    "defaults": {
      "embeddedPi": {
        "timeoutMs": 60000
      }
    }
  }
}

This example configuration snippet illustrates the proposed fix, which adds a configurable timeout setting for embedded Pi LLM requests.

Notes

The proposed solution was previously suggested in PR #34673 but was closed without merge, so it is essential to review and test the change thoroughly to ensure its effectiveness.

Recommendation

Apply the proposed workaround of adding a configurable timeout setting, as it directly addresses the identified issue and provides a clear solution.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING