puruto-cron
What is puruto-cron?
puruto-cron is the local async job scheduler of the ecosystem. It lets you schedule tasks that run automatically — from puruto-data backups to periodic reports.
When to use it
- Periodic
puruto-databackups - Automatic reports (e.g. weekly finance summary)
- Scheduled synchronization with external services
- Alerts or notifications based on data conditions
Generate it
python3 .claude/skills/puruto-generator/scripts/generate.py --name puruto-cronHow it works
puruto-cron uses SQLite to persist jobs and runs (MVP scaffold).
The real scaffold stores fields such as:
job_id,enabled,puruto_target,schedule,promptnext_run_at,last_run_atlease_owner,lease_expires_attimeout_sec,max_retries,retry_backoff_sec
Job lifecycle
- Job is declared in
.jobs.jsonand synced withmain.py sync-jobs - Scheduler checks which jobs should run
- Acquires a lease/lock to avoid duplicate executions
- Invokes the target Puruto via shared
invoker.py(MVP scaffold) - If it fails, retries with backoff (up to the per-job limit)
- Result is recorded in SQLite (
runs) and notification events are emitted
Local notifications and replication to puruto-telegram
The scaffold writes events to:
notifications/events.jsonl(local)
And can replicate them to sibling puruto-telegram by default at:
../puruto-telegram/inbox/cron-events.jsonl
puruto-telegram consumes this inbox with inbox.py / inbox.py --deliver.
Included skills
/init— initializes SQLite DB and directory structure/help— explains how to use the scheduler/list— lists all configured jobs/status— shows scheduler state (jobs, recent runs, notification targets)/logs— inspectsnotifications/events.jsonlandruns//run-now— forces one immediate job execution