The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
feat(doctor): warn when the cron store is unwritable or its disk is nearly full
kshitijk4poor79f45482efbb
diff --git a/hermes_cli/doctor.py b/hermes_cli/doctor.pyindex 9b8ffac8402..337df2e1f8d 100644--- a/hermes_cli/doctor.py+++ b/hermes_cli/doctor.py@@ -51,6 +51,7 @@ from hermes_cli.doctor_tools import ()from hermes_cli.doctor_state import (_check_checkpoint_store,+ _check_cron_store,_check_directory_structure,_check_memory_provider,_check_profiles,@@ -117,7 +118,8 @@ DOCTOR_CHECKS = (('xAI Model Retirement (May 15, 2026)', _check_xai_retirement),('Session Reset (timers removed Sep 7, 2026)', _check_retired_session_reset),('Auth Providers', _check_auth_providers),- ('Directory Structure', _check_directory_structure), (None, _check_state_db), (None, _check_checkpoint_store),+ ('Directory Structure', _check_directory_structure), (None, _check_state_db), (None, _check_cron_store),+ (None, _check_checkpoint_store),(None, _check_gateway_supervision), (None, _check_command_installation),('External Tools', _check_git_and_rg), (None, _check_terminal_backend), (None, _check_node_and_browser),(None, _check_npm_audit), ('API Connectivity', _check_api_connectivity),diff --git a/hermes_cli/doctor_state.py b/hermes_cli/doctor_state.pyindex cd049b18608..01e5c0d8778 100644--- a/hermes_cli/doctor_state.py+++ b/hermes_cli/doctor_state.py@@ -491,6 +491,22 @@ def _check_state_db(should_fix: bool, f: Finding) -> None:_state_db_wal(f, should_fix, state_db_path)+@doctor_check()+def _check_cron_store(should_fix: bool, f: Finding) -> None:+ """The cron store accepts writes and its filesystem is not nearly full (jobs skip otherwise)."""+ from hermes_cli.doctor import HERMES_HOME, _DHH+ from cron.store_health import LOW_FREE_BYTES, free_bytes, probe_report+ cron_dir = HERMES_HOME / "cron"+ if (report := probe_report(cron_dir)) is not None:+ check_warn(f"{_DHH}/cron/ is NOT writable ({report['error']}) — scheduled cron jobs are being skipped")+ return f.issues.append(f"Cron store {report['store']} is not writable: {report['fix']}")+ free = free_bytes(cron_dir) if cron_dir.is_dir() else None+ if free is not None and free < LOW_FREE_BYTES:+ check_warn(f"{_DHH}/cron/ filesystem has only {_human_bytes(free)} free — cron jobs stop when it fills")+ return f.issues.append(f"Free disk space on the filesystem holding {cron_dir}")+ check_ok(f"{_DHH}/cron/ store is writable")++@doctor_check()def _check_checkpoint_store(should_fix: bool, f: Finding) -> None:"""/rollback store footprint: warn when checkpoints are on and the store sits above its cap."""