Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix: discover project-level Claude skills for the picker in the desktop app #4546

ClosedRido(GitHub profile, opens in a new tab)wants to merge 1 commit intomain fromrefs/pull/4546/headopened View on GitHub

What

Project-level Claude Code skills (<project>/.claude/skills/) now show up in the $ picker and / autocomplete for projects added via the UI in the desktop app. Previously only user-level skills (~/.claude/skills/) appeared there, even though project skills executed fine when invoked inside a thread.

Fixes #4544 (open packaged-desktop reproduction), fixes #2048, fixes #2416 (original report: #1283). Reproduced on 0.0.29-nightly.20260725.899, i.e. after #4414 landed.

Why #4414 didn't cover the desktop app

discoverClaudeSkills (added in #4414) is correct in itself, but it receives ServerConfig.cwd — the working directory of the T3 server process. That is only ever the user's repository in the npx t3-launched-from-inside-a-repo flow. In the desktop app the server cwd is unrelated to whatever project is open in the sidebar, so the project-scope scan silently found nothing. The snapshot is also global rather than per project, so even with a correct path, one project's skills would leak into every other project's picker.

How

  • New server.discoverProviderSkills RPC ({ instanceId, cwd } → { skills | null }) that re-runs skill discovery against the active project's own path (or worktree). skills: null means "this driver has no workspace-scoped discovery", so clients can distinguish that from "this project has no skills".
  • ProviderInstance gains an optional discoverSkills(cwd) capability. The Claude driver implements it as a closure over its instance config, reusing discoverClaudeSkills unchanged — the existing project-wins-on-collision rule and best-effort semantics apply as-is.
  • The web app resolves picker/timeline skills through a useWorkspaceProviderSkills hook keyed by the thread's workspace (project path or worktree), falling back to the snapshot's skills while loading, on older servers without the RPC, or for drivers that answer null.

The npx t3 flow is unchanged: the snapshot still scans the server cwd, and the per-workspace call returns the same result there.

Codex

The Codex driver has the same server-cwd assumption (#3040): its snapshot probe passes process.cwd() to the app-server skills/list call (CodexProvider.ts). Not touched here — Codex discovery goes through the app-server JSON-RPC client rather than the filesystem and deserves its own tests. The new per-instance discoverSkills capability is the seam to fix it separately.

Testing

  • ClaudeSkills.test.ts: new case covering two projects with different skill sets discovered against their own paths (not the process cwd), each seeing only its own project skills plus shared user skills — 7/7 passing.
  • server.test.ts: new end-to-end WebSocket RPC test verifying the requested cwd reaches discovery and that instances without the capability answer skills: null — all 20 ws routing tests passing.
  • Typecheck, oxlint, and formatting clean across contracts, client-runtime, server, and web.
  • Manually verified in the desktop app: project skills appear in the $ picker for a sidebar-added project whose path differs from the server cwd.

🤖 Generated with Claude Code


Note

Low Risk Read-scoped RPC and UI wiring with graceful fallbacks; no auth or persistence changes. Filesystem discovery is best-effort as before.

Overview Project-level Claude skills now show in the $ picker and composer when the desktop app’s open project path differs from the server process cwd.

Adds server.discoverProviderSkills (instanceId + workspace cwd → skills or skills: null). ProviderInstance gains optional discoverSkills(cwd); the Claude driver implements it via existing discoverClaudeSkills. The web app uses useWorkspaceProviderSkills (keyed by active project/worktree) in ChatView and ChatComposer, falling back to snapshot skills while loading, on older servers, or when the driver returns null.

Tests cover per-project isolation in ClaudeSkills.test.ts and WebSocket RPC routing in server.test.ts.

Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit ce84ea7fae8d248845b343bdcea2f3c1807b7804. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).
    1. coderabbitai[bot](GitHub profile, opens in a new tab)commented

      Important

      Review skipped

      Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

      ⚙️ Run configuration

      Configuration used: Repository UI

      Review profile: CHILL

      Plan: Pro Plus

      Run ID: 2e560cb5-5e0a-4735-ba7c-ef7f1d0c0ad1

      You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

      Use the checkbox below for a quick retry:

      • 🔍 Trigger review
      ✨ Finishing Touches
      🧪 Generate unit tests (beta)
      • Create PR with unit tests

      Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

      ❤️ Share
      Comment `@coderabbitai help` to get the list of available commands.
    2. github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:unvouched

    3. Approvability

      Verdict: Needs human review

      This PR introduces a new feature spanning multiple layers (new RPC endpoint, server method, client hook, UI integration) rather than a simple bug fix. The scope of new capability - workspace-scoped skill discovery affecting the desktop app's skill picker - warrants human review.

      You can customize Macroscope's approvability policy. [Learn more](https://docs.macroscope.com/approvability#example-custom-eligibility-rules).
    4. I need this to be merged its the only thing stopping me using t3 code

    5. Does this fix the issue for codex as well? that doesn't discover project skills either

    6. @t3dotgg @juliusmarminge Please could we get this in or another fix for project specific skill to be discovered for codex and claude? (I am using the mac desktop app)

    7. Very annoying issue. Please merge this ASAP.

    8. Note

      🤖 GPT-5.6 Sol responding on behalf of Theo

      Closing this PR after an automated pass over open pull requests. Repository-local Claude skill discovery already shipped in #5488.

Sign in to join this conversation.