Olical / conjure

Interactive evaluation for Neovim (Clojure, Fennel, Janet, Racket, Hy, MIT Scheme, Guile, Python and more!)
https://conjure.oli.me.uk
The Unlicense
1.75k stars 109 forks source link

fennel completion issue #443

Open fonghou opened 1 year ago

fonghou commented 1 year ago

Hi, fennel completion list doesn't look correct as shown in below screenshot. I'd expect only those os functions in the list. However, it seems conjure always includes lots of nvim stuff by default.

Is this expected behavior? Is there a way to disable this behavior in conjure?

image

Note that fennel eval works fine in the same buffer. I also disabled nvim_lsp and other lua lsp servers. But made no differenct.

BTW, I use nvim-cmp for conjure completion. It works fine for clj, cljs, cljc, python, even lua filetypes.

  use({ "Olical/conjure", config = get_config("coding.conjure") })
  use({ "PaterJason/cmp-conjure" })

Thanks!

fonghou commented 1 year ago

Looking at https://github.com/Olical/conjure/blob/0be93ef60f075a247bb5de9e29d447dc8a888ff0/fnl/conjure/client/fennel/aniseed.fnl#L233

Conjure aniseed client has its own completion implementation. I haven't figured out why it behaves as above. I'm thinking it's probably better to use fennel repl built-in ,complete command and add completion feature to fennel stdio client.

Olical commented 1 year ago

I can't remember why I implemented my own now, maybe ,complete didn't exist or I couldn't use it because I wasn't using the Fennel REPL for evals at the time (that change was relatively recently).

So I agree, I should look into replacing the completion system with the one built into the REPL now that we should have access to it.

There may be smaller patches we can do in the meantime to reduce the noise as well. Thank you for raising this!