rbanffy / pip-chill

A more relaxed `pip freeze`
Other
555 stars 25 forks source link

pkg_resources missing on fresh install #74

Closed MarcinKonowalczyk closed 2 weeks ago

MarcinKonowalczyk commented 8 months ago

Environment

Description

Installing pip-chill in a fresh venv companies about the lack of pkg_resources. Works after pip install setuptools. I believe that its because setuptools is no longer added to a virtual environment by default...?

Traceback (most recent call last):
  File "~/.pyenv/versions/my-venv/bin/pip-chill", line 5, in <module>
    from pip_chill.cli import main
  File "~/.pyenv/versions/3.12.0/envs/my-venv/lib/python3.12/site-packages/pip_chill/__init__.py", line 3, in <module>
    from .pip_chill import chill
  File "~/.pyenv/versions/3.12.0/envs/my-venv/lib/python3.12/site-packages/pip_chill/pip_chill.py", line 4, in <module>
    import pkg_resources
ModuleNotFoundError: No module named 'pkg_resources'

Short-term solution would be to add setuptools as a dependency(?), but longer-term maybe worth switching to importllib.resources (and importlib_resources backport) just like setuptools reccomends?

github-actions[bot] commented 6 months ago

Stale issue message

MarcinKonowalczyk commented 6 months ago

bump

Drblessing commented 5 months ago

bump

bcrotty commented 5 months ago

Same issue here except with a fresh system install of 3.12.2. As mentioned by OP, installing setuptools fixes this.

github-actions[bot] commented 3 months ago

Stale issue message

MarcinKonowalczyk commented 3 months ago

bump

MarcinKonowalczyk commented 2 months ago

ok, fine. as opposed to just bump'ing, see PR #75

github-actions[bot] commented 2 weeks ago

Stale issue message

MarcinKonowalczyk commented 2 weeks ago

bump (actually work-in-progress 👍)