Cron Runner
CronRunner maintains the authoritative cron schedule for the entire Polytraders system.
What it does
CronRunner maintains the authoritative cron schedule for the entire Polytraders system. It reads a declarative cron manifest (cron_expression per task, UTC), fires each task at the correct wall-clock moment, serialises concurrent firings into an ordered queue, and emits an OperationsReport heartbeat after each dispatch. CronRunner never executes strategy logic or touches the CLOB directly; it is purely a scheduling and dispatch service. Internal-only — no API surface beyond the internal bus.
Pipeline placement
Applies to: All cron-scheduled tasks across all 97 production bots
Why it matters
| If this fails | Consequence |
|---|---|
| Cron task not fired on schedule | Downstream bots that rely on scheduled triggers (e.g. daily P&L reconciliation, pre-event quoting cycles) silently miss their window. Delayed reconciliation compounds drift. |
| Two instances of CronRunner fire the same task simultaneously | Duplicate fills or double-counted reconciliation records corrupt ledgers and inflate reported P&L. |
| CronRunner crashes and does not recover | All scheduled tasks across all 97 bots stop firing. The system drifts into an uncontrolled state without time-based governance. |
| Missed quiet-hours suppression | Strategies fire during configured quiet hours (e.g. market-open volatility windows), creating unintended exposure. |
Inputs
Polymarket inputs
| Input | Source | Required | Use |
|---|---|---|---|
| Market schedule metadata (event start times) | internal | optional | Align pre-event quoting cycles to Polymarket event start times when calendar feeds are configured. |
Internal inputs
| Input | Source | Required | Use |
|---|---|---|---|
| Cron manifest — list of tasks with cron_expression, enabled_strategies, quiet_hour windows | Config store | required | Primary schedule definition. Each entry maps a cron expression to one or more strategy or governance task IDs. |
| KillSwitch active flag | KillSwitch | optional | When KillSwitch is active, suppress all non-critical scheduled tasks. Health and governance tasks continue. |
Authority
What this bot is permitted to do
State
Readiness
General live
Status
live
Class
Governance Service
Default mode
general_live
Developer owner
Polytraders core — Governance pod
Capital impact
Indirect
Reason codes emitted
| Code | Severity | Meaning | Action |
|---|---|---|---|
| CRON_RUNNER_TASK_DISPATCHED | INFO | A cron task fired on schedule and was dispatched to all configured targets. | No action — operational heartbeat. |
| CRON_RUNNER_INVALID_EXPRESSION | HARD_REJECT | A cron expression in the manifest failed to parse. | Reject the config entry at load time; alert on-call. |
| CRON_RUNNER_DUPLICATE_FIRE | WARN | A second CronRunner instance attempted to dispatch the same task at the same scheduled time; distributed lock was already held. | Skip dispatch; log warning. |
| CRON_RUNNER_QUIET_HOURS_SKIP | INFO | A task with disable_during_quiet_hours=true was suppressed because the current UTC time falls within a configured quiet window. | No action — expected behaviour. |
| CRON_RUNNER_NO_TARGETS | WARN | A task entry has an empty enabled_strategies list; there is nothing to dispatch. | Log warning; skip dispatch. |
| KILL_SWITCH_ACTIVE | WARN | KillSwitch is active; trading-class scheduled tasks are suppressed. | Suppress trading tasks; continue governance and health tasks. |
| CRON_RUNNER_BUS_PUBLISH_FAILED | WARN | Internal bus publish for a task trigger failed after retries. | Log error; emit alert; retry on next tick. |
| CRON_RUNNER_MANIFEST_RELOAD_OK | INFO | Cron manifest reloaded successfully after a config change event. | No action. |
Related bots in Governance & Ops
Used by
Reverse index — strategies that currently reference gov.cron-runner. If you change this bot's authority or reason codes, these strategies must re-pass shadow.
| Strategy | State | Activity |
|---|---|---|
| US Elections — sentiment fade | demo-wired | last triggered 18m ago |
| BTC weekly — close-aware quotes | demo-wired | last triggered 25m ago |
| Fed Rates — surprise drift | frozen | last triggered 32m ago |
Showing 3 of 3 · demo-wired ≠ production-live
Why this matters
Governance & Ops bots does NOT propose, approve, or block trades; only observes and reports. Understanding the authority boundary prevents misuse and makes promotion-gate reviews faster and more reliable. View raw spec JSON →