print debug output

This commit is contained in:
rra 2020-06-17 18:11:57 +02:00
parent 993282fc74
commit 207c5dd49c

View File

@ -172,10 +172,10 @@ def post():
r = requests.post('https://post.lurk.org/inbox', json=json_message, headers=signed_headers)
a = (r.status_code, r.text, r.headers)
a = str(a)
return a
html = f'Status code <pre>{r.status_code}</pre></br>Response Headers: <pre>{r.headers}</pre></br></br> json message: <pre>{json.dumps(json_message)}</pre></br></br> Request headers: <pre>{signed_headers}</pre>'
html_headers = f'<html><head><style>pre {{overflow:auto;background-color:#eee;}}</style></head><body>{html}</body></html>'
return html_headers
if __name__ == '__main__':
app.debug =True