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

Error: Can't open ChatGPT #465

Open
revoltez opened this issue Sep 11, 2024 · 5 comments
Open

Error: Can't open ChatGPT #465

revoltez opened this issue Sep 11, 2024 · 5 comments

Comments

@revoltez
Copy link

when typing :ChatGPT then pressing enter, it gives the following error:

Error executing Lua callback: ...acker/start/ChatGPT.nvim/lua/chatgpt/flows/chat/base.lua:52: attempt to index field 'popup_layout' (a nil value)
stack traceback:
        ...acker/start/ChatGPT.nvim/lua/chatgpt/flows/chat/base.lua:52: in function 'init'
        ...packer/start/ChatGPT.nvim/lua/chatgpt/common/classes.lua:88: in function 'new'
        ...acker/start/ChatGPT.nvim/lua/chatgpt/flows/chat/init.lua:13: in function 'open_chat'
        ...nvim/site/pack/packer/start/ChatGPT.nvim/lua/chatgpt.lua:34: in function 'openChat'
        ...m/site/pack/packer/start/ChatGPT.nvim/plugin/chatgpt.lua:2: in function <...m/site/pack/packer/start/ChatGPT.nvim/plugin/chatgpt.lua:1>

this is my current configuration with packer:

local home = vim.fn.expand("$HOME")
return require('packer').startup(function(use)
  use 'wbthomason/packer.nvim'
use({
  "jackMort/ChatGPT.nvim",
    config = function()
	require("chatgpt").setup({
		api_key_cmd = "echo 'my_key'"
	})
    end,
    requires = {
      "MunifTanjim/nui.nvim",
      "folke/trouble.nvim",
      "nvim-telescope/telescope.nvim",
      "nvim-lua/plenary.nvim",
    }
})

  if packer_bootstrap then
    require('packer').sync()
  end
end)

EOF
@Malikazz
Copy link

Malikazz commented Sep 20, 2024

Same issue for me fresh install today running in Windows 11, Terminal

use({
            "jackMort/ChatGPT.nvim",
            config = function()
                require("chatgpt").setup()
            end,
            requires = {
                "MunifTanjim/nui.nvim",
                "nvim-lua/plenary.nvim",
                "folke/trouble.nvim",
                "nvim-telescope/telescope.nvim"
            }
        })

@Malikazz
Copy link

Does anyone have an idea on this issue here happy to try and do some debugging. I tried just hard coding the value for that param but new issues appear to do with a shallow copy of the values.

@revoltez
Copy link
Author

@Malikazz I think this project is dead

@Malikazz
Copy link

It's not dead lol it just open source and others don't have this issue. If you want it fixed then do what I am trying to do and spend some time debugging. The nvim state is odd though so I am unclear on why the state is buggy atm after trying a few things.

@revoltez
Copy link
Author

@Malikazz dead in the sense the author is not resolving issues, i can spend time debugging it or i can save it and use https://github.com/yetone/avante.nvim

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

No branches or pull requests

2 participants