openclaw - 💡(How to fix) Fix [Bug]: Agent prep stages take ~11s per turn, 5x slower than 2026.4.15 [1 comments, 2 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#75654Fetched 2026-05-02 05:32:15
View on GitHub
Comments
1
Participants
2
Timeline
4
Reactions
2
Author
Timeline (top)
labeled ×2closed ×1commented ×1

After upgrading from 2026.4.15 to 2026.4.29, every agent turn spends ~11s in local prep stages (core-plugin-tools 4.5s, system-prompt 2.7s, stream-setup 2.7s) before any API call. The same setup on 2026.4.15 completes end-to-end in 2-3s.

Root Cause

After upgrading from 2026.4.15 to 2026.4.29, every agent turn spends ~11s in local prep stages (core-plugin-tools 4.5s, system-prompt 2.7s, stream-setup 2.7s) before any API call. The same setup on 2026.4.15 completes end-to-end in 2-3s.

Fix Action

Fix / Workaround

Last known good: 2026.4.15 First known bad: 2026.4.29 No intermediate versions tested. Workaround: none available on 4.29; the only workaround is downgrading to 4.15. Config is minimal — only DeepSeek provider and Feishu channel enabled.

Code Example

Gateway prep stage trace (5 consecutive runs, consistent):

  core-plugin-tools:    4,443ms / 4,448ms / 4,496ms / 4,517ms / 4,476ms
  system-prompt:        2,754ms / 2,731ms / 2,826ms / 2,770ms / 2,724ms
  stream-setup:         2,749ms / 2,674ms / 2,734ms / 2,692ms / 2,785ms
  ──────────────────────────────── ─────────────────────────────
  totalMs:            ~11,000ms every turn

  Diagnostic warnings present:
  eventLoopDelayMaxMs=4479, eventLoopUtilization=0.6

  Direct API test (curl to api.deepseek.com): 0.6s total
  Config: minimal (deepseek provider + feishu channel only)
RAW_BUFFERClick to expand / collapse

Bug type

Crash (process/app exits or hangs)

Beta release blocker

No

Summary

After upgrading from 2026.4.15 to 2026.4.29, every agent turn spends ~11s in local prep stages (core-plugin-tools 4.5s, system-prompt 2.7s, stream-setup 2.7s) before any API call. The same setup on 2026.4.15 completes end-to-end in 2-3s.

Steps to reproduce

  1. Start OpenClaw 2026.4.29 on WSL2 with the attached config.
  2. Send any message to the agent.
  3. Observe ~11s prep delay before the first API byte is sent.

Expected behavior

In 2026.4.15, prep stages complete quickly and the agent responds within 2-3s end-to-end under the same WSL2 environment, same model, and same config.

Actual behavior

Gateway logs show prep stages consistently at ~11,000ms total:

  • core-plugin-tools: ~4,500ms
  • system-prompt: ~2,750ms
  • stream-setup: ~2,750ms

The actual DeepSeek API call (measured via curl) completes in ~0.6s. End-to-end user-facing latency is 12-20 seconds per turn.

OpenClaw version

2026.4.29

Operating system

Linux 6.6.87.2-microsoft-standard-WSL2 (x64) on Windows 11

Install method

npm global

Model

deepseek/deepseek-v4-flash (thinking off)

Provider / routing chain

openclaw → api.deepseek.com

Additional provider/model setup details

openclaw → api.deepseek.com

Logs, screenshots, and evidence

Gateway prep stage trace (5 consecutive runs, consistent):

  core-plugin-tools:    4,443ms / 4,448ms / 4,496ms / 4,517ms / 4,476ms
  system-prompt:        2,754ms / 2,731ms / 2,826ms / 2,770ms / 2,724ms
  stream-setup:         2,749ms / 2,674ms / 2,734ms / 2,692ms / 2,785ms
  ──────────────────────────────── ─────────────────────────────
  totalMs:            ~11,000ms every turn

  Diagnostic warnings present:
  eventLoopDelayMaxMs=4479, eventLoopUtilization=0.6

  Direct API test (curl to api.deepseek.com): 0.6s total
  Config: minimal (deepseek provider + feishu channel only)

Impact and severity

Affected: Single-user WSL2 deployment on 2026.4.29 Severity: High (5x latency regression vs 2026.4.15) Frequency: Every agent turn, 100% reproducible Consequence: Agent feels unresponsive; 12-20s wait per message vs previously 2-3s

Additional information

Last known good: 2026.4.15 First known bad: 2026.4.29 No intermediate versions tested. Workaround: none available on 4.29; the only workaround is downgrading to 4.15. Config is minimal — only DeepSeek provider and Feishu channel enabled.

extent analysis

TL;DR

Downgrade to OpenClaw version 2026.4.15 to immediately resolve the 5x latency regression issue.

Guidance

  • Investigate the changes between OpenClaw versions 2026.4.15 and 2026.4.29 to identify the root cause of the latency increase, focusing on the core-plugin-tools, system-prompt, and stream-setup stages.
  • Analyze the eventLoopDelayMaxMs and eventLoopUtilization diagnostic warnings to determine if they are related to the increased latency.
  • Test intermediate versions between 2026.4.15 and 2026.4.29 to pinpoint the exact version where the latency regression was introduced.
  • Consider optimizing the configuration or environment to reduce the latency, although the current minimal config suggests this may not be the primary cause.

Notes

The provided information suggests a clear regression between versions 2026.4.15 and 2026.4.29, with no intermediate versions tested. The exact cause of the latency increase is unknown, but downgrading to the last known good version (2026.4.15) is a reliable workaround.

Recommendation

Downgrade to OpenClaw version 2026.4.15, as it is the last known good version with the expected performance, and there is currently no available workaround for version 2026.4.29.

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…

FAQ

Expected behavior

In 2026.4.15, prep stages complete quickly and the agent responds within 2-3s end-to-end under the same WSL2 environment, same model, and same config.

Still need to ship something?

×6

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

Back to top recommendations

TRENDING