-
-
Notifications
You must be signed in to change notification settings - Fork 69.4k
[Bug]: WhatsApp: message send fails "No active WhatsApp Web listener" but react succeeds (likely duplicate active-listener module) #46659
Description
Bug type
Regression (worked before, now fails)
Summary
Version: OpenClaw 2026.3.13-1 (61d171a) / macOS 13 Ventura / Node v24.13.1
Problem:
message send (CLI and agent tool) always fails with "No active WhatsApp Web listener (account: default)" — but action=react succeeds on the same session, proving the ActiveWebListener Map IS populated.
Channel status ( channels status --probe --json , WhatsApp section):
json
{
"configured": true, "linked": true, "running": true,
"connected": true, "reconnectAttempts": 0,
"lastError": null, "lastOutboundAt": null
}
Minimal repro — react works, send fails:
React (succeeds):
message(action=react, channel=whatsapp, messageId="3BDE41CF2A1D7DD4DAE0", emoji="👀")
→ {"ok": true, "added": "👀"}
Send (fails):
openclaw message send --channel whatsapp --target "+34655112238" --message "test" --account default
→ Error: No active WhatsApp Web listener (account: default)
Environment:
• Single gateway process (verified via ps aux )
• Single install path ( which openclaw matches gateway service path)
• Single config file (cli = service = ~/.openclaw/openclaw.json )
• Single WhatsApp account: default
• lastOutboundAt: null — outbound has never worked
Diagnosis (from Discord #help):
Since react uses sendReactionWhatsApp → requireActiveWebListener and succeeds, but send uses sendMessageWhatsApp → requireActiveWebListener and fails, this points to duplicate module instances of active-listener.ts in the same process — the react codepath reads Map A (populated), the send codepath reads Map B (empty).
active-listener module search:
find "$OPENCLAW_DIR" -name 'active-listener.*' | grep whatsapp
→ [results]
Steps to reproduce
1. Fresh install OpenClaw 2026.3.13-1 on macOS 13 / Node v24.13.1
2. Link WhatsApp via openclaw channels login --channel whatsapp --account default (says "✅ Linked!")
3. Confirm inbound messages arrive to agent ✅
4. Try openclaw message send --channel whatsapp --target "+34..." --message "test" → fails with "No active WhatsApp Web listener"
5. Try message(action=react, emoji="👀") from agent tool → succeeds ✅
6. openclaw channels status shows: linked, running, connected, lastError: null, lastOutboundAt: null
Expected behavior
message send should work when WhatsApp shows as fully connected ( linked , running , connected , lastError: null ) and other actions ( react , inbound receive) work correctly on the same session. The requireActiveWebListener Map should be shared across all WhatsApp codepaths (send, react, auto-reply) within the same gateway process.
Actual behavior
message send fails with "No active WhatsApp Web listener (account: default)" on every attempt. lastOutboundAt: null — outbound has never worked. Inbound and react work fine.
OpenClaw version
2026.3.13-1 (61d171a)
Operating system
macOS 13.6.9 Ventura (Intel x86_64)
Install method
npm global ( npm install -g openclaw@latest )
Model
anthropic/claude-sonnet-4-6 (default), anthropic/claude-opus-4-6 (routing)
Provider / routing chain
anthropic (OAT token via auth-profiles)
Config file / key location
~/.openclaw/openclaw.json — same for CLI and gateway service (confirmed via openclaw gateway status )
Additional provider/model setup details
Single WhatsApp account default , no defaultAccount override. Gateway runs as LaunchAgent on port 18789 (loopback only). Node v24.13.1 via nvm.
Logs, screenshots, and evidence
Send attempt log:
[tools] message failed: Error: No active WhatsApp Web listener (account: default)
React success (same session):
message(action=react, messageId="...", emoji="👀") → {"ok": true, "added": "👀"}
channels status:
WhatsApp default: enabled, configured, linked, running, connected
reconnectAttempts: 0, lastError: null, lastOutboundAt: nullImpact and severity
High — all proactive outbound messaging is broken (no cron notifications, no scheduled reports, no contacting external users). Only reactive replies work (agent responding to inbound messages). Blocks core assistant functionality.
Additional information
Discussed in Discord #help. Diagnosis points to duplicate active-listener module instances in the same process — react codepath reads a populated Map, send codepath reads an empty one. Single PID, single install path, single config confirmed.