PineconeApiTypeError when listing vectors from Pod index

The issue happens only for an Index created as S1 Pod. With my serverless indexes it works ok.
Tested with pinecone-client 3.2.2 and 4.0.0, Python 3.12.
Here’s my code:

from pinecone import Pinecone
l = idx.list(prefix="LALALA")


Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/venv/lib/python3.12/site-packages/pinecone/data/", line 571, in list
    results = self.list_paginated(**kwargs)
  File "/venv/lib/python3.12/site-packages/pinecone/utils/", line 10, in inner_func
    return func(*args, **kwargs)
  File "/venv/lib/python3.12/site-packages/pinecone/data/", line 545, in list_paginated
    return self._vector_api.list(**args_dict, **kwargs)
  File "/venv/lib/python3.12/site-packages/pinecone/core/client/", line 772, in __call__
    return self.callable(self, *args, **kwargs)
  File "/venv/lib/python3.12/site-packages/pinecone/core/client/api/", line 712, in __list
    return self.call_with_http_info(**kwargs)
  File "/venv/lib/python3.12/site-packages/pinecone/core/client/", line 834, in call_with_http_info
    return self.api_client.call_api(
  File "/venv/lib/python3.12/site-packages/pinecone/core/client/", line 409, in call_api
    return self.__call_api(resource_path, method,
  File "/venv/lib/python3.12/site-packages/pinecone/core/client/", line 224, in __call_api
    return_data = self.deserialize(
  File "/venv/lib/python3.12/site-packages/pinecone/core/client/", line 325, in deserialize
    deserialized_data = validate_and_convert_types(
  File "/venv/lib/python3.12/site-packages/pinecone/core/client/", line 1539, in validate_and_convert_types
    converted_instance = attempt_convert_item(
  File "/venv/lib/python3.12/site-packages/pinecone/core/client/", line 1421, in attempt_convert_item
    raise get_type_error(input_value, path_to_item, valid_classes,
pinecone.core.client.exceptions.PineconeApiTypeError: Invalid type for variable 'received_data'. Required value type is ListResponse and passed type was str at ['received_data']

Hello @maciej.pocwierz,

Pod base indexes do not support the list operation. It’s noted in the API reference.

What are you trying to do with the list? Maybe I can recommend a different approach.

1 Like

Thanks, I missed that.

My issue is that when I’m vectorizing my documents some of them can be processed twice and I want to avoid duplicates.

My vector ids are like DOCUMENT_ID#CHUNK_ID so theoretically there should never be duplicates, as they would get overriden.

The problem is, my my chunking logic is based on machine learning, so I don’t think it’s fully deterministic, due to things like precision etc.

So to be sure that I don’t end up with duplicates, I’d rather explicitly delete all vectors for prefix DOCUMENT_ID# before indexing that document.

Is there a way to accomplish this without list operation?