[Python] How to stop jupyter-book build from examining files in .venv directory

Discussão em 'Python' iniciado por Stack, Dezembro 21, 2024.

  1. Stack

    Stack Membro Participativo

    I'm using jupyter-book. I recently switched from using a conda based environment to uv. uv creates a .venv directory at the top level. Now when I issue the command

    jupyter-book build .


    I can see that jupyter-book is traversing the .venv directory as well and trying to build any markdown files, rst files, jupyter notebooks, etc. that are part of any of the Python packages in the .venv directory. This is not ideal, so I'd like to exclude the .venv directory. I updated my _copnfig.yml file to attempt to do so:

    execute:
    execute_notebooks: auto
    exclude_patterns:
    - '.venv'


    But it appears to have no effect. I tried other pattern variants such as '.venv/', '.venv/*', '.venv/**', with no luck.

    Any suggestions would be appreciated.

    Continue reading...

Compartilhe esta Página