nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{ lib
2, aiohttp
3, buildPythonPackage
4, fetchFromGitHub
5, ftfy
6, mailchecker
7, phonenumbers
8, pytestCheckHook
9, python-dateutil
10, python-fsutil
11, pythonOlder
12, python-slugify
13, pyyaml
14, requests
15, six
16, toml
17, xmltodict
18}:
19
20buildPythonPackage rec {
21 pname = "python-benedict";
22 version = "0.25.1";
23 format = "setuptools";
24
25 disabled = pythonOlder "3.7";
26
27 src = fetchFromGitHub {
28 owner = "fabiocaccamo";
29 repo = pname;
30 rev = "refs/tags/${version}";
31 hash = "sha256-egOrotWgRyB6pdWUIRWogwdoK82g/1JfRDc85W4FrjQ=";
32 };
33
34 propagatedBuildInputs = [
35 mailchecker
36 phonenumbers
37 python-dateutil
38 python-fsutil
39 python-slugify
40 pyyaml
41 ftfy
42 requests
43 six
44 toml
45 xmltodict
46 ];
47
48 checkInputs = [
49 pytestCheckHook
50 ];
51
52 disabledTests = [
53 # Tests require network access
54 "test_from_base64_with_valid_url_valid_content"
55 "test_from_json_with_valid_url_valid_content"
56 "test_from_pickle_with_valid_url_valid_content"
57 "test_from_plist_with_valid_url_valid_content"
58 "test_from_query_string_with_valid_url_valid_content"
59 "test_from_toml_with_valid_url_valid_content"
60 "test_from_xml_with_valid_url_valid_content"
61 "test_from_yaml_with_valid_url_valid_content"
62 ];
63
64 pythonImportsCheck = [
65 "benedict"
66 ];
67
68 meta = with lib; {
69 description = "Module with keylist/keypath support";
70 homepage = "https://github.com/fabiocaccamo/python-benedict";
71 license = licenses.mit;
72 maintainers = with maintainers; [ fab ];
73 };
74}