From 748c877484b0dd2b4f890fe691c7ff1db8607ca7 Mon Sep 17 00:00:00 2001 From: Evan Shortiss Date: Thu, 12 Oct 2023 10:13:05 -0700 Subject: [PATCH] fix: use builtin logger --- roshambo-ai/wsgi.py | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/roshambo-ai/wsgi.py b/roshambo-ai/wsgi.py index 62a584b..32273f6 100644 --- a/roshambo-ai/wsgi.py +++ b/roshambo-ai/wsgi.py @@ -5,20 +5,12 @@ from flask import Flask, jsonify, request from prediction import predict -log_level = os.getenv("LOG_LEVEL", "INFO").upper() - application = Flask(__name__) -formatter = logging.Formatter('%(asctime)s - %(levelname)s - %(message)s') -handler = logging.StreamHandler() -handler.setFormatter(formatter) -application.logger.addHandler(handler) -application.logger.setLevel(log_level) - @application.route('/') @application.route('/status') def status(): - logging.debug('responding OK to /status check') + application.logger.debug('responding OK to /status check') return jsonify({'status': 'ok'})