From 0dfad7d5dffe371aeb5e339e5e6011aaffbf3b27 Mon Sep 17 00:00:00 2001 From: Jamie Magee Date: Tue, 29 Dec 2020 19:35:15 +0100 Subject: [PATCH 1/2] pythonPackages.agent-py: init at 0.0.23 --- .../python-modules/agent-py/default.nix | 26 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 28 insertions(+) create mode 100644 pkgs/development/python-modules/agent-py/default.nix diff --git a/pkgs/development/python-modules/agent-py/default.nix b/pkgs/development/python-modules/agent-py/default.nix new file mode 100644 index 000000000000..2a9e358cf043 --- /dev/null +++ b/pkgs/development/python-modules/agent-py/default.nix @@ -0,0 +1,26 @@ +{ aiohttp, buildPythonPackage, fetchPypi, isPy3k, lib, python, requests }: + +buildPythonPackage rec { + pname = "agent-py"; + version = "0.0.23"; + + disabled = !isPy3k; + + src = fetchPypi { + inherit pname version; + sha256 = "1hx88m8b8kfb2gm6hii5ldjv7hlvqf99cz0w2vj0d0grrxcbn5cz"; + }; + + propagatedBuildInputs = [ requests aiohttp ]; + + checkPhase = '' + ${python.interpreter} tests/test_agent.py + ''; + + meta = with lib; { + description = "A python wrapper around the Agent REST API."; + homepage = "https://github.com/ispysoftware/agent-py"; + license = licenses.asl20; + maintainers = with maintainers; [ jamiemagee ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 80f5f6cab1c3..81d8ed0b96e4 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -187,6 +187,8 @@ in { agate-sql = callPackage ../development/python-modules/agate-sql { }; + agent-py = callPackage ../development/python-modules/agent-py { }; + aioamqp = callPackage ../development/python-modules/aioamqp { }; aioconsole = callPackage ../development/python-modules/aioconsole { }; From c493ab12c0fe63dc0e530d524df8445dccc34a77 Mon Sep 17 00:00:00 2001 From: Jamie Magee Date: Tue, 29 Dec 2020 19:47:06 +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 9135ea549f34..22712cd7f83f 100644 --- a/pkgs/servers/home-assistant/component-packages.nix +++ b/pkgs/servers/home-assistant/component-packages.nix @@ -13,7 +13,7 @@ "ads" = ps: with ps; [ pyads ]; "advantage_air" = ps: with ps; [ ]; # missing inputs: advantage_air "aftership" = ps: with ps; [ pyaftership ]; - "agent_dvr" = ps: with ps; [ ]; # missing inputs: agent-py + "agent_dvr" = ps: with ps; [ agent-py ]; "air_quality" = ps: with ps; [ ]; "airly" = ps: with ps; [ ]; # missing inputs: airly "airvisual" = ps: with ps; [ pyairvisual ];