unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
@ 2024-08-22 23:07 Dmitry Gutov
  2024-08-29 11:34 ` Eli Zaretskii
  0 siblings, 1 reply; 18+ messages in thread
From: Dmitry Gutov @ 2024-08-22 23:07 UTC (permalink / raw)
  To: 72765

Here's an example I came upon when testing:


test.c
```
int foo_bar_1;
int foo_bar_2;

int main() {foo_bar|456

```

Point is at |.

If you use completion-at-point, *Completions* buffer pops up, you choose 
one of the options with M-down and M-RET, "_1" is inserted. Good.

But if you use Company, type "_" (or backspace and re-add "r") - a popup 
comes up with "foo_bar_1" and "foo_bar_2", you choose one of the 
options, and the text becomes "foo_bar_1456456", suffix is duplicated.

This only happens with Clang, out of the servers I've tested.

You need a fairly recent Company to reproduce (from master), the 
previous versions simply didn't support completion in the middle of a 
symbol.

To add something that completion-at-point trips over, though: when 
"foo_bar_2" (existing var name) is already inserted, move point to the 
middle of it and press C-M-i:

```
   foo_|bar_2
```

will turn to

```
   foo_bar_2bar_2|
```





^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-08-22 23:07 bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text Dmitry Gutov
@ 2024-08-29 11:34 ` Eli Zaretskii
  2024-08-30 21:23   ` Dmitry Gutov
  0 siblings, 1 reply; 18+ messages in thread
From: Eli Zaretskii @ 2024-08-29 11:34 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: 72765

> Date: Fri, 23 Aug 2024 02:07:59 +0300
> From: Dmitry Gutov <dmitry@gutov.dev>
> 
> Here's an example I came upon when testing:
> 
> 
> test.c
> ```
> int foo_bar_1;
> int foo_bar_2;
> 
> int main() {foo_bar|456
> 
> ```
> 
> Point is at |.
> 
> If you use completion-at-point, *Completions* buffer pops up, you choose 
> one of the options with M-down and M-RET, "_1" is inserted. Good.
> 
> But if you use Company, type "_" (or backspace and re-add "r") - a popup 
> comes up with "foo_bar_1" and "foo_bar_2", you choose one of the 
> options, and the text becomes "foo_bar_1456456", suffix is duplicated.
> 
> This only happens with Clang, out of the servers I've tested.
> 
> You need a fairly recent Company to reproduce (from master), the 
> previous versions simply didn't support completion in the middle of a 
> symbol.
> 
> To add something that completion-at-point trips over, though: when 
> "foo_bar_2" (existing var name) is already inserted, move point to the 
> middle of it and press C-M-i:
> 
> ```
>    foo_|bar_2
> ```
> 
> will turn to
> 
> ```
>    foo_bar_2bar_2|
> ```

Is this an Eglot problem or a completion-at-point problem?





^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-08-29 11:34 ` Eli Zaretskii
@ 2024-08-30 21:23   ` Dmitry Gutov
  2024-08-31  6:47     ` Eli Zaretskii
  0 siblings, 1 reply; 18+ messages in thread
From: Dmitry Gutov @ 2024-08-30 21:23 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 72765

On 29/08/2024 14:34, Eli Zaretskii wrote:
> Is this an Eglot problem or a completion-at-point problem?

Looks like it belongs to Eglot.

It might be difficult to fix, especially given slight behavior 
differences between servers, but I think it's worth investigating.





^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-08-30 21:23   ` Dmitry Gutov
@ 2024-08-31  6:47     ` Eli Zaretskii
  2024-08-31 12:03       ` João Távora
  0 siblings, 1 reply; 18+ messages in thread
From: Eli Zaretskii @ 2024-08-31  6:47 UTC (permalink / raw)
  To: Dmitry Gutov, João Távora; +Cc: 72765

> Date: Sat, 31 Aug 2024 00:23:32 +0300
> Cc: 72765@debbugs.gnu.org
> From: Dmitry Gutov <dmitry@gutov.dev>
> 
> On 29/08/2024 14:34, Eli Zaretskii wrote:
> > Is this an Eglot problem or a completion-at-point problem?
> 
> Looks like it belongs to Eglot.
> 
> It might be difficult to fix, especially given slight behavior 
> differences between servers, but I think it's worth investigating.

João, do you have any comments or suggestions about this?





^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-08-31  6:47     ` Eli Zaretskii
@ 2024-08-31 12:03       ` João Távora
  2024-09-01  1:43         ` Dmitry Gutov
  0 siblings, 1 reply; 18+ messages in thread
From: João Távora @ 2024-08-31 12:03 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Dmitry Gutov, 72765

On Sat, Aug 31, 2024 at 7:47 AM Eli Zaretskii <eliz@gnu.org> wrote:
>
> > Date: Sat, 31 Aug 2024 00:23:32 +0300
> > Cc: 72765@debbugs.gnu.org
> > From: Dmitry Gutov <dmitry@gutov.dev>
> >
> > On 29/08/2024 14:34, Eli Zaretskii wrote:
> > > Is this an Eglot problem or a completion-at-point problem?
> >
> > Looks like it belongs to Eglot.
> >
> > It might be difficult to fix, especially given slight behavior
> > differences between servers, but I think it's worth investigating.
>
> João, do you have any comments or suggestions about this?

Looks like a bug, somewhere. Somehow these new company
versions don't follow exactly the same protocol as completion-at-point.
Eglot aims primarily at that, since it's what's in Emacs proper. But
Eglot also aims at supporting Company in particular as fully
as possible.

Anyway, I don't have time to investigate this. The :exit-function in
eglot.el should be stepped through to understand exactly who's at
fault. And I don't think differences between servers matter:
clangd is likely following the spec correctly here.

João





^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-08-31 12:03       ` João Távora
@ 2024-09-01  1:43         ` Dmitry Gutov
  2024-09-01  9:43           ` João Távora
  0 siblings, 1 reply; 18+ messages in thread
From: Dmitry Gutov @ 2024-09-01  1:43 UTC (permalink / raw)
  To: João Távora, Eli Zaretskii; +Cc: 72765

On 31/08/2024 15:03, João Távora wrote:

> Eglot aims primarily at that, since it's what's in Emacs proper. But
> Eglot also aims at supporting Company in particular as fully
> as possible.
> 
> Anyway, I don't have time to investigate this. The :exit-function in
> eglot.el should be stepped through to understand exactly who's at
> fault. And I don't think differences between servers matter:
> clangd is likely following the spec correctly here.

It seems the difference comes from bug#70968 as well (which came up 
recently).

When the completion style emacs22 is used, Company doesn't delete the 
suffix text before inserting completion. Which is an improvement for 
some other completion sources, but not Eglot, so far.

To to fix this here, we can avoid a fail-over to emacs22 by only 
matching the prefix in eglot--dumb-allc like this:

diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el
index 59d9c346424..20c15584d2d 100644
--- a/lisp/progmodes/eglot.el
+++ b/lisp/progmodes/eglot.el
@@ -3138,7 +3138,9 @@ eglot--dumb-flex
                                        nil comp)
             finally (cl-return comp)))

-(defun eglot--dumb-allc (pat table pred _point) (funcall table pat pred t))
+(defun eglot--dumb-allc (pat table pred point)
+  (funcall table (substring pat 0 point) pred t))
+
  (defun eglot--dumb-tryc (pat table pred point)
    (let ((probe (funcall table pat pred nil)))
      (cond ((eq probe t) t)

That fixes the scenario in Company, with seemingly no change with 
completion-at-point. Or if we want 100% compatibility, we can use 'or':

   (or
    (funcall table pat pred t)
    (funcall table (substring pat 0 point) pred t))

But in any case this doesn't help with the completion-at-point behavior 
described at the end of the report (where foo_|bar_2 turns into 
foo_bar_2bar_2|). If we consider it okay - then the above patch fixes 
the discrepancy with Company completion, and done. But if we think it a 
problem, then the fix might be required somewhere in the area of

                  (cond (textEdit
                         ;; Revert buffer back to state when the edit
                         ;; was obtained from server. If a `proxy'

After (and if) that is done, we might not need to change the completion 
style in the end.





^ permalink raw reply related	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-01  1:43         ` Dmitry Gutov
@ 2024-09-01  9:43           ` João Távora
  2024-09-01 14:28             ` Dmitry Gutov
  0 siblings, 1 reply; 18+ messages in thread
From: João Távora @ 2024-09-01  9:43 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: Eli Zaretskii, 72765

Dmitry Gutov <dmitry@gutov.dev> writes:

> On 31/08/2024 15:03, João Távora wrote:
>
>> Eglot aims primarily at that, since it's what's in Emacs proper. But
>> Eglot also aims at supporting Company in particular as fully
>> as possible.
>> 
>> Anyway, I don't have time to investigate this. The :exit-function in
>> eglot.el should be stepped through to understand exactly who's at
>> fault. And I don't think differences between servers matter:
>> clangd is likely following the spec correctly here.
>
> It seems the difference comes from bug#70968 as well (which came up 
> recently).

Okay, but that presumed bug has nothing to do with Eglot, AFAICT.

> When the completion style emacs22 is used, Company doesn't delete the 
> suffix text before inserting completion. Which is an improvement for 
> some other completion sources, but not Eglot, so far.
>
> To to fix this here, we can avoid a fail-over to emacs22 by only 
> matching the prefix in eglot--dumb-allc like this:
>
> diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el
> index 59d9c346424..20c15584d2d 100644
> --- a/lisp/progmodes/eglot.el
> +++ b/lisp/progmodes/eglot.el
> @@ -3138,7 +3138,9 @@ eglot--dumb-flex
>                                         nil comp)
>              finally (cl-return comp)))
>
> -(defun eglot--dumb-allc (pat table pred _point) (funcall table pat pred t))
> +(defun eglot--dumb-allc (pat table pred point)
> +  (funcall table (substring pat 0 point) pred t))
> +
>   (defun eglot--dumb-tryc (pat table pred point)
>     (let ((probe (funcall table pat pred nil)))
>       (cond ((eq probe t) t)
>
> That fixes the scenario in Company, with seemingly no change with 
> completion-at-point.

Like in that other recent bug, if you can add some Eglot test that
demonstrates the bug and then apply this fix and verify that it passes
the new tests and all the other tests you added recently, I'm fine with
the change.

> Or if we want 100% compatibility, we can use 'or':
>
>    (or
>     (funcall table pat pred t)
>     (funcall table (substring pat 0 point) pred t))

I don't understand what 100% compatibility this refers to, but if it is
a better change that also passes the aforementioned tests, I'm also fine
with it.

> But in any case this doesn't help with the completion-at-point behavior 
> described at the end of the report (where foo_|bar_2 turns into 
> foo_bar_2bar_2|). If we consider it okay - then the above patch fixes 
> the discrepancy with Company completion, and done. But if we think it a 
> problem, then the fix might be required somewhere in the area of
>
>                   (cond (textEdit
>                          ;; Revert buffer back to state when the edit
>                          ;; was obtained from server. If a `proxy'
>
> After (and if) that is done, we might not need to change the completion 
> style in the end.

Same criteria as above.  What's currently working shall continue
working.  I would advise generally to be conservative here: the bugs
you're fixing seem to be somewhat academic edge cases and not reports by
actual Eglot users.  But same idea: make tests that demonstrate the
bugs, fix those bugs and verify all the existing tests still pass.

The only thing I'd like to add is the following two notes:

* before any of this, you showed earlier a way to completely forbid
  partial completions in Eglot.  That's a good change for reasons we've
  already discussed and it prevents a number of bugs.  I'd like that
  change to be commited first (presuming it does what you expect it to).

* the rust-analyzer test you added recently -- and which you said was
  very brittle -- is indeed very brittle: I cannot get it to pass.  We
  should fix it, or just delete it and do those rust-analyzer tests
  manually each time we touch this area.

João





^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-01  9:43           ` João Távora
@ 2024-09-01 14:28             ` Dmitry Gutov
  2024-09-03 13:20               ` Dmitry Gutov
  0 siblings, 1 reply; 18+ messages in thread
From: Dmitry Gutov @ 2024-09-01 14:28 UTC (permalink / raw)
  To: João Távora; +Cc: Eli Zaretskii, 72765

On 01/09/2024 12:43, João Távora wrote:

>> It seems the difference comes from bug#70968 as well (which came up
>> recently).
> 
> Okay, but that presumed bug has nothing to do with Eglot, AFAICT.

One could argue that the current definition of the style (in Eglot) 
relies on buggy (or suboptimal) behavior in completion-at-point.

>> -(defun eglot--dumb-allc (pat table pred _point) (funcall table pat pred t))
>> +(defun eglot--dumb-allc (pat table pred point)
>> +  (funcall table (substring pat 0 point) pred t))
>> +
>>    (defun eglot--dumb-tryc (pat table pred point)
>>      (let ((probe (funcall table pat pred nil)))
>>        (cond ((eq probe t) t)
>>
>> That fixes the scenario in Company, with seemingly no change with
>> completion-at-point.
> 
> Like in that other recent bug, if you can add some Eglot test that
> demonstrates the bug and then apply this fix and verify that it passes
> the new tests and all the other tests you added recently, I'm fine with
> the change.

Sure.

>> Or if we want 100% compatibility, we can use 'or':
>>
>>     (or
>>      (funcall table pat pred t)
>>      (funcall table (substring pat 0 point) pred t))
> 
> I don't understand what 100% compatibility this refers to, but if it is
> a better change that also passes the aforementioned tests, I'm also fine
> with it.

One patch simply doesn't filter by the suffix, and another first tries 
filtering by prefix+suffix and if nothing matches falls back to 
filtering by prefix only.

>> But in any case this doesn't help with the completion-at-point behavior
>> described at the end of the report (where foo_|bar_2 turns into
>> foo_bar_2bar_2|). If we consider it okay - then the above patch fixes
>> the discrepancy with Company completion, and done. But if we think it a
>> problem, then the fix might be required somewhere in the area of
>>
>>                    (cond (textEdit
>>                           ;; Revert buffer back to state when the edit
>>                           ;; was obtained from server. If a `proxy'
>>
>> After (and if) that is done, we might not need to change the completion
>> style in the end.
> 
> Same criteria as above.

Alas, I have a fix which works for Company but not so well for 
completion-at-point:

diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el
index 59d9c346424..197e7d9869d 100644
--- a/lisp/progmodes/eglot.el
+++ b/lisp/progmodes/eglot.el
@@ -3353,7 +3353,6 @@ eglot-completion-at-point
                          ;; "foo.b", the LSP edit applies to that
                          ;; state, _not_ the current "foo.bar".
                          (delete-region orig-pos (point))
-                        (insert (substring bounds-string (- orig-pos 
(car bounds))))
                          (eglot--dbind ((TextEdit) range newText) textEdit
                            (pcase-let ((`(,beg . ,end)
                                         (eglot-range-region range)))

It fixes the main scenario with both UIs - but when the suffix is not 
matching, exit-function can delete too much text.

E.g. v.count|123.123456789 turns into v.count_ones()3456789

That's the example from the recently added test.

> What's currently working shall continue
> working.  I would advise generally to be conservative here: the bugs
> you're fixing seem to be somewhat academic edge cases and not reports by
> actual Eglot users.

I agree that this report is not very critical (and so can wait), but I 
don't think I'll be the only person to trigger it. Just hopefully it 
won't happen too often.

> The only thing I'd like to add is the following two notes:
> 
> * before any of this, you showed earlier a way to completely forbid
>    partial completions in Eglot.  That's a good change for reasons we've
>    already discussed and it prevents a number of bugs.  I'd like that
>    change to be commited first (presuming it does what you expect it to).

Said reasons were also more of "academic" nature, right?

That change would be removing a certain bit of functionality from the 
completion UIs, so I'd rather only do that in the face of hard evidence.

> * the rust-analyzer test you added recently -- and which you said was
>    very brittle -- is indeed very brittle: I cannot get it to pass.  We
>    should fix it, or just delete it and do those rust-analyzer tests
>    manually each time we touch this area.

Could you give more details? It is indeed more brittle in theory, but on 
my machine it's passing every time.

No failures from our CIs have been reported either, although that might 
not be saying much.





^ permalink raw reply related	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-01 14:28             ` Dmitry Gutov
@ 2024-09-03 13:20               ` Dmitry Gutov
  2024-09-03 13:43                 ` João Távora
  0 siblings, 1 reply; 18+ messages in thread
From: Dmitry Gutov @ 2024-09-03 13:20 UTC (permalink / raw)
  To: João Távora; +Cc: Eli Zaretskii, 72765

On 01/09/2024 17:28, Dmitry Gutov wrote:
>> * the rust-analyzer test you added recently -- and which you said was
>>    very brittle -- is indeed very brittle: I cannot get it to pass.  We
>>    should fix it, or just delete it and do those rust-analyzer tests
>>    manually each time we touch this area.
> 
> Could you give more details? It is indeed more brittle in theory, but on 
> my machine it's passing every time.

Yeah, I see it now - it succeeds in an interactive session and fails in 
batch mode. Not sure it was the same when the patch was committed 
(hopefully not).

Might be due to window configuration being different...





^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-03 13:20               ` Dmitry Gutov
@ 2024-09-03 13:43                 ` João Távora
  2024-09-08  2:41                   ` Dmitry Gutov
  0 siblings, 1 reply; 18+ messages in thread
From: João Távora @ 2024-09-03 13:43 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: Eli Zaretskii, 72765

On Tue, Sep 3, 2024 at 2:20 PM Dmitry Gutov <dmitry@gutov.dev> wrote:
>
> On 01/09/2024 17:28, Dmitry Gutov wrote:
> >> * the rust-analyzer test you added recently -- and which you said was
> >>    very brittle -- is indeed very brittle: I cannot get it to pass.  We
> >>    should fix it, or just delete it and do those rust-analyzer tests
> >>    manually each time we touch this area.
> >
> > Could you give more details? It is indeed more brittle in theory, but on
> > my machine it's passing every time.
>
> Yeah, I see it now - it succeeds in an interactive session and fails in
> batch mode. Not sure it was the same when the patch was committed
> (hopefully not).
>
> Might be due to window configuration being different...

Yes, I was trying batch mode.  make -C test eglot-tests  or something
similar.  Please fix it or delete it (or disable it).





^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-03 13:43                 ` João Távora
@ 2024-09-08  2:41                   ` Dmitry Gutov
  2024-09-08 15:51                     ` João Távora
  0 siblings, 1 reply; 18+ messages in thread
From: Dmitry Gutov @ 2024-09-08  2:41 UTC (permalink / raw)
  To: João Távora; +Cc: Eli Zaretskii, 72765

On 03/09/2024 16:43, João Távora wrote:
> On Tue, Sep 3, 2024 at 2:20 PM Dmitry Gutov<dmitry@gutov.dev>  wrote:
>> On 01/09/2024 17:28, Dmitry Gutov wrote:
>>>> * the rust-analyzer test you added recently -- and which you said was
>>>>     very brittle -- is indeed very brittle: I cannot get it to pass.  We
>>>>     should fix it, or just delete it and do those rust-analyzer tests
>>>>     manually each time we touch this area.
>>> Could you give more details? It is indeed more brittle in theory, but on
>>> my machine it's passing every time.
>> Yeah, I see it now - it succeeds in an interactive session and fails in
>> batch mode. Not sure it was the same when the patch was committed
>> (hopefully not).
>>
>> Might be due to window configuration being different...
> Yes, I was trying batch mode.  make -C test eglot-tests  or something
> similar.  Please fix it or delete it (or disable it).

Looking at minibuffer-tests.el, the above might be a solution, but it 
gets me a core dump instead:

diff --git a/test/lisp/progmodes/eglot-tests.el 
b/test/lisp/progmodes/eglot-tests.el
index e0168baee54..fa3b63b38dc 100644
--- a/test/lisp/progmodes/eglot-tests.el
+++ b/test/lisp/progmodes/eglot-tests.el
@@ -711,7 +711,8 @@ eglot-test-rust-completion-exit-function
        (search-forward "v.count_on")
        (let ((minibuffer-message-timeout 0)
              ;; Fail at (ding) if completion fails.
-            (executing-kbd-macro t))
+            (executing-kbd-macro t)
+            (redisplay-skip-initial-frame nil))
          (when (buffer-live-p "*Completions*")
            (kill-buffer "*Completions*"))
          ;; The design is pretty brittle, we'll need to monitor the


Will follow up later if nobody beats me to it (can others reproduce the 
crash?)





^ permalink raw reply related	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-08  2:41                   ` Dmitry Gutov
@ 2024-09-08 15:51                     ` João Távora
  2024-09-09  0:20                       ` Dmitry Gutov
  2024-09-10  1:40                       ` Dmitry Gutov
  0 siblings, 2 replies; 18+ messages in thread
From: João Távora @ 2024-09-08 15:51 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: Eli Zaretskii, 72765

[-- Attachment #1: Type: text/plain, Size: 2852 bytes --]

On Sun, Sep 8, 2024 at 3:41 AM Dmitry Gutov <dmitry@gutov.dev> wrote:
>
> On 03/09/2024 16:43, João Távora wrote:
> > On Tue, Sep 3, 2024 at 2:20 PM Dmitry Gutov<dmitry@gutov.dev>  wrote:
> >> On 01/09/2024 17:28, Dmitry Gutov wrote:
> >>>> * the rust-analyzer test you added recently -- and which you said was
> >>>>     very brittle -- is indeed very brittle: I cannot get it to pass.  We
> >>>>     should fix it, or just delete it and do those rust-analyzer tests
> >>>>     manually each time we touch this area.
> >>> Could you give more details? It is indeed more brittle in theory, but on
> >>> my machine it's passing every time.
> >> Yeah, I see it now - it succeeds in an interactive session and fails in
> >> batch mode. Not sure it was the same when the patch was committed
> >> (hopefully not).
> >>
> >> Might be due to window configuration being different...
> > Yes, I was trying batch mode.  make -C test eglot-tests  or something
> > similar.  Please fix it or delete it (or disable it).
>
> Looking at minibuffer-tests.el, the above might be a solution, but it
> gets me a core dump instead:
>
> diff --git a/test/lisp/progmodes/eglot-tests.el
> b/test/lisp/progmodes/eglot-tests.el
> index e0168baee54..fa3b63b38dc 100644
> --- a/test/lisp/progmodes/eglot-tests.el
> +++ b/test/lisp/progmodes/eglot-tests.el
> @@ -711,7 +711,8 @@ eglot-test-rust-completion-exit-function
>         (search-forward "v.count_on")
>         (let ((minibuffer-message-timeout 0)
>               ;; Fail at (ding) if completion fails.
> -            (executing-kbd-macro t))
> +            (executing-kbd-macro t)
> +            (redisplay-skip-initial-frame nil))
>           (when (buffer-live-p "*Completions*")
>             (kill-buffer "*Completions*"))
>           ;; The design is pretty brittle, we'll need to monitor the
>
>
> Will follow up later if nobody beats me to it (can others reproduce the
> crash?)

This now aborts (segfault?).  At least something different.

So, for the record, before this patch with the latest emacs-30, I get the
results in failure1.txt and with your last redisplay-skip-initial-frame patch
I get failure2.txt.

I've produced these files with

make -C test eglot-tests SELECTOR=\"rust-completion\" 2>&1 | tee failure1.txt
make -C test eglot-tests SELECTOR=\"rust-completion\" 2>&1 | tee failure2.txt

$ rust-analyzer --version
rust-analyzer 1 (0f7f68dad2 2024-08-27)

$ src/emacs --version
GNU Emacs 30.0.90
Development version 89c99891b2b3 on emacs-30 branch; build date 2024-09-08.
Copyright (C) 2024 Free Software Foundation, Inc.
GNU Emacs comes with ABSOLUTELY NO WARRANTY.
You may redistribute copies of GNU Emacs
under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING.

[-- Attachment #2: failure1.txt --]
[-- Type: text/plain, Size: 61310 bytes --]

make: Entering directory '/home/capitaomorte/Source/Emacs/emacs-30/test'
make[1]: Entering directory '/home/capitaomorte/Source/Emacs/emacs-30/test'
  GEN      lisp/progmodes/eglot-tests.log
Running 1 tests (2024-09-08 16:46:42+0100, selector ‘"rust-completion"’)
[eglot-tests] [eglot-test-rust-completion-exit-function]: test start
    Creating binary (application) package
note: see more `Cargo.toml` keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[eglot] Connected! Server `rust-analyzer' now managing `(rust-mode rust-ts-mode)' buffers in project `cmpl-project'.
[eglot] Connected! Server `rust-analyzer' now managing `(rust-mode rust-ts-mode)' buffers in project `cmpl-project'.
[eglot-tests] waiting for `(and (string= method $/progress) rustAnalyzer/Indexing (equal params '(:token rustAnalyzer/Indexing :value (:kind begin :title Indexing :cancellable :json-false :percentage 0))))'
....
[eglot-tests] detected: $/progress
No match

[eglot-tests] [eglot-test-rust-completion-exit-function]: FAILED
[eglot] Asking EGLOT (cmpl-project/(rust-mode rust-ts-mode)) politely to terminate
[jsonrpc] (warning) Sentinel for EGLOT (cmpl-project/(rust-mode rust-ts-mode))<1> still hasn't run, deleting it!
Warning (jsonrpc): Sentinel for EGLOT (cmpl-project/(rust-mode rust-ts-mode))<1> still hasn't run, deleting it!
[jsonrpc] Server exited with status 9
[eglot-tests] Non-critical cleanup error: (cl-assertion-failed (memq id track-changes--trackers))
[eglot-tests] contents of ` *EGLOT (cmpl-project/(rust-mode rust-ts-mode)) output*':
[eglot-tests] contents of ` *EGLOT (cmpl-project/(rust-mode rust-ts-mode)) stderr*':

Process EGLOT (cmpl-project/(rust-mode rust-ts-mode)) stderr<1> finished
[eglot-tests] contents of `*EGLOT (cmpl-project/(rust-mode rust-ts-mode)) events*':
[jsonrpc] D[16:46:42.609] Running language server: rust-analyzer
[jsonrpc] e[16:46:42.610] --> initialize[1] {"jsonrpc":"2.0","id":1,"method":"initialize","params":{"processId":52775,"clientInfo":{"name":"Eglot","version":"1.17.30"},"rootPath":"/tmp/eglot--fixture-XCmCqo/cmpl-project/","rootUri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project","initializationOptions":{},"capabilities":{"workspace":{"applyEdit":true,"executeCommand":{"dynamicRegistration":false},"workspaceEdit":{"documentChanges":true},"didChangeWatchedFiles":{"dynamicRegistration":true},"symbol":{"dynamicRegistration":false},"configuration":true,"workspaceFolders":true},"textDocument":{"synchronization":{"dynamicRegistration":false,"willSave":true,"willSaveWaitUntil":true,"didSave":true},"completion":{"dynamicRegistration":false,"completionItem":{"snippetSupport":false,"deprecatedSupport":true,"resolveSupport":{"properties":["documentation","details","additionalTextEdits"]},"tagSupport":{"valueSet":[1]}},"contextSupport":true},"hover":{"dynamicRegistration":false,"contentFormat":["plaintext"]},"signatureHelp":{"dynamicRegistration":false,"signatureInformation":{"parameterInformation":{"labelOffsetSupport":true},"documentationFormat":["plaintext"],"activeParameterSupport":true}},"references":{"dynamicRegistration":false},"definition":{"dynamicRegistration":false,"linkSupport":true},"declaration":{"dynamicRegistration":false,"linkSupport":true},"implementation":{"dynamicRegistration":false,"linkSupport":true},"typeDefinition":{"dynamicRegistration":false,"linkSupport":true},"documentSymbol":{"dynamicRegistration":false,"hierarchicalDocumentSymbolSupport":true,"symbolKind":{"valueSet":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26]}},"documentHighlight":{"dynamicRegistration":false},"codeAction":{"dynamicRegistration":false,"resolveSupport":{"properties":["edit","command"]},"dataSupport":true,"codeActionLiteralSupport":{"codeActionKind":{"valueSet":["quickfix","refactor","refactor.extract","refactor.inline","refactor.rewrite","source","source.organizeImports"]}},"isPreferredSupport":true},"formatting":{"dynamicRegistration":false},"rangeFormatting":{"dynamicRegistration":false},"rename":{"dynamicRegistration":false},"inlayHint":{"dynamicRegistration":false},"publishDiagnostics":{"relatedInformation":false,"codeDescriptionSupport":false,"tagSupport":{"valueSet":[1,2]}}},"window":{"showDocument":{"support":true},"workDoneProgress":true},"general":{"positionEncodings":["utf-32","utf-8","utf-16"]},"experimental":{}},"workspaceFolders":[{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project","name":"/tmp/eglot--fixture-XCmCqo/cmpl-project/"}]}}
[jsonrpc] e[16:46:42.611] <-- initialize[1] {"jsonrpc":"2.0","id":1,"result":{"capabilities":{"positionEncoding":"utf-32","textDocumentSync":{"openClose":true,"change":2,"save":{}},"selectionRangeProvider":true,"hoverProvider":true,"completionProvider":{"resolveProvider":true,"triggerCharacters":[":",".","'","("],"completionItem":{"labelDetailsSupport":false}},"signatureHelpProvider":{"triggerCharacters":["(",",","<"]},"definitionProvider":true,"typeDefinitionProvider":true,"implementationProvider":true,"referencesProvider":true,"documentHighlightProvider":true,"documentSymbolProvider":true,"workspaceSymbolProvider":true,"codeActionProvider":{"codeActionKinds":["","quickfix","refactor","refactor.extract","refactor.inline","refactor.rewrite"],"resolveProvider":true},"codeLensProvider":{"resolveProvider":true},"documentFormattingProvider":true,"documentRangeFormattingProvider":false,"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"=","moreTriggerCharacter":[".",">","{","("]},"renameProvider":{"prepareProvider":true},"foldingRangeProvider":true,"declarationProvider":true,"workspace":{"workspaceFolders":{"supported":true,"changeNotifications":true},"fileOperations":{"willRename":{"filters":[{"scheme":"file","pattern":{"glob":"**/*.rs","matches":"file"}},{"scheme":"file","pattern":{"glob":"**","matches":"folder"}}]}}},"callHierarchyProvider":true,"semanticTokensProvider":{"legend":{"tokenTypes":["comment","decorator","enumMember","enum","function","interface","keyword","macro","method","namespace","number","operator","parameter","property","string","struct","typeParameter","variable","angle","arithmetic","attributeBracket","attribute","bitwise","boolean","brace","bracket","builtinAttribute","builtinType","character","colon","comma","comparison","constParameter","const","deriveHelper","derive","dot","escapeSequence","formatSpecifier","generic","invalidEscapeSequence","label","lifetime","logical","macroBang","parenthesis","procMacro","punctuation","selfKeyword","selfTypeKeyword","semicolon","static","toolModule","typeAlias","union","unresolvedReference"],"tokenModifiers":["async","documentation","declaration","static","defaultLibrary","associated","attribute","callable","constant","consuming","controlFlow","crateRoot","injected","intraDocLink","library","macro","mutable","procMacro","public","reference","trait","unsafe"]},"range":true,"full":{"delta":true}},"inlayHintProvider":{"resolveProvider":true},"experimental":{"externalDocs":true,"hoverRange":true,"joinLines":true,"matchingBrace":true,"moveItem":true,"onEnter":true,"openCargoToml":true,"parentModule":true,"runnables":{"kinds":["cargo"]},"ssr":true,"workspaceSymbolScopeKindFiltering":true}},"serverInfo":{"name":"rust-analyzer","version":"1 (0f7f68dad2 2024-08-27)"}}}
[jsonrpc] e[16:46:42.612] --> initialized {"jsonrpc":"2.0","method":"initialized","params":{}}
[jsonrpc] e[16:46:42.612] --> textDocument/didOpen {"jsonrpc":"2.0","method":"textDocument/didOpen","params":{"textDocument":{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project/main.rs","version":0,"languageId":"rust","text":"fn test() -> i32 { let v: usize = 1; v.count_on1234.1234567890;"}}}
[jsonrpc] e[16:46:42.612] --> workspace/didChangeConfiguration {"jsonrpc":"2.0","method":"workspace/didChangeConfiguration","params":{"settings":{}}}
[stderr]  
[stderr]  
[stderr]  nil
[stderr]  nil
[stderr]  Process EGLOT (cmpl-project/(rust-mode rust-ts-mode)) stderr finished
[jsonrpc] D[16:46:42.615] Running language server: rust-analyzer
[jsonrpc] e[16:46:42.615] --> initialize[1] {"jsonrpc":"2.0","id":1,"method":"initialize","params":{"processId":52775,"clientInfo":{"name":"Eglot","version":"1.17.30"},"rootPath":"/tmp/eglot--fixture-XCmCqo/cmpl-project/","rootUri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project","initializationOptions":{},"capabilities":{"workspace":{"applyEdit":true,"executeCommand":{"dynamicRegistration":false},"workspaceEdit":{"documentChanges":true},"didChangeWatchedFiles":{"dynamicRegistration":true},"symbol":{"dynamicRegistration":false},"configuration":true,"workspaceFolders":true},"textDocument":{"synchronization":{"dynamicRegistration":false,"willSave":true,"willSaveWaitUntil":true,"didSave":true},"completion":{"dynamicRegistration":false,"completionItem":{"snippetSupport":false,"deprecatedSupport":true,"resolveSupport":{"properties":["documentation","details","additionalTextEdits"]},"tagSupport":{"valueSet":[1]}},"contextSupport":true},"hover":{"dynamicRegistration":false,"contentFormat":["plaintext"]},"signatureHelp":{"dynamicRegistration":false,"signatureInformation":{"parameterInformation":{"labelOffsetSupport":true},"documentationFormat":["plaintext"],"activeParameterSupport":true}},"references":{"dynamicRegistration":false},"definition":{"dynamicRegistration":false,"linkSupport":true},"declaration":{"dynamicRegistration":false,"linkSupport":true},"implementation":{"dynamicRegistration":false,"linkSupport":true},"typeDefinition":{"dynamicRegistration":false,"linkSupport":true},"documentSymbol":{"dynamicRegistration":false,"hierarchicalDocumentSymbolSupport":true,"symbolKind":{"valueSet":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26]}},"documentHighlight":{"dynamicRegistration":false},"codeAction":{"dynamicRegistration":false,"resolveSupport":{"properties":["edit","command"]},"dataSupport":true,"codeActionLiteralSupport":{"codeActionKind":{"valueSet":["quickfix","refactor","refactor.extract","refactor.inline","refactor.rewrite","source","source.organizeImports"]}},"isPreferredSupport":true},"formatting":{"dynamicRegistration":false},"rangeFormatting":{"dynamicRegistration":false},"rename":{"dynamicRegistration":false},"inlayHint":{"dynamicRegistration":false},"publishDiagnostics":{"relatedInformation":false,"codeDescriptionSupport":false,"tagSupport":{"valueSet":[1,2]}}},"window":{"showDocument":{"support":true},"workDoneProgress":true},"general":{"positionEncodings":["utf-32","utf-8","utf-16"]},"experimental":{}},"workspaceFolders":[{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project","name":"/tmp/eglot--fixture-XCmCqo/cmpl-project/"}]}}
[jsonrpc] e[16:46:42.615] <-- window/workDoneProgress/create[0] {"jsonrpc":"2.0","id":0,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Fetching"}}
[jsonrpc] e[16:46:42.615] --> window/workDoneProgress/create[0] {"jsonrpc":"2.0","id":0,"result":null}
[jsonrpc] e[16:46:42.615] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"begin","title":"Fetching","cancellable":false}}}
[jsonrpc] e[16:46:42.615] <-- workspace/configuration[1] {"jsonrpc":"2.0","id":1,"method":"workspace/configuration","params":{"items":[{"section":"rust-analyzer"}]}}
[jsonrpc] e[16:46:42.616] --> workspace/configuration[1] {"jsonrpc":"2.0","id":1,"result":[null]}
[jsonrpc] e[16:46:42.616] <-- initialize[1] {"jsonrpc":"2.0","id":1,"result":{"capabilities":{"positionEncoding":"utf-32","textDocumentSync":{"openClose":true,"change":2,"save":{}},"selectionRangeProvider":true,"hoverProvider":true,"completionProvider":{"resolveProvider":true,"triggerCharacters":[":",".","'","("],"completionItem":{"labelDetailsSupport":false}},"signatureHelpProvider":{"triggerCharacters":["(",",","<"]},"definitionProvider":true,"typeDefinitionProvider":true,"implementationProvider":true,"referencesProvider":true,"documentHighlightProvider":true,"documentSymbolProvider":true,"workspaceSymbolProvider":true,"codeActionProvider":{"codeActionKinds":["","quickfix","refactor","refactor.extract","refactor.inline","refactor.rewrite"],"resolveProvider":true},"codeLensProvider":{"resolveProvider":true},"documentFormattingProvider":true,"documentRangeFormattingProvider":false,"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"=","moreTriggerCharacter":[".",">","{","("]},"renameProvider":{"prepareProvider":true},"foldingRangeProvider":true,"declarationProvider":true,"workspace":{"workspaceFolders":{"supported":true,"changeNotifications":true},"fileOperations":{"willRename":{"filters":[{"scheme":"file","pattern":{"glob":"**/*.rs","matches":"file"}},{"scheme":"file","pattern":{"glob":"**","matches":"folder"}}]}}},"callHierarchyProvider":true,"semanticTokensProvider":{"legend":{"tokenTypes":["comment","decorator","enumMember","enum","function","interface","keyword","macro","method","namespace","number","operator","parameter","property","string","struct","typeParameter","variable","angle","arithmetic","attributeBracket","attribute","bitwise","boolean","brace","bracket","builtinAttribute","builtinType","character","colon","comma","comparison","constParameter","const","deriveHelper","derive","dot","escapeSequence","formatSpecifier","generic","invalidEscapeSequence","label","lifetime","logical","macroBang","parenthesis","procMacro","punctuation","selfKeyword","selfTypeKeyword","semicolon","static","toolModule","typeAlias","union","unresolvedReference"],"tokenModifiers":["async","documentation","declaration","static","defaultLibrary","associated","attribute","callable","constant","consuming","controlFlow","crateRoot","injected","intraDocLink","library","macro","mutable","procMacro","public","reference","trait","unsafe"]},"range":true,"full":{"delta":true}},"inlayHintProvider":{"resolveProvider":true},"experimental":{"externalDocs":true,"hoverRange":true,"joinLines":true,"matchingBrace":true,"moveItem":true,"onEnter":true,"openCargoToml":true,"parentModule":true,"runnables":{"kinds":["cargo"]},"ssr":true,"workspaceSymbolScopeKindFiltering":true}},"serverInfo":{"name":"rust-analyzer","version":"1 (0f7f68dad2 2024-08-27)"}}}
[jsonrpc] e[16:46:42.616] --> initialized {"jsonrpc":"2.0","method":"initialized","params":{}}
[jsonrpc] e[16:46:42.616] --> workspace/didChangeConfiguration {"jsonrpc":"2.0","method":"workspace/didChangeConfiguration","params":{"settings":{}}}
[jsonrpc] e[16:46:42.618] <-- workspace/configuration[0] {"jsonrpc":"2.0","id":0,"method":"workspace/configuration","params":{"items":[{"section":"rust-analyzer"}]}}
[jsonrpc] e[16:46:42.618] --> workspace/configuration[0] {"jsonrpc":"2.0","id":0,"result":[null]}
[jsonrpc] e[16:46:42.618] <-- window/workDoneProgress/create[1] {"jsonrpc":"2.0","id":1,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Fetching"}}
[jsonrpc] e[16:46:42.618] --> window/workDoneProgress/create[1] {"jsonrpc":"2.0","id":1,"result":null}
[jsonrpc] e[16:46:42.618] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"begin","title":"Fetching","cancellable":false}}}
[jsonrpc] e[16:46:42.854] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"report","cancellable":false,"message":"metadata"}}}
[jsonrpc] e[16:46:42.858] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"report","cancellable":false,"message":"metadata"}}}
[jsonrpc] e[16:46:42.981] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"end"}}}
[jsonrpc] e[16:46:42.981] <-- client/registerCapability[2] {"jsonrpc":"2.0","id":2,"method":"client/registerCapability","params":{"registrations":[{"id":"workspace/didChangeWatchedFiles","method":"workspace/didChangeWatchedFiles","registerOptions":{"watchers":[{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/**/*.rs"},{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/**/Cargo.{toml,lock}"},{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/**/rust-analyzer.toml"},{"globPattern":"/dev/null/rust-analyzer/rust-analyzer.toml"},{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/Cargo.toml"}]}}]}}
[jsonrpc] e[16:46:42.990] --> client/registerCapability[2] {"jsonrpc":"2.0","id":2,"result":null}
[jsonrpc] e[16:46:42.990] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"end"}}}
[jsonrpc] e[16:46:42.991] <-- client/registerCapability[2] {"jsonrpc":"2.0","id":2,"method":"client/registerCapability","params":{"registrations":[{"id":"workspace/didChangeWatchedFiles","method":"workspace/didChangeWatchedFiles","registerOptions":{"watchers":[{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/**/*.rs"},{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/**/Cargo.{toml,lock}"},{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/**/rust-analyzer.toml"},{"globPattern":"/dev/null/rust-analyzer/rust-analyzer.toml"},{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/Cargo.toml"}]}}]}}
[jsonrpc] e[16:46:42.997] --> client/registerCapability[2] {"jsonrpc":"2.0","id":2,"result":null}
[jsonrpc] e[16:46:43.008] <-- window/workDoneProgress/create[3] {"jsonrpc":"2.0","id":3,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Building CrateGraph"}}
[jsonrpc] e[16:46:43.010] --> window/workDoneProgress/create[3] {"jsonrpc":"2.0","id":3,"result":null}
[jsonrpc] e[16:46:43.010] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building CrateGraph","value":{"kind":"begin","title":"Building CrateGraph","cancellable":false}}}
[jsonrpc] e[16:46:43.010] <-- window/workDoneProgress/create[3] {"jsonrpc":"2.0","id":3,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Building CrateGraph"}}
[jsonrpc] e[16:46:43.010] --> window/workDoneProgress/create[3] {"jsonrpc":"2.0","id":3,"result":null}
[jsonrpc] e[16:46:43.010] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building CrateGraph","value":{"kind":"begin","title":"Building CrateGraph","cancellable":false}}}
[jsonrpc] e[16:46:43.010] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building CrateGraph","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.010] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building CrateGraph","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.011] <-- window/workDoneProgress/create[4] {"jsonrpc":"2.0","id":4,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Roots Scanned"}}
[jsonrpc] e[16:46:43.011] --> window/workDoneProgress/create[4] {"jsonrpc":"2.0","id":4,"result":null}
[jsonrpc] e[16:46:43.011] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"begin","title":"Roots Scanned","cancellable":false,"message":"0/3","percentage":0}}}
[jsonrpc] e[16:46:43.013] <-- window/workDoneProgress/create[4] {"jsonrpc":"2.0","id":4,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Roots Scanned"}}
[jsonrpc] e[16:46:43.013] --> window/workDoneProgress/create[4] {"jsonrpc":"2.0","id":4,"result":null}
[jsonrpc] e[16:46:43.013] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"begin","title":"Roots Scanned","cancellable":false,"message":"0/3","percentage":0}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"0/3: ","percentage":0}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"0/3: ","percentage":0}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3","percentage":33}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3: /usr/lib/rustlib/src/rust/library","percentage":33}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3: /usr/lib/rustlib/src/rust/library","percentage":33}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3: /usr/lib/rustlib/src/rust/library/backtrace","percentage":33}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3: /usr/lib/rustlib/src/rust/library/rustc-std-workspace-core","percentage":33}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3: /usr/lib/rustlib/src/rust/library/portable-simd","percentage":33}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3","percentage":66}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/proc_macro","percentage":66}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/alloc","percentage":66}}}
[jsonrpc] e[16:46:43.014] <-- window/workDoneProgress/create[5] {"jsonrpc":"2.0","id":5,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Building build-artifacts"}}
[jsonrpc] e[16:46:43.014] --> window/workDoneProgress/create[5] {"jsonrpc":"2.0","id":5,"result":null}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"0/3: ","percentage":0}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"0/3: ","percentage":0}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3","percentage":33}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3: /usr/lib/rustlib/src/rust/library","percentage":33}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3: /usr/lib/rustlib/src/rust/library","percentage":33}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3: /usr/lib/rustlib/src/rust/library/backtrace","percentage":33}}}
[jsonrpc] e[16:46:43.014] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3","percentage":66}}}
[jsonrpc] e[16:46:43.014] <-- window/workDoneProgress/create[5] {"jsonrpc":"2.0","id":5,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Fetching"}}
[jsonrpc] e[16:46:43.015] --> window/workDoneProgress/create[5] {"jsonrpc":"2.0","id":5,"result":null}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"begin","title":"Fetching","cancellable":false}}}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rustc-std-workspace-core","percentage":66}}}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/portable-simd","percentage":66}}}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building build-artifacts","value":{"kind":"begin","title":"Building build-artifacts","cancellable":false}}}
[jsonrpc] e[16:46:43.015] <-- window/workDoneProgress/create[6] {"jsonrpc":"2.0","id":6,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Loading proc-macros"}}
[jsonrpc] e[16:46:43.015] --> window/workDoneProgress/create[6] {"jsonrpc":"2.0","id":6,"result":null}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Loading proc-macros","value":{"kind":"begin","title":"Loading proc-macros","cancellable":false}}}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Loading proc-macros","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/sysroot","percentage":66}}}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rustc-std-workspace-std","percentage":66}}}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/panic_unwind","percentage":66}}}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/std","percentage":66}}}
[jsonrpc] e[16:46:43.015] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/proc_macro","percentage":66}}}
[jsonrpc] e[16:46:43.024] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/profiler_builtins","percentage":66}}}
[jsonrpc] e[16:46:43.025] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/alloc","percentage":66}}}
[jsonrpc] e[16:46:43.025] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/sysroot","percentage":66}}}
[jsonrpc] e[16:46:43.025] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rustc-std-workspace-std","percentage":66}}}
[jsonrpc] e[16:46:43.025] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/panic_unwind","percentage":66}}}
[jsonrpc] e[16:46:43.025] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/std","percentage":66}}}
[jsonrpc] e[16:46:43.025] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/test","percentage":66}}}
[jsonrpc] e[16:46:43.030] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/profiler_builtins","percentage":66}}}
[jsonrpc] e[16:46:43.030] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/test","percentage":66}}}
[jsonrpc] e[16:46:43.030] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/unwind","percentage":66}}}
[jsonrpc] e[16:46:43.030] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/core","percentage":66}}}
[jsonrpc] e[16:46:43.030] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/unwind","percentage":66}}}
[jsonrpc] e[16:46:43.030] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/core","percentage":66}}}
[jsonrpc] e[16:46:43.035] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/panic_abort","percentage":66}}}
[jsonrpc] e[16:46:43.035] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/stdarch","percentage":66}}}
[jsonrpc] e[16:46:43.036] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/panic_abort","percentage":66}}}
[jsonrpc] e[16:46:43.036] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/stdarch","percentage":66}}}
[jsonrpc] e[16:46:43.045] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rtstartup","percentage":66}}}
[jsonrpc] e[16:46:43.045] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rustc-std-workspace-alloc","percentage":66}}}
[jsonrpc] e[16:46:43.045] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rtstartup","percentage":66}}}
[jsonrpc] e[16:46:43.045] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rustc-std-workspace-alloc","percentage":66}}}
[jsonrpc] e[16:46:43.058] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"3/3","percentage":100}}}
[jsonrpc] e[16:46:43.108] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"end","message":"3/3"}}}
[jsonrpc] e[16:46:43.112] <-- window/workDoneProgress/create[7] {"jsonrpc":"2.0","id":7,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Fetching"}}
[jsonrpc] e[16:46:43.112] --> window/workDoneProgress/create[7] {"jsonrpc":"2.0","id":7,"result":null}
[jsonrpc] e[16:46:43.112] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"begin","title":"Fetching","cancellable":false}}}
[jsonrpc] e[16:46:43.116] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building build-artifacts","value":{"kind":"report","cancellable":false,"message":"building proc-macros: cmpl-project"}}}
[jsonrpc] e[16:46:43.137] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building build-artifacts","value":{"kind":"report","cancellable":false,"message":"building proc-macros: cmpl-project"}}}
[jsonrpc] e[16:46:43.137] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building build-artifacts","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.137] <-- client/registerCapability[8] {"jsonrpc":"2.0","id":8,"method":"client/registerCapability","params":{"registrations":[{"id":"workspace/didChangeWatchedFiles","method":"workspace/didChangeWatchedFiles","registerOptions":{"watchers":[{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/**/*.rs"},{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/**/Cargo.{toml,lock}"},{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/**/rust-analyzer.toml"},{"globPattern":"/dev/null/rust-analyzer/rust-analyzer.toml"},{"globPattern":"/tmp/eglot--fixture-XCmCqo/cmpl-project/Cargo.toml"}]}}]}}
[jsonrpc] e[16:46:43.142] --> client/registerCapability[8] {"jsonrpc":"2.0","id":8,"result":null}
[jsonrpc] e[16:46:43.142] <-- window/workDoneProgress/create[9] {"jsonrpc":"2.0","id":9,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Building CrateGraph"}}
[jsonrpc] e[16:46:43.142] --> window/workDoneProgress/create[9] {"jsonrpc":"2.0","id":9,"result":null}
[jsonrpc] e[16:46:43.142] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building CrateGraph","value":{"kind":"begin","title":"Building CrateGraph","cancellable":false}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building CrateGraph","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.143] <-- window/workDoneProgress/create[10] {"jsonrpc":"2.0","id":10,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Roots Scanned"}}
[jsonrpc] e[16:46:43.143] --> window/workDoneProgress/create[10] {"jsonrpc":"2.0","id":10,"result":null}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"begin","title":"Roots Scanned","cancellable":false,"message":"0/3","percentage":0}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"0/3: ","percentage":0}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"0/3: /usr/lib/rustlib/src/rust/library","percentage":0}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"0/3: ","percentage":0}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"0/3: /usr/lib/rustlib/src/rust/library","percentage":0}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"0/3: /usr/lib/rustlib/src/rust/library/backtrace","percentage":0}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"1/3","percentage":33}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rustc-std-workspace-core","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/portable-simd","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/proc_macro","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/alloc","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/sysroot","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rustc-std-workspace-std","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/panic_unwind","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/std","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/profiler_builtins","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/test","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/unwind","percentage":66}}}
[jsonrpc] e[16:46:43.143] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/core","percentage":66}}}
[jsonrpc] e[16:46:43.145] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/panic_abort","percentage":66}}}
[jsonrpc] e[16:46:43.146] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/stdarch","percentage":66}}}
[jsonrpc] e[16:46:43.154] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rtstartup","percentage":66}}}
[jsonrpc] e[16:46:43.154] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"2/3: /usr/lib/rustlib/src/rust/library/rustc-std-workspace-alloc","percentage":66}}}
[jsonrpc] e[16:46:43.156] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"report","cancellable":false,"message":"3/3","percentage":100}}}
[jsonrpc] e[16:46:43.156] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Roots Scanned","value":{"kind":"end","message":"3/3"}}}
[jsonrpc] e[16:46:43.206] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"report","cancellable":false,"message":"metadata"}}}
[jsonrpc] e[16:46:43.248] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"report","cancellable":false,"message":"metadata"}}}
[jsonrpc] e[16:46:43.281] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.287] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.287] <-- window/workDoneProgress/create[11] {"jsonrpc":"2.0","id":11,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Building CrateGraph"}}
[jsonrpc] e[16:46:43.287] --> window/workDoneProgress/create[11] {"jsonrpc":"2.0","id":11,"result":null}
[jsonrpc] e[16:46:43.287] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building CrateGraph","value":{"kind":"begin","title":"Building CrateGraph","cancellable":false}}}
[jsonrpc] e[16:46:43.287] <-- window/workDoneProgress/create[6] {"jsonrpc":"2.0","id":6,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Fetching"}}
[jsonrpc] e[16:46:43.287] --> window/workDoneProgress/create[6] {"jsonrpc":"2.0","id":6,"result":null}
[jsonrpc] e[16:46:43.287] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"begin","title":"Fetching","cancellable":false}}}
[jsonrpc] e[16:46:43.288] <-- window/workDoneProgress/create[7] {"jsonrpc":"2.0","id":7,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Indexing"}}
[jsonrpc] e[16:46:43.288] --> window/workDoneProgress/create[7] {"jsonrpc":"2.0","id":7,"result":null}
[jsonrpc] e[16:46:43.288] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"begin","title":"Indexing","cancellable":false,"percentage":0}}}
[jsonrpc] e[16:46:43.288] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"percentage":100}}}
[jsonrpc] e[16:46:43.288] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.288] <-- textDocument/publishDiagnostics {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project/main.rs","diagnostics":[{"range":{"start":{"line":0,"character":63},"end":{"line":0,"character":63}},"severity":1,"code":"syntax-error","codeDescription":{"href":"https://doc.rust-lang.org/stable/reference/"},"source":"rust-analyzer","message":"Syntax Error: expected R_CURLY"},{"range":{"start":{"line":0,"character":17},"end":{"line":0,"character":63}},"severity":1,"code":"E0308","codeDescription":{"href":"https://doc.rust-lang.org/stable/error_codes/E0308.html"},"source":"rust-analyzer","message":"expected i32, found ()"}],"version":0}}
[jsonrpc] e[16:46:43.288] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building CrateGraph","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.288] <-- window/workDoneProgress/create[12] {"jsonrpc":"2.0","id":12,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Loading proc-macros"}}
[jsonrpc] e[16:46:43.288] --> window/workDoneProgress/create[12] {"jsonrpc":"2.0","id":12,"result":null}
[jsonrpc] e[16:46:43.288] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Loading proc-macros","value":{"kind":"begin","title":"Loading proc-macros","cancellable":false}}}
[jsonrpc] e[16:46:43.288] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Loading proc-macros","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.288] <-- window/workDoneProgress/create[13] {"jsonrpc":"2.0","id":13,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Indexing"}}
[jsonrpc] e[16:46:43.288] --> window/workDoneProgress/create[13] {"jsonrpc":"2.0","id":13,"result":null}
[jsonrpc] e[16:46:43.288] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"begin","title":"Indexing","cancellable":false,"percentage":0}}}
[jsonrpc] e[16:46:43.288] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.288] <-- window/workDoneProgress/create[14] {"jsonrpc":"2.0","id":14,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Indexing"}}
[jsonrpc] e[16:46:43.288] --> window/workDoneProgress/create[14] {"jsonrpc":"2.0","id":14,"result":null}
[jsonrpc] e[16:46:43.289] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"begin","title":"Indexing","cancellable":false,"percentage":0}}}
[jsonrpc] e[16:46:43.293] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"2/12 (core + 3 more)","percentage":16}}}
[jsonrpc] e[16:46:43.317] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"3/12 (core + 2 more)","percentage":25}}}
[jsonrpc] e[16:46:43.317] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"3/12 (core + 3 more)","percentage":25}}}
[jsonrpc] e[16:46:43.317] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"4/12 (core + 2 more)","percentage":33}}}
[jsonrpc] e[16:46:43.317] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"4/12 (core + 3 more)","percentage":33}}}
[jsonrpc] e[16:46:43.317] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"5/12 (core + 2 more)","percentage":41}}}
[jsonrpc] e[16:46:43.336] <-- window/workDoneProgress/create[8] {"jsonrpc":"2.0","id":8,"method":"window/workDoneProgress/create","params":{"token":"rust-analyzer/flycheck/0"}}
[jsonrpc] e[16:46:43.336] --> window/workDoneProgress/create[8] {"jsonrpc":"2.0","id":8,"result":null}
[jsonrpc] e[16:46:43.342] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rust-analyzer/flycheck/0","value":{"kind":"begin","title":"cargo check","cancellable":true}}}
[jsonrpc] e[16:46:43.375] --> textDocument/completion[2] {"jsonrpc":"2.0","id":2,"method":"textDocument/completion","params":{"textDocument":{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project/main.rs"},"position":{"line":0,"character":47},"context":{"triggerKind":1}}}
[jsonrpc] e[16:46:43.378]   <-- textDocument/completion[2] {"jsonrpc":"2.0","id":2,"result":{"isIncomplete":true,"items":[]}}
[jsonrpc] e[16:46:43.398] <-- textDocument/publishDiagnostics {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project/main.rs","diagnostics":[{"range":{"start":{"line":0,"character":63},"end":{"line":0,"character":63}},"severity":1,"code":"syntax-error","codeDescription":{"href":"https://doc.rust-lang.org/stable/reference/"},"source":"rust-analyzer","message":"Syntax Error: expected R_CURLY"},{"range":{"start":{"line":0,"character":17},"end":{"line":0,"character":63}},"severity":1,"code":"E0308","codeDescription":{"href":"https://doc.rust-lang.org/stable/error_codes/E0308.html"},"source":"rust-analyzer","message":"expected i32, found ()"},{"range":{"start":{"line":0,"character":63},"end":{"line":0,"character":63}},"severity":1,"source":"rustc","message":"this file contains an unclosed delimiter","relatedInformation":[{"location":{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project/main.rs","range":{"start":{"line":0,"character":17},"end":{"line":0,"character":18}}},"message":"unclosed delimiter"}],"data":{"rendered":"error: this file contains an unclosed delimiter\n --> main.rs:1:64\n  |\n1 | fn test() -> i32 { let v: usize = 1; v.count_on1234.1234567890;\n  |                  - unclosed delimiter                          ^\n\n"}},{"range":{"start":{"line":0,"character":17},"end":{"line":0,"character":18}},"severity":4,"source":"rustc","message":"unclosed delimiter","relatedInformation":[{"location":{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project/main.rs","range":{"start":{"line":0,"character":63},"end":{"line":0,"character":63}}},"message":"original diagnostic"}]}],"version":0}}
[jsonrpc] e[16:46:43.399] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rust-analyzer/flycheck/0","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.412] <-- textDocument/publishDiagnostics {"jsonrpc":"2.0","method":"textDocument/publishDiagnostics","params":{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project/main.rs","diagnostics":[{"range":{"start":{"line":0,"character":63},"end":{"line":0,"character":63}},"severity":1,"source":"rustc","message":"this file contains an unclosed delimiter","relatedInformation":[{"location":{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project/main.rs","range":{"start":{"line":0,"character":17},"end":{"line":0,"character":18}}},"message":"unclosed delimiter"}],"data":{"rendered":"error: this file contains an unclosed delimiter\n --> main.rs:1:64\n  |\n1 | fn test() -> i32 { let v: usize = 1; v.count_on1234.1234567890;\n  |                  - unclosed delimiter                          ^\n\n"}},{"range":{"start":{"line":0,"character":17},"end":{"line":0,"character":18}},"severity":4,"source":"rustc","message":"unclosed delimiter","relatedInformation":[{"location":{"uri":"file:///tmp/eglot--fixture-XCmCqo/cmpl-project/main.rs","range":{"start":{"line":0,"character":63},"end":{"line":0,"character":63}}},"message":"original diagnostic"}]}]}}
[jsonrpc] e[16:46:43.436] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"report","cancellable":false,"message":"metadata"}}}
[jsonrpc] e[16:46:43.441] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rust-analyzer/flycheck/0","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.471] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Fetching","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.471] <-- window/workDoneProgress/create[9] {"jsonrpc":"2.0","id":9,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Building CrateGraph"}}
[jsonrpc] e[16:46:43.471] --> window/workDoneProgress/create[9] {"jsonrpc":"2.0","id":9,"result":null}
[jsonrpc] e[16:46:43.471] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building CrateGraph","value":{"kind":"begin","title":"Building CrateGraph","cancellable":false}}}
[jsonrpc] e[16:46:43.471] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building CrateGraph","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.473] <-- window/workDoneProgress/create[10] {"jsonrpc":"2.0","id":10,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Building build-artifacts"}}
[jsonrpc] e[16:46:43.473] --> window/workDoneProgress/create[10] {"jsonrpc":"2.0","id":10,"result":null}
[jsonrpc] e[16:46:43.473] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Building build-artifacts","value":{"kind":"begin","title":"Building build-artifacts","cancellable":false}}}
[jsonrpc] e[16:46:43.474] <-- window/workDoneProgress/create[11] {"jsonrpc":"2.0","id":11,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Indexing"}}
[jsonrpc] e[16:46:43.474] --> window/workDoneProgress/create[11] {"jsonrpc":"2.0","id":11,"result":null}
[jsonrpc] D[16:46:43.478] Connection state change: `killed
'

----------b---y---e---b---y---e----------
[jsonrpc] e[16:46:43.479] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"begin","title":"Indexing","cancellable":false,"percentage":0}}}
[jsonrpc] e[16:46:43.484] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"1/12 (core + 2 more)","percentage":8}}}
[jsonrpc] e[16:46:43.484] <-- window/workDoneProgress/create[12] {"jsonrpc":"2.0","id":12,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Loading proc-macros"}}
[jsonrpc] e[16:46:43.484] --> window/workDoneProgress/create[12] {"jsonrpc":"2.0","id":12,"result":null}
[jsonrpc] e[16:46:43.484] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Loading proc-macros","value":{"kind":"begin","title":"Loading proc-macros","cancellable":false}}}
[jsonrpc] e[16:46:43.484] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Loading proc-macros","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.484] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"3/12 (core + 2 more)","percentage":25}}}
[jsonrpc] e[16:46:43.484] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"end"}}}
[jsonrpc] e[16:46:43.484] <-- window/workDoneProgress/create[13] {"jsonrpc":"2.0","id":13,"method":"window/workDoneProgress/create","params":{"token":"rustAnalyzer/Indexing"}}
[jsonrpc] e[16:46:43.484] --> window/workDoneProgress/create[13] {"jsonrpc":"2.0","id":13,"result":null}
[jsonrpc] e[16:46:43.484] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"begin","title":"Indexing","cancellable":false,"percentage":0}}}
[jsonrpc] e[16:46:43.484] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"0/12 (core)","percentage":0}}}
[stderr]  
[stderr]  
[stderr]  nil
[stderr]  nil
[stderr]  Process EGLOT (cmpl-project/(rust-mode rust-ts-mode)) stderr<1> finished
[jsonrpc] e[16:46:43.487] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"1/12 (core + 2 more)","percentage":8}}}
[jsonrpc] e[16:46:43.487] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"4/12 (core + 3 more)","percentage":33}}}
[jsonrpc] e[16:46:43.488] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"5/12 (core + 2 more)","percentage":41}}}
[jsonrpc] e[16:46:43.508] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"6/12 (core + 1 more)","percentage":50}}}
[jsonrpc] e[16:46:43.549] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rustAnalyzer/Indexing","value":{"kind":"report","cancellable":false,"message":"7/12 (core)","percentage":58}}}
[jsonrpc] e[16:46:43.549] <-- window/workDoneProgress/create[14] {"jsonrpc":"2.0","id":14,"method":"window/workDoneProgress/create","params":{"token":"rust-analyzer/flycheck/0"}}
[jsonrpc] e[16:46:43.549] --> window/workDoneProgress/create[14] {"jsonrpc":"2.0","id":14,"result":null}
[jsonrpc] e[16:46:43.549] <-- $/progress {"jsonrpc":"2.0","method":"$/progress","params":{"token":"rust-analyzer/flycheck/0","value":{"kind":"begin","title":"cargo check","cancellable":true}}}
[eglot] Asking EGLOT (cmpl-project/(rust-mode rust-ts-mode)) politely to terminate
[jsonrpc] (warning) Sentinel for EGLOT (cmpl-project/(rust-mode rust-ts-mode)) still hasn't run, deleting it!
Warning (jsonrpc): Sentinel for EGLOT (cmpl-project/(rust-mode rust-ts-mode)) still hasn't run, deleting it!
[jsonrpc] Server exited with status 9
[eglot-tests] Non-critical cleanup error: (cl-assertion-failed (memq id track-changes--trackers))
[eglot-tests] contents of ` *EGLOT (cmpl-project/(rust-mode rust-ts-mode)) output*':
[eglot-tests] contents of `nil':
[eglot-tests] Killing (main.rs), wiping /tmp/eglot--fixture-XCmCqo
Test eglot-test-rust-completion-exit-function backtrace:
  set-buffer(#<killed buffer>)
  (save-current-buffer (set-buffer buffer) (buffer-string))
  (princ (save-current-buffer (set-buffer buffer) (buffer-string)) 'ex
  (let ((buffer (car tail))) (eglot--test-message "contents of `%s':" 
  (while tail (let ((buffer (car tail))) (eglot--test-message "content
  (let ((tail buffers)) (while tail (let ((buffer (car tail))) (eglot-
  (cond (noninteractive (let ((tail buffers)) (while tail (let ((buffe
  (let ((buffers (delq nil (list (process-buffer (jsonrpc--process ser
  (progn (let ((buffers (delq nil (list (process-buffer (jsonrpc--proc
  (if (not test-body-successful-p) (progn (let ((buffers (delq nil (li
  (let ((server (car tail))) (if (jsonrpc-running-p server) (progn (co
  (while tail (let ((server (car tail))) (if (jsonrpc-running-p server
  (let ((tail new-servers)) (while tail (let ((server (car tail))) (if
  (let ((eglot-autoreconnect nil)) (let ((tail new-servers)) (while ta
  (unwind-protect (let ((eglot-autoreconnect nil)) (let ((tail new-ser
  (unwind-protect (let ((process-environment (cons (format "XDG_CONFIG
  (let* ((fixture-directory (make-nearby-temp-file "eglot--fixture-" t
  eglot--call-with-fixture((("cmpl-project" ("main.rs" . "fn test() ->
  #f(lambda () [typescript-mode-abbrev-table typescript-mode-syntax-ta
  #f(compiled-function () #<bytecode -0x8e70ffaf663dceb>)()
  handler-bind-1(#f(compiled-function () #<bytecode -0x8e70ffaf663dceb
  ert--run-test-internal(#s(ert--test-execution-info :test #s(ert-test
  ert-run-test(#s(ert-test :name eglot-test-rust-completion-exit-funct
  ert-run-or-rerun-test(#s(ert--stats :selector "rust-completion" :tes
  ert-run-tests("rust-completion" #f(compiled-function (event-type &re
  ert-run-tests-batch("rust-completion")
  ert-run-tests-batch-and-exit("rust-completion")
  eval((ert-run-tests-batch-and-exit '"rust-completion") t)
  command-line-1(("-L" ":." "-l" "ert" "--eval" "(setq treesit-extra-l
  command-line()
  normal-top-level()
Test eglot-test-rust-completion-exit-function condition:
    (error "Selecting deleted buffer")
   FAILED  1/1  eglot-test-rust-completion-exit-function (1.335289 sec) at lisp/progmodes/eglot-tests.el:698

Ran 1 tests, 0 results as expected, 1 unexpected (2024-09-08 16:46:43+0100, 1.486421 sec)

1 unexpected results:
   FAILED  eglot-test-rust-completion-exit-function

\amake[1]: *** [Makefile:185: lisp/progmodes/eglot-tests.log] Error 1
make[1]: Leaving directory '/home/capitaomorte/Source/Emacs/emacs-30/test'
make: *** [Makefile:251: lisp/progmodes/eglot-tests] Error 2
make: Leaving directory '/home/capitaomorte/Source/Emacs/emacs-30/test'

[-- Attachment #3: failure2.txt --]
[-- Type: text/plain, Size: 1266 bytes --]

make: Entering directory '/home/capitaomorte/Source/Emacs/emacs-30/test'
make[1]: Entering directory '/home/capitaomorte/Source/Emacs/emacs-30/test'
  ELC+ELN  lisp/progmodes/eglot-tests.elc
  GEN      lisp/progmodes/eglot-tests.log
Running 1 tests (2024-09-08 16:48:56+0100, selector ‘"rust-completion"’)
[eglot-tests] [eglot-test-rust-completion-exit-function]: test start
    Creating binary (application) package
note: see more `Cargo.toml` keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[eglot] Connected! Server `rust-analyzer' now managing `(rust-mode rust-ts-mode)' buffers in project `cmpl-project'.
[eglot] Connected! Server `rust-analyzer' now managing `(rust-mode rust-ts-mode)' buffers in project `cmpl-project'.
[eglot-tests] waiting for `(and (string= method $/progress) rustAnalyzer/Indexing (equal params '(:token rustAnalyzer/Indexing :value (:kind begin :title Indexing :cancellable :json-false :percentage 0))))'
make[1]: *** [Makefile:185: lisp/progmodes/eglot-tests.log] Aborted (core dumped)
make[1]: Leaving directory '/home/capitaomorte/Source/Emacs/emacs-30/test'
make: *** [Makefile:251: lisp/progmodes/eglot-tests] Error 2
make: Leaving directory '/home/capitaomorte/Source/Emacs/emacs-30/test'

^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-08 15:51                     ` João Távora
@ 2024-09-09  0:20                       ` Dmitry Gutov
  2024-09-09 11:46                         ` Eli Zaretskii
  2024-09-10  1:40                       ` Dmitry Gutov
  1 sibling, 1 reply; 18+ messages in thread
From: Dmitry Gutov @ 2024-09-09  0:20 UTC (permalink / raw)
  To: João Távora; +Cc: Eli Zaretskii, 72765

[-- Attachment #1: Type: text/plain, Size: 1627 bytes --]

On 08/09/2024 18:51, João Távora wrote:
>> Looking at minibuffer-tests.el, the above might be a solution, but it
>> gets me a core dump instead:
>>
>> diff --git a/test/lisp/progmodes/eglot-tests.el
>> b/test/lisp/progmodes/eglot-tests.el
>> index e0168baee54..fa3b63b38dc 100644
>> --- a/test/lisp/progmodes/eglot-tests.el
>> +++ b/test/lisp/progmodes/eglot-tests.el
>> @@ -711,7 +711,8 @@ eglot-test-rust-completion-exit-function
>>          (search-forward "v.count_on")
>>          (let ((minibuffer-message-timeout 0)
>>                ;; Fail at (ding) if completion fails.
>> -            (executing-kbd-macro t))
>> +            (executing-kbd-macro t)
>> +            (redisplay-skip-initial-frame nil))
>>            (when (buffer-live-p "*Completions*")
>>              (kill-buffer "*Completions*"))
>>            ;; The design is pretty brittle, we'll need to monitor the
>>
>>
>> Will follow up later if nobody beats me to it (can others reproduce the
>> crash?)
> This now aborts (segfault?).  At least something different.
> 
> So, for the record, before this patch with the latest emacs-30, I get the
> results in failure1.txt and with your last redisplay-skip-initial-frame patch
> I get failure2.txt.
> 
> I've produced these files with
> 
> make -C test eglot-tests SELECTOR=\"rust-completion\" 2>&1 | tee failure1.txt

So it's reproducible. Great!

Could someone look into the segfault? The repro steps are simple:

1) apply the patch above,
2) run 'make -C test eglot-tests' or the longer command above which 
executes just one test from that file.

The backtrace that I managed to generate is attached.

[-- Attachment #2: make_test_backtrace.log --]
[-- Type: text/x-log, Size: 12889 bytes --]

Core was generated by `../src/emacs --module-assertions --no-init-file --no-site-file --no-site-lisp -'.
Program terminated with signal SIGABRT, Aborted.
#0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:44
Download failed: Invalid argument.  Continuing without source file ./nptl/./nptl/pthread_kill.c.                                                                                              
44	./nptl/pthread_kill.c: No such file or directory.
(gdb) bt
#0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:44
#1  __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
#2  __GI___pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
#3  0x0000794b524428e6 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#4  0x0000557cbe936774 in terminate_due_to_signal (sig=sig@entry=6, backtrace_limit=backtrace_limit@entry=40) at emacs.c:480
#5  0x0000557cbe959e9f in emacs_abort () at sysdep.c:2391
#6  0x0000557cbe8793fb in try_window_id (w=0x557cc05f09e8) at xdisp.c:22092
#7  redisplay_window (window=0x557cc05f09ed, just_this_one_p=just_this_one_p@entry=false) at xdisp.c:20444
#8  0x0000557cbe87d13e in redisplay_window_0 (window=window@entry=0x557cc05f09ed) at xdisp.c:18020
#9  0x0000557cbe9bff71 in internal_condition_case_1
    (bfun=bfun@entry=0x557cbe87d10b <redisplay_window_0>, arg=arg@entry=0x557cc05f09ed, handlers=<optimized out>, hfun=hfun@entry=0x557cbe835eac <redisplay_window_error>) at eval.c:1637
#10 0x0000557cbe833d83 in redisplay_windows (window=0x557cc05f09ed) at xdisp.c:17989
#11 0x0000557cbe867eeb in redisplay_internal () at xdisp.c:17388
#12 0x0000557cbe86853d in redisplay () at xdisp.c:16563
#13 0x0000557cbe947be0 in read_char
    (commandflag=commandflag@entry=0, map=map@entry=0x0, prev_event=prev_event@entry=0x30, used_mouse_menu=used_mouse_menu@entry=0x0, end_time=0x7fff70418740) at keyboard.c:2678
#14 0x0000557cbe9ebec0 in read_filtered_event
    (no_switch_frame=no_switch_frame@entry=false, ascii_required=ascii_required@entry=false, error_nonascii=error_nonascii@entry=false, input_method=input_method@entry=false, seconds=seconds@entry=0x794b4e67024f) at lread.c:791
#15 0x0000557cbe9ec0fa in Fread_event (prompt=0x0, inherit_input_method=0x0, seconds=0x794b4e67024f) at lread.c:941
#16 0x0000557cbe9c47e8 in eval_sub (form=<optimized out>) at eval.c:2604
#17 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#18 0x0000557cbe9c55a9 in Fcond (args=0x794b4da7fd93) at eval.c:419
#19 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#20 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#21 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#22 0x0000557cbe9c5545 in Fif (args=0x794b4d932be3) at eval.c:394
#23 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#24 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>, body@entry=0x794b4d932e53) at eval.c:439
#25 0x0000557cbe9c597f in prog_ignore (body=0x794b4d932e53) at eval.c:450
#26 Fwhile (args=<optimized out>) at eval.c:1130
#27 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#28 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#29 0x0000557cbe9c6210 in FletX (args=<optimized out>) at /home/dgutov/vc/emacs/src/lisp.h:1539
#30 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#31 0x0000557cbe9c5d5b in Flet (args=<optimized out>) at eval.c:1080
#32 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#33 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#34 0x0000557cbe9c517b in funcall_lambda (fun=<optimized out>, nargs=nargs@entry=0, arg_vector=arg_vector@entry=0x7fff70418f88) at eval.c:3350
#35 0x0000557cbe9c5302 in funcall_general (fun=<optimized out>, numargs=numargs@entry=0, args=args@entry=0x7fff70418f88) at eval.c:3044
#36 0x0000557cbe9c155c in Ffuncall (nargs=1, args=0x7fff70418f80) at eval.c:3093
#37 0x0000557cbe9c46f9 in eval_sub (form=<optimized out>) at eval.c:2570
#38 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>, body@entry=0x794b4da82c63) at eval.c:439
--Type <RET> for more, q to quit, c to continue without paging--c
#39 0x0000557cbe9bfe25 in internal_catch (tag=<optimized out>, func=func@entry=0x557cbe9c4dc4 <Fprogn>, arg=0x794b4da82c63) at eval.c:1292
#40 0x0000557cbe9c59cd in Fcatch (args=0x794b4da82c53) at /home/dgutov/vc/emacs/src/lisp.h:1539
#41 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#42 0x0000557cbe9c566f in Fsetq (args=<optimized out>) at eval.c:486
#43 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#44 0x0000557cbe9c635d in Funwind_protect (args=0x794b4da82d23) at /home/dgutov/vc/emacs/src/lisp.h:1533
#45 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#46 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#47 0x0000557cbe9c6210 in FletX (args=<optimized out>) at /home/dgutov/vc/emacs/src/lisp.h:1539
#48 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#49 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#50 0x0000557cbe9c517b in funcall_lambda (fun=fun@entry=0x557cc0aecc05, nargs=nargs@entry=2, arg_vector=arg_vector@entry=0x7fff704194f0) at eval.c:3350
#51 0x0000557cbe9c5af6 in apply_lambda (fun=fun@entry=0x557cc0aecc05, args=<optimized out>, count=count@entry=...) at eval.c:3215
#52 0x0000557cbe9c48e2 in eval_sub (form=<optimized out>) at eval.c:2645
#53 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#54 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#55 0x0000557cbe9c635d in Funwind_protect (args=0x794b4d9345f3) at /home/dgutov/vc/emacs/src/lisp.h:1533
#56 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#57 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#58 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#59 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#60 0x0000557cbe9c6210 in FletX (args=<optimized out>) at /home/dgutov/vc/emacs/src/lisp.h:1539
#61 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#62 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#63 0x0000557cbe9c6210 in FletX (args=<optimized out>) at /home/dgutov/vc/emacs/src/lisp.h:1539
#64 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#65 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#66 0x0000557cbe9c517b in funcall_lambda (fun=fun@entry=0x557cc0b25a75, nargs=nargs@entry=0, arg_vector=arg_vector@entry=0x7fff70419bd0) at eval.c:3350
#67 0x0000557cbe9c5af6 in apply_lambda (fun=fun@entry=0x557cc0b25a75, args=<optimized out>, count=count@entry=...) at eval.c:3215
#68 0x0000557cbe9c48e2 in eval_sub (form=<optimized out>) at eval.c:2645
#69 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#70 0x0000557cbe9c5ebf in Flet (args=<optimized out>) at /home/dgutov/vc/emacs/src/lisp.h:1539
#71 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#72 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>, body@entry=0x794b4d8f3193) at eval.c:439
#73 0x0000557cbe9b2a66 in Fsave_current_buffer (args=0x794b4d8f3193) at editfns.c:852
#74 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#75 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#76 0x0000557cbe9c517b in funcall_lambda (fun=<optimized out>, nargs=nargs@entry=0, arg_vector=arg_vector@entry=0x7fff7041a078) at eval.c:3350
#77 0x0000557cbe9c5302 in funcall_general (fun=<optimized out>, numargs=numargs@entry=0, args=args@entry=0x7fff7041a078) at eval.c:3044
#78 0x0000557cbe9c155c in Ffuncall (nargs=1, args=0x7fff7041a070) at eval.c:3093
#79 0x0000557cbe9c46f9 in eval_sub (form=<optimized out>) at eval.c:2570
#80 0x0000557cbe9c55c6 in Fprog1 (args=0x794b4da8e5c3) at eval.c:460
#81 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#82 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#83 0x0000557cbe9c5ebf in Flet (args=<optimized out>) at /home/dgutov/vc/emacs/src/lisp.h:1539
#84 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#85 0x0000557cbe9c635d in Funwind_protect (args=0x794b4da8e663) at /home/dgutov/vc/emacs/src/lisp.h:1533
#86 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#87 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#88 0x0000557cbe9c6210 in FletX (args=<optimized out>) at /home/dgutov/vc/emacs/src/lisp.h:1539
#89 0x0000557cbe9c45b2 in eval_sub (form=<optimized out>) at eval.c:2549
#90 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#91 0x0000557cbe9c517b in funcall_lambda (fun=fun@entry=0x557cc0aec9b5, nargs=nargs@entry=2, arg_vector=arg_vector@entry=0x7fff7041a620) at eval.c:3350
#92 0x0000557cbe9c5af6 in apply_lambda (fun=fun@entry=0x557cc0aec9b5, args=<optimized out>, count=count@entry=...) at eval.c:3215
#93 0x0000557cbe9c48e2 in eval_sub (form=<optimized out>) at eval.c:2645
#94 0x0000557cbe9c4df0 in Fprogn (body=<optimized out>) at eval.c:439
#95 0x0000557cbe9c517b in funcall_lambda (fun=<optimized out>, nargs=nargs@entry=0, arg_vector=arg_vector@entry=0x794b4dbff4b8) at eval.c:3350
#96 0x0000557cbe9c5302 in funcall_general (fun=<optimized out>, fun@entry=0x557cc0b283f5, numargs=numargs@entry=0, args=args@entry=0x794b4dbff4b8) at eval.c:3044
#97 0x0000557cbea051f6 in exec_byte_code (fun=<optimized out>, fun@entry=0x557cc12fb10d, args_template=<optimized out>, args_template@entry=0, nargs=<optimized out>, 
    nargs@entry=0, args=<optimized out>, args@entry=0x7fff7041a9c8) at bytecode.c:814
#98 0x0000557cbe9c4f27 in funcall_lambda (fun=0x557cc12fb10d, nargs=nargs@entry=0, arg_vector=arg_vector@entry=0x7fff7041a9c8) at eval.c:3252
#99 0x0000557cbe9c5302 in funcall_general (fun=<optimized out>, numargs=numargs@entry=0, args=args@entry=0x7fff7041a9c8) at eval.c:3044
#100 0x0000557cbe9c155c in Ffuncall (nargs=nargs@entry=1, args=args@entry=0x7fff7041a9c0) at eval.c:3093
#101 0x0000557cbe9c362f in call0 (fn=<optimized out>) at /home/dgutov/vc/emacs/src/lisp.h:3515
#102 Fhandler_bind_1 (nargs=<optimized out>, args=0x794b4dbff468) at eval.c:1478
#103 0x0000557cbe9c34d6 in funcall_subr (subr=<optimized out>, numargs=numargs@entry=3, args=args@entry=0x794b4dbff468) at eval.c:3184
#104 0x0000557cbea0516e in exec_byte_code (fun=<optimized out>, fun@entry=0x557cc0712b2d, args_template=<optimized out>, args_template@entry=256, nargs=<optimized out>, 
    nargs@entry=1, args=<optimized out>, args@entry=0x7fff7041ab70) at /home/dgutov/vc/emacs/src/lisp.h:2243
#105 0x0000557cbe9c4f27 in funcall_lambda (fun=fun@entry=0x557cc0712b2d, nargs=nargs@entry=1, arg_vector=arg_vector@entry=0x7fff7041ab70) at eval.c:3252
#106 0x0000557cbe9c5af6 in apply_lambda (fun=fun@entry=0x557cc0712b2d, args=<optimized out>, count=count@entry=...) at eval.c:3215
#107 0x0000557cbe9c48e2 in eval_sub (form=form@entry=0x794b4d5e8d33) at eval.c:2645
#108 0x0000557cbe9c68e7 in Feval (form=0x794b4d5e8d33, lexical=<optimized out>) at eval.c:2462
#109 0x0000557cbe9c33fb in funcall_subr (subr=<optimized out>, numargs=numargs@entry=2, args=args@entry=0x794b4dbff1c0) at eval.c:3163
#110 0x0000557cbea0516e in exec_byte_code (fun=<optimized out>, fun@entry=0x794b4ecd9285, args_template=<optimized out>, args_template@entry=0, nargs=<optimized out>, 
    nargs@entry=0, args=<optimized out>, args@entry=0x7fff7041ae30) at /home/dgutov/vc/emacs/src/lisp.h:2243
#111 0x0000557cbe9c4f27 in funcall_lambda (fun=fun@entry=0x794b4ecd9285, nargs=nargs@entry=0, arg_vector=arg_vector@entry=0x7fff7041ae30) at eval.c:3252
#112 0x0000557cbe9c5af6 in apply_lambda (fun=fun@entry=0x794b4ecd9285, args=<optimized out>, count=count@entry=...) at eval.c:3215
#113 0x0000557cbe9c48e2 in eval_sub (form=form@entry=0x794b4ee99b7b) at eval.c:2645
#114 0x0000557cbe9c68e7 in Feval (form=0x794b4ee99b7b, lexical=lexical@entry=0x30) at eval.c:2462
#115 0x0000557cbe939510 in top_level_2 () at keyboard.c:1184
#116 0x0000557cbe9bfef3 in internal_condition_case (bfun=bfun@entry=0x557cbe9394bc <top_level_2>, handlers=handlers@entry=0x90, hfun=hfun@entry=0x557cbe93e278 <cmd_error>) at eval.c:1613
#117 0x0000557cbe9393fd in top_level_1 (ignore=ignore@entry=0x0) at keyboard.c:1196
#118 0x0000557cbe9bfe25 in internal_catch (tag=tag@entry=0x122d0, func=func@entry=0x557cbe9393d3 <top_level_1>, arg=arg@entry=0x0) at eval.c:1292
#119 0x0000557cbe93936d in command_loop () at keyboard.c:1145
#120 0x0000557cbe93de34 in recursive_edit_1 () at keyboard.c:754
#121 0x0000557cbe93e19a in Frecursive_edit () at keyboard.c:837
#122 0x0000557cbe93872d in main (argc=16, argv=<optimized out>) at emacs.c:2635

^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-09  0:20                       ` Dmitry Gutov
@ 2024-09-09 11:46                         ` Eli Zaretskii
  2024-09-10  0:58                           ` Dmitry Gutov
  0 siblings, 1 reply; 18+ messages in thread
From: Eli Zaretskii @ 2024-09-09 11:46 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: 72765, joaotavora

> Date: Mon, 9 Sep 2024 03:20:01 +0300
> Cc: Eli Zaretskii <eliz@gnu.org>, 72765@debbugs.gnu.org
> From: Dmitry Gutov <dmitry@gutov.dev>
> 
> > This now aborts (segfault?).  At least something different.
> > 
> > So, for the record, before this patch with the latest emacs-30, I get the
> > results in failure1.txt and with your last redisplay-skip-initial-frame patch
> > I get failure2.txt.
> > 
> > I've produced these files with
> > 
> > make -C test eglot-tests SELECTOR=\"rust-completion\" 2>&1 | tee failure1.txt
> 
> So it's reproducible. Great!
> 
> Could someone look into the segfault? The repro steps are simple:
> 
> 1) apply the patch above,
> 2) run 'make -C test eglot-tests' or the longer command above which 
> executes just one test from that file.
> 
> The backtrace that I managed to generate is attached.

Thanks.  Please try the patch below.

P.S. I'm not at all sure this is the last segfault you will see
because you are playing with fire: you are not supposed to reset
redisplay-skip-initial-frame to nil in batch-mode tests that test
redisplay-related features!

diff --git a/src/xdisp.c b/src/xdisp.c
index bf7d84c..a1319e7 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -22089,7 +22089,8 @@ #define GIVE_UP(X) return 0
 
   /* Window must either use window-based redisplay or be full width.  */
   if (!FRAME_WINDOW_P (f)
-      && (!FRAME_LINE_INS_DEL_OK (f)
+      && (FRAME_INITIAL_P (f)
+	  || !FRAME_LINE_INS_DEL_OK (f)
 	  || !WINDOW_FULL_WIDTH_P (w)))
     GIVE_UP (4);
 





^ permalink raw reply related	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-09 11:46                         ` Eli Zaretskii
@ 2024-09-10  0:58                           ` Dmitry Gutov
  2024-09-10 11:47                             ` Eli Zaretskii
  0 siblings, 1 reply; 18+ messages in thread
From: Dmitry Gutov @ 2024-09-10  0:58 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 72765, joaotavora

On 09/09/2024 14:46, Eli Zaretskii wrote:
>> Date: Mon, 9 Sep 2024 03:20:01 +0300
>> Cc: Eli Zaretskii <eliz@gnu.org>, 72765@debbugs.gnu.org
>> From: Dmitry Gutov <dmitry@gutov.dev>
>>
>>> This now aborts (segfault?).  At least something different.
>>>
>>> So, for the record, before this patch with the latest emacs-30, I get the
>>> results in failure1.txt and with your last redisplay-skip-initial-frame patch
>>> I get failure2.txt.
>>>
>>> I've produced these files with
>>>
>>> make -C test eglot-tests SELECTOR=\"rust-completion\" 2>&1 | tee failure1.txt
>>
>> So it's reproducible. Great!
>>
>> Could someone look into the segfault? The repro steps are simple:
>>
>> 1) apply the patch above,
>> 2) run 'make -C test eglot-tests' or the longer command above which
>> executes just one test from that file.
>>
>> The backtrace that I managed to generate is attached.
> 
> Thanks.  Please try the patch below.

Thanks! The patch takes care of the crash AFAICS (no core dump now), but 
alas not of the original test failure.

> P.S. I'm not at all sure this is the last segfault you will see
> because you are playing with fire: you are not supposed to reset
> redisplay-skip-initial-frame to nil in batch-mode tests that test
> redisplay-related features!

Isn't that the main/only purpose of this variable?

That's how the docstring reads to me, and it's also seems why 
minibuffer-test.el uses it.

In any case, this var is neither necessary nor sufficient (see my next 
email), so sorry if that wasted you time. The fix might still be worth 
installing, though.

> diff --git a/src/xdisp.c b/src/xdisp.c
> index bf7d84c..a1319e7 100644
> --- a/src/xdisp.c
> +++ b/src/xdisp.c
> @@ -22089,7 +22089,8 @@ #define GIVE_UP(X) return 0
>   
>     /* Window must either use window-based redisplay or be full width.  */
>     if (!FRAME_WINDOW_P (f)
> -      && (!FRAME_LINE_INS_DEL_OK (f)
> +      && (FRAME_INITIAL_P (f)
> +	  || !FRAME_LINE_INS_DEL_OK (f)
>   	  || !WINDOW_FULL_WIDTH_P (w)))
>       GIVE_UP (4);
>   






^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-08 15:51                     ` João Távora
  2024-09-09  0:20                       ` Dmitry Gutov
@ 2024-09-10  1:40                       ` Dmitry Gutov
  1 sibling, 0 replies; 18+ messages in thread
From: Dmitry Gutov @ 2024-09-10  1:40 UTC (permalink / raw)
  To: João Távora; +Cc: Eli Zaretskii, 72765

Hi Joao,

On 08/09/2024 18:51, João Távora wrote:
> So, for the record, before this patch with the latest emacs-30, I get the
> results in failure1.txt

I've taken some more looks at the test output.

[eglot-tests] contents of `*EGLOT (cmpl-project/(rust-mode 
rust-ts-mode)) output*':
> [eglot-tests] contents of `nil':
> [eglot-tests] Killing (main.rs), wiping /tmp/eglot--fixture-XCmCqo
> Test eglot-test-rust-completion-exit-function backtrace:
>    set-buffer(#<killed buffer>)  eglot--call-with-fixture((("cmpl-project" ("main.rs" . "fn test() ->Test eglot-test-rust-completion-exit-function condition:
>      (error "Selecting deleted buffer")

This error comes from eglot--call-with-fixture, where one of the last

   (with-current-buffer buffer (buffer-string))

calls results in "Selecting deleted buffer" error. I'm not sure where 
that comes from (for the duration of the log the contents of stdout 
buffer are printed twice, and stderr and events just once -- somehow 
there are two elements inside the 'new-servers' var).

That hid the original problem, which was just that in the bare session 
yasnippet is not available. Not sure what to do about it - 
monkeypatching a replacements does not seem wise - but if we adjust the 
"expected" at the end not to have parens, then the test finally passes. 
It will fail interactively, though, when yasnippet is installed.

I've pushed that fix as 
https://git.savannah.gnu.org/cgit/emacs.git/commit/?h=emacs-30&id=818c0cc9a51a1d678749404cdacdf640d6f32d6e 
now.

It makes that test more similar to 
'eglot-test-try-completion-inside-symbol', but testing rust-analyzer 
separately still seems like a plus.





^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-10  0:58                           ` Dmitry Gutov
@ 2024-09-10 11:47                             ` Eli Zaretskii
  2024-09-10 13:20                               ` Dmitry Gutov
  0 siblings, 1 reply; 18+ messages in thread
From: Eli Zaretskii @ 2024-09-10 11:47 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: 72765, joaotavora

> Date: Tue, 10 Sep 2024 03:58:58 +0300
> Cc: joaotavora@gmail.com, 72765@debbugs.gnu.org
> From: Dmitry Gutov <dmitry@gutov.dev>
> 
> >> The backtrace that I managed to generate is attached.
> > 
> > Thanks.  Please try the patch below.
> 
> Thanks! The patch takes care of the crash AFAICS (no core dump now), but 
> alas not of the original test failure.

I installed the patch on the emacs-30 branch.

> > P.S. I'm not at all sure this is the last segfault you will see
> > because you are playing with fire: you are not supposed to reset
> > redisplay-skip-initial-frame to nil in batch-mode tests that test
> > redisplay-related features!
> 
> Isn't that the main/only purpose of this variable?

You mean, playing with fire?  Yes, but you need to be aware of that.
This variable was introduced relatively recently for use by
test/src/xdisp-tests.el; anywhere else you are on your own ;-)





^ permalink raw reply	[flat|nested] 18+ messages in thread

* bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text
  2024-09-10 11:47                             ` Eli Zaretskii
@ 2024-09-10 13:20                               ` Dmitry Gutov
  0 siblings, 0 replies; 18+ messages in thread
From: Dmitry Gutov @ 2024-09-10 13:20 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 72765, joaotavora

On 10/09/2024 14:47, Eli Zaretskii wrote:
>> Date: Tue, 10 Sep 2024 03:58:58 +0300
>> Cc:joaotavora@gmail.com,72765@debbugs.gnu.org
>> From: Dmitry Gutov<dmitry@gutov.dev>
>>
>>>> The backtrace that I managed to generate is attached.
>>> Thanks.  Please try the patch below.
>> Thanks! The patch takes care of the crash AFAICS (no core dump now), but
>> alas not of the original test failure.
> I installed the patch on the emacs-30 branch.
> 
>>> P.S. I'm not at all sure this is the last segfault you will see
>>> because you are playing with fire: you are not supposed to reset
>>> redisplay-skip-initial-frame to nil in batch-mode tests that test
>>> redisplay-related features!
>> Isn't that the main/only purpose of this variable?
> You mean, playing with fire?  Yes, but you need to be aware of that.
> This variable was introduced relatively recently for use by
> test/src/xdisp-tests.el; anywhere else you are on your own 😉

Thanks!





^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2024-09-10 13:20 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-22 23:07 bug#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text Dmitry Gutov
2024-08-29 11:34 ` Eli Zaretskii
2024-08-30 21:23   ` Dmitry Gutov
2024-08-31  6:47     ` Eli Zaretskii
2024-08-31 12:03       ` João Távora
2024-09-01  1:43         ` Dmitry Gutov
2024-09-01  9:43           ` João Távora
2024-09-01 14:28             ` Dmitry Gutov
2024-09-03 13:20               ` Dmitry Gutov
2024-09-03 13:43                 ` João Távora
2024-09-08  2:41                   ` Dmitry Gutov
2024-09-08 15:51                     ` João Távora
2024-09-09  0:20                       ` Dmitry Gutov
2024-09-09 11:46                         ` Eli Zaretskii
2024-09-10  0:58                           ` Dmitry Gutov
2024-09-10 11:47                             ` Eli Zaretskii
2024-09-10 13:20                               ` Dmitry Gutov
2024-09-10  1:40                       ` Dmitry Gutov

Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).