quarto-dev / quarto-dev/quarto-cli

Embed-resources does not work with Quarto project and just errors

Open
#11,206 14 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

books bug projects
Dominant language
JavaScript
Stars
6k
Forks
458
Avg merge
1d 9h
Merged PRs (30d)
41

Description

Bug description

Problem: quarto render fails when enabling self-contained or embed-resources in yaml.

Steps to reproduce:

  1. In terminal:
    > quarto create project book testbook
  2. Add the following to _quarto.yml (any of these options produce same error):
format:
  html:
    self-contained: true
    embed-resources: true
  1. Add to any qmd file:
```{r } 
#| label: test-plot

plot(1:10, 1:10)

  1. > quarto render

Result in error:

ERROR: 
compilation failed- error
Unable to load picture or PDF file 'intro_files/figure-pdf/test-plot-1.pdf'.

...and warning:

[WARNING] Could not fetch resource ./summary.html

Works when option quarto render --to html is used. Curiously, quarto render --to pdf also works if run separately.

System info:

quarto --version: 1.5.57 on Arch linux
This is XeTeX, Version 3.141592653-2.6-0.999995 (TeX Live 2023) (preloaded format=xelatex)

Steps to reproduce

No response

Expected behavior

quarto render should produce html and pdf book

Actual behavior

quarto render fails
quarto render --to html and quarto render --to pdf works

Your environment

Linux Version: 6.9.2.arch1-1
quarto --version: 1.5.57 on Arch linux
This is XeTeX, Version 3.141592653-2.6-0.999995 (TeX Live 2023) (preloaded format=xelatex)
R version 4.4.0

Quarto check output

> quarto check

Quarto 1.5.57
[✓] Checking versions of quarto binary dependencies...
Pandoc version 3.2.0: OK
Dart Sass version 1.70.0: OK
Deno version 1.41.0: OK
Typst version 0.11.0: OK
[✓] Checking versions of quarto dependencies......OK
[✓] Checking Quarto installation......OK
Version: 1.5.57
Path: /opt/quarto/bin

[✓] Checking tools....................OK
TinyTeX: v2023.12
Chromium: (not installed)

[✓] Checking LaTeX....................OK
Using: TinyTex
Path: /home/e/.TinyTeX/bin/x86_64-linux
Version: 2023

[✓] Checking basic markdown render....OK

[✓] Checking Python 3 installation....OK
Version: 3.12.3
Path: /usr/bin/python3
Jupyter: 5.7.2
Kernels: python3

(/) Checking Jupyter engine render....Traceback (most recent call last):
File "/opt/quarto/share/jupyter/jupyter.py", line 21, in
from notebook import notebook_execute, RestartKernel
File "/opt/quarto/share/jupyter/notebook.py", line 15, in
from yaml import safe_load as parse_string
ModuleNotFoundError: No module named 'yaml'
[✓] Checking Jupyter engine render....OK

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the failure with the shown _quarto.yml and qmd example, then compare combined quarto render with separate HTML and PDF renders. Trace the self-contained/embed-resources handling for the generated PDF resource and the summary.html warning; done means the example renders both book formats without errors.

Written by the indexing model from the issue text.

Assessment

Tech stack
latex, r
Domain
build-system, cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.