# Python client warning: Passing openapi\_config is deprecated and will be removed in a future release

**URL:** <https://community.pinecone.io/t/python-client-warning-passing-openapi-config-is-deprecated-and-will-be-removed-in-a-future-release/5004>\
**Category:** Support\
**Tags:** serverless\
**Created:** [March 27, 2024, 7:11pm UTC](https://community.pinecone.io/t/python-client-warning-passing-openapi-config-is-deprecated-and-will-be-removed-in-a-future-release/5004 "2024-03-27T19:11:37Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![riku](https://sea2.discourse-cdn.com/flex020/user_avatar/community.pinecone.io/riku/32/830_2.png) [@riku](https://community.pinecone.io/u/riku)\
**Post date:** [March 27, 2024, 7:11pm UTC](https://community.pinecone.io/t/python-client-warning-passing-openapi-config-is-deprecated-and-will-be-removed-in-a-future-release/5004/1 "2024-03-27T19:11:37Z")

</div>

pinecone-client version: 3.2.1  
Index type: Serverless

We just started a PoC to see if Pinecone Serverless will meet our needs for our semantic search needs and are going through the quickstart.

Upon creating a new index, the python client shows the following warning:

warnings.warn(“Passing openapi\_config is deprecated and will be removed in a future release. Please pass settings such as proxy\_url, proxy\_headers, ssl\_ca\_certs, and ssl\_verify directly to the Pinecone constructor as keyword arguments. See the README at [GitHub - pinecone-io/pinecone-python-client: The Pinecone Python client](https://github.com/pinecone-io/pinecone-python-client) for examples.”, DeprecationWarning)

The initialization code is mostly straight out from the quickstart.  
Code snippet:

```auto
pinecone = Pinecone(api_key=os.getenv('PINECONE_API_KEY'))

pinecone.create_index(
    name=index_name,
    dimension=dimension,
    metric="euclidean",
    spec=ServerlessSpec(
        cloud='aws', 
        region='us-east-1'
    ) 
) 
index = pinecone.Index(name=index_name)

```

It is very odd, as

- We are not passing openapi\_config arg
- Looks like the client is automatically setting openapi\_config. For example, if I try to pass index = pinecone.Index(name=index\_name, openapi\_config=None), it complains that there are duplicate values for openapi\_config.

Does anyone have the same issue?  
How could I suppress the client auto-setting openapi\_config?

---

<div class="post-metadata">

**Author:** ![jhamon](https://sea2.discourse-cdn.com/flex020/user_avatar/community.pinecone.io/jhamon/32/1306_2.png) [@jhamon](https://community.pinecone.io/u/jhamon)\
**Post date:** [March 27, 2024, 7:26pm UTC](https://community.pinecone.io/t/python-client-warning-passing-openapi-config-is-deprecated-and-will-be-removed-in-a-future-release/5004/2 "2024-03-27T19:26:10Z")

</div>

Hi, I work on the python sdk. 👋

This definitely seems like a bug, so you have my apologies. This warning was introduced late last week in [this release](https://github.com/pinecone-io/pinecone-python-client/releases/tag/v3.2.0) alongside new properties for custom proxy configuration. But you’re right that it’s not appropriate in this instance.

Until I ship a fix, you can safely ignore the warning. Or if you don’t want to see it at all, I think it can be suppressed by putting something like this into the startup for your application or script:

```auto
import warnings

warnings.filterwarnings("ignore", category=DeprecationWarning, module="pinecone")

```

I’ll try to get a fix out soon clearing up this issue.

---

<div class="post-metadata">

**Author:** ![riku](https://sea2.discourse-cdn.com/flex020/user_avatar/community.pinecone.io/riku/32/830_2.png) [@riku](https://community.pinecone.io/u/riku)\
**Post date:** [March 27, 2024, 7:37pm UTC](https://community.pinecone.io/t/python-client-warning-passing-openapi-config-is-deprecated-and-will-be-removed-in-a-future-release/5004/3 "2024-03-27T19:37:46Z")

</div>

Awesome, thanks for your quick reply!  
Looking forward to the fix:)

---

<div class="post-metadata">

**Author:** ![jhamon](https://sea2.discourse-cdn.com/flex020/user_avatar/community.pinecone.io/jhamon/32/1306_2.png) [@jhamon](https://community.pinecone.io/u/jhamon)\
**Post date:** [March 30, 2024, 12:01am UTC](https://community.pinecone.io/t/python-client-warning-passing-openapi-config-is-deprecated-and-will-be-removed-in-a-future-release/5004/4 "2024-03-30T00:01:43Z")

</div>

I just shipped a [v3.2.2](https://github.com/pinecone-io/pinecone-python-client/releases/tag/v3.2.2) release which I believe should take care of this issue. Thanks for reporting!
