Adds debug logging of all request to track possible bugs (stored in file only)

This commit is contained in:
Sergi Delgado Segura
2020-02-17 12:21:53 +01:00
parent defe946b2c
commit 07aa9a73ee

View File

@@ -42,6 +42,9 @@ class API:
logger.info("Received add_appointment request", from_addr="{}".format(remote_addr)) logger.info("Received add_appointment request", from_addr="{}".format(remote_addr))
# FIXME: Logging every request so we can get better understanding of bugs in the alpha
logger.debug("Request details", data="{}".format(request.data))
if request.is_json: if request.is_json:
# Check content type once if properly defined # Check content type once if properly defined
request_data = json.loads(request.get_json()) request_data = json.loads(request.get_json())