Skip to content

fix(install): promote croniter to a core dependency#17577

Merged
teknium1 merged 2 commits into
mainfrom
hermes/hermes-49aabb57
Apr 29, 2026
Merged

fix(install): promote croniter to a core dependency#17577
teknium1 merged 2 commits into
mainfrom
hermes/hermes-49aabb57

Conversation

@teknium1

Copy link
Copy Markdown
Contributor

Salvages #17234 from @txbxxx with a corrected premise.

Summary

pip install hermes-agent (no extras) now yields a working cron scheduler out of the box. Previously, plain installs left HAS_CRONITER=False, so any recurring cron/interval schedule silently returned next_run_at=None and only surfaced as a state=error message on tick — bad first-run UX for a feature that ships in the core CLI, gateway ticker, and cronjob agent tool.

Changes

  • pyproject.tomlcroniter>=6.0.0,<7 moved into core dependencies
  • pyproject.tomlcron = [] kept as empty passthrough so existing hermes-agent[cron] installs and the [all]/[termux] extras continue to resolve
  • cron/jobs.py — update the now-stale compute_next_run() warning message (no longer tells users to install the [cron] extra)
  • scripts/release.py — AUTHOR_MAP entry for @txbxxx

Salvage note

The original PR claimed [cron] wasn't included in [all], but it is (pyproject.toml line 112 on main), so the stated failure mode ("hermes update strips croniter") doesn't happen via [all]. But the deeper UX argument is right: cron is a built-in first-class feature, not an optional integration like modal or matrix, and should work on a bare install. croniter is a tiny pure-Python dep (~60KB, zero native extensions). Kept the [cron] extra as an empty passthrough for back-compat.

Also: the original PR branch was severely stale (would have reverted the entire minimax-oauth feature landed this morning, plus nix workflow hardening, anthropic adapter lazy-load, lmstudio provider, BOOT.md hook, and dozens more unrelated changes). Rebuilt the fix directly on current main.

Validation

Install path Before After
pip install hermes-agent (no extras) HAS_CRONITER=False, schedules silently broken HAS_CRONITER=True, schedules work
pip install 'hermes-agent[cron]' works (legacy extra) works (empty extra, croniter from core)
pip install 'hermes-agent[all]' works works
  • Throwaway venv + pip install -e . (no extras) → HAS_CRONITER=True, compute_next_run({'kind':'cron','expr':'*/5 * * * *'}) → valid ISO timestamp
  • Throwaway venv + pip install -e '.[cron]' → still resolves cleanly, croniter present via core
  • tests/cron/ — 263/263 pass

Original PR: #17234

txbxxx and others added 2 commits April 29, 2026 10:29
Cron is a built-in Hermes feature (CLI `hermes cron`, `cronjob` agent
tool, gateway ticker, scheduler in cron/scheduler.py) but croniter has
been gated behind the [cron] optional extra. Users who do a plain
`pip install hermes-agent` can create jobs via /cron but any recurring
cron schedule silently returns next_run_at=None (HAS_CRONITER=False),
which then gets wrapped into a 'state=error' message only after a tick.

Move croniter into core dependencies so scheduled jobs work out of the
box on any install path. The [cron] extra is kept as an empty
passthrough so existing `pip install hermes-agent[cron]` installs and
the [all]/[termux] extras continue to resolve.

Also update the now-stale user-facing error message in
`compute_next_run()` that still tells users to install `hermes-agent[cron]`.

Salvaged from #17234 (authored by @txbxxx) with a corrected premise:
the original PR claimed [cron] wasn't in [all], but it is (pyproject.toml
line 112). The real UX problem is the plain no-extras install path,
which this fix addresses.
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ npm lockfile hash out of date

Checked against commit 2cf518c (PR head at check time).

The hash = "sha256-..." line in these nix files no longer matches the committed package-lock.json:

Apply the fix

  • Apply lockfile fix — tick to push a commit with the correct hashes to this PR branch
  • Or run the Nix Lockfile Fix workflow manually (pass PR #17577)
  • Or locally: nix run .#fix-lockfiles -- --apply and commit the diff

@teknium1 teknium1 merged commit 69d4800 into main Apr 29, 2026
9 of 12 checks passed
@teknium1 teknium1 deleted the hermes/hermes-49aabb57 branch April 29, 2026 17:35
@alt-glitch alt-glitch added type/bug Something isn't working P1 High — major feature broken, no workaround comp/cron Cron scheduler and job management labels Apr 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/cron Cron scheduler and job management P1 High — major feature broken, no workaround type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants