From 7071ab0bd907f1c06c9b1dd771580913882220a2 Mon Sep 17 00:00:00 2001 From: Hay1tsme Date: Thu, 2 Mar 2023 00:24:04 -0500 Subject: [PATCH] chuni: add IP logging, clean up logs --- titles/chuni/index.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/titles/chuni/index.py b/titles/chuni/index.py index 25f31b5..a0f8b55 100644 --- a/titles/chuni/index.py +++ b/titles/chuni/index.py @@ -135,7 +135,8 @@ class ChuniServlet(): req_data = json.loads(unzip) - self.logger.info(f"v{version} {endpoint} request - {req_data}") + self.logger.info(f"v{version} {endpoint} request from {request.getClientAddress().host}") + self.logger.debug(req_data) func_to_find = "handle_" + inflection.underscore(endpoint) + "_request" @@ -154,7 +155,7 @@ class ChuniServlet(): if resp == None: resp = {'returnCode': 1} - self.logger.info(f"Response {resp}") + self.logger.debug(f"Response {resp}") zipped = zlib.compress(json.dumps(resp, ensure_ascii=False).encode("utf-8"))