Skip to content

Opengraph preview not created automatically from a python-generated cell output image? #10311

@astrowonk

Description

@astrowonk

@cscheid Creating a new issue, per your request. The MRE repo is here.

Discussed in #10260

Here is an example repo, with two test blog posts. Both posts have preview images on the listing page.

In one post, I use the #| classes: preview-image and that post has <meta property="og:image" content="index_files/figure-html/fig-polar-output-1.png"> in the generated HTML.

In the other, I don't set the class in the cell, and there's no og:image in the metadata.

So, perhaps this is a bug?

(base) marcosh@Discovery:~/Developer/active_projects/quarto-ogimage(main) » quarto render                                                                                           
[1/4] posts/a-test-post-og/index.qmd

Starting python3 kernel...Done

Executing 'index.quarto_ipynb'
  Cell 1/1: 'fig-polar'...Done

[2/4] posts/a-test-post/index.qmd

Starting python3 kernel...Done

Executing 'index.quarto_ipynb'
  Cell 1/1: 'fig-polar'...Done

[3/4] index.qmd
[4/4] posts.qmd

Output created: _site/index.html

(base) marcosh@Discovery:~/Developer/active_projects/quarto-ogimage(main○) » cat _site/posts/a-test-post/index.html | grep og:image
(base) marcosh@Discovery:~/Developer/active_projects/quarto-ogimage(main○) » cat _site/posts/a-test-post-og/index.html | grep og:image                                               
<meta property="og:image" content="index_files/figure-html/fig-polar-output-1.png">

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingengines-jupyterAnything related to Jupyter engine

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions