Open pathway27 opened 9 months ago
I have the same issue.
Is there any update or solution on how to solve it? Thank you for helping.
Current workaround (as of 2024-04-21) for me:
overrides = poetry2nix.overrides.withDefaults (self: super: {
watchfiles = super.watchfiles.override {
preferWheel = false;
};
});
I have the same issue but for project name in my pyproject.toml
file. Any new ideas why this happens?
Hm, i changed a dependency in pyproject.toml
, created a new poetry.lock
and thereby somehow forced a new evaluation around that /nix/store/...-sources
folder on the next nix-build
and it worked again.
edit: The culprit dependency in our case on an M1/Arm64 Mac is this dependency:
# pyproject.toml
tensorflow-macos = {version = "2.9.0", markers = "sys_platform == \"darwin\""}
As soon as i remove this dependency at least the poetry2nix build works again.
From my observation yesterday, the build failed because the hook wheelUnpackPhase
was trying to unpack watchfiles
, but it's not packaged as the hook expects.
Hm, i changed a dependency in
pyproject.toml
, created a newpoetry.lock
and thereby somehow forced a new evaluation around that/nix/store/...-sources
folder on the nextnix-build
and it worked again.edit: The culprit dependency in our case on an M1/Arm64 Mac is this dependency:
# pyproject.toml tensorflow-macos = {version = "2.9.0", markers = "sys_platform == \"darwin\""}
As soon as i remove this dependency at least the poetry2nix build works again.
I'm seeing the same issue with tensorflow-cpu 2.14
- removing tensorflow allows my packaged to build without the cp -r ...
error.
Digging a bit further, the building of the project dependency (tensorflow-cpu
, tensorflow-mac
or watchfile
) itself should work (you can check that by building the buildEnv as in poetry2nix.mkPoetryApplication.buildEnv
instead).
The issue is our main project (defined by our pyproject.toml
), which as a last step is turned into a wheel and then installed normally as a pyproject
format installation of buildPythonPackage
without the "wheelUnpackPhase". See all available formats
However, these problematic dependencies make buildPythonPackage
build our main project as a "wheel" format (as if the source code was a ...arm64.whl
file). I couldn't find where this logic bug occurs, but the result is that this "wheelUnpackPhase" is added through wheelUnpackHook
either here
I can't quite follow the evaluation logic yet.
I ran into this because I had tensorboard as a dependency, it was fixed in this commit: https://github.com/nix-community/poetry2nix/commit/8c8f33437914c31c1e1de87a473c16867a4f2a6a
Describe the issue
I seem to get this weird error when trying to use the
dagster-webserver
python package. Any idea on what I can do?Additional context
default.nix
/shell.nix
/flake.nix
:pyproject.toml
:poetry.lock
: