Open turt2live opened 7 years ago
This issue is fixed through extension renaming --rename the file from .ico to .png and it will work.
@Art10001 I think you mean worked around :P
Trying to use .ico for User Avatar has a fun behaviour works in Settings pane and works if you go to full image but because Synapse can't thumbnail the ico, it fails elsewhere
weirdly for me this did not revert the room Avatar, but entirely unset it
OH, looking at the original situation, that may be what happened (unless Travis really had a room with his face on)
This is insanity, so ICO does seem to thumbnail ok in some cases, but there is some...inconsistency
Fire up https://riot.ovh/_matrix/media/v1/download/riot.ovh/rowshuMtUMQCiabHbhCufWct?width=800&height=600 and refresh 10 times, you'll probably see multiple images...
I was looking into this and found that the server some times fail to thumbnail some images https://github.com/matrix-org/synapse/blob/master/synapse/rest/media/v1/thumbnailer.py
Now working on a solution which will use original image url in case thumbnail not available.
On the sdk https://github.com/matrix-org/matrix-js-sdk/blob/d76e8be4ffa5e4b9726660976be7be929bfe35a2/src/content-repo.js#L62 this function is returning /thumbnail url without checking if is exist on the server.
Does anybody know how to check if image is available on server before returning the url? couldn't find it myself.
@agent3bood If the server returns an MXC URL, it should be available on the server.
Please check https://github.com/matrix-org/matrix-react-sdk/pull/1485 This is my first PR here, be easy on me.
Only way to
Does anybody know how to check if image is available on server before returning the url? couldn't find it myself.
is to GET or HEAD the /thumbnail url
Updated the OP to advertise the bounty :)
Description
When using an *.ico file, like this one, Riot tries the upload, considers it successful, and update the local avatar to match the new file. Once the settings pane is dismissed, the icon reverts to whatever it was before.
Steps to reproduce
I would have expected Riot to tell me it was an unsupported file type, or the icon change to work.
Log: not sent
After uploading image:
After closing settings pane:
Version information