-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix sdist make #10366
Fix sdist make #10366
Conversation
Include the `tools` directory in source distribution, as at least `tools/gen.py` and `tools/check_sum.py` are expected by the `Makefile` targets.
Modify `tools/gen.py` to determine the top project directory by the presence of `pyproject.toml` rather than `.git`, in order to make it work correctly outside a git checkout. This is needed to make the `Makefile` targets work.
Add a `cythonize-nodeps` target that can be used by downstreams who wish to re-Cythonize files and have provided the necessary dependencies externally. Calling `pip` is undesirable, as it causes sandbox violations.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #10366 +/- ##
==========================================
- Coverage 98.78% 98.77% -0.01%
==========================================
Files 122 122
Lines 37038 37038
Branches 2041 2041
==========================================
- Hits 36588 36585 -3
- Misses 311 314 +3
Partials 139 139
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
CodSpeed Performance ReportMerging #10366 will not alter performanceComparing Summary
|
be3dc2d
to
f1afe62
Compare
Backport to 3.11: 💚 backport PR created✅ Backport PR branch: Backported as #10367 🤖 @patchback |
(cherry picked from commit 3fb2c8d)
Backport to 3.12: 💚 backport PR created✅ Backport PR branch: Backported as #10368 🤖 @patchback |
(cherry picked from commit 3fb2c8d)
Thanks a lot! |
**This is a backport of PR #10366 as merged into master (3fb2c8d).** Co-authored-by: Michał Górny <[email protected]>
@mgorny thanks! Eventually we'll migrate to something similar to what yarl and others do. But for now, this is good to have. |
What do these changes do?
Three fixes related to use of source distribution to build
aiohttp
:tools
directory to sdist, as it is required by theMakefile
targets.tools/gen.py
to work outside a git checkout, by looking forpyproject.toml
rather than.git
.cythonize-nodeps
target that can be used by downstream packagers to perform cythonization without callingpip
.Are there changes in behavior for the user?
This fixes the ability to call
make
when working in an unpacked source distribution (currently it would fail due to missingtools/gen.py
).Is it a substantial burden for the maintainers to support this?
Don't think so. Worst case, the extra Makefile rule would go out of sync.
Related issue number
n/a
Checklist
CONTRIBUTORS.txt
CHANGES/
folder