about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/pikepdf/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/pikepdf/default.nix')
-rw-r--r--nixpkgs/pkgs/development/python-modules/pikepdf/default.nix44
1 files changed, 21 insertions, 23 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/pikepdf/default.nix b/nixpkgs/pkgs/development/python-modules/pikepdf/default.nix
index ff2a2ce4c5e7..8ed27ea962ed 100644
--- a/nixpkgs/pkgs/development/python-modules/pikepdf/default.nix
+++ b/nixpkgs/pkgs/development/python-modules/pikepdf/default.nix
@@ -1,4 +1,5 @@
-{ attrs
+{ lib
+, attrs
 , buildPythonPackage
 , defusedxml
 , fetchPypi
@@ -6,29 +7,28 @@
 , isPy3k
 , lxml
 , pillow
+, psutil
 , pybind11
-, pytestCheckHook
+, pytest-cov
 , pytest-helpers-namespace
 , pytest-timeout
-, pytest_xdist
-, pytestrunner
+, pytest-xdist
+, pytestCheckHook
 , python-dateutil
 , python-xmp-toolkit
-, python3
 , qpdf
+, setuptools-scm
 , setuptools-scm-git-archive
-, setuptools_scm
-, lib, stdenv
 }:
 
 buildPythonPackage rec {
   pname = "pikepdf";
-  version = "2.2.0";
+  version = "2.5.2";
   disabled = ! isPy3k;
 
   src = fetchPypi {
     inherit pname version;
-    sha256 = "74300a32c41b3d578772f6933f23a88b19f74484185e71e5225ce2f7ea5aea78";
+    sha256 = "sha256-j8PpeyTa+9SxrAV8jxRMGEZ85V00KhqMQmiIkOrVjvM=";
   };
 
   buildInputs = [
@@ -38,36 +38,34 @@ buildPythonPackage rec {
 
   nativeBuildInputs = [
     setuptools-scm-git-archive
-    setuptools_scm
+    setuptools-scm
   ];
 
   checkInputs = [
     attrs
     hypothesis
-    pillow
-    pytestCheckHook
     pytest-helpers-namespace
     pytest-timeout
-    pytest_xdist
-    pytestrunner
+    pytest-xdist
+    psutil
+    pytest-cov
+    pytestCheckHook
     python-dateutil
     python-xmp-toolkit
   ];
 
-  propagatedBuildInputs = [ defusedxml lxml ];
-
-  postPatch = ''
-    sed -i \
-      -e 's/^pytest .*/pytest/g' \
-      -e 's/^attrs .*/attrs/g' \
-      -e 's/^hypothesis .*/hypothesis/g' \
-      requirements/test.txt
-  '';
+  propagatedBuildInputs = [
+    defusedxml
+    lxml
+    pillow
+  ];
 
   preBuild = ''
     HOME=$TMPDIR
   '';
 
+  pythonImportsCheck = [ "pikepdf" ];
+
   meta = with lib; {
     homepage = "https://github.com/pikepdf/pikepdf";
     description = "Read and write PDFs with Python, powered by qpdf";