tzachar / cmp-ai

MIT License
186 stars 33 forks source link

Bard Error: json.choices returns nil instead of table #3

Closed mystilleef closed 1 year ago

mystilleef commented 1 year ago

I'm trying to use the Bard backend with cmp-ai but I'm getting the error in the screenshot below.

Screenshot from 2023-06-20 05-50-43

Just to make sure it's not a problem with my Bard API installation, I can successfully call the Bard API from a Python REPL as you can see in the screenshot below.

Screenshot from 2023-06-20 06-05-12

The culprit seems to be json.choices returning nil instead of a table on line 83 in the bard backend.

Let me know if you need me to provide further details.

tzachar commented 1 year ago

see if its fixed now.

mystilleef commented 1 year ago

It's fixed. However, I can't get any completion suggestions from Bard. Maybe I have to be in the right context for it to work. Back to copilot, lsp, and treesitter for now.

tzachar commented 1 year ago

try to update your api key.

On Wed, Jun 21, 2023 at 12:38 PM Lateef Alabi-Oki @.***> wrote:

It's fixed. However, I can't get any completion suggestions from Bard. Maybe I have to be in the right context for it to work. Back to copilot, lsp, and treesitter for now.

— Reply to this email directly, view it on GitHub https://github.com/tzachar/cmp-ai/issues/3#issuecomment-1600518077, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABFXXC7YBL3WDA3A46IBN23XMK6J3ANCNFSM6AAAAAAZNBZSPY . You are receiving this because you modified the open/close state.Message ID: @.***>