Uh oh!
There was an error while loading. Please reload this page.
OAD schema fix 'parameter object' + in: querystring forbidden fields - #4909
Conversation
There was a problem hiding this comment.
I think this change is unnecessary. Adding this fail test case with the current schema fails as expected:
openapi: 3.2.0info:
title: APIversion: 1.0.0components:
parameters:
querystring-with-schema-not-allowed:
in: querystringname: jsoncontent:
application/json:
schema:
type: objectexplode: trueIt also fails with a single one of the other three keywords not allowed with content.
Side note: schema is not necessary in the not-required list because having both content and schema is already forbidden by the oneOf-required construct in lines 367-371.
I prefer the current style as it is shorter.
Independent of this PR I think we should add a "fail" test case for this exclusion:
handrews
commented
Aug 28, 2025
@notEthan@ralfhandl actually the entire |
notEthan
commented
Aug 28, 2025
That example fails due to |
notEthan
commented
Aug 28, 2025
oh, @handrews beat me to it while I was typing |
40a64d6 to
7bb5630ComparenotEthan
commented
Aug 28, 2025
updated to remove this subschema |
and content cannot be used with style
… subschema This subschema would only forbid the presence of all four properties, rather than any of them, but it is superfluous as these properties are caught by `unevaluatedProperties: false`.
7bb5630 to
3f1df3fComparenotEthan
commented
Aug 29, 2025
rebased against that PR's branch |
Uh oh!
There was an error while loading. Please reload this page.
#4590 introduces parameter object with
in: querystring, which may not have propertiesschema,style,explode, orallowReserved. The accompanying schema change only forbids an object with all of those four properties, though. This fixes to forbid any of them.