2021-09-18 10:52:07 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
2022-08-21 13:32:41 +00:00
|
|
|
, colorful
|
2021-09-18 10:52:07 +00:00
|
|
|
, fetchFromGitHub
|
2022-08-21 13:32:41 +00:00
|
|
|
, git
|
|
|
|
, httpx
|
|
|
|
, packaging
|
2021-09-26 12:46:18 +00:00
|
|
|
, poetry-core
|
2021-09-18 10:52:07 +00:00
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
2022-08-21 13:32:41 +00:00
|
|
|
, rich
|
2021-09-18 10:52:07 +00:00
|
|
|
, tomlkit
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pontos";
|
2022-10-30 15:09:59 +00:00
|
|
|
version = "22.10.0";
|
2021-09-18 10:52:07 +00:00
|
|
|
format = "pyproject";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "greenbone";
|
|
|
|
repo = pname;
|
2022-09-22 12:36:57 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2022-10-30 15:09:59 +00:00
|
|
|
hash = "sha256-z+oJakeZARnyZrkkNjLlyFcOB73u9+G0tXhbI13neyc=";
|
2021-09-18 10:52:07 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
2021-09-26 12:46:18 +00:00
|
|
|
poetry-core
|
2021-09-18 10:52:07 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
colorful
|
2022-08-21 13:32:41 +00:00
|
|
|
httpx
|
2022-02-10 20:34:41 +00:00
|
|
|
packaging
|
2022-08-21 13:32:41 +00:00
|
|
|
rich
|
|
|
|
tomlkit
|
2021-09-18 10:52:07 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
git
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2022-02-10 20:34:41 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace pyproject.toml \
|
|
|
|
--replace 'packaging = "^20.3"' 'packaging = "*"'
|
|
|
|
'';
|
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
disabledTests = [
|
2022-08-21 13:32:41 +00:00
|
|
|
"PrepareTestCase"
|
2021-09-18 10:52:07 +00:00
|
|
|
# Signing fails
|
|
|
|
"test_find_no_signing_key"
|
|
|
|
"test_find_signing_key"
|
|
|
|
"test_find_unreleased_information"
|
2021-10-08 15:17:17 +00:00
|
|
|
# CLI test fails
|
|
|
|
"test_missing_cmd"
|
2022-05-18 14:49:53 +00:00
|
|
|
"test_update_file_changed"
|
2022-07-14 12:49:19 +00:00
|
|
|
# Network access
|
|
|
|
"test_fail_sign_on_upload_fail"
|
|
|
|
"test_successfully_sign"
|
2021-09-18 10:52:07 +00:00
|
|
|
];
|
|
|
|
|
2022-02-10 20:34:41 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"pontos"
|
|
|
|
];
|
2021-09-18 10:52:07 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Collection of Python utilities, tools, classes and functions";
|
|
|
|
homepage = "https://github.com/greenbone/pontos";
|
|
|
|
license = with licenses; [ gpl3Plus ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|