2021-01-25 08:26:54 +00:00
|
|
|
{ lib
|
2018-10-16 21:20:40 +01:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, pytest
|
|
|
|
, gevent
|
|
|
|
, certifi
|
|
|
|
, six
|
|
|
|
, backports_ssl_match_hostname
|
2021-03-12 01:43:36 +00:00
|
|
|
, pythonOlder
|
2018-10-16 21:20:40 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "geventhttpclient";
|
2021-02-20 09:09:09 +00:00
|
|
|
version = "1.4.5";
|
2018-10-16 21:20:40 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-02-20 09:09:09 +00:00
|
|
|
sha256 = "3f0ab18d84ef26ba0c9df73ae2a41ba30a46072b447f2e36c740400de4a63d44";
|
2018-10-16 21:20:40 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ pytest ];
|
2021-03-12 01:43:36 +00:00
|
|
|
propagatedBuildInputs = [ gevent certifi six ]
|
|
|
|
++ lib.optionals (pythonOlder "3.7") [ backports_ssl_match_hostname ];
|
2018-10-16 21:20:40 +01:00
|
|
|
|
|
|
|
# Several tests fail that require network
|
|
|
|
doCheck = false;
|
|
|
|
checkPhase = ''
|
|
|
|
py.test $out
|
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/gwik/geventhttpclient";
|
2018-10-16 21:20:40 +01:00
|
|
|
description = "HTTP client library for gevent";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ koral ];
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|