From 1f8b8f4707cef19ea4f356651652b8dbe47b02d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Tue, 27 Aug 2024 13:33:47 -0700 Subject: [PATCH 1/3] python312Packages.idasen: modernize --- pkgs/development/python-modules/idasen/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/idasen/default.nix b/pkgs/development/python-modules/idasen/default.nix index 61bbdefce2f5..8f1c36006f93 100644 --- a/pkgs/development/python-modules/idasen/default.nix +++ b/pkgs/development/python-modules/idasen/default.nix @@ -14,7 +14,7 @@ buildPythonPackage rec { pname = "idasen"; version = "0.12.0"; - format = "pyproject"; + pyproject = true; disabled = pythonOlder "3.8"; @@ -25,9 +25,9 @@ buildPythonPackage rec { hash = "sha256-TQ+DBFpG+IeZ4/dN+YKMw3AM4Dl1rpqA1kRcb3Tb3jA="; }; - nativeBuildInputs = [ poetry-core ]; + build-system = [ poetry-core ]; - propagatedBuildInputs = [ + dependencies = [ bleak pyyaml voluptuous From 5c82f4d9355d4e900595aded155bd404b1f8d27e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Tue, 27 Aug 2024 13:29:49 -0700 Subject: [PATCH 2/3] python312Packages.idasen-ha: init at 2.6.2 --- .../python-modules/idasen-ha/default.nix | 41 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 43 insertions(+) create mode 100644 pkgs/development/python-modules/idasen-ha/default.nix diff --git a/pkgs/development/python-modules/idasen-ha/default.nix b/pkgs/development/python-modules/idasen-ha/default.nix new file mode 100644 index 000000000000..2c93133cf6ad --- /dev/null +++ b/pkgs/development/python-modules/idasen-ha/default.nix @@ -0,0 +1,41 @@ +{ + buildPythonPackage, + fetchFromGitHub, + idasen, + lib, + pytest-asyncio, + pytestCheckHook, + setuptools, +}: + +buildPythonPackage rec { + pname = "idasen-ha"; + version = "2.6.2"; + pyproject = true; + + src = fetchFromGitHub { + owner = "abmantis"; + repo = "idasen-ha"; + rev = "refs/tags/${version}"; + hash = "sha256-lqqSx4jxQVq2pjVv9lvaX6nNK6OqtMjPqOtLMLpVMUU="; + }; + + build-system = [ setuptools ]; + + dependencies = [ idasen ]; + + pythonImportsCheck = [ "idasen_ha" ]; + + nativeCheckInputs = [ + pytest-asyncio + pytestCheckHook + ]; + + meta = { + changelog = "https://github.com/abmantis/idasen-ha/releases/tag/${version}"; + description = "Home Assistant helper lib for the IKEA Idasen Desk integration"; + homepage = "https://github.com/abmantis/idasen-ha"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ dotlambda ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index adf16544281c..dc8e53b991b7 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5884,6 +5884,8 @@ self: super: with self; { idasen = callPackage ../development/python-modules/idasen { }; + idasen-ha = callPackage ../development/python-modules/idasen-ha { }; + icoextract = toPythonModule (pkgs.icoextract.override { python3Packages = self; }); From 8402c31159e9fb8d3862f7efc32799fc33d48482 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Tue, 27 Aug 2024 13:31:49 -0700 Subject: [PATCH 3/3] home-assistant: support idasen_desk component --- 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 e1a845ce6a1f..47719ef1fc40 100644 --- a/pkgs/servers/home-assistant/component-packages.nix +++ b/pkgs/servers/home-assistant/component-packages.nix @@ -1821,13 +1821,14 @@ habluetooth hassil home-assistant-intents + idasen-ha ifaddr mutagen pymicro-vad pyserial pyudev zeroconf - ]; # missing inputs: idasen-ha + ]; "idteck_prox" = ps: with ps; [ ]; # missing inputs: rfk101py "ifttt" = ps: with ps; [ @@ -5164,6 +5165,7 @@ "iaqualink" "ibeacon" "icloud" + "idasen_desk" "ifttt" "ign_sismologia" "image"