From 554cd39334159def25a046100c891ca5fb648674 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Fri, 3 Mar 2023 01:05:20 +0100 Subject: [PATCH 1/2] python310Packages.py-dormakaba-dkey: init at 1.0.4 --- .../py-dormakaba-dkey/default.nix | 49 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 51 insertions(+) create mode 100644 pkgs/development/python-modules/py-dormakaba-dkey/default.nix diff --git a/pkgs/development/python-modules/py-dormakaba-dkey/default.nix b/pkgs/development/python-modules/py-dormakaba-dkey/default.nix new file mode 100644 index 000000000000..6c70ad8861c7 --- /dev/null +++ b/pkgs/development/python-modules/py-dormakaba-dkey/default.nix @@ -0,0 +1,49 @@ +{ lib +, bleak +, bleak-retry-connector +, buildPythonPackage +, cryptography +, fetchFromGitHub +, pythonOlder +, setuptools +}: + +buildPythonPackage rec { + pname = "py-dormakaba-dkey"; + version = "1.0.4"; + format = "pyproject"; + + disabled = pythonOlder "3.10"; + + src = fetchFromGitHub { + owner = "emontnemery"; + repo = pname; + rev = "refs/tags/${version}"; + hash = "sha256-1jIsKQa27XNVievU02jjanRWFtJDYsHolgPBab6qpM0="; + }; + + nativeBuildInputs = [ + setuptools + ]; + + propagatedBuildInputs = [ + bleak + bleak-retry-connector + cryptography + ]; + + # Module has no tests + doCheck = false; + + pythonImportsCheck = [ + "py_dormakaba_dkey" + ]; + + meta = with lib; { + description = "Library to interact with a Dormakaba dkey lock"; + homepage = "https://github.com/emontnemery/py-dormakaba-dkey"; + changelog = "https://github.com/emontnemery/py-dormakaba-dkey/releases/tag/${version}"; + license = licenses.mit; + maintainers = with maintainers; [ fab ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index e63ad2a6fe9e..bfc540b317fb 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -7743,6 +7743,8 @@ self: super: with self; { py-dmidecode = callPackage ../development/python-modules/py-dmidecode { }; + py-dormakaba-dkey = callPackage ../development/python-modules/py-dormakaba-dkey { }; + py-nightscout = callPackage ../development/python-modules/py-nightscout { }; py-synologydsm-api = callPackage ../development/python-modules/py-synologydsm-api { }; From 7d18bbcb7ccb11d75d9b4c7ecf266dd266d805f8 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Fri, 3 Mar 2023 01:06:42 +0100 Subject: [PATCH 2/2] home-assistant: update component-packages --- pkgs/servers/home-assistant/component-packages.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/servers/home-assistant/component-packages.nix b/pkgs/servers/home-assistant/component-packages.nix index 6111c357490e..96f3cf7d8c5d 100644 --- a/pkgs/servers/home-assistant/component-packages.nix +++ b/pkgs/servers/home-assistant/component-packages.nix @@ -804,11 +804,12 @@ esphome-dashboard-api fnvhash ifaddr + py-dormakaba-dkey pyserial pyudev sqlalchemy zeroconf - ]; # missing inputs: py-dormakaba-dkey + ]; "dovado" = ps: with ps; [ ]; # missing inputs: dovado "downloader" = ps: with ps; [ @@ -4453,6 +4454,7 @@ "dlna_dms" "dnsip" "doorbird" + "dormakaba_dkey" "dsmr" "dsmr_reader" "dte_energy_bridge"