python3Packages.asyncwhois: 0.4.1 -> 1.0.0

This commit is contained in:
Fabian Affolter 2022-02-15 13:22:32 +01:00
parent c3a5c49429
commit 5aa283f01c

View File

@ -1,9 +1,9 @@
{ lib { lib
, aiodns
, asynctest , asynctest
, buildPythonPackage , buildPythonPackage
, fetchFromGitHub , fetchFromGitHub
, pytestCheckHook , pytestCheckHook
, python-socks
, pythonOlder , pythonOlder
, tldextract , tldextract
, whodap , whodap
@ -11,7 +11,8 @@
buildPythonPackage rec { buildPythonPackage rec {
pname = "asyncwhois"; pname = "asyncwhois";
version = "0.4.1"; version = "1.0.0";
format = "setuptools";
disabled = pythonOlder "3.7"; disabled = pythonOlder "3.7";
@ -19,11 +20,11 @@ buildPythonPackage rec {
owner = "pogzyb"; owner = "pogzyb";
repo = pname; repo = pname;
rev = "v${version}"; rev = "v${version}";
sha256 = "sha256-mKKN2IuveOE+3mZGS5LFa15lJPA9y7KgLd0FoRuEMH0="; hash = "sha256-9tSGfF/Ezuya4pEyr1XolWXvSO/F/UrobRVlyHITNTU=";
}; };
propagatedBuildInputs = [ propagatedBuildInputs = [
aiodns python-socks
tldextract tldextract
whodap whodap
]; ];
@ -33,8 +34,13 @@ buildPythonPackage rec {
pytestCheckHook pytestCheckHook
]; ];
# Disable tests that require network access postPatch = ''
substituteInPlace setup.py \
--replace "python-socks[asyncio]" "python-socks"
'';
disabledTests = [ disabledTests = [
# Tests require network access
"test_pywhois_aio_get_hostname_from_ip" "test_pywhois_aio_get_hostname_from_ip"
"test_pywhois_get_hostname_from_ip" "test_pywhois_get_hostname_from_ip"
"test_pywhois_aio_lookup_ipv4" "test_pywhois_aio_lookup_ipv4"
@ -44,9 +50,13 @@ buildPythonPackage rec {
"test_from_whois_cmd" "test_from_whois_cmd"
"test_get_hostname_from_ip" "test_get_hostname_from_ip"
"test_whois_query_run" "test_whois_query_run"
"test_whois_query_create_connection"
"test_whois_query_send_and_recv"
]; ];
pythonImportsCheck = [ "asyncwhois" ]; pythonImportsCheck = [
"asyncwhois"
];
meta = with lib; { meta = with lib; {
description = "Python module for retrieving WHOIS information"; description = "Python module for retrieving WHOIS information";