fd.close()
# TODO write logs (need to collect some statistics)
- logstr = datetime.now().strftime('%Y-%m-%d %H:%M') + ' %s %s\n'
+ logstr = datetime.now().strftime('%d/%b/%Y:%H:%M:%S') + ' %s %s\n'
fd = open(LOGFILE, 'a')
if unblocked:
fd.write(logstr % ('unblocked:', ', '.join(unblocked)))
if blocked:
fd.write(logstr % ('new block:', ', '.join(blocked)))
for k,v in stats.items():
- if v.ignores_warnings() and k not in notlogged:
+ if v.ignores_warnings() and k not in notlogged and ':' not in k:
fd.write(logstr % ('Warning ignored:', k))
fd.close()