Gateway看门狗-知微 was erroring (exit -15): its check_session_health did a live LLM ping with 25s timeout. Cold-start LLM latency is 20-100s so the ping always timed out -> false '不健康' verdict -> false gateway restart -> and each 10-min run burned 22k tokens. Now uses xmpp_logger._scan_agent_log (zero cost, reads real call results): - ok if last real call succeeded - unhealthy only if last call explicitly failed - idle (no recent calls) counts as healthy Verified: watchdog job now status=ok. Also: triggered all 6 weekend 'Blocked' jobs via hermes cron run — all now status=ok, proving the hardlink fix holds.
25 lines
987 B
Python
25 lines
987 B
Python
import json
|
|
from datetime import datetime
|
|
|
|
print('=== pa profile error jobs ===')
|
|
d = json.load(open('/home/hmo/.hermes/profiles/position-analyst/cron/jobs.json'))
|
|
jobs = d if isinstance(d, list) else d.get('jobs', [])
|
|
for j in jobs:
|
|
if j.get('last_status') == 'error':
|
|
lr = str(j.get('last_run_at') or '?')[:19]
|
|
err = str(j.get('last_error') or '')[:120].replace('\n', ' ')
|
|
print(f"{j.get('name')} | last={lr} | {err}")
|
|
|
|
print()
|
|
print('=== default profile error jobs ===')
|
|
d2 = json.load(open('/home/hmo/.hermes/cron/jobs.json'))
|
|
jobs2 = d2 if isinstance(d2, list) else d2.get('jobs', [])
|
|
for j in jobs2:
|
|
if j.get('last_status') == 'error':
|
|
lr = str(j.get('last_run_at') or '?')[:19]
|
|
err = str(j.get('last_error') or '')[:120].replace('\n', ' ')
|
|
print(f"{j.get('name')} | last={lr} | {err}")
|
|
|
|
print()
|
|
print('当前时间:', datetime.now().strftime('%Y-%m-%d %H:%M'))
|
|
print('硬链接修复时间: 2026-07-20 00:53 (周一凌晨)') |