Open dfolio opened 1 year ago
I'm not sure what the underlying cause of this issue, but I don't think this is a Quarto bug (at least not with the latexmk runner). Specifically, after each run, we are detecting that another compilation is required because of the following issue:
LaTeX Warning: There were undefined references.
Package biblatex Warning: Please (re)run BibTeX on the file(s):
(biblatex) test
(biblatex) and rerun LaTeX afterwards.
You can use the option latex-clean: false
to keep intermediate files around post compilation, which can be helpful when trying to figure out what is going on with the pdf compilation.
I assume that YAML-encoded references are, up to now, only supported for the cite-method: citeproc in Quarto.
This is only support by Pandoc's Citeproc as described in Pandoc's Manual (https://pandoc.org/MANUAL.html#specifying-bibliographic-data). If using --natbib
or --biblatex
, a bibliography
file is needed.
With cite-method: natbib only 3 runs are made, but still without bibliography in the pdf output.
Regarding nocite
field, I don't think Pandoc does handle it correctly right now. \nocite
command should be added in body and not in header I believe. So if you add \nocite{*}
in your document you should get the reference
---
title: "example backend=bibtex"
author: "D. Folio"
format:
pdf:
cite-method: natbib
keep-tex: true
bibliography: bibtex.bib
---
## Quarto
Quarto enables you to weave together content and executable code into a finished document. To learn more about Quarto see <https://quarto.org>.
\nocite{*}
I don't know a lot about [backend=bibtex]
, but I do believe the infinite loop here is due to the fact that \nocite{}
is not handled, and that there is no reference found. This seems to be LaTeX issues and I am not sure how Quarto should handle this differently.
Bug description
I try to render a PDF using
and the compilation end with
WARNING: maximum number of runs (9) reached
. Increasinglatex-max-runs:99
, does not solve the issue.As there are no
latex-max-runs
in pandoc, I think this may be related to Quarto.Similar behavior occurs when using YAML-encoded references (instead of an external bibliography) with either
backend=bibtex
orbackend=biber
. Withcite-method: natbib
only 3 runs are made, but still without bibliography in the pdf output. I assume that YAML-encoded references are, up to now, only supported for thecite-method: citeproc
in Quarto. Perhaps a notice on the references page should point this out. Especially,biblatex
andnatbib
are intended for use in producing a LaTeX file that can be processed with bibtex or biber, as mentioned in Pandoc documentation.Steps to reproduce
Here a basic Quarto document (named
example-bibtex.qmd
):example of
bibtex.bib
or with YAML-encoded references
and run
quarto render example-bibtex.qmd
Expected behavior
A similar behavior as with
biblatexoptions: [backend=biber]
Actual behavior
With YAML-encoded references , empty bibliography file are generated.
The references are not rendered in the
example-bibtex.pdf
.Your environment
Quarto check output