Skip to content

fix(cli): hermes -z no longer silently drops -s/--skills (salvage #31591) - #90389

Merged
teknium1 merged 3 commits into
mainfrom
fix/oneshot-skills-preload
Aug 20, 2026
Merged

fix(cli): hermes -z no longer silently drops -s/--skills (salvage #31591)#90389
teknium1 merged 3 commits into
mainfrom
fix/oneshot-skills-preload

Conversation

@teknium1

Copy link
Copy Markdown
Contributor

Summary

hermes -z -s <skill> now actually preloads the requested skill; before, oneshot mode silently discarded -s/--skills while hermes chat -q -s honored it.

Salvage of #31591 by @GarlicGo (earliest of 5 independent fixes), cherry-picked onto current main with authorship preserved. Fixes #31548, #65119.

Root cause: the -z fast path builds its AIAgent directly in hermes_cli/oneshot.py, and neither _run_and_exit_oneshot() nor run_oneshot() accepted or forwarded the skills argument. The skill preload only lived in the interactive cmd_chat path.

Changes

  • hermes_cli/oneshot.py: _normalize_skills() + _build_preloaded_skills_prompt() (same partial-success contract as CLI chat: skip unknown skills when at least one loads, hard-fail when all are unknown); injected via ephemeral_system_prompt
  • hermes_cli/main.py: forward skills= through all three _run_and_exit_oneshot() call sites — including the top-level fast path added on main after the PR (sibling-site widening)
  • tests/hermes_cli/test_oneshot_skills.py: forwarding + partial-success contract tests

Validation

Before After
hermes -s github-pr-workflow -z "quote skill heading" NONE (skill absent) # GitHub Pull Request Workflow (live E2E)
targeted tests 13 passed (test_oneshot_skills.py + test_tui_resume_flow.py)

Duplicate cluster to close on merge: #31591 (salvaged, credit), #63814, #65249, #75930, #86173.

Infographic

oneshot skills fix infographic

@github-actions

github-actions Bot commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

૮ >ﻌ< ა ci review

ran on 74c3f05 — test: pin -z/--oneshot --skills forwarding and partial-succe

⚠️ Warnings

CI timings · View report · View job

Wall time 31m13s vs 3m55s (+697.0%). 12 job(s) slower, 10 faster, 2 unchanged.

  • Python tests / Run tests slice 9/12: +54.0s
  • Python tests / Run tests slice 7/12: +52.0s
  • Python tests / Run tests slice 1/12: -52.0s
  • Python tests / Run tests slice 3/12: -47.0s
  • Python tests / Run tests slice 10/12: -33.0s

OSV vulnerability scan · View job

7 known vulnerabilities found in pinned dependencies.

How to fix:

Review the findings in the Security tab. Update the affected dependencies if a patched version is available.

@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists comp/cli CLI entry point, hermes_cli/, setup wizard tool/skills Skills system (list, view, manage) labels Aug 20, 2026
@teknium1
teknium1 merged commit e73b851 into main Aug 20, 2026
86 of 88 checks passed
@teknium1
teknium1 deleted the fix/oneshot-skills-preload branch August 20, 2026 02:41
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 P2 Medium — degraded but workaround exists tool/skills Skills system (list, view, manage) type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

hermes -z (oneshot) discards --skills silently

3 participants