Python Logging across multiple classes and files; how to configure so as to be easily disabled?
- by mellort
Currently, I have osmething like this in all of my classes:
# Import logging to log information
import logging
# Set up the logger
LOG_FILENAME = 'log.txt'
logging.basicConfig(filename=LOG_FILENAME,level=logging.DEBUG)
This works well, and I get the output I want, but I would really like to have all this sort of information in one place, and be…