You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#138 added support for boolean additionalProperties which invalidates one of the test cases in this PR. I'm not sure whether this is correct as the Swagger 2.0 spec is a bit vague about that, see OAI/OpenAPI-Specification#668.
I'll try to have a look to the PR and the Specifications later this evening.
For what I remember the schemas defined in #/definitions/<key> must be dictionaries, and the PR seems ensuring this but I'm not 100% sure. So I need to validate this and check the code change.
@ngaya-ll thanks for the PR and for holding tight with us until a proper review is possible.
I remember us looking into additionalProperties and the fact that it can be a boolean value in the past, it just slipped through during the code review for #134. OAI/OpenAPI-Specification#668 mentions that (more explicit) support for a boolean value was added in OpenAPI 3.0. See OAI/OpenAPI-Specification#894.
Given all of that, we should allow boolean values for additionalProperties in OpenAPI 2.0.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This prevents an
AttributeErrorwhen validating definitions like this: