Skip to content

taps.apps

App

Bases: Protocol

Application protocol.

run

run(engine: Engine, run_dir: Path) -> None

Run the application.

Source code in taps/apps/_protocol.py
def run(
    self,
    engine: Engine,
    run_dir: pathlib.Path,
) -> None:
    """Run the application."""
    ...

close

close() -> None

Close the application.

Source code in taps/apps/_protocol.py
def close(self) -> None:
    """Close the application."""
    ...

AppConfig

Bases: BaseModel, ABC

Application config protocol.

Application configs must define the create_app() method.

After instantiation, all pathlib.Path types will be resolved to convert them to absolute paths.

Parameters:

  • name (str) –

get_app abstractmethod

get_app() -> App

Initialize an app instance from this config.

Source code in taps/apps/_protocol.py
@abc.abstractmethod
def get_app(self) -> App:
    """Initialize an app instance from this config."""
    ...