2024-04-21 15:54:59 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchPypi,
|
|
|
|
setuptools,
|
|
|
|
pythonOlder,
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "publicsuffix";
|
|
|
|
version = "1.1.1";
|
2024-04-21 15:54:59 +00:00
|
|
|
pyproject = true;
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2024-04-21 15:54:59 +00:00
|
|
|
hash = "sha256-Is4dZatq9emyEi4kQ/rNuT+1xKvyQTgJnLEP55ifQ7Y=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
# disable test_fetch and the doctests (which also invoke fetch)
|
|
|
|
postPatch = ''
|
|
|
|
sed -i -e "/def test_fetch/i\\
|
|
|
|
\\t@unittest.skip('requires internet')" -e "/def additional_tests():/,+1d" tests.py
|
|
|
|
'';
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
build-system = [ setuptools ];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "publicsuffix" ];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Allows to get the public suffix of a domain name";
|
|
|
|
homepage = "https://pypi.python.org/pypi/publicsuffix/";
|
|
|
|
license = licenses.mit;
|
2024-07-31 10:19:44 +00:00
|
|
|
maintainers = [ ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|