From b403a17db8cc54ef69d11cb9965c4db69148bd08 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Fri, 2 Feb 2018 14:54:23 +0100 Subject: [PATCH 1/2] pythonPackages.idna-ssl: init at 1.0.0 --- .../python-modules/idna-ssl/default.nix | 23 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 25 insertions(+) create mode 100644 pkgs/development/python-modules/idna-ssl/default.nix diff --git a/pkgs/development/python-modules/idna-ssl/default.nix b/pkgs/development/python-modules/idna-ssl/default.nix new file mode 100644 index 00000000000..177e68f6295 --- /dev/null +++ b/pkgs/development/python-modules/idna-ssl/default.nix @@ -0,0 +1,23 @@ +{ lib, buildPythonPackage, fetchPypi, idna }: + +buildPythonPackage rec { + pname = "idna_ssl"; + version = "1.0.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "1227e44039bd31e02adaeafdbba61281596d623d222643fb021f87f2144ea147"; + }; + + propagatedBuildInputs = [ idna ]; + + # Infinite recursion: tests require aiohttp, aiohttp requires idna-ssl + doCheck = false; + + meta = with lib; { + description = "Patch ssl.match_hostname for Unicode(idna) domains support"; + homepage = https://github.com/aio-libs/idna-ssl; + license = licenses.mit; + maintainers = with maintainers; [ dotlambda ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 7a279d96591..0876a2d7cf8 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5215,6 +5215,8 @@ in { }; }; + idna-ssl = callPackage ../development/python-modules/idna-ssl/default.nix { }; + ijson = callPackage ../development/python-modules/ijson/default.nix {}; imagesize = buildPythonPackage rec { From 7f531568594db46bcd6cfb079a877951eb61e410 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Fri, 2 Feb 2018 15:13:31 +0100 Subject: [PATCH 2/2] pythonPackages.aiohttp: 2.3.9 -> 2.3.10 and enable tests --- .../python-modules/aiohttp/default.nix | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/pkgs/development/python-modules/aiohttp/default.nix b/pkgs/development/python-modules/aiohttp/default.nix index 17737c33986..bea839f49e3 100644 --- a/pkgs/development/python-modules/aiohttp/default.nix +++ b/pkgs/development/python-modules/aiohttp/default.nix @@ -6,30 +6,33 @@ , multidict , async-timeout , yarl +, idna-ssl , pytest , gunicorn , pytest-raisesregexp +, pytest-mock }: buildPythonPackage rec { pname = "aiohttp"; - version = "2.3.9"; + version = "2.3.10"; src = fetchPypi { inherit pname version; - sha256 = "6003bed78dc591d31bd89ef16e630a1c4fd97a3cd17b975ec945c0f46d6fc881"; + sha256 = "8adda6583ba438a4c70693374e10b60168663ffa6564c5c75d3c7a9055290964"; }; disabled = pythonOlder "3.4"; - doCheck = false; # Too many tests fail. + checkInputs = [ pytest gunicorn pytest-raisesregexp pytest-mock ]; - checkInputs = [ pytest gunicorn pytest-raisesregexp ]; - propagatedBuildInputs = [ async-timeout chardet multidict yarl ]; + propagatedBuildInputs = [ async-timeout chardet multidict yarl ] + ++ lib.optional (pythonOlder "3.7") idna-ssl; - meta = { - description = "Http client/server for asyncio"; - license = with lib.licenses; [ asl20 ]; + meta = with lib; { + description = "Asynchronous HTTP Client/Server for Python and asyncio"; + license = licenses.asl20; homepage = https://github.com/KeepSafe/aiohttp/; + maintainers = with maintainers; [ dotlambda ]; }; }