[BUG] /agents Command Can't Edit Agents in Subdirectories

Resolved 💬 3 comments Opened Aug 2, 2025 by shawnsw Closed Jan 3, 2026

## Description
The /agents command can find and list agents in subdirectories within .claude/agents/, but fails
when trying to edit them.

## Steps to Reproduce

  1. Create agent files in subdirectories: .claude/agents/core/test-engineer.md
  2. Run /agents command - agents in subdirectories are listed correctly
  3. Try to edit an agent in a subdirectory
  4. Edit operation fails

## Expected Behavior

  • /agents should be able to edit agents regardless of subdirectory location
  • Should maintain the same editing workflow for nested agents as root-level agents

## Actual Behavior

  • Can successfully list/find agents in subdirectories
  • Edit operation (silently) fails for agents not in root .claude/agents/ directory
  • No error message or indication why edit failed

## Use Case
Organizing agents into logical groups while maintaining edit capability:
.claude/agents/
├── frontend/
│ ├── react-specialist.md # ✓ Found, ✗ Can't edit
│ └── nextjs-specialist.md # ✓ Found, ✗ Can't edit
└── backend/
├── fastapi-expert.md # ✓ Found, ✗ Can't edit
└── redis-expert.md # ✓ Found, ✗ Can't edit

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗