1{
2 lib,
3 fetchFromGitHub,
4 buildPythonPackage,
5 flask,
6 packaging,
7 pytestCheckHook,
8 setuptools,
9
10 # for passthru.tests
11 aiobotocore,
12 moto,
13}:
14
15buildPythonPackage rec {
16 pname = "flask-cors";
17 version = "5.0.0";
18 pyproject = true;
19
20 src = fetchFromGitHub {
21 owner = "corydolphin";
22 repo = "flask-cors";
23 tag = version;
24 hash = "sha256-DbTeq18CLuwj8lzQnpyPMEfxgR97XlF0s37wkTYd4O4=";
25 };
26
27 nativeBuildInputs = [ setuptools ];
28
29 propagatedBuildInputs = [ flask ];
30
31 nativeCheckInputs = [
32 pytestCheckHook
33 packaging
34 ];
35
36 passthru.tests = {
37 inherit aiobotocore moto;
38 };
39
40 meta = with lib; {
41 description = "Flask extension adding a decorator for CORS support";
42 homepage = "https://github.com/corydolphin/flask-cors";
43 changelog = "https://github.com/corydolphin/flask-cors/releases/tag/${src.tag}";
44 license = with licenses; [ mit ];
45 maintainers = with maintainers; [ nickcao ];
46 };
47}