Skip to content

logs

Logging configuration helpers for Rago pipelines.

Classes:

  • Logs

    Attach a mutable log dictionary to a step.

Logs

Logs(target: dict[str, Any] | None = None)

Bases: ParametersBase

Attach a mutable log dictionary to a step.

Methods:

  • apply

    Merge additional configuration into this object.

  • process

    Return the input unchanged for configuration-only objects.

Attributes:

  • params (dict[str, Any]) –

    Expose the underlying parameter mapping.

Source code in src/rago/extensions/logs.py
16
17
def __init__(self, target: dict[str, Any] | None = None) -> None:
    super().__init__(logs=target if target is not None else {})

params property

params: dict[str, Any]

Expose the underlying parameter mapping.

apply

apply(parameters: Any) -> None

Merge additional configuration into this object.

Source code in src/rago/base.py
86
87
88
def apply(self, parameters: Any) -> None:
    """Merge additional configuration into this object."""
    self.data.update(config_to_dict(parameters))

process

process(inp: Input) -> Output

Return the input unchanged for configuration-only objects.

Source code in src/rago/base.py
90
91
92
def process(self, inp: Input) -> Output:
    """Return the input unchanged for configuration-only objects."""
    return inp.to_output()