branch: elpa/flycheck
commit 5599c6d4dff29ea87f6d69ea708c10f4d2f97e42
Author: Bozhidar Batsov <[email protected]>
Commit: Bozhidar Batsov <[email protected]>

    Trust the Eglot spec's buffer for newer Flymake
    
    Flymake on Emacs master (and so on GNU ELPA) refuses to run any backend in
    an untrusted buffer unless the backend opts out.  Eglot opts out from the
    same change on, but the Eglot that ships with Emacs 30 doesn't, so with
    the newer Flymake the refusal reaches the spec as a user-error and the
    30.2 jobs fail.  The bridge itself calls eglot-flymake-backend directly
    and never meets the check.
---
 test/specs/test-lsp-integration.el | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/test/specs/test-lsp-integration.el 
b/test/specs/test-lsp-integration.el
index db9cb19bba..0113a0a37d 100644
--- a/test/specs/test-lsp-integration.el
+++ b/test/specs/test-lsp-integration.el
@@ -41,6 +41,8 @@
 ;; Bound by eglot, which the spec that uses them loads first
 (defvar eglot-server-programs)
 (defvar eglot-sync-connect)
+;; Emacs 30+ only
+(defvar trusted-content)
 
 (defconst test-lsp-integration/server
   (expand-file-name "mock-lsp-server.py" flycheck-test-directory)
@@ -232,6 +234,10 @@ down before the temp directory goes away."
                `((makefile-gmake-mode . ("python3" ,test-lsp-integration/server
                                          "pull"))))
               (eglot-sync-connect t)
+              ;; Newer Flymake refuses to run a backend in an untrusted
+              ;; buffer unless the backend opts out, which older Eglot
+              ;; doesn't, and the refusal escapes under Buttercup
+              (trusted-content :all)
               (flycheck-checkers '(eglot-check))
               (server nil))
           (unwind-protect

Reply via email to