Open local external docs through remote VS Code authorities - #23119
Open
M-Nabeegh wants to merge 1 commit into
Open
Open local external docs through remote VS Code authorities#23119M-Nabeegh wants to merge 1 commit into
M-Nabeegh wants to merge 1 commit into
Conversation
M-Nabeegh
force-pushed
the
codex/rust-analyzer-wsl-docs
branch
from
August 11, 2026 10:10
08f0f3b to
b28aaf5
Compare
M-Nabeegh
force-pushed
the
codex/rust-analyzer-wsl-docs
branch
from
August 11, 2026 10:22
b28aaf5 to
10ef92d
Compare
Contributor
|
Did you use AI for this? Please note that our AI policy:
|
Author
|
Hi! I’m a 4t year CS student, and my professor asked us to make an open-source contribution sooo I’m still learning the contribution process. I did use AI assistance while working on this PR, and I apologize for not disclosing that earlier. I understand the code and the changes I submitted, and I’ll make sure to follow the project’s AI policy properly going forward. Thank you for pointing this out and for your understanding. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #23057
What changed
Translate local documentation links returned by rust-analyzer for remote editors into host-openable links. WSL authorities use the host's
file://///wsl.localhost/<distro>/...UNC form so local HTML docs open in the default browser; other remote authorities usevscode-remote://links with a:1:1file position so VS Code opens the document instead of treating it as a folder. Local, web, and already-remote links keep their existing behavior.Why
The VS Code extension host can receive a local documentation path from the remote language server, but opening that
file://URI targets the wrong side of the connection. A remote protocol URL without a file position is also interpreted as a folder by VS Code.Validation
npm run format:checknpm run lintnpm run typechecknpm test(VS Code 1.93.0 with a short user-data directory)