(cls, args)
A hook called before the task is initialized.
A hook called before the task is initialized.
A hook called before the task is initialized .
def pre_init_hook(cls, args):
        """A hook called before the task is initialized."""
        if args.log_format == 'json':
            log_manager.format_json()
            # we're mutating the initialized, but not-yet-configured event logger
            # because it's being configured too late -- bad! TODO refactor!
            event_logger.format_json = True
        else:
            log_manager.format_text()
def pre_init_hook ( cls , args ) : if args . log_format == 'json' : log_manager . format_json ( ) # we're mutating the initialized, but not-yet-configured event logger # because it's being configured too late -- bad! TODO refactor! event_logger . format_json = True else : log_manager . format_text ( )