Document configure_debug_logging

This commit is contained in:
James R. Barlow
2020-11-02 00:59:00 -08:00
parent a354663ee1
commit 664d0c7969
+8 -1
View File
@@ -307,7 +307,14 @@ class NeverRaise(Exception):
pass # pylint: disable=unnecessary-pass
def configure_debug_logging(log_filename, prefix=''):
def configure_debug_logging(log_filename, prefix: str = ''):
"""
Create a debug log file at a specified location.
Arguments:
log_filename: Where to the put the log file.
prefix: The logging domain prefix that should be sent to the log.
"""
log_file_handler = logging.FileHandler(log_filename, delay=True)
log_file_handler.setLevel(logging.DEBUG)
formatter = logging.Formatter(