Skip to content

Comments

fix: preserve duplicate skills and expose scope in slash autocomplete#14518

Open
jaried wants to merge 3 commits intoanomalyco:devfrom
jaried:bug2_14506
Open

fix: preserve duplicate skills and expose scope in slash autocomplete#14518
jaried wants to merge 3 commits intoanomalyco:devfrom
jaried:bug2_14506

Conversation

@jaried
Copy link

@jaried jaried commented Feb 21, 2026

Issue for this PR

Closes #14506

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

This PR fixes skill discovery and slash command exposure when the same skill name exists in multiple scopes (system/user/project), which can hide valid skills during / lookup in Windows junction-based setups.

  • Keeps duplicate skills instead of dropping lower-priority entries.
  • Adds scope and duplicate metadata on skill records.
  • Exposes duplicate skill entries in command registration with unique internal keys while preserving command display names.
  • Surfaces scope hints in autocomplete descriptions for duplicate skill entries.
  • Adds a regression test that creates duplicate skill-creator skills in system and user scopes and verifies both are visible.

How did you verify your code works?

  • Added regression coverage in packages/opencode/test/skill/skill.test.ts.
  • Ran locally from packages/opencode:
    • bun test test/skill/skill.test.ts test/skill/discovery.test.ts test/tool/skill.test.ts
  • Environment result in this workspace: test process failed before assertions due missing dependency (Cannot find package 'zod'). CI validation is still required.

Screenshots / recordings

N/A (CLI behavior change)

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR


const clean = async () => {
const retry = new Set(["EBUSY", "EPERM", "ENOTEMPTY"])
for (let i = 0; i < 20; i++) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.

Skills fail to load when junction path is converted from Windows to Unix format

2 participants