-
Notifications
You must be signed in to change notification settings - Fork 69
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
mark the scandir extension as optional #106
Conversation
build errors no longer stop the build this may hide errors but ensures installing on jython or linux without gcc works fine
This fixes pytest-dev/pytest#3750 and alleviates #105 if I'm following the discussion correctly. |
setup.py
Outdated
@@ -32,7 +34,7 @@ | |||
description='scandir, a better directory iterator and faster os.walk()', | |||
long_description=long_description, | |||
py_modules=['scandir'], | |||
ext_modules=[Extension('_scandir', ['_scandir.c'])], | |||
ext_modules=[Extension('_scandir', ['_scandir.c'], optional=True)], |
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.
Perhaps add a comment to say why it's being marked optional?
Also related to #73 |
@benhoyt thanks for merging! Could you please ping this thread once this change is released, so we can verify/close the related issues? Thanks! |
Will do. |
Done and on PyPI |
@benhoyt thanks for the support and the swift release 👍 |
Cross-posting here for visibility: we're seeing the following warning on both 2.7.12 and 2.7.15 and pip fails the build (tested with setuptools: 20.1.1, 40.0.0):
Looks like the optional kwarg for Extension is only supported in python 3 |
indeed, and i missed the issue because i accidentally got myself gcc installed back between python version testing |
im working on a backport of optional=True |
build errors no longer stop the build
this may hide errors but ensures installing on jython or linux without gcc works fine
this can be refined to be conditional on jython/pypy and/or gcc missing