1{ 2 lib, 3 buildPythonPackage, 4 pythonOlder, 5 fetchFromGitHub, 6 poetry-core, 7 django, 8 djangorestframework, 9 pytestCheckHook, 10 pytest-django, 11 pytest-lazy-fixture, 12 pytz, 13}: 14 15buildPythonPackage rec { 16 pname = "django-timezone-field"; 17 version = "7.0"; 18 pyproject = true; 19 20 disabled = pythonOlder "3.8"; 21 22 src = fetchFromGitHub { 23 owner = "mfogel"; 24 repo = "django-timezone-field"; 25 rev = version; 26 hash = "sha256-q06TuYkBA4z6tJdT3an6Z8o1i/o85XbYa1JYZBHC8lI="; 27 }; 28 29 build-system = [ poetry-core ]; 30 31 dependencies = [ django ]; 32 33 pythonImportsCheck = [ 34 # Requested setting USE_DEPRECATED_PYTZ, but settings are not configured. 35 #"timezone_field" 36 ]; 37 38 preCheck = '' 39 export DJANGO_SETTINGS_MODULE=tests.settings 40 ''; 41 42 nativeCheckInputs = [ 43 djangorestframework 44 pytestCheckHook 45 pytest-django 46 pytest-lazy-fixture 47 pytz 48 ]; 49 50 meta = with lib; { 51 description = "Django app providing database, form and serializer fields for pytz timezone objects"; 52 homepage = "https://github.com/mfogel/django-timezone-field"; 53 license = licenses.bsd2; 54 maintainers = with maintainers; [ hexa ]; 55 }; 56}