我正在尝试部署一个简单的 Web 应用程序,并且正在使用命令行waitress-serve --call命令。但每次,命令都会立即返回1. Malformed application 'name_of_project_here'。
这是我用 python 编写的 Flask Web 应用程序:
from flask import Flask, render_template
app = Flask(__name__)
@app.route('/')
def index():
return render_template('base.html')
if __name__ == '__main__':
app.run(debug = True)
Run Code Online (Sandbox Code Playgroud)
我运行的命令只是
waitress-serve --call "name_of_project"
Run Code Online (Sandbox Code Playgroud)
我确实尝试查看文档,找到了错误发生的位置,但找不到发生错误的原因的解释。格式错误的申请是什么意思?
我正在尝试将通知优先级设置为,如此处HIGH文档中所述和此处定义的特定参数。但是,当我在云函数中设置此属性时,尝试部署时出现以下错误:
src/index.ts:107:35 - error TS2345: Argument of type '{ tokens: string[]; notification: { title: string; body: any; }; data: { title: any; subtitle: any; body: any; id: any; }; android: { notification: { icon: string; channel_id: string; tag: any; }; priority: string; }; }' is not assignable to parameter of type 'MulticastMessage'.
The types of 'android.priority' are incompatible between these types.
Type 'string' is not assignable to type '"normal" | "high" | undefined'.
107 admin.messaging().sendMulticast(message) …Run Code Online (Sandbox Code Playgroud)