From debbugs-submit-bounces@debbugs.gnu.org Sun Feb 19 14:15:55 2023 Received: (at submit) by debbugs.gnu.org; 19 Feb 2023 19:15:55 +0000 Received: from localhost ([127.0.0.1]:49670 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTpA9-0000WR-OD for submit@debbugs.gnu.org; Sun, 19 Feb 2023 14:15:55 -0500 Received: from lists.gnu.org ([209.51.188.17]:37790) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTpA6-0000WI-V6 for submit@debbugs.gnu.org; Sun, 19 Feb 2023 14:15:52 -0500 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 1pTpA6-0004N1-Mz for bug-gnu-emacs@gnu.org; Sun, 19 Feb 2023 14:15:50 -0500 Received: from mail-lf1-x134.google.com ([2a00:1450:4864:20::134]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pTpA2-000565-PU for bug-gnu-emacs@gnu.org; Sun, 19 Feb 2023 14:15:50 -0500 Received: by mail-lf1-x134.google.com with SMTP id g15so1465073lfv.13 for ; Sun, 19 Feb 2023 11:15:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd.ie; s=google21; h=mime-version:user-agent:message-id:date:subject:to:from:from:to:cc :subject:date:message-id:reply-to; bh=9Pd8V6uYks7nk3Wa7RYX085K4JbR1/VeQt4GfSC9MHs=; b=FLsLlYOCqjgfBB8WTN87q5nX3qtF06JTd1e84rNLLSzljud0HNA4TwehOf9k7UL7ym Tt7WlM4wqdetIYpKIE+Sd7+wvmttbxVlE46KiA2k9K8Z33ObBuyhbgBDXmJM6Uyg+OX/ oz/g4ZH+/uUdf2ev2YNEfD7Y8k47pyM6HC3c/H40J8evG5T7vsbr6LvXq0FtgA4lzLnN gw8g4ZVwJKny/NzHtSPXx8vRMG5hJdAKINTMNfkJx0mhWgnVECVP4RI15eA+cVeX+7TV OjG01WmpnMPn/CvfKCvBCpOy2loPhLTR+D80wYTFVEtCav0BeSw6q2As7HQRxv4d3+EX eKoQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:user-agent:message-id:date:subject:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=9Pd8V6uYks7nk3Wa7RYX085K4JbR1/VeQt4GfSC9MHs=; b=Y1P1AnBBjCeJX1T4Vi2k9AcMd0ClQ9XNkHuT5xLu56reEVYpgBS+YDqtbITTNnw793 gA3k+tsh0p8u7P68K5kss3nlNxyQULbCM0/IbnLYl8dSUg879QQ8FvnPplw+NZUIqKuU Z8b42OSa8pu0Tk0lhJWVvV801aL1RD+jNuAXgpHwNTB+9+jfX1iGf3uIC0UdhAJ0QN/w 5CbaLAINCJM+3usl7/79Nv/AJOIcMH6QXvHmN6Qo4SgmoH1YiOD8X3Jpb8naoScCNJzE YpbprzT6Cwn0E/50OJ0bfvyoAxXPjX35N74Zdqf+dOXWAxlQvSUy0UjAQHyqjuV9eZaZ Fy9g== X-Gm-Message-State: AO0yUKWxPQ/vI5ryvIpDMCQse7HHt8xFOVH8BUIfXqoEuXSYfc+yMAqr U68JnUjkZRFDXyDz+PqIqaZj4WxZMrz1CbRO X-Google-Smtp-Source: AK7set/jpmcE9JiIlb6ac8bvdqI7Unm3TkFOEDwTSgVlWjWkR9I7d7VFRR15SjLgDQKl+np0Y88jlw== X-Received: by 2002:a1c:545b:0:b0:3dc:50dd:361b with SMTP id p27-20020a1c545b000000b003dc50dd361bmr5109414wmi.5.1676833806789; Sun, 19 Feb 2023 11:10:06 -0800 (PST) Received: from localhost ([109.78.154.153]) by smtp.gmail.com with ESMTPSA id m17-20020a7bce11000000b003e209b45f6bsm12253461wmc.29.2023.02.19.11.10.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 19 Feb 2023 11:10:05 -0800 (PST) From: "Basil L. Contovounesios" To: bug-gnu-emacs@gnu.org Subject: 30.0.50; Fix Eglot tests that need HOME=~USER X-Debbugs-Cc: =?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vora=22?= Date: Sun, 19 Feb 2023 19:10:03 +0000 Message-ID: <87ilfxv5dg.fsf@tcd.ie> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Received-SPF: pass client-ip=2a00:1450:4864:20::134; envelope-from=contovob@tcd.ie; helo=mail-lf1-x134.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, 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.4 (-) 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.4 (--) --=-=-= Content-Type: text/plain Severity: minor Tags: patch With pylsp and rust-analyzer installed, I have been seeing some or all of these failures for quite a while now: --=-=-= Content-Type: application/gzip Content-Disposition: attachment; filename=eglot-tests.txt.gz Content-Transfer-Encoding: base64 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 --=-=-= Content-Type: text/plain The main problem is that: 0. test/Makefile.in sets HOME=/nonexistent 1. lisp/emacs-lisp/ert-x.el sets HOME=/tmp :( 2. eglot--call-with-fixture tries to detect when HOME is nonexistent, but /tmp exists, so that's left unchanged 3. The Rust tools look under HOME=/tmp for which toolchain to use, but the answer is under ~USER, so they give up The following patch temporarily sets HOME=~USER in only those tests that need it. The patch consolidates some let-bindings into a single form to minimise collateral indentation changes. It also bumps the rust-analyzer client/registerCapability timeout from 1 second to 3, because sometimes 1 second was too short a wait. Finally, it updates the expected autopep8 reformatting results to what I see locally, and skips a test that fails without YASnippet. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-Fix-eglot-tests.el-that-need-HOME-USER.patch >From 825d0781522f87c6a2cc954a85b2c48a499d4857 Mon Sep 17 00:00:00 2001 From: "Basil L. Contovounesios" Date: Sun, 19 Feb 2023 17:41:48 +0000 Subject: [PATCH 1/2] Fix eglot-tests.el that need HOME=~USER * test/lisp/progmodes/eglot-tests.el (eglot-tests--real-home-env): New helper function. (eglot-test-rust-analyzer-watches-files) (eglot-test-diagnostic-tags-unnecessary-code) (eglot-test-rust-analyzer-hover-after-edit) (eglot-test-rust-on-type-formatting) (eglot-test-project-wide-diagnostics-rust-analyzer): Use it to run cargo and rust-analyzer under HOME=~USER. (eglot-test-python-autopep-formatting): Update expected formats for latest autopep8. (eglot-test-json-basic): Skip when YASnippet is missing. --- test/lisp/progmodes/eglot-tests.el | 108 +++++++++++++++++------------ 1 file changed, 63 insertions(+), 45 deletions(-) diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eglot-tests.el index 4b6528351b2..4e1b025e63f 100644 --- a/test/lisp/progmodes/eglot-tests.el +++ b/test/lisp/progmodes/eglot-tests.el @@ -86,6 +86,14 @@ eglot--make-file-or-dir (t (eglot--error "Expected a string or a directory spec"))))) +(defun eglot-tests--real-home-env () + "Return a `process-environment' with user's real HOME directory. +This uses `user-login-name' to work around cases where the HOME +environment variable has been set to something like +\"/nonexistent\" or `temporary-file-directory'." + (cons (concat "HOME=" (expand-file-name (concat "~" (user-login-name)))) + process-environment)) + (defun eglot--call-with-fixture (fixture fn) "Helper for `eglot--with-fixture'. Run FN under FIXTURE." (let* ((fixture-directory (make-nearby-temp-file "eglot--fixture" t)) @@ -394,27 +402,27 @@ eglot-test-rust-analyzer-watches-files "Start rust-analyzer. Notify it when a critical file changes." (skip-unless (executable-find "rust-analyzer")) (skip-unless (executable-find "cargo")) - (let ((eglot-autoreconnect 1)) - (eglot--with-fixture - '(("watch-project" . (("coiso.rs" . "bla") - ("merdix.rs" . "bla")))) - (with-current-buffer - (eglot--find-file-noselect "watch-project/coiso.rs") + (eglot--with-fixture + '(("watch-project" . (("coiso.rs" . "bla") + ("merdix.rs" . "bla")))) + (with-current-buffer + (eglot--find-file-noselect "watch-project/coiso.rs") + (let ((eglot-autoreconnect 1) + ;; Cargo doesn't work under `temporary-file-directory'. + (process-environment (eglot-tests--real-home-env)) + register-id) (should (zerop (shell-command "cargo init"))) - (eglot--sniffing ( - :server-requests s-requests - :client-notifications c-notifs - :client-replies c-replies - ) + (eglot--sniffing ( :server-requests s-requests + :client-notifications c-notifs + :client-replies c-replies) (should (eglot--tests-connect)) - (let (register-id) - (eglot--wait-for (s-requests 1) - (&key id method &allow-other-keys) - (setq register-id id) - (string= method "client/registerCapability")) - (eglot--wait-for (c-replies 1) - (&key id error &allow-other-keys) - (and (eq id register-id) (null error)))) + (eglot--wait-for (s-requests 3) + (&key id method &allow-other-keys) + (setq register-id id) + (string= method "client/registerCapability")) + (eglot--wait-for (c-replies 1) + (&key id error &allow-other-keys) + (and (eq id register-id) (null error))) (delete-file "Cargo.toml") (eglot--wait-for (c-notifs 3 "waiting for didChangeWatchedFiles notification") @@ -453,7 +461,9 @@ eglot-test-diagnostic-tags-unnecessary-code "fn main() -> () { let test=3; }")))) (with-current-buffer (eglot--find-file-noselect "diagnostic-tag-project/main.rs") - (let ((eglot-server-programs '((rust-mode . ("rust-analyzer"))))) + (let ((eglot-server-programs '((rust-mode . ("rust-analyzer")))) + ;; Cargo doesn't work under `temporary-file-directory'. + (process-environment (eglot-tests--real-home-env))) (should (zerop (shell-command "cargo init"))) (eglot--sniffing (:server-notifications s-notifs) (eglot--tests-connect) @@ -496,21 +506,20 @@ eglot-test-rust-analyzer-hover-after-edit "fn test() -> i32 { let test=3; return te; }")))) (with-current-buffer (eglot--find-file-noselect "hover-project/main.rs") - (should (zerop (shell-command "cargo init"))) - (eglot--sniffing ( - :server-replies s-replies - :client-requests c-reqs - ) - (eglot--tests-connect) - (goto-char (point-min)) - (search-forward "return te") - (insert "st") - (progn - ;; simulate these two which don't happen when buffer isn't + (let (;; Cargo doesn't work under `temporary-file-directory'. + (process-environment (eglot-tests--real-home-env)) + pending-id) + (should (zerop (shell-command "cargo init"))) + (eglot--sniffing ( :server-replies s-replies + :client-requests c-reqs) + (eglot--tests-connect) + (goto-char (point-min)) + (search-forward "return te") + (insert "st") + ;; Simulate these two which don't happen when buffer isn't ;; visible in a window. (eglot--signal-textDocument/didChange) - (eglot--eldoc-on-demand)) - (let (pending-id) + (eglot--eldoc-on-demand) (eglot--wait-for (c-reqs 2) (&key id method &allow-other-keys) (setq pending-id id) @@ -683,18 +692,22 @@ eglot-test-python-autopep-formatting (with-current-buffer (eglot--find-file-noselect "project/something.py") (should (eglot--tests-connect)) - ;; Try to format just the second line + ;; Try to format just the second line. (search-forward "b():pa") (eglot-format (line-beginning-position) (line-end-position)) - (should (looking-at "ss")) - (should - (or (string= (buffer-string) "def a():pass\n\n\ndef b(): pass\n") - ;; autopep8 2.0.0 (pycodestyle: 2.9.1) - (string= (buffer-string) "def a():pass\n\ndef b(): pass"))) - ;; now format the whole buffer + (should (looking-at-p "ss")) + (should (member (buffer-string) + '(;; autopep8 2.0.1 (pycodestyle: 2.10.0) + "def a():pass\n\ndef b():\n pass\n" + ;; autopep8 2.0.0 (pycodestyle: 2.9.1) + "def a():pass\n\ndef b(): pass" + "def a():pass\n\n\ndef b(): pass\n"))) + ;; Now format the whole buffer. (eglot-format-buffer) - (should - (string= (buffer-string) "def a(): pass\n\n\ndef b(): pass\n"))))) + (should (member (buffer-string) + '(;; autopep8 2.0.1 (pycodestyle: 2.10.0) + "def a():\n pass\n\n\ndef b():\n pass\n" + "def a(): pass\n\n\ndef b(): pass\n")))))) (ert-deftest eglot-test-python-yapf-formatting () "Test formatting in the pylsp python LSP." @@ -728,12 +741,14 @@ eglot-test-rust-on-type-formatting "fn main() -> () {\n foo\n .bar()\n ")))) (with-current-buffer (eglot--find-file-noselect "on-type-formatting-project/main.rs") - (let ((eglot-server-programs '((rust-mode . ("rust-analyzer"))))) + (let ((eglot-server-programs '((rust-mode . ("rust-analyzer")))) + ;; Cargo doesn't work under `temporary-file-directory'. + (process-environment (eglot-tests--real-home-env))) (should (zerop (shell-command "cargo init"))) (eglot--sniffing (:server-notifications s-notifs) (should (eglot--tests-connect)) (eglot--wait-for (s-notifs 10) (&key method &allow-other-keys) - (string= method "textDocument/publishDiagnostics"))) + (string= method "textDocument/publishDiagnostics"))) (goto-char (point-max)) (eglot--simulate-key-event ?.) (should (looking-back "^ \\.")))))) @@ -808,7 +823,9 @@ eglot-test-project-wide-diagnostics-rust-analyzer ("other-file.rs" . "fn foo() -> () { let hi=3; }")))) (eglot--make-file-or-dir '(".git")) - (let ((eglot-server-programs '((rust-mode . ("rust-analyzer"))))) + (let ((eglot-server-programs '((rust-mode . ("rust-analyzer")))) + ;; Cargo doesn't work under `temporary-file-directory'. + (process-environment (eglot-tests--real-home-env))) ;; Open other-file, and see diagnostics arrive for main.rs (with-current-buffer (eglot--find-file-noselect "project/other-file.rs") (should (zerop (shell-command "cargo init"))) @@ -829,6 +846,7 @@ eglot-test-project-wide-diagnostics-rust-analyzer (ert-deftest eglot-test-json-basic () "Test basic autocompletion in vscode-json-languageserver." (skip-unless (executable-find "vscode-json-languageserver")) + (skip-unless (fboundp 'yas-minor-mode)) (eglot--with-fixture '(("project" . (("p.json" . "{\"foo.b") -- 2.39.1 --=-=-= Content-Type: text/plain While putting this together, I also noticed some minor housekeeping opportunities. The following patch mainly removes the symbol-value pair syntax from eglot--with-fixture. The setting and unsetting of these variables happened quite far away from the body, so they could not be used to change, say, process-environment, since eglot--with-fixture already binds that. I think requiring the body to let-bind its own variables is not only sufficient, but more general and less surprising. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0002-Minor-housekeeping-in-ert-x-and-eglot-tests.patch >From 731c39a27b9a21754cbee73e7199366a7cc38d82 Mon Sep 17 00:00:00 2001 From: "Basil L. Contovounesios" Date: Sun, 19 Feb 2023 18:09:06 +0000 Subject: [PATCH 2/2] Minor housekeeping in ert-x and eglot-tests * lisp/emacs-lisp/ert-x.el (ert-remote-temporary-file-directory): Don't add trailing slash to HOME. * test/lisp/progmodes/eglot-tests.el: Move footer line to EOF. (eglot--with-fixture): Don't allow fixture elements to be symbol-value pairs. This feature was used in only one test. The same effect can be achieved in a simpler way, and closer to the body, with let-bindings. (eglot--make-file-or-dir): Ensure default-directory ends with a slash. Simplify using with-temp-file. (eglot--call-with-fixture): Ensure default-directory ends with a slash. Remove symbol setting and restoring logic. Modify process-environment only when needed, and simplify using eglot-tests--real-home-env. Leave XDG_CONFIG_HOME alone; it is already unexported in test/Makefile.in. Fix let-binding syntax. (eglot--cleanup-after-test): Remove symbol restoring logic. (eglot--eldoc-on-demand, eglot--tests-force-full-eldoc): Fix commentary typos. (eglot-test-ensure): Adapt c-mode-hook binding to eglot--with-fixture changes. --- lisp/emacs-lisp/ert-x.el | 2 +- test/lisp/progmodes/eglot-tests.el | 97 ++++++++++++------------------ 2 files changed, 39 insertions(+), 60 deletions(-) diff --git a/lisp/emacs-lisp/ert-x.el b/lisp/emacs-lisp/ert-x.el index 98a017c8a8e..3bf9b59f874 100644 --- a/lisp/emacs-lisp/ert-x.el +++ b/lisp/emacs-lisp/ert-x.el @@ -563,7 +563,7 @@ ert-remote-temporary-file-directory ;; Emacs's Makefile sets $HOME to a nonexistent value. Needed ;; in batch mode only, therefore. (when (and noninteractive (not (file-directory-p "~/"))) - (setenv "HOME" temporary-file-directory)) + (setenv "HOME" (directory-file-name temporary-file-directory))) (format "/mock::%s" temporary-file-directory)))) "Temporary directory for remote file tests.") diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eglot-tests.el index 4e1b025e63f..cce5b572521 100644 --- a/test/lisp/progmodes/eglot-tests.el +++ b/test/lisp/progmodes/eglot-tests.el @@ -60,28 +60,25 @@ ;;; Helpers (defmacro eglot--with-fixture (fixture &rest body) - "Setup FIXTURE, call BODY, teardown FIXTURE. + "Set up FIXTURE, call BODY, tear down FIXTURE. FIXTURE is a list. Its elements are of the form (FILE . CONTENT) to create a readable FILE with CONTENT. FILE may be a directory name and CONTENT another (FILE . CONTENT) list to specify a -directory hierarchy. FIXTURE's elements can also be (SYMBOL -VALUE) meaning SYMBOL should be bound to VALUE during BODY and -then restored." +directory hierarchy." (declare (indent 1) (debug t)) - `(eglot--call-with-fixture - ,fixture #'(lambda () ,@body))) + `(eglot--call-with-fixture ,fixture (lambda () ,@body))) (defun eglot--make-file-or-dir (ass) (let ((file-or-dir-name (car ass)) (content (cdr ass))) (cond ((listp content) (make-directory file-or-dir-name 'parents) - (let ((default-directory (concat default-directory "/" file-or-dir-name))) + (let* ((subdir (expand-file-name file-or-dir-name default-directory)) + (default-directory (file-name-as-directory subdir))) (mapcan #'eglot--make-file-or-dir content))) ((stringp content) - (with-temp-buffer - (insert content) - (write-region nil nil file-or-dir-name nil 'nomessage)) + (with-temp-file file-or-dir-name + (insert content)) (list (expand-file-name file-or-dir-name))) (t (eglot--error "Expected a string or a directory spec"))))) @@ -96,43 +93,27 @@ eglot-tests--real-home-env (defun eglot--call-with-fixture (fixture fn) "Helper for `eglot--with-fixture'. Run FN under FIXTURE." - (let* ((fixture-directory (make-nearby-temp-file "eglot--fixture" t)) - (default-directory fixture-directory) - file-specs created-files - syms-to-restore + (let* ((fixture-directory (make-nearby-temp-file "eglot--fixture-" t)) + (default-directory (file-name-as-directory fixture-directory)) + created-files new-servers test-body-successful-p) - (dolist (spec fixture) - (cond ((symbolp spec) - (push (cons spec (symbol-value spec)) syms-to-restore) - (set spec nil)) - ((symbolp (car spec)) - (push (cons (car spec) (symbol-value (car spec))) syms-to-restore) - (set (car spec) (cadr spec))) - ((stringp (car spec)) (push spec file-specs)))) (unwind-protect - (let* ((home (getenv "HOME")) - (process-environment - (append - `(;; Set XDF_CONFIG_HOME to /dev/null to prevent - ;; user-configuration to have an influence on - ;; language servers. (See github#441) - "XDG_CONFIG_HOME=/dev/null" - ;; ... on the flip-side, a similar technique by - ;; Emacs's test makefiles means that HOME is set to - ;; /nonexistent. This breaks some common - ;; installations for LSP servers like pylsp, making - ;; these tests mostly useless, so we hack around it - ;; here with a great big hack. - ,(format "HOME=%s" - (if (file-exists-p home) home - (format "/home/%s" (getenv "USER"))))) - process-environment)) - ;; Prevent "Can't guess python-indent-offset ..." messages. - (python-indent-guess-indent-offset-verbose . nil) - (eglot-server-initialized-hook - (lambda (server) (push server new-servers)))) - (setq created-files (mapcan #'eglot--make-file-or-dir file-specs)) + (let ((process-environment + (if (file-exists-p "~") + process-environment + ;; `test/Makefile' sets `HOME=/nonexistent' (and + ;; `ert-remote-temporary-file-directory' sets it to + ;; `temporary-file-directory'). This breaks some + ;; common installations for LSP servers like pylsp, + ;; making these tests mostly useless, so we hack + ;; around it here with a great big hack. + (eglot-tests--real-home-env))) + ;; Prevent "Can't guess python-indent-offset ..." messages. + (python-indent-guess-indent-offset-verbose nil) + (eglot-server-initialized-hook + (lambda (server) (push server new-servers)))) + (setq created-files (mapcan #'eglot--make-file-or-dir fixture)) (prog1 (funcall fn) (setq test-body-successful-p t))) (eglot--message @@ -165,18 +146,15 @@ eglot--call-with-fixture (t (eglot--message "Preserved for inspection: %s" (mapconcat #'buffer-name buffers ", ")))))))) - (eglot--cleanup-after-test fixture-directory created-files syms-to-restore))))) + (eglot--cleanup-after-test fixture-directory created-files))))) -(defun eglot--cleanup-after-test (fixture-directory created-files syms-to-restore) +(defun eglot--cleanup-after-test (fixture-directory created-files) (let ((buffers-to-delete - (delete nil (mapcar #'find-buffer-visiting created-files)))) - (eglot--message "Killing %s, wiping %s, restoring %s" + (delq nil (mapcar #'find-buffer-visiting created-files)))) + (eglot--message "Killing %s, wiping %s" buffers-to-delete - fixture-directory - (mapcar #'car syms-to-restore)) - (cl-loop for (sym . val) in syms-to-restore - do (set sym val)) - (dolist (buf buffers-to-delete) ;; have to save otherwise will get prompted + fixture-directory) + (dolist (buf buffers-to-delete) ;; Have to save otherwise will get prompted. (with-current-buffer buf (save-buffer) (kill-buffer))) (delete-directory fixture-directory 'recursive) ;; Delete Tramp buffers if needed. @@ -476,11 +454,11 @@ eglot-test-diagnostic-tags-unnecessary-code (should (eq 'eglot-diagnostic-tag-unnecessary-face (face-at-point)))))))) (defun eglot--eldoc-on-demand () - ;; Trick Eldoc 1.1.0 into accepting on-demand calls. + ;; Trick ElDoc 1.1.0 into accepting on-demand calls. (eldoc t)) (defun eglot--tests-force-full-eldoc () - ;; FIXME: This uses some Eldoc implementation defatils. + ;; FIXME: This uses some ElDoc implementation details. (when (buffer-live-p eldoc--doc-buffer) (with-current-buffer eldoc--doc-buffer (let ((inhibit-read-only t)) @@ -898,9 +876,9 @@ eglot-test-ensure (skip-unless (executable-find "clangd")) (eglot--with-fixture `(("project" . (("foo.c" . "int foo() {return 42;}") - ("bar.c" . "int bar() {return 42;}"))) - (c-mode-hook (eglot-ensure))) - (let (server) + ("bar.c" . "int bar() {return 42;}")))) + (let ((c-mode-hook '(eglot-ensure)) + server) ;; need `ert-simulate-command' because `eglot-ensure' ;; relies on `post-command-hook'. (with-current-buffer @@ -1331,8 +1309,9 @@ eglot-test-same-server-multi-mode (should (eq (eglot-current-server) server)))))) (provide 'eglot-tests) -;;; eglot-tests.el ends here ;; Local Variables: ;; checkdoc-force-docstrings-flag: nil ;; End: + +;;; eglot-tests.el ends here -- 2.39.1 --=-=-= Content-Type: text/plain WDYT? And should any fixes go to emacs-29 or master? Thanks, -- Basil $ pylsp --version pylsp v1.7.1 $ autopep8 --version autopep8 2.0.1 (pycodestyle: 2.10.0) $ cargo --version cargo 1.67.1 (8ecd4f20a 2023-01-10) $ rust-analyzer --version rust-analyzer 0.3.1402-standalone In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, X toolkit, cairo version 1.16.0, Xaw3d scroll bars) of 2023-02-19 built on tia Repository revision: 8fba4cff1bd0b953af9e950e872e1eaecff179d7 Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12101007 System Description: Debian GNU/Linux bookworm/sid Configured using: 'configure 'CFLAGS=-Og -ggdb3' -C --prefix=/home/blc/.local --enable-checking=structs --with-file-notification=yes --with-x-toolkit=lucid --with-x' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG JSON LCMS2 LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 M17N_FLT MODULES NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP X11 XAW3D XDBE XIM XINPUT2 XPM LUCID ZLIB Important settings: value of $LANG: en_IE.UTF-8 value of $XMODIFIERS: @im=ibus locale-coding-system: utf-8-unix Major mode: Lisp Interaction Minor modes in effect: tooltip-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t line-number-mode: t indent-tabs-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message mailcap yank-media puny dired dired-loaddefs rfc822 mml mml-sec password-cache epa derived epg rfc6068 epg-config gnus-util text-property-search time-date subr-x mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader cl-loaddefs cl-lib sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads dbusbind inotify lcms2 dynamic-setting system-font-setting font-render-setting cairo x-toolkit xinput2 x multi-tty make-network-process emacs) Memory information: ((conses 16 36554 8763) (symbols 48 5169 0) (strings 32 13853 1554) (string-bytes 1 377508) (vectors 16 9296) (vector-slots 8 147812 13111) (floats 8 23 25) (intervals 56 245 0) (buffers 984 10)) --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Sun Feb 19 14:39:07 2023 Received: (at 61637) by debbugs.gnu.org; 19 Feb 2023 19:39:07 +0000 Received: from localhost ([127.0.0.1]:49727 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTpWd-0001Cb-9P for submit@debbugs.gnu.org; Sun, 19 Feb 2023 14:39:07 -0500 Received: from mail-oi1-f182.google.com ([209.85.167.182]:42523) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTpWa-0001C4-5P for 61637@debbugs.gnu.org; Sun, 19 Feb 2023 14:39:05 -0500 Received: by mail-oi1-f182.google.com with SMTP id bx17so894755oib.9 for <61637@debbugs.gnu.org>; Sun, 19 Feb 2023 11:39:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=DeVjaPnWzFfjbHY2yfQJ9Zq9Yt6rsKXOZXUH9i14Q4Q=; b=LllzW+oJvHA0br7FWhDyEIPludrRFdDvRiivvofHhpG8r6idED7Rg7qniaEfrImh4Y KiZjsqiPxQcOw8U6n4cDLDJG5YFmnSvu2Cm6Jsp8JUIccXqlOcwqUTmLlrk7OugqdtLE 6vrrWFNWtUunHavN/YUKzbi1mac1UTUZV1X3MQ3AEycobGpIV9WOhHsKbiRT1508Bj5l NvTSY7m/k6L9UkJARsX14rvV5iy313DmohabnXU7hgWtER+OYn/Tje7tWRoZVynJzm18 uf/TfNDGql/ZuKQNX2ot9KnBdKspPAJqBxgDM2QVfUvXy5jQlI/5nsSCZvrCO+bh/qb2 ujTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=DeVjaPnWzFfjbHY2yfQJ9Zq9Yt6rsKXOZXUH9i14Q4Q=; b=vVyQudaAnpplnD8kVwIXU8raIL/ACA36R6AcPK6Sj9S/DfPGA5CQL1FcjZRJqgn83+ hNovtjJy4Q8FGdqKpIa7Gh0mKVoWHFRzTzUiLYjwVIbZwC1sck+DNdpO+xboLwZceiQg IZiQfoG1QRi0sWdNm/tVDG9ZpPQzZ0hut+dySdOj1+dVlGU+8xSD0lXog9o8xkejDtbN 7EyqBLYU/ikuDqzQNPZW3LJv0RMtyTC62GmVRLRZ9ZoXFbA5vWcJq3QJArhxPj3vXjUC uwYCbtHiy5qwIbuLW2m4hpGzgQJBNtk4xc+gepNkAP9u6OcS84FjbCqJfmTaXWnfv9jE W/gw== X-Gm-Message-State: AO0yUKVDa8uMwQKh7gO/aQDP///5QcbaQPwgpUtwc4qHza8GwJcdm9pP PdY4AZUDGzMatVuzh3HlYxpcIIaqmWSpNV8slWc= X-Google-Smtp-Source: AK7set+8xEwm+niTJn8ooN3gBTnrD5kN3AT0w73urxox1LKjrDX/lfZbQot7MxQU9E4YAU/O8q6xNR5h427J9meaPow= X-Received: by 2002:a05:6808:128b:b0:37b:9a3:136f with SMTP id a11-20020a056808128b00b0037b09a3136fmr238966oiw.6.1676835538567; Sun, 19 Feb 2023 11:38:58 -0800 (PST) MIME-Version: 1.0 References: <87ilfxv5dg.fsf@tcd.ie> In-Reply-To: <87ilfxv5dg.fsf@tcd.ie> From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Date: Sun, 19 Feb 2023 19:38:47 +0000 Message-ID: Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER To: "Basil L. Contovounesios" Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 61637 Cc: 61637@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 (-) Hi Basil, Both patches look generally good, though I haven't tested them, so I'm trusting you did and they generally add robustness. If that's the case, go ahead and push (to emacs-29, presumably since this is fixing bugs in the test suite, but master isn't that bad either). The only nit I would point out is that there seems to be some unrelated housekeeping already in the first patch that could be moved to the second patch, or maybe a separate commit. The yasnippet-related fix could also be its own commit. But again, that's only a minor nit. Thanks, Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 20 04:22:48 2023 Received: (at 61637) by debbugs.gnu.org; 20 Feb 2023 09:22:48 +0000 Received: from localhost ([127.0.0.1]:50507 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pU2Nj-0001oD-UG for submit@debbugs.gnu.org; Mon, 20 Feb 2023 04:22:48 -0500 Received: from mail-wm1-f51.google.com ([209.85.128.51]:36559) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pU2Nh-0001nw-3C for 61637@debbugs.gnu.org; Mon, 20 Feb 2023 04:22:46 -0500 Received: by mail-wm1-f51.google.com with SMTP id l2-20020a05600c1d0200b003e1f6dff952so393591wms.1 for <61637@debbugs.gnu.org>; Mon, 20 Feb 2023 01:22:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd.ie; s=google21; 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=LD8S4ql3XUEBHXYWOeyJLecirKDcSScVLN4ZIFX8Oj8=; b=KpMeFeLhinUANHG++e5FZKmnGo6XsaLChTxr577K7AmgIv2kxJoZ01E3VgSrvdKMnK QNhqN9ph5KOTP0TGLY30A67PImcU+mMothxI+o3JvHe7j25GRS4mY2azVRjtMXiy3c5J 173Fiypl0uc1usX8OwwKStcZ69stfufjSJJvmuDpNYhhBxcONZeYG0ntr9MbVxbijPT8 e9mgW3IHGf259BKL4I9LYpd31/w78x3hNOhEe5YS7KnMIlVk402U8g81uM0r9mYk0eBY 8hEluYRRmUSnxdqDnvoqCJCcVqMwc20SlCKiMQo3jQpuhUbjIIFuEPwFt3Y+X/Xzmn4w 4LHw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=LD8S4ql3XUEBHXYWOeyJLecirKDcSScVLN4ZIFX8Oj8=; b=xvopnVPLXDT0rWX861r68EKr80m6WSynJ1TQ5NIyipogBwJ7DQSlbLLrFfHMeRevEw ad1mzGXUT6/0yl/oFnPe0KOgLVLnpMEik9ZNhLylDZH3qRA3bIsdte96kHFm5bKu2Ri5 OFZPjJTnlWtWkUFH5RrtfJuL+i8fJR375jYxhtDvqmE6iVcL6uOEUKGnvOoTNFFSetdg MEYTA3tllQwK7NEzp6L7ajun1LoD8DSsZ7R7nY9stvn3YVqos42cHsvyAF3eE8XEvpHr Ol/Adj7YweWyZvZ2zqFrg8gtZzPJTfkBpWO2sSRxWG0OtHJiuvfbzrALrtZ9Pb/+Vnny HzCA== X-Gm-Message-State: AO0yUKVZMy2nT62E/5IzztKR9ETNFd2WovRjm9o61mL4KoLUc4E/RADx 0y86jUtheBm10dV2fxERkejxWg== X-Google-Smtp-Source: AK7set+wSiM1w4jczZzOZEgEUqH6x0Pikv03dK4Tq//EktXw9GzaTkZFZX1zJwvqChqO0w7M2hfAVw== X-Received: by 2002:a05:600c:332f:b0:3e2:232b:a05d with SMTP id q47-20020a05600c332f00b003e2232ba05dmr8061195wmp.20.1676884958105; Mon, 20 Feb 2023 01:22:38 -0800 (PST) Received: from localhost ([109.79.42.109]) by smtp.gmail.com with ESMTPSA id v10-20020a05600c214a00b003e209186c07sm602114wml.19.2023.02.20.01.22.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 Feb 2023 01:22:37 -0800 (PST) From: "Basil L. Contovounesios" To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vora=22's?= message of "Sun, 19 Feb 2023 19:38:47 +0000") References: <87ilfxv5dg.fsf@tcd.ie> Date: Mon, 20 Feb 2023 09:22:36 +0000 Message-ID: <87h6vgelnn.fsf@tcd.ie> 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: 61637 Cc: 61637@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 (-) Jo=C3=A3o T=C3=A1vora [2023-02-19 19:38 +0000] wrote: > Both patches look generally good, though I haven't tested them, > so I'm trusting you did and they generally add robustness. Thanks, indeed 'make check' now/still succeeds locally. > If that's the case, go ahead and push (to emacs-29, presumably > since this is fixing bugs in the test suite, but master isn't that > bad either). The small change in ert-x.el, and the proximity to an emacs-29 RC, are the reasons I wanted to double check with Eli about where these changes should go. Perhaps I should split out the ert-x.el change for master, and the rest can go to emacs-29? > The only nit I would point out is that there seems to be some > unrelated housekeeping already in the first patch that could > be moved to the second patch, or maybe a separate commit. You mean, the indentation and commentary fixes? The impression I got is that these kinds of changes are more welcome in emacs.git when the surrounding code is already being touched, as opposed to making small whitespace-only changes to functions that are not otherwise being changed. I have little personal preference either way. > The yasnippet-related fix could also be its own commit. But > again, that's only a minor nit. Sure, I can break out the autopep8 and YASnippet changes if that's preferred. Thanks, --=20 Basil From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 20 04:31:02 2023 Received: (at 61637) by debbugs.gnu.org; 20 Feb 2023 09:31:02 +0000 Received: from localhost ([127.0.0.1]:50517 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pU2Vi-000232-JK for submit@debbugs.gnu.org; Mon, 20 Feb 2023 04:31:02 -0500 Received: from mail-oa1-f45.google.com ([209.85.160.45]:34712) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pU2Ve-00022T-Eb for 61637@debbugs.gnu.org; Mon, 20 Feb 2023 04:31:00 -0500 Received: by mail-oa1-f45.google.com with SMTP id 586e51a60fabf-1720d087ff4so433307fac.1 for <61637@debbugs.gnu.org>; Mon, 20 Feb 2023 01:30:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=CdDrKsRQVkTi+H3neD00Qn1b5MQ7oMzj0y0hLoXqQeI=; b=JCNLBBta84ZD9pV41QBPUCt+fHXj0P8RP1CSz+cpfVZCyK0/ky2ZhNOLz89GXZrIZo ugbt2v5d5QW/dKMW6YAc1/zO7cmAwzheacBc14evq1U2gocLJnUJOFEssEj4TggFNaOn NVJ6sRrs7XR1cJ6VHyqtkB+nJq6Ah0zE3aBxmUB1JaGw348qFAHHND6Jgmn2F2JWHtkf Dp3w3AGvGG9wyXVZopad2QHpF8Jp/VWM72acon6k5mIqLqS+t5ZCuwfgG3PmMb4wv0bh Ga69fBQB1UpZM7tMB0jQpTYdA4Wt/RDLV9LSBnW7o4rXnmgh6viIOZ23doh+z8r9CCp6 xJAg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=CdDrKsRQVkTi+H3neD00Qn1b5MQ7oMzj0y0hLoXqQeI=; b=iJ7IlvsSN2p+Gyh5438XO+AvUmN9kQy4AF+wZLzOrK4ehgM1lQZ3n+1aD0pg3kp+P7 1p/1rPzV73/bva9FqgBcYi3OtwtgKFNJSIUGelk4+hak4w2hIYUYQnef14j9jtIuMNg6 pNC8iKy02udwyrcYjG9vV5NDTNoK8H6OzG2qaG69chwzyz0pd9GDFuUn/ElUmArDqRgK JmMoVI9e/pfl0Frqb2yfn375yBkeNLZzjaMPPuttopgBKavOOpuLK7pWrJL4CrdozZ1Q OhdCWTHUlCwRvtDVsElAF6VB6qkbZ+yKcJoGnODrTnQyHsfRRp8J0qA54Bp1hS5SYAcl Hwog== X-Gm-Message-State: AO0yUKVv5UQ+F8LBLqJ3ejgjHYV28qrZW95TeiznZqTZLMj90PGojziu EXcNtBppb8fdDWyzsDcIdYxTl1JCMqouAY+dlbA= X-Google-Smtp-Source: AK7set+uS4xCZlyIoGF0BE9yA0f4M73k9By7MHIbZ5ckdvH5/Llx9H5S6pctNqOx+gFSkoK0IgnZpbWOZhhs+pvSRtI= X-Received: by 2002:a05:6870:d148:b0:16d:dc93:691d with SMTP id f8-20020a056870d14800b0016ddc93691dmr390306oac.6.1676885452537; Mon, 20 Feb 2023 01:30:52 -0800 (PST) MIME-Version: 1.0 References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> In-Reply-To: <87h6vgelnn.fsf@tcd.ie> From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Date: Mon, 20 Feb 2023 09:30:41 +0000 Message-ID: Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER To: "Basil L. Contovounesios" Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 61637 Cc: 61637@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 (-) On Mon, Feb 20, 2023 at 9:22 AM Basil L. Contovounesios w= rote: > > Jo=C3=A3o T=C3=A1vora [2023-02-19 19:38 +0000] wrote: > > The only nit I would point out is that there seems to be some > > unrelated housekeeping already in the first patch that could > > be moved to the second patch, or maybe a separate commit. > > You mean, the indentation and commentary fixes? The impression I got is > that these kinds of changes are more welcome in emacs.git when the > surrounding code is already being touched, as opposed to making small > whitespace-only changes to functions that are not otherwise being > changed. Those cosmetic changes are most welcome. But my personal preference is to do them in a separate commit, so that when you inspect and try to understand a "functional" commit, you are presented with only just behavior-changing changes, which makes the commit easier to understand. But this is just a nit. > I have little personal preference either way. > > > The yasnippet-related fix could also be its own commit. But > > again, that's only a minor nit. > > Sure, I can break out the autopep8 and YASnippet changes if that's > preferred. Again, this is just a nit. Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 20 08:01:09 2023 Received: (at 61637) by debbugs.gnu.org; 20 Feb 2023 13:01:09 +0000 Received: from localhost ([127.0.0.1]:50882 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pU5n2-0001yi-UR for submit@debbugs.gnu.org; Mon, 20 Feb 2023 08:01:09 -0500 Received: from eggs.gnu.org ([209.51.188.92]:33636) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pU5n1-0001yV-Kz for 61637@debbugs.gnu.org; Mon, 20 Feb 2023 08:01:08 -0500 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 1pU5mv-0002lq-TY; Mon, 20 Feb 2023 08:01: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=aMal9X5MPBaZ0q0GUmN4GDSxn5IsiLsGueD7S2m2vms=; b=eXCHW4qoTCaNlJja3uZE lxuEvS8FLM5soTCtsdz5jsWLEkcMuWtQGaAGDasNNcCHnGR1FLxNiI40xDbbwiFvDxyfsj4KWzvWA pL8Pv4X/BDJSvD33+V/plOU6wAiywt1vSYaWGG0pmOhuctcUT0ZlQXjEHLptWkDWoW6uQYVNitth9 StuBKQiSvHBXyuu6+GeRp4o4mIJMZJnZ2ydPd9M6AHLaxk7JasB7fLRJeBI3plfXLVKQtvRYBFeBm WwoAlfIqatLQmeWR/sVz6neBrk7tD1DUmxiC1kwekf/OE3X3dCGLXvbW8ranN7H3QZEMSdIKjDvl9 nFro+sdF5c7rYA==; 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 1pU5mt-0000Gq-Nj; Mon, 20 Feb 2023 08:01:01 -0500 Date: Mon, 20 Feb 2023 15:01:08 +0200 Message-Id: <83mt58v6cr.fsf@gnu.org> From: Eli Zaretskii To: "Basil L. Contovounesios" In-Reply-To: <87ilfxv5dg.fsf@tcd.ie> (bug-gnu-emacs@gnu.org) Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER References: <87ilfxv5dg.fsf@tcd.ie> 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: 61637 Cc: 61637@debbugs.gnu.org, joaotavora@gmail.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: "João Távora" > Date: Sun, 19 Feb 2023 19:10:03 +0000 > From: "Basil L. Contovounesios" via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > The main problem is that: > 0. test/Makefile.in sets HOME=/nonexistent > 1. lisp/emacs-lisp/ert-x.el sets HOME=/tmp :( > 2. eglot--call-with-fixture tries to detect when HOME is nonexistent, > but /tmp exists, so that's left unchanged > 3. The Rust tools look under HOME=/tmp for which toolchain to use, but > the answer is under ~USER, so they give up > > The following patch temporarily sets HOME=~USER in only those tests that > need it. The patch consolidates some let-bindings into a single form to > minimise collateral indentation changes. It also bumps the > rust-analyzer client/registerCapability timeout from 1 second to 3, > because sometimes 1 second was too short a wait. Finally, it updates > the expected autopep8 reformatting results to what I see locally, and > skips a test that fails without YASnippet. I'd rather we didn't touch the real user home directory during tests, it could do real damage or at the very least cause unintended changes to the user customizations. Why not do this the other way around: trick Eglot to think the home directory doesn't exist (as I understand it already knows how to handle this)? > WDYT? And should any fixes go to emacs-29 or master? Master, please. We have enough adventures on emacs-29 already. And this one is not really critical. From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 20 08:02:23 2023 Received: (at 61637) by debbugs.gnu.org; 20 Feb 2023 13:02:23 +0000 Received: from localhost ([127.0.0.1]:50887 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pU5oF-00020f-EQ for submit@debbugs.gnu.org; Mon, 20 Feb 2023 08:02:23 -0500 Received: from eggs.gnu.org ([209.51.188.92]:48764) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pU5oD-00020T-S6 for 61637@debbugs.gnu.org; Mon, 20 Feb 2023 08:02:22 -0500 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 1pU5o8-0003Bb-La; Mon, 20 Feb 2023 08:02:16 -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=2ZQZgAeu8C3d3dTdnxjHZJuvM9SUxONBbkbmSsbLWYs=; b=II3zWZ/DIdmXgNL7onqz pOeQzJo5Uf/vLlH3V7y+hb97QVk/3iaAMg1x7LSZzfN3FI3n2/wvyE5uZk1bWvfLxIFp8qdqkp0aU +sIM6PAwVshaest/wbpOy8SXTRZg2S0iUuyOcjCEs+12m4f+4S8hvmhA1vK9TMSQBRRFd6YjWTmpd 7g3/v/IggOvB8ZW8XLLpoaHpCKkgThL9RweXhhIiRuxGWnMVMRxl9Yb/dDik3JZ5A034vCiOrxne2 tvyjs1uMZYGxHK4EuXsJrxf/lygVIXR6JboGw97i2fkOZMOBcyvnXGn4bXn0ZZEz895yeNtNKVTzv 3FXf4A+9yZ+xVw==; 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 1pU5nv-0002qS-AJ; Mon, 20 Feb 2023 08:02:14 -0500 Date: Mon, 20 Feb 2023 15:02:12 +0200 Message-Id: <83leksv6az.fsf@gnu.org> From: Eli Zaretskii To: "Basil L. Contovounesios" In-Reply-To: <87h6vgelnn.fsf@tcd.ie> (bug-gnu-emacs@gnu.org) Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 61637 Cc: 61637@debbugs.gnu.org, joaotavora@gmail.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: 61637@debbugs.gnu.org > Date: Mon, 20 Feb 2023 09:22:36 +0000 > From: "Basil L. Contovounesios" via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > João Távora [2023-02-19 19:38 +0000] wrote: > > > Both patches look generally good, though I haven't tested them, > > so I'm trusting you did and they generally add robustness. > > Thanks, indeed 'make check' now/still succeeds locally. > > > If that's the case, go ahead and push (to emacs-29, presumably > > since this is fixing bugs in the test suite, but master isn't that > > bad either). > > The small change in ert-x.el, and the proximity to an emacs-29 RC, are > the reasons I wanted to double check with Eli about where these changes > should go. > > Perhaps I should split out the ert-x.el change for master, and the rest > can go to emacs-29? Please install on master, but please let's first discuss the solution, as I don't like us touch the user's home directory during tests. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 03 20:02:58 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 01:02:59 +0000 Received: from localhost ([127.0.0.1]:34313 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYGIc-0006jw-Kc for submit@debbugs.gnu.org; Fri, 03 Mar 2023 20:02:58 -0500 Received: from mail-wm1-f45.google.com ([209.85.128.45]:39799) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYGIa-0006jj-OZ for 61637@debbugs.gnu.org; Fri, 03 Mar 2023 20:02:57 -0500 Received: by mail-wm1-f45.google.com with SMTP id t25-20020a1c7719000000b003eb052cc5ccso4977505wmi.4 for <61637@debbugs.gnu.org>; Fri, 03 Mar 2023 17:02:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1677891770; 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=VMbuyo3TpHWG8vmbauIKTgotQDt4dB/tDTbB5DlXg44=; b=Fsdad2FCteZRul1CQMzgGToLZ+zKl+2sIkl2Eq+4OEibojCj25dLbY4V7YLa6fcSRs ZCBTMRD9/t7R9Vjr0dMPn3wNnrm8Dx/oWaUvNE/xIbtIUaTSFdrsUbbkLINnkq1/R5qD ZvHEbaSZROow77/Jg+qwsXMPzZ5LVnUxvVHOmGdRB0qXCQ6ua8jpJuNqkgHvBzOF8ztm w5aBxLp9L3UTIhxyVl8d1urSCNn9O58Z29ELmAL+n24gPbHWFRs/+HXe1Px+OiHNFeox eK/BH0NczxrhvmBdL/BTaVY4JnKkn7QruMsqVMXHXfQffRZ4AzKwI5o7g38fiNiEqkK6 ZX4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677891770; 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=VMbuyo3TpHWG8vmbauIKTgotQDt4dB/tDTbB5DlXg44=; b=MXFKsS0hB8FgKOjPoNmJH4muk4DXSVRGzL/npIQNc4OPTTmRWuh5OE4qjhTdELjXeb WDAMQ/ZrM58ro213DNbQC+RlheVnjDbAKDTByUNQUcBc2v6kIRTloyERnfld2EOwJF+E rKua+3tMr71RKBeOqPRuX/YRlTJ9lSGhdq/4JJIBaeixfayG45V5pB4PhJ2LSwhpeuGY LYLly++9AVOnLSaQdZw9ZQM9wZUvD0A+nHPmKj03D4Z2qAAe9F8jhjAyQFO1bvSbutzE oJx5OVBZI1DGpI9qASAMEuiyiJosLyGZJXb4LU0QDTiYwLgyo2N6R/vCYTKLcjyQWIvs 6Frg== X-Gm-Message-State: AO0yUKWwEn/7LKNWD7dG1kJVz2S701KBm8o7t1XsCk1eTFQyIgdi/YBy pLw3/bPwuHaY64b4rfihIeNDD92MZT8= X-Google-Smtp-Source: AK7set/TpMMNq+TrmNf73qmsHNhRqPT8Cbf2qLp50V4m23EIS/ml3yAaaZ0Uls+bHQe8tILhRDK1qQ== X-Received: by 2002:a05:600c:3549:b0:3eb:323e:de79 with SMTP id i9-20020a05600c354900b003eb323ede79mr3313847wmq.6.1677891770493; Fri, 03 Mar 2023 17:02:50 -0800 (PST) Received: from krug (87-196-72-142.net.novis.pt. [87.196.72.142]) by smtp.gmail.com with ESMTPSA id c21-20020a7bc015000000b003e214803343sm7315495wmb.46.2023.03.03.17.02.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 Mar 2023 17:02:49 -0800 (PST) From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: Eli Zaretskii Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <83leksv6az.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 20 Feb 2023 15:02:12 +0200") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> Date: Sat, 04 Mar 2023 01:04:45 +0000 Message-ID: <87bkl972du.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: 61637 Cc: "Basil L. Contovounesios" , 61637@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 (-) Hi Eli, Basil I've recently bumped into this problem myself. As I've been doing more development on Eglot recently, running the test suite becomes a real necessity.=20=20 I installed some language servers like clangd, rust-analyzer and pylsp, and they need to a valid HOME to be able to function. Bare 'make check' always fails for me as of late. If one happens to have the servers installed, the problem is twofold: * For Eglot developers, it's impossible to batch-test Eglot * For other devs who are doing changes elsewhere and looking for breakage, they'll have to reason about the 'make check' failure. Another option is to have eglot-tests.el read a new environment var: diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eglot= -tests.el index 5d5de59a19a..ad994915c52 100644 --- a/test/lisp/progmodes/eglot-tests.el +++ b/test/lisp/progmodes/eglot-tests.el @@ -116,9 +116,7 @@ eglot--call-with-fixture ;; installations for LSP servers like pylsp, making ;; these tests mostly useless, so we hack around it ;; here with a great big hack. - ,(format "HOME=3D%s" - (if (file-exists-p home) home - (format "/home/%s" (getenv "USER"))))) + ,(format "HOME=3D%s" (or (getenv "EGLOT_REAL_HOME") (ge= tenv "HOME")))) process-environment)) ;; Prevent "Can't guess python-indent-offset ..." messages. (python-indent-guess-indent-offset-verbose . nil) This is acceptable for Eglot devs like me, but other devs that don't know about this variable will still be confused. WDYT? > Why not do this the other way around: trick Eglot to think the home > directory doesn't exist (as I understand it already knows how to > handle this)? I don't understand what you mean: this is entirely constrained to how certain language servers work, so eglot.el itself can't handle it. Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 02:46:24 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 07:46:24 +0000 Received: from localhost ([127.0.0.1]:35178 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYMb2-0000hP-0o for submit@debbugs.gnu.org; Sat, 04 Mar 2023 02:46:24 -0500 Received: from eggs.gnu.org ([209.51.188.92]:47630) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYMaz-0000hC-ID for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 02:46:22 -0500 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 1pYMar-0002SQ-Vs; Sat, 04 Mar 2023 02:46:15 -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=DptYWdcbzWAGSoKwDfAYkrsZw+JwwBrXrvIZVbqsxaQ=; b=graA6GAuZc42lS9baAcQ BwBCcu+McoOWGzQVHBgNlxDYFvL6/Ghf/35BPtByU0dWcxo/kB87cDObOcKHJmeEhIDuiqxifOkNl 1hnv1FPxJ/4TzGiHL95x24fHp5QHKs6Kwex7ILQtybkRAgF+14ojQo9F0SYas6CY7WTGeM+tDoiEL qeJ8MjJsufBUWzyLvqvOa3o0jVV7vKvOicNSb+ry76P13TZIc2VR9z/O6FFygOvc6Jmp2eR+M338G /1pBrzzU5ndy3Ewpa6B32ZzjZNzDh8l8tjo3R4fYvsUyan9b4X8ziB4od8VGqy3gW+EUSHG06wJMo /3NLzCaPxFK3LA==; 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 1pYMaq-0004Tl-8A; Sat, 04 Mar 2023 02:46:13 -0500 Date: Sat, 04 Mar 2023 09:46:00 +0200 Message-Id: <83a60tarif.fsf@gnu.org> From: Eli Zaretskii To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= In-Reply-To: <87bkl972du.fsf@gmail.com> (message from =?utf-8?B?Sm/Do28g?= =?utf-8?B?VMOhdm9yYQ==?= on Sat, 04 Mar 2023 01:04:45 +0000) Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 61637 Cc: contovob@tcd.ie, 61637@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: -3.3 (---) > From: João Távora > Cc: "Basil L. Contovounesios" , 61637@debbugs.gnu.org > Date: Sat, 04 Mar 2023 01:04:45 +0000 > > I installed some language servers like clangd, rust-analyzer and pylsp, > and they need to a valid HOME to be able to function. Please tell more about this: what exactly do these servers need from the home directory? > diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eglot-tests.el > index 5d5de59a19a..ad994915c52 100644 > --- a/test/lisp/progmodes/eglot-tests.el > +++ b/test/lisp/progmodes/eglot-tests.el > @@ -116,9 +116,7 @@ eglot--call-with-fixture > ;; installations for LSP servers like pylsp, making > ;; these tests mostly useless, so we hack around it > ;; here with a great big hack. > - ,(format "HOME=%s" > - (if (file-exists-p home) home > - (format "/home/%s" (getenv "USER"))))) > + ,(format "HOME=%s" (or (getenv "EGLOT_REAL_HOME") (getenv "HOME")))) > process-environment)) > ;; Prevent "Can't guess python-indent-offset ..." messages. > (python-indent-guess-indent-offset-verbose . nil) > > This is acceptable for Eglot devs like me, but other devs that don't > know about this variable will still be confused. WDYT? As I said, I don't like the idea of using the user's real home directory for test purposes. We could end up clobbering precious files there. We could also have tests fail because some user setting in the home directory makes the test results unpredictable. > > Why not do this the other way around: trick Eglot to think the home > > directory doesn't exist (as I understand it already knows how to > > handle this)? > > I don't understand what you mean: this is entirely constrained to how > certain language servers work, so eglot.el itself can't handle it. In the original report, Basil sais: > The main problem is that: > 0. test/Makefile.in sets HOME=/nonexistent > 1. lisp/emacs-lisp/ert-x.el sets HOME=/tmp :( > 2. eglot--call-with-fixture tries to detect when HOME is nonexistent, > but /tmp exists, so that's left unchanged > 3. The Rust tools look under HOME=/tmp for which toolchain to use, but > the answer is under ~USER, so they give up I interpreted item 2 as meaning that eglot--call-with-fixture can cope with the situation where the user's home directory doesn't exist, and suggested to trick Eglot into thinking it doesn't exist in the cases in point, as the means of solving the problem. If my understanding is incorrect, or if what you describe here is a different problem (thus item 2 is no longer relevant), I'd like to better understand the details, so we could see if there are better alternatives than to use the real home directory of the user running the tests. From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 06:46:44 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 11:46:45 +0000 Received: from localhost ([127.0.0.1]:35334 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYQLc-0000t4-9f for submit@debbugs.gnu.org; Sat, 04 Mar 2023 06:46:44 -0500 Received: from mail-wm1-f50.google.com ([209.85.128.50]:51772) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYQLW-0000sm-Sf for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 06:46:42 -0500 Received: by mail-wm1-f50.google.com with SMTP id az36so3037557wmb.1 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 03:46:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1677930393; 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=bJAMnTtmdAbyZztuKYsoHq/GUUeFNOhqrKApvFthZvw=; b=d5mtRZnrM+6sldV0g1HcIU9H/tUHtdaNdyrMYescPpUSxyYPv2FXuOlm07TX8uDa/k 6W8rv7GtR/F7rv7zelN/5HFIfRRW5oB18T0cw11xy9ByCzbC62VeaoxBETCTwd+1XUm/ 4/d37y27RSJTLp54XtPRBAvZktnY1lMhtOvnn8ua5V87cIuWbi2gKebKSLcOsAWcv1dn iMF67UoT9LmGvJK4f4AMzxoxucMiKDCGuVvaFvfIc9q3tdfaVscIhaSxDn4+eyQtzyIk O7Qu+FDVziHzTPco3Vs1lgv2Eej8tEZopNVJsYbVjKfbCHoE1u0gozX140tO/mgLnBK2 wAmA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677930393; 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=bJAMnTtmdAbyZztuKYsoHq/GUUeFNOhqrKApvFthZvw=; b=OcJASVpU8Cpu/X75cwNjMiU6xGUcSsaiu3cOFc4Dbzdf046jC3XCEkTSlhrEUUNe1W OClrQq9kXhBOOV1RuTPajAuYLRbB/iAZ7+clIDeD4pzyjXrNX+bvNcyK97BMxdQxApZU JwtylnFlFXiIQOR2tYaI2kZQVWZvG6uYao7mmqJk65qqnEZ6qmbF7XJ2rCgRCM8bnLWo UxyyEQIhVm6wlaklnK8+I01G2xM4l5g4U8dWrmYwrku/F0hp5Pok/kcD2OLG9ccy3WIf dTYMJa7YjrDiQU72PR5curhsj774izdjlCsMFNgkx/iXjzt4550G2/ownGJdqVPwEnWH RF/w== X-Gm-Message-State: AO0yUKWw4JP2rf79/GH9DuSlF30Ike2DNb3Gq4S0BV/+Qsz6YjIV0H58 tkJvEfCbO2/ROp9SLluKCaklTXDhQX4= X-Google-Smtp-Source: AK7set+FDnLzyD4Y1MPjH1rbAcS4nakqITuN0upY0AouqLLIiCQ04Wf4wpmnVh5q3kD/30nqSI1L5g== X-Received: by 2002:a05:600c:1907:b0:3dd:af7a:53db with SMTP id j7-20020a05600c190700b003ddaf7a53dbmr4298152wmq.11.1677930392628; Sat, 04 Mar 2023 03:46:32 -0800 (PST) Received: from krug ([87.196.72.142]) by smtp.gmail.com with ESMTPSA id l8-20020a05600c4f0800b003b47b80cec3sm10064504wmq.42.2023.03.04.03.46.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 03:46:32 -0800 (PST) From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: Eli Zaretskii Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <83a60tarif.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 04 Mar 2023 09:46:00 +0200") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> Date: Sat, 04 Mar 2023 11:48:27 +0000 Message-ID: <87v8jg68l0.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: 61637 Cc: contovob@tcd.ie, 61637@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 (-) Eli Zaretskii writes: >> From: Jo=C3=A3o T=C3=A1vora >> Cc: "Basil L. Contovounesios" , 61637@debbugs.gnu.org >> Date: Sat, 04 Mar 2023 01:04:45 +0000 >>=20 >> I installed some language servers like clangd, rust-analyzer and pylsp, >> and they need to a valid HOME to be able to function. > > Please tell more about this: what exactly do these servers need from > the home directory? Every server is different. This is the complain for a pylsp installed with 'pip install pylsp' for the regular user, which you can find in the output of e.g. make -C test lisp/progmodes/eglot-tests SELECTOR=3D'"basic-completions"' This are the relevant parts of the output. Here, it looks like the pylsp trampoline in ~/.local/bin/pylsp can't find the main supporing library, which probably lives around the corner in ~/.local/lib/python3.10/site-packages. [stderr] PWD: /tmp/eglot--fixturelfcOUE/project [stderr] XDG_CONFIG_HOME: /dev/null [stderr] HOME: /tmp/ .... [stderr] EMACS_TEST_DIRECTORY: /home/capitaomorte/Source/Emacs/emacs/test [stderr] Traceback (most recent call last): [stderr] File "/home/capitaomorte/.local/bin/pylsp", line 14, in [stderr] from pylsp.__main__ import main [stderr] ModuleNotFoundError: No module named 'pylsp' [internal] Sat Mar 4 11:31:48 2023: (:message "Connection state changed" :change "exited abnormally with cod= e 1\n") =20=20=20=20 ----------b---y---e---b---y---e---------- [eglot] Killing (something.py), wiping /tmp/eglot--fixturelfcOUE, restor= ing nil Test eglot-test-basic-completions backtrace: signal(error ("[eglot] -1: Server died")) I suppose basil found something similar for rust-analyzer, though my installation of it is system-wide, so I don't get that particular problem. >> This is acceptable for Eglot devs like me, but other devs that don't >> know about this variable will still be confused. WDYT? > > As I said, I don't like the idea of using the user's real home > directory for test purposes. We could end up clobbering precious > files there. We could also have tests fail because some user setting > in the home directory makes the test results unpredictable. As I understand it, the concern of cloberring user customizations is mostly related to Emacs' own packages like ido or auto-save-mode, some of them do write files in ~/.emacs.d and similar. That is reasonable. But this is different IMO. We're talking about user-installed language servers, which presumably these users are already using (because they installed them). Only for the specific invocations of these servers is HOME spoofed. Overall I think the risk is low. Eglot has had these types of tests since practically the beginning and I've never had complains of clobbered files. >> > Why not do this the other way around: trick Eglot to think the home >> > directory doesn't exist (as I understand it already knows how to >> > handle this)? >>=20 >> I don't understand what you mean: this is entirely constrained to how >> certain language servers work, so eglot.el itself can't handle it. > > In the original report, Basil sais: > >> The main problem is that: >> 0. test/Makefile.in sets HOME=3D/nonexistent >> 1. lisp/emacs-lisp/ert-x.el sets HOME=3D/tmp :( >> 2. eglot--call-with-fixture tries to detect when HOME is nonexistent, >> but /tmp exists, so that's left unchanged >> 3. The Rust tools look under HOME=3D/tmp for which toolchain to use, but >> the answer is under ~USER, so they give up > > I interpreted item 2 as meaning that eglot--call-with-fixture can cope > with the situation where the user's home directory doesn't exist Ah, I understand. Indeed it could "cope", but only by doing exactly the same kind of spoof (or rather, unspoof) that Basil was proposing. But at a certain point in Emacs-29 that unspoof stopped working. In fact, I missed this in Basil's patch, but I think the correct fix is actually to fix eglot--call-with-fixture directly, with Basil's better technique of re-constructing $HOME. diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eglot= -tests.el index 5d5de59a19a..5f5adc8e5b3 100644 --- a/test/lisp/progmodes/eglot-tests.el +++ b/test/lisp/progmodes/eglot-tests.el @@ -103,22 +103,21 @@ eglot--call-with-fixture (set (car spec) (cadr spec))) ((stringp (car spec)) (push spec file-specs)))) (unwind-protect - (let* ((home (getenv "HOME")) - (process-environment + (let* ((process-environment (append `(;; Set XDF_CONFIG_HOME to /dev/null to prevent - ;; user-configuration to have an influence on + ;; user's configuration to have an influence on ;; language servers. (See github#441) "XDG_CONFIG_HOME=3D/dev/null" ;; ... on the flip-side, a similar technique by ;; Emacs's test makefiles means that HOME is set to - ;; /nonexistent. This breaks some common - ;; installations for LSP servers like pylsp, making - ;; these tests mostly useless, so we hack around it - ;; here with a great big hack. - ,(format "HOME=3D%s" - (if (file-exists-p home) home - (format "/home/%s" (getenv "USER"))))) + ;; /nonexistent or /tmp/. This breaks some common + ;; installations for LSP servers like pylsp, and + ;; rust-analyzer, making these tests mostly + ;; useless, so we hack around it here with a great + ;; big hack. + ,(format "HOME=3D%s" (expand-file-name (concat + "~" (user-login-n= ame))))) process-environment)) ;; Prevent "Can't guess python-indent-offset ..." messages. (python-indent-guess-indent-offset-verbose . nil) From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 07:47:02 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 12:47:02 +0000 Received: from localhost ([127.0.0.1]:35416 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYRHy-0004nk-BT for submit@debbugs.gnu.org; Sat, 04 Mar 2023 07:47:02 -0500 Received: from eggs.gnu.org ([209.51.188.92]:50248) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYRHv-0004nG-TB for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 07:47:01 -0500 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 1pYRHk-000449-OH; Sat, 04 Mar 2023 07:46:53 -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=aWfh4gJvspRCpbSAKoCSf6NUA95jS0HMX73aiqGk00o=; b=qZjPMR6H/XIpqw+xPEEQ wMsWAwRh09rIK052gfOvcGM92hAiSGjap/M2v0lRxd8TrehbRf+6kyG2O6g/V+ISBXDtQYjCxkMTa GwTBgdjdq52ZEbGa6nvvCN4eYXv3YA+sP9F9U49ix0FtzLhA3gkB5rx7UL0v6NrZZ9sXf3guCBQkc UgubP48SB88h1n5HYpvK6DSZ80WyRw7dQ530T+0RWFQk5dpMqkOU78Lwm6QCEHYLYzHMqpFE7IwlQ 3OzMpJiS17lv+AotNnCFiy1d1cc6hf1JTRU0ut0PpkpoiISX4LZhgfeaCeSv7lCeB5uS66feVFx2d /UTvZQvnRVthUA==; 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 1pYRHj-0006PK-Bc; Sat, 04 Mar 2023 07:46:48 -0500 Date: Sat, 04 Mar 2023 14:46:35 +0200 Message-Id: <83sfekadlg.fsf@gnu.org> From: Eli Zaretskii To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= In-Reply-To: <87v8jg68l0.fsf@gmail.com> (message from =?utf-8?B?Sm/Do28g?= =?utf-8?B?VMOhdm9yYQ==?= on Sat, 04 Mar 2023 11:48:27 +0000) Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> <87v8jg68l0.fsf@gmail.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 61637 Cc: contovob@tcd.ie, 61637@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: -3.3 (---) > From: João Távora > Cc: contovob@tcd.ie, 61637@debbugs.gnu.org > Date: Sat, 04 Mar 2023 11:48:27 +0000 > > Eli Zaretskii writes: > > >> From: João Távora > >> Cc: "Basil L. Contovounesios" , 61637@debbugs.gnu.org > >> Date: Sat, 04 Mar 2023 01:04:45 +0000 > >> > >> I installed some language servers like clangd, rust-analyzer and pylsp, > >> and they need to a valid HOME to be able to function. > > > > Please tell more about this: what exactly do these servers need from > > the home directory? > > Every server is different. This is the complain for a pylsp installed > with 'pip install pylsp' for the regular user, which you can find in the > output of e.g. > > make -C test lisp/progmodes/eglot-tests SELECTOR='"basic-completions"' > > This are the relevant parts of the output. Here, it looks like the > pylsp trampoline in ~/.local/bin/pylsp can't find the main supporing > library, which probably lives around the corner in > ~/.local/lib/python3.10/site-packages. Is it reasonable to have an LSP installed in the HOME directory when running the Emacs test suite, when we clearly document that HOME is ignored for these tests? How about if we ask users who install LSP servers under their home directory to somehow specify the exact location of that installation, so that the LSP will find its components, but Emacs won't access any files in the user's HOME via the "~" shortcut? > > As I said, I don't like the idea of using the user's real home > > directory for test purposes. We could end up clobbering precious > > files there. We could also have tests fail because some user setting > > in the home directory makes the test results unpredictable. > > As I understand it, the concern of cloberring user customizations is > mostly related to Emacs' own packages like ido or auto-save-mode, some > of them do write files in ~/.emacs.d and similar. That is reasonable. > > But this is different IMO. We're talking about user-installed language > servers, which presumably these users are already using (because they > installed them). Only for the specific invocations of these servers is > HOME spoofed. Overall I think the risk is low. Eglot has had these > types of tests since practically the beginning and I've never had > complains of clobbered files. You disregarded the second part of my reasoning, which has to do with the test results being non-deterministic once the user's real home directory is accessible to Emacs. How do we overcome that? From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 08:21:46 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 13:21:46 +0000 Received: from localhost ([127.0.0.1]:35480 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYRpZ-00087C-U0 for submit@debbugs.gnu.org; Sat, 04 Mar 2023 08:21:46 -0500 Received: from mail-wr1-f47.google.com ([209.85.221.47]:34395) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYRpX-00086w-Hu for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 08:21:45 -0500 Received: by mail-wr1-f47.google.com with SMTP id r18so4723709wrx.1 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 05:21:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1677936097; 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=7qhLmuhybv3BBoBOHCFMXUSMGbGImIdZh2+R3KazTpk=; b=qibF4lAj05HPBS/0XGh3b3o+lv/woxNqnDkqnSmUTa5PltI/rAd4sx+UVE8rAejsUr Gu/ngIvif7HwERUbwoRr8aqVbsJXQlzYth6u9Euz7EaB0kh68lQjeSOwcwADkBBNa6uP dhAZBuIodAd3thaUK/UADa6nIX6G/iNKq4DIJXZ8cZBEf+RS/ynOr+jeOW2+UK8SGGz+ dlTqaDh5e23W8+Z1E0tT/nUHTZKijcxALIIKi+G4awpw24XzuzTBzQCiHAO8J/RydQZU X+SSHHNKmAnqKotvcdOxYN4AfsukZFrcYTNmKsCvhfIZNbCrdpI2+6BV5aAHs9x3lgjZ hbkA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677936097; 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=7qhLmuhybv3BBoBOHCFMXUSMGbGImIdZh2+R3KazTpk=; b=S+5JBI2PiYBVWIQZV41RRiaNF0bScb7GzIJebjMF0aRGTsz/DW1X5udiQNdbOix6Mo UYA22+wWFL5OxyzblzkPk/dSK8MJw1WTSeK3P5Dfetjof58P7wmh6ppUo9h62T1Xn1wS T/sso+YqnuuXpOnhOTyJAuQD07mCopGgS7aC9zCCkyOBg0wBdelHaGTRa14JFFRtvMmJ Beujo1JWdyp4FyU3cGNUJ5u6vqBFeRYOkTzYqAzrQW9uvZReeYbnxLBNzK2VVSbSsqi9 0a04PHMgBcnrMQzjJkmdpig+LtvUa0W1gwb/Er23fK2Qq/u0HlvkG6gbm+pSsJedWboE baLQ== X-Gm-Message-State: AO0yUKUtuaiH2IqKifa/HWnWcXEhEav2nAovVwUmYZYJ7/CkNl1Uhxm6 8Ed+dQqBcXsa9+VDhZ4lkFL2g2vjhvk= X-Google-Smtp-Source: AK7set92EWw/AVAOZxeVIaBjNVenJt3VDaWGh/KE4u7e1Df3eac1dkOY3xKMoREcOQ7SxtgV+UeTUA== X-Received: by 2002:adf:e485:0:b0:2c9:57a8:eeac with SMTP id i5-20020adfe485000000b002c957a8eeacmr3834348wrm.25.1677936097166; Sat, 04 Mar 2023 05:21:37 -0800 (PST) Received: from krug (87-196-72-142.net.novis.pt. [87.196.72.142]) by smtp.gmail.com with ESMTPSA id q16-20020adfea10000000b002c559def236sm4955594wrm.57.2023.03.04.05.21.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 05:21:36 -0800 (PST) From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: Eli Zaretskii Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <83sfekadlg.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 04 Mar 2023 14:46:35 +0200") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> <87v8jg68l0.fsf@gmail.com> <83sfekadlg.fsf@gnu.org> Date: Sat, 04 Mar 2023 13:23:32 +0000 Message-ID: <87jzzw646j.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: 61637 Cc: contovob@tcd.ie, 61637@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 (-) Eli Zaretskii writes: >> From: Jo=C3=A3o T=C3=A1vora >> Cc: contovob@tcd.ie, 61637@debbugs.gnu.org >> Date: Sat, 04 Mar 2023 11:48:27 +0000 >>=20 >> Eli Zaretskii writes: >>=20 >> >> From: Jo=C3=A3o T=C3=A1vora >> >> Cc: "Basil L. Contovounesios" , 61637@debbugs.gnu.o= rg >> >> Date: Sat, 04 Mar 2023 01:04:45 +0000 >> >>=20 >> >> I installed some language servers like clangd, rust-analyzer and pyls= p, >> >> and they need to a valid HOME to be able to function. >> > >> > Please tell more about this: what exactly do these servers need from >> > the home directory? >>=20 >> Every server is different. This is the complain for a pylsp installed >> with 'pip install pylsp' for the regular user, which you can find in the >> output of e.g. >>=20 >> make -C test lisp/progmodes/eglot-tests SELECTOR=3D'"basic-completion= s"' >>=20 >> This are the relevant parts of the output. Here, it looks like the >> pylsp trampoline in ~/.local/bin/pylsp can't find the main supporing >> library, which probably lives around the corner in >> ~/.local/lib/python3.10/site-packages. > > Is it reasonable to have an LSP installed in the HOME directory when > running the Emacs test suite, when we clearly document that HOME is > ignored for these tests? It's rather two questions from my perspective: * Is there an easy way to install the pylsp server that _isn't_ this HOME directory installation so that Eglot devs can run the tests? There doesn't seem to be, at least not easy. Furthermore I (and I suppose many others) prefer installing toolchains in unpriviliged places rather than priviliged system ones. * If people do have this installed in HOME, it it reasonable to downright fail in their faces. I think that, to be consistent with this HOME spoofing (which I find a bit draconian in this case) then Emacs should also spoof PATH so that these HOME programs aren't found in the first place.=20=20 It comes down to what are the intended semantics of finding external executable during Emacs 'make check'. Only system-wide executables? Should 'make check' chroot itself or something? Should we be trying to solve the very hard problems of determinism at all? Shouldn't that be left to a broader sandboxing solution, or a chrooting solution like docker? > How about if we ask users who install LSP servers under their home > directory to somehow specify the exact location of that installation, > so that the LSP will find its components, but Emacs won't access any > files in the user's HOME via the "~" shortcut? How do you propose we do that? What users exactly? Eglot-interested devs? What about the others working on libraries and trying not to break things? When should users do that specifying? Isn't it different for each server and each installation method? >> > As I said, I don't like the idea of using the user's real home >> > directory for test purposes. We could end up clobbering precious >> > files there. We could also have tests fail because some user setting >> > in the home directory makes the test results unpredictable. >>=20 >> As I understand it, the concern of cloberring user customizations is >> mostly related to Emacs' own packages like ido or auto-save-mode, some >> of them do write files in ~/.emacs.d and similar. That is reasonable. >>=20 >> But this is different IMO. We're talking about user-installed language >> servers, which presumably these users are already using (because they >> installed them). Only for the specific invocations of these servers is >> HOME spoofed. Overall I think the risk is low. Eglot has had these >> types of tests since practically the beginning and I've never had >> complains of clobbered files. > > You disregarded the second part of my reasoning, which has to do with > the test results being non-deterministic once the user's real home > directory is accessible to Emacs. How do we overcome that? Sorry I didn't mean to disregard, I just missed it. Well, it's not accessible to Emacs, only to LSP servers. Eglot's tests are fairly are deterministic, all other things like LSP server versions being equal. I'd say Eglot's tests are even robust to any changes in LSP server's user init files. See how XDG_CONFIG_HOME is spooffed in eglot-tests.el to this effect. It has been effective AFAICT for some time. And that's only for those few servers that do offer these mechanisms: most of them rely on project-local configurations which is fine because Eglot creates a temporary project for each test. All in all, I think the problem of user file clobbering and determinism are exaggerated -- in this specific case of course. They are secondary to the fact that it's tricky, noisy, or even impossible to run Eglot tests ever since Eglot moved to Emacs core.=20=20 I propose we install my patch and then perfect the solution. Again, we're only affecting those devs who _do_ have these local installations, and that affection is much, much more likely to be beneficial than harmful. Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 10:04:45 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 15:04:45 +0000 Received: from localhost ([127.0.0.1]:37431 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYTRF-00036b-8R for submit@debbugs.gnu.org; Sat, 04 Mar 2023 10:04:45 -0500 Received: from eggs.gnu.org ([209.51.188.92]:47676) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYTRC-00036N-Ty for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 10:04:44 -0500 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 1pYTR7-0004xU-57; Sat, 04 Mar 2023 10:04:37 -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=rJ1p67b7s1FN1no6js9ZfK9KMMV6A6oXRfD3h2nqRnA=; b=LUtRbRvcZK2Q/gAZ9H/v 21dqKyofELVCyQMgpSIZpUI3zi2nLlbad4sqUTXmqiY1C2lNcJQSvHiOb9zgiTLvWDPN31yht78D2 FskljUzWdVOItZQwF3pbTq90mRzPVU/GWvzQBlhPn5JbHbmvg4cLNEe9NjeR95YA6fWJKaaJBYr/C nrVcbwMKnuLfxs+BCrlVzA9VHQ133siOc81HN8f/PiMb27eMKtezrpnOpwJSnHhMw483zoIQLzUln NSqqd7lXRyUm8gtqhYDLQhfoA/TC/WfwJAz7A1Q3qAHdJzyj9YmHjIvaJQwP46kGB7o0qDqUP0LRL yFLH8pOlQjbzpQ==; 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 1pYTR6-00067K-Ce; Sat, 04 Mar 2023 10:04:36 -0500 Date: Sat, 04 Mar 2023 17:04:25 +0200 Message-Id: <83mt4sa77q.fsf@gnu.org> From: Eli Zaretskii To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= In-Reply-To: <87jzzw646j.fsf@gmail.com> (message from =?utf-8?B?Sm/Do28g?= =?utf-8?B?VMOhdm9yYQ==?= on Sat, 04 Mar 2023 13:23:32 +0000) Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> <87v8jg68l0.fsf@gmail.com> <83sfekadlg.fsf@gnu.org> <87jzzw646j.fsf@gmail.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 61637 Cc: contovob@tcd.ie, 61637@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: -3.3 (---) > From: João Távora > Cc: contovob@tcd.ie, 61637@debbugs.gnu.org > Date: Sat, 04 Mar 2023 13:23:32 +0000 > > > You disregarded the second part of my reasoning, which has to do with > > the test results being non-deterministic once the user's real home > > directory is accessible to Emacs. How do we overcome that? > > Sorry I didn't mean to disregard, I just missed it. Well, it's not > accessible to Emacs, only to LSP servers. Eglot's tests are fairly are > deterministic, all other things like LSP server versions being equal. > > I'd say Eglot's tests are even robust to any changes in LSP server's > user init files. See how XDG_CONFIG_HOME is spooffed in eglot-tests.el > to this effect. It has been effective AFAICT for some time. And that's > only for those few servers that do offer these mechanisms: most of them > rely on project-local configurations which is fine because Eglot creates > a temporary project for each test. > > All in all, I think the problem of user file clobbering and determinism > are exaggerated -- in this specific case of course. They are secondary > to the fact that it's tricky, noisy, or even impossible to run Eglot > tests ever since Eglot moved to Emacs core. > > I propose we install my patch and then perfect the solution. Again, > we're only affecting those devs who _do_ have these local installations, > and that affection is much, much more likely to be beneficial than > harmful. OK, please go ahead, and thanks. From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 12:19:36 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 17:19:36 +0000 Received: from localhost ([127.0.0.1]:37628 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYVXk-0006ey-EM for submit@debbugs.gnu.org; Sat, 04 Mar 2023 12:19:36 -0500 Received: from mail-wm1-f50.google.com ([209.85.128.50]:54084) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYVXi-0006ek-P1 for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 12:19:35 -0500 Received: by mail-wm1-f50.google.com with SMTP id c18so3325749wmr.3 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 09:19:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd.ie; s=google21; t=1677950369; 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=q777yJoR2v+GoSNb77TUXJ6lU59JD+vn1oRGLclj+g8=; b=C0eLybKVqmtAaUn5z4gx2pyhnhZnGwTC+beVsEZ7h5wUY1DmVLxJKKb3Y4MRcsySMa MMlO0Zm3SAfQfCKLWBaJfBdPgjzpQwITJHCqO0xfw3vVxm3rvmjvaOUCifQDlcWkHONj 8NfFufsDWfsV9hTBxx/+RKapOohuH6QLsYdJK3Gs63e8LWVSEgjDgOM40fyup79vtJ4d 3/u0U4KXRFyHkiT6xzpGXVLdKE5kmfjeSNVFXLM61/Lq2yw67htzp0FbGwPvaiX+R/gs XJRcmrSGTS9fNKOZIwonHQEEvYve4jE2IiBL+2ieVjdkksc4fefu1Cg0ZgHUyAGrGebt MmXA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677950369; 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=q777yJoR2v+GoSNb77TUXJ6lU59JD+vn1oRGLclj+g8=; b=6bJzOMZzdIzboEwWWOyI+W42rzBXgZgohI9/UMItmkbm6jV/788rCr2ZGbJNi9uzfN ZPl/TN7tei466ZdPHhzmuqAof8KO4CIGSV6y0mGI4CI/Aix4JXVYiD6KszICFZM0mKwT O8hMeqyddSVfc269n7aHPVuHlR0EXIq29UYb7SVf6b2XNQcmLeg87CZctpiRaretoWsa dCXDwnP8lLNN1IrmIbqTMSwMLJZbPSC0pIdLGxYj13msu4unO4s464y10egHFReUNAEM 4tUS0TkvPnXU5NzeLm8NtNke441NfwJ8qlg9spyOTT94iNwtqITv902ZUHbei+BlgB3N 5vAg== X-Gm-Message-State: AO0yUKWETWmuClQsYQS6NQRBZU0dtYoCK3dUBoSKYcsyPcFhQkyA6gTw GwicQtWNun4vdvVICiW+8Ni3QA== X-Google-Smtp-Source: AK7set9xZyjwSIll8SkkeOoSJZRp0EP7PjKujU6Gldrw0e4YUBYYpw8HaRL7b1q0hEY985eVAXg1+w== X-Received: by 2002:a05:600c:474b:b0:3dd:1c46:b92 with SMTP id w11-20020a05600c474b00b003dd1c460b92mr5587410wmo.16.1677950368755; Sat, 04 Mar 2023 09:19:28 -0800 (PST) Received: from localhost ([89.19.67.225]) by smtp.gmail.com with ESMTPSA id u32-20020a05600c4d2000b003dc522dd25esm5591068wmp.30.2023.03.04.09.19.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 09:19:28 -0800 (PST) From: Basil Contovounesios To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <87bkl972du.fsf@gmail.com> (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vor?= =?utf-8?Q?a=22's?= message of "Sat, 04 Mar 2023 01:04:45 +0000") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> Date: Sat, 04 Mar 2023 17:19:26 +0000 Message-ID: <87pm9oqvs1.fsf@tcd.ie> 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: 61637 Cc: Eli Zaretskii , 61637@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 (-) Jo=C3=A3o T=C3=A1vora [2023-03-04 01:04 +0000] wrote: > Another option is to have eglot-tests.el read a new environment var: > > diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/egl= ot-tests.el > index 5d5de59a19a..ad994915c52 100644 > --- a/test/lisp/progmodes/eglot-tests.el > +++ b/test/lisp/progmodes/eglot-tests.el > @@ -116,9 +116,7 @@ eglot--call-with-fixture > ;; installations for LSP servers like pylsp, making > ;; these tests mostly useless, so we hack around it > ;; here with a great big hack. > - ,(format "HOME=3D%s" > - (if (file-exists-p home) home > - (format "/home/%s" (getenv "USER"))))) > + ,(format "HOME=3D%s" (or (getenv "EGLOT_REAL_HOME") (= getenv "HOME")))) > process-environment)) > ;; Prevent "Can't guess python-indent-offset ..." message= s. > (python-indent-guess-indent-offset-verbose . nil) > > This is acceptable for Eglot devs like me, but other devs that don't > know about this variable will still be confused. WDYT? So the suggestion is for parties interested in running the full unadulterated Eglot suite to set this environment variable, thus opting into using their HOME or any other HOME-like environment they may have set up? If so, sounds fine to me, thanks, --=20 Basil From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 12:20:18 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 17:20:18 +0000 Received: from localhost ([127.0.0.1]:37633 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYVYP-0006gN-Rc for submit@debbugs.gnu.org; Sat, 04 Mar 2023 12:20:18 -0500 Received: from mail-wr1-f54.google.com ([209.85.221.54]:35366) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYVYO-0006gB-Mq for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 12:20:17 -0500 Received: by mail-wr1-f54.google.com with SMTP id q16so5061508wrw.2 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 09:20:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd.ie; s=google21; t=1677950411; 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=uDe37jpJcWGIaNziVRYnrSrqVG3vWwS6KY0CbTkWy3Q=; b=PcWPfx/uxKs9NXY0RSobR3ISbhkV7ak9CSLjFO12wzhW9HN+/wOnO8rayGDa1y3tUK zbul2TM5EceABGhPETmgxn4OyEFVq3310EJOkHqHw4Pan8Z/rK4mmYXhQ7tYuQ6fmlvl N83B6cSsqd0G7yo5cXI9OWr7NKmGN6SwPv4FIyZ1rRmCq9IHzS5kR8TFYMW67ytX7pYN f1wjHV0nHAEkh8LQEUEDDjVuJt3Lfv0AnHOzGfOcgr/y0GaJ2cycxG7CX0lJiHi8yK4+ Pi+blyZB7TdRf6wJj9wHS+NYX3QU14EgIvdXNlaIYHqwWij9MU3jc77GSiJWAuNTW0hU 4VzA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677950411; 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=uDe37jpJcWGIaNziVRYnrSrqVG3vWwS6KY0CbTkWy3Q=; b=eFgwsAQ2OjxdjCyPhWA/pbtHzH5TxAYRDAa+YHf1GxyDG2TNUnZVzJPmgOJ8z3OcV8 bxDS+uaRgO4M64NTQGliFMgFtelPuxug6ujO44XPQsmr/niC4mD8Ly1sYEFBn14wMBoW Dvo/cN74FeTDEvciRWo08fJiSUfrYW8zuZdUlHB1yvQsqmu2JbcKkhftheZQj/cYSbD+ LuaoADTVD6KdVRoznRc2wW2SkPgaU1tpy6ytpUiHdCdt9D+j+AE6/cpcvRucUrggW43I GIvTe9wpm4aS7dnBID+GDdfwpdf6bCEs47PEkH0L7r2FFKCbBDevcqPsWB0OfmLpYuV7 mRvw== X-Gm-Message-State: AO0yUKVVOM4K0lpRKh2Lfp06R+RhuGCDFzMBXB3NznPThqtFueDyW2dt ZCwXjXvTFT5LvMdIwnoEXPJi7A== X-Google-Smtp-Source: AK7set/AIgsAHsQ+3M3rDAGaOkXq5MXUqP+wf8aeg1+hgymxOUWsw2T2vnUHnznOjCq4dH1lul/pMA== X-Received: by 2002:adf:f20d:0:b0:2c7:53d:721b with SMTP id p13-20020adff20d000000b002c7053d721bmr4140414wro.44.1677950410657; Sat, 04 Mar 2023 09:20:10 -0800 (PST) Received: from localhost ([89.19.67.225]) by smtp.gmail.com with ESMTPSA id o16-20020a056000011000b002c703d59fa7sm5457625wrx.12.2023.03.04.09.20.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 09:20:10 -0800 (PST) From: Basil Contovounesios To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <87v8jg68l0.fsf@gmail.com> (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vor?= =?utf-8?Q?a=22's?= message of "Sat, 04 Mar 2023 11:48:27 +0000") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> <87v8jg68l0.fsf@gmail.com> Date: Sat, 04 Mar 2023 17:20:08 +0000 Message-ID: <87mt4sqvqv.fsf@tcd.ie> 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: 61637 Cc: Eli Zaretskii , 61637@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 (-) Jo=C3=A3o T=C3=A1vora [2023-03-04 11:48 +0000] wrote: > In fact, I missed this in Basil's patch, but I think the correct fix is > actually to fix eglot--call-with-fixture directly I'm not sure what you mean by 'directly': the patch below unconditionally sets HOME=3D~USER for all eglot-tests.el, whereas the patch in the OP was more conservative in doing this for only those tests which are found to need it, thus mitigating to an extent the risk that Eli is (understandably) concerned about. > diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/egl= ot-tests.el > index 5d5de59a19a..5f5adc8e5b3 100644 > --- a/test/lisp/progmodes/eglot-tests.el > +++ b/test/lisp/progmodes/eglot-tests.el > @@ -103,22 +103,21 @@ eglot--call-with-fixture > (set (car spec) (cadr spec))) > ((stringp (car spec)) (push spec file-specs)))) > (unwind-protect > - (let* ((home (getenv "HOME")) > - (process-environment > + (let* ((process-environment > (append > `(;; Set XDF_CONFIG_HOME to /dev/null to prevent > - ;; user-configuration to have an influence on > + ;; user's configuration to have an influence on > ;; language servers. (See github#441) > "XDG_CONFIG_HOME=3D/dev/null" Note that test/Makefile.in already unexports XDG_CONFIG_HOME, so eglot-tests.el needs not concern itself with it. > ;; ... on the flip-side, a similar technique by > ;; Emacs's test makefiles means that HOME is set to > - ;; /nonexistent. This breaks some common > - ;; installations for LSP servers like pylsp, making > - ;; these tests mostly useless, so we hack around it > - ;; here with a great big hack. > - ,(format "HOME=3D%s" > - (if (file-exists-p home) home > - (format "/home/%s" (getenv "USER"))))) > + ;; /nonexistent or /tmp/. This breaks some common > + ;; installations for LSP servers like pylsp, and > + ;; rust-analyzer, making these tests mostly > + ;; useless, so we hack around it here with a great > + ;; big hack. > + ,(format "HOME=3D%s" (expand-file-name (concat > + "~" (user-login= -name))))) > process-environment)) > ;; Prevent "Can't guess python-indent-offset ..." message= s. > (python-indent-guess-indent-offset-verbose . nil) --=20 Basil From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 12:21:18 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 17:21:18 +0000 Received: from localhost ([127.0.0.1]:37638 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYVZO-0006iQ-Ca for submit@debbugs.gnu.org; Sat, 04 Mar 2023 12:21:18 -0500 Received: from mail-wm1-f45.google.com ([209.85.128.45]:50767) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYVZM-0006iD-Rp for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 12:21:17 -0500 Received: by mail-wm1-f45.google.com with SMTP id k37so3362938wms.0 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 09:21:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd.ie; s=google21; t=1677950471; 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=fMMMoHW2w7T3PfvEvI3DLBPPUBLj9tpmIdMkDMsOyQQ=; b=eXrWlh8L0FrpKa8nFEvzOlE/39LOE89OvSCNfa9J9K+0/xXEjpDDFfdMgs6yXsbJtM zep5r2+mSk6cfF7LeGHmTOHPzWSH42JxToVF8T0MSSB2SjlGdFwDNofwQiEvs5E0VDuZ sH5jeiOHX6nnYbAEF6cRctGjvQo+IfG7NA3XljKy25SKYTLzZRGubVjOI5ecc7x0UlNW 8xQ9il5PVY6LMbl5Ri6O9El+Fe7gV+a/NCLAx6v33ssO/vCvqVY+eUtZky9KBiYQFLNz Pw0P7w0tPXpSNH3iXDhfWWL5IRgCZ3/gCf5nGQjfJxKykA3Nw2GkF9F5MMKB+SCudqkx Lvbg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677950471; 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=fMMMoHW2w7T3PfvEvI3DLBPPUBLj9tpmIdMkDMsOyQQ=; b=M/9Y2w6SwMBox0ABNTerb3lVmgYuFFUWa7wNAbJLttigeU9XkEPRBy1lbSPhDOjYVA hi3Gv0j4cFgJeKMEIzToGkGoQ4jeNopjOmAL4e2hfbwHKA3pwsGkrmg6eBrRvawFbRgh 2iT4fGlqiW7qMzEpjofUzuwjXriJS17pNLS3G9AF+NYhowMCc8voYot0h1XM3ptISsG4 jQRdYw5QugP4v7H3jPk1YRH9xTZ5lICXG4A+52bH9QBXwzljNgUsXEsueHuBSjQvLhcN HdlFR729E6Z69dVNql0OyIyJnuiVMFuM2JZQLkBRXBxFwN3+8hXkN4dFJhVXc43dYSSb PaSQ== X-Gm-Message-State: AO0yUKV1jZOyANZ9AigdE1+W4kFSZuZjRmxS5n2B/0kCvkHoYNPOGjJ3 XRqWsWNUvY18IFif98LTQBPJ9LT3QFH6Veib/uA= X-Google-Smtp-Source: AK7set+HpThQPsUQJ1eR8nWDXs3CMqHfjxHfFTj2hkOf02HauON83qJgRDaVymF24Xt9MFb1RYf9DA== X-Received: by 2002:a05:600c:4f0c:b0:3ea:c100:f18d with SMTP id l12-20020a05600c4f0c00b003eac100f18dmr5049234wmq.9.1677950471225; Sat, 04 Mar 2023 09:21:11 -0800 (PST) Received: from localhost ([89.19.67.225]) by smtp.gmail.com with ESMTPSA id h22-20020a05600c351600b003daf6e3bc2fsm14937882wmq.1.2023.03.04.09.21.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 09:21:10 -0800 (PST) From: Basil Contovounesios To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <87jzzw646j.fsf@gmail.com> (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vor?= =?utf-8?Q?a=22's?= message of "Sat, 04 Mar 2023 13:23:32 +0000") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> <87v8jg68l0.fsf@gmail.com> <83sfekadlg.fsf@gnu.org> <87jzzw646j.fsf@gmail.com> Date: Sat, 04 Mar 2023 17:21:09 +0000 Message-ID: <87ilfgqvp6.fsf@tcd.ie> 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: 61637 Cc: Eli Zaretskii , 61637@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 (-) Jo=C3=A3o T=C3=A1vora [2023-03-04 13:23 +0000] wrote: > I'd say Eglot's tests are even robust to any changes in LSP server's > user init files. See how XDG_CONFIG_HOME is spooffed in eglot-tests.el > to this effect. Based on the test failures I've been seeing for months and tried to address in the original patches (not all of which are due to an unexpected HOME setting), it feels like that's probably too optimistic a conclusion in the general case. A lot of the relevant tooling places its configuration directly under HOME for example, not under XDG_CONFIG_HOME. I can also imagine user-specific settings affecting some of the auto-formatting functionality tested in eglot-tests.el. --=20 Basil From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 12:26:57 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 17:26:57 +0000 Received: from localhost ([127.0.0.1]:37643 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYVer-0006q5-2p for submit@debbugs.gnu.org; Sat, 04 Mar 2023 12:26:57 -0500 Received: from mail-wm1-f50.google.com ([209.85.128.50]:55960) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYVep-0006pt-8m for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 12:26:55 -0500 Received: by mail-wm1-f50.google.com with SMTP id p16so3315073wmq.5 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 09:26:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd.ie; s=google21; t=1677950809; 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=JaXdDJzDJ90mmqZaOe6DFXkLKU0Njif0vwMrKl1Pw0g=; b=SEsb9Jt/rZqsdeci/4V5OYpAOCv3CUojPLT+juM2BUrUAhftfVyreueI9KhqLIqaff k0CMVgxZtd2Pn6eN0+NjU9fe5qBSLVc2El98EAIYOUZ5atL0mDCJnJSYHZJVTAOO3bQS +oD9hVSimzjSw61I+AVYobpdMBIIdR0zz927DHQAvMN5+qxCp9ILi6TXF7lKxTOs42y6 c6h11+P64D1HXUAiKw7ab78R8bkusxsPsFG29BhpE8i4iwjnzpzJAtiqfYZDCNTSK8Wc fpGirnzXHaV9A1aUjQ8FlGSI3tZYNFMJaHbNmLEAsUa9EzbRgltEGY1uAetBukgSeXzn Oytw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677950809; 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=JaXdDJzDJ90mmqZaOe6DFXkLKU0Njif0vwMrKl1Pw0g=; b=XFsIkBiae7lQhremVHTT8CbnfWzGeD+fkieCK6Sg3btT8RA7Yjd5ajjKOCHqweIPNE SwxqWskzlzQDzir7ov5gzqIKjy3XeJ+Rq0GSewC5bzSZkbRYqmBLWZAXTg6EihQCuEFL 1XX9sE/caX6u7vM+gXHc/ubEWc+09WoQvsuCEozqGMTyoqcf/Sn3UgtU6CV0DQM8qB4P MNfBUOKjsDQPBMeAHK53TdFS6pZSEq/j1RRsKfkboNsnDtbSZK8i6XHgR87aOdvT65ug R0kRmk7hyxD9tJVPFvPLq262gMOTgu2QcvxM/YnkkYjG8Br+bcfwkL7990276AjEUaEX hPEw== X-Gm-Message-State: AO0yUKXWsXLvwUI48u0AmrZp80pFZXvR/G+1mzCzDi6WmfFpht+NMHKc wJ6pJjR++t/AEl8OJlWNFZuUxA== X-Google-Smtp-Source: AK7set8Lj5uKziOH/bib4oefAsFla3RqhVREmkrOQohjDdwaBZ7RuSXY6KRTfgQlVz2GUpzymWGDNQ== X-Received: by 2002:a05:600c:3108:b0:3ea:ea6b:f9ad with SMTP id g8-20020a05600c310800b003eaea6bf9admr4828823wmo.31.1677950809447; Sat, 04 Mar 2023 09:26:49 -0800 (PST) Received: from localhost ([89.19.67.225]) by smtp.gmail.com with ESMTPSA id f13-20020a7bcd0d000000b003db01178b62sm9210873wmj.40.2023.03.04.09.26.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 09:26:48 -0800 (PST) From: Basil Contovounesios To: Eli Zaretskii Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <83a60tarif.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 04 Mar 2023 09:46:00 +0200") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> Date: Sat, 04 Mar 2023 17:26:47 +0000 Message-ID: <87cz5oqvfs.fsf@tcd.ie> 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: 61637 Cc: 61637@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 (-) Eli Zaretskii [2023-03-04 09:46 +0200] wrote: >> From: Jo=C3=A3o T=C3=A1vora >> Cc: "Basil L. Contovounesios" , 61637@debbugs.gnu.org >> Date: Sat, 04 Mar 2023 01:04:45 +0000 >>=20 >> I installed some language servers like clangd, rust-analyzer and pylsp, >> and they need to a valid HOME to be able to function. > > Please tell more about this: what exactly do these servers need from > the home directory? Binaries, configuration files, virtual environments, the whole shebang. It seems increasingly common to install such fast-moving tooling under the user's home/local directory without root privileges using language-specific package managers. >> diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eg= lot-tests.el >> index 5d5de59a19a..ad994915c52 100644 >> --- a/test/lisp/progmodes/eglot-tests.el >> +++ b/test/lisp/progmodes/eglot-tests.el >> @@ -116,9 +116,7 @@ eglot--call-with-fixture >> ;; installations for LSP servers like pylsp, making >> ;; these tests mostly useless, so we hack around it >> ;; here with a great big hack. >> - ,(format "HOME=3D%s" >> - (if (file-exists-p home) home >> - (format "/home/%s" (getenv "USER"))))) >> + ,(format "HOME=3D%s" (or (getenv "EGLOT_REAL_HOME") = (getenv "HOME")))) >> process-environment)) >> ;; Prevent "Can't guess python-indent-offset ..." messag= es. >> (python-indent-guess-indent-offset-verbose . nil) >>=20 >> This is acceptable for Eglot devs like me, but other devs that don't >> know about this variable will still be confused. WDYT? > > As I said, I don't like the idea of using the user's real home > directory for test purposes. We could end up clobbering precious > files there. We could also have tests fail because some user setting > in the home directory makes the test results unpredictable. Then I see three options in this discussion so far: 0. Whenever the tooling in question is detected to fail because it is being run under /nonexistent or /tmp, the test should be skipped rather than considered a failure. 1. Allow adventurous devs to opt into having their real HOME (or any provided substitute thereof) used, presumably using either ERT :tags, an environment variable like that which Jo=C3=A3o suggested above, or something similar. 2. Filter exec-path to exclude user-specific directories. None of which sound mutually exclusive to me. Item 2 is the most drastic/limiting one, but it complements the existing policy of the Emacs test suite to modify HOME and unexport XDG_CONFIG_HOME. I am personally not considering the other mentioned possibilities like sandboxing, chrooting, containerising, etc. because I am not familiar with them and have neither the time nor motivation to pursue such changes to the Eglot test suite. >> > Why not do this the other way around: trick Eglot to think the home >> > directory doesn't exist (as I understand it already knows how to >> > handle this)? >>=20 >> I don't understand what you mean: this is entirely constrained to how >> certain language servers work, so eglot.el itself can't handle it. > > In the original report, Basil sais: > >> The main problem is that: >> 0. test/Makefile.in sets HOME=3D/nonexistent >> 1. lisp/emacs-lisp/ert-x.el sets HOME=3D/tmp :( >> 2. eglot--call-with-fixture tries to detect when HOME is nonexistent, >> but /tmp exists, so that's left unchanged >> 3. The Rust tools look under HOME=3D/tmp for which toolchain to use, but >> the answer is under ~USER, so they give up > > I interpreted item 2 as meaning that eglot--call-with-fixture can cope > with the situation where the user's home directory doesn't exist, and > suggested to trick Eglot into thinking it doesn't exist in the cases > in point, as the means of solving the problem. That's too optimistic an interpretation of what I said, I'm afraid: it is precisely when HOME does not exist that eglot--call-with-fixture currently decides to use the user's real home directory. Normally HOME would not exist during our test suite, except eglot-tests.el loads ert-x.el, which conditionally sets HOME=3D/tmp at top-level (see the definition of ert-remote-temporary-file-directory). So on my system eglot-tests.el are currently run under /tmp, but on systems where ert-remote-temporary-file-directory has not messed with the definition of HOME, they could be running under /nonexistent or the user's real HOME. AFAICT Jo=C3=A3o's latest suggestion is to unconditionally use the real HOME for all eglot-tests.el. > If my understanding is incorrect, or if what you describe here is a > different problem (thus item 2 is no longer relevant), I'd like to > better understand the details, so we could see if there are better > alternatives than to use the real home directory of the user running > the tests. See my comments above. Thanks, --=20 Basil From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 12:28:59 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 17:28:59 +0000 Received: from localhost ([127.0.0.1]:37648 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYVgo-0006su-SF for submit@debbugs.gnu.org; Sat, 04 Mar 2023 12:28:59 -0500 Received: from mail-wm1-f53.google.com ([209.85.128.53]:35674) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYVgn-0006si-7p for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 12:28:57 -0500 Received: by mail-wm1-f53.google.com with SMTP id bg16-20020a05600c3c9000b003eb34e21bdfso5777906wmb.0 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 09:28:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd.ie; s=google21; t=1677950931; 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=DlM3n/R+MAveBZZuDyswyqMgqHXm/ODPN1dMH6RBgGg=; b=XlFA3dM6IrlT74fH3/x0u7ujrPNEaFkNuxIfiby4MLRXee7Ads7YBUbYGwZWnHH8BB nQ23MUlI3kcOyris6bohrSsvH3eab7ogpW69TyGCH3Gj08x72YlzM3z8jAHJ0EA+1jxr D8yHUtybGg4mrHheumDNHBphyq29E9Usg3QbIJPVpW5caoMzNFAColk23jtNwC9wlLZu 9BjTrSSb3Qq6VWrWEtugqErwU2GC4MlERv2MILIU3zFLPi7q49qK3IGfZEOuTw0L33yj vQqTEITH3J/QcwJm3ZsBAksZLqMKBmYW44g7tITnYLYLndAT2y/cLMKF7xb3/tQBH8U6 F9zg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677950931; 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=DlM3n/R+MAveBZZuDyswyqMgqHXm/ODPN1dMH6RBgGg=; b=RsLBxWJzF/8zHW/xdZ6l0RUUf+Nik7TGVAFrkW29dWkp7RUliakYynoj6YdIIgZxPB 9K95asjAlMP10HIrd2oxjjeSUD/2Eg3EjnCiitA/TV0yOvYZlJGQnmEhnroUBUv/3JSJ +fAVnrz889P8qErxlBpNIlXFT98yL1FF/XZcVTjkE9Pt7CWo/gtC1zUYzSImWOs4FAtz Mj8E6u34f+WC8lb8r5cSkAlb3iBZRmuucw3flRaTv6IpOaeNXPDQfkvwA1dNz7o+hr11 3VWECbh7muFNAHf+LNTB1q6uGudkwuk1AZlKAcw+ARcvyIzaxfaS4Aas3WG/Ot2dZq48 +AXg== X-Gm-Message-State: AO0yUKWxLM+VjY8YR9KaKHQ6rH0tBqLOpv/a88sBtG+EISqne2DoPzxL hS1wqDTxEr6ncDnaUi1twfvGTQ== X-Google-Smtp-Source: AK7set+VllcylrtGJH4+Mpqvq07i3/lHNAN8WVPc4nX1sNY9IjXAvIVTzzF+5cRuBT+jndW0uZYMOw== X-Received: by 2002:a7b:c5c2:0:b0:3e1:df8d:e022 with SMTP id n2-20020a7bc5c2000000b003e1df8de022mr7096398wmk.9.1677950931560; Sat, 04 Mar 2023 09:28:51 -0800 (PST) Received: from localhost ([89.19.67.225]) by smtp.gmail.com with ESMTPSA id h8-20020a5d5048000000b002c592535839sm5470514wrt.17.2023.03.04.09.28.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 09:28:51 -0800 (PST) From: Basil Contovounesios To: Eli Zaretskii Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <83sfekadlg.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 04 Mar 2023 14:46:35 +0200") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> <87v8jg68l0.fsf@gmail.com> <83sfekadlg.fsf@gnu.org> Date: Sat, 04 Mar 2023 17:28:49 +0000 Message-ID: <874jr0qvce.fsf@tcd.ie> 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: 61637 Cc: 61637@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 (-) Eli Zaretskii [2023-03-04 14:46 +0200] wrote: > Is it reasonable to have an LSP installed in the HOME directory when > running the Emacs test suite, when we clearly document that HOME is > ignored for these tests? The fact that I have LSP servers installed under HOME is orthogonal to the fact that I also happen to frequently run the Emacs test suite, regardless of what the Emacs test suite chooses to do with the HOME environment variable. The purpose of this bug report is to teach eglot-tests.el to gracefully handle such installations, which IME are increasingly common. I'm not particularly bothered whether that's achieved by filtering exec-path, skipping problematic tests, or... > How about if we ask users who install LSP servers under their home > directory to somehow specify the exact location of that installation, > so that the LSP will find its components, but Emacs won't access any > files in the user's HOME via the "~" shortcut? ...some such mechanism of specifying a HOME-like substitute, like Jo=C3=A3o= 's earlier EGLOT_REAL_HOME suggestion. >> > As I said, I don't like the idea of using the user's real home >> > directory for test purposes. We could end up clobbering precious >> > files there. We could also have tests fail because some user setting >> > in the home directory makes the test results unpredictable. >>=20 >> As I understand it, the concern of cloberring user customizations is >> mostly related to Emacs' own packages like ido or auto-save-mode, some >> of them do write files in ~/.emacs.d and similar. That is reasonable. >>=20 >> But this is different IMO. We're talking about user-installed language >> servers, which presumably these users are already using (because they >> installed them). Only for the specific invocations of these servers is >> HOME spoofed. Overall I think the risk is low. Eglot has had these >> types of tests since practically the beginning and I've never had >> complains of clobbered files. > > You disregarded the second part of my reasoning, which has to do with > the test results being non-deterministic once the user's real home > directory is accessible to Emacs. How do we overcome that? Any of the suggestions I've enumerated so far sounds plausible to me. But I'd appreciate some feedback on which combination if any is preferred before proceeding to suggest a new patchset (unless Jo=C3=A3o bea= ts me to it). Thanks, --=20 Basil From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 13:09:44 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 18:09:44 +0000 Received: from localhost ([127.0.0.1]:37711 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYWKG-00081W-B7 for submit@debbugs.gnu.org; Sat, 04 Mar 2023 13:09:44 -0500 Received: from eggs.gnu.org ([209.51.188.92]:47800) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYWKE-00081K-GV for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 13:09:42 -0500 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 1pYWK8-0001BW-D1; Sat, 04 Mar 2023 13:09:36 -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=S230vgiuiK9uPJyV+Lqc2JDcKDQEbJ7ElP2c8DJV3oA=; b=FX/gy88BYdfKCoQ7utgP d+0BP+CIpIJk+XB3g0gS82yfAdCIxjR6IMidu7AGsTDih4u6KZZGyAC/wInQYJZTTwKiccd4KEkjS vmHB9vJ8oqdHA4DnO6+i33K6+tcH1CdYuZ1rugj09QLOou5lCW/WHB2lEYq0Rwhzo/xOsyTJRGgNm KK9JiOnMznmBfVUtcIZxvIQTcGoLNYDa5RKWjsVxdzZzVY6o+3vkLTnLNZ5ui7VQqK482M7hY4Dyd RgY9jz8iIAUIwl1KbnsrZvibGRsYU0UAF501hzwNOEy5SCctQ8jWF4dyaLrGEPGykZ5gWdBWrk8ox g/gM7/f5iPBWTQ==; 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 1pYWK7-0001Tm-Gm; Sat, 04 Mar 2023 13:09:36 -0500 Date: Sat, 04 Mar 2023 20:09:24 +0200 Message-Id: <83fsak9ynf.fsf@gnu.org> From: Eli Zaretskii To: Basil Contovounesios In-Reply-To: <87pm9oqvs1.fsf@tcd.ie> (message from Basil Contovounesios on Sat, 04 Mar 2023 17:19:26 +0000) Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <87pm9oqvs1.fsf@tcd.ie> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 61637 Cc: 61637@debbugs.gnu.org, joaotavora@gmail.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: Basil Contovounesios > Cc: Eli Zaretskii , 61637@debbugs.gnu.org > Date: Sat, 04 Mar 2023 17:19:26 +0000 > > João Távora [2023-03-04 01:04 +0000] wrote: > > > Another option is to have eglot-tests.el read a new environment var: > > > > diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eglot-tests.el > > index 5d5de59a19a..ad994915c52 100644 > > --- a/test/lisp/progmodes/eglot-tests.el > > +++ b/test/lisp/progmodes/eglot-tests.el > > @@ -116,9 +116,7 @@ eglot--call-with-fixture > > ;; installations for LSP servers like pylsp, making > > ;; these tests mostly useless, so we hack around it > > ;; here with a great big hack. > > - ,(format "HOME=%s" > > - (if (file-exists-p home) home > > - (format "/home/%s" (getenv "USER"))))) > > + ,(format "HOME=%s" (or (getenv "EGLOT_REAL_HOME") (getenv "HOME")))) > > process-environment)) > > ;; Prevent "Can't guess python-indent-offset ..." messages. > > (python-indent-guess-indent-offset-verbose . nil) > > > > This is acceptable for Eglot devs like me, but other devs that don't > > know about this variable will still be confused. WDYT? > > So the suggestion is for parties interested in running the full > unadulterated Eglot suite to set this environment variable, thus opting > into using their HOME or any other HOME-like environment they may have > set up? For process-environment only, i.e. for the LSP server that is being started. Presumably, not for Emacs itself. From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 14:18:02 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 19:18:02 +0000 Received: from localhost ([127.0.0.1]:37759 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYXOL-0001cH-PM for submit@debbugs.gnu.org; Sat, 04 Mar 2023 14:18:02 -0500 Received: from mail-wm1-f43.google.com ([209.85.128.43]:52846) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYXOH-0001bn-3D for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 14:18:00 -0500 Received: by mail-wm1-f43.google.com with SMTP id j3so3458176wms.2 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 11:17:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1677957471; 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=LW5drATV/YcoA8YIFgMoB6FlMmSu+G9oebatCGGOXBc=; b=n+Lm8cwQEU7DLniOZz+CInw5OatXIn2WVYJmIgzkmkjXHmB8TSYizLxexxg4JSj3xI 6tZ7wmLX4dQKJLeIyW90+4MT6oMRzvA3SH4Y+AShOhfIfGzph3aPfpAYk8F/gHARor2E ndTbDC2rRcVNLbhfeEiPXQ0e311nsWu74ZljgpM+o+QSCYqbe/if2MnV/q1udrBsCeiX mrB8yRakM0d2+vzH1n4v8k4kRYLSXUWTbFzktfO5o32WDKU8r8T7Ud/Bs3BEcd3pAcPq NB5DtQ27romRkGZdk2Jx25A4u0FUGHqVvalstaY3bxYRvCUu63OOA86tx5NqEW4i1Wn2 ExFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677957471; 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=LW5drATV/YcoA8YIFgMoB6FlMmSu+G9oebatCGGOXBc=; b=1scyO/Pw5j3MgKm07AP3ajWx5vPcUyRivXGAx0fTilR2buQ2JHbbVg3tOAn7D6PywB 31czlSY1gTxC8wi2M23xSW/73C1YycYZwfmLU91d7S12TtVLAfiYEdqQCb1GD2NkI9pU LETx+HubnAdeFJcggCA0z86tblVNYxWXyNI9YLYdDxbTvTiZwcZs6lSE5G2Y0U5m2rLd k/FhsdhHAAniwmgvIDqgUXMm1STxPnk1PqjkC5In590p+Dq+5+GsrdVWvFZUgMKV+eRI 16RusO+MHeZ4DnouRWvp0Bf7cLV1VsXRJTXqw9AC6eJ0M7STWdlIiA9AV0oyi3+ZoarK Quxw== X-Gm-Message-State: AO0yUKUhwoGgufNUU9quvEoVB3HuMfCdjwvrlqPsFOU4gaWe40uVpRt1 AG6fs+iZ0x6N/+UK9bIoyWTFeBpCVeY= X-Google-Smtp-Source: AK7set8dos/45AoEl9cel+NkVTbcQsiF91Q5SSL/l1iNkyTAL7nMhwQk1UNbbiyQxKcyXe5WqEBvhQ== X-Received: by 2002:a05:600c:4f15:b0:3eb:3998:36fa with SMTP id l21-20020a05600c4f1500b003eb399836famr5134136wmq.29.1677957470840; Sat, 04 Mar 2023 11:17:50 -0800 (PST) Received: from krug (87-196-72-142.net.novis.pt. [87.196.72.142]) by smtp.gmail.com with ESMTPSA id d42-20020a05600c4c2a00b003e6efc0f91csm5691281wmp.42.2023.03.04.11.17.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 11:17:50 -0800 (PST) From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: Basil Contovounesios Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <87cz5oqvfs.fsf@tcd.ie> (Basil Contovounesios's message of "Sat, 04 Mar 2023 17:26:47 +0000") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> <87cz5oqvfs.fsf@tcd.ie> Date: Sat, 04 Mar 2023 19:19:46 +0000 Message-ID: <87356kl3xp.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: 61637 Cc: Eli Zaretskii , 61637@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 (-) Basil Contovounesios writes: > Normally HOME would not exist during our test suite, except > eglot-tests.el loads ert-x.el, which conditionally sets HOME=3D/tmp at > top-level (see the definition of ert-remote-temporary-file-directory). Ahhh... so that's why the unspoofing technique stopped working recently. Presumably that is a recent change. If so, that clears up the mistery. Thanks! Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 14:20:56 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 19:20:56 +0000 Received: from localhost ([127.0.0.1]:37763 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYXRA-0001hz-Bb for submit@debbugs.gnu.org; Sat, 04 Mar 2023 14:20:56 -0500 Received: from mail-wm1-f47.google.com ([209.85.128.47]:52941) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYXR8-0001hk-Nh for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 14:20:55 -0500 Received: by mail-wm1-f47.google.com with SMTP id j3so3460506wms.2 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 11:20:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1677957649; 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=pXLZJVseeUaz8+XYAJgYmmV8/cgHCw43XSEKpmRaCJs=; b=Nz7+NcH/X8oa7eer6kD9Gn0DkHVHhE93utDtF0B7NztSOQ9GI4s7KZnAkwrG82gBBa 71pA2oKlBDfHltI24ZRzk59W672M69MQ54DoNISxCYJLI/XIWnCy61U/mO/XWu1z5QUg rvfba881uWKbMuw84g3iOXwBXQoLhg1i442lL1bCSbK4+uXNVWUOBvGZvj4Z7sgp/17E NsnJvQRGl+0NdE4aYLyeBxFo4U6ODJjnekQurZeliVGJqMBpeFO2BosxygY9uNCu9Xak 7qdj0zj0lTnJzeo0xaQMLtRc55CED+Z8LS8Rj0F6AjgrngxHVX9EB3ltrcUMyJhBYDf8 mS+A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677957649; 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=pXLZJVseeUaz8+XYAJgYmmV8/cgHCw43XSEKpmRaCJs=; b=pI6mA9vLYDNbh0OgZ7N7itAaA16Coz4RqrhB28a6B+/VhErRiyv2LbpiIq6IQPt8XM qmfg1ulWK/aJyYMEKYGSjbYN8mZtDFJF8Pn1gMFpb9OsJmr9Om/TSkodTFprpY3fkdgM J8FsSJOg9qwu3SsuWde1xB6Ke95G0NjHvuURiw2zmCzPHz+R+e9WI8QuHe/e8u8lLk+O cviXDoN/+IU/ODg7wkhnDZPKPzXYxkEN6ZOJuWQv+O4NHghPcUlD5MHZsepI/xWn6zHH Zt8d04n3ba9k/VCs47TFSC1iLKv4bWZNnTgqwdZXekrnKiIihsd9Ds4Trvwtrmfle8rP OQtA== X-Gm-Message-State: AO0yUKWBD1Jcmj2/wGJHLvfPoizB+hIEfMIL9ID6i5UMj7K4PWLddEzT kpOLHRAiOqfsTTSKu1ltSIoKozqB1RY= X-Google-Smtp-Source: AK7set82MEKC971j4hMqpXLZZffwbNGuZ0yJJgyl1DuVx8GGi8ceteqe/4VmZVYfjeGZVTj/S1G3sw== X-Received: by 2002:a05:600c:5251:b0:3da:2ba4:b97 with SMTP id fc17-20020a05600c525100b003da2ba40b97mr4007723wmb.19.1677957648715; Sat, 04 Mar 2023 11:20:48 -0800 (PST) Received: from krug (87-196-72-142.net.novis.pt. [87.196.72.142]) by smtp.gmail.com with ESMTPSA id l5-20020a05600c16c500b003e20fa01a86sm5829264wmn.13.2023.03.04.11.20.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 11:20:48 -0800 (PST) From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: Basil Contovounesios Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <874jr0qvce.fsf@tcd.ie> (Basil Contovounesios's message of "Sat, 04 Mar 2023 17:28:49 +0000") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> <87v8jg68l0.fsf@gmail.com> <83sfekadlg.fsf@gnu.org> <874jr0qvce.fsf@tcd.ie> Date: Sat, 04 Mar 2023 19:22:44 +0000 Message-ID: <87y1ocjp8b.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: 61637 Cc: Eli Zaretskii , 61637@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 (-) Basil Contovounesios writes: > Any of the suggestions I've enumerated so far sounds plausible to me. > But I'd appreciate some feedback on which combination if any is > preferred before proceeding to suggest a new patchset (unless Jo=C3=A3o b= eats > me to it). Eli has already said that he is OK with restoring the HOME unspoofing in eglot--call-with-fixture unconditionally, so I've just pushed that. 'make check' now runs consistently with 0 failures on emacs-29. But I'm still interested in your other cleanups, like more idiomatic code, whitespace fixes, etc. So feel free to show a patchset for that or just push directly to emacs-29 (or master). Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 14:24:08 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 19:24:08 +0000 Received: from localhost ([127.0.0.1]:37767 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYXUF-0001p5-T2 for submit@debbugs.gnu.org; Sat, 04 Mar 2023 14:24:08 -0500 Received: from mail-wm1-f43.google.com ([209.85.128.43]:47023) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYXUE-0001oc-05 for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 14:24:06 -0500 Received: by mail-wm1-f43.google.com with SMTP id l7-20020a05600c1d0700b003eb5e6d906bso3036548wms.5 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 11:24:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1677957840; 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=k/vUmV1PlKTBdMwPLFUDKzrVle6lHpomrIhbCxMyZKA=; b=gzly7FJATBSf3I3kzV8LCwkJwgja0BdbNoCinnDwASwEBrFAgWQtJy1pZkRKP7WvJM jkrnViOfX/MYeCC6PXB7oirUNU387CFsEOkq1gpS1Bsnqsdo1/MiKW925OBnXa4kKFyU bOeifV3uzbby0Rite1hz3CNLhWJrfOHgozrjJ1TkygnZehpjToBI1aAHXxKx1TqPBZ/g WSM6Rq7cC9BdYXV6/e+ZvnimtW7mD3LVXu66iLGgkLW2goeTt+zaHI0jp7xvubVRuQ75 oLpUwwm3t1Cm40XD4xS3l0QhMGJOjK5WJFsS5izYulpIzn+LaYtPA7gnEtkapp+4FZFL uU9Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677957840; 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=k/vUmV1PlKTBdMwPLFUDKzrVle6lHpomrIhbCxMyZKA=; b=DLHRYbym/XqsfjuW/lNNpItjTYzG709CQ0pxRqQvfckuHkoBckxz11174RDLSkaXrg 7FxuKWUidGM/0sfKHUxxxTN9ZWsIAOV2Rk4gwFYoQLjAg/mB9uC92bGwKPthB58wjPSg 3LZMVd4TPljH1jWLVnm1TtiTSIP+SHuvJikCKhiOyElKG34bsSNdFnYB2LTcrTLULgg9 QJym3r4AIrHKeZkwYEqFGZQNf6tzQxFnuyapkz+hj8OQNzawENH3ZStXj0o+DHrAL1Ec DWtjGAkPPuMqhZUVCYycTuehP0OnL9IC2MeAnu5TdiTKoswHqZkPhqn0c5fdJOOTdUab nD5Q== X-Gm-Message-State: AO0yUKXuq4MeeNcDv7CuNWwA0So/j7Q7th5gqwRgBo1vNA5ngt3GSvAv FCS4QhBZ1PTriJxpZG9g8zzq3t1EcFU= X-Google-Smtp-Source: AK7set8gqGE+nppc4sWvRNfIwyDSCX0sP0sagCsg4ZGhUZj/uwJKqRBQi/pk9rXbdrnNFvVofo2wdQ== X-Received: by 2002:a05:600c:5248:b0:3eb:3b5d:9cab with SMTP id fc8-20020a05600c524800b003eb3b5d9cabmr5231401wmb.15.1677957839973; Sat, 04 Mar 2023 11:23:59 -0800 (PST) Received: from krug (87-196-72-142.net.novis.pt. [87.196.72.142]) by smtp.gmail.com with ESMTPSA id o10-20020a05600c164a00b003e20cf0408esm5739934wmn.40.2023.03.04.11.23.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 11:23:59 -0800 (PST) From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: Basil Contovounesios Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <87pm9oqvs1.fsf@tcd.ie> (Basil Contovounesios's message of "Sat, 04 Mar 2023 17:19:26 +0000") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <87pm9oqvs1.fsf@tcd.ie> Date: Sat, 04 Mar 2023 19:25:55 +0000 Message-ID: <87sfekjp30.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: 61637 Cc: Eli Zaretskii , 61637@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 (-) Basil Contovounesios writes: > Jo=C3=A3o T=C3=A1vora [2023-03-04 01:04 +0000] wrote: > >> Another option is to have eglot-tests.el read a new environment var: >> >> diff --git a/test/lisp/progmodes/eglot-tests.el b/test/lisp/progmodes/eg= lot-tests.el >> index 5d5de59a19a..ad994915c52 100644 >> --- a/test/lisp/progmodes/eglot-tests.el >> +++ b/test/lisp/progmodes/eglot-tests.el >> @@ -116,9 +116,7 @@ eglot--call-with-fixture >> ;; installations for LSP servers like pylsp, making >> ;; these tests mostly useless, so we hack around it >> ;; here with a great big hack. >> - ,(format "HOME=3D%s" >> - (if (file-exists-p home) home >> - (format "/home/%s" (getenv "USER"))))) >> + ,(format "HOME=3D%s" (or (getenv "EGLOT_REAL_HOME") = (getenv "HOME")))) >> process-environment)) >> ;; Prevent "Can't guess python-indent-offset ..." messag= es. >> (python-indent-guess-indent-offset-verbose . nil) >> >> This is acceptable for Eglot devs like me, but other devs that don't >> know about this variable will still be confused. WDYT? > > So the suggestion is for parties interested in running the full > unadulterated Eglot suite to set this environment variable, thus opting > into using their HOME or any other HOME-like environment they may have > set up? > > If so, sounds fine to me, thanks, Yes that would be the suggestion, but it still has considerable drawback that non-Eglot devs looking just to check that they didn't break anything and who _do_ happen to have these servers installed will still see test failures in Eglot that are hard to diagnose. They likely won't know about EGLOT_REAL_HOME, and neither should they, really. This solution would only be acceptable if PATH was _also_ spoofed (and then unspoofed on request). Bug spoofing PATH is a taller order, since it's hard to know what are platform specific system paths and what are "user paths". Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 14:25:30 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 19:25:30 +0000 Received: from localhost ([127.0.0.1]:37771 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYXVa-0001rw-D5 for submit@debbugs.gnu.org; Sat, 04 Mar 2023 14:25:30 -0500 Received: from mail-wm1-f54.google.com ([209.85.128.54]:42920) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYXVO-0001rI-Dn for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 14:25:29 -0500 Received: by mail-wm1-f54.google.com with SMTP id o11-20020a05600c4fcb00b003eb33ea29a8so3056871wmq.1 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 11:25:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1677957910; 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=wz4JAJF42YLHOLlAFxLjSCdjlSKhzAVT6slCQKhbH1Q=; b=Q0qs2qtksu6FJvKZY0xFrDZI3ixQ0cRVxQrSIR5/bZJ29n2/nkVs95ZZ5kzdOJPHFo ylUQKCinh9iORs2C6y1ao7aqbUFpAozz/98ORV3/xnBbMtKirrCLrpGmKWm1Q01aMylZ EnSqfd/+7ZZ2reY2cCs84xk6febY/eV0ffDQCl5fmLAyT33LrjF0u8XM2G2iUinb+am6 cB+t/dUlgNCpTxH4zODVb9lO5NKIcdw9bee/EJzpiUHEGyB6kX73jG8ElH7zc10JZFnP Ys4liHMlOMPBoPDAJBnQTvWi/QNdAm6+KuoKx5NslslnLrp9lTq2DT12JC8ryf98mrdc PqUw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677957910; 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=wz4JAJF42YLHOLlAFxLjSCdjlSKhzAVT6slCQKhbH1Q=; b=VLUipNSoTKfm7/1VX/cUxMsRWCdtHKhFp6fielpkEnIpnW9T2I6cljY1/ysCnwHJGV QRBrImfOm9ptBQQHaiURVlERdmzFMSzFPohMlSfVphlytws3Ovnu1vPbVorWf2Bp9Wnm w9au2fNhNySVeDFB+UPXuNYI2239NAA5hxoOiMH27hsriEbKBwPZ9XvzlOgdWSTIl4Jy wR+ICnDyfBLlial+TQEqtKdptqsrLbXNsvCwFMKYTyMdXvLET5laTMuOMSZSJ0uBB+QL NNwGorAOp+2c2BAXn+yy8PF6rRn1pvwIV76vUruyvTcIM9pY43kJBd1lq5OBuApEtS8U cqNA== X-Gm-Message-State: AO0yUKWqnbBBaXY6gsjshaZHrCVdFrTusfGSEpwxvAnBP6RkTOuRPCez G5Wuy9tFHcQZFfouI0gIp2Sxpr0TkuU= X-Google-Smtp-Source: AK7set9jtkxELIE4tdeQhWuGDujoRliRViuFbqtoHeb4pr6ynGuOzE4jHbqi+mYnsVk4dbnJIoHbSA== X-Received: by 2002:a05:600c:4f0f:b0:3dc:3b29:7a4 with SMTP id l15-20020a05600c4f0f00b003dc3b2907a4mr4200313wmq.0.1677957910166; Sat, 04 Mar 2023 11:25:10 -0800 (PST) Received: from krug (87-196-72-142.net.novis.pt. [87.196.72.142]) by smtp.gmail.com with ESMTPSA id h17-20020a05600c351100b003e4326a6d53sm10382109wmq.35.2023.03.04.11.25.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 11:25:09 -0800 (PST) From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: Eli Zaretskii Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <83fsak9ynf.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 04 Mar 2023 20:09:24 +0200") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <87pm9oqvs1.fsf@tcd.ie> <83fsak9ynf.fsf@gnu.org> Date: Sat, 04 Mar 2023 19:27:05 +0000 Message-ID: <87o7p8jp12.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: 61637 Cc: Basil Contovounesios , 61637@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 (-) Eli Zaretskii writes: >> So the suggestion is for parties interested in running the full >> unadulterated Eglot suite to set this environment variable, thus opting >> into using their HOME or any other HOME-like environment they may have >> set up? > > For process-environment only, i.e. for the LSP server that is being > started. Presumably, not for Emacs itself. That is correct. Only for process-environment, and only within 'eglot--with-fixture'. Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 04 14:33:58 2023 Received: (at 61637) by debbugs.gnu.org; 4 Mar 2023 19:33:58 +0000 Received: from localhost ([127.0.0.1]:37776 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYXdm-00027u-BX for submit@debbugs.gnu.org; Sat, 04 Mar 2023 14:33:58 -0500 Received: from mail-wr1-f54.google.com ([209.85.221.54]:46819) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pYXdl-00027g-AN for 61637@debbugs.gnu.org; Sat, 04 Mar 2023 14:33:57 -0500 Received: by mail-wr1-f54.google.com with SMTP id bw19so5209086wrb.13 for <61637@debbugs.gnu.org>; Sat, 04 Mar 2023 11:33:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1677958431; 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=gQRldFofzJlSdl6liiL6I7TUvhE16JTrHDQJIApYA2E=; b=CizUABO76posx8/T6hcHm6eU7HKhHsQdq4LJfkm0qrxtGyUgzPLHqUH39chSq8GX97 4j5AxkJVKmIZgbSEj2pBE68h3baEoh9SLj5WbXVcgKG4/rqD0i0GxhoX28Dy+GWAhnHY yhklIHnrt9WvfuTksSP4rUZ+oYrJpJcX8tN9/TrSmLh2QgK/ac7A1ZpI9rarEgVGd/Hw lgXjxTUj+/GK7E9lNe9OCy+UqS8whmvp6KXKT6/1wVgOM46u2EsTlEdeYGLeygVMpdwv IKOBmBgsZUgImO2pfnAOWU5pjQ/iZ23nR9aeAEv7qajF4vhjSToVJMpMB84KVN9N2PIl P8jQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677958431; 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=gQRldFofzJlSdl6liiL6I7TUvhE16JTrHDQJIApYA2E=; b=PK/arUVS7sAbB6Gm23mgYd/riryGU332IdFKKhOfdal72m+cKa6pTyh4q62vJ/y7l6 0VdQxRWZ71sl6PKb1P6Mit9SNWsseP1t3GAX5FCPjOY6mXjaW6Z8y6LfiHHys/SkbnoF E2PObphP1cb94OrXF3Lkg1/ElsVD5XEaQcmnFregAalHNX5DL1jyY9hxQqhv7l9JIKzr ubFpELqk/Zip/1OLWE5ZavJIHDYWCrsBnAA6fyIAvWoXq6bwxf6fn8Hjlm2porRH+IT/ pqJll5pX/HGAYaKVSvErEDFMQED7902i6AU4uj4NqWPdThUqq/AMZ1qXpHz1TnmLzxOz 9Ztw== X-Gm-Message-State: AO0yUKVtZ0QVq82Y7DHoiRNm6Y0aUvGCHcb8XlLlNlAiHf8wcBx9FLk0 vSKRTvmVZJ4NNoSQr5ZflLWwmETBT9k= X-Google-Smtp-Source: AK7set8Jpkcg9QC+YSugIbvDLrEspcM72ialu7p9Pab0+UEJDtJmaOBoXa/adbSoEHRzsnkq+e6xkg== X-Received: by 2002:a5d:5447:0:b0:2c7:a55:bef2 with SMTP id w7-20020a5d5447000000b002c70a55bef2mr3243879wrv.46.1677958431238; Sat, 04 Mar 2023 11:33:51 -0800 (PST) Received: from krug (87-196-72-142.net.novis.pt. [87.196.72.142]) by smtp.gmail.com with ESMTPSA id s11-20020a5d510b000000b002c55b0e6ef1sm5960919wrt.4.2023.03.04.11.33.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Mar 2023 11:33:50 -0800 (PST) From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: Basil Contovounesios Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <87ilfgqvp6.fsf@tcd.ie> (Basil Contovounesios's message of "Sat, 04 Mar 2023 17:21:09 +0000") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> <87v8jg68l0.fsf@gmail.com> <83sfekadlg.fsf@gnu.org> <87jzzw646j.fsf@gmail.com> <87ilfgqvp6.fsf@tcd.ie> Date: Sat, 04 Mar 2023 19:35:46 +0000 Message-ID: <87jzzwjoml.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: 61637 Cc: Eli Zaretskii , 61637@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 (-) Basil Contovounesios writes: > Based on the test failures I've been seeing for months and tried to > address in the original patches (not all of which are due to an > unexpected HOME setting), it feels like that's probably too optimistic a > conclusion in the general case. If you have described those somewhere, I haven't had a chance to look, but I'm interested. Anyway, the other changes of your original patch are fine. You can just push them if they make tests more robust. > A lot of the relevant tooling places its configuration directly under > HOME for example, not under XDG_CONFIG_HOME. As far as I recall, the only LSP server that relied significantly on user-wide configuration is pyls, and it was fixed via XDG_CONFIG_HOME. When that change made it in (in the old Github repo), this was the commit message: Close #441: shield tests from some user customizations =20=20=20=20 Users' customization of Python indenting style in the standard XDG_CONFIG_HOME location of ~/.config/pycodestyle could cause spurious test failures. We prevent this and similar problems by overriding that environment variable in tests. If this turns out to hurt other language servers used in the test suite, we'll have to revisit. See https://github.com/joaotavora/eglot/issues/441 for more. I can't recall other servers -- used in eglot-tests.el -- that suffer from the same effect (at least to the point of that effect being relevant). > I can also imagine user-specific settings affecting some of the > auto-formatting functionality tested in eglot-tests.el. Yes, but as I said these things are much more commonly set per-project (via eglot-workspace-configuration) or on server invocation (via :initializationOptions) than in a user HOME directory. Makes sense, no? Every project has its practices, etc. Jo=C3=A3o From debbugs-submit-bounces@debbugs.gnu.org Mon Apr 10 06:10:09 2023 Received: (at control) by debbugs.gnu.org; 10 Apr 2023 10:10:09 +0000 Received: from localhost ([127.0.0.1]:34376 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ploTQ-0007Zy-Nt for submit@debbugs.gnu.org; Mon, 10 Apr 2023 06:10:09 -0400 Received: from mail-wm1-f49.google.com ([209.85.128.49]:41860) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ploTL-0007Z5-OE for control@debbugs.gnu.org; Mon, 10 Apr 2023 06:10:07 -0400 Received: by mail-wm1-f49.google.com with SMTP id n19-20020a05600c501300b003f064936c3eso7453956wmr.0 for ; Mon, 10 Apr 2023 03:10:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd.ie; s=google21; t=1681121398; x=1683713398; 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=DhFqZGgmucDamSbkkizotnAKK1AYrsvpvFijnwNfIok=; b=Fqg0qP40W+CWww10anD+S9bC/O9cUXzdQISPxVl5USXrpuPR/cM/VrLwJLQfVYZ+qF 1hucAzCcYC+InCQGis4b69pEIrNB4MRBHqdiqa7msa5dI5YA+i32Sx61CBQ4vTkk5IYd yQ+UsocmArB2qa9JCVvNpvz1BAgLsdCXHpDQBw+Z+gV58b32TH0src5lYcRp6jpcXQhq 4Z2LXczAy1SBbfziqxaK6mzMImwZV6LI8fA57UJE5XKGGMsPQcWpMp03pj0SgGJtMBbq fG4L1RGpEkVjgAWOJvk2C2aCvNDLHvrrDVqnM83Ryqrqxk0zlF0YEzh0xoF76Kk3Flsc w85g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681121398; x=1683713398; 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=DhFqZGgmucDamSbkkizotnAKK1AYrsvpvFijnwNfIok=; b=Mn/sDR81BisslvEMjQr/2NHFqhMnHpnqvMSRU4vw5xe0lYx3CNX9oOTkhsnL2GuGh1 Cm86EPYqbs/9vW2/NRxADfYxP71A2WyJBemdVw3gc+7GC0R0nfOzzS8e/DfIwMqloPWD WdIamn7zPEgJKWsIABCixVmr5hZJHi7eyJtdZXM+Vdj+9nkkPHi8NtsZBBQQ2cvRFAG1 YfMstcGozVOs88tiohlRjhzaraYwGeCVp4dCIcKx+awvdO7uRbDYzRg970LvbPJSMwTN 43Tm7f/U/twWBVwD6CFqWBerkYEjtXb97q1IsSU98x6dy59193QZnqaJ4z/EdktE4vgl 14fw== X-Gm-Message-State: AAQBX9fvkn1Pm6k9B2gkV7eJZSCk+SOjEUV9OeZqptPFh1aLZ5rINBUd bqHyahldqStP9FWqQZ+O/F2Bkw== X-Google-Smtp-Source: AKy350bgKrrw+xk9Ax9hTq+5J3cxCR6TOtxfROykJ98OYVUEK+7HrmlezaUATqhwXVireCjdhSgDyg== X-Received: by 2002:a05:600c:254:b0:3ef:6fee:8057 with SMTP id 20-20020a05600c025400b003ef6fee8057mr6810246wmj.25.1681121397963; Mon, 10 Apr 2023 03:09:57 -0700 (PDT) Received: from localhost ([109.78.216.163]) by smtp.gmail.com with ESMTPSA id q10-20020a05600c46ca00b003eddc6aa5fasm17227120wmo.39.2023.04.10.03.09.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Apr 2023 03:09:57 -0700 (PDT) From: Basil Contovounesios To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Subject: Re: bug#61637: 30.0.50; Fix Eglot tests that need HOME=~USER In-Reply-To: <87y1ocjp8b.fsf@gmail.com> (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vor?= =?utf-8?Q?a=22's?= message of "Sat, 04 Mar 2023 19:22:44 +0000") References: <87ilfxv5dg.fsf@tcd.ie> <87h6vgelnn.fsf@tcd.ie> <83leksv6az.fsf@gnu.org> <87bkl972du.fsf@gmail.com> <83a60tarif.fsf@gnu.org> <87v8jg68l0.fsf@gmail.com> <83sfekadlg.fsf@gnu.org> <874jr0qvce.fsf@tcd.ie> <87y1ocjp8b.fsf@gmail.com> Date: Mon, 10 Apr 2023 11:09:56 +0100 Message-ID: <873558gia3.fsf@tcd.ie> 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: control Cc: Eli Zaretskii , 61637-done@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 (-) close 61637 30.1 quit Jo=C3=A3o T=C3=A1vora [2023-03-04 19:22 +0000] wrote: > But I'm still interested in your other cleanups, like more idiomatic > code, whitespace fixes, etc. So feel free to show a patchset for that > or just push directly to emacs-29 (or master). Now pushed to master, and closing. Thanks, --=20 Basil From unknown Fri Aug 22 01:33:45 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Mon, 08 May 2023 11:24:07 +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