nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 django,
6 pydantic,
7 hatchling,
8 djangorestframework,
9 pytestCheckHook,
10 pytest-cov-stub,
11}:
12
13buildPythonPackage rec {
14 pname = "drf-pydantic";
15 version = "2.9.1";
16 pyproject = true;
17
18 src = fetchFromGitHub {
19 owner = "georgebv";
20 repo = "drf-pydantic";
21 tag = "v${version}";
22 hash = "sha256-/dMhKlAMAh63JlhanfSfe15ECMZvtnd1huD8L3Xo2AQ=";
23 };
24
25 build-system = [
26 hatchling
27 ];
28
29 dependencies = [
30 django
31 pydantic
32 djangorestframework
33 ];
34
35 nativeCheckInputs = [
36 pytestCheckHook
37 pytest-cov-stub
38 pydantic.optional-dependencies.email
39 ];
40
41 meta = {
42 changelog = "https://github.com/georgebv/drf-pydantic/releases/tag/${src.tag}";
43 description = "Use pydantic with the Django REST framework";
44 homepage = "https://github.com/georgebv/drf-pydantic";
45 maintainers = [ lib.maintainers.kiara ];
46 license = lib.licenses.mit;
47 };
48}