I have a BASE_DIR setting in my settings.py file:
BASE_DIR = os.path.dirname(os.path.abspath(__file__))
I need to use this variable in my logging.ini file to setup my file handler paths.
The initialization of logging happens in the same file, the settings.py file, below my BASE_DIR variable. Here I tell it the path of my logging.ini file:
LOG_INIT_DONE=False
if not LOG_INIT_DONE:
logging.config.fileConfig(LOGGING_INI)
LOG_INIT_DONE=True
I noticed fileConfig can take a default parameter. I'm not sure if this is what I'm looking for, but I can't seem to find any documentation on how to use this parameter.
Thanks, Pete