GNU bug report logs - #58790
Eglot URI parsing bug when using clojure-lsp server

Previous Next

Package: emacs;

Reported by: Danny Freeman <danny <at> dfreeman.email>

Date: Wed, 26 Oct 2022 05:08:04 UTC

Severity: normal

Done: João Távora <joaotavora <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #140 received at 58790 <at> debbugs.gnu.org (full text, mbox):

From: Richard Copley <rcopley <at> gmail.com>
To: Danny Freeman <danny <at> dfreeman.email>
Cc: Felician Nemeth <felician.nemeth <at> gmail.com>, 58790 <at> debbugs.gnu.org,
 Michael Albinus <michael.albinus <at> gmx.de>,
 Stefan Kangas <stefankangas <at> gmail.com>, Dmitry Gutov <dgutov <at> yandex.ru>,
 Eli Zaretskii <eliz <at> gnu.org>,
 João Távora <joaotavora <at> gmail.com>
Subject: Re: bug#58790: Eglot URI parsing bug when using clojure-lsp server
Date: Wed, 23 Nov 2022 11:55:00 +0000
On 22/11/2022 14:30, Michael Albinus wrote:
> João Távora <joaotavora <at> gmail.com> writes:
> 
> Hi João,
> 
>>      Both seem to be OK, although I'm not sure that it is the right
>>      approach in eglot--path-to-uri just to concat "file://" and the
>>      file-local-name part of a remote file name.
>>
>> Can you describe a case where this would be problematic? Remember
>> that, from the point of view of the server, the file is always local.
>> That's regardless of whether eglot invoked the server remotely or
>> locally.
> 
> Got it.
> 
> Best regards, Michael.

Hi All,

For file names with a Windows drive letter and forward slashes (as 
emitted by CMAKE_EXPORT_COMPILE_COMMANDS), the drive letter is 
misinterpreted as a URL type, leading to repeated errors,
  "clangd only supports 'file' URI scheme for workspace files".


(let ((path "c:/projects/awesome-project/source/main.cpp"))
  (message "type %s, url %s"
           (url-type (url-generic-parse-url path))
           (eglot--path-to-uri path)))

;; => "type c, url c:/projects/awesome-project/source/main.cpp"





This bug report was last modified 2 years and 166 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.