From 680be6bcc973f137c5872863d5efbcfe0d623097 Mon Sep 17 00:00:00 2001 From: Steven Bal Date: Tue, 6 Feb 2024 16:18:35 +0100 Subject: [PATCH] :heavy_plus_sign: Replace dependencies with open-api-framework --- requirements/base.in | 21 +--- requirements/base.txt | 124 +++++++++++++++-------- requirements/ci.txt | 149 +++++++++++++++++++++------- requirements/dev.txt | 149 +++++++++++++++++++++------- src/objecttypes/conf/base.py | 7 +- src/objecttypes/utils/autoschema.py | 8 +- 6 files changed, 311 insertions(+), 147 deletions(-) diff --git a/requirements/base.in b/requirements/base.in index b46de3f4..e2484f83 100644 --- a/requirements/base.in +++ b/requirements/base.in @@ -1,30 +1,13 @@ +open-api-framework + # Core python libraries -psycopg2 # database driver -python-dotenv # environment variables for secrets -python-decouple # processing of envvar configs jsonschema # Framework libraries -django -django-admin-index -django-axes django-jsonsuit -django-redis maykin-django-two-factor-auth maykin-django-two-factor-auth[phonenumbers] -mozilla-django-oidc-db sharing-configs # API libraries -djangorestframework -django-filter drf-nested-routers -drf-spectacular - -# WSGI servers & monitoring - production oriented -uwsgi -sentry-sdk # error monitoring -elastic-apm # Elastic APM integration - -# Common ground libraries -commonground-api-common diff --git a/requirements/base.txt b/requirements/base.txt index 8fd5339c..95c92f84 100644 --- a/requirements/base.txt +++ b/requirements/base.txt @@ -7,7 +7,9 @@ amqp==5.1.1 # via kombu asgiref==3.6.0 - # via django + # via + # django + # django-cors-headers async-timeout==4.0.2 # via redis attrs==23.1.0 @@ -16,12 +18,17 @@ attrs==23.1.0 # jsonschema billiard==3.6.4.0 # via celery +bleach==6.1.0 + # via open-api-framework boltons==23.0.0 # via # face # glom celery==5.2.7 - # via notifications-api-common + # via + # flower + # notifications-api-common + # open-api-framework certifi==2023.5.7 # via # django-simple-certmanager @@ -44,10 +51,12 @@ click-plugins==1.1.1 # via celery click-repl==0.2.0 # via celery -commonground-api-common==1.10.2 - # via -r requirements/base.in +commonground-api-common==1.12.1 + # via open-api-framework coreapi==2.3.3 - # via drf-yasg + # via + # commonground-api-common + # drf-yasg coreschema==0.0.4 # via # coreapi @@ -58,26 +67,28 @@ cryptography==40.0.2 # josepy # mozilla-django-oidc # pyopenssl -django==3.2.20 +django==3.2.24 # via - # -r requirements/base.in # commonground-api-common # django-admin-index # django-axes - # django-choices + # django-cors-headers # django-filter # django-formtools # django-jsonform # django-jsonsuit + # django-markup # django-otp # django-phonenumber-field # django-privates # django-redis # django-relativedelta # django-rest-framework-condition + # django-sendfile2 # django-simple-certmanager # django-solo # djangorestframework + # djangorestframework-inclusions # drf-nested-routers # drf-spectacular # drf-yasg @@ -85,26 +96,29 @@ django==3.2.20 # mozilla-django-oidc # mozilla-django-oidc-db # notifications-api-common + # open-api-framework # sharing-configs # zgw-consumers -django-admin-index==3.0.0 - # via -r requirements/base.in -django-axes==5.41.1 - # via -r requirements/base.in -django-choices==1.7.2 - # via commonground-api-common +django-admin-index==3.1.0 + # via open-api-framework +django-axes==6.3.0 + # via open-api-framework +django-cors-headers==4.3.1 + # via open-api-framework django-filter==23.2 # via - # -r requirements/base.in # commonground-api-common + # open-api-framework django-formtools==2.4.1 # via maykin-django-two-factor-auth -django-ipware==6.0.3 - # via django-axes django-jsonform==2.21.5 - # via mozilla-django-oidc-db + # via + # mozilla-django-oidc-db + # open-api-framework django-jsonsuit==0.5.0 # via -r requirements/base.in +django-markup==1.8.1 + # via open-api-framework django-ordered-model==3.7.4 # via django-admin-index django-otp==1.2.0 @@ -113,15 +127,15 @@ django-phonenumber-field==5.2.0 # via maykin-django-two-factor-auth django-privates==2.0.0.post0 # via django-simple-certmanager -django-redis==5.2.0 - # via -r requirements/base.in +django-redis==5.4.0 + # via open-api-framework django-relativedelta==2.0.0 # via zgw-consumers django-rest-framework-condition==0.1.1 # via commonground-api-common django-sendfile2==0.7.0 # via django-privates -django-simple-certmanager==1.3.0 +django-simple-certmanager==1.4.1 # via zgw-consumers django-solo==2.0.0 # via @@ -132,37 +146,49 @@ django-solo==2.0.0 # zgw-consumers djangorestframework==3.12.4 # via - # -r requirements/base.in # commonground-api-common + # djangorestframework-gis + # djangorestframework-inclusions # drf-nested-routers # drf-spectacular # drf-yasg # notifications-api-common + # open-api-framework djangorestframework-camel-case==1.4.2 # via # commonground-api-common # notifications-api-common +djangorestframework-gis==1.0 + # via open-api-framework +djangorestframework-inclusions==1.2.0 + # via open-api-framework drf-nested-routers==0.93.4 # via # -r requirements/base.in # commonground-api-common -drf-spectacular==0.16.0 - # via -r requirements/base.in +drf-spectacular==0.27.1 + # via open-api-framework drf-yasg==1.21.5 # via commonground-api-common -elastic-apm==6.15.1 - # via -r requirements/base.in +ecs-logging==2.1.0 + # via elastic-apm +elastic-apm==6.20.0 + # via open-api-framework face==20.1.1 # via glom -faker==18.9.0 +faker==22.7.0 # via zgw-consumers -gemma-zds-client==1.0.1 +flower==2.0.1 + # via open-api-framework +gemma-zds-client==2.0.0 # via # commonground-api-common # notifications-api-common # zgw-consumers glom==23.3.0 # via mozilla-django-oidc-db +humanize==4.9.0 + # via flower idna==3.4 # via requests inflection==0.5.1 @@ -192,19 +218,23 @@ maykin-django-two-factor-auth[phonenumbers]==2.0.4 mozilla-django-oidc==4.0.0 # via mozilla-django-oidc-db mozilla-django-oidc-db==0.14.1 - # via -r requirements/base.in + # via open-api-framework notifications-api-common==0.2.2 # via commonground-api-common +open-api-framework==0.1.0 + # via -r requirements/base.in oyaml==1.0 # via commonground-api-common packaging==23.1 # via drf-yasg phonenumbers==8.13.11 # via maykin-django-two-factor-auth +prometheus-client==0.19.0 + # via flower prompt-toolkit==3.0.38 # via click-repl -psycopg2==2.9.6 - # via -r requirements/base.in +psycopg2==2.9.9 + # via open-api-framework pycparser==2.21 # via cffi pyjwt==2.7.0 @@ -223,16 +253,15 @@ python-dateutil==2.8.2 # django-relativedelta # faker python-decouple==3.8 - # via -r requirements/base.in + # via open-api-framework python-dotenv==1.0.0 - # via -r requirements/base.in -python-ipware==2.0.1 - # via django-ipware + # via open-api-framework pytz==2023.3 # via # celery # django # drf-yasg + # flower pyyaml==6.0 # via # commonground-api-common @@ -249,29 +278,32 @@ requests==2.31.0 # coreapi # gemma-zds-client # mozilla-django-oidc + # open-api-framework # requests-mock # sharing-configs # zgw-consumers -requests-mock==1.10.0 +requests-mock==1.11.0 # via zgw-consumers ruamel-yaml==0.17.26 # via drf-yasg ruamel-yaml-clib==0.2.7 # via ruamel-yaml -sentry-sdk==1.23.1 - # via -r requirements/base.in +sentry-sdk==1.40.1 + # via open-api-framework sharing-configs==0.1.2 # via -r requirements/base.in six==1.16.0 # via + # bleach # click-repl - # django-choices # isodate # python-dateutil # qrcode # requests-mock sqlparse==0.4.4 # via django +tornado==6.4 + # via flower uritemplate==4.1.1 # via # coreapi @@ -282,8 +314,8 @@ urllib3==1.26.15 # elastic-apm # requests # sentry-sdk -uwsgi==2.0.21 - # via -r requirements/base.in +uwsgi==2.0.23 + # via open-api-framework vine==5.0.0 # via # amqp @@ -291,10 +323,14 @@ vine==5.0.0 # kombu wcwidth==0.2.6 # via prompt-toolkit -wrapt==1.15.0 +webencodings==0.5.1 + # via bleach +wrapt==1.14.1 # via elastic-apm -zgw-consumers==0.26.1 - # via notifications-api-common +zgw-consumers==0.27.0 + # via + # notifications-api-common + # open-api-framework # The following packages are considered to be unsafe in a requirements file: # setuptools diff --git a/requirements/ci.txt b/requirements/ci.txt index af333aa3..5409c6ca 100644 --- a/requirements/ci.txt +++ b/requirements/ci.txt @@ -12,6 +12,7 @@ asgiref==3.6.0 # via # -r requirements/base.txt # django + # django-cors-headers async-timeout==4.0.2 # via # -r requirements/base.txt @@ -27,6 +28,10 @@ billiard==3.6.4.0 # via # -r requirements/base.txt # celery +bleach==6.1.0 + # via + # -r requirements/base.txt + # open-api-framework boltons==23.0.0 # via # -r requirements/base.txt @@ -35,7 +40,9 @@ boltons==23.0.0 celery==5.2.7 # via # -r requirements/base.txt + # flower # notifications-api-common + # open-api-framework certifi==2023.5.7 # via # -r requirements/base.txt @@ -70,11 +77,14 @@ click-repl==0.2.0 # via # -r requirements/base.txt # celery -commonground-api-common==1.10.2 - # via -r requirements/base.txt +commonground-api-common==1.12.1 + # via + # -r requirements/base.txt + # open-api-framework coreapi==2.3.3 # via # -r requirements/base.txt + # commonground-api-common # drf-yasg coreschema==0.0.4 # via @@ -92,18 +102,19 @@ cryptography==40.0.2 # pyopenssl cssselect==1.2.0 # via pyquery -django==3.2.20 +django==3.2.24 # via # -r requirements/base.txt # commonground-api-common # django-admin-index # django-axes - # django-choices + # django-cors-headers # django-filter # django-formtools # django-jenkins # django-jsonform # django-jsonsuit + # django-markup # django-otp # django-phonenumber-field # django-privates @@ -114,6 +125,7 @@ django==3.2.20 # django-simple-certmanager # django-solo # djangorestframework + # djangorestframework-inclusions # drf-nested-routers # drf-spectacular # drf-yasg @@ -121,36 +133,43 @@ django==3.2.20 # mozilla-django-oidc # mozilla-django-oidc-db # notifications-api-common + # open-api-framework # sharing-configs # zgw-consumers -django-admin-index==3.0.0 - # via -r requirements/base.txt -django-axes==5.41.1 - # via -r requirements/base.txt -django-choices==1.7.2 +django-admin-index==3.1.0 # via # -r requirements/base.txt - # commonground-api-common + # open-api-framework +django-axes==6.3.0 + # via + # -r requirements/base.txt + # open-api-framework +django-cors-headers==4.3.1 + # via + # -r requirements/base.txt + # open-api-framework django-filter==23.2 # via # -r requirements/base.txt # commonground-api-common + # open-api-framework django-formtools==2.4.1 # via # -r requirements/base.txt # maykin-django-two-factor-auth -django-ipware==6.0.3 - # via - # -r requirements/base.txt - # django-axes django-jenkins==0.110.0 # via -r requirements/test-tools.in django-jsonform==2.21.5 # via # -r requirements/base.txt # mozilla-django-oidc-db + # open-api-framework django-jsonsuit==0.5.0 # via -r requirements/base.txt +django-markup==1.8.1 + # via + # -r requirements/base.txt + # open-api-framework django-ordered-model==3.7.4 # via # -r requirements/base.txt @@ -167,8 +186,10 @@ django-privates==2.0.0.post0 # via # -r requirements/base.txt # django-simple-certmanager -django-redis==5.2.0 - # via -r requirements/base.txt +django-redis==5.4.0 + # via + # -r requirements/base.txt + # open-api-framework django-relativedelta==2.0.0 # via # -r requirements/base.txt @@ -181,7 +202,7 @@ django-sendfile2==0.7.0 # via # -r requirements/base.txt # django-privates -django-simple-certmanager==1.3.0 +django-simple-certmanager==1.4.1 # via # -r requirements/base.txt # zgw-consumers @@ -199,41 +220,64 @@ djangorestframework==3.12.4 # via # -r requirements/base.txt # commonground-api-common + # djangorestframework-gis + # djangorestframework-inclusions # drf-nested-routers # drf-spectacular # drf-yasg # notifications-api-common + # open-api-framework djangorestframework-camel-case==1.4.2 # via # -r requirements/base.txt # commonground-api-common # notifications-api-common +djangorestframework-gis==1.0 + # via + # -r requirements/base.txt + # open-api-framework +djangorestframework-inclusions==1.2.0 + # via + # -r requirements/base.txt + # open-api-framework drf-nested-routers==0.93.4 # via # -r requirements/base.txt # commonground-api-common -drf-spectacular==0.16.0 - # via -r requirements/base.txt +drf-spectacular==0.27.1 + # via + # -r requirements/base.txt + # open-api-framework drf-yasg==1.21.5 # via # -r requirements/base.txt # commonground-api-common -elastic-apm==6.15.1 - # via -r requirements/base.txt +ecs-logging==2.1.0 + # via + # -r requirements/base.txt + # elastic-apm +elastic-apm==6.20.0 + # via + # -r requirements/base.txt + # open-api-framework face==20.1.1 # via # -r requirements/base.txt # glom factory-boy==3.2.1 # via -r requirements/test-tools.in -faker==18.9.0 +faker==22.7.0 # via # -r requirements/base.txt # factory-boy # zgw-consumers +flower==2.0.1 + # via + # -r requirements/base.txt + # open-api-framework freezegun==1.2.2 # via -r requirements/test-tools.in -gemma-zds-client==1.0.1 +gemma-zds-client==2.0.0 # via # -r requirements/base.txt # commonground-api-common @@ -243,6 +287,10 @@ glom==23.3.0 # via # -r requirements/base.txt # mozilla-django-oidc-db +humanize==4.9.0 + # via + # -r requirements/base.txt + # flower idna==3.4 # via # -r requirements/base.txt @@ -293,11 +341,15 @@ mozilla-django-oidc==4.0.0 # -r requirements/base.txt # mozilla-django-oidc-db mozilla-django-oidc-db==0.14.1 - # via -r requirements/base.txt + # via + # -r requirements/base.txt + # open-api-framework notifications-api-common==0.2.2 # via # -r requirements/base.txt # commonground-api-common +open-api-framework==0.1.0 + # via -r requirements/base.txt oyaml==1.0 # via # -r requirements/base.txt @@ -310,12 +362,18 @@ phonenumbers==8.13.11 # via # -r requirements/base.txt # maykin-django-two-factor-auth +prometheus-client==0.19.0 + # via + # -r requirements/base.txt + # flower prompt-toolkit==3.0.38 # via # -r requirements/base.txt # click-repl -psycopg2==2.9.6 - # via -r requirements/base.txt +psycopg2==2.9.9 + # via + # -r requirements/base.txt + # open-api-framework pycparser==2.21 # via # -r requirements/base.txt @@ -344,19 +402,20 @@ python-dateutil==2.8.2 # faker # freezegun python-decouple==3.8 - # via -r requirements/base.txt + # via + # -r requirements/base.txt + # open-api-framework python-dotenv==1.0.0 - # via -r requirements/base.txt -python-ipware==2.0.1 # via # -r requirements/base.txt - # django-ipware + # open-api-framework pytz==2023.3 # via # -r requirements/base.txt # celery # django # drf-yasg + # flower pyyaml==6.0 # via # -r requirements/base.txt @@ -379,10 +438,11 @@ requests==2.31.0 # coreapi # gemma-zds-client # mozilla-django-oidc + # open-api-framework # requests-mock # sharing-configs # zgw-consumers -requests-mock==1.10.0 +requests-mock==1.11.0 # via # -r requirements/base.txt # -r requirements/test-tools.in @@ -395,15 +455,17 @@ ruamel-yaml-clib==0.2.7 # via # -r requirements/base.txt # ruamel-yaml -sentry-sdk==1.23.1 - # via -r requirements/base.txt +sentry-sdk==1.40.1 + # via + # -r requirements/base.txt + # open-api-framework sharing-configs==0.1.2 # via -r requirements/base.txt six==1.16.0 # via # -r requirements/base.txt + # bleach # click-repl - # django-choices # isodate # python-dateutil # qrcode @@ -416,6 +478,10 @@ sqlparse==0.4.4 # django tblib==1.7.0 # via -r requirements/test-tools.in +tornado==6.4 + # via + # -r requirements/base.txt + # flower uritemplate==4.1.1 # via # -r requirements/base.txt @@ -428,8 +494,10 @@ urllib3==1.26.15 # elastic-apm # requests # sentry-sdk -uwsgi==2.0.21 - # via -r requirements/base.txt +uwsgi==2.0.23 + # via + # -r requirements/base.txt + # open-api-framework vine==5.0.0 # via # -r requirements/base.txt @@ -442,18 +510,23 @@ wcwidth==0.2.6 # via # -r requirements/base.txt # prompt-toolkit +webencodings==0.5.1 + # via + # -r requirements/base.txt + # bleach webob==1.8.7 # via webtest webtest==3.0.0 # via django-webtest -wrapt==1.15.0 +wrapt==1.14.1 # via # -r requirements/base.txt # elastic-apm -zgw-consumers==0.26.1 +zgw-consumers==0.27.0 # via # -r requirements/base.txt # notifications-api-common + # open-api-framework # The following packages are considered to be unsafe in a requirements file: # setuptools diff --git a/requirements/dev.txt b/requirements/dev.txt index fc6e4249..f1089a20 100644 --- a/requirements/dev.txt +++ b/requirements/dev.txt @@ -14,6 +14,7 @@ asgiref==3.6.0 # via # -r requirements/ci.txt # django + # django-cors-headers async-timeout==4.0.2 # via # -r requirements/ci.txt @@ -35,6 +36,10 @@ billiard==3.6.4.0 # celery black==23.3.0 # via -r requirements/dev.in +bleach==6.1.0 + # via + # -r requirements/ci.txt + # open-api-framework boltons==23.0.0 # via # -r requirements/ci.txt @@ -49,7 +54,9 @@ bumpversion==0.6.0 celery==5.2.7 # via # -r requirements/ci.txt + # flower # notifications-api-common + # open-api-framework certifi==2023.5.7 # via # -r requirements/ci.txt @@ -86,11 +93,14 @@ click-repl==0.2.0 # via # -r requirements/ci.txt # celery -commonground-api-common==1.10.2 - # via -r requirements/ci.txt +commonground-api-common==1.12.1 + # via + # -r requirements/ci.txt + # open-api-framework coreapi==2.3.3 # via # -r requirements/ci.txt + # commonground-api-common # drf-yasg coreschema==0.0.4 # via @@ -110,13 +120,13 @@ cssselect==1.2.0 # via # -r requirements/ci.txt # pyquery -django==3.2.20 +django==3.2.24 # via # -r requirements/ci.txt # commonground-api-common # django-admin-index # django-axes - # django-choices + # django-cors-headers # django-debug-toolbar # django-extensions # django-filter @@ -124,6 +134,7 @@ django==3.2.20 # django-jenkins # django-jsonform # django-jsonsuit + # django-markup # django-otp # django-phonenumber-field # django-privates @@ -134,6 +145,7 @@ django==3.2.20 # django-simple-certmanager # django-solo # djangorestframework + # djangorestframework-inclusions # drf-nested-routers # drf-spectacular # drf-yasg @@ -141,16 +153,21 @@ django==3.2.20 # mozilla-django-oidc # mozilla-django-oidc-db # notifications-api-common + # open-api-framework # sharing-configs # zgw-consumers -django-admin-index==3.0.0 - # via -r requirements/ci.txt -django-axes==5.41.1 - # via -r requirements/ci.txt -django-choices==1.7.2 +django-admin-index==3.1.0 # via # -r requirements/ci.txt - # commonground-api-common + # open-api-framework +django-axes==6.3.0 + # via + # -r requirements/ci.txt + # open-api-framework +django-cors-headers==4.3.1 + # via + # -r requirements/ci.txt + # open-api-framework django-debug-toolbar==4.1.0 # via -r requirements/dev.in django-extensions==3.2.1 @@ -159,22 +176,24 @@ django-filter==23.2 # via # -r requirements/ci.txt # commonground-api-common + # open-api-framework django-formtools==2.4.1 # via # -r requirements/ci.txt # maykin-django-two-factor-auth -django-ipware==6.0.3 - # via - # -r requirements/ci.txt - # django-axes django-jenkins==0.110.0 # via -r requirements/ci.txt django-jsonform==2.21.5 # via # -r requirements/ci.txt # mozilla-django-oidc-db + # open-api-framework django-jsonsuit==0.5.0 # via -r requirements/ci.txt +django-markup==1.8.1 + # via + # -r requirements/ci.txt + # open-api-framework django-ordered-model==3.7.4 # via # -r requirements/ci.txt @@ -191,8 +210,10 @@ django-privates==2.0.0.post0 # via # -r requirements/ci.txt # django-simple-certmanager -django-redis==5.2.0 - # via -r requirements/ci.txt +django-redis==5.4.0 + # via + # -r requirements/ci.txt + # open-api-framework django-relativedelta==2.0.0 # via # -r requirements/ci.txt @@ -205,7 +226,7 @@ django-sendfile2==0.7.0 # via # -r requirements/ci.txt # django-privates -django-simple-certmanager==1.3.0 +django-simple-certmanager==1.4.1 # via # -r requirements/ci.txt # zgw-consumers @@ -223,15 +244,26 @@ djangorestframework==3.12.4 # via # -r requirements/ci.txt # commonground-api-common + # djangorestframework-gis + # djangorestframework-inclusions # drf-nested-routers # drf-spectacular # drf-yasg # notifications-api-common + # open-api-framework djangorestframework-camel-case==1.4.2 # via # -r requirements/ci.txt # commonground-api-common # notifications-api-common +djangorestframework-gis==1.0 + # via + # -r requirements/ci.txt + # open-api-framework +djangorestframework-inclusions==1.2.0 + # via + # -r requirements/ci.txt + # open-api-framework docutils==0.18.1 # via # sphinx @@ -240,30 +272,42 @@ drf-nested-routers==0.93.4 # via # -r requirements/ci.txt # commonground-api-common -drf-spectacular==0.16.0 - # via -r requirements/ci.txt +drf-spectacular==0.27.1 + # via + # -r requirements/ci.txt + # open-api-framework drf-yasg==1.21.5 # via # -r requirements/ci.txt # commonground-api-common -elastic-apm==6.15.1 - # via -r requirements/ci.txt +ecs-logging==2.1.0 + # via + # -r requirements/ci.txt + # elastic-apm +elastic-apm==6.20.0 + # via + # -r requirements/ci.txt + # open-api-framework face==20.1.1 # via # -r requirements/ci.txt # glom factory-boy==3.2.1 # via -r requirements/ci.txt -faker==18.9.0 +faker==22.7.0 # via # -r requirements/ci.txt # factory-boy # zgw-consumers flake8==6.0.0 # via -r requirements/dev.in +flower==2.0.1 + # via + # -r requirements/ci.txt + # open-api-framework freezegun==1.2.2 # via -r requirements/ci.txt -gemma-zds-client==1.0.1 +gemma-zds-client==2.0.0 # via # -r requirements/ci.txt # commonground-api-common @@ -273,6 +317,10 @@ glom==23.3.0 # via # -r requirements/ci.txt # mozilla-django-oidc-db +humanize==4.9.0 + # via + # -r requirements/ci.txt + # flower idna==3.4 # via # -r requirements/ci.txt @@ -332,13 +380,17 @@ mozilla-django-oidc==4.0.0 # -r requirements/ci.txt # mozilla-django-oidc-db mozilla-django-oidc-db==0.14.1 - # via -r requirements/ci.txt + # via + # -r requirements/ci.txt + # open-api-framework mypy-extensions==1.0.0 # via black notifications-api-common==0.2.2 # via # -r requirements/ci.txt # commonground-api-common +open-api-framework==0.1.0 + # via -r requirements/ci.txt oyaml==1.0 # via # -r requirements/ci.txt @@ -360,12 +412,18 @@ pip-tools==6.13.0 # via -r requirements/dev.in platformdirs==3.5.1 # via black +prometheus-client==0.19.0 + # via + # -r requirements/ci.txt + # flower prompt-toolkit==3.0.38 # via # -r requirements/ci.txt # click-repl -psycopg2==2.9.6 - # via -r requirements/ci.txt +psycopg2==2.9.9 + # via + # -r requirements/ci.txt + # open-api-framework pycodestyle==2.10.0 # via flake8 pycparser==2.21 @@ -402,19 +460,20 @@ python-dateutil==2.8.2 # faker # freezegun python-decouple==3.8 - # via -r requirements/ci.txt + # via + # -r requirements/ci.txt + # open-api-framework python-dotenv==1.0.0 - # via -r requirements/ci.txt -python-ipware==2.0.1 # via # -r requirements/ci.txt - # django-ipware + # open-api-framework pytz==2023.3 # via # -r requirements/ci.txt # celery # django # drf-yasg + # flower pyyaml==6.0 # via # -r requirements/ci.txt @@ -437,11 +496,12 @@ requests==2.31.0 # coreapi # gemma-zds-client # mozilla-django-oidc + # open-api-framework # requests-mock # sharing-configs # sphinx # zgw-consumers -requests-mock==1.10.0 +requests-mock==1.11.0 # via # -r requirements/ci.txt # zgw-consumers @@ -453,15 +513,17 @@ ruamel-yaml-clib==0.2.7 # via # -r requirements/ci.txt # ruamel-yaml -sentry-sdk==1.23.1 - # via -r requirements/ci.txt +sentry-sdk==1.40.1 + # via + # -r requirements/ci.txt + # open-api-framework sharing-configs==0.1.2 # via -r requirements/ci.txt six==1.16.0 # via # -r requirements/ci.txt + # bleach # click-repl - # django-choices # isodate # python-dateutil # qrcode @@ -504,6 +566,10 @@ tomli==2.0.1 # via # black # build +tornado==6.4 + # via + # -r requirements/ci.txt + # flower uritemplate==4.1.1 # via # -r requirements/ci.txt @@ -516,8 +582,10 @@ urllib3==1.26.15 # elastic-apm # requests # sentry-sdk -uwsgi==2.0.21 - # via -r requirements/ci.txt +uwsgi==2.0.23 + # via + # -r requirements/ci.txt + # open-api-framework vine==5.0.0 # via # -r requirements/ci.txt @@ -532,6 +600,10 @@ wcwidth==0.2.6 # via # -r requirements/ci.txt # prompt-toolkit +webencodings==0.5.1 + # via + # -r requirements/ci.txt + # bleach webob==1.8.7 # via # -r requirements/ci.txt @@ -542,14 +614,15 @@ webtest==3.0.0 # django-webtest wheel==0.40.0 # via pip-tools -wrapt==1.15.0 +wrapt==1.14.1 # via # -r requirements/ci.txt # elastic-apm -zgw-consumers==0.26.1 +zgw-consumers==0.27.0 # via # -r requirements/ci.txt # notifications-api-common + # open-api-framework # The following packages are considered to be unsafe in a requirements file: # pip diff --git a/src/objecttypes/conf/base.py b/src/objecttypes/conf/base.py index 3a4443c3..1c87a48e 100644 --- a/src/objecttypes/conf/base.py +++ b/src/objecttypes/conf/base.py @@ -330,15 +330,10 @@ # will be forgotten. Can be set to a python timedelta object or an integer. If # an integer, will be interpreted as a number of hours. Default: None AXES_COOLOFF_TIME = 1 -# If True only locks based on user id and never locks by IP if attempts limit -# exceed, otherwise utilize the existing IP and user locking logic Default: -# False -AXES_ONLY_USER_FAILURES = True # If set, specifies a template to render when a user is locked out. Template # receives cooloff_time and failure_limit as context variables. Default: None AXES_LOCKOUT_TEMPLATE = "account_blocked.html" -AXES_USE_USER_AGENT = True # Default: False -AXES_LOCK_OUT_BY_COMBINATION_USER_AND_IP = True # Default: False +AXES_LOCKOUT_PARAMETERS = [["ip_address", "user_agent", "username"]] # The default meta precedence order IPWARE_META_PRECEDENCE_ORDER = ( diff --git a/src/objecttypes/utils/autoschema.py b/src/objecttypes/utils/autoschema.py index c5a32ffc..527e9145 100644 --- a/src/objecttypes/utils/autoschema.py +++ b/src/objecttypes/utils/autoschema.py @@ -24,9 +24,13 @@ def get_override_parameters(self): parent_path_headers = self.get_parent_path_headers() return content_type_headers + parent_path_headers - def _get_response_for_code(self, serializer, status_code, media_types=None): + def _get_response_for_code( + self, serializer, status_code, media_types=None, direction=None + ): """add default description to the response""" - response = super()._get_response_for_code(serializer, status_code, media_types) + response = super()._get_response_for_code( + serializer, status_code, media_types, direction=direction + ) if not response.get("description"): response["description"] = HTTP_STATUS_CODE_TITLES.get(int(status_code))