From c026f0992f25e352346f467e813bd78f2d96a1eb Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sat, 16 Jan 2021 14:28:50 +0100 Subject: [PATCH 1/2] python3Packages.hatasmota: init at 0.2.5 --- .../python-modules/hatasmota/default.nix | 34 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 36 insertions(+) create mode 100644 pkgs/development/python-modules/hatasmota/default.nix diff --git a/pkgs/development/python-modules/hatasmota/default.nix b/pkgs/development/python-modules/hatasmota/default.nix new file mode 100644 index 00000000000..91693343457 --- /dev/null +++ b/pkgs/development/python-modules/hatasmota/default.nix @@ -0,0 +1,34 @@ +{ lib +, attrs +, buildPythonPackage +, fetchFromGitHub +, voluptuous +}: + +buildPythonPackage rec { + pname = "hatasmota"; + version = "0.2.5"; + + src = fetchFromGitHub { + owner = "emontnemery"; + repo = pname; + rev = version; + sha256 = "1xsqrpd0dprjfaa2yrdy1g9n4xyrw6ifnzkrh3sq5fx0yfmxbzqm"; + }; + + propagatedBuildInputs = [ + attrs + voluptuous + ]; + + # Project has no tests + doCheck = false; + pythonImportsCheck = [ "hatasmota" ]; + + meta = with lib; { + description = "Python module to help parse and construct Tasmota MQTT messages"; + homepage = "https://github.com/emontnemery/hatasmota"; + 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 cb786ff781e..9e869a1bd7b 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -2818,6 +2818,8 @@ in { hass-nabucasa = callPackage ../development/python-modules/hass-nabucasa { }; + hatasmota = callPackage ../development/python-modules/hatasmota { }; + hawkauthlib = callPackage ../development/python-modules/hawkauthlib { }; hbmqtt = callPackage ../development/python-modules/hbmqtt { }; From 51a0f49e040316749e39946df143ebd6e1f264f8 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sat, 16 Jan 2021 14:29:42 +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 861b53765ba..cd8b4011074 100644 --- a/pkgs/servers/home-assistant/component-packages.nix +++ b/pkgs/servers/home-assistant/component-packages.nix @@ -816,7 +816,7 @@ "tank_utility" = ps: with ps; [ ]; # missing inputs: tank_utility "tankerkoenig" = ps: with ps; [ ]; # missing inputs: pytankerkoenig "tapsaff" = ps: with ps; [ ]; # missing inputs: tapsaff - "tasmota" = ps: with ps; [ aiohttp-cors paho-mqtt ]; # missing inputs: hatasmota + "tasmota" = ps: with ps; [ aiohttp-cors hatasmota paho-mqtt ]; "tautulli" = ps: with ps; [ ]; # missing inputs: pytautulli "tcp" = ps: with ps; [ ]; "ted5000" = ps: with ps; [ xmltodict ];