5ca88bfbb9
GitOrigin-RevId: 9f918d616c5321ad374ae6cb5ea89c9e04bf3e58
38 lines
811 B
Nix
38 lines
811 B
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
fetchFromGitHub,
|
|
python,
|
|
django,
|
|
dj-database-url,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "django-polymorphic";
|
|
version = "3.1";
|
|
format = "setuptools";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "django-polymorphic";
|
|
repo = "django-polymorphic";
|
|
rev = "v${version}";
|
|
hash = "sha256-JJY+FoMPSnWuSsNIas2JedGJpdm6RfPE3E1VIjGuXIc=";
|
|
};
|
|
|
|
propagatedBuildInputs = [ django ];
|
|
|
|
nativeCheckInputs = [ dj-database-url ];
|
|
|
|
checkPhase = ''
|
|
${python.interpreter} runtests.py
|
|
'';
|
|
|
|
pythonImportsCheck = [ "polymorphic" ];
|
|
|
|
meta = with lib; {
|
|
homepage = "https://github.com/django-polymorphic/django-polymorphic";
|
|
description = "Improved Django model inheritance with automatic downcasting";
|
|
license = licenses.bsd3;
|
|
maintainers = [ ];
|
|
};
|
|
}
|