Browse Source

print debug output

master
rra 4 years ago
parent
commit
207c5dd49c
  1. 8
      basic_ap.py

8
basic_ap.py

@ -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

Loading…
Cancel
Save