depot/third_party/nixpkgs/pkgs/development/python-modules/email-validator/default.nix
Default email e7ec2969af Project import generated by Copybara.
GitOrigin-RevId: 9b19f5e77dd906cb52dade0b7bd280339d2a1f3d
2024-01-13 09:15:51 +01:00

50 lines
1.1 KiB
Nix

{ lib
, buildPythonPackage
, dnspython
, fetchFromGitHub
, idna
, pytestCheckHook
, pythonOlder
}:
buildPythonPackage rec {
pname = "email-validator";
version = "2.1.0";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "JoshData";
repo = "python-${pname}";
rev = "refs/tags/v${version}";
hash = "sha256-58DuQslADM7glrnlSSP6TtIDTlwuS0/GK8+izatqDxI=";
};
propagatedBuildInputs = [
dnspython
idna
];
nativeCheckInputs = [
pytestCheckHook
];
disabledTestPaths = [
# dns.resolver.NoResolverConfiguration: cannot open /etc/resolv.conf
"tests/test_deliverability.py"
"tests/test_main.py"
];
pythonImportsCheck = [
"email_validator"
];
meta = with lib; {
description = "Email syntax and deliverability validation library";
homepage = "https://github.com/JoshData/python-email-validator";
changelog = "https://github.com/JoshData/python-email-validator/releases/tag/v${version}";
license = licenses.cc0;
maintainers = with maintainers; [ siddharthist ];
};
}