tortoise / tortoise-orm

Familiar asyncio ORM for python, built with relations in mind
https://tortoise.github.io
Apache License 2.0
4.63k stars 385 forks source link

ModuleNotFoundError: No module named 'tortoise' #1414

Open pysaundary opened 1 year ago

pysaundary commented 1 year ago

Describe the bug Getting error :from tortoise.contrib.fastapi import HTTPNotFoundError, register_tortoise ModuleNotFoundError: No module named 'tortoise'

but i already installed it in venv , first i was using python3.11, then I downgrade my Python and use python3.10 but i get the same error both time, after that i also checked may be some problems in my both Python so i comment out all tortoise code and try to run fastapi , its run successfully

Expected behavior A clear and concise description of what you expected to happen.

Additional context Add any other context about the problem here. requirements.py aiosqlite==0.17.0 anyio==3.7.0 fastapi==0.98.0 idna==3.4 iso8601==1.1.0 pydantic==1.10.9 pypika-tortoise==0.1.6 pytz==2023.3 sniffio==1.3.0 starlette==0.27.0 tortoise-orm==0.19.3 typing_extensions==4.7.0

Os Ubuntu 22.04

error: from tortoise.contrib.fastapi import HTTPNotFoundError, register_tortoise ModuleNotFoundError: No module named 'tortoise'

danbigthink commented 1 year ago

I saw a post somewhere that suggested downgrading to python 3.8 can help