From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= Newsgroups: gmane.emacs.bugs Subject: bug#66759: 30.0.50; Flymake (with Eglot) error cleaning up old overlay Date: Thu, 26 Oct 2023 18:10:46 +0100 Message-ID: <87il6t1f8p.fsf@gmail.com> References: <87pm111pkh.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="39853"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 66759-done@debbugs.gnu.org To: Richard Copley Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Oct 26 19:08:55 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qw3qp-000A97-BC for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 26 Oct 2023 19:08:55 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qw3qU-0002Tp-GQ; Thu, 26 Oct 2023 13:08:35 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qw3qS-0002Rk-4t for bug-gnu-emacs@gnu.org; Thu, 26 Oct 2023 13:08:32 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qw3qR-0005VW-Sa for bug-gnu-emacs@gnu.org; Thu, 26 Oct 2023 13:08:31 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qw3qw-0005om-NA for bug-gnu-emacs@gnu.org; Thu, 26 Oct 2023 13:09:02 -0400 Resent-From: =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= Original-Sender: "Debbugs-submit" Resent-To: bug-gnu-emacs@gnu.org Resent-Date: Thu, 26 Oct 2023 17:09:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 66759 X-GNU-PR-Package: emacs Mail-Followup-To: 66759@debbugs.gnu.org, joaotavora@gmail.com, rcopley@gmail.com Original-Received: via spool by 66759-done@debbugs.gnu.org id=D66759.169834010922320 (code D ref 66759); Thu, 26 Oct 2023 17:09:02 +0000 Original-Received: (at 66759-done) by debbugs.gnu.org; 26 Oct 2023 17:08:29 +0000 Original-Received: from localhost ([127.0.0.1]:34431 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qw3qP-0005nv-2H for submit@debbugs.gnu.org; Thu, 26 Oct 2023 13:08:29 -0400 Original-Received: from mail-lj1-x22b.google.com ([2a00:1450:4864:20::22b]:61450) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qw3qL-0005ng-7p for 66759-done@debbugs.gnu.org; Thu, 26 Oct 2023 13:08:27 -0400 Original-Received: by mail-lj1-x22b.google.com with SMTP id 38308e7fff4ca-2c59a4dd14cso15904291fa.2 for <66759-done@debbugs.gnu.org>; Thu, 26 Oct 2023 10:07:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1698340067; x=1698944867; darn=debbugs.gnu.org; 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=lveiLXDPvn/1HPPDQgObgAv7pbu0ynHYpLbEczqKy8Y=; b=PBZpbC7iq96jYZDqssQ09JtMd7j26NKZpy0MG2uCvbJOPQAeKPne90zgTnsWZudrHJ aIDxsJYoeFgtyb8O8puIW8o3TIwJpvbjjLneKfPqWAUe957QK9l4PvasXuf4/HG70Sdc W8mE0g9SjFDeALhcitr6MMbEbyK+9fW4rxBEUuKFz8qZrXR1Jp4PAfmmxtueP+WY/Y9C 7hXZ/SDzMKL6Du6t/4FYr3rEtK47+R3UdxDhXNHkT5lM6fdk9UGSRXCxSZTeh8k2HToj yrjzWCF9+Ioa/GQCiEzSTQVJTrzpA76atHGSffURFKiv19qN9nYOBTXLuToFeSH+eMy2 eq5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698340067; x=1698944867; 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=lveiLXDPvn/1HPPDQgObgAv7pbu0ynHYpLbEczqKy8Y=; b=rUqlAHCmAhxK2tX/wrB2Kvn62N3nzZVvkMJ2OshPtL+D5TOjxDqQUJl17INVAoGS/A sWCiZS8wTKgNWnKFS3GAtsJaUK0XSUG5bHTHmTlSiarFjNN08W4kSnaY3oDIJPrYkgny sPqwcXWNoiU6ewdlrpRvcPiGqYu1EtKwqFcD/BvmxJ1emPR/mfO5QWVtiQyAHmIn+/GS v46apoOeuefm9UtpDw5y9JGWVelxff7/Y0HyueVOUWL5L7kEKr4Dyw3TqXDaivm4goWt VLnqvS+4nwQN01sLlAkOBQ9HIOpVxiaY+yBoS1T7X/FEW/3VQuYBwp9yTFFJT6S/mm7v HrFg== X-Gm-Message-State: AOJu0YxocD/l27oA98yNrvPSetwIC8QBjK/4WhWr6FIbwcut2p2e0urw klD8c9/YC8WBVXlIWYv29RsWimBaG0deaA== X-Google-Smtp-Source: AGHT+IF7AZGY9io8MU2Km6iiJW1aS8YvWYnhfMb5TYmey07lNZgXN2x/9F0QiOguThTH134eHF5cBw== X-Received: by 2002:a05:651c:606:b0:2c5:5926:de15 with SMTP id k6-20020a05651c060600b002c55926de15mr147767lje.4.1698340067103; Thu, 26 Oct 2023 10:07:47 -0700 (PDT) Original-Received: from krug (87-196-80-249.net.novis.pt. [87.196.80.249]) by smtp.gmail.com with ESMTPSA id y9-20020a7bcd89000000b00407efbc4361sm3052016wmj.9.2023.10.26.10.07.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 26 Oct 2023 10:07:46 -0700 (PDT) In-Reply-To: (Richard Copley's message of "Thu, 26 Oct 2023 15:17:34 +0100") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:273306 Archived-At: Richard Copley writes: > On Thu, 26 Oct 2023 at 14:24, Jo=C3=A3o T=C3=A1vora wrote: >> Please keep an eye out of this bug. > > Thanks, will do. I've now reproduced the bug consistently. It happens exactly as you conjectured. To test, I temporarily hacked Eglot to take 2 seconds longer to process each request/notification with this patch: diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el index eba66503bf7..48845a889a8 100644 --- a/lisp/progmodes/eglot.el +++ b/lisp/progmodes/eglot.el @@ -1488,7 +1488,7 @@ eglot--connect ,@more-initargs))))) (spread (lambda (fn) (lambda (server method params) (let ((eglot--cached-server server)) - (apply fn server method (append params n= il)))))) + (run-at-time 2 nil #'apply fn server met= hod (append params nil)))))) (server (apply #'make-instance class And then made sure there was a diagnostic at the end of the file, changed the file and quickly enough (but only after the changes were sent to server), deleted the region with the diagnostic at the end of the file. Without my fix, I get exactly the (overlayp nil) error you reported. With the fix, everything works correctly. So I think with the fix I pushed earlier this bug can be closed, which I'm doing now. >> What language server are you using with Eglot btw? > [1] https://leanprover-community.github.io/learn.html > [2] https://github.com/leanprover/lean4-mode > [3] https://github.com/bustercopley/lean4-mode > [4] https://github.com/joaotavora/eglot/issues/615 > [5] https://github.com/joaotavora/eglot/pull/839 Yeah I know about these PRs. If you want can start a new report in the Emacs bug tracker proper (i.e. here) )and direct people to it. Write a summary of the situation if you can, and present this Lean4 use case as a argument. This gives visibility to more Emacs maintainers, and allows me to ping specialists like Eli more easily on the matter. Jo=C3=A3o