openclaw - 💡(How to fix) Fix Subagent announce gives up when requester session is busy (direct call timeout → should queue) [1 participants]

Official PRs (…)
ON THIS PAGE

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#54276Fetched 2026-04-08 01:29:49
View on GitHub
Comments
0
Participants
1
Timeline
1
Reactions
1
Author
Participants
Timeline (top)
cross-referenced ×1

Error Message

[warn] Subagent announce completion direct announce agent call transient failure, 
retrying 2/4 in 5s: gateway timeout after 90000ms

[warn] Subagent announce give up (expiry) 
run=8738b987 child=agent:product-manager:subagent:fe5424f1 
requester=agent:main:telegram:direct:6740110650 
retries=0 endedAgo=1871s

Code Example

[warn] Subagent announce completion direct announce agent call transient failure, 
retrying 2/4 in 5s: gateway timeout after 90000ms

[warn] Subagent announce give up (expiry) 
run=8738b987 child=agent:product-manager:subagent:fe5424f1 
requester=agent:main:telegram:direct:6740110650 
retries=0 endedAgo=1871s

---

Subagent completion direct announce failed: gateway timeout after 15000ms
RAW_BUFFERClick to expand / collapse

Problem

When a subagent completes and tries to announce back to the requester session, it uses a direct agent call. If the requester session has an active run, the announce hits a 90s gateway timeout, retries up to 4 times, and then gives up entirely — the announce is lost.

Logs

[warn] Subagent announce completion direct announce agent call transient failure, 
retrying 2/4 in 5s: gateway timeout after 90000ms

[warn] Subagent announce give up (expiry) 
run=8738b987 child=agent:product-manager:subagent:fe5424f1 
requester=agent:main:telegram:direct:6740110650 
retries=0 endedAgo=1871s

Expected Behavior

The announce should be queued (similar to how collect mode queues inbound messages) and delivered when the requester session's current run completes. The announce should never be lost.

Current Behavior

  1. Subagent completes
  2. Direct agent call to requester session
  3. Requester session is busy (active run) or announce retry window expires
  4. 90s timeout × retries
  5. Give up — announce is permanently lost
  6. Requester has no idea the subagent finished

Scenario

  • Main agent spawns a product-manager subagent for a long coding task (~40 min)
  • Subagent completes successfully (commits + pushes code)
  • Announce attempts fail with gateway timeout
  • endedAgo=1871s (31 minutes after completion) → give up
  • User never receives the completion notification

Other Reports

Same issue reported by another user in Docker environment (Answer Overflow, Feb 2026):

Subagent completion direct announce failed: gateway timeout after 15000ms

Suggested Fix

Route subagent announces through the existing message queue system (e.g., collect mode) rather than direct agent calls. This way:

  • Announce lands in the queue
  • Delivered on next turn (or immediately if session is idle)
  • Never lost

Environment

  • OpenClaw version: 2026.3.13
  • Queue mode: collect
  • maxConcurrent: 10

extent analysis

Fix Plan

To fix the issue, we need to route subagent announces through the existing message queue system. Here are the steps:

  • Modify the subagent to send announces to the message queue instead of making direct agent calls.
  • Update the requester session to process announces from the message queue.

Code Changes

# In subagent code
import queue

# ...

def announce_completion(self):
    # Instead of making a direct agent call
    # announce_direct(self.requester_session)
    queue.put((self.requester_session, "announce_completion"))

# In requester session code
import queue

# ...

def process_queue(self):
    while not queue.empty():
        session, message = queue.get()
        if message == "announce_completion":
            # Process the announce completion
            self.handle_announce_completion(session)

Configuration Changes

  • No configuration changes are needed, as we are leveraging the existing message queue system.

Verification

To verify that the fix worked:

  • Test the scenario where a subagent completes and the requester session is busy.
  • Check that the announce is delivered to the requester session after it becomes idle.
  • Verify that the announce is not lost even if the retry window expires.

Extra Tips

  • Make sure to handle any potential queue overflow issues by implementing a queue size limit or a retry mechanism.
  • Consider adding logging to track announces and their delivery status for debugging purposes.

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

openclaw - 💡(How to fix) Fix Subagent announce gives up when requester session is busy (direct call timeout → should queue) [1 participants]