Google photos images not downloaded

It seems that Discourse doesn’t see that Google image links are images in order to know to download them locally.

I noticed this first on a multi-site instance, and then checked on try.

Here’s this url https://photos.app.goo.gl/KXa79xi3R82sjisX8 that renders beautifully into an image, but it never gets pulled down locally. I think it’s because the stupid Google doesn’t make those URLs end in .jpg the way God intended and there’s nothing that can be done, but I thought I’d ask anyway.

Google Photos

1 Like

Interesting … what about flickr?

I think this is not specific to google, its more of an all onebox thing, @techAPJ any idea why this is happening.

Also … behold my ninja hamster above, so cute, yet so dangerous.

5 Likes

Kind of a scope creep, let’s focus on other things for now. It’s been this way forever.

Yeah I remember this popping up before, I am just a bit surprised cause I thought @vinothkannans fixed this a while back.

https://meta.discourse.org/t/download-images-for-oneboxes-as-well-if-download-images-is-set/21103/30?u=sam

3 Likes

Oh aha maybe @vinothkannans can take a peek next week if he already worked on it before.

3 Likes

We already downloading onebox images. The issue here is “Google Photos” not using file extension in the image URLs. So we are unable to fetch it from the post content. Anyway we can achieve it by adding a special case for Google. Added to my list.

Why it’s not working :thinking:. It have valid image URL (https://c1.staticflickr.com/1/18/24130109_68f93566b9_m.jpg) inside onebox html.

3 Likes

Why do we need this though? Should we not just try to download everything that is <img src="https://site.com/i_must_be_an_image">, it will come back with a mime type.

1 Like

Yes, good question. We should download everything in img src. I will investigate further :+1:

5 Likes

I’ve fixed it here.

https://github.com/discourse/discourse/commit/6aee22b88f61184c0fdf03c7fc16c4cfea4ed5cd

https://github.com/discourse/onebox/commit/ebb4b54548d51bb63923959a16f106f787f2ad48

4 Likes

This topic was automatically closed after 5 days. New replies are no longer allowed.