this post was submitted on 12 Oct 2023
1 points (66.7% liked)

Emacs

310 readers
2 users here now

A community for the timeless and infinitely powerful editor. Want to see what Emacs is capable of?!

Get Emacs

Rules

  1. Posts should be emacs related
  2. Be kind please
  3. Yes, we already know: Google results for "emacs" and "vi" link to each other. We good.

Emacs Resources

Emacs Tutorials

Useful Emacs configuration files and distributions

Quick pain-saver tip

founded 1 year ago
MODERATORS
 

My eglot just stops working properly from time to time. Every once in a while, it'll get "out of sync" from the buffer. i.e. even after I correct the syntax error it reports, it still sends the old code to LSP, and therefore keeps reporting the fixed errors.

`elgot-reconnect` fixes it, but it's really not a solution to call `eglot-reconnect` every 10 minutes.

top 2 comments
sorted by: hot top controversial new old
[–] jvillasante@alien.top 1 points 1 year ago

If you are using corfu, I had a similar issue and the fix is below:

(advice-add 'eglot-completion-at-point :around #'cape-wrap-buster)
(advice-add 'eglot-completion-at-point :around #'cape-wrap-noninterruptible)
[–] yapfff@alien.top 1 points 1 year ago

Do you use corfu for completion by any chance?‌ If yes, see this:

https://github.com/joaotavora/eglot/discussions/1127

Not solved, but although it's not supposed to be a fix wrapping eglot-completion-at-point in cape-capf-noninterruptible (read the thread for details) made things OK for me.