def get_log_filehandle(context):
    """Open the log and error filehandles.

    Args:
        context (scriptworker.context.Context): the scriptworker context.

    Yields:
        log filehandle

    """
    log_file_name = get_log_filename(context)
    makedirs(context.config['task_log_dir'])
    with open(log_file_name, "w", encoding="utf-8") as filehandle:
        yield filehandle
def get_log_filehandle ( context ) : log_file_name = get_log_filename ( context ) makedirs ( context . config [ 'task_log_dir' ] ) with open ( log_file_name , "w" , encoding = "utf-8" ) as filehandle : yield filehandle
Open the log and error filehandles.

    Args:
        context (scriptworker.context.Context): the scriptworker context.

    Yields:
        log filehandle