Skip to content

Forum in maintenance, we will back soon 🙂

FastAPI: error load...
 
Notifications
Clear all

FastAPI: error loading asgi app. could not import module "app".

3 Posts
2 Users
2 Reactions
159 Views
(@john-joe)
Posts: 10
Eminent Member Customer
Topic starter
 

I'm having trouble running the following command:

uvicorn app:app --reload

Every time I try this command, I get this error:

error: error loading ASGI app. could not import module "app".

I'm stuck and can't figure out the problem.

Here's a screenshot of the error.

Error loading ASGI app. Could not import module app.
 
Posted : 05/05/2024 3:47 pm
SSAdvisor
(@ssadvisor)
Posts: 1139
Noble Member
 

@john-joe do you have a file named app.py with an object named app? Show us the code using a screenshot or preferably a public GitHub repository.

Regards,
Earnie Boyd, CEO
Seasoned Solutions Advisor LLC
Schedule 1-on-1 help
Join me on Slack

 
Posted : 05/05/2024 11:12 pm
(@john-joe)
Posts: 10
Eminent Member Customer
Topic starter
 

@ssadvisor Thank you for your reply. It was my mistake; I was on the wrong folder.

 
Posted : 05/06/2024 6:34 am
Share: