Repository navigation
Conversation
MANIFEST.in includes cpp/, CMakeLists.txt, setup.py, etc. so that the sdist can be built. Because pyproject.toml has a [project] table, include_package_data defaults to True, and scikit-build then installs every MANIFEST.in entry that is outside a Python package as a data file, which pip puts at the root of the environment. Turn include_package_data off and list the package's only non-Python files (the adapter test data) in package_data. Discover packages with find_namespace_packages so that csp.build and csp.tests.build, which have no __init__.py, are still included. The files under csp/ in the wheel are unchanged; the sdist is unchanged. Fixes Point72#526 Signed-off-by: Laksh Agarwal <lakshagarwal65@gmail.com>
Lotion-3
requested review from
AdamGlustein,
alexddobkin,
arhamchopra,
ptomecek,
robambalu,
svatasoiu and
timkpaine
as code owners
November 14, 2026 02:27
Member
|
Thanks for the PR! I've trimmed the comments and reformatted in #796 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Fixes #526.
pip install cspputsCMakeLists.txt,cpp/,setup.py,pyproject.toml,vcpkg.json,README.md,LICENSEandNOTICEat the root of the environment (about 290 files).Cause. MANIFEST.in includes these files for the sdist. Since
pyproject.tomlhas a[project]table,include_package_datadefaults toTrue, and scikit-build then treats every MANIFEST.in entry outside a Python package as a data file. pip installs data files at the environment root.Change. In
setup.py:include_package_data=False, so MANIFEST.in only affects the sdist;package_datalists the package's only non-Python files, the adapter test data incsp/tests/adapters/;packages=find_namespace_packages(include=["csp", "csp.*"]), becausecsp/buildandcsp/tests/buildhave no__init__.pyand would be missed bypackages=["csp"]orfind_packages().This is the same idea as #647, which failed CI because it dropped
csp.build,csp.tests.buildand the test data from the wheel. Here the wheel'scsp/contents are unchanged.Testing. I built wheels from
mainand from this branch with the same compiled artifacts and compared them:csp/are identical, byte for byte;csp/lib,csp/include);pip install, the environment root contains only the usual venv files;make lintpasses, and the Python test suite run against the wheel, as CI does (pip install --target .thenpytest csp/tests), gives the same results as the released 0.19.1 wheel.CI. I ran the full CI matrix (
ci-full) on my fork. All 15 wheel builds (Linux, Windows and macOS, cp310–cp314), all 15testjobs, the 3test_dependenciesjobs andtest_sdistpassed: https://github.com/Lotion-3/csp/actions/runs/43494223844. To get the run through, that branch also had three CI-only changes that aren't part of this PR:macos-14runners are no longer supported, so I usedmacos-15withbrew tap homebrew/core --forcebeforebrew extract;lmdbsource, so I used an overlay port fetching the sameLMDB_0.9.33source from the GitHub mirror;pandas<3.1, since fixed on main by Fix pandas 3.1 compatibility #782.This branch is rebased on that fix.
I'm happy to send the macOS change as a separate PR if that's useful.