bug: appservices receive duplicated events #739
Labels
No labels
Blocked
Bug
Cherry-picking
Database
Dependencies
Dependencies/Renovate
Difficulty
Easy
Difficulty
Hard
Difficulty
Medium
Documentation
Enhancement
Good first issue
Help wanted
Inherited
Matrix/Administration
Matrix/Appservices
Matrix/Auth
Matrix/Client
Matrix/Core
Matrix/E2EE
Matrix/Federation
Matrix/Hydra
Matrix/MSC
Matrix/Media
Matrix/T&S
Meta
Meta/CI
Meta/Packaging
Priority
Blocking
Priority
High
Priority
Low
Security
Status
Confirmed
Status
Duplicate
Status
Invalid
Status
Needs Investigation
Support
To-Merge
Wont fix
old/ci/cd
old/rust
No milestone
No project
No assignees
5 participants
Notifications
Due date
No due date set.
Blocks
#751 feat: appservice callbacks
continuwuation/continuwuity
Reference
continuwuation/continuwuity#739
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
more info required
Logs from mautrix-discord's side:

Some people with similar setups haven't encountered this, so may be to do with database corruption caused by the appservice EDU patch
@Jade wrote in continuwuation/continuwuation#739 (comment):
I've managed to repro on transgender.ing before, which never ran the patch. Can't say for sure
Can reproduce with OOYE, never ran whatever patch that was. Can I ask if the repeat messages would have different txnids?
Can reproduce, also it seems to happen when lots of events are firing at the same time, like redacting message or banning user on multiple rooms.
@NoaHimesaka1873 wrote in #739 (comment):
More specifically, for me, it happens when Meowlnir sending "Redacted (n) events from (user) in (channel)" message, and this message getting bridged by mautrix-discord bot.
How can I help debug this? I am pretty sure I am hitting this problem with OOYE and duplicated messages.
Happy to dig into code/compile stuff etc.
First step is likely getting a debug build with traces going, and then watching for suspicious logs around appservices. It might be easier if you can reproduce it in an artificial environment
Lemme put up a debug homeserver setup.
Set up a brand new homeserver and ooye instance with dev continuwuity + trace
Blah:
wtfrog sec...
You have to build with --no-default-features --features default to get all log levels I believe.
Hmm... The way you are meant to build the container is just the Dockerfile in
/dockerright?Also something to note... that Out of Your Element bot was repeating its own messages there...
Think I figured out my problem, I was not using buildx, just trying to manually build and it missed a bunch of stages.