From e364d10db536eeef51a0d63a7570e251dc9d757d Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Sun, 4 Oct 2020 01:44:16 +0200 Subject: [PATCH] python3Packages.asyncio-throttle: init at 1.0.1 --- .../asyncio-throttle/default.nix | 34 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 36 insertions(+) create mode 100644 pkgs/development/python-modules/asyncio-throttle/default.nix diff --git a/pkgs/development/python-modules/asyncio-throttle/default.nix b/pkgs/development/python-modules/asyncio-throttle/default.nix new file mode 100644 index 000000000000..bf08aec41a5b --- /dev/null +++ b/pkgs/development/python-modules/asyncio-throttle/default.nix @@ -0,0 +1,34 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, pythonOlder +, pytestCheckHook +, pytest-asyncio +}: + +buildPythonPackage rec { + pname = "asyncio-throttle"; + version = "1.0.1"; + disabled = pythonOlder "3.6"; + + src = fetchFromGitHub { + owner = "hallazzang"; + repo = pname; + rev = "v${version}"; + sha256 = "0raqnrnp42cn1c7whbm7ajbgaczx33k6hbxsj30nh998pqxhh4sj"; + }; + + checkInputs = [ + pytest-asyncio + pytestCheckHook + ]; + + pythonImportsCheck = [ "asyncio_throttle" ]; + + meta = with lib; { + description = "Simple, easy-to-use throttler for asyncio"; + homepage = "https://github.com/hallazzang/asyncio-throttle"; + license = licenses.mit; + maintainers = with maintainers; [ hexa ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 3f7524840f86..86da89347193 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -426,6 +426,8 @@ in { async_generator = callPackage ../development/python-modules/async_generator { }; + asyncio-throttle = callPackage ../development/python-modules/asyncio-throttle { }; + asyncpg = callPackage ../development/python-modules/asyncpg { }; asyncssh = callPackage ../development/python-modules/asyncssh { };