about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/aioambient/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/aioambient/default.nix')
-rw-r--r--nixpkgs/pkgs/development/python-modules/aioambient/default.nix21
1 files changed, 16 insertions, 5 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/aioambient/default.nix b/nixpkgs/pkgs/development/python-modules/aioambient/default.nix
index 3e5c0c8dfe89..2396b24f6d9f 100644
--- a/nixpkgs/pkgs/development/python-modules/aioambient/default.nix
+++ b/nixpkgs/pkgs/development/python-modules/aioambient/default.nix
@@ -16,17 +16,24 @@
 
 buildPythonPackage rec {
   pname = "aioambient";
-  version = "1.3.0";
+  version = "2021.12.0";
   format = "pyproject";
-  disabled = pythonOlder "3.6";
+
+  disabled = pythonOlder "3.7";
 
   src = fetchFromGitHub {
     owner = "bachya";
     repo = pname;
     rev = version;
-    sha256 = "sha256-blejTXyLe3B2kNytBh+zJz0Q0xDP+Vo2SV9gc7OX6S0=";
+    sha256 = "sha256-nFCLMpkuSVPecKrtJ/z7KuyGw4Z9X79wKXmWsewbxvY=";
   };
 
+  postPatch = ''
+    # https://github.com/bachya/aioambient/pull/97
+    substituteInPlace pyproject.toml \
+      --replace 'websockets = ">=8.1,<10.0"' 'websockets = ">=8.1,<11.0"'
+  '';
+
   nativeBuildInputs = [
     poetry-core
   ];
@@ -47,9 +54,13 @@ buildPythonPackage rec {
   ];
 
   # Ignore the examples directory as the files are prefixed with test_
-  disabledTestPaths = [ "examples/" ];
+  disabledTestPaths = [
+    "examples/"
+  ];
 
-  pythonImportsCheck = [ "aioambient" ];
+  pythonImportsCheck = [
+    "aioambient"
+  ];
 
   meta = with lib; {
     description = "Python library for the Ambient Weather API";