Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, djangorestframework 5, setuptools 6}: 7 8buildPythonPackage rec { 9 pname = "djangorestframework-dataclasses"; 10 version = "1.2.0"; 11 format = "pyproject"; 12 13 src = fetchFromGitHub { 14 owner = "oxan"; 15 repo = "djangorestframework-dataclasses"; 16 rev = "refs/tags/v${version}"; 17 hash = "sha256-PTX5huYdusPV6xCBW+8sFwusuPtZBH1vVApvcQU7Dlc="; 18 }; 19 20 nativeBuildInputs = [ 21 setuptools 22 ]; 23 24 postPatch = '' 25 patchShebangs manage.py 26 ''; 27 28 propagatedBuildInputs = [ 29 djangorestframework 30 ]; 31 32 checkPhase = '' 33 ./manage.py test 34 ''; 35 36 pythonImportsCheck = [ "rest_framework_dataclasses" ]; 37 38 meta = with lib; { 39 description = " Dataclasses serializer for Django REST framework"; 40 homepage = "https://github.com/oxan/djangorestframework-dataclasses"; 41 license = licenses.bsd3; 42 maintainers = with maintainers; [ SuperSandro2000 ]; 43 }; 44}