-
-
Notifications
You must be signed in to change notification settings - Fork 21
Rework support for --allow-hosts
/ --index-url
#30
Rework support for --allow-hosts
/ --index-url
#30
Conversation
Correctly install extras with no markers.
Don't rely on patching `setuptools.Distribution`'s private member: `_egg_fetcher`.
ptr.py
Outdated
and (not name or self.extras) | ||
if (not name or self.extras) | ||
# never include extras that fail to pass marker eval | ||
and (not marker or self.marker_passes(marker)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I meant for self.marker_passes
to encapsulate the full check. I think I want to fix the bug there. Was there a reason you switched the order of these tests?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It just seemed more natural to me when I looked at fixing the conditions: first filter on the name, then check the condition.
I like this approach. The factoring out of the CustomDistribution was precisely the right thing to do. The py26 support is annoying, I know. I think I'll drop support for Python 2.6 after getting this fix out. And thanks for adding tests. I'd always felt like it would be too difficult to write tests for this library because of the complications with test runners, etc, but you've done it. Kudos! I've repeatedly run into issues with my boolean logic in the markers handling stuff. I'm surprised it's worked well enough for all this time without complaints. Glad to have tests to verify the behavior now. |
* Replace pep517.build with build Resolves #30 * Prefer simple usage Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
* Use `extend-ignore` in flake8 config This option allows to add extra ignored rules to the default list instead of replacing it. The default exclusions are: E121, E123, E126, E226, E24, E704, W503 and W504. Fixes #28. Refs: * https://github.com/pypa/setuptools/pull/2486/files#r541943356 * https://flake8.pycqa.org/en/latest/user/options.html#cmdoption-flake8-extend-ignore * https://flake8.pycqa.org/en/latest/user/options.html#cmdoption-flake8-ignore * Enable complexity limit. Fixes jaraco/skeleton#34. * Replace pep517.build with build (#37) * Replace pep517.build with build Resolves #30 * Prefer simple usage Co-authored-by: Jason R. Coombs <jaraco@jaraco.com> * Use license_files instead of license_file in meta (#35) Singular `license_file` is deprecated since wheel v0.32.0. Refs: * https://wheel.readthedocs.io/en/stable/news.html * https://wheel.readthedocs.io/en/stable/user_guide.html#including-license-files-in-the-generated-wheel-file Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
As a prerequisite for pypa/setuptools#1127, don't rely on patching
setuptools.Distribution
's private member:_egg_fetcher
.Note: this PR also include a fix for a bug I found while adding some tests to prevent regressions: extras with no environment marker are not installed when using
--extras
.