-
Notifications
You must be signed in to change notification settings - Fork 200
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Quirks with flex company candidates #539
Comments
Thanks for the report. Indeed I only get substring completion now in the servers I have handy. I will investigate better how to make this happen in Eglot. |
@haoyuan80s Maybe enabling pyls.plugins.jedi_completion.fuzzy option in |
@muffinmad Thanks for your suggestion. But, I cannot make it work. In ".dir-locals.el", I added
The eglot-workspace-configuration has value
Still no flex candidates. |
@haoyuan80s You are right. Enabling
from datetime import datetime
def dotandmime():
pass
dtm|
But |
Thanks for the investigation, @muffinmad . To reproduce this, is it as easy as doing the
Seems like a bug, indeed I find it odd that clangd does give me fuzzy matches, wonder what's going on... |
@joaotavora Yes, sorry, forgot to mention configuration: (setq-default eglot-workspace-configuration
'((:pyls :plugins (:jedi_completion (:fuzzy t))))) |
"Just fine" is an exaggeration. That "test" hint seems wrong, and the server actually replied with three completions:
|
Well, here is the full receipt to check this: Emacs 28.0.50
(progn
(setq package-user-dir "/tmp/tmp-elpa")
(require 'package)
(package-initialize)
(add-to-list 'package-archives '("melpa" . "http://melpa.org/packages/") t)
(package-refresh-contents))
(package-install 'eglot)
(package-install 'company)
(setq-default eglot-workspace-configuration
'((:pyls :plugins (:jedi_completion (:fuzzy t)))))
(global-company-mode)
(find-file "test-eglot-flx.py")
(erase-buffer)
(insert "from datetime import datetime\n\n\ndef dotandmime():\n pass\n\n\ndtm")
Not surprising considering that the only company backend in the current buffer is |
How can I forget! Thanks to one great man we now have @haoyuan80s If you use Emacs 27, just |
I'm glad we could help. But I wouldn't say it works "perfectly":
So I'm keeping the issue open. |
Not the Eglot issue.
This will work only for those servers who support "fuzzy" completion. E.g. for |
@haoyuan80s Check out company-fuzzy |
I test in python (pyls) and go (gopls). For both, the company misses flex candidates.
Python example:
input
sm
->M-x [company complete]
-> "No completion found"There the the company candidates in python (pyls) given by lsp-mode:
My eglot conifg
The text was updated successfully, but these errors were encountered: