OAS 3+ has no property 'definitions'
See original GitHub issueOAS 3.x is not valid as the property definitions
(even though it is added as empty list) is automatically added by flasgger. In case OAS 3.x this has been replaced by components (see here). I am not sure how to properly fix this as it has been used throughout the package.
A dirty hack that works for me is simply removing the definitions
from the dict. (https://github.com/IKNL/flasgger/commit/b4451780d801688f49e2a1405e00883502365412)
I assumed (maybe wrong) that OAS3+ was supported as it was used in one of the examples. Although no were else in the documentation it states that OAS3+ is supported.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:2
- Comments:13 (1 by maintainers)
Top Results From Across the Web
OAS 3+ has no property 'definitions' · Issue #267 - GitHub
OAS 3.x is not valid as the property definitions (even though it is added as empty list) is automatically added by flasgger. In...
Read more >OpenAPI Specification - Version 3.0.3 - Swagger
All objects defined within the components object will have no effect on the API unless they are explicitly referenced from properties outside the...
Read more >OpenAPI Specification v3.1.0 | Introduction, Definitions, & More
The OpenAPI Specification (OAS) defines a standard, programming language-agnostic interface description for HTTP APIs.
Read more >Developers - OAS 3+ has no property 'definitions' - - Bountysource
OAS 3.x is not valid as the property definitions (even though it is added as empty list) is automatically added by flasgger. In...
Read more >openapi - Swagger schema properties ignored when using $ref
Your definition will work as expected when migrated to OpenAPI 3.1. This new version is fully compatible with JSON Schema 2020-12, which allows...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
It would be great if the issue could be solved. I still get errors using 0.9.5 if I try to generate Client stubs using the openapi-generator (Version 4.3.1 and 5.0.0-beta2): “attribute definitions is unexpected”
So we removed the part where
definitions
is added, see: https://github.com/IKNL/flasgger/commit/b4451780d801688f49e2a1405e00883502365412We also published this hack on pypi, see link above. Definitely not a proper fix!
pip install iknl-flasgger