You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BUG]: Skill discovery logs false "duplicate skill name" warnings when .claude/skills is a symlink to .agents/skills #31977
A common multi-agent convention is to keep one canonical skills directory and symlink the agent-specific paths to it, e.g.:
.agents/skills/ # canonical, shared by Claude Code / Codex / opencode
.claude/skills -> ../.agents/skills
opencode scans both .claude/skills and .agents/skills, does not resolve symlinks to a real path, and therefore discovers every skill twice — logging a WARN duplicate skill name per skill on every startup:
In a project with ~30 skills this produces ~30 warnings per session start, drowning out real log signal.
Note this is not the case fixed in #26709 — there the existing and duplicate paths were identical strings. Here the paths are different strings pointing at the same physical file through a symlinked directory, so the string-equality skip does not apply. #17219 reports the same root cause (no realpath dedup) in the permission scanner.
Steps to reproduce
mkdir -p repro/.agents/skills/demo-skill repro/.claude
cat > repro/.agents/skills/demo-skill/SKILL.md <<'SKILL'---name: demo-skilldescription: Demo skill for symlink dedup repro---Demo body.SKILL
ln -s ../.agents/skills repro/.claude/skills
cd repro && git init -q
opencode run 'hi'# then check the log:
grep 'duplicate skill name'~/.local/share/opencode/log/opencode.log | grep demo-skill
Expected behavior
Skill files reachable through more than one scan path should be deduplicated by resolved real path (fs.realpath) and produce no warning. Alternatively (or additionally) a config option to restrict skill discovery directories (#23035) would let users opt out of scanning one of the locations.
Environment
opencode 1.17.3 (also reproduced on earlier 1.17.x)
This issue might be a duplicate of existing issues. Please check:
Skill enumeration is non-deterministic when the same skill is reachable through multiple discovery roots #29950: Same root cause — skill discovery doesn't deduplicate by resolved real path when the same skill is reachable through multiple roots (e.g., .claude/skills/ symlinked to .agents/skills/). That issue focuses on the non-deterministic <location> URL in the system prompt, but the underlying fix (realpath dedup at discovery time) would address both.
If these are indeed the same root cause, it may make sense to consolidate. That said, the specific symptom here (startup WARN duplicate skill name spam) is distinct enough to track separately if the maintainers prefer.
Activity
github-actions commentedon Jun 12, 2026
This issue might be a duplicate of existing issues. Please check:
.claude/skills/symlinked to.agents/skills/). That issue focuses on the non-deterministic<location>URL in the system prompt, but the underlying fix (realpath dedup at discovery time) would address both.If these are indeed the same root cause, it may make sense to consolidate. That said, the specific symptom here (startup
WARN duplicate skill namespam) is distinct enough to track separately if the maintainers prefer.BacLuc commentedon Jun 14, 2026
I also had this issue. opencode web and opencode cli did not start.
They started as soon as i removed the symlink .claude -> .agents
github-actions commentedon Aug 14, 2026
To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.