-
-
Notifications
You must be signed in to change notification settings - Fork 453
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
[bug] platform_machine reported wrong on Arm machines lead to Missing suitable source/wheel file entry errors #1609
Comments
There are actually two issues:
tensorflow = super.tensorflow.overridePythonAttrs (
_old: {
postInstall = ''
rm $out/bin/tensorboard
'';
}
);
tensorflow-macos = super.tensorflow-macos.overridePythonAttrs (
_old: {
inherit (self.tensorflow) postInstall; <------------------
}
);
pep508Env = lib.debug.traceValSeq (pyproject-nix.lib.pep508.mkEnviron python); from Line 175 in 3c92540
results in {
implementation_name = { type = "string"; value = "cpython"; };
implementation_version = { type = "version"; value = { dev = null; epoch = 0; local = null; post = null; pre = null; release = [ 3 9 18 ]; }; };
os_name = { type = "string"; value = "posix"; };
platform_machine = { type = "string"; value = "aarch64"; }; <----------------------------- should be arm64
platform_python_implementation = { type = "string"; value = "CPython"; };
platform_release = { type = "string"; value = ""; };
platform_system = { type = "string"; value = "Darwin"; };
platform_version = { type = "version"; value = { dev = null; epoch = 0; local = null; post = null; pre = null; release = [ ]; }; };
python_full_version = { type = "version"; value = { dev = null; epoch = 0; local = null; post = null; pre = null; release = [ 3 9 18 ]; }; };
python_version = {
type = "version";
value = { dev = null; epoch = 0; local = null; post = null; pre = null; release = [ 3 9 ]; };
};
sys_platform = { type = "string"; value = "darwin"; };
} where as the wheel files metadata use $ python
Python 3.9.16 (main, Mar 27 2023, 10:43:20)
>>> import platform
>>> platform.machine()
'arm64' |
Thanks for looking into this. I ran to this problem probably months ago when I then decided to give up when I discovered the nifty details for This looks really detailed, is PR ready, or do you still need help investigating somewhere? |
No PR's ready. Feel free to copy and adapt the hacks at b8faf1f and 0efcdb9 Also some packages like |
… tensorflow Contributes to nix-community#1609.
… tensorflow Contributes to nix-community#1609.
As dependency markers are quite broken in the current state of |
Describe the issue
In our project we have a dependency that should use a normal package
tensorflow
on all platforms except on arm64 macs; there it should use a special, other packagetensorflow-macos
.A raw
poetry lock && poetry install
without Nix works as expected on all machines.However, on my arm64 M1 Mac poetry2nix tries to download the normal tensorflow package when it shouldn't:
$ nix-build ... error: Missing suitable source/wheel file entry for tensorflow
May it have an issue with multiple markers?
Additional context
Running on an M1 arm64 Mac with Python 3.9.18 with a
pyproject.toml
:The text was updated successfully, but these errors were encountered: