Skip to content

fix(cli): align /cron slash handler with cron parser - #24597

Open
Sylw3ster wants to merge 1 commit into
NousResearch:mainfrom
Sylw3ster:codex/fix-cron-slash-parity
Open

Sylw3ster wants to merge 1 commit into
NousResearch:mainfrom
Sylw3ster:codex/fix-cron-slash-parity

Conversation

@Sylw3ster

@Sylw3ster Sylw3ster commented May 12, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Fixes the interactive /cron slash command so it matches the real cron CLI surface more closely.

It now forwards --script, --workdir, --no-agent, and --agent correctly, and adds /cron status and /cron tick support. This prevents script-backed cron jobs from losing important options when created or edited from chat.

Related Issue

--

Type of Change

  • Bug fix
  • Tests
  • Documentation update
  • Refactor

Changes Made

  • updated /cron slash parsing in cli.py
  • added status and tick to cron subcommand metadata
  • added regression tests for slash-command forwarding and dispatch

How to Test

  1. uv run pytest tests/cli/test_cli_cron_command.py tests/hermes_cli/test_commands.py
  2. uv run ruff check cli.py hermes_cli/commands.py tests/cli/test_cli_cron_command.py tests/hermes_cli/test_commands.py

@alt-glitch alt-glitch added type/bug Something isn't working comp/cli CLI entry point, hermes_cli/, setup wizard comp/cron Cron scheduler and job management P3 Low — cosmetic, nice to have labels May 12, 2026
@teknium1

Copy link
Copy Markdown
Collaborator

Thanks for identifying the CLI/slash-command drift. The underlying bug is still present on current main, but this needs a small salvage onto the extracted handler.

Problems

  • Current cli.py:8678 dispatches /cron to _handle_cron_command, whose active definition is now hermes_cli/cli_commands_mixin.py:1177, not cli.py. The current handler still omits script, workdir, and no_agent from parsing and forwarding (hermes_cli/cli_commands_mixin.py:1194-1247, 1329-1337, 1374-1383).
  • The target CLI parser already supports these flags and status/tick (hermes_cli/subcommands/cron.py:48-72, 107-135, 156-161), so the requested parity remains valid.

Suggested changes

  • Transplant the slash-handler changes into hermes_cli/cli_commands_mixin.py::_handle_cron_command, while retaining the hermes_cli/commands.py subcommand metadata and regression tests.

Automated hermes-sweeper review.

@teknium1 teknium1 added sweeper:risk-compatibility Sweeper risk: may break existing users, config, migrations, defaults, or upgrades sweeper:blast-contained Sweeper blast radius: contained — one narrow path / opt-in / few users labels Jul 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/cli CLI entry point, hermes_cli/, setup wizard comp/cron Cron scheduler and job management P3 Low — cosmetic, nice to have sweeper:blast-contained Sweeper blast radius: contained — one narrow path / opt-in / few users sweeper:risk-compatibility Sweeper risk: may break existing users, config, migrations, defaults, or upgrades type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants