From 7832456e4c50a06f1944ce3aa296bbf588fa6ca3 Mon Sep 17 00:00:00 2001 From: Patka Date: Wed, 14 Feb 2024 15:11:48 +0100 Subject: [PATCH] python311Packages.fastembed: fix build --- .../python-modules/fastembed/default.nix | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/fastembed/default.nix b/pkgs/development/python-modules/fastembed/default.nix index 65536d16151b..0302770761ed 100644 --- a/pkgs/development/python-modules/fastembed/default.nix +++ b/pkgs/development/python-modules/fastembed/default.nix @@ -1,8 +1,11 @@ { lib , buildPythonPackage , fetchFromGitHub +, huggingface-hub , pythonOlder +, pythonRelaxDepsHook , poetry-core +, onnx , onnxruntime , requests , tokenizers @@ -13,7 +16,7 @@ buildPythonPackage rec { pname = "fastembed"; version = "0.1.2"; - format = "pyproject"; + pyproject = true; disabled = pythonOlder "3.8"; @@ -26,16 +29,25 @@ buildPythonPackage rec { nativeBuildInputs = [ poetry-core + pythonRelaxDepsHook ]; propagatedBuildInputs = [ + huggingface-hub + onnx onnxruntime requests tokenizers tqdm ]; - pythonImportsCheck = [ "fastembed" ]; + pythonImportsCheck = [ + "fastembed" + ]; + + pythonRelaxDeps = [ + "huggingface-hub" + ]; nativeCheckInputs = [ pytestCheckHook