nixpkgs/pkgs/development/python-modules/kombu/default.nix

40 lines
883 B
Nix
Raw Normal View History

2019-10-27 17:37:13 +01:00
{ lib, buildPythonPackage, fetchPypi
, amqp
, case
, Pyro4
, pytest
, pytz
, sqlalchemy
}:
2018-07-14 13:19:09 +02:00
buildPythonPackage rec {
pname = "kombu";
2019-11-19 15:35:36 +01:00
version = "4.6.6";
2018-07-14 13:19:09 +02:00
src = fetchPypi {
inherit pname version;
2019-11-19 15:35:36 +01:00
sha256 = "1760b54b1d15a547c9a26d3598a1c8cdaf2436386ac1f5561934bc8a3cbbbd86";
2018-07-14 13:19:09 +02:00
};
postPatch = ''
2019-10-27 17:37:13 +01:00
substituteInPlace requirements/test.txt \
--replace "pytest-sugar" ""
substituteInPlace requirements/default.txt \
--replace "amqp==2.5.1" "amqp~=2.5"
2018-07-14 13:19:09 +02:00
'';
propagatedBuildInputs = [ amqp ];
2019-10-27 17:37:13 +01:00
checkInputs = [ pytest case pytz Pyro4 sqlalchemy ];
# test_redis requires fakeredis, which isn't trivial to package
checkPhase = ''
pytest --ignore t/unit/transport/test_redis.py
'';
2018-07-14 13:19:09 +02:00
meta = with lib; {
description = "Messaging library for Python";
homepage = https://github.com/celery/kombu;
license = licenses.bsd3;
};
}