Fix Matrix reaction removal targeting and harden outgoing MUC stanzas #4

Merged
skunky merged 1 commit from outgoing-reactions into main 2026-11-08 21:00:07 +00:00
Owner

Makes Matrix → XMPP reactions reliable and diagnosable:

  • Reaction removals now resolve the target the same way additions do (metadata RoomID → reverse alias → stored value). Previously they referenced the raw stored ID, which other XMPP clients do not recognize in MUCs, so reaction removals never landed on their side.
  • Join-on-demand for non-message MUC stanzas (reactions, edits, retractions, receipts, typing): MUC services silently drop groupchat stanzas from non-occupants, and component mode has no error surface for that.
  • Info-level log for every forwarded Matrix reaction (Forwarding Matrix reaction to XMPP) with the resolved target id and from address — makes it possible to see from the logs whether the bridge sent the reaction and which ID it referenced.
  • Regression tests with a fake XEP-0114 component server asserting the exact reactions stanza (add, remove, no-puppet fallback).
Makes Matrix → XMPP reactions reliable and diagnosable: - **Reaction removals** now resolve the target the same way additions do (metadata `RoomID` → reverse alias → stored value). Previously they referenced the raw stored ID, which other XMPP clients do not recognize in MUCs, so reaction removals never landed on their side. - **Join-on-demand for non-message MUC stanzas** (reactions, edits, retractions, receipts, typing): MUC services silently drop `groupchat` stanzas from non-occupants, and component mode has no error surface for that. - **Info-level log** for every forwarded Matrix reaction (`Forwarding Matrix reaction to XMPP`) with the resolved target id and from address — makes it possible to see from the logs whether the bridge sent the reaction and which ID it referenced. - **Regression tests** with a fake XEP-0114 component server asserting the exact reactions stanza (add, remove, no-puppet fallback).
Fix Matrix reaction removal targeting and harden outgoing MUC stanzas
Some checks failed
CI / test (pull_request) Has been cancelled
6cba0e6ae6
- HandleMatrixReactionRemove now resolves the target through
  rawIDForOutgoingReference (metadata RoomID -> reverse alias -> stored
  value), the same way HandleMatrixReaction does; removals previously
  referenced the raw stored form, which XMPP clients do not recognize in
  MUCs, so reactions were never removed on their side.
- All outgoing non-message MUC stanzas (reactions, edits, retractions,
  read receipts, typing) join the MUC on demand like messages already
  did; MUC services silently drop groupchat stanzas from non-occupants.
- Log every Matrix reaction forwarded to XMPP at info level with the
  resolved target id and from address, so wire problems are diagnosable.
- Add regression tests with a fake component server that assert the
  exact reactions stanza for add, remove and no-puppet cases.
skunky merged commit e1b76d3b6c into main 2026-11-08 21:00:07 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
xmpp-bridge/mautrix-xmpp!4
No description provided.