1{ 2 lib, 3 stdenv, 4 buildPythonPackage, 5 fetchFromGitHub, 6 gevent, 7 pytest-asyncio, 8 pytest-cov-stub, 9 pytest-tornado, 10 pytest8_3CheckHook, 11 pythonOlder, 12 pytz, 13 setuptools, 14 setuptools-scm, 15 tornado, 16 twisted, 17 tzlocal, 18}: 19 20buildPythonPackage rec { 21 pname = "apscheduler"; 22 version = "3.11.0"; 23 pyproject = true; 24 25 disabled = pythonOlder "3.7"; 26 27 src = fetchFromGitHub { 28 owner = "agronholm"; 29 repo = "apscheduler"; 30 tag = version; 31 hash = "sha256-tFEm9yXf8CqcipSYtM7JM6WQ5Qm0YtgWhZvZOBAzy+w="; 32 }; 33 34 postPatch = '' 35 sed -i "/addopts/d" pyproject.toml 36 ''; 37 38 build-system = [ 39 setuptools 40 setuptools-scm 41 ]; 42 43 dependencies = [ 44 tzlocal 45 ]; 46 47 nativeCheckInputs = [ 48 gevent 49 pytest-asyncio 50 pytest-cov-stub 51 pytest-tornado 52 pytest8_3CheckHook 53 pytz 54 tornado 55 twisted 56 ]; 57 58 disabledTests = [ 59 "test_broken_pool" 60 # gevent tests have issue on newer Python releases 61 "test_add_live_job" 62 "test_add_pending_job" 63 "test_shutdown" 64 ] 65 ++ lib.optionals stdenv.hostPlatform.isDarwin [ 66 "test_submit_job" 67 "test_max_instances" 68 ]; 69 70 pythonImportsCheck = [ "apscheduler" ]; 71 72 meta = with lib; { 73 description = "Library that lets you schedule your Python code to be executed"; 74 homepage = "https://github.com/agronholm/apscheduler"; 75 license = licenses.mit; 76 maintainers = [ ]; 77 }; 78}