blob: a94ca49b9131e0ac93188782d580fb961cd8ba3c (
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
{
lib,
buildPythonPackage,
fetchFromGitHub,
flit-core,
pytestCheckHook,
cerberus,
django,
djangorestframework,
marshmallow,
pyschemes,
wtforms,
email-validator,
}:
buildPythonPackage rec {
pname = "vaa";
version = "0.2.1";
format = "pyproject";
src = fetchFromGitHub {
owner = "life4";
repo = pname;
rev = "refs/tags/v.${version}";
hash = "sha256-24GTTJSZ55ejyHoWP1/S3DLTKvOolAJr9UhWoOm84CU=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace "requires = [\"flit\"]" "requires = [\"flit_core\"]" \
--replace "build-backend = \"flit.buildapi\"" "build-backend = \"flit_core.buildapi\""
'';
nativeBuildInputs = [ flit-core ];
nativeCheckInputs = [
pytestCheckHook
cerberus
django
djangorestframework
marshmallow
pyschemes
wtforms
email-validator
];
pythonImportsCheck = [ "vaa" ];
meta = with lib; {
description = "VAlidators Adapter makes validation by any existing validator with the same interface";
homepage = "https://github.com/life4/vaa";
license = licenses.mit;
maintainers = with maintainers; [ gador ];
};
}
|