kubectl-ai icon indicating copy to clipboard operation
kubectl-ai copied to clipboard

Getting intermittent Error 400, API KEY Expired

Open moficodes opened this issue 7 months ago • 3 comments

Device: Macbook Pro M1 OS: Sequioa 15.4.1 version: 0.0.8 model: gemini-2.5-pro-preview-03-25

Error: reading streaming LLM response: Error 400, Message: API key expired. Please renew the API key., Status: INVALID_ARGUMENT, Details: [map[@type:type.googleapis.com/google.rpc.ErrorInfo domain:googleapis.com metadata:map[service:generativelanguage.googleapis.com] reason:API_KEY_INVALID] map[@type:type.googleapis.com/google.rpc.LocalizedMessage locale:en-US message:API key expired. Please renew the API key.]]

I have tested this API key and it works fine generally.

My assumption is its something to do with the rate limit with the free preview model and the error is being caught somewhere else. Could be wrong here.

moficodes avatar May 08 '25 04:05 moficodes

Thanks @moficodes for reporting it.

Is it possible to take a look at /tmp/kubectl-ai.log or share it here.

droot avatar May 08 '25 04:05 droot

Dont have this file. I wonder if this gets deleted after or got created somewhere else.

moficodes avatar May 08 '25 16:05 moficodes

/tmp directory gets deleted (depending on your distribution this varies but usually upon boot) @moficodes please execute the reproduction of the issue and then share/check the contents of the log

zvdy avatar May 08 '25 18:05 zvdy