Closed Allaman closed 1 year ago
Maybe related to https://github.com/jackMort/ChatGPT.nvim/issues/265 ?
Maybe related to #265 ?
They are definitely related as the issue starts occurring with that same commit. However, it does seem like a default of "api.openai.com" is passed at least if you don't provide the host, so I don't think that's the cause of the error :(
I'm suddenly having the same error as well.
The following commit works:
{
"jackMort/ChatGPT.nvim",
commit = "2107f7037c775bf0b9bff9015eed68929fcf493e",
event = "VeryLazy",
dependencies = {
"MunifTanjim/nui.nvim",
"nvim-lua/plenary.nvim",
"nvim-telescope/telescope.nvim",
},
},
just edit your .bashrc/.zshrc and add:
export OPENAI_API_HOST="api.openai.com"
also looks like a typo in README.md: or environment variable called $OPEN_API_HOST
I would prefer to avoid adding yet another environment variable OPENAI_API_HOST. How can I achieve the equivalent by setting api_host_cmd ?
Good, it is OPENAI_API_HOST, and not OPEN_AI_HOST
just edit your .bashrc/.zshrc and add:
export OPENAI_API_HOST="api.openai.com"
Sure, but don't you think that this is redundant? The README states that this variable is
... useful if you can't access OpenAI driectly
IMO, a default setting should not need a configuration nor cause a warning.
I would prefer to avoid adding yet another environment variable OPENAI_API_HOST. How can I achieve the equivalent by setting api_host_cmd ?
@teto Something like this should work api_host_cmd = "echo -n 'api.openai.com'"
. Adjust to the correct address!
As the title suggests, it would be cool if the warning is not displayed when there is no need to change the API host