嗨,伙计们,我在运行烧瓶代码时出错了。我在做Udemy的课程(python mega课程):
下列过帐代码和错误:
代码:
从烧瓶导入烧瓶,呈现模板app=Flask(__name__)
@app.route('/')
def home():
return render_template("home.html")
@app.route('/about/')
def about():
return render_template("about.html")
if __name__=="__main__":
app.run(port=5000, debug=True)
错误:
*使用stat重新启动
出现异常,请使用%tb查看完整的回溯。在
系统出口:1
C:\Users\vinet\Anaconda3\lib\site packages\IPython\core\interactiveshell.py:2889:UserWarning:要退出:请使用“exit”、“quit”或Ctrl-D。
warn(“要退出:使用‘exit’、‘quit’或Ctrl-D.”,stacklevel=1)
完全回溯:
文件“”,第11行,英寸
应用程序运行(主机=“127.0.0.1”,端口=5000,调试=真)
文件“C:\Users\vinet\Anaconda3\lib\site packages\flask\应用程序副本“,第841行,运行中
del\u get_debug,_set_debug
文件“C:\Users\vinet\Anaconda3\lib\site packages\werkzeug\服务.py“,第737行,在run_simple中
服务。在
文件“C:\Users\vinet\Anaconda3\lib\site packages\werkzeug_重载器.py“,第265行,在运行中,有加载器
输入信号
系统出口:1
因为我对烧瓶框架是全新的,任何帮助都可以。在
问候