diff --git a/pwnagotchi/plugins/default/grid.py b/pwnagotchi/plugins/default/grid.py index 5b32635c..d111f9ab 100644 --- a/pwnagotchi/plugins/default/grid.py +++ b/pwnagotchi/plugins/default/grid.py @@ -135,4 +135,4 @@ def on_internet_available(agent): logging.debug("grid: reporting disabled") except Exception as e: - logging.error("grid api: %s" % e) + logging.error("grid api: %s" % e) \ No newline at end of file diff --git a/pwnagotchi/utils.py b/pwnagotchi/utils.py index ab7acfd3..8532ae44 100644 --- a/pwnagotchi/utils.py +++ b/pwnagotchi/utils.py @@ -108,7 +108,10 @@ def setup_logging(args, config): console_handler = logging.StreamHandler() console_handler.setFormatter(formatter) root.addHandler(console_handler) - + # https://stackoverflow.com/questions/24344045/how-can-i-completely-remove-any-logging-from-requests-module-in-python?noredirect=1&lq=1 + requests_log = logging.getLogger("requests") + requests_log.addHandler(logging.NullHandler()) + requests_log.propagate = False def secs_to_hhmmss(secs): mins, secs = divmod(secs, 60)