From unknown Fri Jun 20 19:54:21 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#62198 <62198@debbugs.gnu.org> To: bug#62198 <62198@debbugs.gnu.org> Subject: Status: [PATCH] Eglot: Send clientInfo during the initialize request Reply-To: bug#62198 <62198@debbugs.gnu.org> Date: Sat, 21 Jun 2025 02:54:21 +0000 retitle 62198 [PATCH] Eglot: Send clientInfo during the initialize request reassign 62198 emacs submitter 62198 Felician Nemeth severity 62198 normal tag 62198 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 15 07:54:07 2023 Received: (at submit) by debbugs.gnu.org; 15 Mar 2023 11:54:07 +0000 Received: from localhost ([127.0.0.1]:39225 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pcPhn-0008LD-1m for submit@debbugs.gnu.org; Wed, 15 Mar 2023 07:54:07 -0400 Received: from lists.gnu.org ([209.51.188.17]:34612) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pcPhl-0008L6-LU for submit@debbugs.gnu.org; Wed, 15 Mar 2023 07:54:06 -0400 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 1pcPhl-0002Xo-Ey for bug-gnu-emacs@gnu.org; Wed, 15 Mar 2023 07:54:05 -0400 Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pcPhj-0005Pm-ID for bug-gnu-emacs@gnu.org; Wed, 15 Mar 2023 07:54:05 -0400 Received: by mail-wm1-x32b.google.com with SMTP id o11-20020a05600c4fcb00b003eb33ea29a8so1008162wmq.1 for ; Wed, 15 Mar 2023 04:54:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1678881241; h=mime-version:face:user-agent:message-id:date:subject:to:from:from :to:cc:subject:date:message-id:reply-to; bh=3CTEUkFPEjV/JsHL51EhPNDHO3lrI0kbG/qFQY4iCus=; b=O8mkeG4KNhZ9btRg5A+mmquPxx+H+KjHwt33EH+ARGHB8Kis7Y/pFdSNilxuEf4SO4 klzUAuq5YijO9nBTRyP/kMRnAl8OXYLCa8dZnwipkv1TXGV6D+qwGZiVoFfs4MNH2l25 kLa/82X+qMcU7+pgigWXdzBqvbWaX9DLkpzJZ5iXiwGWuyzH+A5VfC30KMpXX3lXihCW PDmJCIQX5aPUPWjS74bESDUfwdA3gYV8gKsrgwEGmXmPfrqnXeSuP1jV2lE6pW5TFSWd G00dAicmM5zeOahKQdK3oqZM9rTCZPS8y1fiBRqnGfrXuNQ+PApDxjzYrAgTCyVl9QTp keIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678881241; h=mime-version:face:user-agent:message-id:date:subject:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=3CTEUkFPEjV/JsHL51EhPNDHO3lrI0kbG/qFQY4iCus=; b=PxDBWcHdcvE9olh7MYiEqgtMMqh+XQvObcNPxlDx5zbdWQcZag6q0F/BgOnHYWHszx KR6tKv6eaiRVI7JParYSlzyK9spOQd3BElZi08sZuD599974W/0w1WQ3EkKSEE8AWz1a 4oHxY+9MJOLwYjOYObSuwNGVkmchn4aZd7Z5DknvsXEEb44jnFRLWNx29ZGDGnSJPjcu QQR3t65+bAH6U95oVDMmY6p7ywZHBOsSyekHShd50ivAv5gEuFJ0SSqnIJQzy1AYqaIp Jo5LOLll0c1RkxgPD7BywnsWWaVODrZOdFz/YxG+yQfDPv2aNQ/sbTOjhx0qzwE2zbJf ffxA== X-Gm-Message-State: AO0yUKUJfytqf1xx/Tp06tN2aRCu9t6PnNYUc5SLoLuxJOF3mRm7a2wA HOCx4mxkjqolwWgbY83PFVNBhClwHhA= X-Google-Smtp-Source: AK7set9/piEGZbiJdG9MHKeqL+UtdJRAJ2qazXTqmWE4SgrGd0yYgDVIBywl30Dii+UeUwv2m5qrJQ== X-Received: by 2002:a05:600c:4f91:b0:3eb:3908:8541 with SMTP id n17-20020a05600c4f9100b003eb39088541mr18046239wmq.2.1678881241039; Wed, 15 Mar 2023 04:54:01 -0700 (PDT) Received: from betli.gmail.com (catv-86-101-66-128.catv.fixed.vodafone.hu. [86.101.66.128]) by smtp.gmail.com with ESMTPSA id l10-20020a5d560a000000b002cfeffb442bsm2575804wrv.57.2023.03.15.04.54.00 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 15 Mar 2023 04:54:00 -0700 (PDT) From: Felician Nemeth To: bug-gnu-emacs@gnu.org Subject: [PATCH] Eglot: Send clientInfo during the initialize request X-Debbugs-CC: joaotavora@gmail.com Date: Wed, 15 Mar 2023 12:53:58 +0100 Message-ID: <87v8j28c2x.fsf@betli.tmit.bme.hu> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAADFBMVEX5+fmhoaEwMDD/ ///TMNVWAAAAAWJLR0QDEQxM8gAAAAlwSFlzAAAPEgAADxIBIZvyMwAAAAd0SU1FB+AICBUfHgLs gGoAAAGXSURBVCjPRdK/b5tAFAfw753gBEwM2ApMbuVIqf+Ko0qiyhOu4sj2xJBYMn/FUdX7UUUZ OjHgyvf+yj6IcW6Bjx53934ADEvs8bmEr8UVoTYTOyJO9KoYsVofN8kILdbeJ8Li6YpZWop4xOK0 VdfIoXmkHn5/5D7/Ts/8THacSqnkKTcMTxgUkVzFnEIRTKwwYYSCvzfg16f0i8YApW/XG/Pm8R49 dXjxKmRnxv3OwooQWcv4RUYem1fsNe/WU63uk7AmYxk78y32/ee2tZB4fO+WcZ7lnIGEolXW1EGw LfkSuQ0XTgRefgNlfNwRNV6QhBxJ8JNxTMUPyBqTd0bjaAP5G7NJRU39z80hLOZTjqB7K3tEEFSj aEsuQew6qBxxyhHjVUR7H7NpC9iHJZGLMCEuweqAqE1BHbfK2oRIz9EHYA/+wiFWru9smeVfuWNZ 2+NFtX80UA1TvJNdytM4DwO4kY7bJz8Qcd0G0ceslZGkkeoBsjUHwF1+jjM3XHaXEZ7mGLfwPFO+ RV9QLY2iEdmDo78D/gNPaXVYqd+pyQAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAxNi0wOC0wOFQyMzoz MDoyOCswMjowMGy/yHYAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMTYtMDgtMDhUMjM6MzA6MjgrMDI6 MDAd4nDKAAAAAElFTkSuQmCC MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Received-SPF: pass client-ip=2a00:1450:4864:20::32b; envelope-from=felician.nemeth@gmail.com; helo=mail-wm1-x32b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable I originally posted this patch on github: https://github.com/joaotavora/eglot/pull/818 Jo=C3=A3o requested to resubmit it here. To recap: clientInfo arrived in LSP 3.15.0. LSP clients can use clientInfo to identify themselves in the initialize request. This is generally useful for various debugging tasks. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-Eglot-Send-clientInfo-during-the-initialize-request.patch >From 5fe9d054845382ce74c29bb338ffc737b0770542 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felici=C3=A1n=20N=C3=A9meth?= Date: Wed, 15 Mar 2023 12:34:06 +0100 Subject: [PATCH] Eglot: Send clientInfo during the initialize request clientInfo arrived in LSP 3.15.0. LSP clients can use clientInfo to identify themselves in the initialize request. This is generally useful for various debugging tasks. * lisp/progmodes/eglot.el (eglot--version): New defconst. (eglot--connect): Send clientInfo using eglot--version. * test/lisp/progmodes/eglot-tests.el (eglot-test-client-info): New test. --- lisp/progmodes/eglot.el | 12 ++++++++++++ test/lisp/progmodes/eglot-tests.el | 18 ++++++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el index 037cc87148..f89c47ac4f 100644 --- a/lisp/progmodes/eglot.el +++ b/lisp/progmodes/eglot.el @@ -410,6 +410,14 @@ eglot-withhold-process-id ;;; Constants ;;; +(defconst eglot--version + (eval-when-compile + (when byte-compile-current-file + (require 'lisp-mnt) + (lm-version byte-compile-current-file))) + "The version as a string of this version of Eglot. +It is nil if Eglot is not byte-complied.") + (defconst eglot--symbol-kind-names `((1 . "File") (2 . "Module") (3 . "Namespace") (4 . "Package") (5 . "Class") @@ -1310,6 +1318,10 @@ eglot--connect (eq (jsonrpc-process-type server) 'network)) (emacs-pid)) + :clientInfo (if eglot--version + `(:name "Eglot" + :version ,eglot--version) + '(:name "Eglot")) ;; Maybe turn trampy `/ssh:foo@bar:/path/to/baz.py' ;; into `/path/to/baz.py', so LSP groks it. :rootPath (file-local-name diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eglot-tests.el index b95e527c51..f17b96848f 100644 --- a/test/lisp/progmodes/eglot-tests.el +++ b/test/lisp/progmodes/eglot-tests.el @@ -399,6 +399,24 @@ eglot-test-auto-reconnect (while (process-live-p proc) (accept-process-output nil 0.5))) (should (not (eglot-current-server))))))) +(ert-deftest eglot-test-client-info () + "Check clientInfo in Eglot's initialize request." + (skip-unless (executable-find "pylsp")) + (eglot--with-fixture + `(("project" . (("coiso.py" . "def coiso: pass")))) + (with-current-buffer + (eglot--find-file-noselect "project/coiso.py") + (eglot--sniffing (:client-requests c-reqs) + (should (eglot--tests-connect 10)) + (eglot--wait-for (c-reqs 10) + (&key _id method params &allow-other-keys) + (when (string= method "initialize") + (let* ((clientInfo (plist-get params :clientInfo)) + (name (plist-get clientInfo :name)) + (version (plist-get clientInfo :version))) + (should (equal name "Eglot")) + (should (version<= "1.8" (or version "0")))))))))) + (ert-deftest eglot-test-rust-analyzer-watches-files () "Start rust-analyzer. Notify it when a critical file changes." (skip-unless (executable-find "rust-analyzer")) -- 2.30.2 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 15 16:36:18 2023 Received: (at 62198) by debbugs.gnu.org; 15 Mar 2023 20:36:18 +0000 Received: from localhost ([127.0.0.1]:40618 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pcXr8-00015S-Bu for submit@debbugs.gnu.org; Wed, 15 Mar 2023 16:36:18 -0400 Received: from mail-wm1-f53.google.com ([209.85.128.53]:41532) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pcXr5-00015C-UC for 62198@debbugs.gnu.org; Wed, 15 Mar 2023 16:36:16 -0400 Received: by mail-wm1-f53.google.com with SMTP id r19-20020a05600c459300b003eb3e2a5e7bso2119060wmo.0 for <62198@debbugs.gnu.org>; Wed, 15 Mar 2023 13:36:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1678912569; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=+FQvPtCc+rWP5fxM2uqfCggdFdE6PWX47EwxPxSMPqU=; b=WKhu5AY3EWnNPUvAD8pdAN6JWqoUJVDv4iGhLm3JN4vwK/RNBVkpq2UKhZuxBAbCLN dZTQAugxRoAk9YEgxBH2YNNImTeGWebWbz0eezzK8yzAhldMKMwF3qEhAZni1qTt1Ieq VYKBxt3XT97ip+K6+pOKMaf3Hj4xcIt4zHfzITEbcFCSRNhLXpmvz4Cm3g+jU6G273Ck 0SVxvxpLcztNhdCVL5th6jyPyqeIaVsmtvC6BJNPSTHJjmHIdtB1o47I7s+KT+OiDx65 kgLABNuEDn3cq92gOEQcBUhPsz0ssSc+tNntahYqCWHnlVUBf5Nt6/ibl6kyRWBwHzJx XiZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678912569; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=+FQvPtCc+rWP5fxM2uqfCggdFdE6PWX47EwxPxSMPqU=; b=Vf02kIPiP8mBHdMSO/aUPl03PiN77Ci8/Rsv/wejJPx0wdbLuFD1NxZLXPZ1khs16C rpZIsMFTG+PVxz+YLZqfeN7aapKou9dUnqTiHZDV8ySWmt2L4FysJfFUgeo36ZU1mLHa ta0Ur5pu+u49D1I8QtEouEZBgE0fjZSDY/o10ByyP6OenxF28mFeqD+RtlvGP5zwt/GT Lxfi4vmKt2GR7hJa4HMItW047la4zJ8luI/7TdqQW6tyelLdFMnLDLSWPzc+4d2JIxv9 DhNVhus9AxlFGqradai13bCUwB47Z6L6GHGPudB8jw4zfFv4r+Wvogd5a66s8Jg4o5KD qemQ== X-Gm-Message-State: AO0yUKW0T5cYg6x88JJ0VKIeiUlmrg/0gQ2eZGIVwXHiXQjV1SBp0pCs p2ZQPFSozObQ20+vS1aHNzKYONrILpI= X-Google-Smtp-Source: AK7set/PdtsGC2SAidUr12Li0iiVlGRQhAZ50Kdl7hYaBW9iKN2ZBhIm0phhl3WazXjezmr7cTviCw== X-Received: by 2002:a05:600c:1c27:b0:3ed:2619:6485 with SMTP id j39-20020a05600c1c2700b003ed26196485mr10507620wms.3.1678912569683; Wed, 15 Mar 2023 13:36:09 -0700 (PDT) Received: from krug (87-196-72-142.net.novis.pt. [87.196.72.142]) by smtp.gmail.com with ESMTPSA id o9-20020a05600c4fc900b003ea57808179sm3322458wmq.38.2023.03.15.13.36.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 15 Mar 2023 13:36:09 -0700 (PDT) From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: Felician Nemeth Subject: Re: bug#62198: [PATCH] Eglot: Send clientInfo during the initialize request In-Reply-To: <87v8j28c2x.fsf@betli.tmit.bme.hu> (Felician Nemeth's message of "Wed, 15 Mar 2023 12:53:58 +0100") References: <87v8j28c2x.fsf@betli.tmit.bme.hu> Date: Wed, 15 Mar 2023 20:38:10 +0000 Message-ID: <87pm994uod.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Felician Nemeth writes: > I originally posted this patch on github: > https://github.com/joaotavora/eglot/pull/818 > > Jo=C3=A3o requested to resubmit it here. > > To recap: clientInfo arrived in LSP 3.15.0. LSP clients can use > clientInfo to identify themselves in the initialize request. This is > generally useful for various debugging tasks. > > From 5fe9d054845382ce74c29bb338ffc737b0770542 Mon Sep 17 00:00:00 2001 > From: =3D?UTF-8?q?Felici=3DC3=3DA1n=3D20N=3DC3=3DA9meth?=3D > Date: Wed, 15 Mar 2023 12:34:06 +0100 > Subject: [PATCH] Eglot: Send clientInfo during the initialize request > > clientInfo arrived in LSP 3.15.0. LSP clients can use clientInfo to > identify themselves in the initialize request. This is generally > useful for various debugging tasks. > > * lisp/progmodes/eglot.el (eglot--version): New defconst. > (eglot--connect): Send clientInfo using eglot--version. > * test/lisp/progmodes/eglot-tests.el > (eglot-test-client-info): New test. > --- > lisp/progmodes/eglot.el | 12 ++++++++++++ > test/lisp/progmodes/eglot-tests.el | 18 ++++++++++++++++++ > 2 files changed, 30 insertions(+) > > diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el > index 037cc87148..f89c47ac4f 100644 > --- a/lisp/progmodes/eglot.el > +++ b/lisp/progmodes/eglot.el > @@ -410,6 +410,14 @@ eglot-withhold-process-id > > ;;; Constants > ;;; > +(defconst eglot--version > + (eval-when-compile > + (when byte-compile-current-file > + (require 'lisp-mnt) > + (lm-version byte-compile-current-file))) > + "The version as a string of this version of Eglot. > +It is nil if Eglot is not byte-complied.") I'm not familiar with this lisp-mnt.el library. Is it the kosher way to get version introspection for Elisp libs? Why is it nil if Eglot is not byte-compiled, couldn't we get it by looking at load-file-name? Can we somehow get the Emacs.git SHA in there as well? > @@ -1310,6 +1318,10 @@ eglot--connect > (eq (jsonrpc-process-type server) > 'network)) > (emacs-pid)) > + :clientInfo (if eglot--version > + `(:name "Eglot" > + :version ,eglot--version) > + '(:name "Eglot")) I'd rather just :name "Eglot" :version "unknown" if we don't have it. > + (eglot--with-fixture > + `(("project" . (("coiso.py" . "def coiso: pass")))) > + (with-current-buffer > + (eglot--find-file-noselect "project/coiso.py") > + (eglot--sniffing (:client-requests c-reqs) > + (should (eglot--tests-connect 10)) > + (eglot--wait-for (c-reqs 10) > + (&key _id method params &allow-other-keys) > + (when (string=3D method "initialize") > + (let* ((clientInfo (plist-get params :clientInfo)) > + (name (plist-get clientInfo :name)) > + (version (plist-get clientInfo :version))) > + (should (equal name "Eglot")) > + (should (version<=3D "1.8" (or version "0")))))))))) Thanks. Do we really need a test for this? I suppose it's good practice, but seems a but too much. We could put this check in some other "basic" test, save a bit of time. Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 16 12:47:14 2023 Received: (at 62198) by debbugs.gnu.org; 16 Mar 2023 16:47:14 +0000 Received: from localhost ([127.0.0.1]:42812 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pcql0-0005kk-8y for submit@debbugs.gnu.org; Thu, 16 Mar 2023 12:47:14 -0400 Received: from mail-wm1-f47.google.com ([209.85.128.47]:43811) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pcqky-0005kW-GC for 62198@debbugs.gnu.org; Thu, 16 Mar 2023 12:47:13 -0400 Received: by mail-wm1-f47.google.com with SMTP id p13-20020a05600c358d00b003ed346d4522so1609936wmq.2 for <62198@debbugs.gnu.org>; Thu, 16 Mar 2023 09:47:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1678985226; h=mime-version:face:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=TsFzjCEM8EeSFVtmxx2x3xyHUMz8udln6Rv6sVZvntw=; b=Fe+u6rr7fT903PVchp8iyzt4AX/IrD8TIdOR18D9roL/izbehcOsw5LJ5Rl6XM2nWx jus5ZO2a/lE9ew9C0zTV+2Rso8fiMBZQarH5TJe3C/HvAUuCsi1HeF7LwBeHw2q+5j3P Fy17OywR00MmHhhchO10oQpSUzLSijRgU1toGDPiRV9VyFeK4rbgB0mfzgiYRTV3INRx yzPDynFoQbPvqmgw/O2n6ZSX3y1zCCx+P/XololtUzKt5/nx5z+FdHp28l8L3ZI4lLuO J1czFxeqHX6Y8AGaKpEoaNYYncz5DUoa4vlr7QrA7JFgn0BzWZNLSQ4lEfNO2gn7SZYY gX8Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678985226; h=mime-version:face:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=TsFzjCEM8EeSFVtmxx2x3xyHUMz8udln6Rv6sVZvntw=; b=Q3Y3t5U6cvZBjIGCR6arHehAfnXbz3CSDWKOtuFRCd1g3cfL6f6rgrZvX8dALT07xN Z5MdIh80I9/4ObY5aDMqq8kzPua59/FXJLqaxZbAJd8F93ofHCEtlHfPnBWcdJc/Pm62 35jQCHsh1b5p93A4LDwLq1TlMftyNEJ1QGdbpuDbkaqOx8PTNzzmdcwH64DvvZMO0B3X TCtJj4KYSQygZ2Ps/okYbZdFgeuswi3nCNG/fqjOIVo+grdoQoDOF72rSD1SJ7dri/JK Xa1+y+H9Twoo9SunVgUcudwKszPpNMkTKan1u9KINSH7TlzLwI5WN17UjOftakzPwZMg G8Rg== X-Gm-Message-State: AO0yUKVaZeiIAGJATmrVAwsdEeec0E2Q0rD+BgpcuUIWsX4pCbYe3U9Z wdAcptdbomspJ/Yc9Ou4nQXy9i03QgE= X-Google-Smtp-Source: AK7set9KfSNUpgHHcgupvkQ7CEDNGtlh8f2FxV58ap+VlL2Ih+eC1+Z7rgwO/Jcr6n1gKJSBqAClkQ== X-Received: by 2002:a05:600c:b8c:b0:3ed:2f1a:883c with SMTP id fl12-20020a05600c0b8c00b003ed2f1a883cmr9864287wmb.14.1678985226220; Thu, 16 Mar 2023 09:47:06 -0700 (PDT) Received: from betli.gmail.com (catv-86-101-66-128.catv.fixed.vodafone.hu. [86.101.66.128]) by smtp.gmail.com with ESMTPSA id u13-20020a7bc04d000000b003eb0d6f48f3sm5412880wmc.27.2023.03.16.09.47.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 16 Mar 2023 09:47:05 -0700 (PDT) From: Felician Nemeth To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Subject: Re: bug#62198: [PATCH] Eglot: Send clientInfo during the initialize request References: <87v8j28c2x.fsf@betli.tmit.bme.hu> <87pm994uod.fsf@gmail.com> Date: Thu, 16 Mar 2023 17:47:03 +0100 In-Reply-To: <87pm994uod.fsf@gmail.com> (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vor?= =?utf-8?Q?a=22's?= message of "Wed, 15 Mar 2023 20:38:10 +0000") Message-ID: <87edpo8wzc.fsf@betli.tmit.bme.hu> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAFVBMVEU2EgDVmFNHKAa4dz4q AwCDUSH2zWrE61tmAAACeklEQVQ4jU2UwY7jIAyGEZN5ABSFc9Ytcx6K6DmqmHsD8tyZKrz/I+xv yI6WKlHlj982tomiVckiWrUrgRU5jlqMpJKCkch5W419DQAiQGHDxdrWmm0/2kXCApiUmrZLq20s cjexq3VL25QuxjY7wOcJVEpb+jLeGLAK+OMyaa1hx9rFbkwHFWBVA2y8w1wHaLE7GuDdw5cEuOM5 SLIdrpwBkN0ezwI7nYoiilqthbcYc89KgC5+NnaOHGbZz0T6BCEgOLJ0vmYXuNdPAIXgDZJhF2Yu fjnPNwAsoUTUN/P8q3AAyz4zB/xmifEfiIbvS4jh7b7QqZiSm4MJC5kXNpCRaOsoyQXAMN2XCJfs j94NKfo7ACKUEgKE3y+Sg4jibUZ1A0jgYpxtvYMC3gHaHPq6x32ACeALIZoZxB+l9VrRNIA1ncRg wwC8pvQIvYO+a2yt3VXMVyli6L0VV6aOrJa4CpilVQA+eHt0xavk61akih5BUMay/0BAqu783C5h FifY/3QsAIoWYk6PgpwAzLI652+96e2IfN2cF+BD1uT23F21Ghh5OUl4RlO15oh5A2iv+Zk2wsjZ 2DtB5Sm3A4P0+kyb2vs4iEW7G9ohoN3Stl2kVat6MCkXldo6OKaE8P6GhmrKKxWZXQH1iklhhn+d iVeNf6mDdkV0ltFwApRbp+kXSGBFHGV2aPqnIIyQyzhD5n47khqKI08bIapcas4O+hPkct20NAEv ALRuZFUp3PrnQSAm+4lTdHCsYYZ/nGqQrM5z3NS3zefFxkfFPRFbsjpIfbTlvF3ibpVZQ9nzqv60 F/KXSRLJ1AGappJulZll70N/qz6EfwEOCdYOuTHAzAAAAABJRU5ErkJggg== MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain >> +(defconst eglot--version >> + (eval-when-compile >> + (when byte-compile-current-file >> + (require 'lisp-mnt) >> + (lm-version byte-compile-current-file))) >> + "The version as a string of this version of Eglot. >> +It is nil if Eglot is not byte-complied.") > > I'm not familiar with this lisp-mnt.el library. Is it the kosher way to > get version introspection for Elisp libs? I haven't found the prior art for this. trampver.el repeats the header info, so when the version changes it should be updated two places, which (I think) is an antipattern. For "normal" users, Eglot should come with Emacs or be installed from ELPA. In both cases, Eglot is byte-compiled. > Why is it nil if Eglot is not byte-compiled, couldn't we get it by > looking at load-file-name? Yes, that's a possibily, but that won't be perfect either. I tend to eval-buffer when I work on Eglot. > Can we somehow get the Emacs.git SHA in there as well? There is `emacs-repository-get-version', but according to its docstring it doesn't work all the time. trampver.el is a good example how complicated its usage. Do you intend to rely on the clientInfo in bug reports? I think it's safer to ask for the exact details if the user is running a not released version. >> + :clientInfo (if eglot--version >> + `(:name "Eglot" >> + :version ,eglot--version) >> + '(:name "Eglot")) > > I'd rather just :name "Eglot" :version "unknown" if we don't have it. "Version" is optional. I think it shouldn't be specified if it is unknown. Nevertheless, I updated the patch to send "unknown" in this case. > Do we really need a test for this? I wrote the test after Stefan's implicit request. I'm OK with not having a test. > I suppose it's good practice, but > seems a but too much. We could put this check in some other "basic" > test, save a bit of time. I've updated the patch. It now extends another test. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-Eglot-Send-clientInfo-during-the-initialize-request.patch >From ed48b73457048f89bb5132eefc2c3d2fa94e68f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felici=C3=A1n=20N=C3=A9meth?= Date: Wed, 15 Mar 2023 12:34:06 +0100 Subject: [PATCH] Eglot: Send clientInfo during the initialize request clientInfo arrived in LSP 3.15.0. LSP clients can use clientInfo to identify themselves in the initialize request. This is generally useful for various debugging tasks. * lisp/progmodes/eglot.el (eglot--version): New defconst. (eglot--connect): Send clientInfo using eglot--version. * test/lisp/progmodes/eglot-tests.el (eglot-test-basic-diagnostics): Test clientInfo as well. --- lisp/progmodes/eglot.el | 10 ++++++++++ test/lisp/progmodes/eglot-tests.el | 18 +++++++++++++++--- 2 files changed, 25 insertions(+), 3 deletions(-) diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el index 037cc87148..8ca0db85a7 100644 --- a/lisp/progmodes/eglot.el +++ b/lisp/progmodes/eglot.el @@ -410,6 +410,15 @@ eglot-withhold-process-id ;;; Constants ;;; +(defconst eglot--version + (or (eval-when-compile + (when byte-compile-current-file + (require 'lisp-mnt) + (lm-version byte-compile-current-file))) + "unknown")) + "The version as a string of this version of Eglot. +It is \"unknown\" if Eglot is not byte-complied.") + (defconst eglot--symbol-kind-names `((1 . "File") (2 . "Module") (3 . "Namespace") (4 . "Package") (5 . "Class") @@ -1310,6 +1319,7 @@ eglot--connect (eq (jsonrpc-process-type server) 'network)) (emacs-pid)) + :clientInfo `(:name "Eglot" :version ,eglot--version) ;; Maybe turn trampy `/ssh:foo@bar:/path/to/baz.py' ;; into `/path/to/baz.py', so LSP groks it. :rootPath (file-local-name diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eglot-tests.el index b95e527c51..a2ca35bd7d 100644 --- a/test/lisp/progmodes/eglot-tests.el +++ b/test/lisp/progmodes/eglot-tests.el @@ -435,15 +435,27 @@ eglot-test-rust-analyzer-watches-files (= type 3)))))))))) (ert-deftest eglot-test-basic-diagnostics () - "Test basic diagnostics." + "Test basic diagnostics and clientInfo." (skip-unless (executable-find "clangd")) (eglot--with-fixture `(("diag-project" . (("main.c" . "int main(){froat a = 42.2; return 0;}")))) (with-current-buffer (eglot--find-file-noselect "diag-project/main.c") - (eglot--sniffing (:server-notifications s-notifs) - (eglot--tests-connect) + (eglot--sniffing (:server-notifications s-notifs + :client-requests c-reqs) + (eglot--tests-connect) + ;; Test clientInfo sent by Eglot. + ;; This simple test included here to save some time. + (eglot--wait-for (c-reqs 10) + (&key _id method params &allow-other-keys) + (when (string= method "initialize") + (let* ((clientInfo (plist-get params :clientInfo)) + (name (plist-get clientInfo :name)) + (version (plist-get clientInfo :version))) + (should (equal name "Eglot")) + (should (version<= "1.8" version))))) + ;; Test basic diagnostics. (eglot--wait-for (s-notifs 10) (&key _id method &allow-other-keys) (string= method "textDocument/publishDiagnostics")) -- 2.30.2 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 17 04:25:32 2023 Received: (at 62198) by debbugs.gnu.org; 17 Mar 2023 08:25:32 +0000 Received: from localhost ([127.0.0.1]:43586 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pd5P1-0007hy-RY for submit@debbugs.gnu.org; Fri, 17 Mar 2023 04:25:32 -0400 Received: from mout.gmx.net ([212.227.15.19]:38391) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pd5Oz-0007hh-Dn for 62198@debbugs.gnu.org; Fri, 17 Mar 2023 04:25:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1679041522; i=michael.albinus@gmx.de; bh=lWPYYhvr1WHOIKIvz6TTJpvW1wxsB15CR7qbGsfLrnQ=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=fTWJ6SJFDsQo/3n6yO6WaIH7VuXPzJJDuLM5u/BSN7BBaKTdfO1bzwy39ulKNpq+G rfuOFv2DFS/ZTk+VQAV0uZWA1QU8YPmMZ0obrisjqNiqtfS1tSRNVZTLmtXZOrv/cm u4IfrN6kfYFHDaJprtvh5PovGB8WnanhBDX326krBiNVTB5NUbzXZ/ofG/o+syazcC BFwG6E2l26NbZtlgFkA3DbAgOXdyURVF/VMKFm6RUlGLmBf9Aw9Z3PJ/rwonDIPD/r jGHxJVB351UsTDtAnhUPNhNBer06UmQ9OJ2nvnrqO0CBcqUbr/0ln/E9FsUjFm4yW1 IwjOtqk/y/u4w== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.19]) by mail.gmx.net (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MowGa-1qISom2PMM-00qPjg; Fri, 17 Mar 2023 09:25:22 +0100 From: Michael Albinus To: Felician Nemeth Subject: Re: bug#62198: [PATCH] Eglot: Send clientInfo during the initialize request In-Reply-To: <87edpo8wzc.fsf@betli.tmit.bme.hu> (Felician Nemeth's message of "Thu, 16 Mar 2023 17:47:03 +0100") References: <87v8j28c2x.fsf@betli.tmit.bme.hu> <87pm994uod.fsf@gmail.com> <87edpo8wzc.fsf@betli.tmit.bme.hu> Date: Fri, 17 Mar 2023 09:25:21 +0100 Message-ID: <87mt4beqdq.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:mzjh0hjm7JuYVsmqdvrV8Wv2+zCd9XJLz8Fnqnzc/sZvhh9FH3x yXg478YElRvuAVmHjZF3pl8iplMnPXIkaxrB68XtqMOPYJOQXjDDS7SHD1u04DaG25JH/4D wgMw6mwXQExiqJ+aVHaia1IozMYxPvhum+0VS0z8zwYzd7mAakcDbz2qCThhBIXLL/HwKMX eUWvUZldhVZoa0pJAEUgA== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:xDBuekkTD+U=;TsCE2CXqML0FJVRfpN+p9A9rz3x JN3IFOyr5oPjyTiF0/KrldfmA0zBaFK24z4xz0uhruwptrloJQrWRHfuu2rkCrU95dKAfucSo DJs36mJ35syMT1UZub6YNlh52OVtyDb9X+OV5BZ1Xf+x92JfPeBoSk7ruvSBanAlLoNzxTCNA dyR/So2l4SRR+Sm3YqgaK94aAY0XHPLBhijdPKgAQzBSntiD/9NvKJxCpn4h2VaJA4OdQRsG6 zqD1t1hCeCrDeBh0VqHKXAqU6QIgr/8ErA5EUyKDxJDy5/r8qHn8DCR/BCwL0Qfw5Vp36pY9h YaXmHF5Je85SkHMBAr4Y6ZwF1uptBZoUKxImsVrKRkWgrAOC6wJS5xOczo6KCi5/A5+ins1xU K4beOt6EXEawVmn3dxEIwYBlSwlJhhlMZ1+pVZGw82LkCOvFGyfDYeTcCs+XtJxqD5CRvsdUh VcMJSsQpxu8+r5smt0N3DO5OV7KRGbvjHDrCGF4Cxp4hCHnvr15q2jZ5IcS26i7QatVkpXWFH i4AYgoePOmOZsCafKqwxRrmCpSuXie7I21c+3QEuRC2yMAsfwa1+h1IE2HERxwfGjSS56OC42 C7sMxP6mTwXMoi8XWJpMooFp4VvjCl3QIAHeep/Z4SWp2QtcbhA1WjAwayGUFdgPk+EB3jpSX a7dKl/X+xtBEi0vuPM+saQv0w80RTZD0LUJQuAX9WavDP8FyPd3/rIBjNSKo5UQbpfduiMkFZ 6Knq8BMgoRuD2SRBy1rMNc90D79qN3MoFcK8Fe8hBSo+UPhhxtPnSkU6vYVqvKT0vqZ4SsCVZ 9536z6RXwSb5Rf5K/1+RTR77bR3N/0ABgPR50kuOTz2wRIP0O1z31mcxCgjaLH6if5R5EObnZ moPtke3I6zcZED1v/t8zL2NaL446l7kI8/sUc1YU/spQp/pQpyu1+ts9xBbpqhzj7YvW65m/I 9tDHUveTeGysbn6uieHAcmzz5Yo= X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org, =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Felician Nemeth writes: Hi Felician, > I haven't found the prior art for this. trampver.el repeats the header > info, so when the version changes it should be updated two places, which > (I think) is an antipattern. FTR, trampver.el is always generated from trampver.el.in in the Tramp repository, see . Best regards, Michael. From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 19 08:15:35 2023 Received: (at 62198) by debbugs.gnu.org; 19 Mar 2023 12:15:35 +0000 Received: from localhost ([127.0.0.1]:49590 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pdrwl-0001BO-62 for submit@debbugs.gnu.org; Sun, 19 Mar 2023 08:15:35 -0400 Received: from mail-wr1-f48.google.com ([209.85.221.48]:44666) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pdrwi-0001B9-MA for 62198@debbugs.gnu.org; Sun, 19 Mar 2023 08:15:33 -0400 Received: by mail-wr1-f48.google.com with SMTP id p4so8013041wre.11 for <62198@debbugs.gnu.org>; Sun, 19 Mar 2023 05:15:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1679228126; h=content-transfer-encoding:mime-version:face:user-agent:message-id :in-reply-to:date:references:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to; bh=0ztcZyHGxWBYRa7oTawWBxIAtPs9uvZEYUzcgI5mugc=; b=mlIISTHCgnbMzXpxksMO3NR8jd8CfPGnpm4+hBau4tPOEuAX5nNHqyuJrHHDmBhpzb vRfNY8Vtfiq3LGmoMegHLDPO+exQhbqIJwAPZgPLPHzlfJDVmBgg2WWY0zqBwLm0S6ek G9Nwit3pAOk5VTl+9d4ZwcCYKcwbyWjr1Td4gnmKrdWYjMHFfDULcTLZoonV2AA9S/JI yEltzRFeCxwWr7GfmTRySrY1doFP6e4emCGLyzhqTio6PAA171CP9/ibdsjqrKvf9DM1 UmmmwIL3Y8th5eBL7DNqmHx28DEbtwnWcQ70etfjGau+6oNHks7FxBM71rzyfSbhe6q4 PnPA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679228126; h=content-transfer-encoding:mime-version:face:user-agent:message-id :in-reply-to:date:references:subject:cc:to:from:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=0ztcZyHGxWBYRa7oTawWBxIAtPs9uvZEYUzcgI5mugc=; b=vnLL9mfPHVOM8GB2vmklYaBHu7qgd4ZRdnvNgse/1Ee2a+aN0RVL6g1yb0qc01/V6s 7idkpcgRPb0V90ZAKQhOfVhsYHjv4Km9C0Ad4/0zvzhAGbwkfa5KksLsJFEQyu3AwUam ERzH1oQvLXsXpNUbBIJhzRVCtPS8d8ONrHP01ztYBeUsjF6HXjRVzv7dDlqlv5zOzc0B U4mJw0eQ4vEXCtYRLDTmSGPVKerSSLWaglWNmJVmcLIE7wKPkJlqPriq46QutlqA3rRr p4h7ipHG+rqK2aoAxXFiiW1RVklVlPYtYNX2vGWe/fuPtw7MsGkcun2YuaUYCV3g6wT8 XIyw== X-Gm-Message-State: AO0yUKXtL2gKVXOZ5Dg3kYqxN1x/HU3vPeiouAVnOLv0DGYmkdHzWscr m9DWvLxeuozZjP9buQvq8tHZ+3x6gvw= X-Google-Smtp-Source: AK7set/VOQHiSNruEzV37l3+unwQ+sbGDO1D7FtyW5WJcgTfkDLriQ4hBYTo6pFYOf9X8xzCijunTg== X-Received: by 2002:a5d:4531:0:b0:2cf:e689:e60e with SMTP id j17-20020a5d4531000000b002cfe689e60emr10614386wra.59.1679228126506; Sun, 19 Mar 2023 05:15:26 -0700 (PDT) Received: from betli.gmail.com (catv-86-101-66-128.catv.fixed.vodafone.hu. [86.101.66.128]) by smtp.gmail.com with ESMTPSA id n2-20020adffe02000000b002cfeffb442bsm6422799wrr.57.2023.03.19.05.15.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 19 Mar 2023 05:15:26 -0700 (PDT) From: Felician Nemeth To: Michael Albinus Subject: Re: bug#62198: [PATCH] Eglot: Send clientInfo during the initialize request References: <87v8j28c2x.fsf@betli.tmit.bme.hu> <87pm994uod.fsf@gmail.com> <87edpo8wzc.fsf@betli.tmit.bme.hu> <87mt4beqdq.fsf@gmx.de> Date: Sun, 19 Mar 2023 13:15:24 +0100 In-Reply-To: <87mt4beqdq.fsf@gmx.de> (Michael Albinus's message of "Fri, 17 Mar 2023 09:25:21 +0100") Message-ID: <871qll7x9f.fsf@betli.tmit.bme.hu> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAADFBMVEX5+fmhoaEwMDD/ ///TMNVWAAAAAWJLR0QDEQxM8gAAAAlwSFlzAAAPEgAADxIBIZvyMwAAAAd0SU1FB+AICBUfHgLs gGoAAAGXSURBVCjPRdK/b5tAFAfw753gBEwM2ApMbuVIqf+Ko0qiyhOu4sj2xJBYMn/FUdX7UUUZ OjHgyvf+yj6IcW6Bjx53934ADEvs8bmEr8UVoTYTOyJO9KoYsVofN8kILdbeJ8Li6YpZWop4xOK0 VdfIoXmkHn5/5D7/Ts/8THacSqnkKTcMTxgUkVzFnEIRTKwwYYSCvzfg16f0i8YApW/XG/Pm8R49 dXjxKmRnxv3OwooQWcv4RUYem1fsNe/WU63uk7AmYxk78y32/ee2tZB4fO+WcZ7lnIGEolXW1EGw LfkSuQ0XTgRefgNlfNwRNV6QhBxJ8JNxTMUPyBqTd0bjaAP5G7NJRU39z80hLOZTjqB7K3tEEFSj aEsuQew6qBxxyhHjVUR7H7NpC9iHJZGLMCEuweqAqE1BHbfK2oRIz9EHYA/+wiFWru9smeVfuWNZ 2+NFtX80UA1TvJNdytM4DwO4kY7bJz8Qcd0G0ceslZGkkeoBsjUHwF1+jjM3XHaXEZ7mGLfwPFO+ RV9QLY2iEdmDo78D/gNPaXVYqd+pyQAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAxNi0wOC0wOFQyMzoz MDoyOCswMjowMGy/yHYAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMTYtMDgtMDhUMjM6MzA6MjgrMDI6 MDAd4nDKAAAAAElFTkSuQmCC MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org, =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi Michael, > FTR, trampver.el is always generated from trampver.el.in in the Tramp > repository, see . Ah, okay, sorry. At any rate, I think a Makefile would be an overkill for this little feature. So maybe clientInfo should just send the name of the client if Jo=C3=A3o is not happy with the previous approach finding out the version of Eglot. From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 19 09:21:47 2023 Received: (at 62198) by debbugs.gnu.org; 19 Mar 2023 13:21:47 +0000 Received: from localhost ([127.0.0.1]:49638 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pdsyp-0002xk-A3 for submit@debbugs.gnu.org; Sun, 19 Mar 2023 09:21:47 -0400 Received: from mail-ot1-f48.google.com ([209.85.210.48]:38639) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pdsym-0002xU-Nc for 62198@debbugs.gnu.org; Sun, 19 Mar 2023 09:21:45 -0400 Received: by mail-ot1-f48.google.com with SMTP id x22-20020a056830409600b0069b30fb38f7so5403879ott.5 for <62198@debbugs.gnu.org>; Sun, 19 Mar 2023 06:21:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1679232099; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=SICZstt6141qjY0Tn04gyZD7KYpgbD8BmeJDKRWDCkk=; b=h86MEvzdYIl24g6YXb1lqnmvj3sE9kp2Bzvyt9Xch5YGuZg7MayyaG6AlyG6W1rZFZ tMMViIUlv+C76yzy3iz2kgIni98ldek77MGjLn9bI/0LqF7w0f6HfSk4UuCSztS5x+n1 BXEGfUDQYMa/TIGsaXOK+Rmhl1hfpUq1VBA/vRITYYd1xVbeNtL441yra6Ii3gr8g4o7 A2ZBItbVqlmiDNfm0xL3VpaSs3rOvykNM+k3KH0jXHWLSSfOw1HmlmPkMGQFAzNFkCfR K5hGCrbtNMkCysVS7665bihBwHoJyyj/bV9kjyuyeOMJXApHAP6dQJCtvJ4jskNezHbN UpJg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679232099; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=SICZstt6141qjY0Tn04gyZD7KYpgbD8BmeJDKRWDCkk=; b=waZOEWEfEkfNwBXX/zhuEDJ6eXLzA7iFHSOvVa/ucK9z5foeOjMPrCAN3sYvGeDXNz VpPDdJ8oEB8+cyLPDaPGbe0i2FP0KbGgJd5/Ggy23e6CTgTxrZmkuoEEabdRmnpii6Yi M4RuFTocwHB37ONtkC/sGYLX1v82tDDIwIJTEPS/oNZzDVL1nnEVl04nf0FEQZ3mjt+9 DKZqEqbzgks6Vm3oNUze+p0OiifT27fMjOrD74AfCQMTp3hvUsYS+tiqdQ5JeHmqUGKw DmvNYzwSFPYdR6L7tFkVwkGwT7cdEfHhs/Mt2FwnKfncAUu2mOvnbbXVWg0gwLLm0XWG PslQ== X-Gm-Message-State: AO0yUKUQ6vxLMNaG1pvIYm6qhQqreWPnvkisfxSq+YPE0KP7rNrwEZNY SUvIfKJ/7ZUWrV7GC65qs7dC/fiy+NaL7CcGSro= X-Google-Smtp-Source: AK7set9ASs3SCUH21qwY+qD/9tlrntIiQqeWckbZ4rJ7THCwEqgQR7xlQMtfz130VN/v5VzouciKo0m32Vcq+M7+pZU= X-Received: by 2002:a05:6830:e8d:b0:699:bf77:e691 with SMTP id dp13-20020a0568300e8d00b00699bf77e691mr1398240otb.4.1679232099023; Sun, 19 Mar 2023 06:21:39 -0700 (PDT) MIME-Version: 1.0 References: <87v8j28c2x.fsf@betli.tmit.bme.hu> <87pm994uod.fsf@gmail.com> <87edpo8wzc.fsf@betli.tmit.bme.hu> <87mt4beqdq.fsf@gmx.de> <871qll7x9f.fsf@betli.tmit.bme.hu> In-Reply-To: <871qll7x9f.fsf@betli.tmit.bme.hu> From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Date: Sun, 19 Mar 2023 13:23:29 +0000 Message-ID: Subject: Re: bug#62198: [PATCH] Eglot: Send clientInfo during the initialize request To: Felician Nemeth Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org, Michael Albinus X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Sun, Mar 19, 2023 at 12:15=E2=80=AFPM Felician Nemeth wrote: > > Hi Michael, > > > FTR, trampver.el is always generated from trampver.el.in in the Tramp > > repository, see . > > Ah, okay, sorry. > > At any rate, I think a Makefile would be an overkill for this little > feature. FWIW, my other SLY extension also has a complicated "scan own file" thing. Known to not work extremely well/be very useful... > So maybe clientInfo should just send the name of the client if > Jo=C3=A3o is not happy with the previous approach finding out the version= of > Eglot. I don't know if I'm happy with it, since I'm not familiar with what it does. The version could be useful. The problem is that it is tricky to get right, meaning something that you can really rely on. Ideally I'd like to know two things in the log transcript some hypothetical bug reporter shares: 1. Is this an unmodified GNU(-devel) ELPA version of Eglot installed by the only officially supported `M-x package-install` method? If so, what version exactly? 2. This is something else, a user compilation, a straight-installed package, nix installation (never tried these, but they show up in the wild a lot, and are problematic like in https://github.com/joaotavora/eglot/discussions/1182). I don't think any more granularity within 2 would be very useful, especially to the server devs. Although it _could_ be useful to somehow debug -- not via LSP messages to server, but in the events log as an internal message -- the versions of the packages that Eglot depends on. But that's a broader idea, I think, and one more suitable for a future M-x report-bug-in-elpa-package. If this is not easy to do without complex libraries, i'd prefer just to send the client name via LSP. Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 22 12:05:19 2023 Received: (at 62198) by debbugs.gnu.org; 22 Mar 2023 16:05:20 +0000 Received: from localhost ([127.0.0.1]:36425 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pf0xj-0001Z6-EU for submit@debbugs.gnu.org; Wed, 22 Mar 2023 12:05:19 -0400 Received: from mail-ed1-f49.google.com ([209.85.208.49]:34600) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pf0xi-0001Yu-AM for 62198@debbugs.gnu.org; Wed, 22 Mar 2023 12:05:18 -0400 Received: by mail-ed1-f49.google.com with SMTP id b20so42074204edd.1 for <62198@debbugs.gnu.org>; Wed, 22 Mar 2023 09:05:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1679501111; h=mime-version:face:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=jtRWRmooaXalHcwe7ieBd6usMkw6Q/zvoqYx4e8JFnM=; b=LzCGCZqP7gJ0C4Ab4lOJozqs/ptFptRQFiAjdGmwoZUmO5QAZL8hplgHtnT6kmeMH4 meD5PYqL0X5k9GKwSEAtVuyfW/HT2+iV4x3jqcRHbCViKjUHtkUvK77z9joN90JhQVI7 yjPFkDSBbJvstNyILcb82jPbKZ4sBo6xA4YA2rVX2ArF4PD2LaOKbqSxjxUqvvATq+WT ehVcGK31WCZfQjmnMeLOds+BA2JWrcRU+hdDHFAy+cKDksKl13pZodQO7vTYR2GBDDMk h6ltihbCwEjen6M7Q/URXgXqCjWEMydiUJWlD/mjPeZruJA3vXKJSFryLByCrCqSnzLs vuQQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679501111; h=mime-version:face:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=jtRWRmooaXalHcwe7ieBd6usMkw6Q/zvoqYx4e8JFnM=; b=QpOaabq5MtPgvMiVL2KZlMrdOlE0/4sLFHEWASfMpGolDbpHphaTqMJmpgpICN6nOM emZcHuwJYzBjxDBJLdk5ZcNaZ5xe1cmDRLaIThyZ4ECNBSYY1ypMRLrvnJAaFekeKvsQ SiuZv+n8Lh+9sPxY6LJgHG6UPyB7cVp/4opXyC5ENP4tOYuwgY8Bh2/tHOgTJ6EKnPjN 8H4DPwTJHM8oaaJMhfOQrgvxY46bhiR9yDVoN26NDnJsCw/0NsvjNfQY7wxE6ck3LHe2 M1Uc1WsaYq4q2qTbMuVIJDcYxY8hq0UcFlX7OiQSJF8aUTGWp6oWjO3EfUHf88lS7o6q 2k9g== X-Gm-Message-State: AO0yUKXY+UDbaiTRdl9Ir37zL3AF2ZT+BbuIYRfmcJKQRxa9Bsu4x8X/ Y4wAba9mSzv0Dqn7j1zYyZ0kGDONahQ= X-Google-Smtp-Source: AK7set91A01su779+R0RCv02Hn4MNSBcSfKAhSSmtVlId3yJI6R2YOFBGkZlQxtlXiNZp5MkWmywVg== X-Received: by 2002:a17:906:660f:b0:930:a7c9:e45 with SMTP id b15-20020a170906660f00b00930a7c90e45mr6771111ejp.8.1679501111531; Wed, 22 Mar 2023 09:05:11 -0700 (PDT) Received: from betli.gmail.com (catv-86-101-66-128.catv.fixed.vodafone.hu. [86.101.66.128]) by smtp.gmail.com with ESMTPSA id p15-20020a17090635cf00b009307ddcd13esm7364563ejb.119.2023.03.22.09.05.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Mar 2023 09:05:11 -0700 (PDT) From: Felician Nemeth To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Subject: Re: bug#62198: [PATCH] Eglot: Send clientInfo during the initialize request References: <87v8j28c2x.fsf@betli.tmit.bme.hu> <87pm994uod.fsf@gmail.com> <87edpo8wzc.fsf@betli.tmit.bme.hu> <87mt4beqdq.fsf@gmx.de> <871qll7x9f.fsf@betli.tmit.bme.hu> Date: Wed, 22 Mar 2023 17:05:08 +0100 In-Reply-To: (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vora=22's?= message of "Sun, 19 Mar 2023 13:23:29 +0000") Message-ID: <87o7ok7owb.fsf@betli.tmit.bme.hu> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAElBMVEWOdXElERN7LDLZs6/l 0dDQq6TepMcqAAACW0lEQVQ4jWWSzY7bMAyEaSm6mypylxjkroTRvUW8d9lavf+r7NDOZotWQHzg lyGHP0Sn5ed9qKrLWWIWos9/QJWIeCSywPNTd/AE0LtwFj7A+3WT5PwfeBrQKcsBnkfwVcNySWQr 3i34XN6gRNgis/v4uwSKHCD9lPitB0Aq9BHfHX4cgsI7cJJfLdZg/4bbCzoRmkD9MsagQSBDedZi CgNxkVSJmSOStTBUBKkywEnEoZzbwWj+ACiVJkF6pOpak2PMCqkMYDpaw+gatLR8atMOrB3JGzmm 3rSQo+tkxU+UAbhQSgtslULhsXKk6+IyQ1QTzeQB0MzjlpkCEUCeUdviWrwBcxVqpZjP+v0MYPA0 aq2rvIEZe4GRM0v+9QIB03rsABVSk5y+Mz3LSzExtJLlCCO6dV1uzDQFTBad+gO0TqqL9XE8x4ek +orvYiMJgzC8e+r6TqaPaK6QyqVNvoHtsRrooQ6tTi4vgaSkd8wIikodB3B0iIk58avsDdYNajpS bSKJ+mQnipGszB6zW4lGgsOkKHE2RWVcBpwhaIv3BYIAu3WsnC7YYKLRchp6w8fRGZIWiZuFsVai 7gbcUcJEhiDZ3K1+uzZvBlfaEO8oH4MLu6/hrKVM7QpQcIXJFuC1XjfbfKRxNslk94l9cYcEihV2 HWyNDQAXaLsvnrSyp7HaQhrAn13V6/XW11nh0XINBOEAV+tHK4EvAGNGvEwc0eZw8Vyr56imYEsV sOW9jxm/yb9AH1ufqGMviIK7A0Tc/723oM3tJ4HTOu9gDr3ftbdkxfdjsUv5AqWKwyfCYo5WAAAA AElFTkSuQmCC MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org, Michael Albinus X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable >> So maybe clientInfo should just send the name of the client if >> Jo=C3=A3o is not happy with the previous approach finding out the versio= n of >> Eglot. > > I don't know if I'm happy with it, since I'm not familiar with what > it does. This is eglot--version in my original patch: (defconst eglot--version (eval-when-compile (when byte-compile-current-file (require 'lisp-mnt) (lm-version byte-compile-current-file))) "The version as a string of this version of Eglot. It is nil if Eglot is not byte-complied.") It does something similar to sly-version, but instead of manually parsing the source file it relies on `lm-version' of the lisp-mnt package. (package.el also uses lisp-mnt to parse "header comments".) However, lm-version needs a file argument to parse. If eglot.el is byte-compiled, then byte-compile-current-file will be set to eglot.el during compile-time and eglot--version won't have a run-time calculation cost. > The version could be useful. The problem is that it is tricky > to get right, meaning something that you can really rely on. Ideally > I'd like to know two things in the log transcript some hypothetical > bug reporter shares: > > 1. Is this an unmodified GNU(-devel) ELPA version of Eglot installed by > the only officially supported `M-x package-install` method? If so, > what version exactly? > > 2. This is something else, a user compilation, a straight-installed > package, nix installation (never tried these, but they show > up in the wild a lot, and are problematic like in > https://github.com/joaotavora/eglot/discussions/1182). > > I don't think any more granularity within 2 would be very useful, > especially to the server devs.=20=20 I don't know how to answer these questions. > Although it _could_ be useful to somehow debug -- not via LSP messages > to server, but in the events log as an internal message -- the > versions of the packages that Eglot depends on. But that's a broader > idea, I think, and one more suitable for a future M-x > report-bug-in-elpa-package. I think it is possible write the versions of Eglot and its dependencies into eglot-events-buffer with the help of list-mnt, but I don't think Eglot should send this in clientInfo. > If this is not easy to do without complex libraries, i'd prefer just to > send the client name via LSP. I've attached a simple patch that sends just the client name if you decide to go this way. Thanks. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-Eglot-Send-clientInfo-during-the-initialize-request.patch >From d88fbc30335fa4f68e1dfa339fb9e23f80eadbef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felici=C3=A1n=20N=C3=A9meth?= Date: Wed, 15 Mar 2023 12:34:06 +0100 Subject: [PATCH] Eglot: Send clientInfo during the initialize request clientInfo arrived in LSP 3.15.0. LSP clients can use clientInfo to identify themselves in the initialize request. This is generally useful for various debugging tasks. * lisp/progmodes/eglot.el (eglot--connect): Send clientInfo. --- lisp/progmodes/eglot.el | 1 + 1 file changed, 1 insertion(+) diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el index 037cc87148..91fa00d4b7 100644 --- a/lisp/progmodes/eglot.el +++ b/lisp/progmodes/eglot.el @@ -1310,6 +1310,7 @@ eglot--connect (eq (jsonrpc-process-type server) 'network)) (emacs-pid)) + :clientInfo '(:name "Eglot") ;; Maybe turn trampy `/ssh:foo@bar:/path/to/baz.py' ;; into `/path/to/baz.py', so LSP groks it. :rootPath (file-local-name -- 2.30.2 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 22 14:38:14 2023 Received: (at 62198) by debbugs.gnu.org; 22 Mar 2023 18:38:14 +0000 Received: from localhost ([127.0.0.1]:36715 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pf3Lh-0000AM-Tc for submit@debbugs.gnu.org; Wed, 22 Mar 2023 14:38:14 -0400 Received: from mail-wr1-f45.google.com ([209.85.221.45]:37380) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pf3Lf-0000A5-SK for 62198@debbugs.gnu.org; Wed, 22 Mar 2023 14:38:12 -0400 Received: by mail-wr1-f45.google.com with SMTP id y14so18104003wrq.4 for <62198@debbugs.gnu.org>; Wed, 22 Mar 2023 11:38:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1679510285; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=r+im0W3CM9Fu3aeiGaRi9bB7RDhmB4avhmNbfYhWmRI=; b=LK/M4wfMXV9Ww9rd3RtDTZwZrfmmyUKJq9kUgZhOgm0DvmkfZM6/DN7YyXa+/tWiCa dns1d8O9+N8UVbgFkMuopRrnVLVDgFlEQUO1EMFaYQy/sdKzAhq6uW9PKFmR4WGQjsA+ +Q3mZPU1VciiwsYSkkPsSkw+brMdhbGzrIUsTCiZ6Ymfn06PBbiffhu0Bpc2zZW/dS7y JWxsZCDMzUWz4T7jXT7YY7WI5++gIMeGIkg2xgb13Z1g2Jg/EMXnvd6amBIUDHPgqTQs FAlH4cC3TzhuowG/P6A6VvLJAj8crRaAowZBKfsPqKwig+N681FRzBiEDpxziocUca4x C2zg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679510285; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=r+im0W3CM9Fu3aeiGaRi9bB7RDhmB4avhmNbfYhWmRI=; b=OXPTX/SpFXj8qdVuFqfhDPCFAUp1ZS3PgmmC33j6U+KwYsY4Hv1HiaSkCbQQ+pm5VP YroSb95aS1jYg8mqjROxXisGwOmKhrpMAv7OLuEglHDjCsS1N1oaS8GQHXy1OcT7O12y OR9a4zW/ZYZTwuqT8HnzZpbFxX+RANYOv4cJNL1LCMYpS7X5wcVCOkOH1M/7L1CVNSYd AN/GQoKianR6EhWVx3AsRYMC8TQKY5UuTZBEv3sRuvNIChF1BvoHLjg8PLcPFOR+Sart PO/e1z6xDGoGT36OKw6Y3E5i3jxL4hLaFCRhKPAEQtNWANjK7gs99lmVF/7eiZw52DQa f5rw== X-Gm-Message-State: AAQBX9eAOqIBiqoAA52jDsEcyFFqMS8KlUAANm/U2DvJyNmdGC4rWGsw rG3FGs9bZNdbDqrFHHi7R9OFRS32mIU= X-Google-Smtp-Source: AKy350bhVrw39lkwRAqnDdQEowdcvkSClQOwgdFbhU5UMwe6VxFn8sCeRoAblOnbcTRlJX9xG8gdFQ== X-Received: by 2002:adf:df92:0:b0:2ce:adda:f45a with SMTP id z18-20020adfdf92000000b002ceaddaf45amr608886wrl.62.1679510285746; Wed, 22 Mar 2023 11:38:05 -0700 (PDT) Received: from krug ([87.196.72.142]) by smtp.gmail.com with ESMTPSA id o31-20020a05600c511f00b003edd2ec9f85sm12800651wms.6.2023.03.22.11.38.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Mar 2023 11:38:05 -0700 (PDT) From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: Felician Nemeth Subject: Re: bug#62198: [PATCH] Eglot: Send clientInfo during the initialize request In-Reply-To: <87o7ok7owb.fsf@betli.tmit.bme.hu> (Felician Nemeth's message of "Wed, 22 Mar 2023 17:05:08 +0100") References: <87v8j28c2x.fsf@betli.tmit.bme.hu> <87pm994uod.fsf@gmail.com> <87edpo8wzc.fsf@betli.tmit.bme.hu> <87mt4beqdq.fsf@gmx.de> <871qll7x9f.fsf@betli.tmit.bme.hu> <87o7ok7owb.fsf@betli.tmit.bme.hu> Date: Wed, 22 Mar 2023 18:40:06 +0000 Message-ID: <87ttycvddl.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org, Michael Albinus X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Felician Nemeth writes: >> I don't think any more granularity within 2 would be very useful, >> especially to the server devs.=20=20 > > I don't know how to answer these questions. I'm not asking you :-) These are questions I ask myself when facing bug reports. And usually I don't have a good way of answering except for drilling the bug reporter. I agree this most of this information shouldn't probably be sent over to the server. >> Although it _could_ be useful to somehow debug -- not via LSP messages >> to server, but in the events log as an internal message -- the >> versions of the packages that Eglot depends on. But that's a broader >> idea, I think, and one more suitable for a future M-x >> report-bug-in-elpa-package. > > I think it is possible write the versions of Eglot and its dependencies > into eglot-events-buffer with the help of list-mnt, but I don't think > Eglot should send this in clientInfo. Yes, of course. It's debugging information. Currently the manual advises users to list the files in 'package-user-dir', which is a really poor way of telling the versions of ELPA packages, but it's the best I've come up with. What I meant is I'd like to have a way to produce a listing of packages (required and optional, like markdown/company/yasnippet) for inclusion in bug reports. >> If this is not easy to do without complex libraries, i'd prefer just to >> send the client name via LSP. > > I've attached a simple patch that sends just the client name if you > decide to go this way. Thanks, I've pushed it to master. Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 23 12:03:50 2023 Received: (at 62198) by debbugs.gnu.org; 23 Mar 2023 16:03:51 +0000 Received: from localhost ([127.0.0.1]:39182 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pfNPq-0003E2-Ko for submit@debbugs.gnu.org; Thu, 23 Mar 2023 12:03:50 -0400 Received: from mail-ed1-f44.google.com ([209.85.208.44]:35820) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pfNPp-0003Dl-2O for 62198@debbugs.gnu.org; Thu, 23 Mar 2023 12:03:49 -0400 Received: by mail-ed1-f44.google.com with SMTP id y4so88964256edo.2 for <62198@debbugs.gnu.org>; Thu, 23 Mar 2023 09:03:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1679587423; h=mime-version:face:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=OcMVHBHQj99oor2v+OIrellVeGt2MDWisw7zFUlPSi4=; b=VYIi7TXs6iXNgDsMmqq/DiEsoH4BShfo/hUJyYZootvjy/UGVg49O4SlfRgYbv0MbR XA3jwfQ1uavISe00ivK2+Sn8QasZ6kG00Mhu7MSk8V+idnHZ1+u6tobfARSh5Rjy6g0q Xgp+zWC4ZFf60ZZIw95Nci5htczXmIY0prMeHQmbqdHItC50J7ydTaRvvq1xFhgztClK +PyuukT2TeU3jz851AHuyYn8bXDN5Ai0YVO1iJ9FddeF+EsCyPTqmNqJ6EqcT8uh/QkG RYfJaJFLIEqXNudAH0iZzj0xhfJ+JZzGulsBH1IfsunejiBntkjPPHCkV2/ERt9ErICz bfaQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679587423; h=mime-version:face:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=OcMVHBHQj99oor2v+OIrellVeGt2MDWisw7zFUlPSi4=; b=ddqFHNAwbDi5xKAZCkaxgqG9WqggGC3UvbyCRwDM5ZJTbfYcF/9moUqFxXc9Ypglfh fbQS7lwFpgIr2mGzpNOUbxBcFWKsP8cObcZoVhE8QnBnwZu/JVjeVaj7ja1BxgbL3Z2A Y9Xfwrg2xZGRjSAieQ4BlXaAbI4DNw9opNkDt9j5axBIuVGXvpjytKTlBlxWex5deMam boxZgYDHhu1BupvqdCBS1/g2L0/Nl6D06uC6vbOubuSkjI8rMPp6hA6MHKLl2SSmikJp L8fg2ycz1ImcRpS7uErXx5KYGqXzRl5LGRAfp1MzrTkDrr4HA1kU3UXS/rY4iVwYzoQE Y+cw== X-Gm-Message-State: AO0yUKXU2gI041ZgxuRrrauSUIyLlw6QI8jN8AGhViPW+qrYob8kZMrN EbPpuZMsElYgEQs4FJ37cwN/rNJsgss= X-Google-Smtp-Source: AK7set9nJMLzT1VnY9rLjXR9wK9NWtrKPrXDLSJs+nHkeTsFjUUYKmaFZhOu1JV3uDwHDPCUvoTMQQ== X-Received: by 2002:a17:906:6a94:b0:92b:f019:d5eb with SMTP id p20-20020a1709066a9400b0092bf019d5ebmr11231444ejr.44.1679587422674; Thu, 23 Mar 2023 09:03:42 -0700 (PDT) Received: from betli.gmail.com (catv-86-101-66-128.catv.fixed.vodafone.hu. [86.101.66.128]) by smtp.gmail.com with ESMTPSA id bv1-20020a170906b1c100b00939e76a0cabsm3880292ejb.111.2023.03.23.09.03.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Mar 2023 09:03:42 -0700 (PDT) From: Felician Nemeth To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Subject: Re: bug#62198: [PATCH] Eglot: Send clientInfo during the initialize request References: <87v8j28c2x.fsf@betli.tmit.bme.hu> <87pm994uod.fsf@gmail.com> <87edpo8wzc.fsf@betli.tmit.bme.hu> <87mt4beqdq.fsf@gmx.de> <871qll7x9f.fsf@betli.tmit.bme.hu> <87o7ok7owb.fsf@betli.tmit.bme.hu> <87ttycvddl.fsf@gmail.com> Date: Thu, 23 Mar 2023 17:03:40 +0100 In-Reply-To: <87ttycvddl.fsf@gmail.com> (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vor?= =?utf-8?Q?a=22's?= message of "Wed, 22 Mar 2023 18:40:06 +0000") Message-ID: <877cv778v7.fsf@betli.tmit.bme.hu> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAFVBMVEUMBwgHAgMFAAGPjY7/ //80MDHq6eqJt3pKAAABr0lEQVQ4jX2UzZKDIAzHqR177q7TPbtx2HMr6guQcrbY9txZ0fd/hA0f onXazcEJ/CD8E4Js8/HS9mwjXtqeMRxHXJkakTEm4b4GPVQW8PU8ov4fQCqeThlF60MBWdo1IXzd 2nEEZE7CEAZLwI0N/gJAhTj7ESQAX4gPgO8lyI+cvgViSVPlNomAj2M9gW40eg7VWY3cATjUcyiO Z+i03cFruGLYoUR7VyU3HihdmCEVhoDN65FXkpbSxkomOzsTQN/gySaodGb9Gdi1oSRXP46gdBWh LcUKJNdeGCWac74GKakmne0aHCFvyqJPYLsCFAVlhRTvGdzMdLHqtgRyUulyXIAH7CYQ3AB0Nody JQhAkq/qtOnbjhxdzYDkXPxlH5y4WdUAeUcX1NVJ6GR7UQEYPGWoAnA36OQNn5lRRp38vHTAp9Br LoTmvlPPDoRCKzpjG1SXT89AaT5l456BamJuMcs+NIOMzJ/s5dI6yUVcrARlruwOebfdv6gunTn4 ww3+QjGBEn5suVyLHoSGvAqREuDLN+iqZ+VcFg+HBbsJUU9+FZthbez9T+bdb+kPv2Ls6ct3hTkA AAAASUVORK5CYII= MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) > Currently the manual advises users to list the files in > 'package-user-dir', which is a really poor way of telling the versions > of ELPA packages, but it's the best I've come up with. What I meant > is I'd like to have a way to produce a listing of packages (required > and optional, like markdown/company/yasnippet) for inclusion in bug > reports. The code below might be a good starting point for this. It is inspired by `package-compute-transaction'. It seems to work even with Debian's package manager ("apt install elpa-project"). So I'd like to think that a potential failure in the code is a sign that the bug reporter has a non-standard installation. (require 'find-func) (require 'package) (defun my-list-dependencies (packages &optional seen versions) "Retrun the versions of dependencies of PACKAGES. Argument PACKAGES is a list of symbols. SEEN, VERSION are used internally." (while packages (let ((package (pop packages))) (unless (memq package seen) (push package seen) (let* ((file (condition-case error (find-library-name (symbol-name package)) (error nil))) (pkg-desc (if file (with-temp-buffer (insert-file-contents file) (package-buffer-info)) (if (eq package 'emacs) (package-desc-create :name "emacs" :version (version-to-list emacs-version)) (package-desc-create :name (symbol-name package) :version '(0)))))) (push (package-desc-full-name pkg-desc) versions) (setq packages (append packages (mapcar #'car (package-desc-reqs pkg-desc)))))))) versions) (my-list-dependencies '(eglot markdown company other-optional-dependency)) From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 28 17:03:00 2023 Received: (at 62198) by debbugs.gnu.org; 28 Jun 2023 21:03:00 +0000 Received: from localhost ([127.0.0.1]:51790 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qEcJX-00028u-Tn for submit@debbugs.gnu.org; Wed, 28 Jun 2023 17:03:00 -0400 Received: from mail-oi1-f170.google.com ([209.85.167.170]:48447) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qEcJV-00028e-EL for 62198@debbugs.gnu.org; Wed, 28 Jun 2023 17:02:58 -0400 Received: by mail-oi1-f170.google.com with SMTP id 5614622812f47-3a0423ea74eso153474b6e.1 for <62198@debbugs.gnu.org>; Wed, 28 Jun 2023 14:02:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1687986171; x=1690578171; h=content-transfer-encoding:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=6lTnxUJddIGgaqDn5C/L5ogjTvQy/Espq9Vjs3OtK5c=; b=ixov0MFvxSBLlLug3QtLgNXER7HtPreNS0Oeg0Pg9pswU5FDPs1B3N7J+0non0RpGj PXT1cd1H/M82etOwz+FVEsncZ4ibWERJM5N6OaVqnT5JGO1bf003n34t50Vpn9KlYtPH KeGvUNnbERkyL+DMQJi2t0t1TCF+I2O4JEGQcbAis+ne9I2NxrT7goGt/WNyURTHm2+P h5OkGWQPDPpSM7/BhgA8T69+s/0hXyRhofcR8iRM+tH5lwI2qVUSzow1e3fs3RmZ1PYA GU40NAUDlO5baGvDKixP81m6pS94AJV09ei78dzUQb8JZrwjK6efFss5D4d1VxLWWP/A UwbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687986171; x=1690578171; h=content-transfer-encoding:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=6lTnxUJddIGgaqDn5C/L5ogjTvQy/Espq9Vjs3OtK5c=; b=Z6fzRq2lz0TOpFHYT7U9MiHlWM4zE+B55myd1+fKlQxa86utrHOkiJmLDZgKXQlL+z CZkPvIZjeqHLaAynLwU2BuUkTtXz42dncRZ4h+Df9gB5SDdQIVwL3EBqqw3qDtxWdXbB MHJzqy738/7lrvptQoOHpsx4stlTpFw+BGmRyU2vrAOZCV6/Q0V0gLEd+TPC79K4CSHp R/9xIzu1Xqg1BB5TQGotdzAkGlbABbjywn8Jq47qYWBLTvykV1qYi10WWWAQ4ZAyRu8H NZ6+8x0BEbXe9I74rUvdNzaevgSxnBYF+WRirKkUy1fBhbU4b6ObmWRP877iCMC83nt1 3uOQ== X-Gm-Message-State: AC+VfDzvR3pEt4sU7tKfDFdb13Xycug2ehjqVNAy4Ggie8bV9efZDo3J N0nD9CHl8bHe3yNc0ys0rmh+FWbI0HfaowDqCJ4= X-Google-Smtp-Source: ACHHUZ5bwZPYHKgdTAPYFqNVPyRmuoUJGTDe7qCxLb8pEi7oj3QVZskNRV6EpwPgFle/dY+6o9YDJJZe5501vMcRAcA= X-Received: by 2002:a05:6808:1410:b0:3a0:ff3a:72e2 with SMTP id w16-20020a056808141000b003a0ff3a72e2mr22000573oiv.35.1687986171607; Wed, 28 Jun 2023 14:02:51 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Date: Wed, 28 Jun 2023 22:02:40 +0100 Message-ID: Subject: Re: eglot feature request: set Initialize.ClientInfo.{Name,Version} To: Alan Donovan , 62198@debbugs.gnu.org, Felician Nemeth Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 62198 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Wed, Jun 28, 2023 at 9:41=E2=80=AFPM Alan Donovan = wrote: > > >Hi Jo=C3=A3o, > > > would you mind making eglot populate the clientInfo.{name,version} > > > fields of the Initialize request parameters? All that's necessary is > > > the one-line change below, though I'm sure you know a cleaner way to > > >express the JSON literal and the version constant. > > No I wouldn't mind. > Great! I found that this expression works for the version, assuming > eglot is actually installed: > > (package-desc-version (cadr (assoc 'eglot package-alist))) That's the thing. Sometimes it is installed in that variable, sometimes it's a builtin described in some other variable. There is, I think, a library for this. I've found the bug thread: bug#62198. https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D62198 Taking the liberty of CCing there. Felici=C3=A1n was also looking for this. Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Thu Jun 29 11:46:51 2023 Received: (at 62198) by debbugs.gnu.org; 29 Jun 2023 15:46:51 +0000 Received: from localhost ([127.0.0.1]:53868 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qEtr9-0006ZE-6w for submit@debbugs.gnu.org; Thu, 29 Jun 2023 11:46:51 -0400 Received: from mail-ej1-f53.google.com ([209.85.218.53]:57371) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qEtr4-0006Yt-2y for 62198@debbugs.gnu.org; Thu, 29 Jun 2023 11:46:49 -0400 Received: by mail-ej1-f53.google.com with SMTP id a640c23a62f3a-98d34f1e54fso92701266b.2 for <62198@debbugs.gnu.org>; Thu, 29 Jun 2023 08:46:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1688053600; x=1690645600; h=content-transfer-encoding:mime-version:face:user-agent:message-id :in-reply-to:date:references:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to; bh=0CFU3Z1PZ6BkX4ud18p+AopgSTstohtQARJtfIVSUJI=; b=erxAdmDBeSGiJr7NMvVEmYNADC8Cjm6pdbUkJJb1IU9mhSAEUuFDbQFQt4KdaiO3oi qfl+zhtg4RBfpdfmEIvc2pklZ8bbp47UbuaWZy6yV6htYkpDejoxF9AuNZ6R688sXQWV YU10QQ45Uo2LPAphu7vMaPZvuBkRRduFxxlYXbfe8hOHf8gd+axzbJ2O10VQIG30VKTL paaexiDJHuzta70iAwe4BJ8/dkPVrrewAJdoDTiqSzL6XqgGeSTceGJ00QlBZdJXvHIb 6leDIyZR4EMCc8c2bCIrJTfrPNfVwGgilgxx7seFs1nbSWah+FqdZdd2mNUnwOAkqMVK EF0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1688053600; x=1690645600; h=content-transfer-encoding:mime-version:face:user-agent:message-id :in-reply-to:date:references:subject:cc:to:from:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=0CFU3Z1PZ6BkX4ud18p+AopgSTstohtQARJtfIVSUJI=; b=Mq86NEyjXzn9lwtYtPsxXI6jpLTzaGfAnSnuN0sOrjcCedveQGLUiQeUOINA3pdNIh /Y/K3PZBbnDCgDzuyS6WkshV4PqFxMlj3DLlbHBYEBMQ6yESRZT8k+4cfGsZ3ghrqunu O895jqVwd7RvlrUpVqJIQEXbjECkBPmsefF90AUJMbeYEXabUyW9KvwW/VXF5QQ5mKZ7 eqz//8a9Z7ktpAFsIsBeVed7DM0p1A4UkerRZBIVgdGEP1LO6oQ2yC1flykaE8pxh3ls qD+olczWF8/i6LYDys6dkzNeX2tUiOd/X0ii9Gxhf24HD0E/8WxH8dq7XalrqQMlvzry /LEA== X-Gm-Message-State: AC+VfDx3S/uMfAec1DL85RbWCvinD9AGjXTUrj+aBh8O+aIeFfYYNyzN VgvxwjTcbPXwolYNrEMONQuZqIogl00= X-Google-Smtp-Source: ACHHUZ5LZMdKNd2Nau51Nt/6kMd9V2hhr7Oo6RKUyin+POAbpwToz6CSQnQF+wdr+1NcRoONUpjvgw== X-Received: by 2002:a17:907:944b:b0:992:1653:3406 with SMTP id dl11-20020a170907944b00b0099216533406mr6421513ejc.73.1688053599815; Thu, 29 Jun 2023 08:46:39 -0700 (PDT) Received: from betli.gmail.com (catv-89-134-210-182.catv.fixed.vodafone.hu. [89.134.210.182]) by smtp.gmail.com with ESMTPSA id l13-20020a170906078d00b00992b17a5a85sm735580ejc.151.2023.06.29.08.46.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 29 Jun 2023 08:46:39 -0700 (PDT) From: Felician Nemeth To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Subject: Re: eglot feature request: set Initialize.ClientInfo.{Name,Version} References: Date: Thu, 29 Jun 2023 17:46:37 +0200 In-Reply-To: (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vora=22's?= message of "Wed, 28 Jun 2023 22:02:40 +0100") Message-ID: <87cz1es23m.fsf@betli.tmit.bme.hu> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAElBMVEWOdXElERN7LDLZs6/l 0dDQq6TepMcqAAACW0lEQVQ4jWWSzY7bMAyEaSm6mypylxjkroTRvUW8d9lavf+r7NDOZotWQHzg lyGHP0Sn5ed9qKrLWWIWos9/QJWIeCSywPNTd/AE0LtwFj7A+3WT5PwfeBrQKcsBnkfwVcNySWQr 3i34XN6gRNgis/v4uwSKHCD9lPitB0Aq9BHfHX4cgsI7cJJfLdZg/4bbCzoRmkD9MsagQSBDedZi CgNxkVSJmSOStTBUBKkywEnEoZzbwWj+ACiVJkF6pOpak2PMCqkMYDpaw+gatLR8atMOrB3JGzmm 3rSQo+tkxU+UAbhQSgtslULhsXKk6+IyQ1QTzeQB0MzjlpkCEUCeUdviWrwBcxVqpZjP+v0MYPA0 aq2rvIEZe4GRM0v+9QIB03rsABVSk5y+Mz3LSzExtJLlCCO6dV1uzDQFTBad+gO0TqqL9XE8x4ek +orvYiMJgzC8e+r6TqaPaK6QyqVNvoHtsRrooQ6tTi4vgaSkd8wIikodB3B0iIk58avsDdYNajpS bSKJ+mQnipGszB6zW4lGgsOkKHE2RWVcBpwhaIv3BYIAu3WsnC7YYKLRchp6w8fRGZIWiZuFsVai 7gbcUcJEhiDZ3K1+uzZvBlfaEO8oH4MLu6/hrKVM7QpQcIXJFuC1XjfbfKRxNslk94l9cYcEihV2 HWyNDQAXaLsvnrSyp7HaQhrAn13V6/XW11nh0XINBOEAV+tHK4EvAGNGvEwc0eZw8Vyr56imYEsV sOW9jxm/yb9AH1ufqGMviIK7A0Tc/723oM3tJ4HTOu9gDr3ftbdkxfdjsUv5AqWKwyfCYo5WAAAA AElFTkSuQmCC MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org, Alan Donovan X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Jo=C3=A3o T=C3=A1vora writes: > On Wed, Jun 28, 2023 at 9:41=E2=80=AFPM Alan Donovan wrote: > >> > >Hi Jo=C3=A3o, >> > > would you mind making eglot populate the clientInfo.{name,version} >> > > fields of the Initialize request parameters? All that's necessary is >> > > the one-line change below, though I'm sure you know a cleaner way to >> > >express the JSON literal and the version constant. >> > No I wouldn't mind. >> Great! I found that this expression works for the version, assuming >> eglot is actually installed: >> >> (package-desc-version (cadr (assoc 'eglot package-alist))) > > That's the thing. Sometimes it is installed in that variable, sometimes > it's a builtin described in some other variable. There is, I think, > a library for this. > > I've found the bug thread: bug#62198. > > https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D62198 > > Taking the liberty of CCing there. Felici=C3=A1n was also looking for thi= s. If Eglot is installed, then it is byte-compiled as well. The earlier patch in this bug report made sure that the helper library ('lisp-mnt) was required only at compile time. However, the patch worked even if Eglot was not installed with package.el (but Eglot still needed to be byte-compiled). On the other hand, if package-desc-version is acceptable as opposed to that earlier patch, then it is probably better than not sending a version number in clientInfo. From debbugs-submit-bounces@debbugs.gnu.org Thu Jun 29 12:03:05 2023 Received: (at 62198) by debbugs.gnu.org; 29 Jun 2023 16:03:05 +0000 Received: from localhost ([127.0.0.1]:53883 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qEu6r-00079N-CJ for submit@debbugs.gnu.org; Thu, 29 Jun 2023 12:03:05 -0400 Received: from mail-oa1-f48.google.com ([209.85.160.48]:58787) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qEu6o-00078i-Hw for 62198@debbugs.gnu.org; Thu, 29 Jun 2023 12:03:04 -0400 Received: by mail-oa1-f48.google.com with SMTP id 586e51a60fabf-1b038d7a5faso764331fac.1 for <62198@debbugs.gnu.org>; Thu, 29 Jun 2023 09:03:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1688054576; x=1690646576; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=aEjm+Cx3zOnXPlXJC1oUlJRZpqd/fpP7j2Hzgrla0A8=; b=GB0eDzGt+yrskk3o4YteKUuzKq8FzCjT5uFC407JGNYmacGWeDqPLfm8mZgDo8GYBz H7D4dgOfFW6sq25A7iC+8fC8VhsVBTVJwBqq6jTAYoU7maIQPpupMhrSpLdI1WDW5XuA 7l+O7XafCLs2hlgZse4L8TKc553J/h2ShYH0q91FAszscoZQgsXnQYKRmrlzJu+PNLSQ k+UXuKkXqW9B3uv8L8izqLYnsxPi/oZPOM1bd11KMfoDan9P6L+koJSCQqcLOVhBQ8e1 zaKydY7Ry3+dem03dLd7rHTbwe60P/WQHE/gQu3Qjkabqd3CzXFYwyhOvGR5i7rICHv/ lUFQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1688054576; x=1690646576; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=aEjm+Cx3zOnXPlXJC1oUlJRZpqd/fpP7j2Hzgrla0A8=; b=KbnISs97sYXkk5k2dHfIV5ey3/VrTwm2I5mSsWnifPnkOmTE4FYdtDNlh1c8xjo3n2 mTpouAYPSHbGceO2jkamn4zXoCXQ2KG25x+rrUSnLqBelm1ntLsxQ/zrqT1Enhf4eaO+ +V4KzqemEJnSS4EOAuCBpGAO32JWku58qJN8ykeBOUByO+xut1YxodIg4hmGu3D0PCYj PndpJVOHnvx4O2Zq1QVBDbBCqo8mI4dvSrG7nrQeW+BSkcHy9xtEnUrNR2JRd2vX8PNu JeAvQN4h0W6x+ropiLo1oOXbCZTdkfLKBjgXmghYKHSNXZDR4a0BTzo2zq2Ke33glt5l 3DVA== X-Gm-Message-State: ABy/qLb1/ilvTytqGDIjBnwVK880uT0F7AU44CgowhWUispT9qeZuaJP aPrw6foQGR/Sy2C6lT7cvCnW0P5opvb1pCybMCE= X-Google-Smtp-Source: ACHHUZ6xp6T2bailWAwmI9GSk0BbJVf1+Vs3dfiZjUVSz7jdhsRF2YaqlU48gVQZMlS1CaB8MM5TaJlqomTwwul80s0= X-Received: by 2002:a05:6870:4c18:b0:1b0:2fc3:b4f1 with SMTP id pk24-20020a0568704c1800b001b02fc3b4f1mr447110oab.9.1688054576581; Thu, 29 Jun 2023 09:02:56 -0700 (PDT) MIME-Version: 1.0 References: <87cz1es23m.fsf@betli.tmit.bme.hu> In-Reply-To: <87cz1es23m.fsf@betli.tmit.bme.hu> From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Date: Thu, 29 Jun 2023 17:02:44 +0100 Message-ID: Subject: Re: eglot feature request: set Initialize.ClientInfo.{Name,Version} To: Felician Nemeth Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org, Alan Donovan X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Thu, Jun 29, 2023 at 4:46=E2=80=AFPM Felician Nemeth wrote: > > Jo=C3=A3o T=C3=A1vora writes: > > > On Wed, Jun 28, 2023 at 9:41=E2=80=AFPM Alan Donovan wrote: > > > >> > >Hi Jo=C3=A3o, > >> > > would you mind making eglot populate the clientInfo.{name,version} > >> > > fields of the Initialize request parameters? All that's necessary = is > >> > > the one-line change below, though I'm sure you know a cleaner way = to > >> > >express the JSON literal and the version constant. > >> > No I wouldn't mind. > >> Great! I found that this expression works for the version, assuming > >> eglot is actually installed: > >> > >> (package-desc-version (cadr (assoc 'eglot package-alist))) > > > > That's the thing. Sometimes it is installed in that variable, sometime= s > > it's a builtin described in some other variable. There is, I think, > > a library for this. > > > > I've found the bug thread: bug#62198. > > > > https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D62198 > > > > Taking the liberty of CCing there. Felici=C3=A1n was also looking for t= his. > > If Eglot is installed, then it is byte-compiled as well. The earlier > patch in this bug report made sure that the helper library ('lisp-mnt) > was required only at compile time. However, the patch worked even if > Eglot was not installed with package.el (but Eglot still needed to be > byte-compiled). > > On the other hand, if package-desc-version is acceptable as opposed to > that earlier patch, then it is probably better than not sending a > version number in clientInfo. I thinkt the lisp-mnt-at-compile-time solution is preferable, as I'm not sure 'eglot always lives in package-alist (sometimes it is a built-in and that is a royal pain). Can you show an updated patch for it, when you have time, Felici=C3=A1n? Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Sat Jul 15 06:18:21 2023 Received: (at 62198) by debbugs.gnu.org; 15 Jul 2023 10:18:21 +0000 Received: from localhost ([127.0.0.1]:44217 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qKcM1-0005bN-1G for submit@debbugs.gnu.org; Sat, 15 Jul 2023 06:18:21 -0400 Received: from mail-ej1-x633.google.com ([2a00:1450:4864:20::633]:56773) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qKcLz-0005bA-ST for 62198@debbugs.gnu.org; Sat, 15 Jul 2023 06:18:20 -0400 Received: by mail-ej1-x633.google.com with SMTP id a640c23a62f3a-992acf67388so351439066b.1 for <62198@debbugs.gnu.org>; Sat, 15 Jul 2023 03:18:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1689416293; x=1692008293; h=mime-version:face:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=dFzLmf43GfgpAZtRKDhsu5m738yTlKDNmplDAby/cxE=; b=PeXC93MvjqV9B1RtYr+wl+rfsDyFCKzeNNpT4pXlRZCD5/zxciJLaCCGO4vylE+of9 AosK1788VlPj8OJJlDk4yReyTTTfcIRvnb3bUfHKM6WyIR3c0LcZaVQVp9BptLk7bzKH QEGIJH81BzQ9azfWNh2/QLRRGX93tSkaNVTIhoQp4rdHtvGh9JDnxLHo3LbYhul9Vg3V 2D8oKBBFAiw0/8ImqfSSQd3oDgLNC1qnaRe0Eg0VpLByZDKe4/ya7KJ0ZWbUJCklDm9V 8wePfPDzjRhzmxHvzxFwHOwPg7hfyvh8OIvqyx1h/83EntmcjMJ1+MEoLool59QxTzLZ gTLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689416293; x=1692008293; h=mime-version:face:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=dFzLmf43GfgpAZtRKDhsu5m738yTlKDNmplDAby/cxE=; b=KfVdJQ/Son0ACxCCwTh5AjeLEY4kHcG3PcDSmzSEDI5IpvIjglYEVnZKubl75fF0nG kqYi+YrKQ5WVZ+IJRHF0ujsLhe4jQFDlstOcJvzpb6+v7RmZi/ZKnDI4iKlJ0x3UTKli 0/vHG6uCRyE9GvEUPjefPjvDD2KrydbWuai66w+fg3vxI6BM8j+xHOtq8KZYEfaYkRhy jCu0JiNVKGa8kslJgFoCFOuQD19qdzTeVEkVkBECSb1gAG6VbhudB8NN5SGteHP2ddJG 9VrH48WeLRKSRjj31BXouy9hiysNiCKZdiFw+GaoSPStKMYM3nZnpj9HF49VTSCsc3lY QITA== X-Gm-Message-State: ABy/qLaYa1MPosBlcZuloasGCEa/WH4rOafXQcsDOq/jUuTvo/0/AWtw G/owVOjM0/BjPZD4JRBTu3kFumdQv4w= X-Google-Smtp-Source: APBJJlGbqBR6XNLLvDw8dzKqaAH/1XPLGPWMPoiMfon5ns2fZCwotBQNp+SzS+gWjjxnNTVD85mvNw== X-Received: by 2002:a17:906:6492:b0:973:d06d:545f with SMTP id e18-20020a170906649200b00973d06d545fmr6280454ejm.24.1689416293200; Sat, 15 Jul 2023 03:18:13 -0700 (PDT) Received: from betli.gmail.com (catv-89-134-210-182.catv.fixed.vodafone.hu. [89.134.210.182]) by smtp.gmail.com with ESMTPSA id r11-20020a17090638cb00b00992f309cfe8sm6668909ejd.178.2023.07.15.03.18.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 15 Jul 2023 03:18:12 -0700 (PDT) From: Felician Nemeth To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Subject: Re: eglot feature request: set Initialize.ClientInfo.{Name,Version} References: <87cz1es23m.fsf@betli.tmit.bme.hu> Date: Sat, 15 Jul 2023 12:18:11 +0200 In-Reply-To: (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vora=22's?= message of "Thu, 29 Jun 2023 17:02:44 +0100") Message-ID: <87351psckc.fsf@betli.tmit.bme.hu> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAFVBMVEUMBwgHAgMFAAGPjY7/ //80MDHq6eqJt3pKAAABr0lEQVQ4jX2UzZKDIAzHqR177q7TPbtx2HMr6guQcrbY9txZ0fd/hA0f onXazcEJ/CD8E4Js8/HS9mwjXtqeMRxHXJkakTEm4b4GPVQW8PU8ov4fQCqeThlF60MBWdo1IXzd 2nEEZE7CEAZLwI0N/gJAhTj7ESQAX4gPgO8lyI+cvgViSVPlNomAj2M9gW40eg7VWY3cATjUcyiO Z+i03cFruGLYoUR7VyU3HihdmCEVhoDN65FXkpbSxkomOzsTQN/gySaodGb9Gdi1oSRXP46gdBWh LcUKJNdeGCWac74GKakmne0aHCFvyqJPYLsCFAVlhRTvGdzMdLHqtgRyUulyXIAH7CYQ3AB0Nody JQhAkq/qtOnbjhxdzYDkXPxlH5y4WdUAeUcX1NVJ6GR7UQEYPGWoAnA36OQNn5lRRp38vHTAp9Br LoTmvlPPDoRCKzpjG1SXT89AaT5l456BamJuMcs+NIOMzJ/s5dI6yUVcrARlruwOebfdv6gunTn4 ww3+QjGBEn5suVyLHoSGvAqREuDLN+iqZ+VcFg+HBbsJUU9+FZthbez9T+bdb+kPv2Ls6ct3hTkA AAAASUVORK5CYII= MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org, Alan Donovan X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain; charset=iso-8859-2 Content-Transfer-Encoding: quoted-printable >> If Eglot is installed, then it is byte-compiled as well. The earlier >> patch in this bug report made sure that the helper library ('lisp-mnt) >> was required only at compile time. However, the patch worked even if >> Eglot was not installed with package.el (but Eglot still needed to be >> byte-compiled). > I thinkt the lisp-mnt-at-compile-time solution is preferable, as I'm > not sure 'eglot always lives in package-alist (sometimes it is a > built-in and that is a royal pain). Can you show an > updated patch for it, when you have time, Felici=E1n? I've attached the updated patch. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-Eglot-send-version-in-clientInfo-bug-62198.patch >From df775108a9d0c5171ca6eeb19af752bec15c626a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felici=C3=A1n=20N=C3=A9meth?= Date: Sat, 15 Jul 2023 12:02:49 +0200 Subject: [PATCH] Eglot: send version in clientInfo (bug#62198) * lisp/progmodes/eglot.el (eglot--version): New defconst. (eglot--connect): Use it. --- lisp/progmodes/eglot.el | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el index 8ac21638a5..0da4641fba 100644 --- a/lisp/progmodes/eglot.el +++ b/lisp/progmodes/eglot.el @@ -421,6 +421,14 @@ eglot-withhold-process-id ;;; Constants ;;; +(defconst eglot--version + (eval-when-compile + (when byte-compile-current-file + (require 'lisp-mnt) + (lm-version byte-compile-current-file))) + "The version as a string of this version of Eglot. +It is nil if Eglot is not byte-complied.") + (defconst eglot--symbol-kind-names `((1 . "File") (2 . "Module") (3 . "Namespace") (4 . "Package") (5 . "Class") @@ -1352,7 +1360,9 @@ eglot--connect (eq (jsonrpc-process-type server) 'network)) (emacs-pid)) - :clientInfo '(:name "Eglot") + :clientInfo + `(:name "Eglot" ,@(when eglot--version + `(:version ,eglot--version))) ;; Maybe turn trampy `/ssh:foo@bar:/path/to/baz.py' ;; into `/path/to/baz.py', so LSP groks it. :rootPath (file-local-name -- 2.39.2 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Thu Aug 03 03:39:56 2023 Received: (at 62198) by debbugs.gnu.org; 3 Aug 2023 07:39:56 +0000 Received: from localhost ([127.0.0.1]:50631 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qRSw8-0003vF-E0 for submit@debbugs.gnu.org; Thu, 03 Aug 2023 03:39:56 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36004) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qRSw6-0003v3-Rm for 62198@debbugs.gnu.org; Thu, 03 Aug 2023 03:39:55 -0400 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 1qRSw1-0002OJ-Ko; Thu, 03 Aug 2023 03:39:49 -0400 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=cP4sOyEwR0x+i7t5CiTDOmd8IrPeE2uH1TOqWHrc3+s=; b=ikng/lL9t41DWXgFg4Ho klNQosxPxjUi742ILuadooNmYB+nFGQaeMynZAe6CR3VtdCYtczrq8dcWo5QL7m1OPtGiJMyauIpO ngorJqFcR0GnakizFYofIN030PDOvVprQn5lGfuqTv7b61XzUCrTYKlWMssC3fIz1juTHwTBHi2PZ FmyLMebzmnMRrxJcaTAoxnyvctV88H1NBoPpCemzpqk47vb2c46jwlYTEUwpeMJbtRDnEIQVVpUQw TVj0OpPwB0qwcD7QvgZpLJ6NLfEvM/b4XNFdmujqovhs4zKDD1A3r7WVcZXhGhQe5igujhgfa5tsH 3QBNWbpk0Alr2w==; 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 1qRSw1-0000ya-4Z; Thu, 03 Aug 2023 03:39:49 -0400 Date: Thu, 03 Aug 2023 10:39:58 +0300 Message-Id: <831qgkzi9d.fsf@gnu.org> From: Eli Zaretskii To: joaotavora@gmail.com, Felician Nemeth In-Reply-To: <87351psckc.fsf@betli.tmit.bme.hu> (message from Felician Nemeth on Sat, 15 Jul 2023 12:18:11 +0200) Subject: Re: bug#62198: eglot feature request: set Initialize.ClientInfo.{Name, Version} References: <87cz1es23m.fsf@betli.tmit.bme.hu> <87351psckc.fsf@betli.tmit.bme.hu> MIME-version: 1.0 Content-type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org, adonovan@google.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Cc: 62198@debbugs.gnu.org, Alan Donovan > From: Felician Nemeth > Date: Sat, 15 Jul 2023 12:18:11 +0200 > > >> If Eglot is installed, then it is byte-compiled as well. The earlier > >> patch in this bug report made sure that the helper library ('lisp-mnt) > >> was required only at compile time. However, the patch worked even if > >> Eglot was not installed with package.el (but Eglot still needed to be > >> byte-compiled). > > > I thinkt the lisp-mnt-at-compile-time solution is preferable, as I'm > > not sure 'eglot always lives in package-alist (sometimes it is a > > built-in and that is a royal pain). Can you show an > > updated patch for it, when you have time, Felicián? > > I've attached the updated patch. Ping! João, how should we proceed with this issue? Thanks. From debbugs-submit-bounces@debbugs.gnu.org Thu Aug 03 06:13:30 2023 Received: (at 62198) by debbugs.gnu.org; 3 Aug 2023 10:13:30 +0000 Received: from localhost ([127.0.0.1]:50922 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qRVKj-0005Nn-Kq for submit@debbugs.gnu.org; Thu, 03 Aug 2023 06:13:29 -0400 Received: from mail-ot1-x32d.google.com ([2607:f8b0:4864:20::32d]:60424) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qRVKh-0005NX-JA for 62198@debbugs.gnu.org; Thu, 03 Aug 2023 06:13:28 -0400 Received: by mail-ot1-x32d.google.com with SMTP id 46e09a7af769-6bc9811558cso709950a34.0 for <62198@debbugs.gnu.org>; Thu, 03 Aug 2023 03:13:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691057602; x=1691662402; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=SYGUY/u3A6Dm1I9SO/2StB9viJSbpjVonDKb7IlxBI0=; b=L1IC3UbPptOuVOPcrUV1nhQbCe8XFx71HxH4BSlsYvJEeRtO7c5+BIJ49PuxpJaanO qvIB/Tm2+X6NHceh7qg6U6fr7t3RoC2yxA4c8V8zHrXsHNRHrSBfAvblXnxVqeR5KF9h fw/Ej3k3uzTFI4yqCdm8tp3a+m+Q2in8APsJeF7AsKci/kPnEc+A4ofmgGmvrFKmWJ76 zzNZKNccOXY4zxLE55VSFCD80oikG9BQo9SdNwgMOIGn4hwQf0s3CY+OrW+MqdfmFXfj F0ryMtYyYG2H6J2JeokNXR1FWON8xaAzhd2E9CQOJA8hzcn78Er2D2SwGrs5bf6OkDuv cv6A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691057602; x=1691662402; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=SYGUY/u3A6Dm1I9SO/2StB9viJSbpjVonDKb7IlxBI0=; b=hldr3ok4ql9PCdcXx4Ll4vVyNikk8+rX2MxYEPRkytMBDTI6fyIJ7TCyvlTbD1MUN3 Zhg3YmXRt/RLikUgwST6BbswS9OohIYqTOM4u2QBKSaq+eh1CTgp1bKrXvcjTVm6DTBs IbLYOAiL5wfslAKbep1LSWh/TbkfvtNvrrOfce2AUCxegt+RjR0c+wF2AXzM3+/kLHqS K9TH5gyPInVSAhoIBhzQPgHrlkzUWJmsrUEThs8uuprvLzx7+zLsse4UF2Q7LaPojZjc ONufH4jCxBCGDFjW4bR86tDleDOBQO99Z2MK8yELz2cw+zSgcxHAXrXt2iNEA74rYU1R Tidg== X-Gm-Message-State: ABy/qLaYeX8ZF/JNUPAv1uhnGGkeAAHAE8eR//bz0ICGrmoVSVEy7DZz nSoTj56Etx+rGtwSvr87FTpUYgYr2aHtblFrcPo= X-Google-Smtp-Source: APBJJlFc6/c6cAxNcyw0DYdm1z/wo23sQNAyJtuzQ8XYcA4JwUDp2rUBSyrUwiTsaXXbzxRmC/EeV1qzYTJl9mWm5GY= X-Received: by 2002:a05:6871:723:b0:1b0:5bf7:3bac with SMTP id f35-20020a056871072300b001b05bf73bacmr19831704oap.37.1691057601689; Thu, 03 Aug 2023 03:13:21 -0700 (PDT) MIME-Version: 1.0 References: <87cz1es23m.fsf@betli.tmit.bme.hu> <87351psckc.fsf@betli.tmit.bme.hu> <831qgkzi9d.fsf@gnu.org> In-Reply-To: <831qgkzi9d.fsf@gnu.org> From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Date: Thu, 3 Aug 2023 11:15:50 +0100 Message-ID: Subject: Re: bug#62198: eglot feature request: set Initialize.ClientInfo.{Name, Version} To: Eli Zaretskii Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 62198 Cc: 62198@debbugs.gnu.org, Felician Nemeth , adonovan@google.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Sorry, I think Felici=C3=A1n's patch looks good, and we should push it to master. Jo=C3=A3o On Thu, Aug 3, 2023 at 8:39=E2=80=AFAM Eli Zaretskii wrote: > > > Cc: 62198@debbugs.gnu.org, Alan Donovan > > From: Felician Nemeth > > Date: Sat, 15 Jul 2023 12:18:11 +0200 > > > > >> If Eglot is installed, then it is byte-compiled as well. The earlie= r > > >> patch in this bug report made sure that the helper library ('lisp-mn= t) > > >> was required only at compile time. However, the patch worked even i= f > > >> Eglot was not installed with package.el (but Eglot still needed to b= e > > >> byte-compiled). > > > > > I thinkt the lisp-mnt-at-compile-time solution is preferable, as I'm > > > not sure 'eglot always lives in package-alist (sometimes it is a > > > built-in and that is a royal pain). Can you show an > > > updated patch for it, when you have time, Felici=C3=A1n? > > > > I've attached the updated patch. > > Ping! Jo=C3=A3o, how should we proceed with this issue? > > Thanks. --=20 Jo=C3=A3o T=C3=A1vora From debbugs-submit-bounces@debbugs.gnu.org Thu Aug 03 06:20:19 2023 Received: (at 62198-done) by debbugs.gnu.org; 3 Aug 2023 10:20:20 +0000 Received: from localhost ([127.0.0.1]:50927 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qRVRL-0005YP-Jj for submit@debbugs.gnu.org; Thu, 03 Aug 2023 06:20:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:39772) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qRVRJ-0005Y6-6D for 62198-done@debbugs.gnu.org; Thu, 03 Aug 2023 06:20:18 -0400 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 1qRVRD-0000ue-PO; Thu, 03 Aug 2023 06:20:11 -0400 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=Otq8rKhhm0YH1/sSHu2UwMJXQpg3GhuDHi0M/jvnJpI=; b=l2u4Vx1XTCo/xxAyeAma 76+GHWZZGOlKXySrgCeKjjmwbRYoHd07Amh5WP4Av3zkWF37BCkIwU1ldK9MgtnHim6pZic6A9zSr Z0+EWWIN2gcpQoUx5ERhhqgauwvLaPjwimBIp/uCsAvo5tEHxZjdu0V9ohItPD0bpgqtv7kCs0WDR GB2J1fUTMNue3u3l9JxrKZqSHeiY7/UjJoR3C13r+875fK6ooiO3OJJStwB47nRv6SXJBu62dTdQw TRSx2VKS4q7cRMWhnHxInqJ7AEM3bHQlNhrQS9PDHh43QZX101meAEskW2W+HAg50UZFR+EhBjuuz 4k9QYGo7vCct8w==; 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 1qRVRD-0000hs-8r; Thu, 03 Aug 2023 06:20:11 -0400 Date: Thu, 03 Aug 2023 13:20:20 +0300 Message-Id: <835y5wxw9n.fsf@gnu.org> From: Eli Zaretskii To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= In-Reply-To: (message from =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= on Thu, 3 Aug 2023 11:15:50 +0100) Subject: Re: bug#62198: eglot feature request: set Initialize.ClientInfo.{Name, Version} References: <87cz1es23m.fsf@betli.tmit.bme.hu> <87351psckc.fsf@betli.tmit.bme.hu> <831qgkzi9d.fsf@gnu.org> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 62198-done Cc: 62198-done@debbugs.gnu.org, felician.nemeth@gmail.com, adonovan@google.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: João Távora > Date: Thu, 3 Aug 2023 11:15:50 +0100 > Cc: Felician Nemeth , 62198@debbugs.gnu.org, adonovan@google.com > > Sorry, > > I think Felicián's patch looks good, and we should push it to master. Thanks, done, and closing the bug. From unknown Fri Jun 20 19:54:21 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 31 Aug 2023 11:24:11 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator