2021-01-04 13:27:00 +00:00
|
|
|
{ lib
|
2021-02-13 22:52:06 +00:00
|
|
|
, aiodns
|
|
|
|
, asynctest
|
2021-01-04 13:27:00 +00:00
|
|
|
, buildPythonPackage
|
2021-02-13 22:52:06 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, pytestCheckHook
|
2021-01-04 13:27:00 +00:00
|
|
|
, pythonOlder
|
|
|
|
, tldextract
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "asyncwhois";
|
2021-06-19 01:34:32 +00:00
|
|
|
version = "0.3.2";
|
2021-02-13 22:52:06 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
2021-01-04 13:27:00 +00:00
|
|
|
|
2021-02-13 22:52:06 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "pogzyb";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-06-19 01:34:32 +00:00
|
|
|
sha256 = "0cxmvxc82dxrg18kcc321hfmp877knl76pa6dpfhwphwfs2v02f1";
|
2021-01-04 13:27:00 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiodns
|
|
|
|
tldextract
|
|
|
|
];
|
|
|
|
|
2021-02-13 22:52:06 +00:00
|
|
|
checkInputs = [
|
|
|
|
asynctest
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
# Disable tests that require network access
|
|
|
|
disabledTests = [
|
|
|
|
"test_pywhois_aio_get_hostname_from_ip"
|
|
|
|
"test_pywhois_get_hostname_from_ip"
|
|
|
|
"test_pywhois_aio_lookup_ipv4"
|
|
|
|
"test_not_found"
|
|
|
|
"test_aio_from_whois_cmd"
|
|
|
|
"test_aio_get_hostname_from_ip"
|
|
|
|
"test_from_whois_cmd"
|
|
|
|
"test_get_hostname_from_ip"
|
|
|
|
"test_whois_query_run"
|
|
|
|
];
|
|
|
|
|
2021-01-04 13:27:00 +00:00
|
|
|
pythonImportsCheck = [ "asyncwhois" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python module for retrieving WHOIS information";
|
|
|
|
homepage = "https://github.com/pogzyb/asyncwhois";
|
|
|
|
license = with licenses; [ asl20 ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|