0

I am learning FastApi and while running the code uvicorn main:app --reload inside app directory on cmd below issue occurs

error

My folder structure

is this

I am Stuck in this issue and have no idea what is happening.

Thanks in advance.

azro
  • 53,056
  • 7
  • 34
  • 70
  • Don't do relative import, there's no gain, do absolute import from the root of the package `from app import models` – azro Jul 30 '23 at 08:17
  • Still same issue but saying from app import models ModuleNotFoundError: No module named 'app' – Pratik Sigdel Jul 30 '23 at 08:29

0 Answers0