From 62c2217e19f1d9bddb3d64b95e82105e635fc458 Mon Sep 17 00:00:00 2001 From: Stephen Finucane Date: Wed, 29 Sep 2021 15:58:01 +0100 Subject: [PATCH] requirements: Bump psycopg2-binary, openapi-core Once again, openapi-core has moved stuff around internally. Nothing we can't fix though, as it seems the thing moved is no longer necessary. Signed-off-by: Stephen Finucane --- patchwork/tests/api/validator.py | 6 +----- requirements-test.txt | 4 ++-- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/patchwork/tests/api/validator.py b/patchwork/tests/api/validator.py index 2b1921a3..96912227 100644 --- a/patchwork/tests/api/validator.py +++ b/patchwork/tests/api/validator.py @@ -10,8 +10,7 @@ from django.urls import resolve import openapi_core from openapi_core.contrib.django import DjangoOpenAPIRequestFactory from openapi_core.contrib.django import DjangoOpenAPIResponseFactory -from openapi_core.schema.media_types.exceptions import OpenAPIMediaTypeError -from openapi_core.schema.parameters.exceptions import OpenAPIParameterError +from openapi_core.exceptions import OpenAPIParameterError from openapi_core.templating import util from openapi_core.unmarshalling.schemas.formatters import Formatter from openapi_core.validation.request.validators import RequestValidator @@ -113,9 +112,6 @@ def validate_data(path, request, response, validate_request, result = validator.validate(request) try: result.raise_for_errors() - except OpenAPIMediaTypeError: - if response.status_code != status.HTTP_400_BAD_REQUEST: - raise except OpenAPIParameterError: # TODO(stephenfin): In API v2.0, this should be an error. As things # stand, we silently ignore these issues. diff --git a/requirements-test.txt b/requirements-test.txt index c8ce258b..7f03b0fc 100644 --- a/requirements-test.txt +++ b/requirements-test.txt @@ -1,6 +1,6 @@ mysqlclient~=2.0.0 -psycopg2-binary~=2.8.0 +psycopg2-binary~=2.9.0 sqlparse~=0.4.0 python-dateutil~=2.8.0 tblib~=1.7.0 -openapi-core~=0.13.4 +openapi-core~=0.14.2 -- 2.47.3