Skip to content

[BUG] ModuleNotFoundError: No module named 'setuptools' #589

@timhoffm

Description

@timhoffm

Describe the bug
grayskull creates by-default non-working recipe for packages that still use setuptools.

For python 3.13 setuptools is no longer a dependency of pip https://conda-forge.org/news/2024/08/21/sunsetting-pip-deps/ and needs explicit installation.

To Reproduce
Noted when trying to create a conda package for types-pika-ts (grayskull pypi types-pika-ts) . The created meta.yaml contains

requirements:
  host:
    - python >=3.8
    - pip

conda build then creates a host envionment with python 3.13 and pip but without setuptools.

Expected behavior
The recipe work without additional modification. I haven't looked into the internals of grayskull and therefore don't know whether it can detect if setuptools is required. If so, it should put it into the host requirements explicitly. That is necessary for python 3.13 and doesn't hurt for python versions < 3.13.

Workaround
In case somebody stumbles across this as well, you can manually add setuptools to your host dependencies.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions