1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 setuptools, 6 django, 7 django-stubs-ext, 8 typing-extensions, 9 mysqlclient, 10 psycopg, 11 dj-database-url, 12 django-rq, 13 fakeredis, 14 pytestCheckHook, 15 pytest-django, 16}: 17 18buildPythonPackage rec { 19 pname = "django-tasks"; 20 version = "0.8.1"; 21 pyproject = true; 22 23 src = fetchFromGitHub { 24 owner = "RealOrangeOne"; 25 repo = "django-tasks"; 26 tag = version; 27 hash = "sha256-fXXqPmpyIq+66okWDmTIBaoaslY8BSILXjJWn8cXnMM="; 28 }; 29 30 build-system = [ 31 setuptools 32 ]; 33 34 dependencies = [ 35 django 36 django-stubs-ext 37 typing-extensions 38 ]; 39 40 optional-dependencies = { 41 mysql = [ 42 mysqlclient 43 ]; 44 postgres = [ 45 psycopg 46 ]; 47 }; 48 49 pythonImportsCheck = [ "django_tasks" ]; 50 51 nativeCheckInputs = [ 52 dj-database-url 53 django-rq 54 fakeredis 55 pytestCheckHook 56 pytest-django 57 ]; 58 59 disabledTests = [ 60 # AssertionError: Lists differ: [] != ['Starting worker for queues=default', ... 61 "test_verbose_logging" 62 # AssertionError: '' != 'Deleted 0 task result(s)' 63 "test_doesnt_prune_new_task" 64 # AssertionError: '' != 'Would delete 1 task result(s)' 65 "test_dry_run" 66 # AssertionError: '' != 'Deleted 1 task result(s)' 67 "test_prunes_tasks" 68 # AssertionError: 'Run maximum tasks (2)' not found in '' 69 "test_max_tasks" 70 ]; 71 72 preCheck = '' 73 export DJANGO_SETTINGS_MODULE="tests.settings" 74 ''; 75 76 meta = { 77 description = "Reference implementation and backport of background workers and tasks in Django"; 78 homepage = "https://github.com/RealOrangeOne/django-tasks"; 79 changelog = "https://github.com/RealOrangeOne/django-tasks/releases/tag/${src.tag}"; 80 license = lib.licenses.bsd3; 81 maintainers = with lib.maintainers; [ GaetanLepage ]; 82 }; 83}