Skip to content

"Jupyter is not available in this Python installation" when using pipx #11804

Open
@venpopov

Description

@venpopov

Bug description

I use pipx to install python stuff (https://github.com/pypa/pipx). Jupyterlab works just fine, and in VScode I am able to select kernels installed this way no problem. However, when I run quarto render on a jupyter notebook, I get the following error:

quarto render r-notebook.ipynb --execute

Starting ir kernel...Traceback (most recent call last):
  File "/Applications/quarto/share/jupyter/jupyter.py", line 21, in <module>
    from notebook import notebook_execute, RestartKernel
  File "/Applications/quarto/share/jupyter/notebook.py", line 15, in <module>
    from yaml import safe_load as parse_string
ModuleNotFoundError: No module named 'yaml'
Python 3 installation:
  Version: 3.13.1
  Path: /opt/homebrew/opt/[email protected]/bin/python3.13
  Jupyter: (None)

Jupyter is not available in this Python installation.
Install with python3 -m pip install jupyter

Jupyter is globally accessible to all environments:

> pipx list
venvs are in /Users/venpopov/.local/pipx/venvs
apps are exposed on your $PATH at /Users/venpopov/.local/bin
manual pages are exposed at /Users/venpopov/.local/share/man
   package jupyterlab 4.3.4, installed using Python 3.13.1
    - debugpy
    - httpx
    - ipython
    - ipython3
    - jlpm
    - jsonpointer
    - jsonschema
    - jupyter
    - jupyter-dejavu
    - jupyter-events
    - jupyter-execute
    - jupyter-kernel
    - jupyter-kernelspec
    - jupyter-lab
    - jupyter-labextension
    - jupyter-labhub
    - jupyter-migrate
    - jupyter-nbconvert
    - jupyter-run
    - jupyter-server
    - jupyter-troubleshoot
    - jupyter-trust
    - normalizer
    - pybabel
    - pygmentize
    - pyjson5
    - send2trash
    - wsdump
    - man1/ipython.1
   package notebook 7.3.2, installed using Python 3.13.1
    - jupyter-notebook
   package radian 0.6.13, installed using Python 3.13.1
    - radian

commands like jupyter work just fine in any terminal and VScode. It seems that quarto CLI tool is making erroneous assumptions about how to check for the presence of jupyter.

Steps to reproduce

the following installs jupyterlab via pipx

pipx install jupyterlab --include-deps

Expected behavior

quarto CLI should recognize the globally accessible jupyter installation

Actual behavior

No response

Your environment

  • zsh terminal
  • MacOS Sonoma

Quarto check output

Quarto 1.6.39
[✓] Checking environment information...
Quarto cache location: /Users/venpopov/Library/Caches/quarto
[✓] Checking versions of quarto binary dependencies...
Pandoc version 3.4.0: OK
Dart Sass version 1.70.0: OK
Deno version 1.46.3: OK
Typst version 0.11.0: OK
[✓] Checking versions of quarto dependencies......OK
[✓] Checking Quarto installation......OK
Version: 1.6.39
Path: /Applications/quarto/bin

[✓] Checking tools....................OK
TinyTeX: (not installed)
Chromium: (not installed)

[✓] Checking LaTeX....................OK
Tex: (not detected)

[✓] Checking basic markdown render....OK

[✓] Checking Python 3 installation....OK
Version: 3.13.1
Path: /opt/homebrew/opt/[email protected]/bin/python3.13
Jupyter: (None)

  Jupyter is not available in this Python installation.
  Install with python3 -m pip install jupyter

[✓] Checking R installation...........OK
Version: 4.4.2
Path: /Library/Frameworks/R.framework/Versions/4.4-arm64/Resources
LibPaths:
- /Users/venpopov/Library/R/arm64/4.4/library
- /Library/Frameworks/R.framework/Versions/4.4-arm64/Resources/library
knitr: 1.49
rmarkdown: 2.29

[✓] Checking Knitr engine render......OK

Metadata

Metadata

Assignees

No one assigned

    Labels

    jupyterthird-partyIssues involving interaction with a third-party library

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions