Af_youtube_embed stopped embedding YouTube videos

As the title says, af_youtube_embed plugin stopped embedding YouTube videos into body of feed posts after a recent update.

  • It’s the web version of TT-RSS, so I’m not referring to API.
  • I’ve tried to install a fresh copy of latest version of TT-RSS. New DB and untouched files and everything. It’s the same. What you see is just a link to YouTube video, not an embedded video.
  • I’m on Tiny Tiny RSS v21.02-6f29ecbbb (latest version as of 22 February 2021).
  • I’ve also tried it on TT-RSS demo website. It’s the same.

Steps to reproduce the problem:

  1. Head over to https://srv.tt-rss.org/tt-rss/ and sign in by using demo/demo credentials.
  2. Open Preferences > Plugins settings page
  3. Check af_youtube_embed plugin and make sure no_iframes plugin is unchecked.
  4. Click on Enable Selected Plugins button and then exit Preferences page.
  5. Subscribe to feed of a random YouTube channel
    e.g. National Geographic
    https://www.youtube.com/feeds/videos.xml?channel_id=UCpVm7bg6pXKo1Pr6k5kxG9A

After feeds are updated, you’ll see each post shows a hyper link instead of an embedded video.

In plugin descriptions, af_youtube_embed says

Embed videos in Youtube RSS feeds (and whitelist Youtube iframes)

So, I expect it to work without any additional setting/configuration, which it used to do in the past.

ps.
I read a post where Fox said YouTube is one of the few white listed websites when it comes to iframes. So, I think this may be a bug which was introduced during a recent amendment by mistake.

Feel free to test it on TT-RSS demo website and see it yourself. Also, don’t hesitate to chime in and tell me if somehow I’m missing something here.

it’s another victim of HOOK_RENDER_ENCLOSURE. i’ll take a look, thanks for the youtube feed.

this brings back the aforementioned hook and fixes af_youtube_embed:

https://git.tt-rss.org/fox/tt-rss/commit/33fff2686946021314a24feef61032beaf48e7a4

note for other plugin writers, previously this hook (and this hook only) used a slightly different format for enclosure entries, i’ve removed it and it uses whatever tt-rss is uses internally, for consistency.

the only real difference is $entry["url"] becoming $entry["content_url"].