Open elina2015 opened 2 years ago
If the gif is not valid, we should just display the link as a link and not show the LinkMessageView
Ok, so the problem is that the corrupted gif link is correct, we didn't receive an error from the server, but received a 43 bytes gif, which is empty Tried to validate such a gif via QMovie->isValid() and QImage -> format - everything recognized ok
The only solution I see right now is to load the gif in memory, and check if it is bigger than 43 bytes (this is for the tenor vendor, need to check for another). If less or equal - gif is empty and should not be displayed
As discussed during the meeting, we'll try the ad hoc fix, since the issue is pretty minor and we don't want to spend too much time on a fix for that.
You can open another issue for a later milestone to move the fix to status-go and do a HEAD on the file to check filesize like you said. We just need to make sure to only do that when the gif setting is ON
@mprakhov17 you can do the fancy status-go solution for this one. Reminder: check the setting first if gif is enabled. We do not want to download or HEAD any outside file unless the user actually accepted it.
this is how it looks like
@mprakhov what would be the state/solution of this?
Unfortunately, I do not remember the whole context, as it was a lot of time ago, it require digging into the problem again
@mprakhov from your comment I understand that since there is no indication whether the GIF exists or not we could check the file size, and from @jrainville's comment, this needs to be done in go, if so I would mark this issue as messenger-team
.
I don't have any objections to assign it on messenger team
moved to 2.29 due to lack of space in this milestone
the current behaviour now is that actually the old gif remains regardless of any edits
Bug Report
Description
Steps to reproduce
Expected behavior
The correct default broken GIF image is shown
Actual behavior
The incorrect grey form is shown
Additional Information
Status desktop version: https://github.com/status-im/status-desktop/releases/tag/0.8.0-rc.9 Operating System: macOS Monterey
NOTES: 43 bytes gif is received. We must do a validation on status_go side