summary refs log tree commit diff
diff options
context:
space:
mode:
authorFabian Affolter <mail@fabian-affolter.ch>2021-01-01 22:10:24 +0100
committerFabian Affolter <mail@fabian-affolter.ch>2021-01-01 22:10:24 +0100
commite57af5de02f58a967b96f54f88c32ffed762f837 (patch)
tree97f04a26e7784e5ae9034c4ef1a9b50d1b8bb2ad
parentd4a76b1f5fb48896a3348c394196e7552e3eb9ef (diff)
downloadnixpkgs-e57af5de02f58a967b96f54f88c32ffed762f837.tar
nixpkgs-e57af5de02f58a967b96f54f88c32ffed762f837.tar.gz
nixpkgs-e57af5de02f58a967b96f54f88c32ffed762f837.tar.bz2
nixpkgs-e57af5de02f58a967b96f54f88c32ffed762f837.tar.lz
nixpkgs-e57af5de02f58a967b96f54f88c32ffed762f837.tar.xz
nixpkgs-e57af5de02f58a967b96f54f88c32ffed762f837.tar.zst
nixpkgs-e57af5de02f58a967b96f54f88c32ffed762f837.zip
python3Packages.connect-box: init at 0.2.8
-rw-r--r--pkgs/development/python-modules/connect_box/default.nix42
-rw-r--r--pkgs/servers/home-assistant/component-packages.nix2
-rw-r--r--pkgs/top-level/python-packages.nix2
3 files changed, 45 insertions, 1 deletions
diff --git a/pkgs/development/python-modules/connect_box/default.nix b/pkgs/development/python-modules/connect_box/default.nix
new file mode 100644
index 00000000000..6c92ac025d8
--- /dev/null
+++ b/pkgs/development/python-modules/connect_box/default.nix
@@ -0,0 +1,42 @@
+{ lib
+, buildPythonPackage
+, fetchPypi
+, aiohttp
+, attrs
+, defusedxml
+}:
+
+buildPythonPackage rec {
+  pname = "connect-box";
+  version = "0.2.8";
+
+  src = fetchPypi {
+    pname = "connect_box";
+    inherit version;
+    sha256 = "1lvz7g2f0a9ifnjczmbavn105miirdgyayr4sixhzgdgadcdhz3l";
+  };
+
+  propagatedBuildInputs = [
+    aiohttp
+    attrs
+    defusedxml
+  ];
+
+  # no tests are present
+  doCheck = false;
+
+  pythonImportsCheck = [ "connect_box" ];
+
+  meta = with lib; {
+    description = "Interact with a Compal CH7465LG cable modem/router";
+    longDescription = ''
+      Python Client for interacting with the cable modem/router Compal
+      CH7465LG which is provided under different names by various ISP
+      in Europe, e.g., UPC Connect Box (CH), Irish Virgin Media Super
+      Hub 3.0 (IE), Ziggo Connectbox (NL) or Unitymedia Connect Box (DE).
+    '';
+    homepage = "https://github.com/home-assistant-ecosystem/python-connect-box";
+    license = with licenses; [ mit ];
+    maintainers = with maintainers; [ fab ];
+  };
+}
diff --git a/pkgs/servers/home-assistant/component-packages.nix b/pkgs/servers/home-assistant/component-packages.nix
index 93595c5729f..fbd39a5e7c4 100644
--- a/pkgs/servers/home-assistant/component-packages.nix
+++ b/pkgs/servers/home-assistant/component-packages.nix
@@ -879,7 +879,7 @@
     "unifiled" = ps: with ps; [ ]; # missing inputs: unifiled
     "universal" = ps: with ps; [ ];
     "upb" = ps: with ps; [ ]; # missing inputs: upb_lib
-    "upc_connect" = ps: with ps; [ ]; # missing inputs: connect-box
+    "upc_connect" = ps: with ps; [ connect-box ];
     "upcloud" = ps: with ps; [ ]; # missing inputs: upcloud-api
     "updater" = ps: with ps; [ distro ];
     "upnp" = ps: with ps; [ async-upnp-client ];
diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix
index 57458230bb1..5273ee3155c 100644
--- a/pkgs/top-level/python-packages.nix
+++ b/pkgs/top-level/python-packages.nix
@@ -1116,6 +1116,8 @@ in {
 
   cement = callPackage ../development/python-modules/cement { };
 
+  connect-box = callPackage ../development/python-modules/connect_box { };
+
   cerberus = callPackage ../development/python-modules/cerberus { };
 
   certbot = callPackage ../development/python-modules/certbot { };