From 779662af30293df050e7ea7403611a6babaae073 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Mon, 4 Jan 2021 14:29:35 +0100 Subject: [PATCH 1/2] python3Packages.python-whois: init at 0.7.3 --- .../python-modules/python-whois/default.nix | 41 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 43 insertions(+) create mode 100644 pkgs/development/python-modules/python-whois/default.nix diff --git a/pkgs/development/python-modules/python-whois/default.nix b/pkgs/development/python-modules/python-whois/default.nix new file mode 100644 index 000000000000..c4d163100ca9 --- /dev/null +++ b/pkgs/development/python-modules/python-whois/default.nix @@ -0,0 +1,41 @@ +{ lib +, buildPythonPackage +, fetchPypi +, future +, nose +, pytestCheckHook +, simplejson +}: + +buildPythonPackage rec { + pname = "python-whois"; + version = "0.7.3"; + + src = fetchPypi { + inherit pname version; + sha256 = "05jaxbnlw5wck0hl124py364jqrx7a4mmv0hy3d2jzvmp0012sk5"; + }; + + propagatedBuildInputs = [ future ]; + + checkInputs = [ + nose + pytestCheckHook + simplejson + ]; + + # Exclude tests that require network access + disabledTests = [ + "test_dk_parse" + "test_ipv4" + "test_ipv6" + ]; + pythonImportsCheck = [ "whois" ]; + + meta = with lib; { + description = "Python module to produce parsed WHOIS data"; + homepage = "https://github.com/richardpenman/whois"; + license = with licenses; [ mit ]; + maintainers = with maintainers; [ fab ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index cfb9ac52ccb1..c91cbc93214b 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -6147,6 +6147,8 @@ in { python-vlc = callPackage ../development/python-modules/python-vlc { }; + python-whois = callPackage ../development/python-modules/python-whois { }; + python-wifi = callPackage ../development/python-modules/python-wifi { }; python-xmp-toolkit = callPackage ../development/python-modules/python-xmp-toolkit { }; From d8f10e326f0245ad5d86ce937becfce422fb537c Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Mon, 4 Jan 2021 14:30:01 +0100 Subject: [PATCH 2/2] home-assistant: add python-whois to component-packages --- pkgs/servers/home-assistant/component-packages.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/servers/home-assistant/component-packages.nix b/pkgs/servers/home-assistant/component-packages.nix index 9b3b6e662b91..855e52cdbd84 100644 --- a/pkgs/servers/home-assistant/component-packages.nix +++ b/pkgs/servers/home-assistant/component-packages.nix @@ -925,7 +925,7 @@ "webostv" = ps: with ps; [ ]; # missing inputs: aiopylgtv "websocket_api" = ps: with ps; [ aiohttp-cors ]; "wemo" = ps: with ps; [ ]; # missing inputs: pywemo - "whois" = ps: with ps; [ ]; # missing inputs: python-whois + "whois" = ps: with ps; [ python-whois ]; "wiffi" = ps: with ps; [ ]; # missing inputs: wiffi "wilight" = ps: with ps; [ ]; # missing inputs: pywilight "wink" = ps: with ps; [ aiohttp-cors ]; # missing inputs: pubnubsub-handler python-wink