updog-logging_template/logging_template.py
2024-01-31 18:22:20 -06:00

7 lines
284 B
Python

class LoggingTemplate:
# there's no close() and that might cause some issues
def __init__(self, arguments):
self.log_file = open(arguments['file'], 'wt')
def log(self, service_name, code, status):
self.log_file.write(f'{service_name} {code}: {status}\n')