Flask-smorest

Latest version: v0.44.0

Safety actively analyzes 628918 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 11 of 13

0.9.2

++++++++++++++++++

Features:

- ``Api.register_blueprint`` passes ``**options`` keyword parameters to
``app.register_blueprint`` to override ``Blueprint`` defaults. Thanks
:user:`dryobates` for the suggestion.

0.9.1

++++++++++++++++++

Features:

- Support apispec 1.0.0b3.

Bug fixes:

- Fix crash when serving documentation at root of application. Thanks
:user:`fbergroth` for the suggestion.

0.9.0

++++++++++++++++++

Features:

- *Backwards-incompatible*: When pagination parameters are out of range, the
API does not return a `404` error anymore. It returns a `200` code with an
empty list and pagination metadata (:pr:`10`).
- *Backwards-incompatible*: Remove dependency on python-dateutil. This is an
optional marshmallow dependency. Whether it is needed to deserialize date,
time, or datetime strings depends on the application.
- Rework internal features by using mixin classes. This makes the code cleaner
and adds customization possibilities (:issue:`9`).
- *Backwards-incompatible*: ``DEFAULT_PAGINATION_PARAMETERS`` is a class
attribute of ``Blueprint``.
- *Backwards-incompatible*: When no ``Page`` class is passed to ``pagination``,
(i.e. when doing pagination in view function), the pagination parameters are
passed as a ``PaginationParameters`` object. The item count must be passed by
setting it as ``item_count`` attribute of the ``PaginationParameters``
object. The ``set_item_count`` function is removed.
- The pagination header name can be configured by overriding
``PAGINATION_HEADER_FIELD_NAME`` class attribute of ``Blueprint``. If set to
``None``, no pagination header is added to the response.
- *Backwards-incompatible*: The ``paginate`` decorator doesn't use
``NestedQueryFlaskParser`` by default. It is renamed to
``NestedQueryArgsParser`` and it can be used by overriding
``Blueprint.ARGUMENTS_PARSER``.
- Default error handler is registered for generic ``HTTPException``. Other
extensions may register other handlers for specific exceptions or codes
(:pr:`12`).

Other changes:

- *Backwards-incompatible*: Drop Flask 0.x support. Flask>=1.0 is now required.

0.8.1

++++++++++++++++++

Features:

- Add `page` (page number) to pagination metadata.
- Set `produces` and `consumes` root document attributes when using OpenAPI v2.

Bug fixes:

- Document body parameter correctly when using OpenAPI v3.

0.8.0

++++++++++++++++++

Features:

- Add ``API_SPEC_OPTIONS`` app config parameter. Thanks :user:`xalioth` for the
suggestion.
- *Backwards-incompatible*: ``Api`` accepts a ``spec_kargs`` parameter, passed
as kwargs to the internal ``APISpec`` instance. ``spec_plugins`` is removed,
plugins shall be passed as ``spec_kwargs={'plugins': [...]}``.
- *Backwards-incompatible*: Get `summary` and `description` from docstrings
(:pr:`5`).
- Add support for marshmallow 3.0.0b13. 2.x and 3b are now supported.
- Add support for apispec 1.0.0b2. 0.x and 1b are now supported.

Bug fixes:

- Document response schema correctly when using OpenAPI 3 (:issue:`8`). Thanks
:user:`ffarella` for reporting.

0.7.0

++++++++++++++++++

Other changes:

- *Backwards-incompatible*: Remove ``_wrapper_class`` from ``Page``. Creating a
custom pager is easier by just overriding ``Page`` methods.
- *Backwards-incompatible*: Let ``OPENAPI_SWAGGER_UI_SUPPORTED_SUBMIT_METHODS``
default to "all methods" list.

Page 11 of 13

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.