`spacy` fails to specify `click` as a dependency even though it is being used and thus fresh install + import fails
How to reproduce the behaviour
python -m pip install spacy
python -c "import spacy" # results in failure
Your Environment
- Operating System: MacOS / Ubuntu (CI)
- Python Version Used: 3.11
- spaCy Version Used: 3.8.14
- Environment Information: Brand new
venvbased environment
The output in fresh install of env
((.venv) ) martratas@Marts-MacBook-Pro 2026_05_27_spacy_click % pip freeze
((.venv) ) martratas@Marts-MacBook-Pro 2026_05_27_spacy_click % pip --version
pip 26.1.1 from /Users/martratas/Documents/CogStack/.MedCAT.nosync/monorepo-nlp/medcat-v2/.temp/2026_05_27_spacy_click/.venv/lib/python3.12/site-packages/pip (python 3.12)
((.venv) ) martratas@Marts-MacBook-Pro 2026_05_27_spacy_click % python -m pip install spacy
Collecting spacy
Using cached spacy-3.8.14-cp312-cp312-macosx_11_0_arm64.whl.metadata (28 kB)
Collecting spacy-legacy<3.1.0,>=3.0.11 (from spacy)
Using cached spacy_legacy-3.0.12-py2.py3-none-any.whl.metadata (2.8 kB)
Collecting spacy-loggers<2.0.0,>=1.0.0 (from spacy)
Using cached spacy_loggers-1.0.5-py3-none-any.whl.metadata (23 kB)
Collecting murmurhash<1.1.0,>=0.28.0 (from spacy)
Using cached murmurhash-1.0.15-cp312-cp312-macosx_11_0_arm64.whl.metadata (2.3 kB)
Collecting cymem<2.1.0,>=2.0.2 (from spacy)
Using cached cymem-2.0.13-cp312-cp312-macosx_11_0_arm64.whl.metadata (9.7 kB)
Collecting preshed<3.1.0,>=3.0.2 (from spacy)
Using cached preshed-3.0.13-cp312-cp312-macosx_11_0_arm64.whl.metadata (5.2 kB)
Collecting thinc<8.4.0,>=8.3.12 (from spacy)
Using cached thinc-8.3.13-cp312-cp312-macosx_11_0_arm64.whl.metadata (14 kB)
Collecting wasabi<1.2.0,>=0.9.1 (from spacy)
Using cached wasabi-1.1.3-py3-none-any.whl.metadata (28 kB)
Collecting srsly<3.0.0,>=2.5.3 (from spacy)
Using cached srsly-2.5.3-cp312-cp312-macosx_11_0_arm64.whl.metadata (19 kB)
Collecting catalogue<2.1.0,>=2.0.6 (from spacy)
Using cached catalogue-2.0.10-py3-none-any.whl.metadata (14 kB)
Collecting weasel<2.0.0,>=1.0.0 (from spacy)
Using cached weasel-1.0.0-py3-none-any.whl.metadata (4.6 kB)
Collecting confection<2.0.0,>=1.3.2 (from spacy)
Using cached confection-1.3.3-py3-none-any.whl.metadata (19 kB)
Collecting typer<1.0.0,>=0.3.0 (from spacy)
Using cached typer-0.26.2-py3-none-any.whl.metadata (16 kB)
Collecting tqdm<5.0.0,>=4.38.0 (from spacy)
Using cached tqdm-4.67.3-py3-none-any.whl.metadata (57 kB)
Collecting numpy>=1.19.0 (from spacy)
Downloading numpy-2.4.6-cp312-cp312-macosx_14_0_arm64.whl.metadata (6.6 kB)
Collecting requests<3.0.0,>=2.13.0 (from spacy)
Downloading requests-2.34.2-py3-none-any.whl.metadata (4.8 kB)
Collecting pydantic<3.0.0,>=2.0.0 (from spacy)
Using cached pydantic-2.13.4-py3-none-any.whl.metadata (109 kB)
Collecting jinja2 (from spacy)
Using cached jinja2-3.1.6-py3-none-any.whl.metadata (2.9 kB)
Collecting setuptools (from spacy)
Using cached setuptools-82.0.1-py3-none-any.whl.metadata (6.5 kB)
Collecting packaging>=20.0 (from spacy)
Using cached packaging-26.2-py3-none-any.whl.metadata (3.5 kB)
Collecting annotated-types>=0.6.0 (from pydantic<3.0.0,>=2.0.0->spacy)
Using cached annotated_types-0.7.0-py3-none-any.whl.metadata (15 kB)
Collecting pydantic-core==2.46.4 (from pydantic<3.0.0,>=2.0.0->spacy)
Using cached pydantic_core-2.46.4-cp312-cp312-macosx_11_0_arm64.whl.metadata (6.6 kB)
Collecting typing-extensions>=4.14.1 (from pydantic<3.0.0,>=2.0.0->spacy)
Using cached typing_extensions-4.15.0-py3-none-any.whl.metadata (3.3 kB)
Collecting typing-inspection>=0.4.2 (from pydantic<3.0.0,>=2.0.0->spacy)
Using cached typing_inspection-0.4.2-py3-none-any.whl.metadata (2.6 kB)
Collecting charset_normalizer<4,>=2 (from requests<3.0.0,>=2.13.0->spacy)
Using cached charset_normalizer-3.4.7-cp312-cp312-macosx_10_13_universal2.whl.metadata (40 kB)
Collecting idna<4,>=2.5 (from requests<3.0.0,>=2.13.0->spacy)
Downloading idna-3.16-py3-none-any.whl.metadata (6.4 kB)
Collecting urllib3<3,>=1.26 (from requests<3.0.0,>=2.13.0->spacy)
Using cached urllib3-2.7.0-py3-none-any.whl.metadata (6.9 kB)
Collecting certifi>=2023.5.7 (from requests<3.0.0,>=2.13.0->spacy)
Downloading certifi-2026.5.20-py3-none-any.whl.metadata (2.5 kB)
Collecting blis<1.4.0,>=1.3.0 (from thinc<8.4.0,>=8.3.12->spacy)
Using cached blis-1.3.3-cp312-cp312-macosx_11_0_arm64.whl.metadata (7.5 kB)
Collecting shellingham>=1.3.0 (from typer<1.0.0,>=0.3.0->spacy)
Using cached shellingham-1.5.4-py2.py3-none-any.whl.metadata (3.5 kB)
Collecting rich>=13.8.0 (from typer<1.0.0,>=0.3.0->spacy)
Using cached rich-15.0.0-py3-none-any.whl.metadata (18 kB)
Collecting annotated-doc>=0.0.2 (from typer<1.0.0,>=0.3.0->spacy)
Using cached annotated_doc-0.0.4-py3-none-any.whl.metadata (6.6 kB)
Collecting cloudpathlib>=0.7.0 (from weasel<2.0.0,>=1.0.0->spacy)
Using cached cloudpathlib-0.24.0-py3-none-any.whl.metadata (16 kB)
Collecting smart-open>=5.2.1 (from weasel<2.0.0,>=1.0.0->spacy)
Downloading smart_open-7.6.1-py3-none-any.whl.metadata (25 kB)
Collecting httpx>=0.24.0 (from weasel<2.0.0,>=1.0.0->spacy)
Using cached httpx-0.28.1-py3-none-any.whl.metadata (7.1 kB)
Collecting anyio (from httpx>=0.24.0->weasel<2.0.0,>=1.0.0->spacy)
Using cached anyio-4.13.0-py3-none-any.whl.metadata (4.5 kB)
Collecting httpcore==1.* (from httpx>=0.24.0->weasel<2.0.0,>=1.0.0->spacy)
Using cached httpcore-1.0.9-py3-none-any.whl.metadata (21 kB)
Collecting h11>=0.16 (from httpcore==1.*->httpx>=0.24.0->weasel<2.0.0,>=1.0.0->spacy)
Using cached h11-0.16.0-py3-none-any.whl.metadata (8.3 kB)
Collecting markdown-it-py>=2.2.0 (from rich>=13.8.0->typer<1.0.0,>=0.3.0->spacy)
Using cached markdown_it_py-4.2.0-py3-none-any.whl.metadata (7.4 kB)
Collecting pygments<3.0.0,>=2.13.0 (from rich>=13.8.0->typer<1.0.0,>=0.3.0->spacy)
Using cached pygments-2.20.0-py3-none-any.whl.metadata (2.5 kB)
Collecting mdurl~=0.1 (from markdown-it-py>=2.2.0->rich>=13.8.0->typer<1.0.0,>=0.3.0->spacy)
Using cached mdurl-0.1.2-py3-none-any.whl.metadata (1.6 kB)
Collecting wrapt (from smart-open>=5.2.1->weasel<2.0.0,>=1.0.0->spacy)
Downloading wrapt-2.2.1-cp312-cp312-macosx_11_0_arm64.whl.metadata (7.4 kB)
Collecting MarkupSafe>=2.0 (from jinja2->spacy)
Using cached markupsafe-3.0.3-cp312-cp312-macosx_11_0_arm64.whl.metadata (2.7 kB)
Using cached spacy-3.8.14-cp312-cp312-macosx_11_0_arm64.whl (6.0 MB)
Using cached catalogue-2.0.10-py3-none-any.whl (17 kB)
Using cached confection-1.3.3-py3-none-any.whl (35 kB)
Using cached cymem-2.0.13-cp312-cp312-macosx_11_0_arm64.whl (42 kB)
Using cached murmurhash-1.0.15-cp312-cp312-macosx_11_0_arm64.whl (27 kB)
Using cached preshed-3.0.13-cp312-cp312-macosx_11_0_arm64.whl (138 kB)
Using cached pydantic-2.13.4-py3-none-any.whl (472 kB)
Using cached pydantic_core-2.46.4-cp312-cp312-macosx_11_0_arm64.whl (2.0 MB)
Downloading requests-2.34.2-py3-none-any.whl (73 kB)
Using cached charset_normalizer-3.4.7-cp312-cp312-macosx_10_13_universal2.whl (311 kB)
Downloading idna-3.16-py3-none-any.whl (74 kB)
Using cached spacy_legacy-3.0.12-py2.py3-none-any.whl (29 kB)
Using cached spacy_loggers-1.0.5-py3-none-any.whl (22 kB)
Using cached srsly-2.5.3-cp312-cp312-macosx_11_0_arm64.whl (658 kB)
Using cached thinc-8.3.13-cp312-cp312-macosx_11_0_arm64.whl (791 kB)
Using cached blis-1.3.3-cp312-cp312-macosx_11_0_arm64.whl (1.2 MB)
Downloading numpy-2.4.6-cp312-cp312-macosx_14_0_arm64.whl (5.2 MB)
ββββββββββββββββββββββββββββββββββββββββ 5.2/5.2 MB 26.2 MB/s 0:00:00
Using cached tqdm-4.67.3-py3-none-any.whl (78 kB)
Using cached typer-0.26.2-py3-none-any.whl (123 kB)
Using cached urllib3-2.7.0-py3-none-any.whl (131 kB)
Using cached wasabi-1.1.3-py3-none-any.whl (27 kB)
Using cached weasel-1.0.0-py3-none-any.whl (50 kB)
Using cached annotated_doc-0.0.4-py3-none-any.whl (5.3 kB)
Using cached annotated_types-0.7.0-py3-none-any.whl (13 kB)
Downloading certifi-2026.5.20-py3-none-any.whl (134 kB)
Using cached cloudpathlib-0.24.0-py3-none-any.whl (63 kB)
Using cached httpx-0.28.1-py3-none-any.whl (73 kB)
Using cached httpcore-1.0.9-py3-none-any.whl (78 kB)
Using cached h11-0.16.0-py3-none-any.whl (37 kB)
Using cached packaging-26.2-py3-none-any.whl (100 kB)
Using cached rich-15.0.0-py3-none-any.whl (310 kB)
Using cached pygments-2.20.0-py3-none-any.whl (1.2 MB)
Using cached markdown_it_py-4.2.0-py3-none-any.whl (91 kB)
Using cached mdurl-0.1.2-py3-none-any.whl (10.0 kB)
Using cached shellingham-1.5.4-py2.py3-none-any.whl (9.8 kB)
Downloading smart_open-7.6.1-py3-none-any.whl (64 kB)
Using cached typing_extensions-4.15.0-py3-none-any.whl (44 kB)
Using cached typing_inspection-0.4.2-py3-none-any.whl (14 kB)
Using cached anyio-4.13.0-py3-none-any.whl (114 kB)
Using cached jinja2-3.1.6-py3-none-any.whl (134 kB)
Using cached markupsafe-3.0.3-cp312-cp312-macosx_11_0_arm64.whl (12 kB)
Using cached setuptools-82.0.1-py3-none-any.whl (1.0 MB)
Downloading wrapt-2.2.1-cp312-cp312-macosx_11_0_arm64.whl (81 kB)
Installing collected packages: wrapt, wasabi, urllib3, typing-extensions, tqdm, spacy-loggers, spacy-legacy, shellingham, setuptools, pygments, packaging, numpy, murmurhash, mdurl, MarkupSafe, idna, h11, cymem, confection, cloudpathlib, charset_normalizer, certifi, catalogue, annotated-types, annotated-doc, typing-inspection, srsly, smart-open, requests, pydantic-core, preshed, markdown-it-py, jinja2, httpcore, blis, anyio, rich, pydantic, httpx, typer, thinc, weasel, spacy
Successfully installed MarkupSafe-3.0.3 annotated-doc-0.0.4 annotated-types-0.7.0 anyio-4.13.0 blis-1.3.3 catalogue-2.0.10 certifi-2026.5.20 charset_normalizer-3.4.7 cloudpathlib-0.24.0 confection-1.3.3 cymem-2.0.13 h11-0.16.0 httpcore-1.0.9 httpx-0.28.1 idna-3.16 jinja2-3.1.6 markdown-it-py-4.2.0 mdurl-0.1.2 murmurhash-1.0.15 numpy-2.4.6 packaging-26.2 preshed-3.0.13 pydantic-2.13.4 pydantic-core-2.46.4 pygments-2.20.0 requests-2.34.2 rich-15.0.0 setuptools-82.0.1 shellingham-1.5.4 smart-open-7.6.1 spacy-3.8.14 spacy-legacy-3.0.12 spacy-loggers-1.0.5 srsly-2.5.3 thinc-8.3.13 tqdm-4.67.3 typer-0.26.2 typing-extensions-4.15.0 typing-inspection-0.4.2 urllib3-2.7.0 wasabi-1.1.3 weasel-1.0.0 wrapt-2.2.1
((.venv) ) martratas@Marts-MacBook-Pro 2026_05_27_spacy_click % python -c "import spacy"
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/Users/martratas/Documents/CogStack/.MedCAT.nosync/monorepo-nlp/medcat-v2/.temp/2026_05_27_spacy_click/.venv/lib/python3.12/site-packages/spacy/__init__.py", line 18, in <module>
from .cli.info import info # noqa: F401
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/martratas/Documents/CogStack/.MedCAT.nosync/monorepo-nlp/medcat-v2/.temp/2026_05_27_spacy_click/.venv/lib/python3.12/site-packages/spacy/cli/__init__.py", line 4, in <module>
from . import download as download_module # noqa: F401
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/martratas/Documents/CogStack/.MedCAT.nosync/monorepo-nlp/medcat-v2/.temp/2026_05_27_spacy_click/.venv/lib/python3.12/site-packages/spacy/cli/download.py", line 21, in <module>
from ._util import SDIST_SUFFIX, WHEEL_SUFFIX, Arg, Opt, app
File "/Users/martratas/Documents/CogStack/.MedCAT.nosync/monorepo-nlp/medcat-v2/.temp/2026_05_27_spacy_click/.venv/lib/python3.12/site-packages/spacy/cli/_util.py", line 18, in <module>
from click import NoSuchOption
ModuleNotFoundError: No module named 'click'
EDIT:
I think spacy has been relying on typer bringing in click. But as of typer==0.26.x, it looks like typer no longer depends on click. And as such it doesn't get installed anymore.
I can confirm this is a breaking regression on fresh installations/CI runners that triggered between May 20, 2026, and May 27, 2026.
Our CI builds using spacy~=3.8.11 (resolving to 3.8.14) were passing flawlessly up until May 20, but began failing completely today with the ModuleNotFoundError: No module named 'click' upon import spacy.
Root Cause / Log Analysis
Comparing our historical successful installation traces to today's failing traces reveals the exact downstream shift:
- Successful trace (May 20):
spacypulled downtyper-0.25.1, which explicitly mandatedclick>=8.2.1. - Failing trace (May 27):
spacypulled down the newly releasedtyper-0.26.2because spaCyβs internal constraint is wide (typer<1.0.0,>=0.3.0). In this newer version oftyper,clickwas decoupled and made an optional dependency.
Because import spacy eagerly calls from click import NoSuchOption on initialization inside spacy/cli/_util.py, the entire library crashes on import in a naked environment.
Workaround for other users hitting this today
Until a patch is released, you can fix your environment by explicitly forcing click back into your top-level project dependencies (requirements.txt or pyproject.toml):
click >= 8.2.1
- related fix we did https://github.com/canonical/chisel-releases/pull/1018
I encountered the issue with missing click module today (July 14, 2026) on a fresh installation of spaCy (Mac OS 26.5.2 on an Apple M4 Pro).
Encountered July 15, setting up an r docker container. after this container is up and running, doing 'R -e 'spacyr::install_spacey()' causes the error
Dockerfile
FROM <hidden>docker/r-lang/r-base:4.5
RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && apt-get install -y nodejs \
&& apt-get install -y --no-install-recommends \
git \
build-essential \
wget \
vim \
libxml2-dev \
libssl-dev \
libcurl4-openssl-dev \
libpython3-dev \
python3 \
python3-pip \
python3-venv \
python3-dev \
zlib1g-dev \
libbz2-dev \
libreadline-dev \
libsqlite3-dev \
git \
libncursesw5-dev \
xz-utils \
tk-dev \
libxmlsec1-dev \
libffi-dev \
liblzma-dev \
libzstd-dev \
python3-click \
&& curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" && \
unzip awscliv2.zip && \
./aws/install && \
rm -rf aws \
\
&& install2.r --error \
devtools \
stringr \
tidytext \
readxl \
dplyr \
tidyr \
purrr \
readr \
stringi \
R.utils \
jsonlite \
cli \
tidyselect \
lubridate \
tidyverse \
yaml \
scales \
leaflet \
rvest \
httr2 \
spacyr \
sf \
tidygeocoder \
tigris \
crosstalk \
htmlwidgets \
htmltools \
tibble \
testthat \
withr \
quarto \
reticulate
see docker container create log
Then after it is downloaded I enter the container and:
root@ebcb743ab092:/data# Rscript -e 'spacyr::spacy_install()'
Using Python: /usr/bin/python3.12
Creating virtual environment 'r-spacyr' ...
+ /usr/bin/python3.12 -m venv /root/.virtualenvs/r-spacyr
Done!
Installing packages: pip, wheel, setuptools
+ /root/.virtualenvs/r-spacyr/bin/python -m pip install --upgrade pip wheel setuptools
Requirement already satisfied: pip in /root/.virtualenvs/r-spacyr/lib/python3.12/site-packages (24.0)
Collecting pip
Downloading pip-26.1.2-py3-none-any.whl.metadata (4.6 kB)
Collecting wheel
Downloading wheel-0.47.0-py3-none-any.whl.metadata (2.3 kB)
Collecting setuptools
Downloading setuptools-83.0.0-py3-none-any.whl.metadata (6.6 kB)
Collecting packaging>=24.0 (from wheel)
Downloading packaging-26.2-py3-none-any.whl.metadata (3.5 kB)
Downloading pip-26.1.2-py3-none-any.whl (1.8 MB)
ββββββββββββββββββββββββββββββββββββββββ 1.8/1.8 MB 23.8 MB/s eta 0:00:00
Downloading wheel-0.47.0-py3-none-any.whl (32 kB)
Downloading setuptools-83.0.0-py3-none-any.whl (1.0 MB)
ββββββββββββββββββββββββββββββββββββββββ 1.0/1.0 MB 50.5 MB/s eta 0:00:00
Downloading packaging-26.2-py3-none-any.whl (100 kB)
ββββββββββββββββββββββββββββββββββββββββ 100.2/100.2 kB 11.4 MB/s eta 0:00:00
Installing collected packages: setuptools, pip, packaging, wheel
Attempting uninstall: pip
Found existing installation: pip 24.0
Uninstalling pip-24.0:
Successfully uninstalled pip-24.0
Successfully installed packaging-26.2 pip-26.1.2 setuptools-83.0.0 wheel-0.47.0
Installing packages: numpy
+ /root/.virtualenvs/r-spacyr/bin/python -m pip install --upgrade --no-user numpy
Collecting numpy
Downloading numpy-2.5.1-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.metadata (6.6 kB)
Downloading numpy-2.5.1-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (16.7 MB)
ββββββββββββββββββββββββββββββββββββββββ 16.7/16.7 MB 52.4 MB/s 0:00:00
Installing collected packages: numpy
Successfully installed numpy-2.5.1
Virtual environment 'r-spacyr' successfully created.
Using virtual environment 'r-spacyr' ...
+ /root/.virtualenvs/r-spacyr/bin/python -m pip install --upgrade --no-user spacy
Collecting spacy
Downloading spacy-3.8.14-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.metadata (28 kB)
Collecting spacy-legacy<3.1.0,>=3.0.11 (from spacy)
Downloading spacy_legacy-3.0.12-py2.py3-none-any.whl.metadata (2.8 kB)
Collecting spacy-loggers<2.0.0,>=1.0.0 (from spacy)
Downloading spacy_loggers-1.0.5-py3-none-any.whl.metadata (23 kB)
Collecting murmurhash<1.1.0,>=0.28.0 (from spacy)
Downloading murmurhash-1.0.15-cp312-cp312-manylinux1_x86_64.manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_5_x86_64.whl.metadata (2.3 kB)
Collecting cymem<2.1.0,>=2.0.2 (from spacy)
Downloading cymem-2.0.13-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.metadata (9.7 kB)
Collecting preshed<3.1.0,>=3.0.2 (from spacy)
Downloading preshed-3.0.13-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.metadata (5.2 kB)
Collecting thinc<8.4.0,>=8.3.12 (from spacy)
Downloading thinc-8.3.13-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.metadata (14 kB)
Collecting wasabi<1.2.0,>=0.9.1 (from spacy)
Downloading wasabi-1.1.3-py3-none-any.whl.metadata (28 kB)
Collecting srsly<3.0.0,>=2.5.3 (from spacy)
Downloading srsly-2.5.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.metadata (19 kB)
Collecting catalogue<2.1.0,>=2.0.6 (from spacy)
Downloading catalogue-2.0.10-py3-none-any.whl.metadata (14 kB)
Collecting weasel<2.0.0,>=1.0.0 (from spacy)
Downloading weasel-1.0.0-py3-none-any.whl.metadata (4.6 kB)
Collecting confection<2.0.0,>=1.3.2 (from spacy)
Downloading confection-1.3.3-py3-none-any.whl.metadata (19 kB)
Collecting typer<1.0.0,>=0.3.0 (from spacy)
Downloading typer-0.27.0-py3-none-any.whl.metadata (15 kB)
Collecting tqdm<5.0.0,>=4.38.0 (from spacy)
Downloading tqdm-4.68.4-py3-none-any.whl.metadata (57 kB)
Requirement already satisfied: numpy>=1.19.0 in /root/.virtualenvs/r-spacyr/lib/python3.12/site-packages (from spacy) (2.5.1)
Collecting requests<3.0.0,>=2.13.0 (from spacy)
Downloading requests-2.34.2-py3-none-any.whl.metadata (4.8 kB)
Collecting pydantic<3.0.0,>=2.0.0 (from spacy)
Downloading pydantic-2.13.4-py3-none-any.whl.metadata (109 kB)
Collecting jinja2 (from spacy)
Downloading jinja2-3.1.6-py3-none-any.whl.metadata (2.9 kB)
Requirement already satisfied: setuptools in /root/.virtualenvs/r-spacyr/lib/python3.12/site-packages (from spacy) (83.0.0)
Requirement already satisfied: packaging>=20.0 in /root/.virtualenvs/r-spacyr/lib/python3.12/site-packages (from spacy) (26.2)
Collecting annotated-types>=0.6.0 (from pydantic<3.0.0,>=2.0.0->spacy)
Downloading annotated_types-0.7.0-py3-none-any.whl.metadata (15 kB)
Collecting pydantic-core==2.46.4 (from pydantic<3.0.0,>=2.0.0->spacy)
Downloading pydantic_core-2.46.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (6.6 kB)
Collecting typing-extensions>=4.14.1 (from pydantic<3.0.0,>=2.0.0->spacy)
Downloading typing_extensions-4.16.0-py3-none-any.whl.metadata (3.3 kB)
Collecting typing-inspection>=0.4.2 (from pydantic<3.0.0,>=2.0.0->spacy)
Downloading typing_inspection-0.4.2-py3-none-any.whl.metadata (2.6 kB)
Collecting charset_normalizer<4,>=2 (from requests<3.0.0,>=2.13.0->spacy)
Downloading charset_normalizer-3.4.9-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.metadata (41 kB)
Collecting idna<4,>=2.5 (from requests<3.0.0,>=2.13.0->spacy)
Downloading idna-3.18-py3-none-any.whl.metadata (6.1 kB)
Collecting urllib3<3,>=1.26 (from requests<3.0.0,>=2.13.0->spacy)
Downloading urllib3-2.7.0-py3-none-any.whl.metadata (6.9 kB)
Collecting certifi>=2023.5.7 (from requests<3.0.0,>=2.13.0->spacy)
Downloading certifi-2026.6.17-py3-none-any.whl.metadata (2.5 kB)
Collecting blis<1.4.0,>=1.3.0 (from thinc<8.4.0,>=8.3.12->spacy)
Downloading blis-1.3.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.metadata (7.5 kB)
Collecting shellingham>=1.3.0 (from typer<1.0.0,>=0.3.0->spacy)
Downloading shellingham-1.5.4-py2.py3-none-any.whl.metadata (3.5 kB)
Collecting rich>=13.8.0 (from typer<1.0.0,>=0.3.0->spacy)
Downloading rich-15.0.0-py3-none-any.whl.metadata (18 kB)
Collecting annotated-doc>=0.0.2 (from typer<1.0.0,>=0.3.0->spacy)
Downloading annotated_doc-0.0.4-py3-none-any.whl.metadata (6.6 kB)
Collecting cloudpathlib>=0.7.0 (from weasel<2.0.0,>=1.0.0->spacy)
Downloading cloudpathlib-0.24.0-py3-none-any.whl.metadata (16 kB)
Collecting smart-open>=5.2.1 (from weasel<2.0.0,>=1.0.0->spacy)
Downloading smart_open-8.0.1-py3-none-any.whl.metadata (24 kB)
Collecting httpx>=0.24.0 (from weasel<2.0.0,>=1.0.0->spacy)
Downloading httpx-0.28.1-py3-none-any.whl.metadata (7.1 kB)
Collecting anyio (from httpx>=0.24.0->weasel<2.0.0,>=1.0.0->spacy)
Downloading anyio-4.14.2-py3-none-any.whl.metadata (4.6 kB)
Collecting httpcore==1.* (from httpx>=0.24.0->weasel<2.0.0,>=1.0.0->spacy)
Downloading httpcore-1.0.9-py3-none-any.whl.metadata (21 kB)
Collecting h11>=0.16 (from httpcore==1.*->httpx>=0.24.0->weasel<2.0.0,>=1.0.0->spacy)
Downloading h11-0.16.0-py3-none-any.whl.metadata (8.3 kB)
Collecting markdown-it-py>=2.2.0 (from rich>=13.8.0->typer<1.0.0,>=0.3.0->spacy)
Downloading markdown_it_py-4.2.0-py3-none-any.whl.metadata (7.4 kB)
Collecting pygments<3.0.0,>=2.13.0 (from rich>=13.8.0->typer<1.0.0,>=0.3.0->spacy)
Downloading pygments-2.20.0-py3-none-any.whl.metadata (2.5 kB)
Collecting mdurl~=0.1 (from markdown-it-py>=2.2.0->rich>=13.8.0->typer<1.0.0,>=0.3.0->spacy)
Downloading mdurl-0.1.2-py3-none-any.whl.metadata (1.6 kB)
Collecting wrapt (from smart-open>=5.2.1->weasel<2.0.0,>=1.0.0->spacy)
Downloading wrapt-2.2.2-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.metadata (7.4 kB)
Collecting MarkupSafe>=2.0 (from jinja2->spacy)
Downloading markupsafe-3.0.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.metadata (2.7 kB)
Downloading spacy-3.8.14-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (33.2 MB)
ββββββββββββββββββββββββββββββββββββββββ 33.2/33.2 MB 38.7 MB/s 0:00:00
Downloading catalogue-2.0.10-py3-none-any.whl (17 kB)
Downloading confection-1.3.3-py3-none-any.whl (35 kB)
Downloading cymem-2.0.13-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (260 kB)
Downloading murmurhash-1.0.15-cp312-cp312-manylinux1_x86_64.manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_5_x86_64.whl (134 kB)
Downloading preshed-3.0.13-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (868 kB)
ββββββββββββββββββββββββββββββββββββββββ 869.0/869.0 kB 27.2 MB/s 0:00:00
Downloading pydantic-2.13.4-py3-none-any.whl (472 kB)
Downloading pydantic_core-2.46.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.1 MB)
ββββββββββββββββββββββββββββββββββββββββ 2.1/2.1 MB 43.4 MB/s 0:00:00
Downloading requests-2.34.2-py3-none-any.whl (73 kB)
Downloading charset_normalizer-3.4.9-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (224 kB)
Downloading idna-3.18-py3-none-any.whl (65 kB)
Downloading spacy_legacy-3.0.12-py2.py3-none-any.whl (29 kB)
Downloading spacy_loggers-1.0.5-py3-none-any.whl (22 kB)
Downloading srsly-2.5.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (1.2 MB)
ββββββββββββββββββββββββββββββββββββββββ 1.2/1.2 MB 45.8 MB/s 0:00:00
Downloading thinc-8.3.13-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (3.9 MB)
ββββββββββββββββββββββββββββββββββββββββ 3.9/3.9 MB 45.1 MB/s 0:00:00
Downloading blis-1.3.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (11.4 MB)
ββββββββββββββββββββββββββββββββββββββββ 11.4/11.4 MB 56.6 MB/s 0:00:00
Downloading tqdm-4.68.4-py3-none-any.whl (676 kB)
ββββββββββββββββββββββββββββββββββββββββ 676.6/676.6 kB 50.8 MB/s 0:00:00
Downloading typer-0.27.0-py3-none-any.whl (122 kB)
Downloading urllib3-2.7.0-py3-none-any.whl (131 kB)
Downloading wasabi-1.1.3-py3-none-any.whl (27 kB)
Downloading weasel-1.0.0-py3-none-any.whl (50 kB)
Downloading annotated_doc-0.0.4-py3-none-any.whl (5.3 kB)
Downloading annotated_types-0.7.0-py3-none-any.whl (13 kB)
Downloading certifi-2026.6.17-py3-none-any.whl (133 kB)
Downloading cloudpathlib-0.24.0-py3-none-any.whl (63 kB)
Downloading httpx-0.28.1-py3-none-any.whl (73 kB)
Downloading httpcore-1.0.9-py3-none-any.whl (78 kB)
Downloading h11-0.16.0-py3-none-any.whl (37 kB)
Downloading rich-15.0.0-py3-none-any.whl (310 kB)
Downloading pygments-2.20.0-py3-none-any.whl (1.2 MB)
ββββββββββββββββββββββββββββββββββββββββ 1.2/1.2 MB 90.5 MB/s 0:00:00
Downloading markdown_it_py-4.2.0-py3-none-any.whl (91 kB)
Downloading mdurl-0.1.2-py3-none-any.whl (10.0 kB)
Downloading shellingham-1.5.4-py2.py3-none-any.whl (9.8 kB)
Downloading smart_open-8.0.1-py3-none-any.whl (73 kB)
Downloading typing_extensions-4.16.0-py3-none-any.whl (45 kB)
Downloading typing_inspection-0.4.2-py3-none-any.whl (14 kB)
Downloading anyio-4.14.2-py3-none-any.whl (125 kB)
Downloading jinja2-3.1.6-py3-none-any.whl (134 kB)
Downloading markupsafe-3.0.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (22 kB)
Downloading wrapt-2.2.2-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (169 kB)
Installing collected packages: wrapt, wasabi, urllib3, typing-extensions, tqdm, spacy-loggers, spacy-legacy, shellingham, pygments, murmurhash, mdurl, MarkupSafe, idna, h11, cymem, confection, cloudpathlib, charset_normalizer, certifi, catalogue, blis, annotated-types, annotated-doc, typing-inspection, srsly, smart-open, requests, pydantic-core, preshed, markdown-it-py, jinja2, httpcore, anyio, rich, pydantic, httpx, typer, thinc, weasel, spacy
Successfully installed MarkupSafe-3.0.3 annotated-doc-0.0.4 annotated-types-0.7.0 anyio-4.14.2 blis-1.3.3 catalogue-2.0.10 certifi-2026.6.17 charset_normalizer-3.4.9 cloudpathlib-0.24.0 confection-1.3.3 cymem-2.0.13 h11-0.16.0 httpcore-1.0.9 httpx-0.28.1 idna-3.18 jinja2-3.1.6 markdown-it-py-4.2.0 mdurl-0.1.2 murmurhash-1.0.15 preshed-3.0.13 pydantic-2.13.4 pydantic-core-2.46.4 pygments-2.20.0 requests-2.34.2 rich-15.0.0 shellingham-1.5.4 smart-open-8.0.1 spacy-3.8.14 spacy-legacy-3.0.12 spacy-loggers-1.0.5 srsly-2.5.3 thinc-8.3.13 tqdm-4.68.4 typer-0.27.0 typing-extensions-4.16.0 typing-inspection-0.4.2 urllib3-2.7.0 wasabi-1.1.3 weasel-1.0.0 wrapt-2.2.2
Executing command:
/root/.virtualenvs/r-spacyr/bin/python -m spacy download en_core_web_sm
Traceback (most recent call last):
File "<frozen runpy>", line 189, in _run_module_as_main
File "<frozen runpy>", line 148, in _get_module_details
File "<frozen runpy>", line 112, in _get_module_details
File "/root/.virtualenvs/r-spacyr/lib/python3.12/site-packages/spacy/__init__.py", line 18, in <module>
from .cli.info import info # noqa: F401
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/root/.virtualenvs/r-spacyr/lib/python3.12/site-packages/spacy/cli/__init__.py", line 4, in <module>
from . import download as download_module # noqa: F401
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/root/.virtualenvs/r-spacyr/lib/python3.12/site-packages/spacy/cli/download.py", line 21, in <module>
from ._util import SDIST_SUFFIX, WHEEL_SUFFIX, Arg, Opt, app
File "/root/.virtualenvs/r-spacyr/lib/python3.12/site-packages/spacy/cli/_util.py", line 18, in <module>
from click import NoSuchOption
ModuleNotFoundError: No module named 'click'
Installation of spaCy version 3.8.14 complete.
root@ebcb743ab092:/data#
Oh yeah, I've hit this exact issue before. The problem's that click isn't explicitly listed as a dependency in spacy's install_requires, but it's still a hard requirement for CLI stuff. So on a fresh virtualenv, if no other package pulls in click, the import just breaks.
Quick fix: manually install click alongside spacy. Something like:
pip install spacy click
Long term, though, this really needs to be fixed upstream by adding click to the setup.py or pyproject.toml for spacy. Honestly, I'm kinda surprised this hasn't been caught already, since click is used in their CLI. Maybe it gets pulled in transitively in most real-world setups, so it slipped through.
Btw, are you stuck on 3.8.14? If you can, maybe try the latest patch release too, sometimes stuff like this gets quietly patched but doesn't make it into the changelog.
I can reproduce this with uv on Python 3.12 as well:
uv add spacy
uv run python -m spacy download en_core_web_sm
The resolved set includes spacy==3.8.14 and typer==0.27.0, but no click. The command fails before the model download starts because importing spacy.cli._util raises:
ModuleNotFoundError: No module named 'click'
Adding click explicitly with uv add click fixes the import/download path, so this matches the missing direct runtime dependency described above.
The fact that @svlandeg is the one that implemented the change in Typer while this breaking bug with a one-line fix languishes here in spaCy unreviewed for months is... confusing. I can't imagine I'm alone in not understanding what the present and future status of Explosion and spaCy looks like.
Hi @cdjameson! I am not an active maintainer of spaCy anymore, and as such I do not merge any PRs here anymore.
I have added reviews to both relevant PRs though, and will ping Matt/Ines about this issue in case they haven't seen it here. Matt/Ines: let me know if I can help (more) with any of this.
The fact that @svlandeg is the one that implemented the change in Typer while this breaking bug with a one-line fix languishes here in spaCy unreviewed for months is... confusing. I can't imagine I'm alone in not understanding what the present and future status of Explosion and spaCy looks like.
I understand the frustration but unfortunately I simply missed this. I've merged the requirements change as Sofie recommended and am triggering a release.
Actions is down but will trigger a release when they're back up.
I understand the frustration but unfortunately I simply missed this. I've merged the requirements change as Sofie recommended and am triggering a release.
Thanks for the quick turnaround, everything works for our releases now! No frustration intended: Sofie addressed part of my confusion aboveβI had seen her commit to the repo as recently as March of this year and didn't understand that she was hands-off hereβand if it's just you or even just you and Ines of course things are going to slip through unnoticed!
If I weren't changing job roles myself I would offer to help out more directly instead of just opening issues and seeming frustrated. Thanks for everything you do for spaCy, it's the backbone of our production NLP services!
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.