about summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorFabian Affolter <mail@fabian-affolter.ch>2022-11-01 23:54:39 +0100
committerFabian Affolter <mail@fabian-affolter.ch>2022-11-01 23:54:39 +0100
commitaee30a880155db2e7c84e7a4d210a02b820272f0 (patch)
treee27d944a9106efc37b14c8cf7e2b21ca8410f351 /pkgs
parent796cc1ad514ec46ab0631ec56e6cb4e397f36e26 (diff)
python310Packages.parsel: 1.6.0 -> 1.7.0
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/development/python-modules/parsel/default.nix49
1 files changed, 18 insertions, 31 deletions
diff --git a/pkgs/development/python-modules/parsel/default.nix b/pkgs/development/python-modules/parsel/default.nix
index 423f4eb0293bb..9c70561cd37b5 100644
--- a/pkgs/development/python-modules/parsel/default.nix
+++ b/pkgs/development/python-modules/parsel/default.nix
@@ -2,63 +2,50 @@
 , buildPythonPackage
 , cssselect
 , fetchPypi
-, functools32
-, isPy27
 , lxml
+, packaging
+, psutil
 , pytestCheckHook
-, six
+, pythonOlder
 , w3lib
 }:
 
 buildPythonPackage rec {
   pname = "parsel";
-  version = "1.6.0";
+  version = "1.7.0";
+  format = "setuptools";
+
+  disabled = pythonOlder "3.7";
 
   src = fetchPypi {
     inherit pname version;
-    sha256 = "0yawf9r3r863lwxj0n89i7h3n8xjbsl5b7n6xg76r68scl5yzvvh";
+    hash = "sha256-AlQTPLAwTeE/zEhXu4IU/3DWmIcnYfpr6DdOG7vVgZI=";
   };
 
+  postPatch = ''
+    substituteInPlace setup.py \
+      --replace '"pytest-runner",' ""
+  '';
+
   propagatedBuildInputs = [
     cssselect
     lxml
-    six
+    packaging
     w3lib
-  ] ++ lib.optionals isPy27 [
-    functools32
   ];
 
   checkInputs = [
+    psutil
     pytestCheckHook
   ];
 
-  postPatch = ''
-    substituteInPlace setup.py \
-      --replace "'pytest-runner'," ""
-  '';
-
-  disabledTests = [
-    # Test are out-dated and are failing (AssertionError: Lists differ: ...)
-    # https://github.com/scrapy/parsel/pull/174
-    "test_differences_parsing_xml_vs_html"
-    "test_nested_selectors"
-    "test_re"
-    "test_replacement_null_char_from_body"
-    "test_select_on_text_nodes"
-    "test_selector_get_alias"
-    "test_selector_getall_alias"
-    "test_selector_over_text"
-    "test_selectorlist_get_alias"
-    "test_selectorlist_getall_alias"
-    "test_slicing"
-    "test_text_pseudo_element"
+  pythonImportsCheck = [
+    "parsel"
   ];
 
-  pythonImportsCheck = [ "parsel" ];
-
   meta = with lib; {
-    homepage = "https://github.com/scrapy/parsel";
     description = "Python library to extract data from HTML and XML using XPath and CSS selectors";
+    homepage = "https://github.com/scrapy/parsel";
     license = licenses.bsd3;
     maintainers = with maintainers; [ fab ];
   };