depot/third_party/nixpkgs/pkgs/development/python-modules/django-simple-captcha/default.nix
Default email 9c6ee729d6 Project import generated by Copybara.
GitOrigin-RevId: 6cee3b5893090b0f5f0a06b4cf42ca4e60e5d222
2023-07-15 19:15:38 +02:00

44 lines
957 B
Nix

{ lib
, buildPythonPackage
, fetchPypi
, python
, testfixtures
, django
, django-ranged-response
, pillow
, withTTS ? true
, flite
}:
buildPythonPackage rec {
pname = "django-simple-captcha";
version = "0.5.18";
src = fetchPypi {
inherit pname version;
hash = "sha256-bh/MT0AF99ae56Llmn6GO105GPNqhaTYEUmJhK7MSM4=";
};
nativeCheckInputs = [
testfixtures
];
checkPhase = ''
cd testproject
${python.interpreter} manage.py test captcha
'';
propagatedBuildInputs = [
django
django-ranged-response
pillow
] ++ lib.optional withTTS flite;
meta = with lib; {
description = "Customizable Django application to add captcha images to any Django form";
homepage = "https://github.com/mbi/django-simple-captcha";
changelog = "https://github.com/mbi/django-simple-captcha/blob/v${version}/CHANGES";
license = licenses.mit;
maintainers = with maintainers; [ mrmebelman schmittlauch ];
};
}