From 9eec624fa9dc4f58a5ad8a6113450554c7f36503 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Fri, 11 Feb 2022 14:33:40 +0100 Subject: [PATCH 1/2] python3Packages.pynetgear: init at 0.9.1 --- .../python-modules/pynetgear/default.nix | 40 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 42 insertions(+) create mode 100644 pkgs/development/python-modules/pynetgear/default.nix diff --git a/pkgs/development/python-modules/pynetgear/default.nix b/pkgs/development/python-modules/pynetgear/default.nix new file mode 100644 index 000000000000..e1d87cdcae33 --- /dev/null +++ b/pkgs/development/python-modules/pynetgear/default.nix @@ -0,0 +1,40 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, requests +, pythonOlder +}: + +buildPythonPackage rec { + pname = "pynetgear"; + version = "0.9.1"; + format = "setuptools"; + + disabled = pythonOlder "3.7"; + + src = fetchFromGitHub { + owner = "MatMaul"; + repo = pname; + rev = version; + sha256 = "sha256-sLGr8I0LcLPrmQZ6dI+hwRAiNCrnLtr2WU04rPoG4x4="; + }; + + propagatedBuildInputs = [ + requests + ]; + + pythonImportsCheck = [ + "pynetgear" + ]; + + # Tests don't pass + # https://github.com/MatMaul/pynetgear/issues/109 + doCheck = false; + + meta = with lib; { + description = "Module for interacting with Netgear wireless routers"; + homepage = "https://github.com/MatMaul/pynetgear"; + 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 dbf982ea7b9b..eba889916fd2 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -7206,6 +7206,8 @@ in { pynetdicom = callPackage ../development/python-modules/pynetdicom { }; + pynetgear = callPackage ../development/python-modules/pynetgear { }; + pynina = callPackage ../development/python-modules/pynina { }; pynisher = callPackage ../development/python-modules/pynisher { }; From e5dbdf3a8e7f38359b001670a13753c35f5936ee Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Fri, 11 Feb 2022 14:36:19 +0100 Subject: [PATCH 2/2] home-assistant: update component-packages --- pkgs/servers/home-assistant/component-packages.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/servers/home-assistant/component-packages.nix b/pkgs/servers/home-assistant/component-packages.nix index 8518f0350f18..1610a52d3ec3 100644 --- a/pkgs/servers/home-assistant/component-packages.nix +++ b/pkgs/servers/home-assistant/component-packages.nix @@ -569,7 +569,7 @@ "nest" = ps: with ps; [ aiohttp-cors google-nest-sdm ha-ffmpeg python-nest ]; "netatmo" = ps: with ps; [ pyturbojpeg aiohttp-cors hass-nabucasa pyatmo ]; "netdata" = ps: with ps; [ netdata ]; - "netgear" = ps: with ps; [ ]; # missing inputs: pynetgear + "netgear" = ps: with ps; [ pynetgear ]; "netgear_lte" = ps: with ps; [ eternalegypt ]; "netio" = ps: with ps; [ aiohttp-cors ]; # missing inputs: pynetio "network" = ps: with ps; [ aiohttp-cors ifaddr ]; @@ -1368,6 +1368,7 @@ "ness_alarm" "nest" "netatmo" + "netgear" "network" "nexia" "nightscout"