【发布时间】:2022-01-15 15:32:20
【问题描述】:
我目前在 cs50 的第 9 周工作,我对 vscode web 中的烧瓶有点困惑。 如果我运行这段代码:
from flask import Flask, render_template, request
app = Flask(__name__)
@app.route("hello")
def index():
return render_template("index.html", name=request.args.get("name"))
在带有“flask run”的 vscode 中并点击链接我收到错误“Bad request 400”
{"type":"https://tools.ietf.org/html/rfc7231#section-6.5.1","title":"Bad
Request","status":400,"traceId":"|e2de7987-46bd8bcf98f5f413."}
但是如果我在 cs50ide 中以相同的方式运行相同的代码,它就可以正常工作
我真的很想使用 vscode。 所以如果有人可以帮助我,那就太好了
【问题讨论】: