Skip to content

Commit bf9aa7f

Browse files
committed
chore: refresh spec — Pydantic discriminated unions for auth + check details
Picks up the upstream @devhelm/openapi-tools update that inlines discriminator subtypes and rewrites parents as oneOf+discriminator. The generated Pydantic models now use: type: Literal["bearer"] (and "basic", "header", "api_key") check_type: Literal["http"] (and "tcp", "icmp", "dns", "mcp_server") with `Annotated[Union[...], Field(discriminator="type")]` on the parent union (MonitorAuthConfig and CheckTypeDetailsDto). Pydantic's discriminator-aware union resolution now picks the right subtype in O(1) on validation, vs the previous "try every member, keep the first that parses" fallback that misclassified shape-equivalent subtypes (e.g. BearerAuthConfig vs BasicAuthConfig — both `{vault_secret_id}` only). Spec refresh also propagates the regular field-level fixes from the upstream typing audit. ruff, mypy strict, and pytest (681 tests) pass. Made-with: Cursor
1 parent 52416d2 commit bf9aa7f

2 files changed

Lines changed: 1631 additions & 1528 deletions

File tree

0 commit comments

Comments
 (0)