1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 setuptools, 6 django, 7 dj-database-url, 8 pytest-django, 9 pytestCheckHook, 10}: 11 12buildPythonPackage rec { 13 pname = "django-polymorphic"; 14 version = "4.0.0"; 15 pyproject = true; 16 17 src = fetchFromGitHub { 18 owner = "django-polymorphic"; 19 repo = "django-polymorphic"; 20 tag = "v${version}"; 21 hash = "sha256-cEV9gnc9gLpAVmYkzSaQwDbgXsklMTq71edndDJeP9E="; 22 }; 23 24 patches = [ 25 # https://github.com/jazzband/django-polymorphic/issues/616 26 ./django-5.1-compat.patch 27 ]; 28 29 build-system = [ setuptools ]; 30 31 dependencies = [ django ]; 32 33 nativeCheckInputs = [ 34 dj-database-url 35 pytest-django 36 pytestCheckHook 37 ]; 38 39 pythonImportsCheck = [ "polymorphic" ]; 40 41 meta = with lib; { 42 changelog = "https://github.com/jazzband/django-polymorphic/releases/tag/${src.tag}"; 43 homepage = "https://github.com/django-polymorphic/django-polymorphic"; 44 description = "Improved Django model inheritance with automatic downcasting"; 45 license = licenses.bsd3; 46 maintainers = [ ]; 47 }; 48}