Subject: bug#59149: Feature Request: Report progress of long requests in Eglot

From: João Távora <[email-masked]>
Date: Thu, 10 Nov 2022 15:50:29 +0000

Danny Freeman <[email-masked]> writes:

> Something I think would be nice to have in eglot is some kind of
> progress indicator for long running requests. Attached is my attempt at
> implementing these. The patch contains links to relevant LSP specs in
> the commit message.
>
> Here is a link to an old github discussion about progress notifications:
> https://github.com/joaotavora/eglot/discussions/835 
>
> It uses the built in progress-reporter to display progress in the
> echo area. Something that may be missing is a way for the user to
> enable/disable this. Not sure what the right facilities are for that.
> The eglot-stay-out-of pattern maybe? I didn't include that because I'm
> not sure what to "stay out of". Maybe the symbol `progress-reporter'?
> Happy to add something like that.

Thanks Danny, this doesn't look bad at all, though I have yet to
understand how it works.  I can half-see why progress status should be a
server property, but it would be better if you provided an automated
test, or maybe just a step-by-step sequence diagram (which can be in
plain text and language) that clarifies this.  An animated gif that
might also work.

Anyway, the way the user opts out of LSP configuration is via the user
variable eglot-ignored-server-capabilities.  So there should be some
point where you check the associated LSP capability of "progress
reporting" with eglot--server-capable.

João