1{ lib 2, buildPythonPackage 3, pythonAtLeast 4, fetchpatch 5, fetchFromGitHub 6, python 7, django 8, packaging 9, nodejs 10, js2py 11, six 12}: 13 14buildPythonPackage rec { 15 pname = "django-js-reverse"; 16 version = "0.10.1-b1"; 17 18 src = fetchFromGitHub { 19 owner = "BITSOLVER"; 20 repo = "django-js-reverse"; 21 rev = version; 22 hash = "sha256-i78UsxVwxyDAc8LrOVEXLG0tdidoQhvUx7GvPDaH0KY="; 23 }; 24 25 propagatedBuildInputs = [ 26 django 27 ] ++ lib.optionals (pythonAtLeast "3.7") [ 28 packaging 29 ]; 30 31 nativeCheckInputs = [ 32 nodejs 33 js2py 34 six 35 ]; 36 37 checkPhase = '' 38 ${python.interpreter} django_js_reverse/tests/unit_tests.py 39 ''; 40 41 pythonImportsCheck = [ "django_js_reverse" ]; 42 43 meta = with lib; { 44 description = "Javascript url handling for Django that doesn't hurt"; 45 homepage = "https://django-js-reverse.readthedocs.io/en/latest/"; 46 license = licenses.mit; 47 maintainers = with maintainers; [ ambroisie ]; 48 }; 49}