-
Notifications
You must be signed in to change notification settings - Fork 150
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
wheel 0.36.0 fails on macOS 11 (Big Sur) when MACOSX_DEPLOYMENT_TARGET=11 #385
Comments
What's happening? Even if we remove that assert, or the platform_tag were different: if If I simply remove the two asserts, then I can run
I am not sure whether the platform tag |
On further thought, I think since |
@Czaki comments? It's your code. |
Also, how come the existing tests don't fail when run on macOS 11? Does this only happen when the env variable is set? |
@agronholm I don't know how you run your tests. This happens when |
@fxcoudert could You check I also check pypi warehouse source code: https://github.com/pypa/warehouse/blob/0b6c95b1318a1572507d33f8abf220eef2984b19/warehouse/forklift/legacy.py#L127 and its requirements to have mayor and minor provided. So tag should be I do not upgrade to BigSur yet. When I working on this code there is no option to build a wheel for the system below 10.6. So I do not expect to provide only major version. |
@Czaki the numbering of macOS has changed from In any case, |
Ok. I understand. At this moment I do not have access to a machine with BigSur. I stuck on the 10.x series. I could create PR with a patch but I cannot test it locally. During writing this code it is impossible to predict that Apple will change the numbering scheme. But to solve this problem there should be a decision done in the warehouse. Currently, the warehouse will accept To prepare the patch I also need some .so or .dylib file to check the results of binary file inspection. @fxcoudert If I prepare a patch did you have time to test it? |
According to pypa/packaging#319 (comment):
It seems there is a need for a coordinated discussion about this. |
Ok. So I will prepare bugfix patch. But I still have a problem with testing it. |
Please pin the minor version to 0 and treat MACOSX_DEPLOYMENT_TARGET=N as MACOSX_DEPLOYMENT_TARGET=N.0. There are already wheels for |
@Czaki I can help test, for sure |
The fix in e6102e5 only works for Mac x86-64; it still fails on Apple Silicon. |
Would vendoring the latest |
@emeryberger, it actually works for Apple Silicon. Some packages will build their own separate dedicated environment with an old wheel version when installed (e.g. numpy). You need to write an issue for each package to make the wheel version >=0.36.1. |
I do wonder what reason they have for doing that. |
I am building numpy on M1. I succeeded by checking out the newest commit, instead of staying at 1.20.1 release. They seems to have done exactly the same thing: to upgrade wheel, in this commit: numpy/numpy@0a8dca0 |
The problem is not |
Yes it is packaging. I guess upgrading packaging would also make wheel upgraded. Before upgrading it, I was encountering errors like this, which indicated that it was a wheel version issue:
|
Wheel vendors packaging. But the traceback here indicates a problem that has already been fixed in the latest wheel release. |
I have M1 and upgraded to newest versions: wheel==0.36.2, packaging==21.0, but still get the same exception when installing scipy (numpy installed from wheels just in case). I've also tried running this one-time command without success. |
Are you sure it's actually using the latest wheel? Do other libraries build binary wheels properly? If so, then the culprit is most likely the scientific Python stack with its custom build processes. |
Possibly related: python/cpython#102362 |
We can not build numpy because of issue [^1] on macOS Big Sur or later. To resolve this, we need to bump three packages: numpy, pyworld, and scipy. All these packages depends on numpy, and the current required version of the packages require older version of numpy. [^1]: pypa/wheel#385 Signed-off-by: Naoki Ikeguchi <me@s6n.jp>
On previously macOS versions, the major version were 10.15, 10.14, etc. But on macOS Big Sur (11.x.y) the major version is now 11, and the next major version will be 12, etc.
Therefore, because
MACOSX_DEPLOYMENT_TARGET
typically specifies a major macOS version, it is now natural to haveMACOSX_DEPLOYMENT_TARGET=11
. This is accepted by all system build tools and compilers.This triggered several build failures in cpython 3.9.0, which are now fixed (see python/cpython#23556). This is also triggering problems now in wheel. We are seeing this error as part of Homebrew build and testing (Homebrew/homebrew-core#66063 (comment)).
I install Python 3.9.0, with an upstream patch (python/cpython#23556), and wheel 0.36.0. Then I run
pip3 install markupsafe
, which gives the following error:The text was updated successfully, but these errors were encountered: