Include Cython sources via package_data #6232
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
The point of this PR is to get the
.pyx
,.pxd
or.pxi
Cython files included in the wheels again while still avoiding inclusion of the large Cython-generated.c
or.cpp
files. It resolves the discussion in #6177It seems like we should just be able to set
include_package_data=True
and rely on theMANIFEST.in
, but whenever I tried this locally, the.c
and.cpp
files generated by Cython also end up getting included in the wheels (but not in the source distribution). I am not sure why that is.So, rather than set
include_package_data=True
, this PR leaves that variable False and just manually specifiespackage_data
insetup.py
. I had to add a few missing__init__.py
files for this to properly include all the tests.Checklist
./doc/examples
(new features only)./benchmarks
, if your changes aren't covered by anexisting benchmark
For reviewers
later.
__init__.py
.doc/release/release_dev.rst
.example, to backport to v0.19.x after merging, add the following in a PR
comment:
@meeseeksdev backport to v0.19.x
run-benchmark
label. To rerun, the labelcan be removed and then added again. The benchmark output can be checked in
the "Actions" tab.