get_universe_from_context¶
- lsst.daf.butler.pydantic_utils.get_universe_from_context(context: dict[str, Any] | None) DimensionUniverse ¶
Extract the dimension universe from a Pydantic validation context dictionary.
- Parameters:
- context
dict
Dictionary obtained from
pydantic.ValidationInfo.context
.
- context
- Returns:
- universe
DimensionUniverse
Definitions for all dimensions.
- universe
Notes
This function just provides consistent error handling around:
context["universe"]