Importing Nornir in a Python 3.12 virtual environment fails because setuptools is not installed:
from nornir import InitNornir
.venv/lib/python3.12/site-packages/nornir/__init__.py:1: in <module>
import pkg_resources
E ModuleNotFoundError: No module named 'pkg_resources'
gh-95299: Do not pre-install setuptools in virtual environments created with venv. This means that distutils, setuptools, pkg_resources, and easy_install will no longer available by default; to access these run pip install setuptools in the activated virtual environment.
Manually installing setuptools works, but it should be listed as an explicit dependency of Nornir.
I'd make a PR, but I'm not sure what version constraint to use.
Importing Nornir in a Python 3.12 virtual environment fails because
setuptools
is not installed:In Python 3.12,
setuptools
is no longer installed in virtual environments (https://docs.python.org/3/whatsnew/3.12.html):Manually installing
setuptools
works, but it should be listed as an explicit dependency of Nornir.I'd make a PR, but I'm not sure what version constraint to use.