Skip to content
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

Completions disappear after dot + symbol #4419

Closed
3 tasks done
Hi-Angel opened this issue Apr 8, 2024 · 1 comment · Fixed by #4428
Closed
3 tasks done

Completions disappear after dot + symbol #4419

Hi-Angel opened this issue Apr 8, 2024 · 1 comment · Fixed by #4428
Labels

Comments

@Hi-Angel
Copy link
Contributor

Hi-Angel commented Apr 8, 2024

Thank you for the bug report

  • I am using the latest version of lsp-mode related packages.
  • I checked FAQ and Troubleshooting sections
  • You may also try reproduce the issue using clean environment using the following command: M-x lsp-start-plain

Bug description

lsp-mode treats . specially for many languages, as in, it provides completions immediately even though company-minimum-prefix-length isn't satisfied. Which makes sense of course. Unfortunately, lsp-mode loses completion after typing out the next symbol, instead of reducing them to ones that start with the symbol.

So e.g. foo. pops up completions, but foo.c kills the pop up even if there are candidates.

Also asked as a question here: https://emacs.stackexchange.com/questions/80977/prevent-lsp-company-from-losing-completion-after-dot-symbol

Side note: elgot, the competitor mode, handles that correctly.

Steps to reproduce

  1. Create /tmp/.emacs as follows:

    (package-initialize)
    (use-package company)
    (use-package lsp)
  2. Start emacs as emacs -Q -l /tmp/.emacs test.py

  3. Execute M-x lsp

  4. Type "".

    A completion should appear

  5. Type c to reduce completions to ones starting with that letter

Expected behavior

Completions get reduced to ones starting with c, i.e. capitalize(), casefold(), etc.

Which Language Server did you use?

lsp-python, lsp-go, clangd.

OS

Linux

Error callstack

No response

Anything else?

No response

@Hi-Angel Hi-Angel added the bug label Apr 8, 2024
@jcs090218
Copy link
Member

I'm using my own company-fuzzy, so I don't have this issue. Let me ping one of the maintainers.

cc @kiennq

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants