我正在尝试导入我的app
函数,它位于front/app __init__
内部,但不知何故from front.app import app
它在^{
.
├── settings
│ ├── settings.json
├── front
│ ├── app
│ │ ├── __init__.py
│ │ ├── __init__.pyc
│ │ ├── __pycache__
│ │ │ ├── __init__.cpython-36.pyc
│ │ │ └── views.cpython-36.pyc
│ │ ├── static
│ │ │ ├── css
│ │ │ │ └── demo.css
│ │ │ ├── data.json
│ │ │ └── js
│ │ │ └── script.js
│ │ ├── templates
│ │ │ └── public
│ │ │ └── index.html
│ │ ├── views.py
│ │ └── views.pyc
│ └── run.py
├── tooler.py
├── __pycache__
│ └── utils.cpython-36.pyc
├── requirements.txt
├── tester.py
├── tree
└── utils.py
run.py
from app import app
if __name__ == "__main__":
app.run()
init
from flask import Flask
app = Flask(__name__)
from app import views
我期望running the server flask
的输出,但实际输出是ModuleNotFoundError: No module named 'app'
目前没有回答
相关问题 更多 >
编程相关推荐