Function
_validate_closed_range
(name: str, values: tuple[float, float])
Source from the content-addressed store, hash-verified
| 246 | |
| 247 | |
| 248 | def _validate_closed_range(name: str, values: tuple[float, float]) -> None: |
| 249 | if len(values) != 2: |
| 250 | raise ValueError(f"{name} must contain exactly two values.") |
| 251 | low = float(values[0]) |
| 252 | high = float(values[1]) |
| 253 | if high < low: |
| 254 | raise ValueError(f"{name} must satisfy min <= max.") |
| 255 | |
| 256 | |
| 257 | def _build_instance_id(*, semantic_name: str, occurrence: int, salt: str) -> str: |
Tested by
no test coverage detected