7 djangorestframework-simplejwt,
13 unittest-xml-reporting,
16 buildPythonPackage rec {
17 pname = "dj-rest-auth";
21 disabled = pythonOlder "3.8";
23 src = fetchFromGitHub {
25 repo = "dj-rest-auth";
26 rev = "refs/tags/${version}";
27 hash = "sha256-fNy1uN3oH54Wd9+EqYpiV0ot1MbSSC7TZoAARQeR81s=";
31 substituteInPlace setup.py \
32 --replace-fail "==" ">="
33 substituteInPlace dj_rest_auth/tests/test_api.py \
34 --replace-fail "assertEquals" "assertEqual"
37 build-system = [ setuptools ];
39 buildInputs = [ django ];
41 dependencies = [ djangorestframework ];
43 optional-dependencies.with_social = [ django-allauth ];
46 djangorestframework-simplejwt
48 unittest-xml-reporting
49 ] ++ optional-dependencies.with_social;
52 # Test connects to graph.facebook.com
53 substituteInPlace dj_rest_auth/tests/test_serializers.py \
54 --replace-fail "def test_http_error" "def dont_test_http_error"
59 ${python.interpreter} runtests.py
63 pythonImportsCheck = [ "dj_rest_auth" ];
66 description = "Authentication for Django Rest Framework";
67 homepage = "https://github.com/iMerica/dj-rest-auth";
68 changelog = "https://github.com/iMerica/dj-rest-auth/releases/tag/${version}";
69 license = licenses.mit;