From d08a3154a215e0f8ac9436447b9639af408c2e53 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Wed, 13 Dec 2023 21:46:37 +0100 Subject: [PATCH] python311Packages.aiohappyeyeballs: init at 2.3.0 Modul for connecting with Happy Eyeballs https://github.com/bdraco/aiohappyeyeballs --- .../aiohappyeyeballs/default.nix | 54 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 56 insertions(+) create mode 100644 pkgs/development/python-modules/aiohappyeyeballs/default.nix diff --git a/pkgs/development/python-modules/aiohappyeyeballs/default.nix b/pkgs/development/python-modules/aiohappyeyeballs/default.nix new file mode 100644 index 000000000000..8922c8283adc --- /dev/null +++ b/pkgs/development/python-modules/aiohappyeyeballs/default.nix @@ -0,0 +1,54 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, poetry-core +, pytest-asyncio +, pytestCheckHook +, pythonOlder +}: + +buildPythonPackage rec { + pname = "aiohappyeyeballs"; + version = "2.3.0"; + pyproject = true; + + disabled = pythonOlder "3.10"; + + src = fetchFromGitHub { + owner = "bdraco"; + repo = "aiohappyeyeballs"; + rev = "refs/tags/v${version}"; + hash = "sha256-LMvELnN6Sy6DssXfH6fQ84N2rhdjqB8AlikTMidrjT4="; + }; + + postPatch = '' + substituteInPlace pyproject.toml \ + --replace " --cov=aiohappyeyeballs --cov-report=term-missing:skip-covered" "" + ''; + + nativeBuildInputs = [ + poetry-core + ]; + + nativeCheckInputs = [ + pytest-asyncio + pytestCheckHook + ]; + + pythonImportsCheck = [ + "aiohappyeyeballs" + ]; + + disabledTestPaths = [ + # Test has typos + "tests/test_impl.py" + ]; + + meta = with lib; { + description = "Modul for connecting with Happy Eyeballs"; + homepage = "https://github.com/bdraco/aiohappyeyeballs"; + changelog = "https://github.com/bdraco/aiohappyeyeballs/blob/${version}/CHANGELOG.md"; + license = licenses.psfl; + maintainers = with maintainers; [ fab ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 7cf03fc84e9e..0e337c6fc022 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -218,6 +218,8 @@ self: super: with self; { aiogram = callPackage ../development/python-modules/aiogram { }; + aiohappyeyeballs = callPackage ../development/python-modules/aiohappyeyeballs { }; + aioharmony = callPackage ../development/python-modules/aioharmony { }; aiohomekit = callPackage ../development/python-modules/aiohomekit { };