1{ lib
2, babel
3, buildPythonPackage
4, fetchFromGitLab
5, fetchpatch
6, gnupg
7, html2text
8, libyaml
9, lxml
10, nose
11, packaging
12, pillow
13, prettytable
14, pycountry
15, python-dateutil
16, pythonOlder
17, pyyaml
18, requests
19, termcolor
20, testers
21, unidecode
22, woob
23}:
24
25buildPythonPackage rec {
26 pname = "woob";
27 version = "3.5";
28 format = "pyproject";
29
30 disabled = pythonOlder "3.7";
31
32 src = fetchFromGitLab {
33 owner = "woob";
34 repo = pname;
35 rev = version;
36 hash = "sha256-Yb3AgUSqr9r2TIymiEUIhKThNC7yjQEkhi8GSI9fqNA=";
37 };
38
39 nativeBuildInputs = [
40 packaging
41 ];
42
43 propagatedBuildInputs = [
44 babel
45 python-dateutil
46 gnupg
47 html2text
48 libyaml
49 lxml
50 packaging
51 pillow
52 prettytable
53 pycountry
54 pyyaml
55 requests
56 termcolor
57 unidecode
58 ];
59
60 nativeCheckInputs = [
61 nose
62 ];
63
64 checkPhase = ''
65 nosetests
66 '';
67
68 pythonImportsCheck = [
69 "woob"
70 ];
71
72 passthru.tests.version = testers.testVersion {
73 package = woob;
74 version = "v${version}";
75 };
76
77 meta = with lib; {
78 description = "Collection of applications and APIs to interact with websites";
79 homepage = "https://woob.tech";
80 license = licenses.lgpl3Plus;
81 maintainers = with maintainers; [ DamienCassou ];
82 };
83}