tavily-ai / tavily-python

A python wrapper for Tavily search API
https://docs.tavily.com
MIT License
112 stars 21 forks source link

ImportError: cannot import name 'TavilyClient' #3

Closed bukosabino closed 7 months ago

bukosabino commented 7 months ago

Hi all,

Congratulations on your work! I play with the search engine and it works really well!

Just an advice, I spent some time with this issue:

$ python tavily.py 
Traceback (most recent call last):
  File "/Users/.../tavily.py", line 3, in <module>
    from tavily import TavilyClient
  File "/Users/.../tavily.py", line 3, in <module>
    from tavily import TavilyClient
ImportError: cannot import name 'TavilyClient' from partially initialized module 'tavily' (most likely due to a circular import) (/Users/.../tavily.py)

I solved the problem by renaming the tavily.py file to whatever name I want!

assafelovic commented 7 months ago

Great @bukosabino . Generally you should consider using a different name than the library. Thanks for sharing!