From 61d056d212b22b985e06b4212a45fb8f40afa302 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Sun, 5 Jun 2022 21:45:58 +0200 Subject: [PATCH] python3Packages.hyperion-py: fix python3.10 support --- .../python-modules/hyperion-py/default.nix | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/hyperion-py/default.nix b/pkgs/development/python-modules/hyperion-py/default.nix index 7837deea6dba..ed57ad767b07 100644 --- a/pkgs/development/python-modules/hyperion-py/default.nix +++ b/pkgs/development/python-modules/hyperion-py/default.nix @@ -2,6 +2,7 @@ , aiohttp , buildPythonPackage , fetchFromGitHub +, fetchpatch , pytestCheckHook , pythonOlder , pythonAtLeast @@ -13,7 +14,7 @@ buildPythonPackage rec { pname = "hyperion-py"; version = "0.7.5"; - disabled = pythonOlder "3.8" || pythonAtLeast "3.10"; + disabled = pythonOlder "3.8"; format = "pyproject"; src = fetchFromGitHub { @@ -23,6 +24,14 @@ buildPythonPackage rec { sha256 = "sha256-arcnpCQsRuiWCrAz/t4TCjTe8DRDtRuzYp8k7nnjGDk="; }; + patches = [ + (fetchpatch { + # python3.10 compat: Drop loop kwarg in asyncio.sleep call + url = "https://github.com/dermotduffy/hyperion-py/commit/f02af52fcce17888984c99bfc03935e372011394.patch"; + hash = "sha256-4nfsQVxd77VV9INwNxTyFRDlAjwdTYqfSGuF487hFCs="; + }) + ]; + nativeBuildInputs = [ poetry-core ];