Skip to content

fix: null values in schema enums in OpenAPI 3 examples#195

Merged
codekie merged 1 commit into
codekie:mainfrom
JoshFerge:jferg/fix-null-example
Apr 13, 2025
Merged

fix: null values in schema enums in OpenAPI 3 examples#195
codekie merged 1 commit into
codekie:mainfrom
JoshFerge:jferg/fix-null-example

Conversation

@JoshFerge
Copy link
Copy Markdown
Contributor

tfranzel/drf-spectacular#235 (comment)

Having null in the enum is valid OpenAPI spec, but the examples validator currently fails if an example enum contains null and --no-additional-properties is set to true.

We implement a small fix, and a test for it.

our upstream PR that depends on this: getsentry/sentry#88370

@codekie
Copy link
Copy Markdown
Owner

codekie commented Apr 13, 2025

LGTM. Thanks for your contribution!

@codekie codekie merged commit 9f62d21 into codekie:main Apr 13, 2025
leeandher added a commit to getsentry/sentry that referenced this pull request Apr 17, 2025
…t` (#88370)

Relates to #88127, where most of
the work was done.

Upgrading `openapi-examples-validator` to 6.0.2 to include
codekie/openapi-examples-validator#195 which
will allow `null` values in example enums.

Publishes the PUT method of the `OrganizationGroupIndexEndpoint`
andrewshie-sentry pushed a commit to getsentry/sentry that referenced this pull request Apr 22, 2025
…t` (#88370)

Relates to #88127, where most of
the work was done.

Upgrading `openapi-examples-validator` to 6.0.2 to include
codekie/openapi-examples-validator#195 which
will allow `null` values in example enums.

Publishes the PUT method of the `OrganizationGroupIndexEndpoint`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants