blob: 0eed5cf1a62d52c3d68d6a89b91682793ba66dfd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
{
lib,
buildPythonPackage,
docker,
fetchFromGitHub,
poetry-core,
pytestCheckHook,
requests,
responses,
}:
buildPythonPackage rec {
pname = "securityreporter";
version = "1.3.0";
pyproject = true;
src = fetchFromGitHub {
owner = "dongit-org";
repo = "python-reporter";
tag = "v${version}";
hash = "sha256-YvUDgsKM0JUajp8JAR2vj30QsNtcGvADGCZ791ZZD/8=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace-fail 'version = "0.0.0"' 'version = "${version}"'
'';
build-system = [ poetry-core ];
dependencies = [ requests ];
nativeCheckInputs = [
docker
pytestCheckHook
responses
];
pythonImportsCheck = [ "reporter" ];
disabledTestPaths = [
# Test require a running Docker instance
"tests/functional/"
];
meta = {
description = "Python wrapper for the Reporter API";
homepage = "https://github.com/dongit-org/python-reporter";
changelog = "https://github.com/dongit-org/python-reporter/releases/tag/v${version}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ fab ];
};
}
|