【发布时间】:2018-06-16 23:18:31
【问题描述】:
所以,每当我尝试连接到我的 python 应用程序时,它都会崩溃并出现以下错误:
2018-06-16T22:59:44.633397+00:00 app[web.1]: from flask import
Markup
2018-06-16T22:59:44.633403+00:00 app[web.1]: File
"/app/.heroku/python/lib/python2.7/site-packages/flask/__init__.py",
line 30, in <module>
2018-06-16T22:59:44.633405+00:00 app[web.1]: from .blueprints
import Blueprint
2018-06-16T22:59:44.633415+00:00 app[web.1]: File
"/app/.heroku/python/lib/python2.7/site-packages/flask/blueprints.py",
line 13, in <module>
2018-06-16T22:59:44.729487+00:00 heroku[web.1]: State changed from
starting to crashed
2018-06-16T22:59:44.633417+00:00 app[web.1]: from werkzeug.urls
import url_join
2018-06-16T22:59:44.633419+00:00 app[web.1]: ImportError: cannot
import name url_join
2018-06-16T22:59:44.714734+00:00 heroku[web.1]: Process exited with
status 1
2018-06-16T22:59:45.682717+00:00 heroku[router]: at=error code=H10
desc="App crashed" method=GET path="/" host=snowfin.herokuapp.com
request_id=0488bd20-cdf7-4f39-9665-31038b8833a9 fwd="199.192.192.168"
dyno= connect= service= status=503 bytes= protocol=https
2018-06-16T22:59:46.227743+00:00 heroku[router]: at=error code=H10
desc="App crashed" method=GET path="/favicon.ico"
host=snowfin.herokuapp.com request_id=f78f7452-0266-4683-b2cb-
fa26e8439c69 fwd="199.192.192.168" dyno= connect= service= status=503
bytes= protocol=https
我正在使用 python 2.7.15,如果需要可以提供更多信息。谢谢大家!
【问题讨论】:
-
我不完全确定,但我认为 heroku 使用 python3,这可能是导致问题的原因吗?
-
我在 runtime.txt 中声明使用 python 2.7.15 并且在构建时没有给出任何错误。所以...
标签: python heroku flask deployment werkzeug