NTNU-IndEcol / BuildME

6 stars 1 forks source link

Add logging #65

Open CBreton026 opened 2 years ago

CBreton026 commented 2 years ago

This is a tentative logging module for BuildME.

This adds loggers to each file in BuildME/BuildME; the loggers are 'collected' by the logger in main.py, which uses the dictConfig as defined in settings.LOGGING_CONFIG.

For now, it simply collects logging messages and outputs them to the console; it also 'records' any logging.error() in an error log file. This file is "rotating" - two text files of up to 1 MB each can coexist; after that, the older file is deleted.

This is a first step, the logger can be enhanced further to include the features discussed in #61 !

CBreton026 commented 2 years ago

This PR seems to also include "pip install", although I tried to keep those separate... Sorry if this causes any issue, I'm not sure what happened!

nheeren commented 2 years ago

Also here I wonder if a short description in our doc files would make sense? How to configure verbosity, etc.? Or ist that for later?

CBreton026 commented 1 year ago

@nheeren that makes sense! I may have already something written for it, I'll have a look!