Skip to content

fix(junie): normalize imported subagent names - #3943

Merged
dyoshikawa merged 1 commit into
dyoshikawa:mainfrom
521Peter:fix/junie-import-agent-name
Nov 24, 2026
Merged

dyoshikawa merged 1 commit into
dyoshikawa:mainfrom
521Peter:fix/junie-import-agent-name

Conversation

@521Peter

Copy link
Copy Markdown
Contributor

Refs #3888

Import Junie subagents using the name Junie actually exposes. Both an explicit name: Code Reviewer and a nameless Code Reviewer.agent.md currently import as Code Reviewer, whereas Junie calls the agent code-reviewer. This carries a different identifier into the shared subagent configuration when converting existing Junie agents to other tools.

Normalize the explicit or filename-derived name to lowercase and replace whitespace with hyphens when converting to a rulesync subagent, following the Junie file-format documentation. Keep the source filename and other frontmatter intact. This addresses the name-normalization item left out of #3892; nested discovery remains outside this change.

Validation:

  • The three new cases fail on the old implementation (Code Reviewer instead of code-reviewer). They cover explicit names and both .md and .agent.md fallbacks, including regeneration.
  • Targeted Junie subagent tests: 30 passed.
  • pnpm cicheck: code checks and all 619 test files passed (17,250 tests passed, 7 skipped). The content step initially stopped because its git diff --exit-code check sees unstaged documentation changes; after staging the synchronized docs, pnpm run cicheck:content passed in full.
  • pnpm build: passed.
  • Repository review-pr skill: separate code and security reviews found no blocking findings.

Found while checking the remaining work in #3888, rather than in personal use. AI assistance was used to inspect the implementation, write the regression tests and patch, and review the diff. I checked the changed lines and validation results. I did not run the Junie CLI itself; the normalization rule is verified against its documentation.

@dyoshikawa
dyoshikawa merged commit 4fb7cd9 into dyoshikawa:main Nov 24, 2026
7 checks passed
@dyoshikawa

Copy link
Copy Markdown
Owner

@521Peter Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants