Skip to content

fix(gateway): harden BlueBubbles webhooks and duplicate delivery - #34183

Closed
Oceanswave wants to merge 3 commits into
NousResearch:mainfrom
Oceanswave:fix/bluebubbles-webhook-hardening-v2
Closed

fix(gateway): harden BlueBubbles webhooks and duplicate delivery#34183
Oceanswave wants to merge 3 commits into
NousResearch:mainfrom
Oceanswave:fix/bluebubbles-webhook-hardening-v2

Conversation

@Oceanswave

@Oceanswave Oceanswave commented May 28, 2026

Copy link
Copy Markdown

Summary

  • Reapply the BlueBubbles webhook hardening changes on top of current main.
  • Make webhook registration event-aware and avoid unregistering the gateway-owned webhook from one-shot outbound senders.
  • Add duplicate inbound-message guards for BlueBubbles new-message/updated-message delivery, including DM variants that arrive with different chat IDs/GUIDs.
  • Preserve webhook URL/password masking in logs.

Why

BlueBubbles/iMessage is still seeing duplicate replies and webhook handling problems locally. This keeps receipt/status update webhooks from triggering duplicate conversational handling and prevents outbound one-shot sends from interfering with the long-running gateway listener/registration.

Test Plan

  • python -m pytest tests/gateway/test_bluebubbles.py -q
  • python -m py_compile gateway/platforms/bluebubbles.py

Related issues

@alt-glitch

Copy link
Copy Markdown
Collaborator

Competing with open #32691 (broader scope BlueBubbles webhook hardening). Also overlaps with #18395 (dedup fix). Related issues: #33327, #24157, #23409.

(cherry picked from commit 0c0a848212712fc3b7d21cbbc2acf3173675ea28)
(cherry picked from commit ff1f0e58964352c8916695056a2fb5656551c150)
@Oceanswave
Oceanswave force-pushed the fix/bluebubbles-webhook-hardening-v2 branch from 676220f to 8fcffb5 Compare June 8, 2026 12:45
@Oceanswave

Copy link
Copy Markdown
Author

Closing this in favor of the consolidated BlueBubbles hardening PR: #45317

That PR folds the repeated local reapply work into one clean branch and explicitly documents the purpose/struggles: BlueBubbles updates can produce duplicate inbound iMessage turns, status-only updated-message webhook echoes, fragile typing behavior, and one-shot outbound adapter conflicts with the gateway-owned webhook listener. It also includes the focused regression suite covering the consolidated behavior.

@Oceanswave

Copy link
Copy Markdown
Author

Superseded by consolidated BlueBubbles hardening PR #45317.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/gateway Gateway runner, session dispatch, delivery P2 Medium — degraded but workaround exists type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants