Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix copy-paste "format: binary" error #4294

Merged
merged 2 commits into from
Jan 10, 2025
Merged

Conversation

handrews
Copy link
Member

@handrews handrews commented Jan 9, 2025

Fixes #4293

These examples got copied from 3.0.4 and apparently I forgot to adjust them for 3.1.1 and no one else noticed.

These examples got copied from 3.0.4 and apparently I forgot to
adjust them for 3.1.1 and no one else noticed.
@handrews handrews added bug examples requests for more or better examples in the specification labels Jan 9, 2025
@handrews handrews added this to the v3.1.2 milestone Jan 9, 2025
@handrews handrews requested review from a team as code owners January 9, 2025 02:40
src/oas.md Outdated Show resolved Hide resolved
@ralfhandl
Copy link
Contributor

Lgtm

@ralfhandl ralfhandl self-requested a review January 10, 2025 14:51
Copy link
Contributor

@mikekistler mikekistler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. 👍

I left some comments to add contentEncoding in places where I thought it added clarity. When I first read this line:

default for a string without contentEncoding is text/plain

my thought was "default what"? So my changes are intended to fix that but I'll defer to your judgement to decide if this is necessary.

@@ -1800,17 +1800,17 @@ requestBody:
schema:
type: object
properties:
# default for a string without `contentEncoding` is `text/plain`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we instead say:

Suggested change
# default for a string without `contentEncoding` is `text/plain`
# default `contentEncoding` for a string is `text/plain`

# default for a schema without `type` is `application/octet-stream`
profileImage: {}

# default for arrays is based on the type in the `items`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and

Suggested change
# default for arrays is based on the type in the `items`
# default `contentEncoding` for arrays is based on the type in the `items`

@@ -1828,31 +1828,27 @@ requestBody:
schema:
type: object
properties:
# No Encoding Object, so use default `text/plain`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and

Suggested change
# No Encoding Object, so use default `text/plain`
# No Encoding Object, so use default `contentEncoding` `text/plain`

type: string
format: uuid

# Encoding Object overrides the default `application/json`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and maybe

Suggested change
# Encoding Object overrides the default `application/json`
# Encoding Object overrides the default `contentEncoding` `application/json`

@ralfhandl ralfhandl merged commit 9291879 into OAI:v3.1-dev Jan 10, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug examples requests for more or better examples in the specification
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Discrepancy between encoding multipart/ examples and working with binary data sections
3 participants