mautrix/whatsapp

Media sent on Matrix isn't downloaded (and sent) by the bridge

Closed this issue · 2 comments

General info:
Matrix server: Synapse
Synapse version: 1.106.0
mautrix-whatsapp version: v0.11.1+dev.[3e9bf5a] installed on docker
Client: Schildichat version 1.6.22.sc81 on android, but other clients have the same error
Host OS: DietPi v9.8.0 with everything updated as of the 28th of November
Host device: Raspberry Pi 4B (8GB Ram version)

Steps to reproduce:

  • Enter a room
  • Send any type of media (Images, Videos, etc)
  • The message gets sent to the synapse server, but it doesn't get bridged to whatsapp and the bot replies with
    ⚠️ Your message was not bridged: failed to download media

Logs:
The Mautrix-whatsapp logs say:

ERR Failed to handle Matrix message error="failed to convert message: failed to download media: failed to GET /_matrix/client/v1/media/download/xxxxxxxxxx/FHshbKvJpkxIvCsYCrjtsmMY: M_UNRECOGNIZED (HTTP 404): Unrecognized request" action="handle matrix event" event_id=$xxxxzzxzzzzxz event_loop_index=1 event_type=m.room.message login_id=xxxxxxxxx portal_id=xxxxxxxxxxx portal_mxid=!xxxxxxxxxx sender=@xxxxxxxxxxx

The xxxx are redacted info, the server URL, login ID and everything else are all there in reality.

There doesn't seem to be anything on the Synapse logs that relates to this error

That said, it could be my jank setup with synapse installed by the dietpi software installer and mautrix on docker with host network access, but until the recent update (0.11.1) everything regarding images was working fine. I do need to mention that I was behind on updating and skipped the 0.11.0 version, directly going from 0.10.9 to 0.11.1, but no errors were shown during that and normal messages still get bridged just fine.

What I tried

Navigating to mydomain.example/_matrix/client/v1/media/download/mydomain.example/FHshbKvJpkxIvCsYCrjtsmMY from a browser (firefox, but i don't think it matters) gives another error,
{"errcode":"M_UNRECOGNIZED","error":"Unrecognized request"}

Meanwhile, going to mydomain.example/_matrix/media/r0/download/mydomain.example/FHshbKvJpkxIvCsYCrjtsmMY (of course in both examples mydomain.example is the actual domain) gives the image I sent in the matrix room, ready to be grabbed from the bridge

What I didn't figure out yet

Is this a misconfiguration on my part and the image should be on the URL that the bridge is fetching or does the bridge fetch the wrong URL?

tulir commented

Outdated synapse

Updated, but the problem still persists

EDIT: my pip was messed up and synapse was indeed outdated while showing it as up to date, thanks so much for the support and sorry for wasting your time