flowrep.nodes.helper_models module
- class flowrep.nodes.helper_models.ConditionalCase(**data: Any)[source]
Bases:
BaseModel- body: LabeledRecipe
- condition: LabeledRecipe
- condition_output: base_models.Label | None
- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class flowrep.nodes.helper_models.ExceptionCase(**data: Any)[source]
Bases:
BaseModelAn exception/node pair.
- exceptions
The version info for exception types against which to except.
- Type:
list[pyiron_snippets.versions.VersionInfo]
- body
The node to couple to these exceptions.
Note
In a try-except case, we expect the exception target to always be a type – and more idiomatically a subclass of python’s builtin
BaseException. Here, we don’t explicitly validate that. Usingpyiron_snippets.versions.VersionInfoallows us to ensure that recipes are able to fully specify where exceptions can be found, should a non-builtin exception be used.- body: LabeledRecipe
- exceptions: list[versions.VersionInfo]
- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class flowrep.nodes.helper_models.LabeledRecipe(*, label: Annotated[str, BeforeValidator(func=_validate_label, json_schema_input_type=PydanticUndefined)], node: AtomicRecipe | ForEachRecipe | IfRecipe | TryRecipe | WhileRecipe | WorkflowRecipe)[source]
Bases:
BaseModel- label: base_models.Label
- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- node: RecipeDiscrimination