1{ lib
2, beautifultable
3, buildPythonPackage
4, click
5, click-default-group
6, fetchFromGitHub
7, humanize
8, keyring
9, unittestCheckHook
10, python-dateutil
11, pythonOlder
12, requests
13}:
14
15buildPythonPackage rec {
16 pname = "mwdblib";
17 version = "4.5.0";
18 format = "setuptools";
19
20 disabled = pythonOlder "3.7";
21
22 src = fetchFromGitHub {
23 owner = "CERT-Polska";
24 repo = pname;
25 rev = "refs/tags/v${version}";
26 hash = "sha256-+hh7SJFITpLumIuzNgBbXtFh+26tUG66UFv6DLDk5ag=";
27 };
28
29 propagatedBuildInputs = [
30 beautifultable
31 click
32 click-default-group
33 humanize
34 keyring
35 python-dateutil
36 requests
37 ];
38
39 nativeCheckInputs = [ unittestCheckHook ];
40
41 pythonImportsCheck = [
42 "mwdblib"
43 ];
44
45 meta = with lib; {
46 description = "Python client library for the mwdb service";
47 homepage = "https://github.com/CERT-Polska/mwdblib";
48 changelog = "https://github.com/CERT-Polska/mwdblib/releases/tag/v${version}";
49 license = with licenses; [ bsd3 ];
50 maintainers = with maintainers; [ fab ];
51 };
52}