RPi: crash while using multi inverters with diff num of strings

- add some comments
- change timestamp format for logging
This commit is contained in:
Knuti_in_Paese 2023-07-20 13:15:30 +02:00
parent 8eef8e2ef4
commit 3ee80c4790

View file

@ -325,7 +325,7 @@ def init_logging(ahoy_config):
lvl = logging.DEBUG
logging.basicConfig(handlers=[RotatingFileHandler(fn, maxBytes=max_log_filesize, backupCount=max_log_files)],
format='%(asctime)s %(levelname)s: %(message)s',
datefmt='%Y-%m-%d %H:%M:%S.%f', level=lvl)
datefmt='%Y-%m-%d %H:%M:%S.%s', level=lvl)
dtu_name = ahoy_config.get('dtu',{}).get('name','hoymiles-dtu')
logging.info(f'start logging for {dtu_name} with level: {logging.getLevelName(logging.root.level)}')