2023-02-15 14:17:21 +13:00
|
|
|
{ lib, poetry2nix }:
|
2020-01-21 12:30:41 +00:00
|
|
|
let
|
|
|
|
drv = poetry2nix.mkPoetryApplication {
|
|
|
|
pyproject = ./pyproject.toml;
|
|
|
|
poetrylock = ./poetry.lock;
|
|
|
|
src = lib.cleanSource ./.;
|
2020-02-25 14:24:48 +01:00
|
|
|
overrides = poetry2nix.overrides.withDefaults
|
2020-01-21 12:30:41 +00:00
|
|
|
# This is also in overrides.nix but repeated for completeness
|
|
|
|
(
|
2023-10-26 12:18:24 +13:00
|
|
|
_self: super: {
|
2020-01-21 12:30:41 +00:00
|
|
|
maturin = super.maturin.override {
|
|
|
|
preferWheel = true;
|
|
|
|
};
|
2023-10-26 12:18:24 +13:00
|
|
|
funcy = super.funcy.overridePythonAttrs (_old: {
|
2023-01-19 10:53:20 +00:00
|
|
|
preferWheel = true;
|
|
|
|
});
|
2020-01-21 12:30:41 +00:00
|
|
|
}
|
2020-02-25 14:24:48 +01:00
|
|
|
);
|
2020-01-21 12:30:41 +00:00
|
|
|
};
|
2023-01-19 10:53:20 +00:00
|
|
|
isWheelMaturin = drv.passthru.python.pkgs.maturin.src.isWheel or false;
|
|
|
|
isWheelFuncy = drv.passthru.python.pkgs.funcy.src.isWheel or false;
|
2020-01-21 12:30:41 +00:00
|
|
|
in
|
2023-01-26 10:00:13 +00:00
|
|
|
assert isWheelMaturin;
|
|
|
|
|
|
|
|
# HACK https://github.com/nix-community/poetry2nix/pull/948
|
|
|
|
# TODO Be able some day to invert this assertion
|
|
|
|
assert !isWheelFuncy;
|
|
|
|
drv
|