Module with __init__.pyx is not recognized by setuptools.find_packages()
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 2.9k
- Forks
- 1.4k
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 1
Description
A module with a Cythonized init.pyx (but other files being a *.py file) is not recognized by setuptools.find_packages():
$ mkdir mymodule
$ touch mymodule/__init__.pyx mymodule/__init__.cpython-36m-x86_64-linux-gnu.so mymodule/__init__.c
$ python3 -c "import setuptools; print(setuptools.find_packages('.'))"
[]
$ touch mymodule/__init__.py
$ python3 -c "import setuptools; print(setuptools.find_packages('.'))"
['mymodule']
However, if I put an __init__.py in there as well, I don't think I can properly import the Cython .so module anymore. Is this a bug of sorts? I don't know what to do about this...
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue with the shown mymodule layout and inspect setuptools.find_packages() and its package-discovery entry point. Determine how a directory with only a Cythonized init.pyx should be recognized, then add coverage showing the package is found without requiring an init.py file.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100