1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, pythonOlder
5, w3lib
6, parsel
7, jmespath
8, itemadapter
9, pytestCheckHook
10}:
11
12buildPythonPackage rec {
13 pname = "itemloaders";
14 version = "1.0.6";
15 format = "setuptools";
16
17 disabled = pythonOlder "3.6";
18
19 src = fetchFromGitHub {
20 owner = "scrapy";
21 repo = pname;
22 rev = "refs/tags/v${version}";
23 hash = "sha256-ZzpWIJNDve6SvLDb+QUDVSXUfJabFuRwtyBeCUasUgY=";
24 };
25
26 propagatedBuildInputs = [
27 w3lib
28 parsel
29 jmespath
30 itemadapter
31 ];
32
33 checkInputs = [
34 pytestCheckHook
35 ];
36
37 disabledTests = [
38 # Test are failing (AssertionError: Lists differ: ...)
39 "test_nested_css"
40 "test_nested_xpath"
41 ];
42
43 pythonImportsCheck = [
44 "itemloaders"
45 ];
46
47 meta = with lib; {
48 description = "Base library for scrapy's ItemLoader";
49 homepage = "https://github.com/scrapy/itemloaders";
50 changelog = "https://github.com/scrapy/itemloaders/raw/v${version}/docs/release-notes.rst";
51 license = licenses.bsd3;
52 maintainers = with maintainers; [ marsam ];
53 };
54}