diff options
author | Alyssa Ross <hi@alyssa.is> | 2022-12-06 19:57:55 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2023-02-08 13:48:30 +0000 |
commit | bf3aadfdd39aa197e18bade671fab6726349ffa4 (patch) | |
tree | 698567af766ed441d757b57a7b21e68d4a342a2b /nixpkgs/pkgs/development/python-modules/httpcore | |
parent | f4afc5a01d9539ce09e47494e679c51f80723d07 (diff) | |
parent | 99665eb45f58d959d2cb9e49ddb960c79d596f33 (diff) | |
download | nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar.gz nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar.bz2 nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar.lz nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar.xz nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar.zst nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.zip |
Merge commit '99665eb45f58d959d2cb9e49ddb960c79d596f33'
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/httpcore')
-rw-r--r-- | nixpkgs/pkgs/development/python-modules/httpcore/default.nix | 53 |
1 files changed, 35 insertions, 18 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/httpcore/default.nix b/nixpkgs/pkgs/development/python-modules/httpcore/default.nix index 79d979b10a97..5016ece96f2f 100644 --- a/nixpkgs/pkgs/development/python-modules/httpcore/default.nix +++ b/nixpkgs/pkgs/development/python-modules/httpcore/default.nix @@ -1,54 +1,71 @@ { lib -, buildPythonPackage -, pythonOlder -, fetchFromGitHub , anyio +, buildPythonPackage , certifi +, fetchFromGitHub , h11 , h2 , pproxy , pytest-asyncio -, pytestCheckHook -, pytest-cov , pytest-httpbin +, pytest-trio +, pytestCheckHook +, pythonOlder , sniffio -, trio -, trustme -, uvicorn +, socksio }: buildPythonPackage rec { pname = "httpcore"; - version = "0.14.4"; - disabled = pythonOlder "3.6"; + version = "0.15.0"; + format = "setuptools"; + + disabled = pythonOlder "3.7"; src = fetchFromGitHub { owner = "encode"; repo = pname; rev = version; - sha256 = "19zsg8ijw0s1722ka67mjxx5z07lx9jq36z97l1fa6z1129wq240"; + hash = "sha256-FF3Yzac9nkVcA5bHVOz2ymvOelSfJ0K6oU8UWpBDcmo="; }; + postPatch = '' + substituteInPlace setup.py \ + --replace "h11>=0.11,<0.13" "h11>=0.11,<0.14" + ''; + propagatedBuildInputs = [ anyio certifi h11 - h2 sniffio ]; + passthru.optional-dependencies = { + http2 = [ + h2 + ]; + socks = [ + socksio + ]; + }; + checkInputs = [ pproxy pytest-asyncio - pytestCheckHook - pytest-cov pytest-httpbin - trio - trustme - uvicorn + pytest-trio + pytestCheckHook + ] ++ passthru.optional-dependencies.http2 + ++ passthru.optional-dependencies.socks; + + pythonImportsCheck = [ + "httpcore" ]; - pythonImportsCheck = [ "httpcore" ]; + pytestFlagsArray = [ + "--asyncio-mode=strict" + ]; meta = with lib; { description = "A minimal low-level HTTP client"; |