2022-06-16 17:23:12 +00:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
2021-12-24 04:21:11 +00:00
|
|
|
, buildPythonPackage
|
2024-05-15 15:35:15 +00:00
|
|
|
, fetchPypi
|
|
|
|
, pythonOlder
|
|
|
|
|
|
|
|
# build-system
|
|
|
|
, setuptools
|
|
|
|
|
|
|
|
# dependencies
|
|
|
|
, billiard
|
|
|
|
, kombu
|
|
|
|
, vine
|
2021-12-24 04:21:11 +00:00
|
|
|
, click
|
|
|
|
, click-didyoumean
|
|
|
|
, click-repl
|
2024-05-15 15:35:15 +00:00
|
|
|
, click-plugins
|
|
|
|
, tzdata
|
|
|
|
, python-dateutil
|
|
|
|
|
|
|
|
# optional-dependencies
|
|
|
|
, google-cloud-storage
|
2021-12-24 04:21:11 +00:00
|
|
|
, moto
|
2024-05-15 15:35:15 +00:00
|
|
|
, msgpack
|
2021-12-24 04:21:11 +00:00
|
|
|
, pymongo
|
2024-05-15 15:35:15 +00:00
|
|
|
, pyyaml
|
|
|
|
|
|
|
|
# tests
|
2021-12-24 04:21:11 +00:00
|
|
|
, pytest-celery
|
2023-07-15 17:15:38 +00:00
|
|
|
, pytest-click
|
2021-12-24 04:21:11 +00:00
|
|
|
, pytest-subtests
|
|
|
|
, pytest-timeout
|
2024-02-07 01:22:34 +00:00
|
|
|
, pytest-xdist
|
2021-12-24 04:21:11 +00:00
|
|
|
, pytestCheckHook
|
2022-03-05 16:20:37 +00:00
|
|
|
, nixosTests
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "celery";
|
2024-05-15 15:35:15 +00:00
|
|
|
version = "5.4.0";
|
|
|
|
pyproject = true;
|
2021-12-24 04:21:11 +00:00
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
disabled = pythonOlder "3.8";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2024-05-15 15:35:15 +00:00
|
|
|
hash = "sha256-UEoZFA6NMCnVrK2IMwxUHUw/ZMeJ2F+UdWdi2Lyn5wY=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
build-system = [
|
|
|
|
setuptools
|
|
|
|
];
|
|
|
|
|
|
|
|
dependencies = [
|
2021-12-24 04:21:11 +00:00
|
|
|
billiard
|
|
|
|
click
|
|
|
|
click-didyoumean
|
|
|
|
click-plugins
|
|
|
|
click-repl
|
|
|
|
kombu
|
2023-07-15 17:15:38 +00:00
|
|
|
python-dateutil
|
|
|
|
tzdata
|
2021-12-24 04:21:11 +00:00
|
|
|
vine
|
|
|
|
];
|
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
optional-dependencies = {
|
|
|
|
gcs = [ google-cloud-storage ];
|
|
|
|
mongodb = [ pymongo ];
|
|
|
|
msgpack = [ msgpack ];
|
|
|
|
yaml = [ pyyaml ];
|
|
|
|
};
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-12-24 04:21:11 +00:00
|
|
|
moto
|
|
|
|
pytest-celery
|
2023-07-15 17:15:38 +00:00
|
|
|
pytest-click
|
2021-12-24 04:21:11 +00:00
|
|
|
pytest-subtests
|
|
|
|
pytest-timeout
|
2024-02-07 01:22:34 +00:00
|
|
|
pytest-xdist
|
2021-12-24 04:21:11 +00:00
|
|
|
pytestCheckHook
|
2024-05-15 15:35:15 +00:00
|
|
|
]
|
|
|
|
# based on https://github.com/celery/celery/blob/main/requirements/test.txt
|
|
|
|
++ optional-dependencies.yaml
|
|
|
|
++ optional-dependencies.msgpack
|
|
|
|
++ optional-dependencies.mongodb
|
|
|
|
++ optional-dependencies.gcs;
|
2021-12-24 04:21:11 +00:00
|
|
|
|
|
|
|
disabledTestPaths = [
|
|
|
|
# test_eventlet touches network
|
|
|
|
"t/unit/concurrency/test_eventlet.py"
|
|
|
|
# test_multi tries to create directories under /var
|
|
|
|
"t/unit/bin/test_multi.py"
|
|
|
|
"t/unit/apps/test_multi.py"
|
2024-04-21 15:54:59 +00:00
|
|
|
# requires moto<5
|
|
|
|
"t/unit/backends/test_s3.py"
|
2021-12-24 04:21:11 +00:00
|
|
|
];
|
2020-12-09 12:39:15 +00:00
|
|
|
|
2021-12-24 04:21:11 +00:00
|
|
|
disabledTests = [
|
|
|
|
"msgpack"
|
|
|
|
"test_check_privileges_no_fchown"
|
2024-04-21 15:54:59 +00:00
|
|
|
# seems to only fail on higher core counts
|
|
|
|
# AssertionError: assert 3 == 0
|
|
|
|
"test_setup_security_disabled_serializers"
|
2024-02-07 01:22:34 +00:00
|
|
|
# fails with pytest-xdist
|
|
|
|
"test_itercapture_limit"
|
|
|
|
"test_stamping_headers_in_options"
|
|
|
|
"test_stamping_with_replace"
|
2022-06-16 17:23:12 +00:00
|
|
|
] ++ lib.optionals stdenv.isDarwin [
|
|
|
|
# too many open files on hydra
|
|
|
|
"test_cleanup"
|
|
|
|
"test_with_autoscaler_file_descriptor_safety"
|
|
|
|
"test_with_file_descriptor_safety"
|
2021-12-24 04:21:11 +00:00
|
|
|
];
|
2020-12-09 12:39:15 +00:00
|
|
|
|
2021-12-24 04:21:11 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"celery"
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-03-05 16:20:37 +00:00
|
|
|
passthru.tests = {
|
|
|
|
inherit (nixosTests) sourcehut;
|
|
|
|
};
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Distributed task queue";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "celery";
|
2021-12-24 04:21:11 +00:00
|
|
|
homepage = "https://github.com/celery/celery/";
|
2023-10-09 19:29:22 +00:00
|
|
|
changelog = "https://github.com/celery/celery/releases/tag/v${version}";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.bsd3;
|
2022-01-13 20:06:32 +00:00
|
|
|
maintainers = with maintainers; [ fab ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|