Exafunction / codeium.vim

Free, ultrafast Copilot alternative for Vim and Neovim
https://codeium.com
MIT License
3.72k stars 127 forks source link

Hangging after install this plugin. #35

Closed meicale closed 1 year ago

meicale commented 1 year ago

Just after installing this plugin, My neovim in WLS just hanging. It just stopped responding to anything. I guess that it may downloading the codeium server. But It just stops the whole NeoVim, maybe there are better way to deal with this. Thx!

pqn commented 1 year ago

What commit are you using? I recently pushed https://github.com/Exafunction/codeium.vim/commit/d252af59f06b8c8ded4247aed2e0d76a5ae4a9c7 intending to fix this.

meicale commented 1 year ago

I just retried and the nothing changed. I am not sure whether it is downloading the server. Can I download the server and install it manually?

jcdickinson commented 1 year ago

@meicale you can grab it here: https://github.com/Exafunction/codeium/releases

It goes into ~/.codeium/bin/<sha>, sha is this: https://github.com/Exafunction/codeium.vim/blob/main/autoload/codeium/server.vim#L2

On my machine, this means that I currently have ~/.codeium/bin/0a0cf69c54bd02be577e1240463b85d782fa5475/language_server_linux_x64.

calops commented 1 year ago

I'm having the same issue, on native linux neovim. It does grab the binary correctly into ~/.codeium, but it still hangs after a :Codeium Auth command. As far as I can tell, nothing at all is happening, it just freezes the whole editor.

By the way, a bit of a tangent but:

VarunMohan commented 1 year ago

@calops we should fix the hanging issue, that's definitely a bug.

It is a bug that we're fetching .exe on Linux - we should be fetching the write executable for your operating system. We were previously using XDG settings but that was leaking API keys for folks that were syncing dotfiles to github.

pqn commented 1 year ago
  • Why not use XDG settings for choosing config and binary dirs by default?

This is tracked and explained a bit in #24.

pqn commented 1 year ago
  • Why is it fetching the windows .exe as well if I'm on Linux? Looks like a waste of bandwidth and disk space.

The code to determine which binary is downloaded lives here: https://github.com/Exafunction/codeium.vim/blob/b22c53819a505b5789e4d4f65c4193e11ffacea0/autoload/codeium/server.vim#L110-L125

@calops can you let me know what uname and uname -m give you on your system?

meicale commented 1 year ago

Thank you all!

@meicale you can grab it here: https://github.com/Exafunction/codeium/releases

It goes into ~/.codeium/bin/<sha>, sha is this: https://github.com/Exafunction/codeium.vim/blob/main/autoload/codeium/server.vim#L2

On my machine, this means that I currently have ~/.codeium/bin/0a0cf69c54bd02be577e1240463b85d782fa5475/language_server_linux_x64.

Thx! It works for me. I download the server manually and put it in the right place, and then I have to use the "gzip -d" command to get the excutable file. It just works. I think this is caused by my Internet connection which is too slow to download the whole server.

meicale commented 1 year ago

Thank you all!

meicale commented 1 year ago

Thank you all!

alex-popov-tech commented 1 year ago

Hey guys! I think that should be re-opened because there is no way for user to know whats happening while downloading, and therefore no way to understand what happening. For me it was even worse:

At least saying that it is being downloaded would be really nice, and even better do not block whole vim while waiting for it

VarunMohan commented 1 year ago

@pqn I thought we made some changes to make this async?

pqn commented 1 year ago

@alex-popov-tech are you on a commit after d252af59f06b8c8ded4247aed2e0d76a5ae4a9c7? That was intended to make the download async.

Jxstxs commented 1 year ago

I am on the newest commit, and it still freezes.

It downloads the server correctly, but it wouldn't authenticate

wizard-28 commented 1 year ago

Same issue here

pqn commented 1 year ago

@Jxstxs @wizard-28 could you tell me what your OS/[neo]vim version/installation methods are?

Could you describe in what way the auth is failing?

Jxstxs commented 1 year ago

OS: Archlinux

nvim -v: NVIM v0.9.0-dev-461+ged23cd3e5 Build type: RelWithDebInfo LuaJIT 2.1.0-beta3

After the download of the server bin is done, neovim doesn't do anything else, it just stays freezed. I waited 30 Min but nothing happened.

Sorry that this is all, but if I could help any further just ask

Edit: Also, during the download of the server bin, neovim freezes.

meicale commented 1 year ago

I met hanging problem again after I install all the thing once. And I remove all codeium directory and install it again, it just works. I guess the latest version may work.