From 266a1baa49cddce934bc6baaa6c0edb0a632615d Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 11 Apr 2021 12:52:34 +0200 Subject: [PATCH 1/3] python3Packages.pycomfoconnect: init at 0.4 --- .../python-modules/pycomfoconnect/default.nix | 34 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 36 insertions(+) create mode 100644 pkgs/development/python-modules/pycomfoconnect/default.nix diff --git a/pkgs/development/python-modules/pycomfoconnect/default.nix b/pkgs/development/python-modules/pycomfoconnect/default.nix new file mode 100644 index 00000000000..cb40ec8f527 --- /dev/null +++ b/pkgs/development/python-modules/pycomfoconnect/default.nix @@ -0,0 +1,34 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, protobuf +, pytestCheckHook +}: + +buildPythonPackage rec { + pname = "pycomfoconnect"; + version = "0.4"; + + src = fetchFromGitHub { + owner = "michaelarnauts"; + repo = "comfoconnect"; + rev = version; + sha256 = "0bipzv68yw056iz9m2g9h40hzrwd058a7crxp0xbq4rw2d8j0jn6"; + }; + + propagatedBuildInputs = [ + protobuf + ]; + + # Project has no tests + doCheck = false; + + pythonImportsCheck = [ "pycomfoconnect" ]; + + meta = with lib; { + description = "Python module to interact with ComfoAir Q350/450/600 units"; + homepage = "https://github.com/michaelarnauts/comfoconnect"; + 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 68832d87e9b..54bf55d1a31 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5621,6 +5621,8 @@ in { pycollada = callPackage ../development/python-modules/pycollada { }; + pycomfoconnect = callPackage ../development/python-modules/pycomfoconnect { }; + pycontracts = callPackage ../development/python-modules/pycontracts { }; pycosat = callPackage ../development/python-modules/pycosat { }; From f87c12b6890ba1be555d8da799c737bd13950207 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 11 Apr 2021 12:54:09 +0200 Subject: [PATCH 2/3] 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 0a801fa2c2f..9ccc4e45be2 100644 --- a/pkgs/servers/home-assistant/component-packages.nix +++ b/pkgs/servers/home-assistant/component-packages.nix @@ -131,7 +131,7 @@ "coinbase" = ps: with ps; [ ]; # missing inputs: coinbase "color_extractor" = ps: with ps; [ ]; # missing inputs: colorthief "comed_hourly_pricing" = ps: with ps; [ ]; - "comfoconnect" = ps: with ps; [ ]; # missing inputs: pycomfoconnect + "comfoconnect" = ps: with ps; [ pycomfoconnect ]; "command_line" = ps: with ps; [ ]; "concord232" = ps: with ps; [ ]; # missing inputs: concord232 "config" = ps: with ps; [ aiohttp-cors ]; From e9a0be7040e74080f9931b2fcc3f6fb560256417 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 11 Apr 2021 13:02:33 +0200 Subject: [PATCH 3/3] home-assistant: enable comfoconnect tests --- pkgs/servers/home-assistant/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/servers/home-assistant/default.nix b/pkgs/servers/home-assistant/default.nix index e0f7db7a577..d02cc41ea28 100644 --- a/pkgs/servers/home-assistant/default.nix +++ b/pkgs/servers/home-assistant/default.nix @@ -197,6 +197,7 @@ in with py.pkgs; buildPythonApplication rec { "cast" "climate" "cloud" + "comfoconnect" "command_line" "config" "configurator"