depot/third_party/nixpkgs/pkgs/development/python-modules/django-cryptography/default.nix
Default email bcb2f287e1 Project import generated by Copybara.
GitOrigin-RevId: d603719ec6e294f034936c0d0dc06f689d91b6c3
2024-06-20 20:27:18 +05:30

53 lines
1.1 KiB
Nix

{
buildPythonPackage,
cryptography,
django,
django-appconf,
fetchFromGitHub,
lib,
python,
pythonOlder,
setuptools,
}:
buildPythonPackage rec {
pname = "django-cryptography";
version = "1.1";
disabled = pythonOlder "3.7";
format = "pyproject";
src = fetchFromGitHub {
owner = "georgemarshall";
repo = "django-cryptography";
rev = "refs/tags/${version}";
hash = "sha256-C3E2iT9JdLvF+1g+xhZ8dPDjjh25JUxLAtTMnalIxPk=";
};
nativeBuildInputs = [ setuptools ];
propagatedBuildInputs = [
cryptography
django
django-appconf
];
patches = [
# See: https://github.com/georgemarshall/django-cryptography/pull/88
./fix-setup-cfg.patch
];
pythonImportsCheck = [ "django_cryptography" ];
checkPhase = ''
runHook preCheck
${python.interpreter} ./runtests.py
runHook postCheck
'';
meta = with lib; {
homepage = "https://github.com/georgemarshall/django-cryptography";
description = "Set of primitives for performing cryptography in Django";
license = licenses.bsd3;
maintainers = with maintainers; [ centromere ];
};
}