fix(cronjob): warn when builtin scheduler has no gateway - #87058
Conversation
Duplicate of #51790, the earlier open PR implementing the same builtin-scheduler/no-gateway creation warning and external-scheduler suppression. |
fix(cronjob): warn when builtin scheduler has no gateway
|
|
Closing as duplicate — merged via #88323 which salvages #73877 (the more complete implementation with a shared Your PR's approach was correct (detect builtin scheduler + no gateway → warn), and your tests covered the right branches. #73877 went further by extracting the logic into a shared module so both the CLI and the tool use the same code, avoiding future duplication. The salvage also adds a fix for the desktop ticker false positive (HERMES_DESKTOP=1 runs its own cron ticker without a gateway process). Thank you for the contribution! |
Summary
cronjobjobs are created with the builtin scheduler but no gateway process is running.Changes
tools/cronjob_tools.py_gateway_not_running_warning()to detectresolve_cron_scheduler().name == "builtin"and no running gateway PID.cronjobcreate response message alongside existing local-delivery notice.tests/tools/test_cronjob_tools.pyTest Plan
python3 -m py_compile tools/cronjob_tools.py tests/tools/test_cronjob_tools.pypython3 -m pytest tests/tools/test_cronjob_tools.py::TestLocalDeliveryNotice::test_builtin_scheduler_without_gateway_emits_warning tests/tools/test_cronjob_tools.py::TestLocalDeliveryNotice::test_non_builtin_scheduler_omits_gateway_warning tests/tools/test_cronjob_tools.py::TestLocalDeliveryNotice::test_running_gateway_omits_warning tests/tools/test_cronjob_tools.py::TestUnifiedCronjobTool::test_create_and_list -qCloses #87033