Since version 1.1.0, we use Github releases and autogenerated changelogs.
- Take default value from missing attribute (thanks @sp-schoen)
Breaking Changes
- Drop Python 2 support
Internal changes
- bump swagger-ui files to 3.23.11
Support swagger
example
field on colanderSchemaNode
custom kwarg:def SomeSchema(colander.MappingSchema): name = colander.SchemaNode(colander.String(), example='Mr. IceCream')
The
example
field is returned in the swagger spec accordingly.
- Add
cornice_enable_openapi_view()
cornice_enable_openapi_explorer()
Pyramid directives to serve the API Explorer and the spec information (#79)
- Prevent failure with non-colander schemas (#78, thanks @ergo!)
Internals
- Fix return types in docstrings (#77)
Pyramid compliance
- Handle callables for
cornice.service.Service.content_type
argument. For more details, see: http://cornice.readthedocs.io/en/latest/api.html#cornice.service.Service.
Internals
- Add classifiers to the Python package.
Pyramid compliance
- Support subpaths and regex when parsing paths (#68).
Api
_extract_path_from_service
, now returns the path name along with the path swagger object (#68).
Api
- Allow implementing a custom generator by subclassing the
CorniceSwagger
class (#63). - Introduced a new method
CorniceSwagger.generate
to generate the spec (#63). - Deprecated
CorniceSwagger
call method. You should now usegenerate
(#63). - Removed deprecated
generate_swagger_spec
call. (#64). - Allow defining custom type converters on the
CorniceSwagger
class. (#65)
Internals
- Fixed coveralls repeated messages on PRs. (#62).
Api
- Summaries from docstrings are now not included by default. You can enable them by passing
summary_docstrings = True
to the generator. - Trying to document multiple views on same method now raises an exception. You should ignore the unwanted ones by content type.
- Raw
swagger
items are now recursively merged (instead of replaced) with the extracted fields. - Add support for documenting operation ids via an
operation_id
argument on the view or by passing adefault_op_ids
callable to the generator. - Add a shortcut to the generator on
cornice_swagger.CorniceSwagger
. - Support Cornice schema synonyms (headers and GET are the same as header and querystring).
- Add support for documenting security properties via a
api_security
list on the view or by passing adefault_security
list or callable to the generator.
OpenAPI compliance
- Remove invalid
title
field from response headers and request parameters. - Support conversion of parameter validators.
Internals
- Fix default tag generator.
- Fix references when using declarative schemas.
- Simplify parameter converter by properly isolating
body
.
Api
- Use
cornice_swagger.swagger.CorniceSwagger
class to generate the swagger document rather thengenerate_swagger_spec
. - Allow overriding extractors in the application.
- Schemas are now broken into JSON pointers only if specified.
- Allow documenting responses via
response_schemas
view attribute. - Allow documenting tags via
tags
view attribute or using adefault_tags
parameter when calling the generator.
Internals
- Decouples converters from path generators.
- Make considerable changes in the package organisation.
- Reach 100% coverage on tests.
Documentation
- Create a Sphinx documentation hosted on https://cornices.github.io/cornice.ext.swagger.
- Check if schema is not instantiated.
- Add support for query parameter description. [ridha]
- Pypi release.
- Point scaffold doc to right url.
- First release for new cornice 2.0