2020-04-24 23:36:52 +00:00
|
|
|
{ lib, buildPythonPackage, fetchPypi
|
|
|
|
, amqp
|
2020-06-15 15:56:04 +00:00
|
|
|
, botocore
|
2020-04-24 23:36:52 +00:00
|
|
|
, case
|
|
|
|
, Pyro4
|
|
|
|
, pytest
|
|
|
|
, pytz
|
|
|
|
, sqlalchemy
|
2020-05-03 17:38:23 +00:00
|
|
|
, importlib-metadata
|
|
|
|
, pythonOlder
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "kombu";
|
2020-08-20 17:08:02 +00:00
|
|
|
version = "4.6.11";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-08-20 17:08:02 +00:00
|
|
|
sha256 = "ca1b45faac8c0b18493d02a8571792f3c40291cf2bcf1f55afed3d8f3aa7ba74";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace requirements/test.txt \
|
|
|
|
--replace "pytest-sugar" ""
|
|
|
|
substituteInPlace requirements/default.txt \
|
|
|
|
--replace "amqp==2.5.1" "amqp~=2.5"
|
|
|
|
'';
|
|
|
|
|
2020-05-03 17:38:23 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
amqp
|
|
|
|
] ++ lib.optionals (pythonOlder "3.8") [
|
|
|
|
importlib-metadata
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-06-15 15:56:04 +00:00
|
|
|
checkInputs = [ botocore pytest case pytz Pyro4 sqlalchemy ];
|
2020-04-24 23:36:52 +00:00
|
|
|
# test_redis requires fakeredis, which isn't trivial to package
|
|
|
|
checkPhase = ''
|
|
|
|
pytest --ignore t/unit/transport/test_redis.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Messaging library for Python";
|
|
|
|
homepage = "https://github.com/celery/kombu";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
};
|
|
|
|
}
|