about summary refs log tree commit diff
path: root/pkgs/development/python-modules/python-miio
diff options
context:
space:
mode:
authorFlorian Pester <florian.pester@cyberus-technology.de>2020-10-30 21:30:32 +0100
committerFlorian Pester <florian.pester@cyberus-technology.de>2020-10-30 21:41:47 +0100
commit79e81e840415651f4470942f86f19c3fd254efab (patch)
tree61a2d102be1585fd423ed32578eb70b302bde6fd /pkgs/development/python-modules/python-miio
parent3a12f8588a3ceb52169d2bf491b5ad47730ac0d3 (diff)
downloadnixlib-79e81e840415651f4470942f86f19c3fd254efab.tar
nixlib-79e81e840415651f4470942f86f19c3fd254efab.tar.gz
nixlib-79e81e840415651f4470942f86f19c3fd254efab.tar.bz2
nixlib-79e81e840415651f4470942f86f19c3fd254efab.tar.lz
nixlib-79e81e840415651f4470942f86f19c3fd254efab.tar.xz
nixlib-79e81e840415651f4470942f86f19c3fd254efab.tar.zst
nixlib-79e81e840415651f4470942f86f19c3fd254efab.zip
python-miio: fix
Diffstat (limited to 'pkgs/development/python-modules/python-miio')
-rw-r--r--pkgs/development/python-modules/python-miio/default.nix17
1 files changed, 15 insertions, 2 deletions
diff --git a/pkgs/development/python-modules/python-miio/default.nix b/pkgs/development/python-modules/python-miio/default.nix
index abce18c8841a..6bd140ae5b4c 100644
--- a/pkgs/development/python-modules/python-miio/default.nix
+++ b/pkgs/development/python-modules/python-miio/default.nix
@@ -4,8 +4,11 @@
 , appdirs
 , click
 , construct
+, croniter
 , cryptography
+, importlib-metadata
 , pytest
+, pytest-mock
 , zeroconf
 , attrs
 , pytz
@@ -13,6 +16,7 @@
 , netifaces
 }:
 
+
 buildPythonPackage rec {
   pname = "python-miio";
   version = "0.5.3";
@@ -22,8 +26,17 @@ buildPythonPackage rec {
     sha256 = "3be5275b569844dfa267c80a1e23dc0957411dd501cae0ed3cccf43467031ceb";
   };
 
-  checkInputs = [ pytest ];
-  propagatedBuildInputs = [ appdirs click construct cryptography zeroconf attrs pytz tqdm netifaces ];
+  postPatch = ''
+    substituteInPlace setup.py \
+      --replace  "zeroconf>=0.25.1,<0.26.0" "zeroconf"
+    substituteInPlace setup.py \
+      --replace  "pytz>=2019.3,<2020.0" "pytz"
+    substituteInPlace setup.py \
+      --replace  "cryptography>=2.9,<3.0" "cryptography"
+    '';
+
+  checkInputs = [ pytest pytest-mock];
+  propagatedBuildInputs = [ appdirs click construct croniter cryptography importlib-metadata zeroconf attrs pytz tqdm netifaces ];
 
   checkPhase = ''
     pytest