Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copilot panel fails on remote scp files #277

Open
Arakade opened this issue Feb 29, 2024 · 0 comments
Open

Copilot panel fails on remote scp files #277

Arakade opened this issue Feb 29, 2024 · 0 comments

Comments

@Arakade
Copy link

Arakade commented Feb 29, 2024

Reproduction

Edit a remote file using vim scp://user@myserver[:port]//path/to/file.txt syntax.
Attempting to open the Copilot panel.

Error

Result is Lua exception E95 "Buffer with this name already exists".

Cause and workaround / fix

Looks like lua/copilot/panel.lua panel_uri_from_doc_uri() assumes doc URL starts file://. Switching ^file:// to ^%a+:// seems to fix it (but I don't know other implications like are other URL schemes explicitly supposed to fail?)

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

No branches or pull requests

1 participant