URGENT: Pinecone API Updated?

Getting this error since Wednesday at 00:00 UTC:

Error: Error getting Pinecone index: Failed to connect to Pinecone's controller on region us-west1-gcp. Please verify client configuration: API key, region and project_id. See more info: https://docs.pinecone.io/docs/quickstart#2-get-and-verify-your-pinecone-api-key
Underlying Error: error decoding response body: invalid type: null, expected a string at line 1 column 42

Was the Pinecone API updated in a non-backwards-compatible way?

Hi @arvid. Which SDK and what version of it are you using?

I am seeing a similar issue in region us-east-1-aws:

  File "/app/datastore/pinecone.py", line 25, in __init__
    self._client = Client(api_key=self._api_key, region=self._region)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: `Failed to retrieve the user's project_id using `GET /actions/whoami`. Please verify the API key is correct`

We have tested multiple API keys with multiple instances in different projects. We are using pinecone-client = “3.0.0rc2”.

We’re using this one: GitHub - pinecone-io/pinecone-client

Any chance you could just revert the most recent deployment? Would be super helpful. Our service is down because of this.

If not, would be super helpful to know what changed, so we can patch it on our end.

Just to be clear @arvid , are you using the latest version of that client? Should be 2.2.4.

@anita I’m not sure your error is related to what Arvid is reporting. Did this behavior just start for you, as well? And was your code working as-is previously?

1 Like

A post was merged into an existing topic: Cannot connect to indexes: error get project_id using GET /actions/whoami

Hmmm I believe it is version 3.0.0.

We’re just using the GitHub repo.

@arvid and @anita, can you upgrade to the latest RC? It was just published yesterday but isn’t reflected in the install instructions in the Github repo. You can install with:

pip3 install pinecone-client==3.0.0rc3

RC2 is from last March and is pretty out of date. RC3 has a number of improvements over it.

Could you push the latest version to the GitHub? We are using the Rust version.

@arvid sorry I’m not sure what you mean, RC3 of the client was published on PyPi last night and can be installed via pip. That’s the recommended way to install the Python client.

Our code is in Rust, not Python, so we cannot use the Python version. Could you publish the underlying Rust code too?

Any way we could hop on a call?

1 Like

Oh hmmm, looks like RC3 is in pure Python…

Would love some creative solution here! Maybe you could spin up a new version of the old deployment at a new URL, that we can point to? Our users cannot use a very popular feature after this change, and it will take us a while to refactor all of our code.

I’ll DM you a Zoom link.

3 Likes

Do you have documentation on what is needed after upgrading to 3.0.0.rc3? It looks like we need to make quite a few code changes.

Just to follow up on this, @anita we found the underlying issue and have an immediate workaround you can use.

In your connect call, you want to add a third parameter: project_id. This is normally an optional parameter, but adding it means you don’t have to make the call to /actions/whoami, which is the part that’s failing here.

So your new connection string would look like:

client = pinecone.Client(api_key=YOUR_API_KEY,region=YOUR_REGION,project_id=YOUR_PROJECT_ID)

You can get your project ID from the console. Just click Settings->Projects, and copy the seven-character string for the project you’re working with.

3 Likes