From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#58790: Eglot URI parsing bug when using clojure-lsp server Date: Wed, 23 Nov 2022 15:33:58 +0200 Message-ID: <83edttztfd.fsf@gnu.org> References: <9bb290c8-f000-31d8-265d-b5441c33eb38@dfreeman.email> <4d50b820-7053-75eb-5b11-d3d36a02b013@dfreeman.email> <87v8nxsrq6.fsf@gmail.com> <87cza40xgs.fsf@dfreeman.email> <83edubrvf0.fsf@gnu.org> <87cz9v9irh.fsf@gmail.com> <83o7terf9a.fsf@gnu.org> <87k042tqze.fsf@dfreeman.email> <87fseqtpiu.fsf@dfreeman.email> <875yfm8lzf.fsf@gmail.com> <83wn82osoo.fsf@gnu.org> <871qq8xfzr.fsf@gmx.de> <87mt8uwo2q.fsf@dfreeman.email> <87zgcs6nvb.fsf@gmx.de> <87r0y3luad.fsf@dfreeman.email> <87iljf72ua.fsf@gmx.de> <87a64qykcf.fsf@gmx.de> <8735ab12pr.fsf@gmx.de> <720bcf72-e944-4978-982f-4b6fa8b31e5c@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="34581"; mail-complaints-to="usenet@ciao.gmane.io" Cc: felician.nemeth@gmail.com, danny@dfreeman.email, 58790@debbugs.gnu.org, rcopley@gmail.com, michael.albinus@gmx.de, stefankangas@gmail.com, dgutov@yandex.ru To: =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Nov 23 14:35:21 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oxpuK-0008mt-Hi for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 23 Nov 2022 14:35:20 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oxpu5-0005kV-79; Wed, 23 Nov 2022 08:35:05 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oxpu2-0005kD-CA for bug-gnu-emacs@gnu.org; Wed, 23 Nov 2022 08:35:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oxpu2-0000CT-1s for bug-gnu-emacs@gnu.org; Wed, 23 Nov 2022 08:35:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oxpu1-0005ZN-L5 for bug-gnu-emacs@gnu.org; Wed, 23 Nov 2022 08:35:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 23 Nov 2022 13:35:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 58790 X-GNU-PR-Package: emacs Original-Received: via spool by 58790-submit@debbugs.gnu.org id=B58790.166921045221339 (code B ref 58790); Wed, 23 Nov 2022 13:35:01 +0000 Original-Received: (at 58790) by debbugs.gnu.org; 23 Nov 2022 13:34:12 +0000 Original-Received: from localhost ([127.0.0.1]:54172 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oxptD-0005Y7-Hq for submit@debbugs.gnu.org; Wed, 23 Nov 2022 08:34:11 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:44618) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oxptA-0005Xr-Op for 58790@debbugs.gnu.org; Wed, 23 Nov 2022 08:34:09 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oxpsl-00004u-Rz; Wed, 23 Nov 2022 08:34:01 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=VzCz4P9dkkZFAwGxwQj9xuaUJqJVfbLesux+JyEhsiY=; b=DyZsSBER3UGww5Q9ADIb bFs6wHhQP4pbHAK+7VjDYWVMhwJ32bZu9EiC0Qxj+pySW77P2XzjT6IdFHMuzMXj8+1wlPlHon8bJ HbiOEs1LQZZPH+q8A5HXqO3TsY1Q24CsIkx0Ik6UCl8H7Acl2EXgMTmkqH9zhWvW2hJj6nDWPJHCj 8Arqkp1A5i/oTG68Pu9o9ezVvzdJo0e1Oe33K64fcHI8tfswwfJE/Joe45nGHCoG5sunou7BqmmLO mWcuxcMyYeIPM8DM2D6s5clt77y5heWncmPwQCVlAXiVmYB0t62IlpPhhU3iBJ1Vf/CWxTSPOzoOk xD39ffscJpMR7A==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oxpsk-0006uY-E9; Wed, 23 Nov 2022 08:33:43 -0500 In-Reply-To: (message from =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= on Wed, 23 Nov 2022 12:36:37 +0000) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:248740 Archived-At: > From: João Távora > Date: Wed, 23 Nov 2022 12:36:37 +0000 > Cc: Danny Freeman , Felician Nemeth , > 58790@debbugs.gnu.org, Stefan Kangas , > Dmitry Gutov , Eli Zaretskii , > Michael Albinus > > Yes,I think I follow. To be clear I think the problem is somewhere in > > (defun eglot--path-to-uri (path) > "URIfy PATH." > (let ((truepath (file-truename path))) > (if (url-type (url-generic-parse-url truepath)) > ;; Path is already a URI, so forward it to the LSP server > ;; untouched. The server should be able to handle it, since > ;; it provided this URI to clients in the first place. > truepath > ...) > > So either url-generic-parse-url and url-type is fixed in url-parse.el, or > we must add some Windows-specific guards in eglot.el. Or likely > both, since url-parse.el is not a :core ELPA package. > > Richard/Danny, can you perhaps come up with some patch? >From where I stand, the solution was already proposed here: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=59338#53 You said you wanted to augment it with something that didn't depend on url-parse.el, because it wasn't in Emacs < 29, but I don't think I understand the concern, since AFAICT url-parse.el is in all versions of Emacs since at least Emacs 23. So what am I missing? In any case, I suggest that a solution be based on the patch shown in that bug#59338 discussion.