Exafunction / codeium.nvim

A native neovim extension for Codeium
MIT License
647 stars 50 forks source link

Issue with Codeium Auth #70

Closed ChrisGVE closed 9 months ago

ChrisGVE commented 1 year ago

Using LazyVim config on a Mac and when keying Codeium Auth, Safari is triggered and there is a key generated but on neovim side I receive the following error

Error 19:54:14 msg_show.lua_error Error executing vim.schedule lua callback: ...e/nvim/lazy/codeium.nvim/lua/codeium/views/auth-menu.lua:5: attempt to call field 'inputsecret' (a nil value) stack traceback: ...e/nvim/lazy/codeium.nvim/lua/codeium/views/auth-menu.lua:5: in function 'get_key' ...e/nvim/lazy/codeium.nvim/lua/codeium/views/auth-menu.lua:90: in function 'callback' ...e/nvim/lazy/codeium.nvim/lua/codeium/views/auth-menu.lua:122: in function 'on_choice' ...are/nvim/lazy/dressing.nvim/lua/dressing/select/init.lua:78: in function '' vim/_editor.lua: in function <vim/_editor.lua:0>

I have tried to deactivate dressing.nvim but I get the same problem.

As always I assume an operator error but in this case I am not able to detect/correct what I am doing wrong. Any help would be appreciated

ariel-frischer commented 1 year ago

Had the same error I changed inputsecret to just input and it worked.

ariel-frischer commented 1 year ago

I guess neovim doesn't have vim.ui.inputsecret implemented yet? https://github.com/neovim/neovim/issues/18781

WillEhrendreich commented 1 year ago

i had to switch it to input as well, there's a pr for vim.fn.inputsecret but that also didn't work for me, it wouldn't save the auth

ChrisGVE commented 1 year ago

Thanks guys, indeed replacing inputsecret with input did work for me.

DieracDelta commented 1 year ago

Where are you making the inputsecret to input change?

jellydn commented 1 year ago

This is a workaround until that issue has resolved. I've pinned the version to before that release with below config.

-- Add Codeium support, pin to stable version due to crash on input auth key
      {
        "jcdickinson/codeium.nvim",
        commit = "b1ff0d6c993e3d87a4362d2ccd6c660f7444599f",
        config = true,
      },
pqn commented 9 months ago

I think this is resolved by #74.