From 41a57f67312c2de031f5d31dae33c11a8cea5285 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 25 Dec 2023 18:47:13 +0000 Subject: [PATCH 1/3] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/psf/black: 23.10.1 → 23.12.1](https://github.com/psf/black/compare/23.10.1...23.12.1) - [github.com/pre-commit/mirrors-mypy: v1.6.1 → v1.8.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.6.1...v1.8.0) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1ceb0200..fb1eb869 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -5,7 +5,7 @@ repos: - id: pyupgrade args: [--py37-plus] - repo: https://github.com/psf/black - rev: 23.10.1 + rev: 23.12.1 hooks: - id: black language_version: python3 @@ -20,7 +20,7 @@ repos: - id: blacken-docs additional_dependencies: [black==22.3.0] - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.6.1 + rev: v1.8.0 hooks: - id: mypy additional_dependencies: ["marshmallow>=3,<4", "types-PyYAML"] From beb8d1cad44fa656275ec4d606db92315f9820ed Mon Sep 17 00:00:00 2001 From: Steven Loria Date: Sun, 7 Jan 2024 18:20:44 -0500 Subject: [PATCH 2/3] Update --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 797edd4a..c18f12d1 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -3,7 +3,7 @@ repos: rev: v3.15.0 hooks: - id: pyupgrade - args: [--py37-plus] + args: [--py38-plus] - repo: https://github.com/psf/black rev: 23.12.1 hooks: @@ -18,7 +18,7 @@ repos: rev: 1.16.0 hooks: - id: blacken-docs - additional_dependencies: [black==22.3.0] + additional_dependencies: [black==23.12.1] - repo: https://github.com/pre-commit/mirrors-mypy rev: v1.8.0 hooks: From 9fd301d9e778eb39e23ca6870f93b10ae6c4e737 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sun, 7 Jan 2024 23:21:55 +0000 Subject: [PATCH 3/3] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- README.rst | 1 + docs/index.rst | 1 + docs/using_plugins.rst | 2 ++ 3 files changed, 4 insertions(+) diff --git a/README.rst b/README.rst index 52f70c87..3b18555c 100644 --- a/README.rst +++ b/README.rst @@ -67,6 +67,7 @@ Example Application plugins=[FlaskPlugin(), MarshmallowPlugin()], ) + # Optional marshmallow support class CategorySchema(Schema): id = fields.Int() diff --git a/docs/index.rst b/docs/index.rst index cd068515..55c83b85 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -36,6 +36,7 @@ Example Application plugins=[FlaskPlugin(), MarshmallowPlugin()], ) + # Optional marshmallow support class CategorySchema(Schema): id = fields.Int() diff --git a/docs/using_plugins.rst b/docs/using_plugins.rst index 8dd2b4bc..369fa227 100644 --- a/docs/using_plugins.rst +++ b/docs/using_plugins.rst @@ -113,6 +113,7 @@ We'll add some YAML in the docstring to add response information. app = Flask(__name__) + # NOTE: Plugins may inspect docstrings to gather more information for the spec @app.route("/gists/") def gist_detail(gist_id): @@ -258,6 +259,7 @@ OpenAPI type and format, or a marshmallow `Field` that has the desired target ma title="Demo", version="0.1", openapi_version="3.0.0", plugins=(ma_plugin,) ) + # Inherits Integer mapping of ('integer', None) class CustomInteger(Integer): pass