已尝试所有步骤:https://www.ssl2buy.com/wiki/how-to-fix-err-ssl-protocol-error
的数据
代码:https://techwithtim.net/tutorials/flask/a-basic-website/
from flask import Flask
# Defining the home page of our site
app = Flask(__name__)
if __name__ == "__main__":
app.run()
@app.route("/") # this sets the route to this page
def home():
return "Hello! this is the main page <h1>HELLO</h1>" # some basic inline [email protected]("/") # this sets the route to this page
字符串
1条答案
按热度按时间hvvq6cgz1#
代码顺序不对。所有页面/路由都应该在运行应用程序之前定义(app.run())。我认为网站上的视频比你链接的网站更好地解释了这一点。
此外,这个问题与Heroku无关,所以我建议将其从标题中删除。
字符串