Skip to content

feat: add cron doctor health check - #43729

Open
joe102084 wants to merge 1 commit into
NousResearch:mainfrom
joe102084:feat/cron-delivery-doctor
Open

feat: add cron doctor health check#43729
joe102084 wants to merge 1 commit into
NousResearch:mainfrom
joe102084:feat/cron-delivery-doctor

Conversation

@joe102084

Copy link
Copy Markdown
Contributor

Summary

  • add a read-only Cron doctor found 2 issue(s) across 2 job(s):

    a61111adcdb0 Daily smart Hermes collaboration tip for Joe

    • last run failed: RuntimeError: HTTP 404: Model 'openai/gpt-5.5' requires available credits. Your account balance is too low to use paid models — add credits at https://portal.nousresearch.com or pick a free model.
      7ff4afbace0e Daily Movement BD lead pre-mortem
    • last run failed: RuntimeError: Unknown provider 'openai'. Check 'hermes model' for available providers, or run 'hermes doctor' to diagnose config issues.

Next: fix the listed job config, then run hermes cron doctor again. command for scheduled-job health checks

  • flag last run failures, delivery failures, missing next run times, invalid no-agent jobs, missing/out-of-sandbox scripts, and missing workdirs
  • add a small spec plus focused CLI/parser tests

Tests

  • ▶ running per-file parallel test suite via run_tests_parallel.py
    (TZ=UTC LANG=C.UTF-8 PYTHONHASHSEED=0; clean env)
    Discovered 2 test files (12 tests) under ['tests/hermes_cli/test_cron.py', 'tests/hermes_cli/test_subcommands_cron.py']; running with -j 20
    [ 50.0% | 6/12 | ✓6 | ✗0] ✓ tests/hermes_cli/test_subcommands_cron.py (6✓, 0.2s)
    [100.0% | 12/12 | ✓12 | ✗ 0] ✓ tests/hermes_cli/test_cron.py (6✓, 0.2s)

=== Summary: 2 files, 12 tests passed, 0 failed (100% complete) in 0.2s (20 workers) ===
Durations cached to test_durations.json (2 files)

=== Per-file subprocess time distribution ===
Files: 2
Total subprocess CPU-wall: 0.4s (runner wall: 0.2s, parallelism: 20x)
P50: 0.23s P90: 0.23s P95: 0.23s P99: 0.23s Max: 0.23s
<1s: 2 files (100%) <2s: 2 files (100%)
Top 10 slowest:
0.23s tests/hermes_cli/test_cron.py
0.20s tests/hermes_cli/test_subcommands_cron.py

  • ✓ Cron doctor found no issues
    No active jobs configured.

Notes

  • Read-only diagnostic only; it does not mutate jobs or start/stop the gateway.

@alt-glitch alt-glitch added type/feature New feature or request comp/cli CLI entry point, hermes_cli/, setup wizard comp/cron Cron scheduler and job management P3 Low — cosmetic, nice to have labels Jun 10, 2026
@teknium1

Copy link
Copy Markdown
Contributor

Thanks for the focused read-only diagnostic proposal. The command remains absent on current main: hermes_cli/cron.py:419-455 and hermes_cli/subcommands/cron.py:156-162 have no doctor path.

Problems

  • The PR’s script-root helper uses static CRON_DIR, but current execution resolves the active profile dynamically in cron/scheduler.py:543-552 and uses that home for scripts at cron/scheduler.py:2045. Salvage should preserve that profile/store alignment.
  • The tests do not cover all advertised findings. In particular, persisted legacy records are needed to test invalid no_agent, vanished workdir, no next_run_at, and sandbox-escape cases; create-time validation already rejects several of these states in cron/jobs.py:897-927 and cron/jobs.py:1128-1135.
  • The user-facing cron guide’s CLI list at website/docs/user-guide/features/cron.md:178-188 needs the new command, not only a standalone spec.

Suggested changes

  • Rebase the diagnostic logic around current profile-aware storage and the runs/history execution-ledger surface added by 49b375fcc.
  • Add table-driven coverage for each reported condition and update the public cron guide.

Automated hermes-sweeper review.

@teknium1 teknium1 added sweeper:blast-moderate Sweeper blast radius: moderate — a subsystem or single platform area/install-update Installer, updater, packaging, wheels, doctor labels Jul 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/install-update Installer, updater, packaging, wheels, doctor comp/cli CLI entry point, hermes_cli/, setup wizard comp/cron Cron scheduler and job management P3 Low — cosmetic, nice to have sweeper:blast-moderate Sweeper blast radius: moderate — a subsystem or single platform type/feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants