blob: 497d10d84fe8d1412e04e6bcb2f07aa7fd756903 (
plain) (
blame)
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
|
{ lib
, stdenv
, buildPythonPackage
, fetchFromGitHub
, pytestCheckHook
, pythonOlder
}:
buildPythonPackage rec {
pname = "token-bucket";
version = "0.3.0";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "falconry";
repo = pname;
rev = "refs/tags/${version}";
hash = "sha256-dazqJRpC8FUHOhgKFzDnIl5CT2L74J2o2Hsm0IQf4Cg=";
};
postPatch = ''
substituteInPlace setup.py \
--replace "'pytest-runner'" ""
'';
nativeCheckInputs = [
pytestCheckHook
];
doCheck = !stdenv.isDarwin;
meta = with lib; {
description = "Token Bucket Implementation for Python Web Apps";
homepage = "https://github.com/falconry/token-bucket";
changelog = "https://github.com/falconry/token-bucket/releases/tag/${version}";
license = licenses.asl20;
maintainers = with maintainers; [ hexa ];
};
}
|