From d8305b6539314b1e3d29cbb8f5445025c2e58844 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Mon, 1 Mar 2021 19:17:54 +0100 Subject: [PATCH 1/2] python3Packages.pyvicare: init at 0.2.5 --- .../python-modules/pyvicare/default.nix | 35 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 37 insertions(+) create mode 100644 pkgs/development/python-modules/pyvicare/default.nix diff --git a/pkgs/development/python-modules/pyvicare/default.nix b/pkgs/development/python-modules/pyvicare/default.nix new file mode 100644 index 000000000000..7c87431d80b3 --- /dev/null +++ b/pkgs/development/python-modules/pyvicare/default.nix @@ -0,0 +1,35 @@ +{ lib +, buildPythonPackage +, fetchPypi +, pythonOlder +, requests_oauthlib +, simplejson +}: + +buildPythonPackage rec { + pname = "pyvicare"; + version = "0.2.5"; + disabled = pythonOlder "3.7"; + + src = fetchPypi { + pname = "PyViCare"; + inherit version; + sha256 = "16wqqjs238ad6znlz2gjadqj8891226bd02a1106xyz6vbbk2gdk"; + }; + + propagatedBuildInputs = [ + requests_oauthlib + simplejson + ]; + + # The published tarball on PyPI is incomplete and there are GitHub releases + doCheck = false; + pythonImportsCheck = [ "PyViCare" ]; + + meta = with lib; { + description = "Python Library to access Viessmann ViCare API"; + homepage = "https://github.com/somm15/PyViCare"; + license = with licenses; [ asl20 ]; + maintainers = with maintainers; [ fab ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 205813ddb1c5..1c6a6e8ec4c3 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -6624,6 +6624,8 @@ in { pyvex = callPackage ../development/python-modules/pyvex { }; + pyvicare = callPackage ../development/python-modules/pyvicare { }; + pyviz-comms = callPackage ../development/python-modules/pyviz-comms { }; pyvizio = callPackage ../development/python-modules/pyvizio { }; From 90bda5dde7136ac1785677099516ba4b174b5bfd Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Mon, 1 Mar 2021 19:18:22 +0100 Subject: [PATCH 2/2] home-assistant: update 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 2836f8a64e3b..5a1209750394 100644 --- a/pkgs/servers/home-assistant/component-packages.nix +++ b/pkgs/servers/home-assistant/component-packages.nix @@ -903,7 +903,7 @@ "version" = ps: with ps; [ pyhaversion ]; "vesync" = ps: with ps; [ pyvesync ]; "viaggiatreno" = ps: with ps; [ ]; - "vicare" = ps: with ps; [ ]; # missing inputs: PyViCare + "vicare" = ps: with ps; [ pyvicare ]; "vilfo" = ps: with ps; [ ]; # missing inputs: vilfo-api-client "vivotek" = ps: with ps; [ ]; # missing inputs: libpyvivotek "vizio" = ps: with ps; [ pyvizio ];