Run nbdev_preview in a new repo got error


I’ve installed Quarto and successfully run nbdev_preview in a repo. However, I got errors when I used nbdev_preview in another repo. Then I ran nbdev_install in this repo to reinstall Quarto, the errors disappeared.

I was wondering if I need to install Quarto every time when I use nbdev_preview in a new repo? thank you.

This should not be happening are you installing Quarto system wide? How are you installing it?

Thank you, Hamel. I installed Nbdev v2 and Quarto in a same environment, but not the base environment. Is this the reason I got error? Thanks.

It’s hard for us to know without more information. Here’s some tips for getting help:

Thank you, Jeremy. Here is the error message when I built a new repo: nbdemo2. I tried nbdev_test, It showed success, but I got errors when I ran nbdev_preview.

I think this error is because your package isn’t installed. Try pip install -e '.[dev]'

EDIT: To clarify: nbdev_install does two things atm: installs Quarto and then installs your own package using pip install -e '.[dev]'. You don’t need to install Quarto everytime, but definitely do need to install each package :slight_smile:

Thank you very much. You solved my problem. Nbdev works great now.

1 Like