about summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorFabian Affolter <fabian@affolter-engineering.ch>2022-02-28 14:42:25 +0100
committerGitHub <noreply@github.com>2022-02-28 14:42:25 +0100
commitcac893eaedf2126064b5a999862b660745d6e4e6 (patch)
tree803517f146fa54867f4da4e4103118abdad3a13a /pkgs
parenta53ee3d2060a98de88bbdadd5c88f970513dcd6b (diff)
parentba549fc0b99546fa7a3f442a333b8a638177e2fa (diff)
Merge pull request #162193 from fabaff/fix-portpicker
python3Packages.portpicker: fix build
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/development/python-modules/portpicker/default.nix26
1 files changed, 19 insertions, 7 deletions
diff --git a/pkgs/development/python-modules/portpicker/default.nix b/pkgs/development/python-modules/portpicker/default.nix
index fd7bf7bc09c34..faf3b95816286 100644
--- a/pkgs/development/python-modules/portpicker/default.nix
+++ b/pkgs/development/python-modules/portpicker/default.nix
@@ -1,6 +1,8 @@
-{ buildPythonPackage
-, lib
+{ lib
+, buildPythonPackage
 , fetchPypi
+, psutil
+, pythonOlder
 }:
 
 buildPythonPackage rec {
@@ -8,15 +10,25 @@ buildPythonPackage rec {
   version = "1.5.0";
   format = "pyproject";
 
+  disabled = pythonOlder "3.7";
+
   src = fetchPypi {
     inherit pname version;
-    sha256 = "e13b148008adeb2793cf8b55bcd20fdcec4f763f2d3bf3c45f5e5e5d1df7d228";
+    hash = "sha256-4TsUgAit6yeTz4tVvNIP3OxPdj8tO/PEX15eXR330ig=";
   };
 
-  meta = {
-    description = "A library to choose unique available network ports.";
+  propagatedBuildInputs = [
+    psutil
+  ];
+
+  pythonImportsCheck = [
+    "portpicker"
+  ];
+
+  meta = with lib; {
+    description = "Library to choose unique available network ports";
     homepage = "https://github.com/google/python_portpicker";
-    license = lib.licenses.asl20;
-    maintainers = with lib.maintainers; [ danharaj ];
+    license = licenses.asl20;
+    maintainers = with maintainers; [ danharaj ];
   };
 }