mirror of
https://github.com/ZuneDev/PyZuneCommerceServer.git
synced 2026-07-27 13:12:13 -07:00
Return the trace if an exception occurred
This commit is contained in:
@@ -16,6 +16,7 @@ musicbrainzngs.set_useragent("Zune", "4.8", "https://github.com/yoshiask/PyZuneC
|
||||
|
||||
@app.route(f"/v2/<string:locale>/account/signin", methods=['POST'])
|
||||
def account_signin(locale: str):
|
||||
try:
|
||||
print(request.data)
|
||||
signinReq: Document = xml.parseString(request.data.decode('utf-8'))
|
||||
tunerInfo: Element = signinReq.firstChild
|
||||
@@ -31,6 +32,9 @@ def account_signin(locale: str):
|
||||
# doc.appendChild(feed)
|
||||
xml_str = doc.toprettyxml(indent="\t")
|
||||
return Response(xml_str, mimetype=MIME_XML)
|
||||
except Exception as e:
|
||||
import traceback
|
||||
return Response(traceback.format_exc(), status=500, mimetype="text/plain")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
||||
Reference in New Issue
Block a user