Skip to content

fix(agent): use correct HOME for ~ expansion in skill config resolution#12736

Open
Tranquil-Flow wants to merge 1 commit into
NousResearch:mainfrom
Tranquil-Flow:fix/skill-config-home-expansion
Open

fix(agent): use correct HOME for ~ expansion in skill config resolution#12736
Tranquil-Flow wants to merge 1 commit into
NousResearch:mainfrom
Tranquil-Flow:fix/skill-config-home-expansion

Conversation

@Tranquil-Flow

@Tranquil-Flow Tranquil-Flow commented Apr 20, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Skill config path resolution could expand ~ against the wrong HOME in profile/container contexts. This PR routes skill config path expansion through the Hermes path helper so tilde expansion follows the intended Hermes environment.

Related Issue

Related to skill config path expansion under overridden Hermes homes.

Type of Change

  • 🐛 Bug fix (non-breaking change that fixes an issue)
  • ✨ New feature (non-breaking change that adds functionality)
  • 🔒 Security fix
  • 📝 Documentation update
  • ✅ Tests (adding or improving test coverage)
  • ♻️ Refactor (no behavior change)
  • 🎯 New skill (bundled or hub)

Changes Made

  • Use the shared Hermes path expansion helper in agent/skill_utils.py.
  • Adjust hermes_constants.py path expansion support.
  • Add regression tests for HOME-sensitive skill config expansion.

How to Test

  1. Check out this PR branch.
  2. Run: .venv/bin/python -m pytest -o 'addopts=' tests/agent/test_expand_hermes_path.py -q
  3. Expected result: 5 passed

Checklist

Code

  • I've read the Contributing Guide
  • My commit messages follow Conventional Commits (fix(scope):, feat(scope):, etc.)
  • I searched for existing PRs to make sure this isn't a duplicate
  • My PR contains only changes related to this fix/feature (no unrelated commits)
  • I've run pytest tests/ -q and all tests pass — focused pytest passed; full suite was not run in this salvage pass
  • I've added tests for my changes (required for bug fixes, strongly encouraged for features)
  • I've tested on my platform: Linux container / Python 3.11

Documentation & Housekeeping

  • I've updated relevant documentation (README, docs/, docstrings) — or N/A
  • I've updated cli-config.yaml.example if I added/changed config keys — or N/A
  • I've updated CONTRIBUTING.md or AGENTS.md if I changed architecture or workflows — or N/A
  • I've considered cross-platform impact (Windows, macOS) per the compatibility guide — or N/A
  • I've updated tool descriptions/schemas if I changed tool behavior — or N/A

Screenshots / Logs

Focused verification:

`.venv/bin/python -m pytest -o 'addopts=' tests/agent/test_expand_hermes_path.py -q` — 5 passed

@Tranquil-Flow Tranquil-Flow force-pushed the fix/skill-config-home-expansion branch from d49b256 to 3e18951 Compare April 20, 2026 01:13
@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists comp/agent Core agent loop, run_agent.py, prompt builder tool/skills Skills system (list, view, manage) labels Apr 23, 2026
@Tranquil-Flow Tranquil-Flow force-pushed the fix/skill-config-home-expansion branch 2 times, most recently from 40ada4f to ac62f4e Compare May 25, 2026 14:01
@Tranquil-Flow Tranquil-Flow force-pushed the fix/skill-config-home-expansion branch from ac62f4e to bbb91a2 Compare May 25, 2026 23:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/agent Core agent loop, run_agent.py, prompt builder 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.

2 participants