1{ lib 2, beautifultable 3, buildPythonPackage 4, click 5, click-default-group 6, fetchFromGitHub 7, humanize 8, keyring 9, python 10, python-dateutil 11, requests 12}: 13 14buildPythonPackage rec { 15 pname = "mwdblib"; 16 version = "3.4.1"; 17 18 src = fetchFromGitHub { 19 owner = "CERT-Polska"; 20 repo = pname; 21 rev = "v${version}"; 22 sha256 = "sha256-jCtK3Fk725EaA26GG6j6xqEMFH4Qq92QWrJ7sxcWRaY="; 23 }; 24 25 propagatedBuildInputs = [ 26 beautifultable 27 click 28 click-default-group 29 humanize 30 keyring 31 python-dateutil 32 requests 33 ]; 34 35 checkPhase = '' 36 runHook preCheck 37 ${python.interpreter} -m unittest discover 38 runHook postCheck 39 ''; 40 41 pythonImportsCheck = [ "mwdblib" ]; 42 43 meta = with lib; { 44 description = "Python client library for the mwdb service"; 45 homepage = "https://github.com/CERT-Polska/mwdblib"; 46 license = with licenses; [ bsd3 ]; 47 maintainers = with maintainers; [ fab ]; 48 }; 49}