depot/third_party/nixpkgs/pkgs/development/python-modules/h2/default.nix
Default email 841d9c7fc1 Project import generated by Copybara.
GitOrigin-RevId: 3a8d7958a610cd3fec3a6f424480f91a1b259185
2021-06-29 00:13:55 +01:00

52 lines
1 KiB
Nix

{ lib
, buildPythonPackage
, pythonOlder
, fetchPypi
, fetchpatch
, hpack
, hyperframe
, pytestCheckHook
, hypothesis
}:
buildPythonPackage rec {
pname = "h2";
version = "4.0.0";
format = "setuptools";
disabled = pythonOlder "3.6";
src = fetchPypi {
inherit pname version;
sha256 = "bb7ac7099dd67a857ed52c815a6192b6b1f5ba6b516237fc24a085341340593d";
};
patches = [
# Workaround issues with hypothesis 6.6
# https://github.com/python-hyper/h2/pull/1248
(fetchpatch {
url = "https://github.com/python-hyper/h2/commit/0646279dab694a89562846c810202ce2c0b49be3.patch";
sha256 = "1k0fsxwq9wbv15sc9ixls4qmxxghlzpflf3awm66ar9m2ikahiak";
})
];
propagatedBuildInputs = [
hpack
hyperframe
];
checkInputs = [
pytestCheckHook
hypothesis
];
pythonImportCheck = [
"h2.connection"
"h2.config"
];
meta = with lib; {
description = "HTTP/2 State-Machine based protocol implementation";
homepage = "http://hyper.rtfd.org/";
license = licenses.mit;
};
}