pymor.tools.typer

Module Contents

pymor.tools.typer.Choices(choices)[source]

Multiple-choice options for typer.

This is a convenicence function that creates string Enums to be used as the type of command-line arguments that can take a fixed set of values. For example, the command:

@app.command()
def main(arg: Choices('value1 value2')):
    pass

takes one argument that may either have the value value1 or the value value2.