1{ lib 2, buildPythonPackage 3, chardet 4, diff-match-patch 5, django 6, fetchFromGitHub 7, psycopg2 8, python 9, pythonOlder 10, pytz 11, tablib 12}: 13 14buildPythonPackage rec { 15 pname = "django-import-export"; 16 version = "3.3.1"; 17 format = "setuptools"; 18 19 disabled = pythonOlder "3.7"; 20 21 src = fetchFromGitHub { 22 owner = "django-import-export"; 23 repo = pname; 24 rev = "refs/tags/${version}"; 25 hash = "sha256-9eFBFTx+M28tbIKflldvDJW1po5ht/5FBX5ImfHGFuk="; 26 }; 27 28 propagatedBuildInputs = [ 29 diff-match-patch 30 django 31 tablib 32 ] ++ (with tablib.optional-dependencies; html ++ ods ++ xls ++ xlsx ++ yaml); 33 34 nativeCheckInputs = [ 35 chardet 36 psycopg2 37 pytz 38 ]; 39 40 checkPhase = '' 41 runHook preCheck 42 ${python.interpreter} tests/manage.py test core --settings=settings 43 runHook postCheck 44 ''; 45 46 pythonImportsCheck = [ 47 "import_export" 48 ]; 49 50 meta = with lib; { 51 description = "Django application and library for importing and exporting data with admin integration"; 52 homepage = "https://github.com/django-import-export/django-import-export"; 53 changelog = "https://github.com/django-import-export/django-import-export/blob/${version}/docs/changelog.rst"; 54 license = licenses.bsd2; 55 maintainers = with maintainers; [ sephi ]; 56 }; 57}