*** pinecone.core.client.exceptions.PineconeException: UNKNOWN:Error received from peer {grpc_message:"No explicit ids expected when delete_all=true", grpc_status:3, created_time:"202"}
I’m not providing any vector IDs though, just the namespace as is specified in the docs.
Hi @steven and welcome to the Pinecone community forums!
Thank you for your question.
Could you please share all your relevant code, being careful not to include secrets like your Pinecone API key, including where you installed the Pinecone library?
The code flow that I’m currently using first uses random vectors to query the index and retrieve all vectors for each namespace in the index (I can’t use index.list because it’s not serverless). I’m essentially using a dictionary that looks like {namespace: {vectors}}.
The code for deletion looks like this:
for namespace in namespace2vectors:
index.delete(namespace=namespace, delete_all=True)
Note, when I change to code to provide the actual vector IDs the deletion happens properly:
for namespace, vectors in namespace2vectors.items():
ids = list(vectors)
index.delete(ids=ids, namespace=namespace)
I’m currently using a Poetry environment to manage my packages. The relevant packages are as follows:
@steven, yes, that’s understood. To debug the issue, I hope to see the values of namespace that get extracted from namespace2vectors, or just the complete namespace2vectors object.
If you do not feel comfortable sharing the namespace2vectors with the actual names, you can omit the details. I am curious to see the structure of the stored object. We likely need to improve our error messaging in some fashion, but I first want to determine the root cause of the behavior.
Each vector is itself a mapping from a unique string ID to a dictionary consisting of the two keys "values" and "metadata", and each namepace has many of these vectors. The values are lists of floating point numbers.
Thanks, @steven. I’ve just spent some time testing the below code with namespace2vectors set to a dictionary of the object structure you specified and have not been able to reproduce the issue.
for namespace in namespace2vectors:
print(namespace)
index.delete(namespace=namespace, delete_all=True)
For reference, here is the original error statement you shared:
*** pinecone.core.client.exceptions.PineconeException: UNKNOWN:Error received from peer {grpc_message:"No explicit ids expected when delete_all=true", grpc_status:3, created_time:"202"}
If you can still reproduce this error consistently, please insert the print statement as shown in the above code and share the output, along with the name of the index on which you perform these actions.