Recently my users have reported a problem with YouTube video embeds. Some of the YouTube links just work as before, some get partially embedded, some embeds are fully broken.
Example:
(Fully working)
(Has picture - no title)
(no picture, no title)
It seems that YouTube embed link https://www.youtube.com/embed/{video_id} is not working for the videos with partial oneboxes.
I did check it out manually and thumbnails are sometimes loaded a bit slower, but nothing that bad. For now as well I see consistent results. If onebox does not work for a video, it newer works.
As far as I have tested post rebuild produces the same result each time. I might add that meta.discourse.org behaves in the exactly the same way as my Discourse installation.
Hi @WaitroseCarpark, as Sam mentioned, it does seem to be related to the server’s IP address attempting to access those videos, likely due to changes YouTube has made to prevent bots. However, we’re still investigating the issue.
In the meantime, I’ve merged this PR, which should help in cases where video metadata is unavailable:
Are you still experiencing these issues after applying this patch?
Thank you @jancernik - I’ve had a crack at asking discourse to cherry pick this fix using chatgpt as a guide (as above I’m waiting to come off dev channel) but it’s a little beyond my capability. Hopefully someone else who’s experiencing this can give it a go?
Actually - I think I’ve applied the fix. Tried a youtube video with known issues and same thing is happening. Although it would be nice to hear the same thing from another person as I’m not that good with docker/CLI stuff, it absolutely scares me to death