DOC: Add thumbnail for hyperlinks_sgskip gallery example#31377
DOC: Add thumbnail for hyperlinks_sgskip gallery example#31377abhinavjha98 wants to merge 3 commits intomatplotlib:mainfrom
Conversation
Set a dedicated gallery thumbnail path and add a compact PNG thumbnail for the hyperlinks sgskip example to address missing-docs thumbnail coverage. Made-with: Cursor
Made-with: Cursor
Point the gallery thumbnail path to a committed SVG generated from the example output so the sgskip example has a stable docs thumbnail without changing execution behavior. Made-with: Cursor
|
Thank you for opening your first PR into Matplotlib! If you have not heard from us in a week or so, please leave a new comment below and that should bring it to our attention. Most of our reviewers are volunteers and sometimes things fall through the cracks. We also ask that you please finish addressing any review comments on this PR and wait for it to be merged (or closed) before opening a new one, as it can be a valuable learning experience to go through the review process. You can also join us on gitter for real-time discussion. For details on testing, writing docs, and our review process, please see the developer guide. We strive to be a welcoming and open project. Please follow our Code of Conduct. |
|
Can you just set the path to the svg produced by the PR? Or if you're gonna use a screenshot, can it somehow highlight the URL part since that's what's important about this example? |
I set sphinx_gallery_thumbnail_path to a committed SVG (doc/_static/hyperlinks_thumbnail.svg) generated from the example output. Since this example is _sgskip, build-time scatter.svg is not guaranteed to exist, so referencing a checked-in SVG is more reliable. I can also provide an annotated screenshot if preferred, but I used the generated SVG to stay closest to the example output. |
Does it have to be sgskip if it's given a manual thumbnail path? |
|
Yes, it still needs to be |
Why is this necessary? Why does sphinx-gallery care if this is skipped? What happens if you don't skip this? |
PR summary
Adds a thumbnail for the
hyperlinks_sgskipgallery example, which was missing one (showing a placeholder blob instead).The example uses the SVG backend and saves output directly to disk, so it carries the
_sgskipsuffix meaning sphinx-gallery does not execute it automatically. Since the image scraper cannot capture a thumbnail from it, this PR manually sets one usingsphinx_gallery_thumbnail_path.The thumbnail is an SVG screenshot of the grayscale image plot produced by the example.
Closes part of #17479