chatgpt-retrieval
chatgpt-retrieval copied to clipboard
ImportError: cannot import name 'URL' from 'sqlalchemy'
Trying to run:
python chatgpt.py "what is my dog's name"
I get:
ImportError: cannot import name 'URL' from 'sqlalchemy' (/Users/brad/anaconda3/lib/python3.11/site-packages/sqlalchemy/__init__.py)
Similar error. I'm getting:
ImportError: cannot import name 'Engine' from 'sqlalchemy' (C:\Users\rafae\AppData\Roaming\Python\Python311\site -packages\sqlalchemy\__init__.py)
try installing sqlalchemy
pip install flask-sqlalchemy
I had a similar issue and when running pip install sqlalchemy
it might simply respond with saying Requirement already satisfied: sqlalchemy
so nothing would change.
For me, this was fixed when, instead, I ran pip install sqlalchemy --upgrade
as it proceeded to initiate downloading the latest version despite the "requirement already satisfied".