You sure it's not just your app? Works fine for me
Feddit UK
Community for the Feddit UK instance.
A place to log issues, and for the admins to communicate with everyone.
Hello, Connect dev here but I'll also tag the Thunder dev @darklightxi@lemmy.world as far as I know we're the two Flutter based front-ends.
The issue I believe seems to be with how the URI gets parsed for Bluesky. Since the URL path ends with @jpeg?.jpg
the uri.path that I get ends up being "/img/feed_fullsize/plain/did:plc:wf7nfy2us3h5gpa7zfettmzl/bafkreidiiq5pzo4dec3o32z4okokwo5vz55ykd5vsm7ltqkxzrfpwnah64@jpeg"
instead of the typical some_path/some_image.jpg
. So when the code checks if the url is an image it doesn't find a file extension and reports that this is a link and not an image. The simplified form of what I'm doing app-side is
List<String> imageFormats = [
"jpg",
...
];
var uri = Uri.parse(url);
var extension = uri.path.split('.').last;
if (imageFormats.contains(extension)) {
return true;
}
...
For some instances this is not a problem since they are proxying all image requests which is why it might be happening only on specific instances for you.
I'll roll this fix into the next version, which should be rolling out tonight.
I'm not entirely sure what you did, but that has fixed it - thanks!
If you don't mind me asking, but what's the reason you're detecting images like this instead of using the MIME type Lemmy indicates (or hell, the one in the Content-Type header from GET'ting the URL)?
Hey there, fellow Flutter dev! 👋
Thanks for tagging me in this and bringing this to my attention! I'll take a look at this issue on my end as well and apply some fixes to it.
It might be the weird format Bluesky uses for image links:
https://cdn.bsky.app/img/feed_fullsize/plain/did:plc:wf7nfy2us3h5gpa7zfettmzl/bafkreib6k2uwcy52wi654fdfmfqakzqu54m4eq7vi6cwrolwud6yhehihy@jpeg?.jpg
It show up fine in the API:
~> curl https://feddit.uk/api/v3/post?id=26413986 | jq .post_view.post
{
"id": 26413986,
"name": "Daily bunny no.2906 is making waves",
"url": "https://cdn.bsky.app/img/feed_fullsize/plain/did:plc:wf7nfy2us3h5gpa7zfettmzl/bafkreib6k2uwcy52wi654fdfmfqakzqu54m4eq7vi6cwrolwud6yhehihy@jpeg?.jpg",
"body": "[…]",
"creator_id": 16021247,
"community_id": 683956,
"removed": false,
"locked": false,
"published": "2025-03-27T03:33:21.968620Z",
"deleted": false,
"nsfw": false,
"thumbnail_url": "https://cdn.bsky.app/img/feed_fullsize/plain/did:plc:wf7nfy2us3h5gpa7zfettmzl/bafkreib6k2uwcy52wi654fdfmfqakzqu54m4eq7vi6cwrolwud6yhehihy@jpeg?.jpg",
"ap_id": "https://lemmings.world/post/23311812",
"local": false,
"language_id": 37,
"featured_community": false,
"featured_local": false,
"url_content_type": "image/jpeg"
}
The only difference between us and .ca is they generate a thumbnail_url
, while we don't (I turned that off when Lemmy had thumbnail issues).
Tested some apps I have (I don't have Connect). In Thunder it show up as a link, in Jeboa and Voyager it shows up as an image like you'd expect.
Hmm, maybe it's the thumbnail URL causing it?
Connect really shouldn't use the thumbnail_url
as an image link post-0.19.6 (see here). I can turn it back on, but that only fixes the issue for us, we're not the only instance with thumbnail generation turned off (e.g. lemm.ee).
Even when it is displayed "as expected" as you put it, it seems to be displaying a thumbnail preview of the website rather than embedding the image directly. I'm experiencing a similar problem in Thunder.