in2lambda.defaults.fillΒΆ

in2lambda.defaults.fill(obj: Any, section: str, response_type: str | None = None) → None[source]ΒΆ

Sets each of an object’s unset fields to its default.

Parameters:
  • obj – A dataclass instance.

  • section – Its table in the defaults.

  • response_type – For a response area, its type, whose own table comes first.

Raises:

TypeError – A field has no default, or the defaults give it a value of the wrong type.