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

API Key does not apply on Code-Server #105

Open
AustinM731 opened this issue Nov 3, 2023 · 1 comment
Open

API Key does not apply on Code-Server #105

AustinM731 opened this issue Nov 3, 2023 · 1 comment
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@AustinM731
Copy link

Describe the bug

After adding an OpenAI API key with with the Rubberduck: Enter OpenAI API key command, I get an error stating that I have not yet entered an API key.

Error: Failed after 1 attempt(s) with non-retryable error: 'You didn't provide an API key. You need to provide your API key in an Authorization header using Bearer auth (i.e. Authorization: Bearer YOUR_KEY), or as the password field (with blank username) if you're accessing the API from your browser and are prompted for a username and password. You can obtain an API key from https://platform.openai.com/account/api-keys.'

How to reproduce

Install Code-Server, install Rubber duck extension, enter api key, try to use the chat fuction.

Expected behavior

Rubber Duck extension should be able to communicate with OpenAI API when running in Code-Server.

@AustinM731 AustinM731 added the bug Something isn't working label Nov 3, 2023
@AustinM731
Copy link
Author

After a little more digging into this, I found that the variable for OPEN_AI_API_KEY_SECRET_KEY was not being set or read correctly. Manually exporting this variable with my API key seems to resolve my issue.

Not sure if this is an issue with the plugin, or just a difference in the way that VS Code and Code-Server operate. But it would be very handy if the add API key command would work correctly on Code-Server installs.

@lgrammel lgrammel added the help wanted Extra attention is needed label Nov 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants