openclaw - 💡(How to fix) Fix [Bug]: RangeError: Maximum call stack size exceeded when sending audio attachments (.m4a) via Control UI/WebChat — fix #73360 scope gap

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…

Sending messages with audio file attachments (.m4a) via the Control UI/WebChat triggers a RangeError: Maximum call stack size exceeded. The user message and audio file are silently dropped with no recovery. This appears to be a scope gap in the #73360 fix, which only covers PDF/image attachments.

Error Message

  1. Observe the RangeError: Maximum call stack size exceeded banner and a fake agent "reply" showing the raw error. The audio file and message text are silently dropped with no recovery. The Control UI immediately shows RangeError: Maximum call stack size exceeded as both a banner and a fake agent reply. The user message and audio file are silently dropped. The error triggers within ~50ms, indicating immediate recursion in the attachment rendering pipeline. No compaction or recovery is triggered.
  • #56980: Similar error in facade-runtime (commit 9a03fe8181 added recursion guard, but this is a different code path)

Root Cause

Root cause hypothesis

Fix Action

Fix / Workaround

  • Affected: Any user sending audio file attachments via Control UI/WebChat
  • Severity: High — blocks audio summarization/transcription workflows; user message + file silently dropped with no recovery
  • Frequency: Always observed with audio attachments on this version
  • Consequence: Cannot use OpenClaw to summarize or transcribe audio files through the WebChat interface. Workaround requires sending audio via other channels or processing outside OpenClaw.
RAW_BUFFERClick to expand / collapse

Summary

Sending messages with audio file attachments (.m4a) via the Control UI/WebChat triggers a RangeError: Maximum call stack size exceeded. The user message and audio file are silently dropped with no recovery. This appears to be a scope gap in the #73360 fix, which only covers PDF/image attachments.

Steps to reproduce

  1. Open OpenClaw 2026.5.20 Control UI (webchat channel) with an agent session (configured PM agent, qwen3.6-plus model).
  2. Send a message with an audio file attachment (e.g., an .m4a file, a few MB).
  3. Observe the RangeError: Maximum call stack size exceeded banner and a fake agent "reply" showing the raw error. The audio file and message text are silently dropped with no recovery.
  4. This occurs regardless of session context usage — reproduced at 31k/1M tokens (3% context utilization), confirming it is NOT context-overflow related.

Expected behavior

Audio file attachments should be handled the same way as PDF/image attachments after the #73360 fix: large payloads should be kept out of Lit state and optimistic chat messages, using object URL previews plus send-time payload serialization. The agent should receive the audio file path and be able to process it normally.

Actual behavior

The Control UI immediately shows RangeError: Maximum call stack size exceeded as both a banner and a fake agent reply. The user message and audio file are silently dropped. The error triggers within ~50ms, indicating immediate recursion in the attachment rendering pipeline. No compaction or recovery is triggered.

OpenClaw version

2026.5.20

Operating system

Linux 6.8.0-57-generic (Ubuntu, x64)

Install method

npm global

Model

qwen3.6-plus (via custom provider)

Provider / routing chain

OpenClaw Gateway -> custom provider -> qwen3.6-plus

Impact and severity

  • Affected: Any user sending audio file attachments via Control UI/WebChat
  • Severity: High — blocks audio summarization/transcription workflows; user message + file silently dropped with no recovery
  • Frequency: Always observed with audio attachments on this version
  • Consequence: Cannot use OpenClaw to summarize or transcribe audio files through the WebChat interface. Workaround requires sending audio via other channels or processing outside OpenClaw.

Related issues

  • #73360 (fixed): Control UI/WebChat: keep large attachment payloads out of Lit state and optimistic chat messages, using object URL previews plus send-time payload serialization so PDF/image uploads no longer trigger RangeError: Maximum call stack size exceeded — This fix only covers PDF/image, NOT audio files.
  • #38859: Similar stack overflow with image attachments near context limit (version 2026.3.2)
  • #56980: Similar error in facade-runtime (commit 9a03fe8181 added recursion guard, but this is a different code path)

Root cause hypothesis

The #73360 fix added object URL previews for PDF/image attachments but did not extend this handling to audio MIME types. When an audio file is attached, the Control UI Lit framework still tries to render the full binary payload into component state, triggering the stack overflow.

Suggested fix

Extend the #73360 attachment handling to cover audio MIME types (audio/m4a, audio/mp3, audio/wav, audio/ogg, etc.) — use object URL previews instead of inline payload serialization for all binary file types, not just PDF/image.

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

Audio file attachments should be handled the same way as PDF/image attachments after the #73360 fix: large payloads should be kept out of Lit state and optimistic chat messages, using object URL previews plus send-time payload serialization. The agent should receive the audio file path and be able to process it normally.

Still need to ship something?

×6

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

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix [Bug]: RangeError: Maximum call stack size exceeded when sending audio attachments (.m4a) via Control UI/WebChat — fix #73360 scope gap