Bug Report
Summary: The inbound message debouncer uses key {channel}:{accountId}:{channelId}:{authorId} (without message.id). When Discord retransmits a message on gateway resume failure (e.g., after container restart or WebSocket reconnect), OpenClaw processes it again as a new message, potentially sending duplicate responses.
Root cause: message-handler.ts (or equivalent) uses a debouncer keyed on channel + author, not on the unique message ID. Discord may retransmit the same MESSAGE_CREATE event on RESUME if acknowledgment failed.
Impact:
- Duplicate agent responses to the same user message after container restart
- Potential message flooding if multiple retransmit events occur in quick succession
Workaround (applied locally): Track processed message.id in SQLite at the application layer before enqueuing inference. SQLite store with 24h TTL inserted at the message handler entry point.
Suggested fix: Include message.id in the debouncer key, or add an idempotency check on message.id before dispatch.
Environment:
- OpenClaw version: latest (as of 2026-02-28)
- Node.js: v22.22.0
- Platform: Docker container (Linux)
- Discord gateway: @buape/carbon
Bug Report
Summary: The inbound message debouncer uses key
{channel}:{accountId}:{channelId}:{authorId}(withoutmessage.id). When Discord retransmits a message on gateway resume failure (e.g., after container restart or WebSocket reconnect), OpenClaw processes it again as a new message, potentially sending duplicate responses.Root cause:
message-handler.ts(or equivalent) uses a debouncer keyed on channel + author, not on the unique message ID. Discord may retransmit the sameMESSAGE_CREATEevent on RESUME if acknowledgment failed.Impact:
Workaround (applied locally): Track processed
message.idin SQLite at the application layer before enqueuing inference. SQLite store with 24h TTL inserted at the message handler entry point.Suggested fix: Include
message.idin the debouncer key, or add an idempotency check onmessage.idbefore dispatch.Environment: