2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2022-01-26 04:04:25 +00:00
|
|
|
, pythonOlder
|
|
|
|
|
|
|
|
# tested using
|
2020-04-24 23:36:52 +00:00
|
|
|
, python
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "hiredis";
|
2021-08-23 08:02:39 +00:00
|
|
|
version = "2.0.0";
|
2022-01-26 04:04:25 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.6";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-08-23 08:02:39 +00:00
|
|
|
sha256 = "81d6d8e39695f2c37954d1011c0480ef7cf444d4e3ae24bc5e89ee5de360139a";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
2022-01-26 04:04:25 +00:00
|
|
|
|
|
|
|
pythonImportsCheck = [ "hiredis" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
checkPhase = ''
|
2020-09-25 04:45:31 +00:00
|
|
|
mv hiredis _hiredis
|
2020-04-24 23:36:52 +00:00
|
|
|
${python.interpreter} test.py
|
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Wraps protocol parsing code in hiredis, speeds up parsing of multi bulk replies";
|
|
|
|
homepage = "https://github.com/redis/hiredis-py";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ mmai ];
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|