pinecone-io / pinecone-python-client

The Pinecone Python client
https://www.pinecone.io/docs
Apache License 2.0
304 stars 79 forks source link

[Bug] Cant initialize Pinecone class because it says it doesn't have an api_key argument #300

Closed juanccontreras8 closed 6 months ago

juanccontreras8 commented 9 months ago

Is this a new bug in the Pinecone Python client?

Current Behavior

Pinecone(api_key = ) isn't initializing

Expected Behavior

Class should initialize

Steps To Reproduce

from pinecone import Pinecone

pc = Pinecone(api_key=os.environ.get('PINECONE_API_KEY'))

Relevant log output

TypeError: Pinecone.__init__() got an unexpected keyword argument 'api_key'

Environment

- OS: Windows 11
- Python:3.10.0
- pinecone: 3.0.1

Additional Context

No response

ranjanbatra3pg commented 9 months ago

Same is happening with me.

UmairAhmadBaltoro commented 8 months ago
TypeError: Pinecone.__init__() got an unexpected keyword argument 'api_key'
[2024-02-12 16:16:51,898] ERROR in polling_thread: Error in polling thread: Pinecone.__init__() got an unexpected keyword argument 'api_key'
ranjanbatra3pg commented 8 months ago

I found out what was causing the error on my side. Double check imports - make sure there is no duplicate imports. I had an import: from langchain.vectorstores import Pinecone

UmairAhmadBaltoro commented 8 months ago

Thanks. @ranjanbatra3pg I also had the same issue. now fixed..