mautrix / whatsapp

A Matrix-WhatsApp puppeting bridge
https://maunium.net/go/mautrix-whatsapp
GNU Affero General Public License v3.0
1.29k stars 175 forks source link

Response from whatsappbot not arriving on homeserver, but bridge/Synapse logs tell me messages are being sent/received #577

Closed Janbong closed 1 year ago

Janbong commented 1 year ago

Hi,

I had a working setup of synapse + mautrix-whatsapp and other bridges. Suddenly the whatsapp bridge stopped working. I fully reconfigured everything from scratch, but I can't seem to get it to work again.

I can see in both the mautrix-whatsapp AND the synapse logs that messages are being sent with 200 http codes, but they never seem to arrive on any of my Matrix clients.

Seems related to this issue with the telegram bot: https://github.com/mautrix/telegram/issues/844

Btw, I tried to join the #whatsapp:maunium.net matrix group instead of making a Github issue, but it seems to be down? Or is it just me?

Thanks in advance for the help.

Janbong commented 1 year ago

snippet from Synapse logs

2022-12-14 17:03:37,743 - synapse.http.client - 446 - INFO - as-sender-whatsapp-19 - Received response to PUT http://mautrix-whatsapp:29318/transactions/7040?access_token=<redacted>: 200
2022-12-14 17:03:37,958 - synapse.http.client - 446 - INFO - as-sender-whatsapp-20 - Received response to PUT http://mautrix-whatsapp:29318/transactions/7041?access_token=<redacted>: 200

snippet from Mautrix-Whatsapp logs

[Dec 14, 2022 16:39:57] [Matrix/Bot/DEBUG] req #17: POST https://matrix.bngrs.net/_matrix/client/v3/rooms/%21XiaslTBHKajUlXxDiL:bngrs.net/join?user_id=%40whatsappbot%3Abngrs.net <default empty object>
[Dec 14, 2022 16:39:57] [Matrix/Bot/DEBUG] req #17 (/v3/rooms/!XiaslTBHKajUlXxDiL:bngrs.net/join) completed in 74.632838ms with status 200 and 43 bytes of application/json body
[Dec 14, 2022 16:39:57] [Matrix/Bot/DEBUG] req #18: GET https://matrix.bngrs.net/_matrix/client/v3/rooms/%21XiaslTBHKajUlXxDiL:bngrs.net/joined_members?user_id=%40whatsappbot%3Abngrs.net
[Dec 14, 2022 16:39:57] [Matrix/Bot/DEBUG] req #18 (/v3/rooms/!XiaslTBHKajUlXxDiL:bngrs.net/joined_members) completed in 13.622833ms with status 200 and 200 bytes of application/json body
[Dec 14, 2022 16:39:57] [Matrix/DEBUG] Starting handling of transaction 6966 (1 PDUs)
[Dec 14, 2022 16:39:57] [Matrix/Bot/DEBUG] req #19: PUT https://matrix.bngrs.net/_matrix/client/v3/rooms/%21XiaslTBHKajUlXxDiL:bngrs.net/send/m.room.message/mautrix-go_1671035997526717449_7?user_id=%40whatsappbot%3Abngrs.net {"msgtype":"m.notice","body":"Hello, I'm a WhatsApp bridge bot."}
[Dec 14, 2022 16:39:57] [Matrix/Bot/DEBUG] req #19 (/v3/rooms/!XiaslTBHKajUlXxDiL:bngrs.net/send/m.room.message/mautrix-go_1671035997526717449_7) completed in 72.499844ms with status 200 and 59 bytes of application/json body
[Dec 14, 2022 16:39:57] [Matrix/Bot/DEBUG] req #20: PUT https://matrix.bngrs.net/_matrix/client/v3/rooms/%21XiaslTBHKajUlXxDiL:bngrs.net/send/m.room.message/mautrix-go_1671035997603796552_8?user_id=%40whatsappbot%3Abngrs.net {"msgtype":"m.notice","body":"This room has been registered as your bridge management/status room."}
[Dec 14, 2022 16:39:57] [Matrix/DEBUG] Starting handling of transaction 6967 (1 PDUs)
[Dec 14, 2022 16:39:57] [Matrix/Bot/DEBUG] req #20 (/v3/rooms/!XiaslTBHKajUlXxDiL:bngrs.net/send/m.room.message/mautrix-go_1671035997603796552_8) completed in 64.826009ms with status 200 and 59 bytes of application/json body
[Dec 14, 2022 16:39:57] [Matrix/DEBUG] !XiaslTBHKajUlXxDiL:bngrs.net registered as a management room with @jan:bngrs.net
[Dec 14, 2022 16:39:57] [Matrix/Bot/DEBUG] req #21: PUT https://matrix.bngrs.net/_matrix/client/v3/rooms/%21XiaslTBHKajUlXxDiL:bngrs.net/send/m.room.message/mautrix-go_1671035997670268688_9?user_id=%40whatsappbot%3Abngrs.net {"msgtype":"m.notice","body":"Use `help` for
help or `login` to log in.","format":"org.matrix.custom.html","formatted_body":"Use \u003ccode\u003ehelp\u003c/code\u003e for help or \u003ccode\u003elogin\u003c/code\u003e to log in."}
[Dec 14, 2022 16:39:57] [Matrix/DEBUG] Starting handling of transaction 6968 (1 PDUs)
[Dec 14, 2022 16:39:57] [Matrix/Bot/DEBUG] req #21 (/v3/rooms/!XiaslTBHKajUlXxDiL:bngrs.net/send/m.room.message/mautrix-go_1671035997670268688_9) completed in 54.568623ms with status 200 and 59 bytes of application/json body
[Dec 14, 2022 16:39:57] [Matrix/DEBUG] Starting handling of transaction 6969 (1 PDUs)
[Dec 14, 2022 16:39:58] [Matrix/DEBUG] Starting handling of transaction 6970 (1 PDUs)
[Dec 14, 2022 16:40:02] [Matrix/DEBUG] Starting handling of transaction 6971 (1 EDUs (unstable))
....
...
tulir commented 1 year ago

You probably ignored the bot