all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "João Távora" <joaotavora@gmail.com>
To: David Ventimiglia <davidaventimiglia@neptunestation.com>
Cc: 59824@debbugs.gnu.org
Subject: bug#59824: flymake-show-project-diagnotics not updating (eglot for Java with jdtls)
Date: Sun, 04 Dec 2022 21:03:12 +0000	[thread overview]
Message-ID: <87v8mqq3u7.fsf@gmail.com> (raw)
In-Reply-To: <CAPTUb8YsSQmGWOcJueK2F8pGfe0F2B3cJY88MEdYMjtSn9Zx3g@mail.gmail.com> (David Ventimiglia's message of "Sun, 4 Dec 2022 12:38:55 -0800")

David Ventimiglia <davidaventimiglia@neptunestation.com> writes:

> I grant that this may not be a bug and could be a mis-configuration,
> but I am trying to track that down.  Thanks!

I may have found the possibly culprit in Eglot.  I wish you could try
the patch after my sig, untested by me.  Also, if you find that the
project listing still doesn't update automatically, please go to its
buffer and type 'g' (and report back here that you needed this extra
step).

João

diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el
index e057b12e0ee..3d0e97bba8c 100644
--- a/lisp/progmodes/eglot.el
+++ b/lisp/progmodes/eglot.el
@@ -2048,9 +2048,11 @@ eglot-handle-notification
                     (t          'eglot-note)))
             (mess (source code message)
               (concat source (and code (format " [%s]" code)) ": " message)))
-    (if-let ((buffer (find-buffer-visiting (eglot--uri-to-path uri))))
+    (if-let* ((path (expand-file-name (eglot--uri-to-path uri)))
+              (buffer (find-buffer-visiting path)))
         (with-current-buffer buffer
           (cl-loop
+           initially (assoc-delete-all path flymake-list-only-diagnostics #'string=)
            for diag-spec across diagnostics
            collect (eglot--dbind ((Diagnostic) range code message severity source tags)
                        diag-spec
@@ -2093,7 +2095,6 @@ eglot-handle-notification
                          (t
                           (setq eglot--diagnostics diags)))))
       (cl-loop
-       with path = (expand-file-name (eglot--uri-to-path uri))
        for diag-spec across diagnostics
        collect (eglot--dbind ((Diagnostic) code range message severity source) diag-spec
                  (setq message (mess source code message))







  parent reply	other threads:[~2022-12-04 21:03 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-04 20:38 bug#59826: flymake-show-project-diagnotics not updating (eglot for Java with jdtls) David Ventimiglia
2022-12-04 20:46 ` bug#59824: " João Távora
2022-12-04 21:03 ` João Távora [this message]
2022-12-04 23:22   ` David Ventimiglia
2022-12-05 11:30     ` João Távora
2022-12-05 22:28       ` David Ventimiglia
2022-12-07 11:34         ` João Távora
2022-12-05 22:27 ` bug#59826: additional info David Ventimiglia

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87v8mqq3u7.fsf@gmail.com \
    --to=joaotavora@gmail.com \
    --cc=59824@debbugs.gnu.org \
    --cc=davidaventimiglia@neptunestation.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.