fix(slack): add message deduplication for Socket Mode retransmissions#364
Closed
leighstillard wants to merge 1 commit intochenhg5:mainfrom
Closed
fix(slack): add message deduplication for Socket Mode retransmissions#364leighstillard wants to merge 1 commit intochenhg5:mainfrom
leighstillard wants to merge 1 commit intochenhg5:mainfrom
Conversation
…issions Slack Socket Mode retransmits events when ack is delayed or after reconnects. Without dedup, the same message gets processed multiple times, causing "message queued for busy session" spam and duplicate bot responses. Every other platform (Feishu, DingTalk, QQ, QQBot, WeCom) already uses core.MessageDedup — Slack was the only one missing it. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
chenhg5
approved these changes
Mar 29, 2026
Owner
chenhg5
left a comment
There was a problem hiding this comment.
LGTM. Good fix following the established pattern.
Review notes:
- ✅ CI passes
- Matches dedup pattern used by other platforms (Feishu, DingTalk, QQ, WeCom)
- Uses
ev.TimeStampas unique message ID - Prevents duplicate processing from Socket Mode retransmissions
Approved for merge.
Contributor
Author
|
Final checks have been done, ready for merge |
Contributor
Author
|
Merged locally into feature/thread-affinity-router — dedup fix now included in #533 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
core.MessageDedupto the Slack platform adapter, matching the pattern used by every other platform (Feishu, DingTalk, QQ, QQBot, WeCom)AppMentionEventandMessageEventusingev.TimeStampas the unique message IDProblem
Slack Socket Mode retransmits events when acknowledgment is delayed or after connection drops/reconnects. Without dedup, the same message is processed multiple times:
This causes "message queued for busy session" spam and can trigger duplicate bot responses after the current turn completes.
Test plan
go build ./...passesgo test ./core/passes (614 tests)🤖 Generated with Claude Code