flask-restful-api-template icon indicating copy to clipboard operation
flask-restful-api-template copied to clipboard

circular import in users/resource.py

Open zengyee opened this issue 4 years ago • 1 comments

when run the project with following command, got import errors:

python3 app.py -m flask run --host=0.0.0.0

error message:

ImportError: cannot import name 'UsersResource' from partially initialized module 'endpoints.users.resource' (most likely due to a circular import) (/home/jeff/Desktop/flask-restful-api-template-master/endpoints/users/resource.py)

not repro for python3 manage.py runserver

zengyee avatar Apr 29 '20 05:04 zengyee

Same issue as above! @zengyee I created a db.py file initializing db to solve this issue.

kishdubey avatar Jan 03 '21 23:01 kishdubey