matrix-org / matrix-appservice-discord

A bridge between Matrix and Discord.
Apache License 2.0
792 stars 148 forks source link

Bridging broken with Dendrite 0.9.6 #841

Closed tux93 closed 1 year ago

tux93 commented 1 year ago

Describe the bug After updating to Dendrite 0.9.6 matrix-appservice-discord no longer works and is throwing exceptions. Also reported at Dendrite

To Reproduce Steps to reproduce the behavior:

  1. Install Dendrite 0.9.6 and DiscordAS 3.0.0
  2. Bridge some Rooms
  3. Send some messages
  4. For every message an exception is logged, no messages are delivered to or from Discord

Expected behavior Messages are sent to and received from Discord

Desktop (please complete the following information):

Additional context

Sep 01 22:36:12 node[6098]: Sep-1 22:36:12.721 [DiscordAS] error: Exception thrown while handling "room.event" event TypeError: Cannot read properties of undefined (reading 'age')
Sep 01 22:36:12 node[6098]:     at MatrixEventProcessor.<anonymous> (/home/matrix-discord/matrix-appservice-discord/src/matrixeventprocessor.ts:94:28)
Sep 01 22:36:12 node[6098]:     at Generator.next (<anonymous>)
Sep 01 22:36:12 node[6098]:     at /home/matrix-discord/matrix-appservice-discord/build/src/matrixeventprocessor.js:23:71
Sep 01 22:36:12 node[6098]:     at new Promise (<anonymous>)
Sep 01 22:36:12 node[6098]:     at __awaiter (/home/matrix-discord/matrix-appservice-discord/build/src/matrixeventprocessor.js:19:12)
Sep 01 22:36:12 node[6098]:     at MatrixEventProcessor.OnEvent (/home/matrix-discord/matrix-appservice-discord/build/src/matrixeventprocessor.js:78:16)
Sep 01 22:36:12 node[6098]:     at /home/matrix-discord/matrix-appservice-discord/src/discordas.ts:211:34
Sep 01 22:36:12 node[6098]:     at Generator.next (<anonymous>)
Sep 01 22:36:12 node[6098]:     at fulfilled (/home/matrix-discord/matrix-appservice-discord/build/src/discordas.js:5:58)
Sep 01 22:36:12 node[6098]:     at processTicksAndRejections (node:internal/process/task_queues:96:5)
Half-Shot commented 1 year ago

That sounds like we're relying on the unstable field age.