element-hq / element-hq/synapse
webp images don't appear to thumbnail correctly, sometimes
- Dominant language
- Python
- Stars
- 4.6k
- Forks
- 600
- Avg merge
- 5d 22h
- Merged PRs (30d)
- 51
Description
This issue has been migrated from [#13607](https://github.com/matrix-org/synapse/issues/13607).
---
Tested with image: https://matrix-client.matrix.org/_matrix/media/r0/thumbnail/matrix.org/NhXqgLrnxWBLDijZfPdkebex?width=800&height=600&method=scale
The event:
```json
{
"content": {
"body": "1.sm.webp",
"info": {
"h": 214,
"mimetype": "image/webp",
"size": 10474,
"thumbnail_info": {
"h": 214,
"mimetype": "image/png",
"size": 111399,
"w": 320
},
"thumbnail_url": "mxc://matrix.org/IERMYhtRkHBmQPJAQvPkKjSM",
"w": 320,
"xyz.amorgan.blurhash": "L:CHWyR-RPae.TRkR*oM.8WYR.f6"
},
"msgtype": "m.image",
"url": "mxc://matrix.org/NhXqgLrnxWBLDijZfPdkebex"
},
"origin_server_ts": 1661287579310,
"sender": "@travisr_github:matrix.org",
"type": "m.room.message",
"unsigned": {
"age": 16824,
"transaction_id": "m1661287578061.1"
},
"event_id": "$szqt1kDU19np2xfg7l0vStUF-tr6wHyrYcYUtFo8_jo",
"room_id": "!GGEAWumnYnZnKVDuDO:matrix.org"
}
```
The image: https://www.gstatic.com/webp/gallery/1.webp
For matrix.org users, it looks something like this because of the 400 HTTP error code:

on alternative (😇) media repos it appears to work fine:

----
Note: I don't know what the error could be on matrix.org's side. Some people report being able to see the thumbnail correctly, so presumably it's something to do with sizing/method combination from different devices and/or client decisions?
Also tested with `mxc://t2l.io/21fb55d639cc38839f3e1b6eb3846487aa1dfcc3` (thumbnailed as `mxc://t2l.io/f624dc59738478bab082190fe1234b194b7e63c9`) with similar results.
Contributor guide
Assessment
This issue has not been assessed yet.