我的app.yaml当前为错误指定了以下内容。
错误处理程序:
-
文件:templates/error_static.html
在flask框架内,可以根据以下内容指定错误处理程序
@app.errorhandler(400) # Bad Request
@app.errorhandler(401) # Unauthorized
@app.errorhandler(403) # Forbidden
@app.errorhandler(404) # Not Found
@app.errorhandler(405) # Method Not Allowed
@app.errorhandler(410) # Gone
@app.errorhandler(418) # I'm a Teapot
@app.errorhandler(422) # Unprocessable Entity
@app.errorhandler(500) # Internal Server Error
def error_handler(e):
当在app.yaml内指定404时,这是否会取代上述内容?
错误处理程序:
-文件:templates/error_static.html
如果app.yaml指定了通配符路由和404处理程序,是否有理由保留上述内容?