[BUG] Desktop (Windows): every claude://code/new?folder= link shows the workspace trust prompt, even for an already-trusted folder
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 55/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- electron, typescript
Research direction
Start by locating the main-process code/new handler and confirm where it adds src=external and forwards only q, folder, src, environment and runner_pool. Then trace the renderer path that decides whether to show the workspace trust prompt, and compare it with the LocalSessions.checkTrust and LocalSessions.saveTrust records described in the logs. Reproduce with Start-Process "claude://code/new?folder=...&q=hello" on a folder already trusted from the Code tab. Done means an already-trusted folder opens without the prompt, while an untrusted folder still asks once.
Written by the indexing model from the issue text.
Description
Environment
- Claude desktop 6.28899.2.0 (Windows 11, Microsoft Store/MSIX build)
- Claude Code 2.1.328 (bundled)
Summary
Every claude://code/new?folder=<path>&q=<prompt> link shows the workspace trust prompt for <path>. This happens even when the app has just reported the folder as trusted. Accepting the prompt does not stick: the next link to the same folder asks again.
Steps to reproduce
- Use a folder you already work in from the Code tab, so it is trusted (
main.logshowsLocalSessions.checkTrust: cwd=<folder>followed byLocalSessions.checkTrust: trusted=true). - From another process, open
claude://code/new?folder=<url-encoded absolute folder>&q=hello(for exampleStart-Process "claude://code/new?...", oros.startfile(url)in Python). - The new-session page asks you to trust
<folder>. Accept it. - Open the same link again.
Expected
No trust prompt for a folder that is already trusted, or at most one prompt per folder.
Actual
The prompt appears on every link. Each acceptance logs a new save for the same folder:
[info] LocalSessions.checkTrust: cwd=<folder>
[info] LocalSessions.checkTrust: trusted=true, sources=1
... (link opened: second-instance)
[info] LocalSessions.saveTrust: cwd=<folder>
[info] Saved workspace trust for <folder>
... (next link, a few minutes later)
[info] LocalSessions.saveTrust: cwd=<folder>
[info] Saved workspace trust for <folder>
About 14 hours of main.log contain 116 outside launches of the app (second-instance events, not counting resume links). 66 of them were followed by a saveTrust within two minutes, before the next launch. In 62 of those 66, no checkTrust line was logged between the launch and the save. One folder was saved three times in about eight minutes.
Notes from the bundled code (may be wrong)
- The main-process
code/newhandler appendssrc=externalwheneverfolder(or thessh_*parameters) is present. It forwards onlyq,folder,src,environmentandrunner_poolto the renderer, so a link cannot carry anything that affects trust. - The renderer then shows the trust prompt without consulting the stored trust that
checkTrustreports, or it reads a different record thansaveTrustwrites. - No setting turns this off.
Impact
Local tools that start Code sessions through claude://code/new (task runners, todo launchers) need a manual click on every launch, even in folders the user trusted long ago.
Request
Honor existing workspace trust for src=external links (the prompt is still right for folders that were never trusted), or add a setting that allows deep links into already-trusted folders without the prompt.
Related
- #106542 (macOS: the same handler drops
folderand shows no prompt at all) - #77750 (closed as stale: grant trust through settings or deep links)
- Dominant language
- TypeScript
- Stars
- 156k
- Forks
- 25k
- Avg merge
- 16h 19m
- Merged PRs (30d)
- 5
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- No pull request template
- No contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from anthropics/claude-code
-
area:vscode bug has repro platform:vscode platform:windows
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
anthropics/claude-code#111416 ·
-
area:plugins area:tui bug platform:macos
Difficulty 2/5 1-3 hours Newbie friendliness 73/100
anthropics/claude-code#111195 ·
-
area:docs area:security documentation enhancement platform:macos
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
anthropics/claude-code#111180 ·
-
area:ide enhancement platform:macos platform:vscode
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
anthropics/claude-code#111172 ·
-
area:mcp bug has repro platform:linux platform:wsl
Difficulty 2/5 1-3 hours Newbie friendliness 73/100
anthropics/claude-code#111077 ·
All issues in anthropics/claude-code
Similar issues
-
fix(resources): `flisk resources api` fails with a bare "too many arguments" and no hint; status, logs, down and networks already explain names are not positionalPossibly taken A pull request linked to this issue is open or already merged. Openarea: cli beginner beginner friendly bug community difficulty: easy dx easy first-timers-only good first issue hacktoberfest help wanted low-hanging fruit mentor available priority: P3 severity: low tech: typescript testing up-for-grabs ux
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
backlog-skill cat:docs documentation effort:s ready-for-agent sev:low
Difficulty 1/5 Under an hour Newbie friendliness 82/100
LucasSantana-Dev/Lucky#3284 ·
Maintainers usually reply within 1 day
-
.aif still missing from the pipeline and library MIME maps, AUDIO_INPUTS, and search aliasesPossibly taken A pull request linked to this issue is open or already merged. Openarea: backend bug priority: low
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
snapotter-hq/SnapOtter#5194 ·
Maintainers usually reply within 1 day
-
needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
homarr-labs/homarr#7671 ·
Maintainers usually reply within 1 day
-
clawsweeper:needs-maintainer-review clawsweeper:needs-product-decision clawsweeper:no-new-fix-pr clawsweeper:source-repro impact:ux-friction issue-rating: 🦞 diamond lobster P3
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
openclaw/openclaw#203385 · 1 comment · 1 reaction ·
Maintainers usually reply within 1 day