From 2d4146fb2bd7ec972832710ba09fa8a30afab0a8 Mon Sep 17 00:00:00 2001 From: Tim Paine <3105306+timkpaine@users.noreply.github.com> Date: Sat, 18 Jul 2026 15:48:22 -0400 Subject: [PATCH] Exclude jupyter_execute output from documentation build myst-nb writes executed notebooks into a jupyter_execute directory inside the source tree. With the source root at the project root, each rebuild re-read that output as source and nested it deeper (jupyter_execute/.../jupyter_execute/...), eventually failing with a missing .doctree path. Exclude jupyter_execute at any depth so it is never picked up as source. Signed-off-by: Tim Paine <3105306+timkpaine@users.noreply.github.com> --- yardang/conf.py.j2 | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/yardang/conf.py.j2 b/yardang/conf.py.j2 index 159cabc..d7b5848 100644 --- a/yardang/conf.py.j2 +++ b/yardang/conf.py.j2 @@ -155,6 +155,15 @@ exclude_patterns = [ "*.wiki/*", "docs/.jupyter_cache", "docs/.jupyter_cache/*", + # myst-nb writes executed notebooks into a ``jupyter_execute`` directory + # inside the source tree. With the source root at the project root, a + # rebuild would otherwise re-read that output as source and nest it deeper + # on every run (``jupyter_execute/.../jupyter_execute/...``). Exclude it at + # any depth. + "jupyter_execute", + "jupyter_execute/*", + "**/jupyter_execute", + "**/jupyter_execute/**", "docs/wiki", "docs/wiki/*", "docs/html",