# \[ANN\] Native Julia engine for quarto using QuartoNotebookRunner.jl

**URL:** <https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753>\
**Category:** Package Announcements\
**Created:** [April 10, 2024, 5:48am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753 "2024-04-10T05:48:52Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://discourse.julialang.org/u/jules)\
**Post date:** [April 10, 2024, 5:48am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/1 "2024-04-10T05:48:53Z")

</div>

The dev team at [PumasAI](https://pumasai.com/) is excited to announce that, after months of work, the quarto project has accepted [PR #8645](https://github.com/quarto-dev/quarto-cli/pull/8645) which adds a new, native Julia engine based on PumasAI’s [QuartoNotebookRunner.jl](https://github.com/PumasAI/QuartoNotebookRunner.jl/) package.  
The engine is now available in prereleases [Release v1.5.29 · quarto-dev/quarto-cli · GitHub](https://github.com/quarto-dev/quarto-cli/releases/tag/v1.5.29) until the release of quarto’s next minor version 1.5.

[Quarto](https://quarto.org/) is the successor to RMarkdown, and a widely used document authoring and publishing system based on Pandoc.

So far, Julia has been supported in quarto via an IJulia Jupyter kernel, which has a couple drawbacks:  
In addition to Julia, it requires a working Python and Jupyter installation, the correct configuration of the Julia kernel in this setup, and the availability of IJulia in the main Julia environment.  
Many users have been facing difficulties getting this system to work reliably due to its many moving parts, which in turn hinders adoption.

With our new engine, all that’s needed to get started with Julia and quarto is a working installation of each of those tools.  
At first render of a qmd file with the `engine: julia` setting, quarto will automatically install QuartoNotebookRunner into a separate environment, resulting in a frictionless user experience.

With quarto’s RMarkdown legacy, the R engine is currently the most featureful.  
With a native Julia engine, we now have more freedom to shape how exactly qmd files are rendered, and can potentially add features currently only available to R users.

All in all, with this work we are striving for a first-class Julia experience with quarto and we hope it will turn out to be useful for you all.

---

<div class="post-metadata">

**Author:** ![kellertuer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kellertuer/32/220707_2.png) [@kellertuer](https://discourse.julialang.org/u/kellertuer)\
**Post date:** [April 10, 2024, 6:52am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/2 "2024-04-10T06:52:08Z")

</div>

Hi,  
this is super great news, since currently my documenter CI / runs have a Python dependency, which I would get rid of with this.

Just to clarify (since I could not find instructions on the homepage – yet?) I would take my `_quarto.yml` configuration and replace

```julia
jupyter: julia-1.10

```

with

```julia
engine: julia

```

?

Because changing that does not seem to have en effect, the `quarto render myFile.qmd` still fires up a Jupyter (and temporary `ipynb` file).

---

<div class="post-metadata">

**Author:** ![huang\_min](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/huang_min/32/34337_2.png) [@huang\_min](https://discourse.julialang.org/u/huang_min)\
**Post date:** [April 10, 2024, 7:06am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/3 "2024-04-10T07:06:13Z")

</div>

The engine will soon be available in pre-releases until the release of quarto’s next minor version 1.5.

---

<div class="post-metadata">

**Author:** ![kellertuer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kellertuer/32/220707_2.png) [@kellertuer](https://discourse.julialang.org/u/kellertuer)\
**Post date:** [April 10, 2024, 7:08am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/4 "2024-04-10T07:08:06Z")

</div>

Thanks for the info; I did not see this. Hm, sad, I was super eager to try this out, because my current Documenter.jl workflow is a bit of a chaotic mess due to python dependencies for running quarto.  
And on the other hand the post here read like “just add `engine: Julia` and it works” which read for me – that it is released and not planned to be released somewhen in summer, but I know see I did not read the post careful enough.

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://discourse.julialang.org/u/jules)\
**Post date:** [April 10, 2024, 7:21am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/5 "2024-04-10T07:21:16Z")

</div>

The prereleases are made [every week or so](https://github.com/quarto-dev/quarto-cli/releases), one with this change included should drop soon ([Native Julia engine based on QuartoNotebookRunner.jl by jkrumbiegel · Pull Request #8645 · quarto-dev/quarto-cli · GitHub](https://github.com/quarto-dev/quarto-cli/pull/8645#issuecomment-2045551568)) and you should be able to use that in CI. The actual minor releases are on a slower schedule, that’s true.

I’ve highlighted the prerelease part now 🙂

---

<div class="post-metadata">

**Author:** ![kellertuer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kellertuer/32/220707_2.png) [@kellertuer](https://discourse.julialang.org/u/kellertuer)\
**Post date:** [April 10, 2024, 7:26am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/6 "2024-04-10T07:26:42Z")

</div>

Yes, sorry for not seeing the “on pre-release soon”.  
Currently I fear it might take me too much time to convince my brew (local installation) and the CI to use a pre-release (at least I fear that might take me quite some time). So I will probably juts wait. And don’t get me wrong, I subscribed to the PR already when I saw it to keep that in sight – I am really happy this is happening and look forward to trying it 🙂

---

<div class="post-metadata">

**Author:** ![svilupp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/svilupp/32/34933_2.png) [@svilupp](https://discourse.julialang.org/u/svilupp)\
**Post date:** [April 10, 2024, 8:28am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/7 "2024-04-10T08:28:33Z")

</div>

If anyone wants to try before the quarto pre-release happens:

Install quarto with

```julia
git clone https://github.com/quarto-dev/quarto-cli
cd quarto-cli
./configure.sh
# In my case I had to use sudo ./configure.sh

```

Test quarto version:

```julia
quarto --version 
# expected output: 99.9.9 
# you can also run `quarto check` to make sure all is setup correctly

```

If you’re getting something else, it’s your other quarto installation.

I added a simple alias in my .zshrc (depending on your shell):  
`alias quarto='/Users/USERNAME/.local/bin/quarto'`

My MWE quarto - notice the `engine: julia` in YAML header  
You need to `]add DataFrames, StatsPlots` in the environment you’re in

Create file `demo.qmd` with the following contents:

````julia
---
title: "StatsPlots Demo"
author: "xxx"
date: "1/1/1900"
format:
  html:
    code-fold: true
engine: julia
---

# Header 1
```{julia}
using DataFrames, StatsPlots
```

# Header 2
```{julia}
df = DataFrame(a = 1:10, b = 10 .* rand(10), c = 10 .* rand(10))
@df df plot(:a, [:b :c], colour = [:red :blue])
```

Second plot:
```{julia}
@df df scatter(:a, :b, markersize = 4 .* log.(:c .+ 0.1))
```

````

And then run your standard quarto render, eg,  
`quarto render demo.qmd --to html`

---

<div class="post-metadata">

**Author:** ![mike](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mike/32/39_2.png) [@mike](https://discourse.julialang.org/u/mike)\
**Post date:** [April 10, 2024, 8:40am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/8 "2024-04-10T08:40:38Z")

</div>

> [@svilupp](#):
>
> You need to `]add DataFrames, StatsPlots` in the environment you’re in

To add to that, since it’s not easily visible in any docs currently, note that you can control the flags passed to workers that run notebooks via the `julia.exeflags` key in a notebook’s frontmatter, so you can pick the `Project.toml` used via that rather than having to use the global environment. See [new feature: pure-Julia engine by cscheid · Pull Request #1071 · quarto-dev/quarto-web · GitHub](https://github.com/quarto-dev/quarto-web/pull/1071/files#diff-9f3c9f3cb11b61ea3468fd78dbd6ee2bcb04cdec2995484581a3d3841ea84b89R267) I’m sure their docs site will update with those details sometime soon.

---

<div class="post-metadata">

**Author:** ![devmotion](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/devmotion/32/9201_2.png) [@devmotion](https://discourse.julialang.org/u/devmotion)\
**Post date:** [April 10, 2024, 9:32am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/9 "2024-04-10T09:32:05Z")

</div>

An additional comment: By default, QuartoNotebookRunner starts the Julia process that the notebook is executed in with `--project=@.` ([Use `--project=@.` as default environment by devmotion · Pull Request #73 · PumasAI/QuartoNotebookRunner.jl · GitHub](https://github.com/PumasAI/QuartoNotebookRunner.jl/pull/73)), so if you put e.g. a Project.toml file next to the notebook it will be picked up automatically. This is the same behaviour as the [default IJulia kernel](https://julialang.github.io/IJulia.jl/stable/manual/usage/#Julia-projects). You can specify some (other) project environment by adding `"--project=myproject"` to the list of `julia.exeflags` or by setting the `"JULIA_PROJECT=myproject"` environment variable in the `julia.env` key.

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [April 10, 2024, 10:11am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/10 "2024-04-10T10:11:53Z")

</div>

Question: How PumasAI is using Quarto? Did you mean JuliaHub?

---

<div class="post-metadata">

**Author:** ![mike](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mike/32/39_2.png) [@mike](https://discourse.julialang.org/u/mike)\
**Post date:** [April 10, 2024, 10:14am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/11 "2024-04-10T10:14:43Z")

</div>

Currently, all publicly facing tutorials are written with quarto, [https://tutorials.pumas.ai/](https://tutorials.pumas.ai/). It is used internally as well for reporting etc.

---

<div class="post-metadata">

**Author:** ![VivMendes](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/vivmendes/32/16477_2.png) [@VivMendes](https://discourse.julialang.org/u/VivMendes)\
**Post date:** [April 10, 2024, 10:16am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/12 "2024-04-10T10:16:14Z")

</div>

It is always good to have different options to choose from. As I have never used Quarto as a Julia IDE, and I know Pluto quite well, what are the main advantages(disadvantages) of using one or the other? Thanks.

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://discourse.julialang.org/u/jules)\
**Post date:** [April 10, 2024, 10:27am UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/13 "2024-04-10T10:27:01Z")

</div>

Quarto is not an IDE, you write a plain text notebook format with code fences like

````julia
```{julia}
1 + 1
```

````

and then you render the full notebook through an intermediate markdown representation into tons of formats supported via pandoc. Pluto does not have so many output options because it’s not focused so much on static outputs. For Pluto, I would say the interactive experience is the defining factor.

---

<div class="post-metadata">

**Author:** ![liuyxpp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/liuyxpp/32/9870_2.png) [@liuyxpp](https://discourse.julialang.org/u/liuyxpp)\
**Post date:** [April 10, 2024, 12:05pm UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/14 "2024-04-10T12:05:58Z")

</div>

It is super cool! I will use it to write docs and research notes once it is available.

---

<div class="post-metadata">

**Author:** ![kellertuer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kellertuer/32/220707_2.png) [@kellertuer](https://discourse.julialang.org/u/kellertuer)\
**Post date:** [April 10, 2024, 12:42pm UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/15 "2024-04-10T12:42:56Z")

</div>

I would say a large advantage is, that the Quarto notebooks are Markdown with code cells – and that quarto interoperates with pandoc, so you can get the result in your favourite format. For example in markdown to use it in documenter (my use case). If you need an environment, probably the one of the folder is the one to go for

Pluto is the other way around: Code cells where some of them might be markdown. An advantage might be that each Pluto notebook automatically keeps its own environment, automatically, which I love when exchanging code with students for example. A disadvantage is that rendering Pluto to something is not so easy (but that is on het other hand a main feature of Quarto).

---

<div class="post-metadata">

**Author:** ![kellertuer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kellertuer/32/220707_2.png) [@kellertuer](https://discourse.julialang.org/u/kellertuer)\
**Post date:** [April 10, 2024, 1:52pm UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/16 "2024-04-10T13:52:24Z")

</div>

To extend on this, what I would love to have is a Pluto ↔ Quarto “translator”, that is probably a pandoc receipt.  
I love to sketch and develop something in Pluto. But for longtime or tutorial work I prefer Quarto – so somewhere in between I have to “switch”.

---

<div class="post-metadata">

**Author:** ![edavidaja](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/edavidaja/32/208401_2.png) [@edavidaja](https://discourse.julialang.org/u/edavidaja)\
**Post date:** [April 10, 2024, 2:07pm UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/17 "2024-04-10T14:07:46Z")

</div>

[qvm](https://github.com/dpastoor/qvm) can help with running multiple versions of quarto.

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [April 10, 2024, 2:09pm UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/18 "2024-04-10T14:09:13Z")

</div>

If anyone is interested in a working example with Quarto and IJulia, including appropriate configuration of GitHub CI tools, take a look here: [Geospatial Data Science with Julia](https://juliaearth.github.io/geospatial-data-science-with-julia)

We have many issues with Makie.jl integration. Hopefully the new QuartoNotebookRunner.jl will improve the situation.

---

<div class="post-metadata">

**Author:** ![randyzwitch](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/randyzwitch/32/15955_2.png) [@randyzwitch](https://discourse.julialang.org/u/randyzwitch)\
**Post date:** [April 10, 2024, 2:10pm UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/19 "2024-04-10T14:10:26Z")

</div>

Worlds are colliding! Will this be the contribution that gets this manager back to programming?

(Not around much any more in the Julia world, but now Head of Developer Relations at Posit)

---

<div class="post-metadata">

**Author:** ![kellertuer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kellertuer/32/220707_2.png) [@kellertuer](https://discourse.julialang.org/u/kellertuer)\
**Post date:** [April 10, 2024, 2:14pm UTC](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753/20 "2024-04-10T14:14:53Z")

</div>

Sounds nice, though I have not yet understood how to install qvm itself (I am just a poor Mac user with only some terminal knowledge and usually struggle a bit with anything beyond brew)

[Next page](https://discourse.julialang.org/t/ann-native-julia-engine-for-quarto-using-quartonotebookrunner-jl/112753.md?page=2)
