TryGhost/Ghost

Bookmark for YouTube links not populated with video metadata

Fechada

#24.741 aberto em 24 de ago. de 2025

 (1 comentário) (0 reação) (0 responsável)JavaScript (11.888 forks)batch import
bugcommunitygood first issue

Métricas do repositório

Stars
 (54.780 estrelas)
Métricas de merge de PR
 (Mesclagem média 19d 11h) (658 fundiu PRs em 30d)

Description

Issue Summary

Helloo!

When adding a /bookmark to a post using a YouTube video link, it fills the bookmark card with generic info rather than a card containing the video's metadata.

Recently, I tried this on v5.129.1 with Firefox & iOS Safari, then upgraded to v6.0.5 using ghost-cli, and tried again with both. But I've had it with earlier versions too.

If this is something silly that I've done rather than a bug, then no problem at all!

Video as a bookmark card vs an embed

Metadata from the youtube video's page

<meta property="og:site_name" content="YouTube">
<meta property="og:url" content="https://www.youtube.com/watch?v=0i1Xz-xiYSU">
<meta property="og:title" content="What happens in the European Space Agency's Mission Control?">
<meta property="og:image" content="https://i.ytimg.com/vi/0i1Xz-xiYSU/maxresdefault.jpg">
<meta property="og:image:width" content="1280">
<meta property="og:image:height" content="720">
<meta property="og:description" content="The European Space Agency invited me to their mission control centre in Germany to find out what it takes to be a Satellite Operations Engineer working on th...">

Steps to Reproduce

  1. edit a page
  2. /bookmark
  3. paste youtube url
  4. hit enter

Ghost Version

5.129.1, 6.05

Node.js Version

v22.18.0

How did you install Ghost?

Linux 6.8.0-78-generic #78-Ubuntu SMP PREEMPT_DYNAMIC Tue Aug 12 11:34:18 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux

Database type

MySQL 8

Browser & OS version

Firefox 139.0.4 (aarch64) / Safari on iOS 18.5

Relevant log / error output

$ ghost log
[2025-08-24 12:29:03] ERROR

MESSAGE: Failed to parse URL from null

TypeError: Failed to parse URL from null
    at node:internal/deps/undici/undici:13510:13
    at async OEmbedService.fetchImageBuffer (/var/www/ghost/versions/6.0.5/core/server/services/oembed/OEmbedService.js:136:26)
    at async OEmbedService.processImageFromUrl (/var/www/ghost/versions/6.0.5/core/server/services/oembed/OEmbedService.js:156:29)
    at async OEmbedService.fetchBookmarkData (/var/www/ghost/versions/6.0.5/core/server/services/oembed/OEmbedService.js:349:13)
    at async getResponse (/var/www/ghost/versions/6.0.5/node_modules/@tryghost/api-framework/lib/pipeline.js:259:34)
    at async ImplWrapper (/var/www/ghost/versions/6.0.5/node_modules/@tryghost/api-framework/lib/pipeline.js:264:30)
    at async Http (/var/www/ghost/versions/6.0.5/node_modules/@tryghost/api-framework/lib/http.js:70:28)

[2025-08-24 12:29:03] INFO "GET /ghost/api/admin/oembed/?url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D0i1Xz-xiYSU&type=bookmark" 200 1485ms
[2025-08-24 12:29:03] INFO "GET /content/images/icon/favicon_144x144-14.png" 200 2ms


$ ghost version
Ghost-CLI version: 1.28.3
Ghost version: 6.0.5 (at [REDACTED])

$ ghost doctor
✔ Checking system Node.js version - found v22.18.0
✔ Checking logged in user
✔ Ensuring user is not logged in as ghost user
✔ Checking if logged in user is directory owner
✔ Checking current folder permissions
✔ Checking system compatibility
✔ Checking for a MySQL installation
+ sudo systemctl is-active [REDACTED]
Instance is currently running
ℹ Validating config [skipped]
✔ Checking folder permissions
✔ Checking file permissions
✔ Checking content folder ownership
✔ Checking memory availability
✔ Checking binary dependencies
✔ Checking free space
✔ Checking systemd unit file
✔ Checking systemd node version - found v22.18.0

Code of Conduct

  • I agree to be friendly and polite to people in this repository

Guia do colaborador