biome: 1.9.2 -> 1.9.3 (#349335)
[NixPkgs.git] / pkgs / development / python-modules / django-login-required-middleware / default.nix
blob7dbbbcd9a411ae64d81c4085d2a6886f2a602aab
2   lib,
3   buildPythonPackage,
4   django,
5   djangorestframework,
6   fetchFromGitHub,
7   python,
8   setuptools-scm,
9 }:
11 buildPythonPackage rec {
12   pname = "django-login-required-middleware";
13   version = "0.9.0";
14   format = "pyproject";
16   src = fetchFromGitHub {
17     owner = "CleitonDeLima";
18     repo = pname;
19     rev = "refs/tags/${version}";
20     hash = "sha256-WFQ/JvKh6gkUxPV27QBd2TzwFS8hfQGmcTInTnmh6iA=";
21   };
23   nativeBuildInputs = [ setuptools-scm ];
25   propagatedBuildInputs = [ django ];
27   checkInputs = [ djangorestframework ];
29   pythonImportsCheck = [ "login_required" ];
31   checkPhase = ''
32     ${python.interpreter} -m django test --settings tests.settings
33   '';
35   meta = with lib; {
36     description = "Requires login to all requests through middleware in Django";
37     homepage = "https://github.com/CleitonDeLima/django-login-required-middleware";
38     license = licenses.mit;
39     maintainers = with maintainers; [ onny ];
40   };