# Path: mistralclient/commands/v2/base.py
# DEFAULT_LIMIT = 100
#     COLUMNS = []
# class MistralFormatter(metaclass=abc.ABCMeta):
# class MistralLister(command.Lister, metaclass=abc.ABCMeta):
# class MistralExecutionLister(MistralLister, metaclass=abc.ABCMeta):
#     def fields(cls):
#     def headings(cls):
#     def format_list(cls, instance=None):
#     def format(instance=None, lister=False):
#     def _get_format_function(self):
#     def get_parser(self, parsed_args):
#     def _get_resources(self, parsed_args):
#     def _validate_parsed_args(self, parsed_args):
#     def take_action(self, parsed_args):
#     def get_parser(self, parsed_args):
#     def take_action(self, parsed_args):
# def cut(string, length=25):
# def wrap(string, width=25):
# def get_filters(parsed_args):
# def get_duration_str(start_dt_str, end_dt_str):
# 
# Path: mistralclient/commands/v2/executions.py
# LOG = logging.getLogger(__name__)
#     COLUMNS = [
#         ('id', 'ID'),
#         ('workflow_id', 'Workflow ID'),
#         ('workflow_name', 'Workflow name'),
#         ('workflow_namespace', 'Workflow namespace'),
#         ('description', 'Description'),
#         ('task_execution_id', 'Task Execution ID'),
#         ('root_execution_id', 'Root Execution ID'),
#         ('state', 'State'),
#         ('state_info', 'State info'),
#         ('created_at', 'Created at'),
#         ('updated_at', 'Updated at'),
#         ('duration', 'Duration', True),
#     ]
# REPORT_ENTRY_INDENT = 4
# class ExecutionFormatter(base.MistralFormatter):
# class List(base.MistralExecutionLister):
# class Get(command.ShowOne):
# class Create(command.ShowOne):
# class Delete(command.Command):
# class Update(command.ShowOne):
# class GetInput(command.Command):
# class GetOutput(command.Command):
# class GetReport(command.Command):
# class GetPublished(command.Command):
# class SubExecutionsBaseLister(cliff_lister):
# class SubExecutionsLister(SubExecutionsBaseLister):
#     def format(wf_ex=None, lister=False):
#     def _get_format_function(self):
#     def get_parser(self, parsed_args):
#     def _get_resources(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def print_line(self, line, level=0):
#     def print_workflow_execution_entry(self, wf_ex, level):
#     def print_task_execution_entry(self, t_ex, level):
#     def print_action_execution_entry(self, a_ex, level):
#     def print_statistics(self, stat):
#     def print_report(self, report_json):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def _get_format_function(self):
#     def _get_resources_function(self):
#     def get_parser(self, prog_name):
#     def _get_resources(self, parsed_args):
#     def take_action(self, parsed_args):
#     def _get_format_function(self):
#     def _get_resources_function(self):
# 
# Path: mistralclient/utils.py
# def do_action_on_many(action, resources, success_msg, error_msg):
# def load_content(content):
# def load_file(path):
# def get_contents_if_file(contents_or_file_name):
# def load_json(input_string):


import logging
import os.path
from oslo_serialization import jsonutils
from osc_lib.command import command
from mistralclient.commands.v2 import base
from mistralclient.commands.v2 import executions
from mistralclient import utils
    def get_parser(self, prog_name):
        parser = super(Rerun, self).get_parser(prog_name)

        parser.add_argument(
            'id',
            help='Task identifier'
        )

        parser.add_argument(
            '--resume',
            action='store_true',
            dest='resume',
            default=False,
            help=('rerun only failed or unstarted action '
                  'executions for with-items task')
        )

        parser.add_argument(
            '-e',
            '--env',
            dest='env',
            help='Environment variables'
        )

        return parser

    def take_action(self, parsed_args):
        mistral_client = self.app.client_manager.workflow_engine

        env = (

# Path: mistralclient/commands/v2/base.py
# DEFAULT_LIMIT = 100
#     COLUMNS = []
# class MistralFormatter(metaclass=abc.ABCMeta):
# class MistralLister(command.Lister, metaclass=abc.ABCMeta):
# class MistralExecutionLister(MistralLister, metaclass=abc.ABCMeta):
#     def fields(cls):
#     def headings(cls):
#     def format_list(cls, instance=None):
#     def format(instance=None, lister=False):
#     def _get_format_function(self):
#     def get_parser(self, parsed_args):
#     def _get_resources(self, parsed_args):
#     def _validate_parsed_args(self, parsed_args):
#     def take_action(self, parsed_args):
#     def get_parser(self, parsed_args):
#     def take_action(self, parsed_args):
# def cut(string, length=25):
# def wrap(string, width=25):
# def get_filters(parsed_args):
# def get_duration_str(start_dt_str, end_dt_str):
# 
# Path: mistralclient/commands/v2/executions.py
# LOG = logging.getLogger(__name__)
#     COLUMNS = [
#         ('id', 'ID'),
#         ('workflow_id', 'Workflow ID'),
#         ('workflow_name', 'Workflow name'),
#         ('workflow_namespace', 'Workflow namespace'),
#         ('description', 'Description'),
#         ('task_execution_id', 'Task Execution ID'),
#         ('root_execution_id', 'Root Execution ID'),
#         ('state', 'State'),
#         ('state_info', 'State info'),
#         ('created_at', 'Created at'),
#         ('updated_at', 'Updated at'),
#         ('duration', 'Duration', True),
#     ]
# REPORT_ENTRY_INDENT = 4
# class ExecutionFormatter(base.MistralFormatter):
# class List(base.MistralExecutionLister):
# class Get(command.ShowOne):
# class Create(command.ShowOne):
# class Delete(command.Command):
# class Update(command.ShowOne):
# class GetInput(command.Command):
# class GetOutput(command.Command):
# class GetReport(command.Command):
# class GetPublished(command.Command):
# class SubExecutionsBaseLister(cliff_lister):
# class SubExecutionsLister(SubExecutionsBaseLister):
#     def format(wf_ex=None, lister=False):
#     def _get_format_function(self):
#     def get_parser(self, parsed_args):
#     def _get_resources(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def print_line(self, line, level=0):
#     def print_workflow_execution_entry(self, wf_ex, level):
#     def print_task_execution_entry(self, t_ex, level):
#     def print_action_execution_entry(self, a_ex, level):
#     def print_statistics(self, stat):
#     def print_report(self, report_json):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def _get_format_function(self):
#     def _get_resources_function(self):
#     def get_parser(self, prog_name):
#     def _get_resources(self, parsed_args):
#     def take_action(self, parsed_args):
#     def _get_format_function(self):
#     def _get_resources_function(self):
# 
# Path: mistralclient/utils.py
# def do_action_on_many(action, resources, success_msg, error_msg):
# def load_content(content):
# def load_file(path):
# def get_contents_if_file(contents_or_file_name):
# def load_json(input_string):


# Path: mistralclient/commands/v2/tasks.py
import logging
import os.path
from oslo_serialization import jsonutils
from osc_lib.command import command
from mistralclient.commands.v2 import base
from mistralclient.commands.v2 import executions
from mistralclient import utils

    def get_parser(self, prog_name):
        parser = super(Rerun, self).get_parser(prog_name)

        parser.add_argument(
            'id',
            help='Task identifier'
        )

        parser.add_argument(
            '--resume',
            action='store_true',
            dest='resume',
            default=False,
            help=('rerun only failed or unstarted action '
                  'executions for with-items task')
        )

        parser.add_argument(
            '-e',
            '--env',
            dest='env',
            help='Environment variables'
        )

        return parser

    def take_action(self, parsed_args):
        mistral_client = self.app.client_manager.workflow_engine

        env = (

            utils.load_file(parsed_args.env)