thoth.adviser.prescription package

Subpackages

Module contents

Prescription module implementation.

class thoth.adviser.prescription.Prescription(*, prescriptions: List[Tuple[str, str]] = NOTHING, boots_dict: Dict[str, Dict[str, Any]] = NOTHING, pseudonyms_dict: Dict[str, Dict[str, Any]] = NOTHING, sieves_dict: Dict[str, Dict[str, Any]] = NOTHING, steps_dict: Dict[str, Dict[str, Any]] = NOTHING, strides_dict: Dict[str, Dict[str, Any]] = NOTHING, wraps_dict: Dict[str, Dict[str, Any]] = NOTHING)[source]

Bases: object

Dynamically create pipeline units based on inscription.

boots_dict
classmethod from_dict(prescription: Dict[str, Any], *, prescription_instance: Optional[Prescription] = None) → thoth.adviser.prescription.v1.prescription.Prescription[source]

Instantiate prescription from a dictionary representation.

If an instance is provided, a safe merge will be performed.

iter_boot_units() → Generator[Type[BootType], None, None][source]

Iterate over prescription boot units registered in the prescription supplied.

iter_pseudonym_units() → Generator[Type[PseudonymType], None, None][source]

Iterate over prescription pseudonym units registered in the prescription supplied.

iter_sieve_units() → Generator[Type[SieveType], None, None][source]

Iterate over prescription sieve units registered in the prescription supplied.

iter_step_units() → Generator[Type[StepType], None, None][source]

Iterate over prescription step units registered in the prescription supplied.

iter_stride_units() → Generator[Type[StrideType], None, None][source]

Iterate over prescription stride units registered in the prescription supplied.

iter_wrap_units() → Generator[Type[WrapType], None, None][source]

Iterate over prescription stride units registered in the prescription supplied.

classmethod load(*prescriptions: str) → thoth.adviser.prescription.v1.prescription.Prescription[source]

Load prescription from files or from their YAML representation.

prescriptions
pseudonyms_dict
sieves_dict
steps_dict
strides_dict
classmethod validate(prescription: Dict[str, Any]) → None[source]

Validate the given prescription.

wraps_dict