Open bureyburey opened 10 months ago
Stale issue message
reopening, will take a look at this
Experiencing the same issue here, not sure if my OpenAI api key is not valid for a specific reason, I have a free account at the moment:
$ oco config set OCO_OPENAI_API_KEY="sk-proj-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
┌ opencommit — config
│
└ ✖ Unsupported config key OCO_OPENAI_API_KEY: Must be 51 characters long
If there's a workaround for this, I'd be happy to apply it
Opencommit Version
3.0.4
Node Version
16.18.0
NPM Version
8.9.2
What OS are you seeing the problem on?
Mac
What happened?
A bug happened!
I am unable to set an OpenAI API key with length different than 51 characters due to the validation that checks it. I am using a key which is 65 characters long.
Expected Behavior
Allow setting OpenAI API key with length different from 51 characters.
Current Behavior
The validation prevents setting/using OpenAI API key with length different from 51 characters.
Possible Solution
I've tested it by manually changing the validation rule to accept key that is equal or longer than 51 characters and the OpenAI API did not reject it.
Steps to Reproduce
No response
Relevant log output
No response