2021-09-18 10:52:07 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
2021-09-26 12:46:18 +00:00
|
|
|
, poetry-core
|
2021-09-18 10:52:07 +00:00
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
|
|
|
, colorful
|
|
|
|
, tomlkit
|
|
|
|
, git
|
2022-02-10 20:34:41 +00:00
|
|
|
, packaging
|
2021-09-18 10:52:07 +00:00
|
|
|
, requests
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pontos";
|
2022-03-05 16:20:37 +00:00
|
|
|
version = "22.2.4";
|
2021-09-18 10:52:07 +00:00
|
|
|
format = "pyproject";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "greenbone";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2022-03-05 16:20:37 +00:00
|
|
|
hash = "sha256-RmMlwnAJlCTDnTyim0MdAeW3NA8r2IiqrE0YeWgxUk4=";
|
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
|
|
|
|
tomlkit
|
2022-02-10 20:34:41 +00:00
|
|
|
packaging
|
2021-09-18 10:52:07 +00:00
|
|
|
requests
|
|
|
|
];
|
|
|
|
|
|
|
|
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 = [
|
|
|
|
# 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"
|
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 ];
|
|
|
|
};
|
|
|
|
}
|