Skip to content

[Bug]: Editable install seems broken #27005

Closed as not planned
Closed as not planned
@timhoffm

Description

@timhoffm

Bug summary

Possibly realted to the Port of the build system to Meson #26621. Ping @QuLogic

Code for reproduction

# standard installation procedure according to:
# https://matplotlib.org/stable/devel/development_setup.html#create-a-dedicated-environment
conda env create -f environment.yml
conda activate mpl-dev
python -m pip install -e .
python -c "import matplotlib; print(matplotlib.__file__)"

Note: A non-editable install python -m pip install . works.

Actual outcome

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1138, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 1078, in _find_spec
  File "/home/tim/anaconda3/envs/mpl-dev/lib/python3.11/site-packages/_matplotlib_editable_loader.py", line 271, in find_spec
    tree = self.rebuild()
           ^^^^^^^^^^^^^^
  File "/home/tim/anaconda3/envs/mpl-dev/lib/python3.11/site-packages/_matplotlib_editable_loader.py", line 312, in rebuild
    subprocess.run(self._build_cmd, cwd=self._build_path, env=env, stdout=stdout, check=True)
  File "/home/tim/anaconda3/envs/mpl-dev/lib/python3.11/subprocess.py", line 571, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['/home/tim/anaconda3/envs/mpl-dev/bin/ninja']' returned non-zero exit status 1.```

Matplotlib Version

main branch

Python version

3.11.6

Installation

git checkout

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions