Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / pontos / default.nix
blob70cf9bc721ddbfe3da8fef6d7046c110825a0801
1 { lib
2 , buildPythonPackage
3 , colorful
4 , fetchFromGitHub
5 , git
6 , httpx
7 , lxml
8 , packaging
9 , poetry-core
10 , pytestCheckHook
11 , python-dateutil
12 , pythonOlder
13 , semver
14 , rich
15 , tomlkit
16 , typing-extensions
19 buildPythonPackage rec {
20   pname = "pontos";
21   version = "23.9.1";
22   format = "pyproject";
24   disabled = pythonOlder "3.9";
26   src = fetchFromGitHub {
27     owner = "greenbone";
28     repo = pname;
29     rev = "refs/tags/v${version}";
30     hash = "sha256-HRIGS2B6tc4qaOMTud5/uhEr1k7puqJUugDj1WuacqU=";
31   };
33   nativeBuildInputs = [
34     poetry-core
35   ];
37   propagatedBuildInputs = [
38     colorful
39     httpx
40     lxml
41     packaging
42     python-dateutil
43     semver
44     rich
45     typing-extensions
46     tomlkit
47   ] ++ lib.optionals (pythonOlder "3.8") [
48     typing-extensions
49   ] ++ httpx.optional-dependencies.http2;
51   nativeCheckInputs = [
52     git
53     pytestCheckHook
54   ];
56   disabledTests = [
57     "PrepareTestCase"
58     # Signing fails
59     "test_find_no_signing_key"
60     "test_find_signing_key"
61     "test_find_unreleased_information"
62     # CLI test fails
63     "test_missing_cmd"
64     "test_update_file_changed"
65     # Network access
66     "test_fail_sign_on_upload_fail"
67     "test_successfully_sign"
68     # calls git log, but our fetcher removes .git
69     "test_git_error"
70     # Tests require git executable
71     "test_github_action_output"
72     "test_initial_release"
73   ];
75   pythonImportsCheck = [
76     "pontos"
77   ];
79   meta = with lib; {
80     description = "Collection of Python utilities, tools, classes and functions";
81     homepage = "https://github.com/greenbone/pontos";
82     changelog = "https://github.com/greenbone/pontos/releases/tag/v${version}";
83     license = with licenses; [ gpl3Plus ];
84     maintainers = with maintainers; [ fab ];
85   };