bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#58790: Eglot URI parsing bug when using clojure-lsp server


From: Danny Freeman
Subject: bug#58790: Eglot URI parsing bug when using clojure-lsp server
Date: Sun, 13 Nov 2022 16:04:02 -0500

Michael Albinus <michael.albinus@gmx.de> writes:

> Well, using nil as operation might work in this special case, but it
> disables an important feature of file name handlers: use of
> inhibit-file-name-operation. That's why it shouldn't be documented as
> such.
>
> Using just an arbitrary symbol as operation looks better to me. If you
> use an existing operation name, like access-file, it could conflict later
> with the inhibit-file-name-operation/inhibit-file-name-handlers machinery.
>
> This said, I don't understand why you need this check at all. But I
> haven't followed the eglot discussion closely.
>
> Best regards, Michael.

Thanks for your insights Michael! If you are curious, this code in eglot
is about to round-aboutly call `find-file-noselect' on a URI, which
Emacs will probably fail to open if there is no registered file name
handler. So before doing that we write a message warning the user if no
file name handler is registered. That's the idea.

With this info I've written up another patch that checks
find-file-name-handler with an arbitrary symbol (with a better name than
my first attempt, IMO). I've tried to strike a balance between inline
comments and the commit message.

Attachment: 0001-Eglot-Warn-when-receiving-a-non-file-type-URI-bug-58.patch
Description: eglot file name handler warning patch

-- 
Danny Freeman

reply via email to

[Prev in Thread] Current Thread [Next in Thread]