From 44b3f371f9fe7c5e6ad0fe7e64af6af61c61156b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 29 Mar 2022 09:56:06 +0200 Subject: [PATCH 001/324] * Migrate documentation from RST to Markdown. --- .../docs/{authors.rst => authors.md} | 0 .../docs/{history.rst => history.md} | 0 .../docs/index.md} | 7 ++-- .../docs/index.rst | 18 ---------- .../docs/make.bat | 36 ------------------- .../docs/readme.md | 1 + .../docs/readme.rst | 4 --- .../docs/{runthetests.rst => runthetests.md} | 0 .../docs/usage.rst | 7 ---- .../docs/{authors.rst => authors.md} | 0 .../docs/{history.rst => history.md} | 0 .../minos-microservice-common/docs/index.md | 16 +++++++++ .../minos-microservice-common/docs/index.rst | 18 ---------- .../minos-microservice-common/docs/make.bat | 36 ------------------- .../minos-microservice-common/docs/readme.md | 1 + .../minos-microservice-common/docs/readme.rst | 4 --- .../docs/{runthetests.rst => runthetests.md} | 0 .../minos-microservice-common/docs/usage.rst | 8 ----- .../minos/common/model/abc.py | 4 +-- .../minos/common/protocol/avro/base.py | 4 +-- .../docs/{authors.rst => authors.md} | 0 .../docs/{history.rst => history.md} | 0 .../minos-microservice-cqrs/docs/index.md | 16 +++++++++ .../minos-microservice-cqrs/docs/make.bat | 36 ------------------- .../minos-microservice-cqrs/docs/readme.md | 1 + .../minos-microservice-cqrs/docs/readme.rst | 4 --- .../docs/{runthetests.rst => runthetests.md} | 0 .../minos-microservice-cqrs/docs/usage.rst | 7 ---- .../docs/{authors.rst => authors.md} | 0 .../docs/{history.rst => history.md} | 0 .../minos-microservice-networks/docs/index.md | 16 +++++++++ .../docs/index.rst | 18 ---------- .../minos-microservice-networks/docs/make.bat | 36 ------------------- .../docs/modules.rst | 8 ----- .../docs/readme.md | 1 + .../docs/readme.rst | 4 --- .../docs/{runthetests.rst => runthetests.md} | 0 .../docs/usage.rst | 9 ----- .../minos-microservice-saga/docs/authors.md | 1 + .../minos-microservice-saga/docs/authors.rst | 1 - .../docs/{history.rst => history.md} | 0 .../minos-microservice-saga/docs/index.md | 16 +++++++++ .../minos-microservice-saga/docs/index.rst | 18 ---------- .../minos-microservice-saga/docs/make.bat | 36 ------------------- .../minos-microservice-saga/docs/readme.md | 1 + .../minos-microservice-saga/docs/readme.rst | 4 --- .../docs/{runthetests.rst => runthetests.md} | 0 .../minos-microservice-saga/docs/usage.rst | 7 ---- .../plugins/minos-broker-kafka/docs/index.md | 4 +-- .../plugins/minos-broker-kafka/docs/usage.md | 1 - .../minos-broker-rabbitmq/docs/index.md | 6 ++-- .../minos-broker-rabbitmq/docs/usage.md | 1 - .../minos-discovery-minos/docs/index.md | 4 +-- .../minos-discovery-minos/docs/usage.md | 1 - .../plugins/minos-http-aiohttp/docs/index.md | 3 +- .../plugins/minos-http-aiohttp/docs/usage.md | 1 - .../minos-router-graphql/docs/index.md | 4 +-- .../minos-router-graphql/docs/usage.md | 1 - 58 files changed, 87 insertions(+), 343 deletions(-) rename packages/core/minos-microservice-aggregate/docs/{authors.rst => authors.md} (100%) rename packages/core/minos-microservice-aggregate/docs/{history.rst => history.md} (100%) rename packages/core/{minos-microservice-cqrs/docs/index.rst => minos-microservice-aggregate/docs/index.md} (50%) delete mode 100644 packages/core/minos-microservice-aggregate/docs/index.rst delete mode 100644 packages/core/minos-microservice-aggregate/docs/make.bat create mode 100644 packages/core/minos-microservice-aggregate/docs/readme.md delete mode 100644 packages/core/minos-microservice-aggregate/docs/readme.rst rename packages/core/minos-microservice-aggregate/docs/{runthetests.rst => runthetests.md} (100%) delete mode 100644 packages/core/minos-microservice-aggregate/docs/usage.rst rename packages/core/minos-microservice-common/docs/{authors.rst => authors.md} (100%) rename packages/core/minos-microservice-common/docs/{history.rst => history.md} (100%) create mode 100644 packages/core/minos-microservice-common/docs/index.md delete mode 100644 packages/core/minos-microservice-common/docs/index.rst delete mode 100644 packages/core/minos-microservice-common/docs/make.bat create mode 100644 packages/core/minos-microservice-common/docs/readme.md delete mode 100644 packages/core/minos-microservice-common/docs/readme.rst rename packages/core/minos-microservice-common/docs/{runthetests.rst => runthetests.md} (100%) delete mode 100644 packages/core/minos-microservice-common/docs/usage.rst rename packages/core/minos-microservice-cqrs/docs/{authors.rst => authors.md} (100%) rename packages/core/minos-microservice-cqrs/docs/{history.rst => history.md} (100%) create mode 100644 packages/core/minos-microservice-cqrs/docs/index.md delete mode 100644 packages/core/minos-microservice-cqrs/docs/make.bat create mode 100644 packages/core/minos-microservice-cqrs/docs/readme.md delete mode 100644 packages/core/minos-microservice-cqrs/docs/readme.rst rename packages/core/minos-microservice-cqrs/docs/{runthetests.rst => runthetests.md} (100%) delete mode 100644 packages/core/minos-microservice-cqrs/docs/usage.rst rename packages/core/minos-microservice-networks/docs/{authors.rst => authors.md} (100%) rename packages/core/minos-microservice-networks/docs/{history.rst => history.md} (100%) create mode 100644 packages/core/minos-microservice-networks/docs/index.md delete mode 100644 packages/core/minos-microservice-networks/docs/index.rst delete mode 100644 packages/core/minos-microservice-networks/docs/make.bat delete mode 100644 packages/core/minos-microservice-networks/docs/modules.rst create mode 100644 packages/core/minos-microservice-networks/docs/readme.md delete mode 100644 packages/core/minos-microservice-networks/docs/readme.rst rename packages/core/minos-microservice-networks/docs/{runthetests.rst => runthetests.md} (100%) delete mode 100644 packages/core/minos-microservice-networks/docs/usage.rst create mode 100644 packages/core/minos-microservice-saga/docs/authors.md delete mode 100644 packages/core/minos-microservice-saga/docs/authors.rst rename packages/core/minos-microservice-saga/docs/{history.rst => history.md} (100%) create mode 100644 packages/core/minos-microservice-saga/docs/index.md delete mode 100644 packages/core/minos-microservice-saga/docs/index.rst delete mode 100644 packages/core/minos-microservice-saga/docs/make.bat create mode 100644 packages/core/minos-microservice-saga/docs/readme.md delete mode 100644 packages/core/minos-microservice-saga/docs/readme.rst rename packages/core/minos-microservice-saga/docs/{runthetests.rst => runthetests.md} (100%) delete mode 100644 packages/core/minos-microservice-saga/docs/usage.rst delete mode 100644 packages/plugins/minos-broker-kafka/docs/usage.md delete mode 100644 packages/plugins/minos-broker-rabbitmq/docs/usage.md delete mode 100644 packages/plugins/minos-discovery-minos/docs/usage.md delete mode 100644 packages/plugins/minos-http-aiohttp/docs/usage.md delete mode 100644 packages/plugins/minos-router-graphql/docs/usage.md diff --git a/packages/core/minos-microservice-aggregate/docs/authors.rst b/packages/core/minos-microservice-aggregate/docs/authors.md similarity index 100% rename from packages/core/minos-microservice-aggregate/docs/authors.rst rename to packages/core/minos-microservice-aggregate/docs/authors.md diff --git a/packages/core/minos-microservice-aggregate/docs/history.rst b/packages/core/minos-microservice-aggregate/docs/history.md similarity index 100% rename from packages/core/minos-microservice-aggregate/docs/history.rst rename to packages/core/minos-microservice-aggregate/docs/history.md diff --git a/packages/core/minos-microservice-cqrs/docs/index.rst b/packages/core/minos-microservice-aggregate/docs/index.md similarity index 50% rename from packages/core/minos-microservice-cqrs/docs/index.rst rename to packages/core/minos-microservice-aggregate/docs/index.md index 2b89d9b5b..3ad2062c7 100644 --- a/packages/core/minos-microservice-cqrs/docs/index.rst +++ b/packages/core/minos-microservice-aggregate/docs/index.md @@ -1,18 +1,15 @@ -Welcome to Minos Microservice CQRS's documentation! -====================================== +# Welcome to Minos Microservice Aggregate's documentation! .. toctree:: :maxdepth: 2 readme runthetests - usage api/minos authors history -Indices and tables -==================== +## Indices and tables * :ref:`genindex` * :ref:`modindex` * :ref:`search` diff --git a/packages/core/minos-microservice-aggregate/docs/index.rst b/packages/core/minos-microservice-aggregate/docs/index.rst deleted file mode 100644 index ec3d028b7..000000000 --- a/packages/core/minos-microservice-aggregate/docs/index.rst +++ /dev/null @@ -1,18 +0,0 @@ -Welcome to Minos Microservice Aggregate's documentation! -====================================== - -.. toctree:: - :maxdepth: 2 - - readme - runthetests - usage - api/minos - authors - history - -Indices and tables -==================== -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/core/minos-microservice-aggregate/docs/make.bat b/packages/core/minos-microservice-aggregate/docs/make.bat deleted file mode 100644 index 12f64c3bd..000000000 --- a/packages/core/minos-microservice-aggregate/docs/make.bat +++ /dev/null @@ -1,36 +0,0 @@ -@ECHO OFF - -pushd %~dp0 - -REM Command file for Sphinx documentation - -if "%SPHINXBUILD%" == "" ( - set SPHINXBUILD=python -msphinx -) -set SOURCEDIR=. -set BUILDDIR=_build -set SPHINXPROJ=minos_microservice_aggregate - -if "%1" == "" goto help - -%SPHINXBUILD% >NUL 2>NUL -if errorlevel 9009 ( - echo. - echo.The Sphinx module was not found. Make sure you have Sphinx installed, - echo.then set the SPHINXBUILD environment variable to point to the full - echo.path of the 'sphinx-build' executable. Alternatively you may add the - echo.Sphinx directory to PATH. - echo. - echo.If you don't have Sphinx installed, grab it from - echo.http://sphinx-doc.org/ - exit /b 1 -) - -%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% -goto end - -:help -%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% - -:end -popd diff --git a/packages/core/minos-microservice-aggregate/docs/readme.md b/packages/core/minos-microservice-aggregate/docs/readme.md new file mode 100644 index 000000000..97d495851 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/docs/readme.md @@ -0,0 +1 @@ +.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-aggregate/docs/readme.rst b/packages/core/minos-microservice-aggregate/docs/readme.rst deleted file mode 100644 index af09813a4..000000000 --- a/packages/core/minos-microservice-aggregate/docs/readme.rst +++ /dev/null @@ -1,4 +0,0 @@ -Introduction -************** - -.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-aggregate/docs/runthetests.rst b/packages/core/minos-microservice-aggregate/docs/runthetests.md similarity index 100% rename from packages/core/minos-microservice-aggregate/docs/runthetests.rst rename to packages/core/minos-microservice-aggregate/docs/runthetests.md diff --git a/packages/core/minos-microservice-aggregate/docs/usage.rst b/packages/core/minos-microservice-aggregate/docs/usage.rst deleted file mode 100644 index a4149f5cd..000000000 --- a/packages/core/minos-microservice-aggregate/docs/usage.rst +++ /dev/null @@ -1,7 +0,0 @@ -===== -Usage -===== - -To use Minos Microservice Aggregate in a project:: - - import minos_microservice_aggregate diff --git a/packages/core/minos-microservice-common/docs/authors.rst b/packages/core/minos-microservice-common/docs/authors.md similarity index 100% rename from packages/core/minos-microservice-common/docs/authors.rst rename to packages/core/minos-microservice-common/docs/authors.md diff --git a/packages/core/minos-microservice-common/docs/history.rst b/packages/core/minos-microservice-common/docs/history.md similarity index 100% rename from packages/core/minos-microservice-common/docs/history.rst rename to packages/core/minos-microservice-common/docs/history.md diff --git a/packages/core/minos-microservice-common/docs/index.md b/packages/core/minos-microservice-common/docs/index.md new file mode 100644 index 000000000..40d4b726b --- /dev/null +++ b/packages/core/minos-microservice-common/docs/index.md @@ -0,0 +1,16 @@ +# Welcome to Minos Microservice Common's documentation! + +.. toctree:: + :maxdepth: 2 + + readme + runthetests + api/minos + authors + history + +## Indices and tables + +* :ref:`genindex` +* :ref:`modindex` +* :ref:`search` diff --git a/packages/core/minos-microservice-common/docs/index.rst b/packages/core/minos-microservice-common/docs/index.rst deleted file mode 100644 index 5cdfdb36d..000000000 --- a/packages/core/minos-microservice-common/docs/index.rst +++ /dev/null @@ -1,18 +0,0 @@ -Welcome to Minos Microservice Common's documentation! -======================================================= - -.. toctree:: - :maxdepth: 2 - - readme - runthetests - usage - api/minos - authors - history - -Indices and tables -==================== -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/core/minos-microservice-common/docs/make.bat b/packages/core/minos-microservice-common/docs/make.bat deleted file mode 100644 index 3c73e0ecc..000000000 --- a/packages/core/minos-microservice-common/docs/make.bat +++ /dev/null @@ -1,36 +0,0 @@ -@ECHO OFF - -pushd %~dp0 - -REM Command file for Sphinx documentation - -if "%SPHINXBUILD%" == "" ( - set SPHINXBUILD=python -msphinx -) -set SOURCEDIR=. -set BUILDDIR=_build -set SPHINXPROJ=minos_microservice_common - -if "%1" == "" goto help - -%SPHINXBUILD% >NUL 2>NUL -if errorlevel 9009 ( - echo. - echo.The Sphinx module was not found. Make sure you have Sphinx installed, - echo.then set the SPHINXBUILD environment variable to point to the full - echo.path of the 'sphinx-build' executable. Alternatively you may add the - echo.Sphinx directory to PATH. - echo. - echo.If you don't have Sphinx installed, grab it from - echo.http://sphinx-doc.org/ - exit /b 1 -) - -%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% -goto end - -:help -%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% - -:end -popd diff --git a/packages/core/minos-microservice-common/docs/readme.md b/packages/core/minos-microservice-common/docs/readme.md new file mode 100644 index 000000000..97d495851 --- /dev/null +++ b/packages/core/minos-microservice-common/docs/readme.md @@ -0,0 +1 @@ +.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-common/docs/readme.rst b/packages/core/minos-microservice-common/docs/readme.rst deleted file mode 100644 index af09813a4..000000000 --- a/packages/core/minos-microservice-common/docs/readme.rst +++ /dev/null @@ -1,4 +0,0 @@ -Introduction -************** - -.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-common/docs/runthetests.rst b/packages/core/minos-microservice-common/docs/runthetests.md similarity index 100% rename from packages/core/minos-microservice-common/docs/runthetests.rst rename to packages/core/minos-microservice-common/docs/runthetests.md diff --git a/packages/core/minos-microservice-common/docs/usage.rst b/packages/core/minos-microservice-common/docs/usage.rst deleted file mode 100644 index 6a5226254..000000000 --- a/packages/core/minos-microservice-common/docs/usage.rst +++ /dev/null @@ -1,8 +0,0 @@ -===== -Usage -===== - -To use Minos Microservice Common in a project:: - - from minos import common - diff --git a/packages/core/minos-microservice-common/minos/common/model/abc.py b/packages/core/minos-microservice-common/minos/common/model/abc.py index cb6fa4051..ec16c2551 100644 --- a/packages/core/minos-microservice-common/minos/common/model/abc.py +++ b/packages/core/minos-microservice-common/minos/common/model/abc.py @@ -114,11 +114,11 @@ def from_avro_str(cls: Type[T], raw: str, **kwargs) -> Union[T, list[T]]: # noinspection PyUnusedLocal @classmethod def from_avro_bytes(cls: Type[T], raw: bytes, batch_mode: bool = False, **kwargs) -> Union[T, list[T]]: - """Build a single instance or a sequence of instances from bytes + """Build a single instance or a sequence of instances from bytes. :param raw: A ``bytes`` representation of the model. :param batch_mode: If ``True`` the data is processed as a list of models, otherwise the data is processed as a - single model. + single model. :param kwargs: Additional named arguments. :return: A single instance or a sequence of instances. """ diff --git a/packages/core/minos-microservice-common/minos/common/protocol/avro/base.py b/packages/core/minos-microservice-common/minos/common/protocol/avro/base.py index 1fd1154de..617494855 100644 --- a/packages/core/minos-microservice-common/minos/common/protocol/avro/base.py +++ b/packages/core/minos-microservice-common/minos/common/protocol/avro/base.py @@ -31,7 +31,7 @@ def encode(cls, value: Any, schema: Any, *args, batch_mode: bool = False, **kwar :param schema: The schema relative to the data. :param args: Additional positional arguments. :param batch_mode: If ``True`` the data is processed as a list of models, otherwise the data is processed as a - single model. + single model. :param kwargs: Additional named arguments. :return: A bytes object. """ @@ -69,7 +69,7 @@ def decode(cls, data: bytes, *args, batch_mode: bool = False, **kwargs) -> Any: :param data: A bytes object. :param args: Additional positional arguments. :param batch_mode: If ``True`` the data is processed as a list of models, otherwise the data is processed as a - single model. + single model. :param kwargs: Additional named arguments. :return: A dictionary or a list of dictionaries. """ diff --git a/packages/core/minos-microservice-cqrs/docs/authors.rst b/packages/core/minos-microservice-cqrs/docs/authors.md similarity index 100% rename from packages/core/minos-microservice-cqrs/docs/authors.rst rename to packages/core/minos-microservice-cqrs/docs/authors.md diff --git a/packages/core/minos-microservice-cqrs/docs/history.rst b/packages/core/minos-microservice-cqrs/docs/history.md similarity index 100% rename from packages/core/minos-microservice-cqrs/docs/history.rst rename to packages/core/minos-microservice-cqrs/docs/history.md diff --git a/packages/core/minos-microservice-cqrs/docs/index.md b/packages/core/minos-microservice-cqrs/docs/index.md new file mode 100644 index 000000000..d9d78632b --- /dev/null +++ b/packages/core/minos-microservice-cqrs/docs/index.md @@ -0,0 +1,16 @@ +# Welcome to Minos Microservice CQRS's documentation! + +.. toctree:: + :maxdepth: 2 + + readme + runthetests + api/minos + authors + history + +## Indices and tables + +* :ref:`genindex` +* :ref:`modindex` +* :ref:`search` diff --git a/packages/core/minos-microservice-cqrs/docs/make.bat b/packages/core/minos-microservice-cqrs/docs/make.bat deleted file mode 100644 index 49883f1e7..000000000 --- a/packages/core/minos-microservice-cqrs/docs/make.bat +++ /dev/null @@ -1,36 +0,0 @@ -@ECHO OFF - -pushd %~dp0 - -REM Command file for Sphinx documentation - -if "%SPHINXBUILD%" == "" ( - set SPHINXBUILD=python -msphinx -) -set SOURCEDIR=. -set BUILDDIR=_build -set SPHINXPROJ=minos_microservice_cqrs - -if "%1" == "" goto help - -%SPHINXBUILD% >NUL 2>NUL -if errorlevel 9009 ( - echo. - echo.The Sphinx module was not found. Make sure you have Sphinx installed, - echo.then set the SPHINXBUILD environment variable to point to the full - echo.path of the 'sphinx-build' executable. Alternatively you may add the - echo.Sphinx directory to PATH. - echo. - echo.If you don't have Sphinx installed, grab it from - echo.http://sphinx-doc.org/ - exit /b 1 -) - -%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% -goto end - -:help -%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% - -:end -popd diff --git a/packages/core/minos-microservice-cqrs/docs/readme.md b/packages/core/minos-microservice-cqrs/docs/readme.md new file mode 100644 index 000000000..97d495851 --- /dev/null +++ b/packages/core/minos-microservice-cqrs/docs/readme.md @@ -0,0 +1 @@ +.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-cqrs/docs/readme.rst b/packages/core/minos-microservice-cqrs/docs/readme.rst deleted file mode 100644 index af09813a4..000000000 --- a/packages/core/minos-microservice-cqrs/docs/readme.rst +++ /dev/null @@ -1,4 +0,0 @@ -Introduction -************** - -.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-cqrs/docs/runthetests.rst b/packages/core/minos-microservice-cqrs/docs/runthetests.md similarity index 100% rename from packages/core/minos-microservice-cqrs/docs/runthetests.rst rename to packages/core/minos-microservice-cqrs/docs/runthetests.md diff --git a/packages/core/minos-microservice-cqrs/docs/usage.rst b/packages/core/minos-microservice-cqrs/docs/usage.rst deleted file mode 100644 index 617674dc1..000000000 --- a/packages/core/minos-microservice-cqrs/docs/usage.rst +++ /dev/null @@ -1,7 +0,0 @@ -===== -Usage -===== - -To use Minos Microservice CQRS in a project:: - - import minos_microservice_cqrs diff --git a/packages/core/minos-microservice-networks/docs/authors.rst b/packages/core/minos-microservice-networks/docs/authors.md similarity index 100% rename from packages/core/minos-microservice-networks/docs/authors.rst rename to packages/core/minos-microservice-networks/docs/authors.md diff --git a/packages/core/minos-microservice-networks/docs/history.rst b/packages/core/minos-microservice-networks/docs/history.md similarity index 100% rename from packages/core/minos-microservice-networks/docs/history.rst rename to packages/core/minos-microservice-networks/docs/history.md diff --git a/packages/core/minos-microservice-networks/docs/index.md b/packages/core/minos-microservice-networks/docs/index.md new file mode 100644 index 000000000..e057f69c6 --- /dev/null +++ b/packages/core/minos-microservice-networks/docs/index.md @@ -0,0 +1,16 @@ +# Welcome to Minos Microservice Network's documentation! + +.. toctree:: + :maxdepth: 2 + + readme + runthetests + api/minos + authors + history + +## Indices and tables + +* :ref:`genindex` +* :ref:`modindex` +* :ref:`search` diff --git a/packages/core/minos-microservice-networks/docs/index.rst b/packages/core/minos-microservice-networks/docs/index.rst deleted file mode 100644 index 20c5a78f3..000000000 --- a/packages/core/minos-microservice-networks/docs/index.rst +++ /dev/null @@ -1,18 +0,0 @@ -Welcome to Minos Microservice Network's documentation! -======================================================= - -.. toctree:: - :maxdepth: 2 - - readme - runthetests - usage - api/minos - authors - history - -Indices and tables -==================== -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/core/minos-microservice-networks/docs/make.bat b/packages/core/minos-microservice-networks/docs/make.bat deleted file mode 100644 index 3e4631be9..000000000 --- a/packages/core/minos-microservice-networks/docs/make.bat +++ /dev/null @@ -1,36 +0,0 @@ -@ECHO OFF - -pushd %~dp0 - -REM Command file for Sphinx documentation - -if "%SPHINXBUILD%" == "" ( - set SPHINXBUILD=python -msphinx -) -set SOURCEDIR=. -set BUILDDIR=_build -set SPHINXPROJ=minos_microservice_networks - -if "%1" == "" goto help - -%SPHINXBUILD% >NUL 2>NUL -if errorlevel 9009 ( - echo. - echo.The Sphinx module was not found. Make sure you have Sphinx installed, - echo.then set the SPHINXBUILD environment variable to point to the full - echo.path of the 'sphinx-build' executable. Alternatively you may add the - echo.Sphinx directory to PATH. - echo. - echo.If you don't have Sphinx installed, grab it from - echo.http://sphinx-doc.org/ - exit /b 1 -) - -%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% -goto end - -:help -%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% - -:end -popd diff --git a/packages/core/minos-microservice-networks/docs/modules.rst b/packages/core/minos-microservice-networks/docs/modules.rst deleted file mode 100644 index 9201e6d9e..000000000 --- a/packages/core/minos-microservice-networks/docs/modules.rst +++ /dev/null @@ -1,8 +0,0 @@ -======= -Modules -======= - -.. toctree:: - :maxdepth: 2 - - api/minos diff --git a/packages/core/minos-microservice-networks/docs/readme.md b/packages/core/minos-microservice-networks/docs/readme.md new file mode 100644 index 000000000..97d495851 --- /dev/null +++ b/packages/core/minos-microservice-networks/docs/readme.md @@ -0,0 +1 @@ +.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-networks/docs/readme.rst b/packages/core/minos-microservice-networks/docs/readme.rst deleted file mode 100644 index af09813a4..000000000 --- a/packages/core/minos-microservice-networks/docs/readme.rst +++ /dev/null @@ -1,4 +0,0 @@ -Introduction -************** - -.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-networks/docs/runthetests.rst b/packages/core/minos-microservice-networks/docs/runthetests.md similarity index 100% rename from packages/core/minos-microservice-networks/docs/runthetests.rst rename to packages/core/minos-microservice-networks/docs/runthetests.md diff --git a/packages/core/minos-microservice-networks/docs/usage.rst b/packages/core/minos-microservice-networks/docs/usage.rst deleted file mode 100644 index 9a8247b53..000000000 --- a/packages/core/minos-microservice-networks/docs/usage.rst +++ /dev/null @@ -1,9 +0,0 @@ -===== -Usage -===== - -To use Minos Microservice Networks in a project:: - - import minos_microservice_common - - diff --git a/packages/core/minos-microservice-saga/docs/authors.md b/packages/core/minos-microservice-saga/docs/authors.md new file mode 100644 index 000000000..cf16fc494 --- /dev/null +++ b/packages/core/minos-microservice-saga/docs/authors.md @@ -0,0 +1 @@ +.. mdinclude:: ../AUTHORS.md diff --git a/packages/core/minos-microservice-saga/docs/authors.rst b/packages/core/minos-microservice-saga/docs/authors.rst deleted file mode 100644 index bcfd9cb00..000000000 --- a/packages/core/minos-microservice-saga/docs/authors.rst +++ /dev/null @@ -1 +0,0 @@ -.. include:: ../AUTHORS.md diff --git a/packages/core/minos-microservice-saga/docs/history.rst b/packages/core/minos-microservice-saga/docs/history.md similarity index 100% rename from packages/core/minos-microservice-saga/docs/history.rst rename to packages/core/minos-microservice-saga/docs/history.md diff --git a/packages/core/minos-microservice-saga/docs/index.md b/packages/core/minos-microservice-saga/docs/index.md new file mode 100644 index 000000000..63ebb97d9 --- /dev/null +++ b/packages/core/minos-microservice-saga/docs/index.md @@ -0,0 +1,16 @@ +# Welcome to Minos Microservice Saga's documentation! + +.. toctree:: + :maxdepth: 2 + + readme + runthetests + api/minos + authors + history + +## Indices and tables + +* :ref:`genindex` +* :ref:`modindex` +* :ref:`search` diff --git a/packages/core/minos-microservice-saga/docs/index.rst b/packages/core/minos-microservice-saga/docs/index.rst deleted file mode 100644 index b1860482b..000000000 --- a/packages/core/minos-microservice-saga/docs/index.rst +++ /dev/null @@ -1,18 +0,0 @@ -Welcome to Minos Microservice Saga's documentation! -======================================================= - -.. toctree:: - :maxdepth: 2 - - readme - runthetests - usage - api/minos - authors - history - -Indices and tables -==================== -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/core/minos-microservice-saga/docs/make.bat b/packages/core/minos-microservice-saga/docs/make.bat deleted file mode 100644 index 0be133d1b..000000000 --- a/packages/core/minos-microservice-saga/docs/make.bat +++ /dev/null @@ -1,36 +0,0 @@ -@ECHO OFF - -pushd %~dp0 - -REM Command file for Sphinx documentation - -if "%SPHINXBUILD%" == "" ( - set SPHINXBUILD=python -msphinx -) -set SOURCEDIR=. -set BUILDDIR=_build -set SPHINXPROJ=minos_microservice_saga - -if "%1" == "" goto help - -%SPHINXBUILD% >NUL 2>NUL -if errorlevel 9009 ( - echo. - echo.The Sphinx module was not found. Make sure you have Sphinx installed, - echo.then set the SPHINXBUILD environment variable to point to the full - echo.path of the 'sphinx-build' executable. Alternatively you may add the - echo.Sphinx directory to PATH. - echo. - echo.If you don't have Sphinx installed, grab it from - echo.http://sphinx-doc.org/ - exit /b 1 -) - -%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% -goto end - -:help -%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% - -:end -popd diff --git a/packages/core/minos-microservice-saga/docs/readme.md b/packages/core/minos-microservice-saga/docs/readme.md new file mode 100644 index 000000000..97d495851 --- /dev/null +++ b/packages/core/minos-microservice-saga/docs/readme.md @@ -0,0 +1 @@ +.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-saga/docs/readme.rst b/packages/core/minos-microservice-saga/docs/readme.rst deleted file mode 100644 index af09813a4..000000000 --- a/packages/core/minos-microservice-saga/docs/readme.rst +++ /dev/null @@ -1,4 +0,0 @@ -Introduction -************** - -.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-saga/docs/runthetests.rst b/packages/core/minos-microservice-saga/docs/runthetests.md similarity index 100% rename from packages/core/minos-microservice-saga/docs/runthetests.rst rename to packages/core/minos-microservice-saga/docs/runthetests.md diff --git a/packages/core/minos-microservice-saga/docs/usage.rst b/packages/core/minos-microservice-saga/docs/usage.rst deleted file mode 100644 index f5df84d05..000000000 --- a/packages/core/minos-microservice-saga/docs/usage.rst +++ /dev/null @@ -1,7 +0,0 @@ -===== -Usage -===== - -To use Minos Microservice Saga in a project:: - - from minos import saga diff --git a/packages/plugins/minos-broker-kafka/docs/index.md b/packages/plugins/minos-broker-kafka/docs/index.md index 38de1cc89..84373f9c9 100644 --- a/packages/plugins/minos-broker-kafka/docs/index.md +++ b/packages/plugins/minos-broker-kafka/docs/index.md @@ -5,12 +5,12 @@ readme runthetests - usage api/minos.plugins authors history -# Indices and tables +## Indices and tables + * :ref:`genindex` * :ref:`modindex` * :ref:`search` diff --git a/packages/plugins/minos-broker-kafka/docs/usage.md b/packages/plugins/minos-broker-kafka/docs/usage.md deleted file mode 100644 index 8f04b05ad..000000000 --- a/packages/plugins/minos-broker-kafka/docs/usage.md +++ /dev/null @@ -1 +0,0 @@ -# Usage diff --git a/packages/plugins/minos-broker-rabbitmq/docs/index.md b/packages/plugins/minos-broker-rabbitmq/docs/index.md index dcece9b84..692dfb31e 100644 --- a/packages/plugins/minos-broker-rabbitmq/docs/index.md +++ b/packages/plugins/minos-broker-rabbitmq/docs/index.md @@ -5,12 +5,12 @@ readme runthetests - usage - api/minos + api/minos.plugins authors history -# Indices and tables +## Indices and tables + * :ref:`genindex` * :ref:`modindex` * :ref:`search` diff --git a/packages/plugins/minos-broker-rabbitmq/docs/usage.md b/packages/plugins/minos-broker-rabbitmq/docs/usage.md deleted file mode 100644 index 8f04b05ad..000000000 --- a/packages/plugins/minos-broker-rabbitmq/docs/usage.md +++ /dev/null @@ -1 +0,0 @@ -# Usage diff --git a/packages/plugins/minos-discovery-minos/docs/index.md b/packages/plugins/minos-discovery-minos/docs/index.md index b470bca77..2d96d79e5 100644 --- a/packages/plugins/minos-discovery-minos/docs/index.md +++ b/packages/plugins/minos-discovery-minos/docs/index.md @@ -5,12 +5,12 @@ readme runthetests - usage api/minos.plugins authors history -# Indices and tables +## Indices and tables + * :ref:`genindex` * :ref:`modindex` * :ref:`search` diff --git a/packages/plugins/minos-discovery-minos/docs/usage.md b/packages/plugins/minos-discovery-minos/docs/usage.md deleted file mode 100644 index 8f04b05ad..000000000 --- a/packages/plugins/minos-discovery-minos/docs/usage.md +++ /dev/null @@ -1 +0,0 @@ -# Usage diff --git a/packages/plugins/minos-http-aiohttp/docs/index.md b/packages/plugins/minos-http-aiohttp/docs/index.md index 5e842068d..4f215a105 100644 --- a/packages/plugins/minos-http-aiohttp/docs/index.md +++ b/packages/plugins/minos-http-aiohttp/docs/index.md @@ -10,7 +10,8 @@ authors history -# Indices and tables +## Indices and tables + * :ref:`genindex` * :ref:`modindex` * :ref:`search` diff --git a/packages/plugins/minos-http-aiohttp/docs/usage.md b/packages/plugins/minos-http-aiohttp/docs/usage.md deleted file mode 100644 index 8f04b05ad..000000000 --- a/packages/plugins/minos-http-aiohttp/docs/usage.md +++ /dev/null @@ -1 +0,0 @@ -# Usage diff --git a/packages/plugins/minos-router-graphql/docs/index.md b/packages/plugins/minos-router-graphql/docs/index.md index afb71f631..aff45744f 100644 --- a/packages/plugins/minos-router-graphql/docs/index.md +++ b/packages/plugins/minos-router-graphql/docs/index.md @@ -6,12 +6,12 @@ This plugin integrates the official graphql-core library. readme runthetests - usage api/minos.plugins authors history -# Indices and tables +## Indices and tables + * :ref:`genindex` * :ref:`modindex` * :ref:`search` diff --git a/packages/plugins/minos-router-graphql/docs/usage.md b/packages/plugins/minos-router-graphql/docs/usage.md deleted file mode 100644 index 8f04b05ad..000000000 --- a/packages/plugins/minos-router-graphql/docs/usage.md +++ /dev/null @@ -1 +0,0 @@ -# Usage From 6db8b0de2cacbfdfb8ca9b81022811bca7285264 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 30 Mar 2022 11:58:50 +0200 Subject: [PATCH 002/324] ISSUE #332 * Improving documentation building process. --- .../minos-microservice-aggregate/docs/conf.py | 146 +----------------- .../docs/index.md | 4 +- .../docs/readme.md | 2 + .../minos-microservice-common/docs/index.md | 2 +- .../minos-microservice-common/docs/readme.md | 2 + .../minos-microservice-cqrs/docs/index.md | 2 +- .../minos-microservice-cqrs/docs/readme.md | 2 + .../minos-microservice-networks/docs/index.md | 2 +- .../docs/readme.md | 2 + .../minos-microservice-saga/docs/index.md | 2 +- .../minos-microservice-saga/docs/readme.md | 2 + .../plugins/minos-broker-kafka/docs/index.md | 2 +- .../plugins/minos-broker-kafka/docs/readme.md | 2 +- .../minos-broker-rabbitmq/docs/index.md | 2 +- .../minos-broker-rabbitmq/docs/readme.md | 2 +- .../minos-discovery-minos/docs/index.md | 2 +- .../minos-discovery-minos/docs/readme.md | 2 +- .../plugins/minos-http-aiohttp/docs/index.md | 2 +- .../plugins/minos-http-aiohttp/docs/readme.md | 2 +- .../minos-router-graphql/docs/index.md | 2 +- .../minos-router-graphql/docs/readme.md | 2 +- 21 files changed, 29 insertions(+), 159 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/docs/conf.py b/packages/core/minos-microservice-aggregate/docs/conf.py index bd3a84574..18d99fc0f 100755 --- a/packages/core/minos-microservice-aggregate/docs/conf.py +++ b/packages/core/minos-microservice-aggregate/docs/conf.py @@ -1,43 +1,13 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# import os import sys +from datetime import datetime sys.path.insert(0, os.path.abspath("..")) -import sphinx_rtd_theme - from minos import ( aggregate, ) -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - extensions = [ "sphinxcontrib.apidoc", "sphinx.ext.autodoc", @@ -46,136 +16,27 @@ "sphinx_rtd_theme", "m2r2", ] -# Add any paths that contain templates here, relative to this directory. templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# source_suffix = [".rst", ".md"] -# The master toctree document. master_doc = "index" - -# General information about the project. -project = "Minos Microservice Aggregate" -copyright = "2021, Clariteia" +project = "minos-microservice-aggregate" +copyright = f"2021-{datetime.now().year}, Clariteia" author = "Minos Framework Devs" -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. version = aggregate.__version__ -# The full version, including alpha/beta/rc tags. release = aggregate.__version__ -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] -# The name of the Pygments (syntax highlighting) style to use. pygments_style = "sphinx" -# If true, `todo` and `todoList` produce output, else they produce nothing. todo_include_todos = False - - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "aggregate", -# "github_type": "star", -# } - html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". html_static_path = ["_static"] - - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. htmlhelp_basename = "minosdoc" - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Microservice Aggregate Documentation", "Minos Framework Devs", "manual"), -] - - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Microservice Aggregate Documentation", [author], 1)] - - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Microservice Aggregate Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension apidoc_module_dir = "../minos" apidoc_output_dir = "api" apidoc_separate_modules = True @@ -191,7 +52,6 @@ "--force", "--implicit-namespaces", ] -# "autodoc typehints" extension set_type_checking_flag = True typehints_fully_qualified = True diff --git a/packages/core/minos-microservice-aggregate/docs/index.md b/packages/core/minos-microservice-aggregate/docs/index.md index 3ad2062c7..5b4febf9f 100644 --- a/packages/core/minos-microservice-aggregate/docs/index.md +++ b/packages/core/minos-microservice-aggregate/docs/index.md @@ -1,7 +1,7 @@ -# Welcome to Minos Microservice Aggregate's documentation! +# Welcome to `minos-microservice-aggregate`'s documentation! .. toctree:: - :maxdepth: 2 + :maxdepth: 1 readme runthetests diff --git a/packages/core/minos-microservice-aggregate/docs/readme.md b/packages/core/minos-microservice-aggregate/docs/readme.md index 97d495851..9a7702cfc 100644 --- a/packages/core/minos-microservice-aggregate/docs/readme.md +++ b/packages/core/minos-microservice-aggregate/docs/readme.md @@ -1 +1,3 @@ +# Readme + .. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-common/docs/index.md b/packages/core/minos-microservice-common/docs/index.md index 40d4b726b..92681672b 100644 --- a/packages/core/minos-microservice-common/docs/index.md +++ b/packages/core/minos-microservice-common/docs/index.md @@ -1,7 +1,7 @@ # Welcome to Minos Microservice Common's documentation! .. toctree:: - :maxdepth: 2 + :maxdepth: 1 readme runthetests diff --git a/packages/core/minos-microservice-common/docs/readme.md b/packages/core/minos-microservice-common/docs/readme.md index 97d495851..9a7702cfc 100644 --- a/packages/core/minos-microservice-common/docs/readme.md +++ b/packages/core/minos-microservice-common/docs/readme.md @@ -1 +1,3 @@ +# Readme + .. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-cqrs/docs/index.md b/packages/core/minos-microservice-cqrs/docs/index.md index d9d78632b..f7a299cc4 100644 --- a/packages/core/minos-microservice-cqrs/docs/index.md +++ b/packages/core/minos-microservice-cqrs/docs/index.md @@ -1,7 +1,7 @@ # Welcome to Minos Microservice CQRS's documentation! .. toctree:: - :maxdepth: 2 + :maxdepth: 1 readme runthetests diff --git a/packages/core/minos-microservice-cqrs/docs/readme.md b/packages/core/minos-microservice-cqrs/docs/readme.md index 97d495851..9a7702cfc 100644 --- a/packages/core/minos-microservice-cqrs/docs/readme.md +++ b/packages/core/minos-microservice-cqrs/docs/readme.md @@ -1 +1,3 @@ +# Readme + .. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-networks/docs/index.md b/packages/core/minos-microservice-networks/docs/index.md index e057f69c6..3dd9c300e 100644 --- a/packages/core/minos-microservice-networks/docs/index.md +++ b/packages/core/minos-microservice-networks/docs/index.md @@ -1,7 +1,7 @@ # Welcome to Minos Microservice Network's documentation! .. toctree:: - :maxdepth: 2 + :maxdepth: 1 readme runthetests diff --git a/packages/core/minos-microservice-networks/docs/readme.md b/packages/core/minos-microservice-networks/docs/readme.md index 97d495851..9a7702cfc 100644 --- a/packages/core/minos-microservice-networks/docs/readme.md +++ b/packages/core/minos-microservice-networks/docs/readme.md @@ -1 +1,3 @@ +# Readme + .. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-saga/docs/index.md b/packages/core/minos-microservice-saga/docs/index.md index 63ebb97d9..3dabc853e 100644 --- a/packages/core/minos-microservice-saga/docs/index.md +++ b/packages/core/minos-microservice-saga/docs/index.md @@ -1,7 +1,7 @@ # Welcome to Minos Microservice Saga's documentation! .. toctree:: - :maxdepth: 2 + :maxdepth: 1 readme runthetests diff --git a/packages/core/minos-microservice-saga/docs/readme.md b/packages/core/minos-microservice-saga/docs/readme.md index 97d495851..9a7702cfc 100644 --- a/packages/core/minos-microservice-saga/docs/readme.md +++ b/packages/core/minos-microservice-saga/docs/readme.md @@ -1 +1,3 @@ +# Readme + .. mdinclude:: ../README.md diff --git a/packages/plugins/minos-broker-kafka/docs/index.md b/packages/plugins/minos-broker-kafka/docs/index.md index 84373f9c9..2b4e1c123 100644 --- a/packages/plugins/minos-broker-kafka/docs/index.md +++ b/packages/plugins/minos-broker-kafka/docs/index.md @@ -1,7 +1,7 @@ # Welcome to Minos Broker Kafka's documentation! .. toctree:: - :maxdepth: 2 + :maxdepth: 1 readme runthetests diff --git a/packages/plugins/minos-broker-kafka/docs/readme.md b/packages/plugins/minos-broker-kafka/docs/readme.md index da72dbef1..9a7702cfc 100644 --- a/packages/plugins/minos-broker-kafka/docs/readme.md +++ b/packages/plugins/minos-broker-kafka/docs/readme.md @@ -1,3 +1,3 @@ -# Introduction +# Readme .. mdinclude:: ../README.md diff --git a/packages/plugins/minos-broker-rabbitmq/docs/index.md b/packages/plugins/minos-broker-rabbitmq/docs/index.md index 692dfb31e..ab82e0fab 100644 --- a/packages/plugins/minos-broker-rabbitmq/docs/index.md +++ b/packages/plugins/minos-broker-rabbitmq/docs/index.md @@ -1,7 +1,7 @@ # Welcome to Minos Broker RabbitMQ's documentation! .. toctree:: - :maxdepth: 2 + :maxdepth: 1 readme runthetests diff --git a/packages/plugins/minos-broker-rabbitmq/docs/readme.md b/packages/plugins/minos-broker-rabbitmq/docs/readme.md index da72dbef1..9a7702cfc 100644 --- a/packages/plugins/minos-broker-rabbitmq/docs/readme.md +++ b/packages/plugins/minos-broker-rabbitmq/docs/readme.md @@ -1,3 +1,3 @@ -# Introduction +# Readme .. mdinclude:: ../README.md diff --git a/packages/plugins/minos-discovery-minos/docs/index.md b/packages/plugins/minos-discovery-minos/docs/index.md index 2d96d79e5..6e892f8fd 100644 --- a/packages/plugins/minos-discovery-minos/docs/index.md +++ b/packages/plugins/minos-discovery-minos/docs/index.md @@ -1,7 +1,7 @@ # Welcome to Minos Discovery Minos's documentation! .. toctree:: - :maxdepth: 2 + :maxdepth: 1 readme runthetests diff --git a/packages/plugins/minos-discovery-minos/docs/readme.md b/packages/plugins/minos-discovery-minos/docs/readme.md index da72dbef1..9a7702cfc 100644 --- a/packages/plugins/minos-discovery-minos/docs/readme.md +++ b/packages/plugins/minos-discovery-minos/docs/readme.md @@ -1,3 +1,3 @@ -# Introduction +# Readme .. mdinclude:: ../README.md diff --git a/packages/plugins/minos-http-aiohttp/docs/index.md b/packages/plugins/minos-http-aiohttp/docs/index.md index 4f215a105..f9e341d25 100644 --- a/packages/plugins/minos-http-aiohttp/docs/index.md +++ b/packages/plugins/minos-http-aiohttp/docs/index.md @@ -1,7 +1,7 @@ # Welcome to Minos AIOHTTP's documentation! .. toctree:: - :maxdepth: 2 + :maxdepth: 1 readme runthetests diff --git a/packages/plugins/minos-http-aiohttp/docs/readme.md b/packages/plugins/minos-http-aiohttp/docs/readme.md index da72dbef1..9a7702cfc 100644 --- a/packages/plugins/minos-http-aiohttp/docs/readme.md +++ b/packages/plugins/minos-http-aiohttp/docs/readme.md @@ -1,3 +1,3 @@ -# Introduction +# Readme .. mdinclude:: ../README.md diff --git a/packages/plugins/minos-router-graphql/docs/index.md b/packages/plugins/minos-router-graphql/docs/index.md index aff45744f..ee0c06e68 100644 --- a/packages/plugins/minos-router-graphql/docs/index.md +++ b/packages/plugins/minos-router-graphql/docs/index.md @@ -2,7 +2,7 @@ This plugin integrates the official graphql-core library. .. toctree:: - :maxdepth: 2 + :maxdepth: 1 readme runthetests diff --git a/packages/plugins/minos-router-graphql/docs/readme.md b/packages/plugins/minos-router-graphql/docs/readme.md index da72dbef1..9a7702cfc 100644 --- a/packages/plugins/minos-router-graphql/docs/readme.md +++ b/packages/plugins/minos-router-graphql/docs/readme.md @@ -1,3 +1,3 @@ -# Introduction +# Readme .. mdinclude:: ../README.md From 33c8ed64a1a8451471f23b4df3affebb33729e40 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 30 Mar 2022 13:34:59 +0200 Subject: [PATCH 003/324] ISSUE #332 * Minor improvements. --- .../minos-microservice-aggregate/minos/aggregate/queries.py | 4 ++-- .../minos/aggregate/snapshots/pg/readers.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/queries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/queries.py index efe8ac77d..66411ed65 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/queries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/queries.py @@ -173,11 +173,11 @@ class Condition: * `LOWER_EQUAL`: Evaluates as `True` only if the field of the given model is lower or equal (<=) to the parameter. * `GREATER`: Evaluates as `True` only if the field of the given model is greater (>) than the parameter. * `GREATER_EQUAL`: Evaluates as `True` only if the field of the given model is greater or equal (>=) to the - parameter. + parameter. * `EQUAL`: Evaluates as `True` only if the field of the given model is equal (==) to the parameter. * `NOT_EQUAL`: Evaluates as `True` only if the field of the given model is not equal (!=) to the parameter. * `IN`: Evaluates as `True` only if the field of the given model belongs (in) to the parameter (which must be a - collection). + collection). * `LIKE`: Evaluates as `True` only if the field of the given model matches to the parameter _pattern. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py index 9793b7ddc..7ec0eff9d 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py @@ -116,7 +116,7 @@ async def find_entries( transaction is extracted from the context var. If not any transaction is being scoped then the query is performed to the global snapshot. :param exclude_deleted: If ``True``, deleted ``RootEntity`` entries are included, otherwise deleted - ``RootEntity`` entries are filtered. + ``RootEntity`` entries are filtered. :param kwargs: Additional named arguments. :return: An asynchronous iterator that containing the ``RootEntity`` instances. """ From 908c8746452beeefc7aa999d0934614bbb24c1ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 30 Mar 2022 13:35:28 +0200 Subject: [PATCH 004/324] ISSUE #332 * Working on autodoc --- .../core/minos-microservice-aggregate/docs/conf.py | 14 +++++--------- .../minos-microservice-aggregate/docs/index.md | 2 +- .../minos-microservice-aggregate/docs/reference.md | 6 ++++++ 3 files changed, 12 insertions(+), 10 deletions(-) create mode 100644 packages/core/minos-microservice-aggregate/docs/reference.md diff --git a/packages/core/minos-microservice-aggregate/docs/conf.py b/packages/core/minos-microservice-aggregate/docs/conf.py index 18d99fc0f..da7c0ba41 100755 --- a/packages/core/minos-microservice-aggregate/docs/conf.py +++ b/packages/core/minos-microservice-aggregate/docs/conf.py @@ -40,18 +40,14 @@ apidoc_module_dir = "../minos" apidoc_output_dir = "api" apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False apidoc_module_first = True apidoc_extra_args = [ "--force", "--implicit-namespaces", ] +autodoc_default_options = { + "inherited-members": True, + "undoc-members": True, +} +autodoc_member_order = "bysource" -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/core/minos-microservice-aggregate/docs/index.md b/packages/core/minos-microservice-aggregate/docs/index.md index 5b4febf9f..b979a59b9 100644 --- a/packages/core/minos-microservice-aggregate/docs/index.md +++ b/packages/core/minos-microservice-aggregate/docs/index.md @@ -4,8 +4,8 @@ :maxdepth: 1 readme + reference runthetests - api/minos authors history diff --git a/packages/core/minos-microservice-aggregate/docs/reference.md b/packages/core/minos-microservice-aggregate/docs/reference.md new file mode 100644 index 000000000..fdd1327ae --- /dev/null +++ b/packages/core/minos-microservice-aggregate/docs/reference.md @@ -0,0 +1,6 @@ +# API Reference + +.. toctree:: + :maxdepth: 5 + + api/modules \ No newline at end of file From 7ebbbeacc1bbb3c494d722c11dbf762c13ec4438 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 30 Mar 2022 13:57:52 +0200 Subject: [PATCH 005/324] ISSUE #332 * Properly set namespace. --- .../minos/common/injections/decorators.py | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/core/minos-microservice-common/minos/common/injections/decorators.py b/packages/core/minos-microservice-common/minos/common/injections/decorators.py index baa15a80d..ea299ab77 100644 --- a/packages/core/minos-microservice-common/minos/common/injections/decorators.py +++ b/packages/core/minos-microservice-common/minos/common/injections/decorators.py @@ -73,6 +73,7 @@ def __call__(self, input_type: InputType) -> OutputType: # noinspection PyTypeChecker output_type: OutputType = types.new_class(input_type.__name__, bases, {}) + output_type.__module__ = input_type.__module__ # noinspection PyProtectedMember output_type._set_injectable_name(self._name) From f5076568b46a9bebcabd1dddca5e56b43a9d8d88 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 30 Mar 2022 14:22:03 +0200 Subject: [PATCH 006/324] ISSUE #332 * Improve documentation. --- .../docs/_static/style.css | 16 ++++++++++++++ .../minos-microservice-aggregate/docs/conf.py | 4 ++-- .../minos-microservice-aggregate/poetry.lock | 21 +------------------ .../pyproject.toml | 1 - 4 files changed, 19 insertions(+), 23 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/docs/_static/style.css b/packages/core/minos-microservice-aggregate/docs/_static/style.css index 8aa6c288f..d05920cb6 100644 --- a/packages/core/minos-microservice-aggregate/docs/_static/style.css +++ b/packages/core/minos-microservice-aggregate/docs/_static/style.css @@ -1,3 +1,19 @@ .wy-nav-content { max-width: 1200px !important; } +/* Newlines (\a) and spaces (\20) before each parameter */ +.sig-param::before { + content: "\a\20\20\20\20\20\20\20\20\20\20\20\20\20\20\20\20"; + white-space: pre; +} + +/* Newline after the last parameter (so the closing bracket is on a new line) */ +dt em.sig-param:last-of-type::after { + content: "\a"; + white-space: pre; +} + +/* To have blue background of width of the block (instead of width of content) */ +dl.class > dt:first-of-type { + display: block !important; +} \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/docs/conf.py b/packages/core/minos-microservice-aggregate/docs/conf.py index da7c0ba41..08885d4f1 100755 --- a/packages/core/minos-microservice-aggregate/docs/conf.py +++ b/packages/core/minos-microservice-aggregate/docs/conf.py @@ -11,7 +11,6 @@ extensions = [ "sphinxcontrib.apidoc", "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", "sphinx.ext.viewcode", "sphinx_rtd_theme", "m2r2", @@ -49,5 +48,6 @@ "inherited-members": True, "undoc-members": True, } +autoclass_content = "both" autodoc_member_order = "bysource" - +autodoc_typehints_format = "short" diff --git a/packages/core/minos-microservice-aggregate/poetry.lock b/packages/core/minos-microservice-aggregate/poetry.lock index 16f003c05..e985553b3 100644 --- a/packages/core/minos-microservice-aggregate/poetry.lock +++ b/packages/core/minos-microservice-aggregate/poetry.lock @@ -675,21 +675,6 @@ docs = ["sphinxcontrib-websupport"] lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - [[package]] name = "sphinx-rtd-theme" version = "1.0.0" @@ -871,7 +856,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "7371da2d5d13ab97d2bd9539bab6c57260134ac0a0859728f2f9a685323002ad" +content-hash = "932671cb0c292ef96dfb260fba1f120bb3f61957e952ef814b943f0b355129da" [metadata.files] aiomisc = [ @@ -1389,10 +1374,6 @@ sphinx = [ {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, ] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] sphinx-rtd-theme = [ {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index bc41cf257..6f65bf75d 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -46,7 +46,6 @@ coverage = "^6.3" flake8 = "^4.0.1" Sphinx = "^4.0.1" pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.17.0" sphinxcontrib-apidoc = "^0.3.0" sphinx-rtd-theme = "^1.0.0" m2r2 = "^0.3.2" From 9620f9c726edc9e87906149323a0687450633f24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 30 Mar 2022 17:14:00 +0200 Subject: [PATCH 007/324] ISSUE #332 * Update documentation building process. --- .../{HISTORY.md => CHANGELOG.md} | 2 +- .../docs/_static/style.css | 16 ------ .../docs/_templates/package.rst_t | 49 +++++++++++++++++++ .../docs/changelog.md | 1 + .../minos-microservice-aggregate/docs/conf.py | 12 +++-- .../docs/history.md | 1 - .../docs/index.md | 2 +- .../docs/reference.md | 3 +- .../minos/aggregate/contextvars.py | 4 ++ .../aggregate/transactions/contextvars.py | 3 ++ 10 files changed, 68 insertions(+), 25 deletions(-) rename packages/core/minos-microservice-aggregate/{HISTORY.md => CHANGELOG.md} (99%) create mode 100644 packages/core/minos-microservice-aggregate/docs/_templates/package.rst_t create mode 100644 packages/core/minos-microservice-aggregate/docs/changelog.md delete mode 100644 packages/core/minos-microservice-aggregate/docs/history.md diff --git a/packages/core/minos-microservice-aggregate/HISTORY.md b/packages/core/minos-microservice-aggregate/CHANGELOG.md similarity index 99% rename from packages/core/minos-microservice-aggregate/HISTORY.md rename to packages/core/minos-microservice-aggregate/CHANGELOG.md index f010edf94..be3dd2d75 100644 --- a/packages/core/minos-microservice-aggregate/HISTORY.md +++ b/packages/core/minos-microservice-aggregate/CHANGELOG.md @@ -1,4 +1,4 @@ -# History +# Changelog ## 0.1.0 (2021-11-08) diff --git a/packages/core/minos-microservice-aggregate/docs/_static/style.css b/packages/core/minos-microservice-aggregate/docs/_static/style.css index d05920cb6..00a18c905 100644 --- a/packages/core/minos-microservice-aggregate/docs/_static/style.css +++ b/packages/core/minos-microservice-aggregate/docs/_static/style.css @@ -1,19 +1,3 @@ .wy-nav-content { max-width: 1200px !important; -} -/* Newlines (\a) and spaces (\20) before each parameter */ -.sig-param::before { - content: "\a\20\20\20\20\20\20\20\20\20\20\20\20\20\20\20\20"; - white-space: pre; -} - -/* Newline after the last parameter (so the closing bracket is on a new line) */ -dt em.sig-param:last-of-type::after { - content: "\a"; - white-space: pre; -} - -/* To have blue background of width of the block (instead of width of content) */ -dl.class > dt:first-of-type { - display: block !important; } \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/docs/_templates/package.rst_t b/packages/core/minos-microservice-aggregate/docs/_templates/package.rst_t new file mode 100644 index 000000000..87efea5e7 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/docs/_templates/package.rst_t @@ -0,0 +1,49 @@ +{%- macro automodule(modname, options) -%} +.. automodule:: {{ modname }} +{%- for option in options %} + :{{ option }}: +{%- endfor %} +{%- endmacro %} + +{%- macro toctree(docnames) -%} +.. toctree:: + :maxdepth: {{ maxdepth }} +{% for docname in docnames %} + {{ docname }} +{%- endfor %} +{%- endmacro %} + +{%- if is_namespace %} +{{- [pkgname, "namespace"] | join(" ") | e | heading }} +{% else %} +{{- [pkgname, "package"] | join(" ") | e | heading }} +{% endif %} + +{%- if is_namespace %} +.. py:module:: {{ pkgname }} +{% endif %} + +{%- if modulefirst and not is_namespace %} +{{ automodule(pkgname, automodule_options) }} +{% endif %} + +{%- if subpackages %} +{{ toctree(subpackages) }} +{% endif %} + +{%- if submodules %} +{% if separatemodules %} +{{ toctree(submodules) }} +{% else %} +{%- for submodule in submodules %} +{% if show_headings %} +{{- [submodule, "module"] | join(" ") | e | heading(2) }} +{% endif %} +{{ automodule(submodule, automodule_options) }} +{% endfor %} +{%- endif %} +{%- endif %} + +{%- if not modulefirst and not is_namespace %} +{{ automodule(pkgname, automodule_options) }} +{% endif %} \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/docs/changelog.md b/packages/core/minos-microservice-aggregate/docs/changelog.md new file mode 100644 index 000000000..6336d7666 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/docs/changelog.md @@ -0,0 +1 @@ +.. mdinclude:: ../CHANGELOG.md diff --git a/packages/core/minos-microservice-aggregate/docs/conf.py b/packages/core/minos-microservice-aggregate/docs/conf.py index 08885d4f1..87210feb0 100755 --- a/packages/core/minos-microservice-aggregate/docs/conf.py +++ b/packages/core/minos-microservice-aggregate/docs/conf.py @@ -5,7 +5,7 @@ sys.path.insert(0, os.path.abspath("..")) from minos import ( - aggregate, + aggregate as module, ) extensions = [ @@ -23,8 +23,8 @@ copyright = f"2021-{datetime.now().year}, Clariteia" author = "Minos Framework Devs" -version = aggregate.__version__ -release = aggregate.__version__ +version = module.__version__ +release = module.__version__ exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] @@ -38,16 +38,20 @@ apidoc_module_dir = "../minos" apidoc_output_dir = "api" +apidoc_toc_file = False apidoc_separate_modules = True -apidoc_module_first = True apidoc_extra_args = [ "--force", "--implicit-namespaces", + "--templatedir=_templates", ] autodoc_default_options = { + "members": True, "inherited-members": True, "undoc-members": True, + 'member-order': 'bysource', } autoclass_content = "both" autodoc_member_order = "bysource" autodoc_typehints_format = "short" +autodoc_typehints = "description" diff --git a/packages/core/minos-microservice-aggregate/docs/history.md b/packages/core/minos-microservice-aggregate/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/core/minos-microservice-aggregate/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/core/minos-microservice-aggregate/docs/index.md b/packages/core/minos-microservice-aggregate/docs/index.md index b979a59b9..0e50336bc 100644 --- a/packages/core/minos-microservice-aggregate/docs/index.md +++ b/packages/core/minos-microservice-aggregate/docs/index.md @@ -6,8 +6,8 @@ readme reference runthetests + changelog authors - history ## Indices and tables * :ref:`genindex` diff --git a/packages/core/minos-microservice-aggregate/docs/reference.md b/packages/core/minos-microservice-aggregate/docs/reference.md index fdd1327ae..d92219ccb 100644 --- a/packages/core/minos-microservice-aggregate/docs/reference.md +++ b/packages/core/minos-microservice-aggregate/docs/reference.md @@ -1,6 +1,5 @@ # API Reference .. toctree:: - :maxdepth: 5 - api/modules \ No newline at end of file + api/minos \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/contextvars.py b/packages/core/minos-microservice-aggregate/minos/aggregate/contextvars.py index e03e76bd9..482bd865d 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/contextvars.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/contextvars.py @@ -8,3 +8,7 @@ IS_REPOSITORY_SERIALIZATION_CONTEXT_VAR: Final[ContextVar[bool]] = ContextVar( "is_repository_serialization", default=False ) +""" +Context variable that contains ``True`` if the serialization process has been started by some repository, or ``False`` +otherwise. +""" diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py index f19e82409..b04eb9506 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py @@ -17,3 +17,6 @@ ) TRANSACTION_CONTEXT_VAR: Final[ContextVar[Optional[TransactionEntry]]] = ContextVar("transaction", default=None) +""" +Context Variable that contains the transaction's identifier of the currently active transaction, or ``None`` otherwise. +""" \ No newline at end of file From 61522139382c910117505173ea0f172a5f961808 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 30 Mar 2022 18:19:20 +0200 Subject: [PATCH 008/324] ISSUE #332 * Update documentation building process (2). --- .../core/minos-microservice-aggregate/docs/_static/style.css | 4 ++++ packages/core/minos-microservice-aggregate/docs/conf.py | 4 +--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/docs/_static/style.css b/packages/core/minos-microservice-aggregate/docs/_static/style.css index 00a18c905..efaf9ef61 100644 --- a/packages/core/minos-microservice-aggregate/docs/_static/style.css +++ b/packages/core/minos-microservice-aggregate/docs/_static/style.css @@ -1,3 +1,7 @@ .wy-nav-content { max-width: 1200px !important; +} + +dl, .py + dd + dl, .py { + display: block !important; } \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/docs/conf.py b/packages/core/minos-microservice-aggregate/docs/conf.py index 87210feb0..1089dd782 100755 --- a/packages/core/minos-microservice-aggregate/docs/conf.py +++ b/packages/core/minos-microservice-aggregate/docs/conf.py @@ -12,7 +12,6 @@ "sphinxcontrib.apidoc", "sphinx.ext.autodoc", "sphinx.ext.viewcode", - "sphinx_rtd_theme", "m2r2", ] templates_path = ["_templates"] @@ -28,8 +27,6 @@ exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] -pygments_style = "sphinx" - todo_include_todos = False html_theme = "sphinx_rtd_theme" html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} @@ -55,3 +52,4 @@ autodoc_member_order = "bysource" autodoc_typehints_format = "short" autodoc_typehints = "description" +add_module_names = False From 7b816b400b2a477022a1a38d2c5621dbeff09b59 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Wed, 30 Mar 2022 19:21:22 +0200 Subject: [PATCH 009/324] added kong plugin --- packages/plugins/minos-kong/AUTHORS.md | 15 + packages/plugins/minos-kong/HISTORY.md | 5 + packages/plugins/minos-kong/LICENSE | 21 + packages/plugins/minos-kong/Makefile | 42 + packages/plugins/minos-kong/README.md | 55 + packages/plugins/minos-kong/RUNTHETESTS.md | 21 + packages/plugins/minos-kong/SETUP.md | 11 + packages/plugins/minos-kong/docs/Makefile | 20 + .../plugins/minos-kong/docs/_static/style.css | 3 + .../minos-kong/docs/_templates/layout.html | 4 + packages/plugins/minos-kong/docs/authors.md | 1 + packages/plugins/minos-kong/docs/conf.py | 194 ++ packages/plugins/minos-kong/docs/history.md | 1 + packages/plugins/minos-kong/docs/index.md | 16 + packages/plugins/minos-kong/docs/readme.md | 3 + .../plugins/minos-kong/docs/runthetests.md | 1 + packages/plugins/minos-kong/docs/usage.md | 1 + .../minos/plugins/minos_kong/__init__.py | 7 + .../minos/plugins/minos_kong/client.py | 127 ++ .../minos/plugins/minos_kong/utils.py | 13 + packages/plugins/minos-kong/poetry.lock | 1579 +++++++++++++++++ packages/plugins/minos-kong/poetry.toml | 2 + packages/plugins/minos-kong/pyproject.toml | 55 + packages/plugins/minos-kong/setup.cfg | 28 + .../minos-kong/tests/docker-compose.yml | 99 ++ .../tests/test_minos_discovery/__init__.py | 0 .../tests/test_minos_discovery/test_client.py | 35 + 27 files changed, 2359 insertions(+) create mode 100644 packages/plugins/minos-kong/AUTHORS.md create mode 100644 packages/plugins/minos-kong/HISTORY.md create mode 100644 packages/plugins/minos-kong/LICENSE create mode 100644 packages/plugins/minos-kong/Makefile create mode 100644 packages/plugins/minos-kong/README.md create mode 100644 packages/plugins/minos-kong/RUNTHETESTS.md create mode 100644 packages/plugins/minos-kong/SETUP.md create mode 100644 packages/plugins/minos-kong/docs/Makefile create mode 100644 packages/plugins/minos-kong/docs/_static/style.css create mode 100644 packages/plugins/minos-kong/docs/_templates/layout.html create mode 100644 packages/plugins/minos-kong/docs/authors.md create mode 100755 packages/plugins/minos-kong/docs/conf.py create mode 100644 packages/plugins/minos-kong/docs/history.md create mode 100644 packages/plugins/minos-kong/docs/index.md create mode 100644 packages/plugins/minos-kong/docs/readme.md create mode 100644 packages/plugins/minos-kong/docs/runthetests.md create mode 100644 packages/plugins/minos-kong/docs/usage.md create mode 100644 packages/plugins/minos-kong/minos/plugins/minos_kong/__init__.py create mode 100644 packages/plugins/minos-kong/minos/plugins/minos_kong/client.py create mode 100644 packages/plugins/minos-kong/minos/plugins/minos_kong/utils.py create mode 100644 packages/plugins/minos-kong/poetry.lock create mode 100644 packages/plugins/minos-kong/poetry.toml create mode 100644 packages/plugins/minos-kong/pyproject.toml create mode 100644 packages/plugins/minos-kong/setup.cfg create mode 100644 packages/plugins/minos-kong/tests/docker-compose.yml create mode 100644 packages/plugins/minos-kong/tests/test_minos_discovery/__init__.py create mode 100644 packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py diff --git a/packages/plugins/minos-kong/AUTHORS.md b/packages/plugins/minos-kong/AUTHORS.md new file mode 100644 index 000000000..30ff94991 --- /dev/null +++ b/packages/plugins/minos-kong/AUTHORS.md @@ -0,0 +1,15 @@ +# Credits + +## Development Lead + +* Andrea Mucci + +## Core Devs + +* Sergio Garcia Prado +* Vladyslav Fenchak +* Alberto Amigo Alonso + +## Contributors + +None yet. Why not be the first? diff --git a/packages/plugins/minos-kong/HISTORY.md b/packages/plugins/minos-kong/HISTORY.md new file mode 100644 index 000000000..1521d4753 --- /dev/null +++ b/packages/plugins/minos-kong/HISTORY.md @@ -0,0 +1,5 @@ +# History + +## 0.1.0 (2022-03-30) + +* First Release diff --git a/packages/plugins/minos-kong/LICENSE b/packages/plugins/minos-kong/LICENSE new file mode 100644 index 000000000..4daf85bf2 --- /dev/null +++ b/packages/plugins/minos-kong/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2021 Clariteia + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/packages/plugins/minos-kong/Makefile b/packages/plugins/minos-kong/Makefile new file mode 100644 index 000000000..acc861207 --- /dev/null +++ b/packages/plugins/minos-kong/Makefile @@ -0,0 +1,42 @@ +.PHONY: docs dist + +lint: + poetry run flake8 + +test: + poetry run pytest + +coverage: + poetry run coverage run -m pytest + poetry run coverage report -m + poetry run coverage xml + +reformat: + poetry run black --line-length 120 minos tests + poetry run isort minos tests + +docs: + rm -rf docs/api + poetry run $(MAKE) --directory=docs html + +release: + $(MAKE) dist + poetry publish + +dist: + poetry build + ls -l dist + +install: + poetry install + +update: + poetry update + +check: + $(MAKE) install + $(MAKE) reformat + $(MAKE) lint + $(MAKE) test + $(MAKE) docs + $(MAKE) dist diff --git a/packages/plugins/minos-kong/README.md b/packages/plugins/minos-kong/README.md new file mode 100644 index 000000000..01d5852be --- /dev/null +++ b/packages/plugins/minos-kong/README.md @@ -0,0 +1,55 @@ +

+ Minos logo +

+ +## minos-discovery-minos + +[![PyPI Latest Release](https://img.shields.io/pypi/v/minos-kong.svg)](https://pypi.org/project/minos-kong/) +[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://minos-framework.github.io/minos-python) +[![License](https://img.shields.io/github/license/minos-framework/minos-python.svg)](https://github.com/minos-framework/minos-python/blob/main/LICENSE) +[![Coverage](https://codecov.io/github/minos-framework/minos-python/coverage.svg?branch=main)](https://codecov.io/gh/minos-framework/minos-python) +[![Stack Overflow](https://img.shields.io/badge/Stack%20Overflow-Ask%20a%20question-green)](https://stackoverflow.com/questions/tagged/minos) + +## Summary + +Minos Kong is a plugin that integrate minos micorservices with Kong API Gateway + +## Installation + +Install the dependency: + +```shell +pip install minos-kong +``` + +Modify `config.yml` file: + +```yaml +... +discovery: + connector: minos.networks.DiscoveryConnector + client: minos.plugins.minos_kong.MinosKongClient + host: localhost + port: 5567 +... +``` + +## Documentation + +The official API Reference is publicly available at the [GitHub Pages](https://minos-framework.github.io/minos-python). + +## Source Code + +The source code of this project is hosted at the [GitHub Repository](https://github.com/minos-framework/minos-python). + +## Getting Help + +For usage questions, the best place to go to is [StackOverflow](https://stackoverflow.com/questions/tagged/minos). + +## Discussion and Development + +Most development discussions take place over the [GitHub Issues](https://github.com/minos-framework/minos-python/issues). In addition, a [Gitter channel](https://gitter.im/minos-framework/community) is available for development-related questions. + +## License + +This project is distributed under the [MIT](https://raw.githubusercontent.com/minos-framework/minos-python/main/LICENSE) license. diff --git a/packages/plugins/minos-kong/RUNTHETESTS.md b/packages/plugins/minos-kong/RUNTHETESTS.md new file mode 100644 index 000000000..8b5e95b1f --- /dev/null +++ b/packages/plugins/minos-kong/RUNTHETESTS.md @@ -0,0 +1,21 @@ +Run the tests +============== + +In order to run the tests, please make sure you have the `Docker Engine `_ +and `Docker Compose `_ installed. + +Move into tests/ directory + +`cd tests/` + +Run service dependencies: + +`docker-compose up -d` + +Install library dependencies: + +`make install` + +Run tests: + +`make test` diff --git a/packages/plugins/minos-kong/SETUP.md b/packages/plugins/minos-kong/SETUP.md new file mode 100644 index 000000000..8203965c7 --- /dev/null +++ b/packages/plugins/minos-kong/SETUP.md @@ -0,0 +1,11 @@ +Set up a development environment +================================= + +Since we use `poetry` as the default package manager, it must be installed. Please refer to +`https://python-poetry.org/docs/#installation`. + +Run `poetry install` to get the dependencies. + +Run `pre-commit install` to set the git checks before commiting. + +Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/plugins/minos-kong/docs/Makefile b/packages/plugins/minos-kong/docs/Makefile new file mode 100644 index 000000000..11e69918e --- /dev/null +++ b/packages/plugins/minos-kong/docs/Makefile @@ -0,0 +1,20 @@ +# Minimal makefile for Sphinx documentation +# + +# You can set these variables from the command line. +SPHINXOPTS = +SPHINXBUILD = sphinx-build +SPHINXPROJ = minos-kong +SOURCEDIR = . +BUILDDIR = _build + +# Put it first so that "make" without argument is like "make help". +help: + @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) + +.PHONY: help Makefile + +# Catch-all target: route all unknown targets to Sphinx using the new +# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). +%: Makefile + @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/plugins/minos-kong/docs/_static/style.css b/packages/plugins/minos-kong/docs/_static/style.css new file mode 100644 index 000000000..8aa6c288f --- /dev/null +++ b/packages/plugins/minos-kong/docs/_static/style.css @@ -0,0 +1,3 @@ +.wy-nav-content { + max-width: 1200px !important; +} diff --git a/packages/plugins/minos-kong/docs/_templates/layout.html b/packages/plugins/minos-kong/docs/_templates/layout.html new file mode 100644 index 000000000..b0a448060 --- /dev/null +++ b/packages/plugins/minos-kong/docs/_templates/layout.html @@ -0,0 +1,4 @@ +{% extends "!layout.html" %} +{% block extrahead %} + +{% endblock %} \ No newline at end of file diff --git a/packages/plugins/minos-kong/docs/authors.md b/packages/plugins/minos-kong/docs/authors.md new file mode 100644 index 000000000..cf16fc494 --- /dev/null +++ b/packages/plugins/minos-kong/docs/authors.md @@ -0,0 +1 @@ +.. mdinclude:: ../AUTHORS.md diff --git a/packages/plugins/minos-kong/docs/conf.py b/packages/plugins/minos-kong/docs/conf.py new file mode 100755 index 000000000..783f76876 --- /dev/null +++ b/packages/plugins/minos-kong/docs/conf.py @@ -0,0 +1,194 @@ +#!/usr/bin/env python +# +# minos documentation build configuration file, created by +# sphinx-quickstart on Fri Jun 9 13:47:02 2017. +# +# This file is execfile()d with the current directory set to its +# containing dir. +# +# Note that not all possible configuration values are present in this +# autogenerated file. +# +# All configuration values have a default; values that are commented out +# serve to show the default. + +# If extensions (or modules to document with autodoc) are in another +# directory, add these directories to sys.path here. If the directory is +# relative to the documentation root, use os.path.abspath to make it +# absolute, like shown here. +# +import os +import sys + +sys.path.insert(0, os.path.abspath("..")) + +from minos.plugins import ( + minos_discovery, +) + +# -- General configuration --------------------------------------------- + +# If your documentation needs a minimal Sphinx version, state it here. +# +# needs_sphinx = '1.0' + +# Add any Sphinx extension module names here, as strings. They can be +# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. + + +extensions = [ + "sphinxcontrib.apidoc", + "sphinx.ext.autodoc", + "sphinx_autodoc_typehints", + "sphinx.ext.viewcode", + "sphinx_rtd_theme", + "m2r2", +] +# Add any paths that contain templates here, relative to this directory. +templates_path = ["_templates"] + +# The suffix(es) of source filenames. +# You can specify multiple suffix as a list of string: +# +source_suffix = [".rst", ".md"] + +# The master toctree document. +master_doc = "index" + +# General information about the project. +project = "Minos Kong Plugin" +copyright = "2021, Clariteia" +author = "Minos Framework Devs" + +# The version info for the project you're documenting, acts as replacement +# for |version| and |release|, also used in various other places throughout +# the built documents. +# +# The short X.Y version. +version = minos_discovery.__version__ +# The full version, including alpha/beta/rc tags. +release = minos_discovery.__version__ + +# The language for content autogenerated by Sphinx. Refer to documentation +# for a list of supported languages. +# +# This is also used if you do content translation via gettext catalogs. +# Usually you set "language" from the command line for these cases. +language = None + +# List of patterns, relative to source directory, that match files and +# directories to ignore when looking for source files. +# This patterns also effect to html_static_path and html_extra_path +exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] + +# The name of the Pygments (syntax highlighting) style to use. +pygments_style = "sphinx" + +todo_include_todos = False + + +# -- Options for HTML output ------------------------------------------- + +# The theme to use for HTML and HTML Help pages. See the documentation for +# a list of builtin themes. +# + +html_theme = "sphinx_rtd_theme" + +# Theme options are theme-specific and customize the look and feel of a +# theme further. For a list of options available for each theme, see the +# documentation. +# + +# html_theme_options = { +# "codecov_button": True, +# "description": "Reactive microservices for an asynchronous world", +# "github_button": True, +# "github_user": "Clariteia", +# "github_repo": "cqrs", +# "github_type": "star", +# } + +html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} + +# Add any paths that contain custom static files (such as style sheets) here, +# relative to this directory. They are copied after the builtin static files, +# so a file named "default.css" will overwrite the builtin "default.css". +html_static_path = ["_static"] + + +# -- Options for HTMLHelp output --------------------------------------- + +# Output file base name for HTML help builder. +htmlhelp_basename = "minosdoc" + + +# -- Options for LaTeX output ------------------------------------------ + +latex_elements = { + # The paper size ('letterpaper' or 'a4paper'). + # + # 'papersize': 'letterpaper', + # The font size ('10pt', '11pt' or '12pt'). + # + # 'pointsize': '10pt', + # Additional stuff for the LaTeX preamble. + # + # 'preamble': '', + # Latex figure (float) alignment + # + # 'figure_align': 'htbp', +} + +# Grouping the document tree into LaTeX files. List of tuples +# (source start file, target name, title, author, documentclass +# [howto, manual, or own class]). +latex_documents = [ + (master_doc, "minos.tex", "Minos Kong Plugin Documentation", "Minos Framework Devs", "manual"), +] + + +# -- Options for manual page output ------------------------------------ + +# One entry per manual page. List of tuples +# (source start file, name, description, authors, manual section). +man_pages = [(master_doc, "minos", "Minos Kong Plugin Documentation", [author], 1)] + + +# -- Options for Texinfo output ---------------------------------------- + +# Grouping the document tree into Texinfo files. List of tuples +# (source start file, target name, title, author, +# dir menu entry, description, category) +texinfo_documents = [ + ( + master_doc, + "minos", + "Minos Kong Plugin Documentation", + author, + "minos", + "One line description of project.", + "Miscellaneous", + ), +] + +# "apidoc" extension +apidoc_module_dir = "../minos" +apidoc_output_dir = "api" +apidoc_separate_modules = True +autodoc_default_options = { + "inherited-members": True, + "special-members": "__init__", + "undoc-members": True, +} + +apidoc_toc_file = False +apidoc_module_first = True +apidoc_extra_args = [ + "--force", + "--implicit-namespaces", +] +# "autodoc typehints" extension + +set_type_checking_flag = True +typehints_fully_qualified = True diff --git a/packages/plugins/minos-kong/docs/history.md b/packages/plugins/minos-kong/docs/history.md new file mode 100644 index 000000000..d26e5be83 --- /dev/null +++ b/packages/plugins/minos-kong/docs/history.md @@ -0,0 +1 @@ +.. mdinclude:: ../HISTORY.md diff --git a/packages/plugins/minos-kong/docs/index.md b/packages/plugins/minos-kong/docs/index.md new file mode 100644 index 000000000..b470bca77 --- /dev/null +++ b/packages/plugins/minos-kong/docs/index.md @@ -0,0 +1,16 @@ +# Welcome to Minos Discovery Minos's documentation! + +.. toctree:: + :maxdepth: 2 + + readme + runthetests + usage + api/minos.plugins + authors + history + +# Indices and tables +* :ref:`genindex` +* :ref:`modindex` +* :ref:`search` diff --git a/packages/plugins/minos-kong/docs/readme.md b/packages/plugins/minos-kong/docs/readme.md new file mode 100644 index 000000000..da72dbef1 --- /dev/null +++ b/packages/plugins/minos-kong/docs/readme.md @@ -0,0 +1,3 @@ +# Introduction + +.. mdinclude:: ../README.md diff --git a/packages/plugins/minos-kong/docs/runthetests.md b/packages/plugins/minos-kong/docs/runthetests.md new file mode 100644 index 000000000..309db1b96 --- /dev/null +++ b/packages/plugins/minos-kong/docs/runthetests.md @@ -0,0 +1 @@ +.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/plugins/minos-kong/docs/usage.md b/packages/plugins/minos-kong/docs/usage.md new file mode 100644 index 000000000..8f04b05ad --- /dev/null +++ b/packages/plugins/minos-kong/docs/usage.md @@ -0,0 +1 @@ +# Usage diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/__init__.py b/packages/plugins/minos-kong/minos/plugins/minos_kong/__init__.py new file mode 100644 index 000000000..4c7a7aa16 --- /dev/null +++ b/packages/plugins/minos-kong/minos/plugins/minos_kong/__init__.py @@ -0,0 +1,7 @@ +__author__ = "Minos Framework Devs" +__email__ = "hey@minos.run" +__version__ = "0.6.0" + +from .client import ( + MinosKongClient, +) diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py b/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py new file mode 100644 index 000000000..d8363f8db --- /dev/null +++ b/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py @@ -0,0 +1,127 @@ +import logging +from collections.abc import ( + Iterable, +) +from functools import ( + partial, +) +from typing import ( + Optional, +) + +import httpx as httpx + +from minos.common import ( + CircuitBreakerMixin, +) +from minos.networks import ( + DiscoveryClient, +) + +from .utils import Endpoint + +logger = logging.getLogger(__name__) + + +class MinosKongClient(DiscoveryClient, CircuitBreakerMixin): + """Minos Discovery Client class.""" + + def __init__( + self, + host: Optional[str] = None, + port: Optional[int] = None, + circuit_breaker_exceptions: Iterable[type] = tuple(), + **kwargs, + ): + if host is None: + host = "localhost" + if port is None: + port = 5567 + super().__init__(host, port, circuit_breaker_exceptions=(httpx.HTTPStatusError, *circuit_breaker_exceptions), **kwargs) + + async def subscribe( + self, host: str, port: int, name: str, endpoints: list[dict[str, str]], *args, **kwargs + ) -> httpx.Response: + """Perform the subscription query. + + :param host: The ip of the microservice to be subscribed. + :param port: The port of the microservice to be subscribed. + :param name: The name of the microservice to be subscribed. + :param endpoints: List of endpoints exposed by the microservice. + :param args: Additional positional arguments. + :param kwargs: Additional named arguments. + :return: This method does not return anything. + """ + fnsr = partial(self._register_service, self.route, name, host, port) + response_service = await self.with_circuit_breaker(fnsr) + if response_service.status_code == 409: + # if service already exist, delete and add again + fn_delete = partial(self._delete_service, self.route, name) + response_delete = await self.with_circuit_breaker(fn_delete) + fnsr = partial(self._register_service, self.route, name, host, port) + response_service = await self.with_circuit_breaker(fnsr) + + content_service = response_service.json() + + for endpoint in endpoints: + endpointClass = Endpoint(endpoint["url"]) + data = { + "protocols": ["http"], + "methods": [endpoint["method"]], + "paths": [endpointClass.path_as_str], + "service": { + "id": content_service["id"] + } + } + fn = partial(self._subscribe_routes, self.route, data) + response = await self.with_circuit_breaker(fn) + + return response + + @staticmethod + async def _register_service(discovery_route: str, service_name: str, + microservice_host: str, microservice_port: str) -> httpx.Response: + url = f"{discovery_route}/services" + data = { + "name": service_name, + "protocol": "http", + "host": microservice_host, + "port": microservice_port + } + async with httpx.AsyncClient() as client: + response = await client.post(url, json=data) + return response + + @staticmethod + async def _subscribe_routes(endpoint: str, data: dict[str, str]) -> httpx.Response: + logger.debug(f"Subscribing into {endpoint!r}...") + url = f"{endpoint}/routes" + async with httpx.AsyncClient() as client: + response = await client.post(url, json=data) + return response + + async def unsubscribe(self, name: str, *args, **kwargs) -> httpx.Response: + """Perform the unsubscription query. + + :param name: The name of the microservice to be unsubscribed. + :param args: Additional positional arguments. + :param kwargs: Additional named arguments. + :return: This method does not return anything. + """ + fn = partial(self._delete_service, self.route, name) + response = await self.with_circuit_breaker(fn) + return response + + @staticmethod + async def _delete_service(discovery_route: str, service_name) -> httpx.Response: + async with httpx.AsyncClient() as client: + url_get_route = f"{discovery_route}/services/{service_name}/routes" + response_routes = await client.get(url_get_route) + json_routes_response = response_routes.json() + if len(json_routes_response["data"]) > 0: + for route in json_routes_response["data"]: + url_delete_route = f"{discovery_route}/routes/{route['id']}" + await client.delete(url_delete_route) + url_delete_service = f"{discovery_route}/services/{service_name}" + response_delete_service = await client.delete(url_delete_service) + return response_delete_service diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/utils.py b/packages/plugins/minos-kong/minos/plugins/minos_kong/utils.py new file mode 100644 index 000000000..07bd67a51 --- /dev/null +++ b/packages/plugins/minos-kong/minos/plugins/minos_kong/utils.py @@ -0,0 +1,13 @@ +class PathPart: + def __init__(self, name: str): + self.name = name + self.is_generic: bool = True if self.name.startswith("{") and self.name.endswith("}") else False + + +class Endpoint: + def __init__(self, path: str): + self.path: tuple[PathPart] = tuple(PathPart(path_part) for path_part in path.split("/")) + + @property + def path_as_str(self) -> str: + return "/".join([str(part.name) for part in self.path]) diff --git a/packages/plugins/minos-kong/poetry.lock b/packages/plugins/minos-kong/poetry.lock new file mode 100644 index 000000000..5f5c584a4 --- /dev/null +++ b/packages/plugins/minos-kong/poetry.lock @@ -0,0 +1,1579 @@ +[[package]] +name = "aiomisc" +version = "15.7.3" +description = "aiomisc - miscellaneous utils for asyncio" +category = "main" +optional = false +python-versions = "*" + +[package.dependencies] +colorlog = "*" + +[package.extras] +aiohttp = ["aiohttp"] +asgi = ["aiohttp-asgi"] +carbon = ["aiocarbon (>=0.15,<1.0)"] +contextvars = ["contextvars (>=2.4,<3.0)"] +cron = ["croniter (>=0.3.34,<0.4.0)"] +develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-timeout", "coveralls", "croniter (>=0.3.34,<0.4.0)", "fastapi", "freezegun (<1.1)", "mypy (>=0.782,<1.0)", "pylava", "pytest", "pytest-cov (>=3.0,<4.0)", "pytest-freezegun (>=0.4.2,<0.5.0)", "pytest-rst", "pytest-subtests", "rich", "setproctitle", "sphinx-autobuild", "sphinx-intl", "sphinx (>=3.5.1)", "timeout-decorator", "tox (>=2.4)", "types-croniter"] +raven = ["raven-aiohttp"] +uvloop = ["uvloop (>=0.14,<1)"] + +[[package]] +name = "aiopg" +version = "1.3.3" +description = "Postgres integration with asyncio." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +async-timeout = ">=3.0,<5.0" +psycopg2-binary = ">=2.8.4" + +[package.extras] +sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] + +[[package]] +name = "alabaster" +version = "0.7.12" +description = "A configurable sidebar-enabled Sphinx theme" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "anyio" +version = "3.5.0" +description = "High level compatibility layer for multiple asynchronous event loop implementations" +category = "main" +optional = false +python-versions = ">=3.6.2" + +[package.dependencies] +idna = ">=2.8" +sniffio = ">=1.1" + +[package.extras] +doc = ["packaging", "sphinx-rtd-theme", "sphinx-autodoc-typehints (>=1.2.0)"] +test = ["coverage[toml] (>=4.5)", "hypothesis (>=4.0)", "pytest (>=6.0)", "pytest-mock (>=3.6.1)", "trustme", "contextlib2", "uvloop (<0.15)", "mock (>=4)", "uvloop (>=0.15)"] +trio = ["trio (>=0.16)"] + +[[package]] +name = "async-timeout" +version = "4.0.2" +description = "Timeout context manager for asyncio programs" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "atomicwrites" +version = "1.4.0" +description = "Atomic file writes." +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" + +[[package]] +name = "attrs" +version = "21.4.0" +description = "Classes Without Boilerplate" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[package.extras] +dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] +docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] +tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] +tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] + +[[package]] +name = "babel" +version = "2.9.1" +description = "Internationalization utilities" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" + +[package.dependencies] +pytz = ">=2015.7" + +[[package]] +name = "black" +version = "22.3.0" +description = "The uncompromising code formatter." +category = "dev" +optional = false +python-versions = ">=3.6.2" + +[package.dependencies] +click = ">=8.0.0" +mypy-extensions = ">=0.4.3" +pathspec = ">=0.9.0" +platformdirs = ">=2" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} +typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} + +[package.extras] +colorama = ["colorama (>=0.4.3)"] +d = ["aiohttp (>=3.7.4)"] +jupyter = ["ipython (>=7.8.0)", "tokenize-rt (>=3.2.0)"] +uvloop = ["uvloop (>=0.15.2)"] + +[[package]] +name = "cached-property" +version = "1.5.2" +description = "A decorator for caching properties in classes." +category = "main" +optional = false +python-versions = "*" + +[[package]] +name = "certifi" +version = "2021.10.8" +description = "Python package for providing Mozilla's CA Bundle." +category = "main" +optional = false +python-versions = "*" + +[[package]] +name = "cfgv" +version = "3.3.1" +description = "Validate configuration and produce human readable error messages." +category = "dev" +optional = false +python-versions = ">=3.6.1" + +[[package]] +name = "charset-normalizer" +version = "2.0.12" +description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." +category = "main" +optional = false +python-versions = ">=3.5.0" + +[package.extras] +unicode_backport = ["unicodedata2"] + +[[package]] +name = "click" +version = "8.1.0" +description = "Composable command line interface toolkit" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} + +[[package]] +name = "colorama" +version = "0.4.4" +description = "Cross-platform colored terminal text." +category = "main" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "colorlog" +version = "6.6.0" +description = "Add colours to the output of Python's logging module." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +colorama = {version = "*", markers = "sys_platform == \"win32\""} + +[package.extras] +development = ["black", "flake8", "mypy", "pytest", "types-colorama"] + +[[package]] +name = "coverage" +version = "6.3.2" +description = "Code coverage measurement for Python" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.extras] +toml = ["tomli"] + +[[package]] +name = "crontab" +version = "0.23.0" +description = "Parse and use crontab schedules in Python" +category = "main" +optional = false +python-versions = "*" + +[[package]] +name = "dependency-injector" +version = "4.39.1" +description = "Dependency injection framework for Python" +category = "main" +optional = false +python-versions = "*" + +[package.dependencies] +six = ">=1.7.0,<=1.16.0" + +[package.extras] +aiohttp = ["aiohttp"] +flask = ["flask"] +pydantic = ["pydantic"] +yaml = ["pyyaml"] + +[[package]] +name = "distlib" +version = "0.3.4" +description = "Distribution utilities" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "docutils" +version = "0.17.1" +description = "Docutils -- Python Documentation Utilities" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "fastavro" +version = "1.4.10" +description = "Fast read/write of AVRO files" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.extras] +codecs = ["python-snappy", "zstandard", "lz4"] +lz4 = ["lz4"] +snappy = ["python-snappy"] +zstandard = ["zstandard"] + +[[package]] +name = "filelock" +version = "3.6.0" +description = "A platform independent file lock." +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.extras] +docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] +testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] + +[[package]] +name = "flake8" +version = "4.0.1" +description = "the modular source code checker: pep8 pyflakes and co" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +mccabe = ">=0.6.0,<0.7.0" +pycodestyle = ">=2.8.0,<2.9.0" +pyflakes = ">=2.4.0,<2.5.0" + +[[package]] +name = "h11" +version = "0.12.0" +description = "A pure-Python, bring-your-own-I/O implementation of HTTP/1.1" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "httpcore" +version = "0.14.7" +description = "A minimal low-level HTTP client." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +anyio = ">=3.0.0,<4.0.0" +certifi = "*" +h11 = ">=0.11,<0.13" +sniffio = ">=1.0.0,<2.0.0" + +[package.extras] +http2 = ["h2 (>=3,<5)"] +socks = ["socksio (>=1.0.0,<2.0.0)"] + +[[package]] +name = "httpx" +version = "0.22.0" +description = "The next generation HTTP client." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +certifi = "*" +charset-normalizer = "*" +httpcore = ">=0.14.5,<0.15.0" +rfc3986 = {version = ">=1.3,<2", extras = ["idna2008"]} +sniffio = "*" + +[package.extras] +brotli = ["brotlicffi", "brotli"] +cli = ["click (>=8.0.0,<9.0.0)", "rich (>=10.0.0,<11.0.0)", "pygments (>=2.0.0,<3.0.0)"] +http2 = ["h2 (>=3,<5)"] +socks = ["socksio (>=1.0.0,<2.0.0)"] + +[[package]] +name = "identify" +version = "2.4.12" +description = "File identification library for Python" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.extras] +license = ["ukkonen"] + +[[package]] +name = "idna" +version = "3.3" +description = "Internationalized Domain Names in Applications (IDNA)" +category = "main" +optional = false +python-versions = ">=3.5" + +[[package]] +name = "imagesize" +version = "1.3.0" +description = "Getting image size from png/jpeg/jpeg2000/gif file" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" + +[[package]] +name = "importlib-metadata" +version = "4.11.3" +description = "Read metadata from Python packages" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +zipp = ">=0.5" + +[package.extras] +docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +perf = ["ipython"] +testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] + +[[package]] +name = "iniconfig" +version = "1.1.1" +description = "iniconfig: brain-dead simple config-ini parsing" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "isort" +version = "5.10.1" +description = "A Python utility / library to sort Python imports." +category = "dev" +optional = false +python-versions = ">=3.6.1,<4.0" + +[package.extras] +pipfile_deprecated_finder = ["pipreqs", "requirementslib"] +requirements_deprecated_finder = ["pipreqs", "pip-api"] +colors = ["colorama (>=0.4.3,<0.5.0)"] +plugins = ["setuptools"] + +[[package]] +name = "jinja2" +version = "3.1.1" +description = "A very fast and expressive template engine." +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +MarkupSafe = ">=2.0" + +[package.extras] +i18n = ["Babel (>=2.7)"] + +[[package]] +name = "lmdb" +version = "1.3.0" +description = "Universal Python binding for the LMDB 'Lightning' Database" +category = "main" +optional = false +python-versions = "*" + +[[package]] +name = "m2r2" +version = "0.3.2" +description = "Markdown and reStructuredText in a single file." +category = "dev" +optional = false +python-versions = "*" + +[package.dependencies] +docutils = "*" +mistune = "0.8.4" + +[[package]] +name = "markupsafe" +version = "2.1.1" +description = "Safely add untrusted strings to HTML/XML markup." +category = "dev" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "mccabe" +version = "0.6.1" +description = "McCabe checker, plugin for flake8" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "minos-microservice-common" +version = "0.6.0" +description = "The common core of the Minos Framework" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +aiomisc = ">=14.0.3,<16.0.0" +aiopg = "^1.2.1" +cached-property = "^1.5.2" +dependency-injector = "^4.32.2" +fastavro = "^1.4.0" +lmdb = "^1.2.1" +orjson = "^3.5.2" +PyYAML = ">=5.4.1,<7.0.0" +uvloop = "^0.16.0" + +[package.source] +type = "directory" +url = "../../core/minos-microservice-common" + +[[package]] +name = "minos-microservice-networks" +version = "0.6.0" +description = "The networks core of the Minos Framework" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +aiopg = "^1.2.1" +crontab = "^0.23.0" +minos-microservice-common = "^0.6.0" +psycopg2-binary = "^2.9.3" + +[package.source] +type = "directory" +url = "../../core/minos-microservice-networks" + +[[package]] +name = "mistune" +version = "0.8.4" +description = "The fastest markdown parser in pure Python" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "mypy-extensions" +version = "0.4.3" +description = "Experimental type system extensions for programs checked with the mypy typechecker." +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "nodeenv" +version = "1.6.0" +description = "Node.js virtual environment builder" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "orjson" +version = "3.6.7" +description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" +category = "main" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "packaging" +version = "21.3" +description = "Core utilities for Python packages" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" + +[[package]] +name = "pathspec" +version = "0.9.0" +description = "Utility library for gitignore style pattern matching of file paths." +category = "dev" +optional = false +python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" + +[[package]] +name = "pbr" +version = "5.8.1" +description = "Python Build Reasonableness" +category = "dev" +optional = false +python-versions = ">=2.6" + +[[package]] +name = "platformdirs" +version = "2.5.1" +description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.extras] +docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] +test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] + +[[package]] +name = "pluggy" +version = "1.0.0" +description = "plugin and hook calling mechanisms for python" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.extras] +dev = ["pre-commit", "tox"] +testing = ["pytest", "pytest-benchmark"] + +[[package]] +name = "pre-commit" +version = "2.17.0" +description = "A framework for managing and maintaining multi-language pre-commit hooks." +category = "dev" +optional = false +python-versions = ">=3.6.1" + +[package.dependencies] +cfgv = ">=2.0.0" +identify = ">=1.0.0" +nodeenv = ">=0.11.1" +pyyaml = ">=5.1" +toml = "*" +virtualenv = ">=20.0.8" + +[[package]] +name = "psycopg2-binary" +version = "2.9.3" +description = "psycopg2 - Python-PostgreSQL Database Adapter" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "py" +version = "1.11.0" +description = "library with cross-python path, ini-parsing, io, code, log facilities" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "pycodestyle" +version = "2.8.0" +description = "Python style guide checker" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "pyflakes" +version = "2.4.0" +description = "passive checker of Python programs" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" + +[[package]] +name = "pygments" +version = "2.11.2" +description = "Pygments is a syntax highlighting package written in Python." +category = "dev" +optional = false +python-versions = ">=3.5" + +[[package]] +name = "pyparsing" +version = "3.0.7" +description = "Python parsing module" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.extras] +diagrams = ["jinja2", "railroad-diagrams"] + +[[package]] +name = "pytest" +version = "6.2.5" +description = "pytest: simple powerful testing with Python" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +atomicwrites = {version = ">=1.0", markers = "sys_platform == \"win32\""} +attrs = ">=19.2.0" +colorama = {version = "*", markers = "sys_platform == \"win32\""} +iniconfig = "*" +packaging = "*" +pluggy = ">=0.12,<2.0" +py = ">=1.8.2" +toml = "*" + +[package.extras] +testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] + +[[package]] +name = "pytz" +version = "2022.1" +description = "World timezone definitions, modern and historical" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "pyyaml" +version = "6.0" +description = "YAML parser and emitter for Python" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "requests" +version = "2.27.1" +description = "Python HTTP for Humans." +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" + +[package.dependencies] +certifi = ">=2017.4.17" +charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} +idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} +urllib3 = ">=1.21.1,<1.27" + +[package.extras] +socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] +use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] + +[[package]] +name = "rfc3986" +version = "1.5.0" +description = "Validating URI References per RFC 3986" +category = "main" +optional = false +python-versions = "*" + +[package.dependencies] +idna = {version = "*", optional = true, markers = "extra == \"idna2008\""} + +[package.extras] +idna2008 = ["idna"] + +[[package]] +name = "six" +version = "1.16.0" +description = "Python 2 and 3 compatibility utilities" +category = "main" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" + +[[package]] +name = "sniffio" +version = "1.2.0" +description = "Sniff out which async library your code is running under" +category = "main" +optional = false +python-versions = ">=3.5" + +[[package]] +name = "snowballstemmer" +version = "2.2.0" +description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "sphinx" +version = "4.5.0" +description = "Python documentation generator" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +alabaster = ">=0.7,<0.8" +babel = ">=1.3" +colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} +docutils = ">=0.14,<0.18" +imagesize = "*" +importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} +Jinja2 = ">=2.3" +packaging = "*" +Pygments = ">=2.0" +requests = ">=2.5.0" +snowballstemmer = ">=1.1" +sphinxcontrib-applehelp = "*" +sphinxcontrib-devhelp = "*" +sphinxcontrib-htmlhelp = ">=2.0.0" +sphinxcontrib-jsmath = "*" +sphinxcontrib-qthelp = "*" +sphinxcontrib-serializinghtml = ">=1.1.5" + +[package.extras] +docs = ["sphinxcontrib-websupport"] +lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] +test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] + +[[package]] +name = "sphinx-autodoc-typehints" +version = "1.17.0" +description = "Type hints (PEP 484) support for the Sphinx autodoc extension" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +Sphinx = ">=4" + +[package.extras] +testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] +type_comments = ["typed-ast (>=1.4.0)"] + +[[package]] +name = "sphinx-rtd-theme" +version = "1.0.0" +description = "Read the Docs theme for Sphinx" +category = "dev" +optional = false +python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" + +[package.dependencies] +docutils = "<0.18" +sphinx = ">=1.6" + +[package.extras] +dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] + +[[package]] +name = "sphinxcontrib-apidoc" +version = "0.3.0" +description = "A Sphinx extension for running 'sphinx-apidoc' on each build" +category = "dev" +optional = false +python-versions = "*" + +[package.dependencies] +pbr = "*" +Sphinx = ">=1.6.0" + +[[package]] +name = "sphinxcontrib-applehelp" +version = "1.0.2" +description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" +category = "dev" +optional = false +python-versions = ">=3.5" + +[package.extras] +lint = ["flake8", "mypy", "docutils-stubs"] +test = ["pytest"] + +[[package]] +name = "sphinxcontrib-devhelp" +version = "1.0.2" +description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." +category = "dev" +optional = false +python-versions = ">=3.5" + +[package.extras] +lint = ["flake8", "mypy", "docutils-stubs"] +test = ["pytest"] + +[[package]] +name = "sphinxcontrib-htmlhelp" +version = "2.0.0" +description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.extras] +lint = ["flake8", "mypy", "docutils-stubs"] +test = ["pytest", "html5lib"] + +[[package]] +name = "sphinxcontrib-jsmath" +version = "1.0.1" +description = "A sphinx extension which renders display math in HTML via JavaScript" +category = "dev" +optional = false +python-versions = ">=3.5" + +[package.extras] +test = ["pytest", "flake8", "mypy"] + +[[package]] +name = "sphinxcontrib-qthelp" +version = "1.0.3" +description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." +category = "dev" +optional = false +python-versions = ">=3.5" + +[package.extras] +lint = ["flake8", "mypy", "docutils-stubs"] +test = ["pytest"] + +[[package]] +name = "sphinxcontrib-serializinghtml" +version = "1.1.5" +description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." +category = "dev" +optional = false +python-versions = ">=3.5" + +[package.extras] +lint = ["flake8", "mypy", "docutils-stubs"] +test = ["pytest"] + +[[package]] +name = "toml" +version = "0.10.2" +description = "Python Library for Tom's Obvious, Minimal Language" +category = "dev" +optional = false +python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" + +[[package]] +name = "tomli" +version = "2.0.1" +description = "A lil' TOML parser" +category = "dev" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "typing-extensions" +version = "4.1.1" +description = "Backported and Experimental Type Hints for Python 3.6+" +category = "dev" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "urllib3" +version = "1.26.9" +description = "HTTP library with thread-safe connection pooling, file post, and more." +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" + +[package.extras] +brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] +secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] +socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] + +[[package]] +name = "uvloop" +version = "0.16.0" +description = "Fast implementation of asyncio event loop on top of libuv" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.extras] +dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)", "aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] +docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] +test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] + +[[package]] +name = "virtualenv" +version = "20.14.0" +description = "Virtual Python Environment builder" +category = "dev" +optional = false +python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" + +[package.dependencies] +distlib = ">=0.3.1,<1" +filelock = ">=3.2,<4" +platformdirs = ">=2,<3" +six = ">=1.9.0,<2" + +[package.extras] +docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] +testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] + +[[package]] +name = "zipp" +version = "3.7.0" +description = "Backport of pathlib-compatible object wrapper for zip files" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.extras] +docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] +testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] + +[metadata] +lock-version = "1.1" +python-versions = "^3.9" +content-hash = "6f3959912700b8e1376699eb9a5a8f1b993a35f458368f4b3e2b254b4a37df33" + +[metadata.files] +aiomisc = [ + {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, + {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, +] +aiopg = [ + {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, + {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, +] +alabaster = [ + {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, + {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, +] +anyio = [ + {file = "anyio-3.5.0-py3-none-any.whl", hash = "sha256:b5fa16c5ff93fa1046f2eeb5bbff2dad4d3514d6cda61d02816dba34fa8c3c2e"}, + {file = "anyio-3.5.0.tar.gz", hash = "sha256:a0aeffe2fb1fdf374a8e4b471444f0f3ac4fb9f5a5b542b48824475e0042a5a6"}, +] +async-timeout = [ + {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, + {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, +] +atomicwrites = [ + {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, + {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, +] +attrs = [ + {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, + {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, +] +babel = [ + {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, + {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, +] +black = [ + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, +] +cached-property = [ + {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, + {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, +] +certifi = [ + {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, + {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, +] +cfgv = [ + {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, + {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, +] +charset-normalizer = [ + {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, + {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, +] +click = [ + {file = "click-8.1.0-py3-none-any.whl", hash = "sha256:19a4baa64da924c5e0cd889aba8e947f280309f1a2ce0947a3e3a7bcb7cc72d6"}, + {file = "click-8.1.0.tar.gz", hash = "sha256:977c213473c7665d3aa092b41ff12063227751c41d7b17165013e10069cc5cd2"}, +] +colorama = [ + {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, + {file = "colorama-0.4.4.tar.gz", hash = "sha256:5941b2b48a20143d2267e95b1c2a7603ce057ee39fd88e7329b0c292aa16869b"}, +] +colorlog = [ + {file = "colorlog-6.6.0-py2.py3-none-any.whl", hash = "sha256:351c51e866c86c3217f08e4b067a7974a678be78f07f85fc2d55b8babde6d94e"}, + {file = "colorlog-6.6.0.tar.gz", hash = "sha256:344f73204009e4c83c5b6beb00b3c45dc70fcdae3c80db919e0a4171d006fde8"}, +] +coverage = [ + {file = "coverage-6.3.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:9b27d894748475fa858f9597c0ee1d4829f44683f3813633aaf94b19cb5453cf"}, + {file = "coverage-6.3.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:37d1141ad6b2466a7b53a22e08fe76994c2d35a5b6b469590424a9953155afac"}, + {file = "coverage-6.3.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f9987b0354b06d4df0f4d3e0ec1ae76d7ce7cbca9a2f98c25041eb79eec766f1"}, + {file = "coverage-6.3.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:26e2deacd414fc2f97dd9f7676ee3eaecd299ca751412d89f40bc01557a6b1b4"}, + {file = "coverage-6.3.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4dd8bafa458b5c7d061540f1ee9f18025a68e2d8471b3e858a9dad47c8d41903"}, + {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:46191097ebc381fbf89bdce207a6c107ac4ec0890d8d20f3360345ff5976155c"}, + {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:6f89d05e028d274ce4fa1a86887b071ae1755082ef94a6740238cd7a8178804f"}, + {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:58303469e9a272b4abdb9e302a780072c0633cdcc0165db7eec0f9e32f901e05"}, + {file = "coverage-6.3.2-cp310-cp310-win32.whl", hash = "sha256:2fea046bfb455510e05be95e879f0e768d45c10c11509e20e06d8fcaa31d9e39"}, + {file = "coverage-6.3.2-cp310-cp310-win_amd64.whl", hash = "sha256:a2a8b8bcc399edb4347a5ca8b9b87e7524c0967b335fbb08a83c8421489ddee1"}, + {file = "coverage-6.3.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:f1555ea6d6da108e1999b2463ea1003fe03f29213e459145e70edbaf3e004aaa"}, + {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e5f4e1edcf57ce94e5475fe09e5afa3e3145081318e5fd1a43a6b4539a97e518"}, + {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7a15dc0a14008f1da3d1ebd44bdda3e357dbabdf5a0b5034d38fcde0b5c234b7"}, + {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:21b7745788866028adeb1e0eca3bf1101109e2dc58456cb49d2d9b99a8c516e6"}, + {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:8ce257cac556cb03be4a248d92ed36904a59a4a5ff55a994e92214cde15c5bad"}, + {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:b0be84e5a6209858a1d3e8d1806c46214e867ce1b0fd32e4ea03f4bd8b2e3359"}, + {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:acf53bc2cf7282ab9b8ba346746afe703474004d9e566ad164c91a7a59f188a4"}, + {file = "coverage-6.3.2-cp37-cp37m-win32.whl", hash = "sha256:8bdde1177f2311ee552f47ae6e5aa7750c0e3291ca6b75f71f7ffe1f1dab3dca"}, + {file = "coverage-6.3.2-cp37-cp37m-win_amd64.whl", hash = "sha256:b31651d018b23ec463e95cf10070d0b2c548aa950a03d0b559eaa11c7e5a6fa3"}, + {file = "coverage-6.3.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:07e6db90cd9686c767dcc593dff16c8c09f9814f5e9c51034066cad3373b914d"}, + {file = "coverage-6.3.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:2c6dbb42f3ad25760010c45191e9757e7dce981cbfb90e42feef301d71540059"}, + {file = "coverage-6.3.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c76aeef1b95aff3905fb2ae2d96e319caca5b76fa41d3470b19d4e4a3a313512"}, + {file = "coverage-6.3.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:8cf5cfcb1521dc3255d845d9dca3ff204b3229401994ef8d1984b32746bb45ca"}, + {file = "coverage-6.3.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8fbbdc8d55990eac1b0919ca69eb5a988a802b854488c34b8f37f3e2025fa90d"}, + {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ec6bc7fe73a938933d4178c9b23c4e0568e43e220aef9472c4f6044bfc6dd0f0"}, + {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:9baff2a45ae1f17c8078452e9e5962e518eab705e50a0aa8083733ea7d45f3a6"}, + {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:fd9e830e9d8d89b20ab1e5af09b32d33e1a08ef4c4e14411e559556fd788e6b2"}, + {file = "coverage-6.3.2-cp38-cp38-win32.whl", hash = "sha256:f7331dbf301b7289013175087636bbaf5b2405e57259dd2c42fdcc9fcc47325e"}, + {file = "coverage-6.3.2-cp38-cp38-win_amd64.whl", hash = "sha256:68353fe7cdf91f109fc7d474461b46e7f1f14e533e911a2a2cbb8b0fc8613cf1"}, + {file = "coverage-6.3.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b78e5afb39941572209f71866aa0b206c12f0109835aa0d601e41552f9b3e620"}, + {file = "coverage-6.3.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:4e21876082ed887baed0146fe222f861b5815455ada3b33b890f4105d806128d"}, + {file = "coverage-6.3.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:34626a7eee2a3da12af0507780bb51eb52dca0e1751fd1471d0810539cefb536"}, + {file = "coverage-6.3.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1ebf730d2381158ecf3dfd4453fbca0613e16eaa547b4170e2450c9707665ce7"}, + {file = "coverage-6.3.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dd6fe30bd519694b356cbfcaca9bd5c1737cddd20778c6a581ae20dc8c04def2"}, + {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:96f8a1cb43ca1422f36492bebe63312d396491a9165ed3b9231e778d43a7fca4"}, + {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:dd035edafefee4d573140a76fdc785dc38829fe5a455c4bb12bac8c20cfc3d69"}, + {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:5ca5aeb4344b30d0bec47481536b8ba1181d50dbe783b0e4ad03c95dc1296684"}, + {file = "coverage-6.3.2-cp39-cp39-win32.whl", hash = "sha256:f5fa5803f47e095d7ad8443d28b01d48c0359484fec1b9d8606d0e3282084bc4"}, + {file = "coverage-6.3.2-cp39-cp39-win_amd64.whl", hash = "sha256:9548f10d8be799551eb3a9c74bbf2b4934ddb330e08a73320123c07f95cc2d92"}, + {file = "coverage-6.3.2-pp36.pp37.pp38-none-any.whl", hash = "sha256:18d520c6860515a771708937d2f78f63cc47ab3b80cb78e86573b0a760161faf"}, + {file = "coverage-6.3.2.tar.gz", hash = "sha256:03e2a7826086b91ef345ff18742ee9fc47a6839ccd517061ef8fa1976e652ce9"}, +] +crontab = [ + {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, +] +dependency-injector = [ + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, +] +distlib = [ + {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, + {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, +] +docutils = [ + {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, + {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, +] +fastavro = [ + {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, + {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, + {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, + {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, + {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, + {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, + {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, + {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, + {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, + {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, + {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, + {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, + {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, + {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, + {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, + {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, +] +filelock = [ + {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, + {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, +] +flake8 = [ + {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, + {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, +] +h11 = [ + {file = "h11-0.12.0-py3-none-any.whl", hash = "sha256:36a3cb8c0a032f56e2da7084577878a035d3b61d104230d4bd49c0c6b555a9c6"}, + {file = "h11-0.12.0.tar.gz", hash = "sha256:47222cb6067e4a307d535814917cd98fd0a57b6788ce715755fa2b6c28b56042"}, +] +httpcore = [ + {file = "httpcore-0.14.7-py3-none-any.whl", hash = "sha256:47d772f754359e56dd9d892d9593b6f9870a37aeb8ba51e9a88b09b3d68cfade"}, + {file = "httpcore-0.14.7.tar.gz", hash = "sha256:7503ec1c0f559066e7e39bc4003fd2ce023d01cf51793e3c173b864eb456ead1"}, +] +httpx = [ + {file = "httpx-0.22.0-py3-none-any.whl", hash = "sha256:e35e83d1d2b9b2a609ef367cc4c1e66fd80b750348b20cc9e19d1952fc2ca3f6"}, + {file = "httpx-0.22.0.tar.gz", hash = "sha256:d8e778f76d9bbd46af49e7f062467e3157a5a3d2ae4876a4bbfd8a51ed9c9cb4"}, +] +identify = [ + {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, + {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, +] +idna = [ + {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, + {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, +] +imagesize = [ + {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, + {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, +] +importlib-metadata = [ + {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, + {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, +] +iniconfig = [ + {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, + {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, +] +isort = [ + {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, + {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, +] +jinja2 = [ + {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, + {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, +] +lmdb = [ + {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, + {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, + {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, + {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, + {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, + {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, + {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, + {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, + {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, + {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, + {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, + {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, + {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, + {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, + {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, + {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, + {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, + {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, + {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, + {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, + {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, + {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, + {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, + {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, + {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, + {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, + {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, +] +m2r2 = [ + {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, + {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, +] +markupsafe = [ + {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, + {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, + {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, + {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, + {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, + {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, + {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, + {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, + {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, + {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, + {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, + {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, + {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, + {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, + {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, + {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, + {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, + {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, + {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, + {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, + {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, + {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, + {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, + {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, + {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, + {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, + {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, + {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, + {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, + {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, + {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, + {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, + {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, + {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, + {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, + {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, + {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, + {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, + {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, + {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, +] +mccabe = [ + {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, + {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, +] +minos-microservice-common = [] +minos-microservice-networks = [] +mistune = [ + {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, + {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, +] +mypy-extensions = [ + {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, + {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, +] +nodeenv = [ + {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, + {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, +] +orjson = [ + {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, + {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, + {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, + {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, + {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, + {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, + {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, + {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, + {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, + {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, + {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, + {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, + {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, + {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, + {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, + {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, + {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, + {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, + {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, + {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, + {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, + {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, + {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, + {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, + {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, + {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, + {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, + {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, + {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, + {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, + {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, + {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, +] +packaging = [ + {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, + {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, +] +pathspec = [ + {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, + {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, +] +pbr = [ + {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, + {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, +] +platformdirs = [ + {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, + {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, +] +pluggy = [ + {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, + {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, +] +pre-commit = [ + {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, + {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, +] +psycopg2-binary = [ + {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, +] +py = [ + {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, + {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, +] +pycodestyle = [ + {file = "pycodestyle-2.8.0-py2.py3-none-any.whl", hash = "sha256:720f8b39dde8b293825e7ff02c475f3077124006db4f440dcbc9a20b76548a20"}, + {file = "pycodestyle-2.8.0.tar.gz", hash = "sha256:eddd5847ef438ea1c7870ca7eb78a9d47ce0cdb4851a5523949f2601d0cbbe7f"}, +] +pyflakes = [ + {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, + {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, +] +pygments = [ + {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, + {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, +] +pyparsing = [ + {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, + {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, +] +pytest = [ + {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, + {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, +] +pytz = [ + {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, + {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, +] +pyyaml = [ + {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, + {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, + {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, + {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4"}, + {file = "PyYAML-6.0-cp36-cp36m-win32.whl", hash = "sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293"}, + {file = "PyYAML-6.0-cp36-cp36m-win_amd64.whl", hash = "sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57"}, + {file = "PyYAML-6.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9"}, + {file = "PyYAML-6.0-cp37-cp37m-win32.whl", hash = "sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737"}, + {file = "PyYAML-6.0-cp37-cp37m-win_amd64.whl", hash = "sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d"}, + {file = "PyYAML-6.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287"}, + {file = "PyYAML-6.0-cp38-cp38-win32.whl", hash = "sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78"}, + {file = "PyYAML-6.0-cp38-cp38-win_amd64.whl", hash = "sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0"}, + {file = "PyYAML-6.0-cp39-cp39-win32.whl", hash = "sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb"}, + {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, + {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, +] +requests = [ + {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, + {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, +] +rfc3986 = [ + {file = "rfc3986-1.5.0-py2.py3-none-any.whl", hash = "sha256:a86d6e1f5b1dc238b218b012df0aa79409667bb209e58da56d0b94704e712a97"}, + {file = "rfc3986-1.5.0.tar.gz", hash = "sha256:270aaf10d87d0d4e095063c65bf3ddbc6ee3d0b226328ce21e036f946e421835"}, +] +six = [ + {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, + {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, +] +sniffio = [ + {file = "sniffio-1.2.0-py3-none-any.whl", hash = "sha256:471b71698eac1c2112a40ce2752bb2f4a4814c22a54a3eed3676bc0f5ca9f663"}, + {file = "sniffio-1.2.0.tar.gz", hash = "sha256:c4666eecec1d3f50960c6bdf61ab7bc350648da6c126e3cf6898d8cd4ddcd3de"}, +] +snowballstemmer = [ + {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, + {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, +] +sphinx = [ + {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, + {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, +] +sphinx-autodoc-typehints = [ + {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, + {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, +] +sphinx-rtd-theme = [ + {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, + {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, +] +sphinxcontrib-apidoc = [ + {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, + {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, +] +sphinxcontrib-applehelp = [ + {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, + {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, +] +sphinxcontrib-devhelp = [ + {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, + {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, +] +sphinxcontrib-htmlhelp = [ + {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, + {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, +] +sphinxcontrib-jsmath = [ + {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, + {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, +] +sphinxcontrib-qthelp = [ + {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, + {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, +] +sphinxcontrib-serializinghtml = [ + {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, + {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, +] +toml = [ + {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, + {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, +] +tomli = [ + {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, + {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, +] +typing-extensions = [ + {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, + {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, +] +urllib3 = [ + {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, + {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, +] +uvloop = [ + {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, + {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, + {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:bd53f7f5db562f37cd64a3af5012df8cac2c464c97e732ed556800129505bd64"}, + {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:772206116b9b57cd625c8a88f2413df2fcfd0b496eb188b82a43bed7af2c2ec9"}, + {file = "uvloop-0.16.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:b572256409f194521a9895aef274cea88731d14732343da3ecdb175228881638"}, + {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:04ff57aa137230d8cc968f03481176041ae789308b4d5079118331ab01112450"}, + {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3a19828c4f15687675ea912cc28bbcb48e9bb907c801873bd1519b96b04fb805"}, + {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e814ac2c6f9daf4c36eb8e85266859f42174a4ff0d71b99405ed559257750382"}, + {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:bd8f42ea1ea8f4e84d265769089964ddda95eb2bb38b5cbe26712b0616c3edee"}, + {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:647e481940379eebd314c00440314c81ea547aa636056f554d491e40503c8464"}, + {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e0d26fa5875d43ddbb0d9d79a447d2ace4180d9e3239788208527c4784f7cab"}, + {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:6ccd57ae8db17d677e9e06192e9c9ec4bd2066b77790f9aa7dede2cc4008ee8f"}, + {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:089b4834fd299d82d83a25e3335372f12117a7d38525217c2258e9b9f4578897"}, + {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98d117332cc9e5ea8dfdc2b28b0a23f60370d02e1395f88f40d1effd2cb86c4f"}, + {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, + {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, +] +virtualenv = [ + {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, + {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, +] +zipp = [ + {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, + {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, +] diff --git a/packages/plugins/minos-kong/poetry.toml b/packages/plugins/minos-kong/poetry.toml new file mode 100644 index 000000000..ab1033bd3 --- /dev/null +++ b/packages/plugins/minos-kong/poetry.toml @@ -0,0 +1,2 @@ +[virtualenvs] +in-project = true diff --git a/packages/plugins/minos-kong/pyproject.toml b/packages/plugins/minos-kong/pyproject.toml new file mode 100644 index 000000000..6264e9407 --- /dev/null +++ b/packages/plugins/minos-kong/pyproject.toml @@ -0,0 +1,55 @@ +[tool.poetry] +name = "minos-kong" +version = "0.1.0" +description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" +readme = "README.md" +repository = "https://github.com/minos-framework/minos-python" +homepage = "https://www.minos.run/" +authors = ["Minos Framework Devs "] +license = "MIT" +classifiers = [ + "Development Status :: 4 - Beta", + "Intended Audience :: Developers", + "Natural Language :: English", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3.9", +] +keywords = [ + "clariteia", + "minos", + "microservice", + "saga", +] +packages = [ + { include = "minos" } +] +include = [ + "AUTHORS.md", + "HISTORY.md", + "LICENSE", +] + +[tool.poetry.dependencies] +python = "^3.9" +minos-microservice-common = "^0.6.0" +minos-microservice-networks = "^0.6.0" +httpx = "^0.22.0" + +[tool.poetry.dev-dependencies] +minos-microservice-common = { path = "../../core/minos-microservice-common", develop = true } +minos-microservice-networks = { path = "../../core/minos-microservice-networks", develop = true } +black = "^22.1" +isort = "^5.8.0" +pytest = "^6.2.4" +coverage = "^6.3" +flake8 = "^4.0.1" +Sphinx = "^4.0.1" +pre-commit = "^2.12.1" +sphinx-autodoc-typehints = "^1.12.0" +sphinxcontrib-apidoc = "^0.3.0" +sphinx-rtd-theme = "^1.0.0" +m2r2 = "^0.3.2" + +[build-system] +requires = ["poetry-core>=1.0.0"] +build-backend = "poetry.core.masonry.api" diff --git a/packages/plugins/minos-kong/setup.cfg b/packages/plugins/minos-kong/setup.cfg new file mode 100644 index 000000000..dbb9ac849 --- /dev/null +++ b/packages/plugins/minos-kong/setup.cfg @@ -0,0 +1,28 @@ +[coverage:run] +source = + minos + +[coverage:report] +exclude_lines = + pragma: no cover + raise NotImplementedError + if TYPE_CHECKING: + pass +precision = 2 + +[flake8] +filename = + ./minos/**/*.py, + ./tests/**/*.py, + ./examples/**/*.py +max-line-length = 120 +per-file-ignores = + ./**/__init__.py:F401,W391 + +[isort] +known_first_party=minos +multi_line_output = 3 +include_trailing_comma = True +force_grid_wrap = 1 +use_parentheses = True +line_length = 120 diff --git a/packages/plugins/minos-kong/tests/docker-compose.yml b/packages/plugins/minos-kong/tests/docker-compose.yml new file mode 100644 index 000000000..f807b9044 --- /dev/null +++ b/packages/plugins/minos-kong/tests/docker-compose.yml @@ -0,0 +1,99 @@ +version: '3.9' + +x-kong-config: &kong-env + KONG_DATABASE: postgres + KONG_PG_DATABASE: kong + KONG_PG_HOST: db + KONG_PG_USER: kong + KONG_PG_PASSWORD: kong + +volumes: + kong_data: {} + kong_prefix_vol: + driver_opts: + type: tmpfs + device: tmpfs + kong_tmp_vol: + driver_opts: + type: tmpfs + device: tmpfs + +services: + kong-migrations: + image: kong/kong-gateway:2.8.0.0-alpine + command: kong migrations bootstrap + depends_on: + - db + environment: + KONG_DATABASE: postgres + KONG_PG_DATABASE: kong + KONG_PG_HOST: db + KONG_PG_USER: kong + KONG_PG_PASSWORD: kong + restart: on-failure + + kong-migrations-up: + image: kong/kong-gateway:2.8.0.0-alpine + command: kong migrations up && kong migrations finish + depends_on: + - db + environment: + KONG_DATABASE: postgres + KONG_PG_DATABASE: kong + KONG_PG_HOST: db + KONG_PG_USER: kong + KONG_PG_PASSWORD: kong + restart: on-failure + + kong: + image: kong/kong-gateway:2.8.0.0-alpine + user: kong + environment: + KONG_DATABASE: postgres + KONG_PG_DATABASE: kong + KONG_PG_HOST: db + KONG_PG_USER: kong + KONG_PG_PASSWORD: kong + KONG_ADMIN_ACCESS_LOG: /dev/stdout + KONG_ADMIN_ERROR_LOG: /dev/stderr + KONG_PROXY_LISTEN: 0.0.0.0:8000 + KONG_ADMIN_LISTEN: 0.0.0.0:8001 + KONG_PROXY_ACCESS_LOG: /dev/stdout + KONG_PROXY_ERROR_LOG: /dev/stderr + KONG_PREFIX: /var/run/kong + KONG_DECLARATIVE_CONFIG: "/opt/kong/kong.yaml" + ports: + - "0.0.0.0:8000:8000/tcp" + - "0.0.0.0:8443:8443/tcp" + - "127.0.0.1:8001:8001/tcp" + - "127.0.0.1:8444:8444/tcp" + healthcheck: + test: ["CMD", "kong", "health"] + interval: 10s + timeout: 10s + retries: 10 + restart: on-failure:5 + read_only: true + volumes: + - kong_prefix_vol:/var/run/kong + - kong_tmp_vol:/tmp + - ./config:/opt/kong + security_opt: + - no-new-privileges + + db: + image: postgres:9.5 + environment: + POSTGRES_DB: kong + POSTGRES_USER: kong + POSTGRES_PASSWORD: kong + healthcheck: + test: ["CMD", "pg_isready", "-U", "kong"] + interval: 30s + timeout: 30s + retries: 3 + restart: on-failure + stdin_open: true + tty: true + volumes: + - kong_data:/var/lib/postgresql/data diff --git a/packages/plugins/minos-kong/tests/test_minos_discovery/__init__.py b/packages/plugins/minos-kong/tests/test_minos_discovery/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py b/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py new file mode 100644 index 000000000..ac6bfc669 --- /dev/null +++ b/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py @@ -0,0 +1,35 @@ +import unittest +from minos.plugins.minos_kong import ( + MinosKongClient, +) + + +class TestMinosKongClient(unittest.IsolatedAsyncioTestCase): + def setUp(self) -> None: + self.client = MinosKongClient("localhost", 8001, circuit_breaker_time=0.1) + + def test_constructor(self): + client = MinosKongClient() + self.assertEqual("localhost", client.host) + self.assertEqual(5567, client.port) + + def test_route(self): + # noinspection HttpUrlsUsage + self.assertEqual("http://localhost:8001", self.client.route) + + async def test_subscribe(self): + response = await self.client.subscribe( + "172.160.16.24", 5660, "test", [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] + ) + self.assertTrue(201 == response.status_code) + + async def test_unsubscribe(self): + response = await self.client.subscribe( + "172.160.16.24", 5660, "test", [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] + ) + + response_delete = await self.client.unsubscribe("test") + self.assertTrue(204 == response_delete.status_code) + +if __name__ == "__main__": + unittest.main() From f785a2f4ab35923621b45a4dd61b4d4543155ef1 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Wed, 30 Mar 2022 19:22:33 +0200 Subject: [PATCH 010/324] modified readme --- packages/plugins/minos-kong/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/plugins/minos-kong/README.md b/packages/plugins/minos-kong/README.md index 01d5852be..a76d57c00 100644 --- a/packages/plugins/minos-kong/README.md +++ b/packages/plugins/minos-kong/README.md @@ -2,7 +2,7 @@ Minos logo

-## minos-discovery-minos +## minos-kong [![PyPI Latest Release](https://img.shields.io/pypi/v/minos-kong.svg)](https://pypi.org/project/minos-kong/) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://minos-framework.github.io/minos-python) From 0584404ca25cf615cf4fc7badb95512d069e61fa Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Wed, 30 Mar 2022 19:54:00 +0200 Subject: [PATCH 011/324] updated with regex routes creation --- .../minos-kong/minos/plugins/minos_kong/utils.py | 7 ++++++- .../tests/test_minos_discovery/test_client.py | 15 +++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/utils.py b/packages/plugins/minos-kong/minos/plugins/minos_kong/utils.py index 07bd67a51..431a3dcad 100644 --- a/packages/plugins/minos-kong/minos/plugins/minos_kong/utils.py +++ b/packages/plugins/minos-kong/minos/plugins/minos_kong/utils.py @@ -10,4 +10,9 @@ def __init__(self, path: str): @property def path_as_str(self) -> str: - return "/".join([str(part.name) for part in self.path]) + list_parts = [] + for part in self.path: + if part.is_generic: + part.name = ".*" + list_parts.append(str(part.name)) + return "/".join(list_parts) diff --git a/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py b/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py index ac6bfc669..5f7c29db4 100644 --- a/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py +++ b/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py @@ -1,4 +1,5 @@ import unittest +import httpx from minos.plugins.minos_kong import ( MinosKongClient, ) @@ -31,5 +32,19 @@ async def test_unsubscribe(self): response_delete = await self.client.unsubscribe("test") self.assertTrue(204 == response_delete.status_code) + async def test_route_params(self): + response = await self.client.subscribe( + "172.160.16.24", 5660, "test", [{"url": "/foo/{:user}", "method": "POST"}, + {"url": "/bar/{:domain}/{:username}", "method": "GET"}] + ) + + async with httpx.AsyncClient() as client: + url = f"http://{self.client.host}:{self.client.port}/services/test/routes" + response = await client.get(url) + response_data = response.json() + self.assertGreater(len(response_data['data']), 0) + self.assertTrue(201 == response.status_code) + + if __name__ == "__main__": unittest.main() From 7e99c6f2af1a8fa7be2e85b4a645dd712e19edcb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 31 Mar 2022 08:54:03 +0200 Subject: [PATCH 012/324] ISSUE #332 * Minor fixes. --- packages/core/minos-microservice-aggregate/docs/conf.py | 8 +++----- .../minos/aggregate/transactions/contextvars.py | 2 +- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/docs/conf.py b/packages/core/minos-microservice-aggregate/docs/conf.py index 1089dd782..0e9203fdc 100755 --- a/packages/core/minos-microservice-aggregate/docs/conf.py +++ b/packages/core/minos-microservice-aggregate/docs/conf.py @@ -5,7 +5,7 @@ sys.path.insert(0, os.path.abspath("..")) from minos import ( - aggregate as module, + aggregate as package, ) extensions = [ @@ -22,16 +22,14 @@ copyright = f"2021-{datetime.now().year}, Clariteia" author = "Minos Framework Devs" -version = module.__version__ -release = module.__version__ +version = package.__version__ +release = package.__version__ exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] -todo_include_todos = False html_theme = "sphinx_rtd_theme" html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} html_static_path = ["_static"] -htmlhelp_basename = "minosdoc" apidoc_module_dir = "../minos" apidoc_output_dir = "api" diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py index b04eb9506..6db02792c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py @@ -19,4 +19,4 @@ TRANSACTION_CONTEXT_VAR: Final[ContextVar[Optional[TransactionEntry]]] = ContextVar("transaction", default=None) """ Context Variable that contains the transaction's identifier of the currently active transaction, or ``None`` otherwise. -""" \ No newline at end of file +""" From 6961bb63dfe2421de7e81048d327be36ffe2d25f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 31 Mar 2022 08:56:18 +0200 Subject: [PATCH 013/324] ISSUE #332 * Minor fixes (2). --- packages/core/minos-microservice-aggregate/docs/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-aggregate/docs/index.md b/packages/core/minos-microservice-aggregate/docs/index.md index 0e50336bc..8318ac7cf 100644 --- a/packages/core/minos-microservice-aggregate/docs/index.md +++ b/packages/core/minos-microservice-aggregate/docs/index.md @@ -1,7 +1,7 @@ # Welcome to `minos-microservice-aggregate`'s documentation! .. toctree:: - :maxdepth: 1 + :maxdepth: 2 readme reference From 376a7c7acee1198301a081ee9e1bfc538b07578d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 31 Mar 2022 09:13:45 +0200 Subject: [PATCH 014/324] ISSUE #332 * Minor fixes (3). --- .../minos-microservice-aggregate/docs/_static/style.css | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-aggregate/docs/_static/style.css b/packages/core/minos-microservice-aggregate/docs/_static/style.css index efaf9ef61..45da50c55 100644 --- a/packages/core/minos-microservice-aggregate/docs/_static/style.css +++ b/packages/core/minos-microservice-aggregate/docs/_static/style.css @@ -2,6 +2,10 @@ max-width: 1200px !important; } -dl, .py + dd + dl, .py { +dl[class*="py"] { + display: block !important; +} + +dl[class*="py"] > dt { display: block !important; } \ No newline at end of file From 43fb8c2b4b228f65921c240e9cdaff786fc4e68f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 31 Mar 2022 09:14:50 +0200 Subject: [PATCH 015/324] ISSUE #332 * Reformat code. --- .../core/minos-microservice-aggregate/docs/conf.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/docs/conf.py b/packages/core/minos-microservice-aggregate/docs/conf.py index 0e9203fdc..aed046dba 100755 --- a/packages/core/minos-microservice-aggregate/docs/conf.py +++ b/packages/core/minos-microservice-aggregate/docs/conf.py @@ -1,12 +1,12 @@ import os import sys -from datetime import datetime +from datetime import ( + datetime, +) sys.path.insert(0, os.path.abspath("..")) -from minos import ( - aggregate as package, -) +from minos import aggregate as package extensions = [ "sphinxcontrib.apidoc", @@ -44,7 +44,7 @@ "members": True, "inherited-members": True, "undoc-members": True, - 'member-order': 'bysource', + "member-order": "bysource", } autoclass_content = "both" autodoc_member_order = "bysource" From 5439c34cc4cf329c62c46c167669ea1ad751f24c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 31 Mar 2022 09:29:43 +0200 Subject: [PATCH 016/324] ISSUE #332 * Minor fixes (4). --- packages/core/minos-microservice-aggregate/docs/conf.py | 1 - .../minos/aggregate/contextvars.py | 5 +---- .../minos/aggregate/transactions/contextvars.py | 4 +--- 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/docs/conf.py b/packages/core/minos-microservice-aggregate/docs/conf.py index aed046dba..0ec7a56cc 100755 --- a/packages/core/minos-microservice-aggregate/docs/conf.py +++ b/packages/core/minos-microservice-aggregate/docs/conf.py @@ -42,7 +42,6 @@ ] autodoc_default_options = { "members": True, - "inherited-members": True, "undoc-members": True, "member-order": "bysource", } diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/contextvars.py b/packages/core/minos-microservice-aggregate/minos/aggregate/contextvars.py index 482bd865d..2bcc02511 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/contextvars.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/contextvars.py @@ -8,7 +8,4 @@ IS_REPOSITORY_SERIALIZATION_CONTEXT_VAR: Final[ContextVar[bool]] = ContextVar( "is_repository_serialization", default=False ) -""" -Context variable that contains ``True`` if the serialization process has been started by some repository, or ``False`` -otherwise. -""" +"""Context variable containing ``True`` if serialization has been started by a repository, or ``False`` otherwise.""" diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py index 6db02792c..473025386 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/contextvars.py @@ -17,6 +17,4 @@ ) TRANSACTION_CONTEXT_VAR: Final[ContextVar[Optional[TransactionEntry]]] = ContextVar("transaction", default=None) -""" -Context Variable that contains the transaction's identifier of the currently active transaction, or ``None`` otherwise. -""" +"""Context Variable that contains the identifier of the currently active transaction, or ``None`` otherwise.""" From 07d215ba1034c65378fe17f0791e95c852b0e3ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 31 Mar 2022 10:44:31 +0200 Subject: [PATCH 017/324] ISSUE #332 * Minor fixes (5). --- .../minos-microservice-aggregate/docs/conf.py | 20 ++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-aggregate/docs/conf.py b/packages/core/minos-microservice-aggregate/docs/conf.py index 0ec7a56cc..4b029151c 100755 --- a/packages/core/minos-microservice-aggregate/docs/conf.py +++ b/packages/core/minos-microservice-aggregate/docs/conf.py @@ -12,6 +12,8 @@ "sphinxcontrib.apidoc", "sphinx.ext.autodoc", "sphinx.ext.viewcode", + "sphinx.ext.intersphinx", + "sphinx.ext.autosummary", "m2r2", ] templates_path = ["_templates"] @@ -43,10 +45,26 @@ autodoc_default_options = { "members": True, "undoc-members": True, + "inherited-members": True, + #"special-members": "__init__", "member-order": "bysource", } -autoclass_content = "both" +autoclass_content = "class" +autodoc_class_signature = "separated" autodoc_member_order = "bysource" autodoc_typehints_format = "short" autodoc_typehints = "description" +autodoc_preserve_defaults = True add_module_names = False +intersphinx_mapping = { + "python": ("https://docs.python.org/3", None), + "minos-microservice-common": ( + "https://minos-framework.github.io/minos-python/packages/core/minos-microservice-common", + ("../../minos-microservice-common/docs/_build/html/objects.inv", None), + ), + "minos-microservice-networks": ( + "https://minos-framework.github.io/minos-python/packages/core/minos-microservice-networks", + ("../../minos-microservice-networks/docs/_build/html/objects.inv", None), + ), + +} From f8ba454b24787fc3cf60c14375c831a6c9c9035e Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Thu, 31 Mar 2022 12:47:24 +0200 Subject: [PATCH 018/324] added some doc lines --- .../minos/plugins/minos_kong/client.py | 30 ++++++++++++------- 1 file changed, 19 insertions(+), 11 deletions(-) diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py b/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py index d8363f8db..4300c9ae6 100644 --- a/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py +++ b/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py @@ -52,16 +52,17 @@ async def subscribe( :param kwargs: Additional named arguments. :return: This method does not return anything. """ + fnsr = partial(self._register_service, self.route, name, host, port) - response_service = await self.with_circuit_breaker(fnsr) - if response_service.status_code == 409: + response_service = await self.with_circuit_breaker(fnsr) # register a service + if response_service.status_code == 409: # service already exist # if service already exist, delete and add again fn_delete = partial(self._delete_service, self.route, name) - response_delete = await self.with_circuit_breaker(fn_delete) + response_delete = await self.with_circuit_breaker(fn_delete) # delete the service fnsr = partial(self._register_service, self.route, name, host, port) - response_service = await self.with_circuit_breaker(fnsr) + response_service = await self.with_circuit_breaker(fnsr) # send the servie subscription again - content_service = response_service.json() + content_service = response_service.json() # get the servie information like the id for endpoint in endpoints: endpointClass = Endpoint(endpoint["url"]) @@ -74,14 +75,14 @@ async def subscribe( } } fn = partial(self._subscribe_routes, self.route, data) - response = await self.with_circuit_breaker(fn) + response = await self.with_circuit_breaker(fn) # send the route request return response @staticmethod async def _register_service(discovery_route: str, service_name: str, microservice_host: str, microservice_port: str) -> httpx.Response: - url = f"{discovery_route}/services" + url = f"{discovery_route}/services" # kong url for service POST or add data = { "name": service_name, "protocol": "http", @@ -114,14 +115,21 @@ async def unsubscribe(self, name: str, *args, **kwargs) -> httpx.Response: @staticmethod async def _delete_service(discovery_route: str, service_name) -> httpx.Response: + """ + the delete of a service must be checking before if the service already have the routes + if yes the DELETE routes must be called + :param discovery_route: + :param service_name: + :return: + """ async with httpx.AsyncClient() as client: - url_get_route = f"{discovery_route}/services/{service_name}/routes" + url_get_route = f"{discovery_route}/services/{service_name}/routes" # url to get the routes response_routes = await client.get(url_get_route) json_routes_response = response_routes.json() - if len(json_routes_response["data"]) > 0: + if len(json_routes_response["data"]) > 0: # service already have route, routes must be deleted for route in json_routes_response["data"]: - url_delete_route = f"{discovery_route}/routes/{route['id']}" + url_delete_route = f"{discovery_route}/routes/{route['id']}" # url for routes delete await client.delete(url_delete_route) - url_delete_service = f"{discovery_route}/services/{service_name}" + url_delete_service = f"{discovery_route}/services/{service_name}" # url for service delete response_delete_service = await client.delete(url_delete_service) return response_delete_service From 008c7bb9666a861032892cfd06e2bcbda34b666a Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 31 Mar 2022 12:48:44 +0200 Subject: [PATCH 019/324] Fix test --- packages/plugins/minos-kong/tests/Makefile | 30 +++++++++++++++++++ .../tests/test_minos_discovery/test_client.py | 7 ++++- 2 files changed, 36 insertions(+), 1 deletion(-) create mode 100644 packages/plugins/minos-kong/tests/Makefile diff --git a/packages/plugins/minos-kong/tests/Makefile b/packages/plugins/minos-kong/tests/Makefile new file mode 100644 index 000000000..c874587ac --- /dev/null +++ b/packages/plugins/minos-kong/tests/Makefile @@ -0,0 +1,30 @@ +up: + $(MAKE) build + echo "Starting containers..." + docker-compose up --quiet-pull --detach + +build: + echo "Building images..." + docker-compose build --progress=plain --pull + +down: + echo "Stopping containers..." + docker-compose down --remove-orphans + +clean: + echo "Cleaning..." + docker system prune -a + docker volume rm $(docker volume ls -q) + docker rm -f $(docker ps -a -q) + +logs: + echo "Showing logs..." + docker-compose logs --follow + +export-logs: + echo "Showing logs..." + docker-compose logs --no-color > logs.txt + +integration-tests: + echo "Running Integration Tests..." + docker-compose run tavern \ No newline at end of file diff --git a/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py b/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py index 5f7c29db4..67e83d8f6 100644 --- a/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py +++ b/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py @@ -29,6 +29,8 @@ async def test_unsubscribe(self): "172.160.16.24", 5660, "test", [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] ) + self.assertTrue(201 == response.status_code) + response_delete = await self.client.unsubscribe("test") self.assertTrue(204 == response_delete.status_code) @@ -38,12 +40,15 @@ async def test_route_params(self): {"url": "/bar/{:domain}/{:username}", "method": "GET"}] ) + self.assertTrue(201 == response.status_code) + async with httpx.AsyncClient() as client: url = f"http://{self.client.host}:{self.client.port}/services/test/routes" response = await client.get(url) response_data = response.json() self.assertGreater(len(response_data['data']), 0) - self.assertTrue(201 == response.status_code) + + self.assertTrue(200 == response.status_code) if __name__ == "__main__": From e04f5d6e4931c5b01ec908c9542567850964486e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 31 Mar 2022 12:57:59 +0200 Subject: [PATCH 020/324] ISSUE #332 * Fully refactor documentation process. --- .gitignore | 2 +- Makefile | 35 +-------------------- README.md | 1 + docs/_static/style.css | 8 +++++ docs/conf.py | 69 ++++++++++++++++++++++++++++-------------- docs/index.md | 42 ++++++++++++++++++++++++- 6 files changed, 98 insertions(+), 59 deletions(-) diff --git a/.gitignore b/.gitignore index 8746393f5..b0db19fbb 100644 --- a/.gitignore +++ b/.gitignore @@ -323,7 +323,7 @@ $RECYCLE.BIN/ *.lmdb # Sphinx Api Documentation -**/docs/api* +**/docs/api-reference* **/docs/_build tutorials/stock-wallet/front/stock-front diff --git a/Makefile b/Makefile index adc26476f..545c73033 100644 --- a/Makefile +++ b/Makefile @@ -6,38 +6,5 @@ install: poetry install docs: - mkdir -p $(DOCS_TARGET)/core - mkdir -p $(DOCS_TARGET)/plugins - - $(MAKE) --directory=packages/core/minos-microservice-aggregate install docs - cp -R packages/core/minos-microservice-aggregate/docs/_build/html $(DOCS_TARGET)/core/minos-microservice-aggregate - - $(MAKE) --directory=packages/core/minos-microservice-common install docs - cp -R packages/core/minos-microservice-common/docs/_build/html $(DOCS_TARGET)/core/minos-microservice-common - - $(MAKE) --directory=packages/core/minos-microservice-cqrs install docs - cp -R packages/core/minos-microservice-cqrs/docs/_build/html $(DOCS_TARGET)/core/minos-microservice-cqrs - - $(MAKE) --directory=packages/core/minos-microservice-networks install docs - cp -R packages/core/minos-microservice-networks/docs/_build/html $(DOCS_TARGET)/core/minos-microservice-networks - - $(MAKE) --directory=packages/core/minos-microservice-saga install docs - cp -R packages/core/minos-microservice-saga/docs/_build/html $(DOCS_TARGET)/core/minos-microservice-saga - - $(MAKE) --directory=packages/plugins/minos-broker-kafka install docs - cp -R packages/plugins/minos-broker-kafka/docs/_build/html $(DOCS_TARGET)/plugins/minos-broker-kafka - - $(MAKE) --directory=packages/plugins/minos-broker-rabbitmq install docs - cp -R packages/plugins/minos-broker-rabbitmq/docs/_build/html $(DOCS_TARGET)/plugins/minos-broker-rabbitmq - - $(MAKE) --directory=packages/plugins/minos-discovery-minos install docs - cp -R packages/plugins/minos-discovery-minos/docs/_build/html $(DOCS_TARGET)/plugins/minos-discovery-minos - - $(MAKE) --directory=packages/plugins/minos-http-aiohttp install docs - cp -R packages/plugins/minos-http-aiohttp/docs/_build/html $(DOCS_TARGET)/plugins/minos-http-aiohttp - - $(MAKE) --directory=packages/plugins/minos-router-graphql install docs - cp -R packages/plugins/minos-router-graphql/docs/_build/html $(DOCS_TARGET)/plugins/minos-router-graphql - - + rm -rf docs/api-reference poetry run $(MAKE) --directory=docs html diff --git a/README.md b/README.md index 76d0206d3..11d551960 100644 --- a/README.md +++ b/README.md @@ -4,6 +4,7 @@ # minos-python: The framework which helps you create reactive microservices in Python +[![GitHub Repo stars](https://img.shields.io/github/stars/minos-framework/minos-python?label=GitHub)] [![PyPI Latest Release](https://img.shields.io/pypi/v/minos-microservice-common.svg)](https://pypi.org/project/minos-microservice-common/) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://minos-framework.github.io/minos-python) [![License](https://img.shields.io/github/license/minos-framework/minos-python.svg)](https://github.com/minos-framework/minos-python/blob/main/LICENSE) diff --git a/docs/_static/style.css b/docs/_static/style.css index 8aa6c288f..45da50c55 100644 --- a/docs/_static/style.css +++ b/docs/_static/style.css @@ -1,3 +1,11 @@ .wy-nav-content { max-width: 1200px !important; } + +dl[class*="py"] { + display: block !important; +} + +dl[class*="py"] > dt { + display: block !important; +} \ No newline at end of file diff --git a/docs/conf.py b/docs/conf.py index f42516f84..044ed7176 100755 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,38 +1,61 @@ import os import sys +from datetime import datetime -sys.path.insert(0, os.path.abspath('..')) +sys.path.insert(0, os.path.abspath("..")) -import sphinx_rtd_theme # noqa +from minos import common + +exclude_patterns = [ + "standard/docs/*.md", # FIXME: Include these directories. + "standard/docs/architecture/*.md", # FIXME: Include these directories. + "_build", + "Thumbs.db", + ".DS_Store", +] extensions = [ + # "sphinxcontrib.apidoc", + "sphinx.ext.autodoc", "sphinx.ext.viewcode", - "sphinx_rtd_theme", + "sphinx.ext.intersphinx", + "sphinx.ext.autosummary", "m2r2", ] +templates_path = ["_templates"] +source_suffix = [".rst", ".md"] -source_suffix = ['.rst', '.md'] - -master_doc = 'index' - -project = 'Minos Python' -copyright = "2021, Clariteia" +master_doc = "index" +project = "minos-python" +copyright = f"2021-{datetime.now().year}, Clariteia" author = "Minos Framework Devs" -language = None - -templates_path = ['_templates'] - -exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] - -pygments_style = 'sphinx' - -todo_include_todos = False - -html_theme = 'sphinx_rtd_theme' - -html_extra_path = ['api-reference'] +version = common.__version__ +release = common.__version__ +html_theme = "sphinx_rtd_theme" html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - html_static_path = ["_static"] + +autodoc_default_options = { + "members": True, + "undoc-members": True, + "inherited-members": True, + "show-inheritance": True, + "member-order": "bysource", +} +autodoc_mock_imports = [ + "unittest", +] + +autoclass_content = "class" +autodoc_class_signature = "separated" +autodoc_member_order = "bysource" +autodoc_typehints_format = "short" +autodoc_typehints = "description" +autodoc_preserve_defaults = True +add_module_names = False +intersphinx_mapping = { + "python": ("https://docs.python.org/3", None), +} +autosummary_generate = True diff --git a/docs/index.md b/docs/index.md index 97d495851..4c94ac363 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1 +1,41 @@ -.. mdinclude:: ../README.md +

+ Minos logo +

+ +# minos-python: The framework which helps you create reactive microservices in Python + +[![GitHub Repo stars](https://img.shields.io/github/stars/minos-framework/minos-python?label=GitHub)](https://github.com/minos-framework/minos-python/stargazers) +[![PyPI Latest Release](https://img.shields.io/pypi/v/minos-microservice-common.svg)](https://pypi.org/project/minos-microservice-common/) +[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://minos-framework.github.io/minos-python) +[![License](https://img.shields.io/github/license/minos-framework/minos-python.svg)](https://github.com/minos-framework/minos-python/blob/main/LICENSE) +[![Coverage](https://codecov.io/github/minos-framework/minos-python/coverage.svg?branch=main)](https://codecov.io/gh/minos-framework/minos-python) +[![Stack Overflow](https://img.shields.io/badge/Stack%20Overflow-Ask%20a%20question-green)](https://stackoverflow.com/questions/tagged/minos) +[![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/minos-framework/community) +[![Tokei](https://tokei.rs/b1/github/minos-framework/minos-python?category=code)](https://github.com/minos-framework/minos-python) + +## Summary + +Minos is a framework which helps you create [reactive](https://www.reactivemanifesto.org/) microservices in Python. Internally, it leverages Event Sourcing, CQRS and a message driven architecture to fulfil the commitments of an asynchronous environment. + + +## API Reference + +.. autosummary:: + :toctree: api-reference + :recursive: + + minos.aggregate + minos.common + minos.cqrs + minos.networks + minos.saga + minos.plugins.aiohttp + minos.plugins.kafka + minos.plugins.rabbitmq + minos.plugins.minos_discovery + minos.plugins.graphql + +## Indices and tables +* :ref:`genindex` +* :ref:`modindex` +* :ref:`search` From 78e0aed39c6e71327cdcd1fa27ce71bd3f63af5e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 31 Mar 2022 13:15:05 +0200 Subject: [PATCH 021/324] ISSUE #332 * Remove documentation from each package. --- CONTRIBUTING.md | 11 +- docs/index.md | 2 +- .../{CHANGELOG.md => HISTORY.md} | 11 +- .../minos-microservice-aggregate/Makefile | 5 - .../RUNTHETESTS.md | 3 +- .../minos-microservice-aggregate/SETUP.md | 3 +- .../docs/Makefile | 20 - .../docs/_static/style.css | 11 - .../docs/_templates/layout.html | 4 - .../docs/_templates/package.rst_t | 49 -- .../docs/authors.md | 1 - .../docs/changelog.md | 1 - .../minos-microservice-aggregate/docs/conf.py | 70 -- .../docs/index.md | 15 - .../docs/readme.md | 3 - .../docs/reference.md | 5 - .../docs/runthetests.md | 1 - .../minos/aggregate/__init__.py | 2 + .../minos-microservice-aggregate/poetry.lock | 730 ++--------------- .../pyproject.toml | 5 - .../core/minos-microservice-common/HISTORY.md | 165 ++-- .../core/minos-microservice-common/Makefile | 5 - .../minos-microservice-common/RUNTHETESTS.md | 3 +- .../core/minos-microservice-common/SETUP.md | 3 +- .../minos-microservice-common/docs/Makefile | 20 - .../docs/_static/style.css | 3 - .../docs/_templates/layout.html | 4 - .../minos-microservice-common/docs/authors.md | 1 - .../minos-microservice-common/docs/conf.py | 198 ----- .../minos-microservice-common/docs/history.md | 1 - .../minos-microservice-common/docs/index.md | 16 - .../minos-microservice-common/docs/readme.md | 3 - .../docs/runthetests.md | 1 - .../minos/common/__init__.py | 1 + .../minos-microservice-common/poetry.lock | 749 ++---------------- .../minos-microservice-common/pyproject.toml | 6 - .../core/minos-microservice-cqrs/Makefile | 5 - .../minos-microservice-cqrs/RUNTHETESTS.md | 3 +- .../core/minos-microservice-cqrs/SETUP.md | 3 +- .../minos-microservice-cqrs/docs/Makefile | 20 - .../docs/_static/style.css | 3 - .../docs/_templates/layout.html | 4 - .../minos-microservice-cqrs/docs/authors.md | 1 - .../core/minos-microservice-cqrs/docs/conf.py | 197 ----- .../minos-microservice-cqrs/docs/history.md | 1 - .../minos-microservice-cqrs/docs/index.md | 16 - .../minos-microservice-cqrs/docs/readme.md | 3 - .../docs/runthetests.md | 1 - .../minos/cqrs/__init__.py | 2 + .../core/minos-microservice-cqrs/poetry.lock | 749 ++---------------- .../minos-microservice-cqrs/pyproject.toml | 6 - .../minos-microservice-networks/HISTORY.md | 93 +-- .../core/minos-microservice-networks/Makefile | 5 - .../RUNTHETESTS.md | 3 +- .../core/minos-microservice-networks/SETUP.md | 3 +- .../minos-microservice-networks/docs/Makefile | 20 - .../docs/_static/style.css | 3 - .../docs/_templates/layout.html | 4 - .../docs/authors.md | 1 - .../minos-microservice-networks/docs/conf.py | 198 ----- .../docs/history.md | 1 - .../minos-microservice-networks/docs/index.md | 16 - .../docs/readme.md | 3 - .../docs/runthetests.md | 1 - .../minos/networks/__init__.py | 2 + .../minos-microservice-networks/poetry.lock | 749 ++---------------- .../pyproject.toml | 6 - .../core/minos-microservice-saga/HISTORY.md | 87 +- .../core/minos-microservice-saga/Makefile | 5 - .../minos-microservice-saga/RUNTHETESTS.md | 3 +- .../core/minos-microservice-saga/SETUP.md | 3 +- .../minos-microservice-saga/docs/Makefile | 20 - .../docs/_static/style.css | 3 - .../docs/_templates/layout.html | 4 - .../minos-microservice-saga/docs/authors.md | 1 - .../core/minos-microservice-saga/docs/conf.py | 197 ----- .../minos-microservice-saga/docs/history.md | 1 - .../minos-microservice-saga/docs/index.md | 16 - .../minos-microservice-saga/docs/readme.md | 3 - .../docs/runthetests.md | 1 - .../minos/saga/__init__.py | 2 + .../minos/saga/executions/saga.py | 2 +- .../core/minos-microservice-saga/poetry.lock | 749 ++---------------- .../minos-microservice-saga/pyproject.toml | 6 - packages/plugins/minos-broker-kafka/Makefile | 5 - .../plugins/minos-broker-kafka/RUNTHETESTS.md | 3 +- packages/plugins/minos-broker-kafka/SETUP.md | 3 +- .../plugins/minos-broker-kafka/docs/Makefile | 20 - .../minos-broker-kafka/docs/_static/style.css | 3 - .../docs/_templates/layout.html | 4 - .../minos-broker-kafka/docs/authors.md | 1 - .../plugins/minos-broker-kafka/docs/conf.py | 191 ----- .../minos-broker-kafka/docs/history.md | 1 - .../plugins/minos-broker-kafka/docs/index.md | 16 - .../plugins/minos-broker-kafka/docs/readme.md | 3 - .../minos-broker-kafka/docs/runthetests.md | 1 - .../minos/plugins/kafka/__init__.py | 2 + .../plugins/minos-broker-kafka/poetry.lock | 737 ++--------------- .../plugins/minos-broker-kafka/pyproject.toml | 6 - .../plugins/minos-broker-rabbitmq/Makefile | 5 - .../minos-broker-rabbitmq/RUNTHETESTS.md | 3 +- .../plugins/minos-broker-rabbitmq/SETUP.md | 3 +- .../minos-broker-rabbitmq/docs/Makefile | 20 - .../docs/_static/style.css | 3 - .../docs/_templates/layout.html | 4 - .../minos-broker-rabbitmq/docs/authors.md | 1 - .../minos-broker-rabbitmq/docs/conf.py | 191 ----- .../minos-broker-rabbitmq/docs/history.md | 1 - .../minos-broker-rabbitmq/docs/index.md | 16 - .../minos-broker-rabbitmq/docs/readme.md | 3 - .../minos-broker-rabbitmq/docs/runthetests.md | 1 - .../minos/plugins/rabbitmq/__init__.py | 2 + .../plugins/minos-broker-rabbitmq/poetry.lock | 731 ++--------------- .../minos-broker-rabbitmq/pyproject.toml | 6 - .../plugins/minos-discovery-minos/Makefile | 5 - .../minos-discovery-minos/RUNTHETESTS.md | 3 +- .../plugins/minos-discovery-minos/SETUP.md | 3 +- .../minos-discovery-minos/docs/Makefile | 20 - .../docs/_static/style.css | 3 - .../docs/_templates/layout.html | 4 - .../minos-discovery-minos/docs/authors.md | 1 - .../minos-discovery-minos/docs/conf.py | 194 ----- .../minos-discovery-minos/docs/history.md | 1 - .../minos-discovery-minos/docs/index.md | 16 - .../minos-discovery-minos/docs/readme.md | 3 - .../minos-discovery-minos/docs/runthetests.md | 1 - .../minos/plugins/minos_discovery/__init__.py | 2 + .../plugins/minos-discovery-minos/poetry.lock | 710 ++--------------- .../minos-discovery-minos/pyproject.toml | 8 +- packages/plugins/minos-http-aiohttp/Makefile | 5 - .../plugins/minos-http-aiohttp/RUNTHETESTS.md | 3 +- packages/plugins/minos-http-aiohttp/SETUP.md | 3 +- .../plugins/minos-http-aiohttp/docs/Makefile | 20 - .../minos-http-aiohttp/docs/_static/style.css | 3 - .../docs/_templates/layout.html | 4 - .../minos-http-aiohttp/docs/authors.md | 1 - .../plugins/minos-http-aiohttp/docs/conf.py | 197 ----- .../minos-http-aiohttp/docs/history.md | 1 - .../plugins/minos-http-aiohttp/docs/index.md | 17 - .../plugins/minos-http-aiohttp/docs/readme.md | 3 - .../minos-http-aiohttp/docs/runthetests.md | 1 - .../minos/plugins/aiohttp/__init__.py | 2 + .../plugins/minos-http-aiohttp/poetry.lock | 710 ++--------------- .../plugins/minos-http-aiohttp/pyproject.toml | 8 +- .../plugins/minos-router-graphql/Makefile | 5 - .../minos-router-graphql/RUNTHETESTS.md | 3 +- .../plugins/minos-router-graphql/SETUP.md | 3 +- .../minos-router-graphql/docs/Makefile | 20 - .../docs/_static/style.css | 3 - .../docs/_templates/layout.html | 4 - .../minos-router-graphql/docs/authors.md | 1 - .../plugins/minos-router-graphql/docs/conf.py | 197 ----- .../minos-router-graphql/docs/history.md | 1 - .../minos-router-graphql/docs/index.md | 17 - .../minos-router-graphql/docs/readme.md | 3 - .../minos-router-graphql/docs/runthetests.md | 1 - .../minos/plugins/graphql/__init__.py | 2 + .../plugins/minos-router-graphql/poetry.lock | 737 ++--------------- .../minos-router-graphql/pyproject.toml | 8 +- 159 files changed, 841 insertions(+), 9458 deletions(-) rename packages/core/minos-microservice-aggregate/{CHANGELOG.md => HISTORY.md} (96%) delete mode 100644 packages/core/minos-microservice-aggregate/docs/Makefile delete mode 100644 packages/core/minos-microservice-aggregate/docs/_static/style.css delete mode 100644 packages/core/minos-microservice-aggregate/docs/_templates/layout.html delete mode 100644 packages/core/minos-microservice-aggregate/docs/_templates/package.rst_t delete mode 100644 packages/core/minos-microservice-aggregate/docs/authors.md delete mode 100644 packages/core/minos-microservice-aggregate/docs/changelog.md delete mode 100755 packages/core/minos-microservice-aggregate/docs/conf.py delete mode 100644 packages/core/minos-microservice-aggregate/docs/index.md delete mode 100644 packages/core/minos-microservice-aggregate/docs/readme.md delete mode 100644 packages/core/minos-microservice-aggregate/docs/reference.md delete mode 100644 packages/core/minos-microservice-aggregate/docs/runthetests.md delete mode 100644 packages/core/minos-microservice-common/docs/Makefile delete mode 100644 packages/core/minos-microservice-common/docs/_static/style.css delete mode 100644 packages/core/minos-microservice-common/docs/_templates/layout.html delete mode 100644 packages/core/minos-microservice-common/docs/authors.md delete mode 100755 packages/core/minos-microservice-common/docs/conf.py delete mode 100644 packages/core/minos-microservice-common/docs/history.md delete mode 100644 packages/core/minos-microservice-common/docs/index.md delete mode 100644 packages/core/minos-microservice-common/docs/readme.md delete mode 100644 packages/core/minos-microservice-common/docs/runthetests.md delete mode 100644 packages/core/minos-microservice-cqrs/docs/Makefile delete mode 100644 packages/core/minos-microservice-cqrs/docs/_static/style.css delete mode 100644 packages/core/minos-microservice-cqrs/docs/_templates/layout.html delete mode 100644 packages/core/minos-microservice-cqrs/docs/authors.md delete mode 100755 packages/core/minos-microservice-cqrs/docs/conf.py delete mode 100644 packages/core/minos-microservice-cqrs/docs/history.md delete mode 100644 packages/core/minos-microservice-cqrs/docs/index.md delete mode 100644 packages/core/minos-microservice-cqrs/docs/readme.md delete mode 100644 packages/core/minos-microservice-cqrs/docs/runthetests.md delete mode 100644 packages/core/minos-microservice-networks/docs/Makefile delete mode 100644 packages/core/minos-microservice-networks/docs/_static/style.css delete mode 100644 packages/core/minos-microservice-networks/docs/_templates/layout.html delete mode 100644 packages/core/minos-microservice-networks/docs/authors.md delete mode 100755 packages/core/minos-microservice-networks/docs/conf.py delete mode 100644 packages/core/minos-microservice-networks/docs/history.md delete mode 100644 packages/core/minos-microservice-networks/docs/index.md delete mode 100644 packages/core/minos-microservice-networks/docs/readme.md delete mode 100644 packages/core/minos-microservice-networks/docs/runthetests.md delete mode 100644 packages/core/minos-microservice-saga/docs/Makefile delete mode 100644 packages/core/minos-microservice-saga/docs/_static/style.css delete mode 100644 packages/core/minos-microservice-saga/docs/_templates/layout.html delete mode 100644 packages/core/minos-microservice-saga/docs/authors.md delete mode 100755 packages/core/minos-microservice-saga/docs/conf.py delete mode 100644 packages/core/minos-microservice-saga/docs/history.md delete mode 100644 packages/core/minos-microservice-saga/docs/index.md delete mode 100644 packages/core/minos-microservice-saga/docs/readme.md delete mode 100644 packages/core/minos-microservice-saga/docs/runthetests.md delete mode 100644 packages/plugins/minos-broker-kafka/docs/Makefile delete mode 100644 packages/plugins/minos-broker-kafka/docs/_static/style.css delete mode 100644 packages/plugins/minos-broker-kafka/docs/_templates/layout.html delete mode 100644 packages/plugins/minos-broker-kafka/docs/authors.md delete mode 100755 packages/plugins/minos-broker-kafka/docs/conf.py delete mode 100644 packages/plugins/minos-broker-kafka/docs/history.md delete mode 100644 packages/plugins/minos-broker-kafka/docs/index.md delete mode 100644 packages/plugins/minos-broker-kafka/docs/readme.md delete mode 100644 packages/plugins/minos-broker-kafka/docs/runthetests.md delete mode 100644 packages/plugins/minos-broker-rabbitmq/docs/Makefile delete mode 100644 packages/plugins/minos-broker-rabbitmq/docs/_static/style.css delete mode 100644 packages/plugins/minos-broker-rabbitmq/docs/_templates/layout.html delete mode 100644 packages/plugins/minos-broker-rabbitmq/docs/authors.md delete mode 100755 packages/plugins/minos-broker-rabbitmq/docs/conf.py delete mode 100644 packages/plugins/minos-broker-rabbitmq/docs/history.md delete mode 100644 packages/plugins/minos-broker-rabbitmq/docs/index.md delete mode 100644 packages/plugins/minos-broker-rabbitmq/docs/readme.md delete mode 100644 packages/plugins/minos-broker-rabbitmq/docs/runthetests.md delete mode 100644 packages/plugins/minos-discovery-minos/docs/Makefile delete mode 100644 packages/plugins/minos-discovery-minos/docs/_static/style.css delete mode 100644 packages/plugins/minos-discovery-minos/docs/_templates/layout.html delete mode 100644 packages/plugins/minos-discovery-minos/docs/authors.md delete mode 100755 packages/plugins/minos-discovery-minos/docs/conf.py delete mode 100644 packages/plugins/minos-discovery-minos/docs/history.md delete mode 100644 packages/plugins/minos-discovery-minos/docs/index.md delete mode 100644 packages/plugins/minos-discovery-minos/docs/readme.md delete mode 100644 packages/plugins/minos-discovery-minos/docs/runthetests.md delete mode 100644 packages/plugins/minos-http-aiohttp/docs/Makefile delete mode 100644 packages/plugins/minos-http-aiohttp/docs/_static/style.css delete mode 100644 packages/plugins/minos-http-aiohttp/docs/_templates/layout.html delete mode 100644 packages/plugins/minos-http-aiohttp/docs/authors.md delete mode 100755 packages/plugins/minos-http-aiohttp/docs/conf.py delete mode 100644 packages/plugins/minos-http-aiohttp/docs/history.md delete mode 100644 packages/plugins/minos-http-aiohttp/docs/index.md delete mode 100644 packages/plugins/minos-http-aiohttp/docs/readme.md delete mode 100644 packages/plugins/minos-http-aiohttp/docs/runthetests.md delete mode 100644 packages/plugins/minos-router-graphql/docs/Makefile delete mode 100644 packages/plugins/minos-router-graphql/docs/_static/style.css delete mode 100644 packages/plugins/minos-router-graphql/docs/_templates/layout.html delete mode 100644 packages/plugins/minos-router-graphql/docs/authors.md delete mode 100755 packages/plugins/minos-router-graphql/docs/conf.py delete mode 100644 packages/plugins/minos-router-graphql/docs/history.md delete mode 100644 packages/plugins/minos-router-graphql/docs/index.md delete mode 100644 packages/plugins/minos-router-graphql/docs/readme.md delete mode 100644 packages/plugins/minos-router-graphql/docs/runthetests.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index a582cde96..908ae1bd7 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,18 +1,17 @@ # How to contribute -Minos being an open-source project, we are looking forward to having your contributions. No matter whether it is a pull -request with new features, or the creation of an issue related to a bug you have found. +Minos being an open-source project, we are looking forward to having your contributions. No matter whether it is a pull request with new features, or the creation of an issue related to a bug you have found. Please consider these guidelines before you submit any modification. -Create an issue ----------------- +## Create an issue + 1. If you happen to find a bug, please file a new issue filling the 'Bug report' template. 2. Set the appropriate labels, so we can categorise it easily. 3. Wait for any core developer's feedback on it. -Submit a Pull Request ------------------------ +## Submit a Pull Request + 1. Create an issue following the previous steps. 2. Fork the project. 3. Push your changes to a local branch. diff --git a/docs/index.md b/docs/index.md index 4c94ac363..2247efc62 100644 --- a/docs/index.md +++ b/docs/index.md @@ -29,10 +29,10 @@ Minos is a framework which helps you create [reactive](https://www.reactivemanif minos.cqrs minos.networks minos.saga - minos.plugins.aiohttp minos.plugins.kafka minos.plugins.rabbitmq minos.plugins.minos_discovery + minos.plugins.aiohttp minos.plugins.graphql ## Indices and tables diff --git a/packages/core/minos-microservice-aggregate/CHANGELOG.md b/packages/core/minos-microservice-aggregate/HISTORY.md similarity index 96% rename from packages/core/minos-microservice-aggregate/CHANGELOG.md rename to packages/core/minos-microservice-aggregate/HISTORY.md index be3dd2d75..da6af7328 100644 --- a/packages/core/minos-microservice-aggregate/CHANGELOG.md +++ b/packages/core/minos-microservice-aggregate/HISTORY.md @@ -1,4 +1,4 @@ -# Changelog +# History ## 0.1.0 (2021-11-08) @@ -78,24 +78,21 @@ * Rename `TransactionService` command topics to avoid collisions with application-level topics. * Minor changes. -0.5.3 (2022-03-04) ------------------- +## 0.5.3 (2022-03-04) * Add `RefException` to be raised when some reference cannot be resolved. * Improve attribute and item accessors of `Ref`, `Event` and `FieldDiffContainer` * Deprecate `Event.get_one` in favor of `Event.get_field`. * Deprecate `Event.get_all` in favor of `Event.get_fields`. -0.5.4 (2022-03-07) ------------------- +## 0.5.4 (2022-03-07) * Fix bug related with `Ref.resolve`. * Add `RefResolver.build_topic_name` static method. * Remove `SnapshotService.__get_one__` method. * Minor changes. -0.6.0 (2022-03-28) ------------------- +## 0.6.0 (2022-03-28) * Replace `dependency-injector`'s injection classes by the ones provided by the `minos.common.injections` module. * Be compatible with latest `minos.common.Config` API. \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/Makefile b/packages/core/minos-microservice-aggregate/Makefile index acc861207..ef814b8bc 100644 --- a/packages/core/minos-microservice-aggregate/Makefile +++ b/packages/core/minos-microservice-aggregate/Makefile @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/core/minos-microservice-aggregate/RUNTHETESTS.md b/packages/core/minos-microservice-aggregate/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/core/minos-microservice-aggregate/RUNTHETESTS.md +++ b/packages/core/minos-microservice-aggregate/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/core/minos-microservice-aggregate/SETUP.md b/packages/core/minos-microservice-aggregate/SETUP.md index 8203965c7..e85ca0f64 100644 --- a/packages/core/minos-microservice-aggregate/SETUP.md +++ b/packages/core/minos-microservice-aggregate/SETUP.md @@ -1,5 +1,4 @@ -Set up a development environment -================================= +# Set up a development environment Since we use `poetry` as the default package manager, it must be installed. Please refer to `https://python-poetry.org/docs/#installation`. diff --git a/packages/core/minos-microservice-aggregate/docs/Makefile b/packages/core/minos-microservice-aggregate/docs/Makefile deleted file mode 100644 index c7f03de43..000000000 --- a/packages/core/minos-microservice-aggregate/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -SPHINXPROJ = minos-microservice-aggregate -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/core/minos-microservice-aggregate/docs/_static/style.css b/packages/core/minos-microservice-aggregate/docs/_static/style.css deleted file mode 100644 index 45da50c55..000000000 --- a/packages/core/minos-microservice-aggregate/docs/_static/style.css +++ /dev/null @@ -1,11 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} - -dl[class*="py"] { - display: block !important; -} - -dl[class*="py"] > dt { - display: block !important; -} \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/docs/_templates/layout.html b/packages/core/minos-microservice-aggregate/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/core/minos-microservice-aggregate/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/docs/_templates/package.rst_t b/packages/core/minos-microservice-aggregate/docs/_templates/package.rst_t deleted file mode 100644 index 87efea5e7..000000000 --- a/packages/core/minos-microservice-aggregate/docs/_templates/package.rst_t +++ /dev/null @@ -1,49 +0,0 @@ -{%- macro automodule(modname, options) -%} -.. automodule:: {{ modname }} -{%- for option in options %} - :{{ option }}: -{%- endfor %} -{%- endmacro %} - -{%- macro toctree(docnames) -%} -.. toctree:: - :maxdepth: {{ maxdepth }} -{% for docname in docnames %} - {{ docname }} -{%- endfor %} -{%- endmacro %} - -{%- if is_namespace %} -{{- [pkgname, "namespace"] | join(" ") | e | heading }} -{% else %} -{{- [pkgname, "package"] | join(" ") | e | heading }} -{% endif %} - -{%- if is_namespace %} -.. py:module:: {{ pkgname }} -{% endif %} - -{%- if modulefirst and not is_namespace %} -{{ automodule(pkgname, automodule_options) }} -{% endif %} - -{%- if subpackages %} -{{ toctree(subpackages) }} -{% endif %} - -{%- if submodules %} -{% if separatemodules %} -{{ toctree(submodules) }} -{% else %} -{%- for submodule in submodules %} -{% if show_headings %} -{{- [submodule, "module"] | join(" ") | e | heading(2) }} -{% endif %} -{{ automodule(submodule, automodule_options) }} -{% endfor %} -{%- endif %} -{%- endif %} - -{%- if not modulefirst and not is_namespace %} -{{ automodule(pkgname, automodule_options) }} -{% endif %} \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/docs/authors.md b/packages/core/minos-microservice-aggregate/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/core/minos-microservice-aggregate/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/core/minos-microservice-aggregate/docs/changelog.md b/packages/core/minos-microservice-aggregate/docs/changelog.md deleted file mode 100644 index 6336d7666..000000000 --- a/packages/core/minos-microservice-aggregate/docs/changelog.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../CHANGELOG.md diff --git a/packages/core/minos-microservice-aggregate/docs/conf.py b/packages/core/minos-microservice-aggregate/docs/conf.py deleted file mode 100755 index 4b029151c..000000000 --- a/packages/core/minos-microservice-aggregate/docs/conf.py +++ /dev/null @@ -1,70 +0,0 @@ -import os -import sys -from datetime import ( - datetime, -) - -sys.path.insert(0, os.path.abspath("..")) - -from minos import aggregate as package - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx.ext.viewcode", - "sphinx.ext.intersphinx", - "sphinx.ext.autosummary", - "m2r2", -] -templates_path = ["_templates"] -source_suffix = [".rst", ".md"] - -master_doc = "index" -project = "minos-microservice-aggregate" -copyright = f"2021-{datetime.now().year}, Clariteia" -author = "Minos Framework Devs" - -version = package.__version__ -release = package.__version__ - -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -html_theme = "sphinx_rtd_theme" -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} -html_static_path = ["_static"] - -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_toc_file = False -apidoc_separate_modules = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", - "--templatedir=_templates", -] -autodoc_default_options = { - "members": True, - "undoc-members": True, - "inherited-members": True, - #"special-members": "__init__", - "member-order": "bysource", -} -autoclass_content = "class" -autodoc_class_signature = "separated" -autodoc_member_order = "bysource" -autodoc_typehints_format = "short" -autodoc_typehints = "description" -autodoc_preserve_defaults = True -add_module_names = False -intersphinx_mapping = { - "python": ("https://docs.python.org/3", None), - "minos-microservice-common": ( - "https://minos-framework.github.io/minos-python/packages/core/minos-microservice-common", - ("../../minos-microservice-common/docs/_build/html/objects.inv", None), - ), - "minos-microservice-networks": ( - "https://minos-framework.github.io/minos-python/packages/core/minos-microservice-networks", - ("../../minos-microservice-networks/docs/_build/html/objects.inv", None), - ), - -} diff --git a/packages/core/minos-microservice-aggregate/docs/index.md b/packages/core/minos-microservice-aggregate/docs/index.md deleted file mode 100644 index 8318ac7cf..000000000 --- a/packages/core/minos-microservice-aggregate/docs/index.md +++ /dev/null @@ -1,15 +0,0 @@ -# Welcome to `minos-microservice-aggregate`'s documentation! - -.. toctree:: - :maxdepth: 2 - - readme - reference - runthetests - changelog - authors - -## Indices and tables -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/core/minos-microservice-aggregate/docs/readme.md b/packages/core/minos-microservice-aggregate/docs/readme.md deleted file mode 100644 index 9a7702cfc..000000000 --- a/packages/core/minos-microservice-aggregate/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Readme - -.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-aggregate/docs/reference.md b/packages/core/minos-microservice-aggregate/docs/reference.md deleted file mode 100644 index d92219ccb..000000000 --- a/packages/core/minos-microservice-aggregate/docs/reference.md +++ /dev/null @@ -1,5 +0,0 @@ -# API Reference - -.. toctree:: - - api/minos \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/docs/runthetests.md b/packages/core/minos-microservice-aggregate/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/core/minos-microservice-aggregate/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index f6e04059f..95ec86a09 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -1,3 +1,5 @@ +"""The Aggregate pattern of the Minos Framework.""" + __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.6.0" diff --git a/packages/core/minos-microservice-aggregate/poetry.lock b/packages/core/minos-microservice-aggregate/poetry.lock index e985553b3..a3b389f5d 100644 --- a/packages/core/minos-microservice-aggregate/poetry.lock +++ b/packages/core/minos-microservice-aggregate/poetry.lock @@ -34,14 +34,6 @@ psycopg2-binary = ">=2.8.4" [package.extras] sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "async-timeout" version = "4.0.2" @@ -72,20 +64,9 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +77,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -113,40 +94,13 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[[package]] -name = "charset-normalizer" -version = "2.0.12" -description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "dev" -optional = false -python-versions = ">=3.5.0" - -[package.extras] -unicode_backport = ["unicodedata2"] - [[package]] name = "click" -version = "8.0.4" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -194,7 +148,7 @@ python-versions = "*" [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -209,22 +163,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -239,18 +177,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -264,49 +190,6 @@ mccabe = ">=0.6.0,<0.7.0" pycodestyle = ">=2.8.0,<2.9.0" pyflakes = ">=2.4.0,<2.5.0" -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - -[[package]] -name = "idna" -version = "3.3" -description = "Internationalized Domain Names in Applications (IDNA)" -category = "dev" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -329,20 +212,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "lmdb" version = "1.3.0" @@ -351,26 +220,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -422,14 +271,6 @@ psycopg2-binary = "^2.9.3" type = "directory" url = "../minos-microservice-networks" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "mypy-extensions" version = "0.4.3" @@ -438,14 +279,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -473,14 +306,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -505,22 +330,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -553,14 +362,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -593,14 +394,6 @@ tomli = ">=1.0.0" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2.7.2)", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -609,24 +402,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "six" version = "1.16.0" @@ -635,152 +410,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "toml" -version = "0.10.2" -description = "Python Library for Tom's Obvious, Minimal Language" -category = "dev" -optional = false -python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" - [[package]] name = "tomli" version = "2.0.1" @@ -797,19 +426,6 @@ category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - [[package]] name = "uvloop" version = "0.16.0" @@ -823,40 +439,10 @@ dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0 docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "932671cb0c292ef96dfb260fba1f120bb3f61957e952ef814b943f0b355129da" +content-hash = "1549a02e3f01d64d8b6538473e34bb0cccc3f5acc3ad3fdcfde5032c1109edae" [metadata.files] aiomisc = [ @@ -867,10 +453,6 @@ aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, ] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -883,54 +465,38 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] -charset-normalizer = [ - {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, - {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, -] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -987,50 +553,42 @@ crontab = [ {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, @@ -1050,30 +608,10 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] -idna = [ - {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, - {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, -] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1082,10 +620,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] lmdb = [ {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, @@ -1115,70 +649,16 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] minos-microservice-common = [] minos-microservice-networks = [] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1221,10 +701,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1233,10 +709,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1307,10 +779,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1319,10 +787,6 @@ pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1358,58 +822,10 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] -toml = [ - {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, - {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, -] tomli = [ {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, @@ -1418,10 +834,6 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, @@ -1440,11 +852,3 @@ uvloop = [ {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index 6f65bf75d..55d31e50a 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -44,11 +44,6 @@ isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/packages/core/minos-microservice-common/HISTORY.md b/packages/core/minos-microservice-common/HISTORY.md index d549e8617..b18c30b35 100644 --- a/packages/core/minos-microservice-common/HISTORY.md +++ b/packages/core/minos-microservice-common/HISTORY.md @@ -1,79 +1,55 @@ -History -========== +# History -0.0.1.1-alpha (2021-03-28) --------------------------------- +## 0.0.1.1-alpha (2021-03-28) -0.0.1.2-alpha (2021-03-31) ------------------------------ +## 0.0.1.2-alpha (2021-03-31) -0.0.1.3-alpha (2021-03-31) ----------------------------- +## 0.0.1.3-alpha (2021-03-31) -0.0.1.4-alpha (2021-04-02) ------------------------------- +## 0.0.1.4-alpha (2021-04-02) -0.0.1.5-alpha (2021-04-02) ----------------------------- +## 0.0.1.5-alpha (2021-04-02) -0.0.1.6 (2021-04-03) ---------------------- +## 0.0.1.6 (2021-04-03) -0.0.1.7 (2021-04-06) ----------------------- +## 0.0.1.7 (2021-04-06) -0.0.2 (2021-04-19) -------------------- +## 0.0.2 (2021-04-19) -0.0.3 (2021-04-26) --------------------- +## 0.0.3 (2021-04-26) -0.0.4 (2021-04-28) --------------------- +## 0.0.4 (2021-04-28) -0.0.5 (2021-05-03) --------------------- +## 0.0.5 (2021-05-03) -0.0.6 (2021-05-04) --------------------- +## 0.0.6 (2021-05-04) -0.0.7 (2021-05-06) --------------------- +## 0.0.7 (2021-05-06) -0.0.8 (2021-05-07) --------------------- +## 0.0.8 (2021-05-07) -0.0.9 (2021-05-10) -------------------- +## 0.0.9 (2021-05-10) -0.0.10 (2021-05-11) ---------------------- +## 0.0.10 (2021-05-11) -0.0.11 (2021-05-12) ---------------------- +## 0.0.11 (2021-05-12) -0.0.12 (2021-05-17) ---------------------- +## 0.0.12 (2021-05-17) -0.0.13 (2021-05-18) ---------------------- +## 0.0.13 (2021-05-18) -0.0.14 (2021-05-20) --------------------- +## 0.0.14 (2021-05-20) -0.0.15 (2021-05-26) --------------------- +## 0.0.15 (2021-05-26) * Some code refactoring * Test cases coverage optimization * fixed some Sagas functionalities * fixed Sphinx documentation generation process -0.0.16 (2021-05-28) --------------------- +## 0.0.16 (2021-05-28) -0.0.17 (2021-06-02) --------------------- +## 0.0.17 (2021-06-02) * Documentation improvements * Removed DependencyInjector, conflict with minos.microservice package @@ -81,21 +57,18 @@ History * Added abstract classes Response and Request for Microservice Controller * Bugfix -0.1.0 (2021-06-18) --------------------- +## 0.1.0 (2021-06-18) * Enrich exception messages * Classes refactors * Added support for DTO Model class -0.1.1 (2021-07-01) --------------------- +## 0.1.1 (2021-07-01) * Resolved float problem with avro * Bugfixes -0.1.2 (2021-07-06) --------------------- +## 0.1.2 (2021-07-06) * Added Exceptions Traitment * Bugfixes @@ -103,8 +76,7 @@ History * Improved queries for Aggregate ( per id query ) * Added methods for Snapshot ( added check for duplicates ) -0.1.3 (2021-07-12) --------------------- +## 0.1.3 (2021-07-12) * AggregateRef Model * ValueObjects Model @@ -112,37 +84,31 @@ History * Removed ID to UUID for models * Events use AggregateDIff -0.1.4 (2021-07-19) --------------------- +## 0.1.4 (2021-07-19) * Bugfixes -0.1.5 (2021-07-19) --------------------- +## 0.1.5 (2021-07-19) * Bugfixes -0.1.6 (2021-07-21) --------------------- +## 0.1.6 (2021-07-21) * Bugfixes * Added Pool for Kafka -0.1.7 (2021-07-27) --------------------- +## 0.1.7 (2021-07-27) * Simplify configuration file * Bugfixes -0.1.8 (2021-08-03) --------------------- +## 0.1.8 (2021-08-03) * Connection Pool improvement for async * Small inmprovements * Bugfixes -0.1.9 (2021-08-17) --------------------- +## 0.1.9 (2021-08-17) * Add `minos.common.Entity`. * Refactor `minos.common.AggregateDiff.fields_diff`: @@ -152,22 +118,19 @@ History * Add support for `typing.Generic` and `typing.TypeVar`. * Bugfixes -0.1.10 (2021-08-23) --------------------- +## 0.1.10 (2021-08-23) * Add `created_at` and `updated_at` to `Aggregate`. * Improve Fix `AggregateDiff` + `FieldDiffContainer` API. * Fix `Aggregate` bug that stored empty field differences instead of skipping them. * Fix bug from `Model` related with `getitem`, `setitem`, `getattr` and `setattr`. -0.1.11 (2021-08-25) --------------------- +## 0.1.11 (2021-08-25) * Fix bug related with `datetime` serialization in `Field`. * Fix bug related with the `AggregateDiff.__getattr__` implementation. -0.1.12 (2021-09-01) --------------------- +## 0.1.12 (2021-09-01) * Add generics to `MinosSagaManager` interface. * Remove `saga.items` from `MinosConfig`. @@ -176,8 +139,7 @@ History * Fix bug related with `TypeHintBuilder` and `Any`. * Fix bug related with `ModelType` comparisons. -0.1.13 (2021-09-16) --------------------- +## 0.1.13 (2021-09-16) * Add `discovery.client` into `MinosConfig` allowing to setup custom Discovery clients. * Add `minos.common.queries` module, containing `Condition` and `Ordering` classes. @@ -187,37 +149,32 @@ History * Remove file headers. * Stop using `NoReturn` everywhere. -0.1.14 (2021-09-27) --------------------- +## 0.1.14 (2021-09-27) * Add support for `timedelta`. * Fix `Optional[ModelRef[T]]` behaviour. * Remove `events` section from `MinosConfig`. * Fix troubles related with dependency injections. -0.1.15 (2021-10-04) --------------------- +## 0.1.15 (2021-10-04) * Fix bug from `PostgreSqlSnapshotReader` that returned already deleted aggregates when `Condition.TRUE` was passed. -0.1.16 (2021-10-07) --------------------- +## 0.1.16 (2021-10-07) * Improve support for `Model` inheritance inside container classes (`list`, `dict`, `EntitySet`, etc.). * Add support for `set[T]` type. * Fix bug related with complex types and `PostgreSqlSnapshotQueryBuilder`. * Fix bug related with empty `dict` and `minos.saga.SagaContext`. -0.1.17 (2021-10-08) --------------------- +## 0.1.17 (2021-10-08) * Add `IncrementalSet` as the base implementation for incremental sets. * Now `ValueObjectSet` and `EntitySet` inherit from `IncrementalSet`. * Refactor `ValueObjectSet` to be implemented on top of a `set` instead of a `dict`. * Fix bug related with `list`, `set` and `dict` in combination with `Any` and the `avro` schemas. -0.2.0 (2021-11-08) --------------------- +## 0.2.0 (2021-11-08) * Migrate all Aggregate-related stuff to the brand-new `minos.aggregate` package. * Move `Aggregate`, `Entity`, `ValueObject`, etc. model classes and related utility classes (`AggregateDiff`, `FieldDiff`, Action`, `ModelRef`, etc.). @@ -228,73 +185,61 @@ History * Add `PostgreSqlLock` and `PostgreSqlLockPool` * Replace the `MinosPool` instance creation strategy, from "create if possible or get or wait" to "get or create if possible or wait". -0.2.1 (2021-11-09) --------------------- +## 0.2.1 (2021-11-09) * Fix bug related with dependency injections over `minos.*` modules. -0.3.0 (2021-11-15) --------------------- +## 0.3.0 (2021-11-15) * Add `services` and `middleware` sections to `MinosConfig`. * Remove `Command`, `CommandReply`, `CommandStatus` and `Event` (moved to `minos.networks`). * Remove `MinosBroker` and `MinosHandler` (moved to `minos.networks`). * Remove `MinosSagaManager` (moved to `minos.saga`). -0.3.1 (2021-11-24) --------------------- +## 0.3.1 (2021-11-24) * Fix bug related with `enum.Enum` inherited classes that do not recover the original type after being serialized. * Fix bug related with`str` values auto-casting to an iterable of characters. -0.3.2 (2021-11-30) --------------------- +## 0.3.2 (2021-11-30) * Fix bug related with `EntrypointLauncher`'s dependency injection and unloaded `minos.*` modules. -0.3.3 (2022-01-10) --------------------- +## 0.3.3 (2022-01-10) * Big refactor of the `minos.common.model.serializers` module: * Add `encode_schema`, `decode_schema`, `encode_data` and `decode_data` callback-like functions to be able to modify the serialization/deserialization logic. * Add `SchemaEncoder`, `SchemaDecoder`, `DataEncoder` and `DataDecoder` abstract base classes. * Increase serialization/deserialization robustness. -0.3.4 (2022-01-11) --------------------- +## 0.3.4 (2022-01-11) * Add `batch_mode: bool` argument to manage if the `avro` serialization is performed for a single model or a batch of models. -0.4.0 (2022-01-27) ------------------- +## 0.4.0 (2022-01-27) * Add waiting time before destroying the `minos.common.MinosPool` acquired instances. -0.4.1 (2022-01-31) ------------------- +## 0.4.1 (2022-01-31) * Update `README.md`. -0.5.0 (2022-02-03) ------------------- +## 0.5.0 (2022-02-03) * Minor changes. -0.5.2 (2022-02-08) ------------------- +## 0.5.2 (2022-02-08) * Add `query_repository` section to `MinosConfig`. * Minor changes. -0.5.3 (2022-03-04) ------------------- +## 0.5.3 (2022-03-04) * Big performance improvement related with a caching layer over type hint comparisons at `TypeHintComparator`. * Improve attribute and item accessors of `Model`. * Fix bug related with casting from `dict` to `Model` instances on field setters. -0.6.0 (2022-03-28) ------------------- +## 0.6.0 (2022-03-28) * Add `Config` with support for config versioning. * Add `ConfigV1` as the class that supports the V1 config file. diff --git a/packages/core/minos-microservice-common/Makefile b/packages/core/minos-microservice-common/Makefile index acc861207..ef814b8bc 100644 --- a/packages/core/minos-microservice-common/Makefile +++ b/packages/core/minos-microservice-common/Makefile @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/core/minos-microservice-common/RUNTHETESTS.md b/packages/core/minos-microservice-common/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/core/minos-microservice-common/RUNTHETESTS.md +++ b/packages/core/minos-microservice-common/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/core/minos-microservice-common/SETUP.md b/packages/core/minos-microservice-common/SETUP.md index 8203965c7..e85ca0f64 100644 --- a/packages/core/minos-microservice-common/SETUP.md +++ b/packages/core/minos-microservice-common/SETUP.md @@ -1,5 +1,4 @@ -Set up a development environment -================================= +# Set up a development environment Since we use `poetry` as the default package manager, it must be installed. Please refer to `https://python-poetry.org/docs/#installation`. diff --git a/packages/core/minos-microservice-common/docs/Makefile b/packages/core/minos-microservice-common/docs/Makefile deleted file mode 100644 index f0f022757..000000000 --- a/packages/core/minos-microservice-common/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -SPHINXPROJ = minos-microservice-common -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/core/minos-microservice-common/docs/_static/style.css b/packages/core/minos-microservice-common/docs/_static/style.css deleted file mode 100644 index 8aa6c288f..000000000 --- a/packages/core/minos-microservice-common/docs/_static/style.css +++ /dev/null @@ -1,3 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} diff --git a/packages/core/minos-microservice-common/docs/_templates/layout.html b/packages/core/minos-microservice-common/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/core/minos-microservice-common/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/core/minos-microservice-common/docs/authors.md b/packages/core/minos-microservice-common/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/core/minos-microservice-common/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/core/minos-microservice-common/docs/conf.py b/packages/core/minos-microservice-common/docs/conf.py deleted file mode 100755 index fc7935987..000000000 --- a/packages/core/minos-microservice-common/docs/conf.py +++ /dev/null @@ -1,198 +0,0 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# -import os -import sys - -sys.path.insert(0, os.path.abspath("..")) - -import sphinx_rtd_theme - -from minos import ( - common, -) - -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", - "sphinx.ext.viewcode", - "sphinx_rtd_theme", - "m2r2", -] -# Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# -source_suffix = [".rst", ".md"] - -# The master toctree document. -master_doc = "index" - -# General information about the project. -project = "Minos Microservice Common" -copyright = "2021, Clariteia" -author = "Minos Framework Devs" - -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. -version = common.__version__ -# The full version, including alpha/beta/rc tags. -release = common.__version__ - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = "sphinx" - -# If true, `todo` and `todoList` produce output, else they produce nothing. -todo_include_todos = False - - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - -html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "minos_microservice_common", -# "github_type": "star", -# } - -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ["_static"] - - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. -htmlhelp_basename = "minosdoc" - - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Microservice Common Documentation", "Minos Framework Devs", "manual"), -] - - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Microservice Common Documentation", [author], 1)] - - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Microservice Common Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False -apidoc_module_first = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", -] -apidoc_excluded_paths = ["../minos/common/testing.py"] -# "autodoc typehints" extension - -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/core/minos-microservice-common/docs/history.md b/packages/core/minos-microservice-common/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/core/minos-microservice-common/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/core/minos-microservice-common/docs/index.md b/packages/core/minos-microservice-common/docs/index.md deleted file mode 100644 index 92681672b..000000000 --- a/packages/core/minos-microservice-common/docs/index.md +++ /dev/null @@ -1,16 +0,0 @@ -# Welcome to Minos Microservice Common's documentation! - -.. toctree:: - :maxdepth: 1 - - readme - runthetests - api/minos - authors - history - -## Indices and tables - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/core/minos-microservice-common/docs/readme.md b/packages/core/minos-microservice-common/docs/readme.md deleted file mode 100644 index 9a7702cfc..000000000 --- a/packages/core/minos-microservice-common/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Readme - -.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-common/docs/runthetests.md b/packages/core/minos-microservice-common/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/core/minos-microservice-common/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 853fce3f1..e8235064c 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -1,3 +1,4 @@ +"""The common core of the Minos Framework.""" __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.6.0" diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index 62682cf99..0eb899eac 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -34,14 +34,6 @@ psycopg2-binary = ">=2.8.4" [package.extras] sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "async-timeout" version = "4.0.2" @@ -72,20 +64,9 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +77,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -113,40 +94,13 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[[package]] -name = "charset-normalizer" -version = "2.0.12" -description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "dev" -optional = false -python-versions = ">=3.5.0" - -[package.extras] -unicode_backport = ["unicodedata2"] - [[package]] name = "click" -version = "8.0.4" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -186,7 +140,7 @@ toml = ["tomli"] [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -201,22 +155,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -231,18 +169,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -256,49 +182,6 @@ mccabe = ">=0.6.0,<0.7.0" pycodestyle = ">=2.8.0,<2.9.0" pyflakes = ">=2.4.0,<2.5.0" -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - -[[package]] -name = "idna" -version = "3.3" -description = "Internationalized Domain Names in Applications (IDNA)" -category = "dev" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -321,20 +204,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "lmdb" version = "1.3.0" @@ -343,26 +212,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -371,14 +220,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "mypy-extensions" version = "0.4.3" @@ -387,14 +228,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -422,14 +255,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -454,22 +279,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -502,14 +311,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -542,14 +343,6 @@ tomli = ">=1.0.0" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2.7.2)", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -558,24 +351,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "six" version = "1.16.0" @@ -584,167 +359,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "toml" -version = "0.10.2" -description = "Python Library for Tom's Obvious, Minimal Language" -category = "dev" -optional = false -python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" - [[package]] name = "tomli" version = "2.0.1" @@ -761,19 +375,6 @@ category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - [[package]] name = "uvloop" version = "0.16.0" @@ -787,40 +388,10 @@ dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0 docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "fbf86feb57cef7a80f0568f8da50f945ebeb84d401d32fa5a3bde0bac05febda" +content-hash = "594cd8dc9f403bfe2dfb1541d233602ab7778702e566e0ff7d50db68e3d387d6" [metadata.files] aiomisc = [ @@ -831,10 +402,6 @@ aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, ] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -847,54 +414,38 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] -charset-normalizer = [ - {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, - {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, -] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -948,50 +499,42 @@ coverage = [ {file = "coverage-6.3.2.tar.gz", hash = "sha256:03e2a7826086b91ef345ff18742ee9fc47a6839ccd517061ef8fa1976e652ce9"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, @@ -1011,30 +554,10 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] -idna = [ - {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, - {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, -] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1043,10 +566,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] lmdb = [ {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, @@ -1076,68 +595,14 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1180,10 +645,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1192,10 +653,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1266,10 +723,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1278,10 +731,6 @@ pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1317,62 +766,10 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] -toml = [ - {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, - {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, -] tomli = [ {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, @@ -1381,10 +778,6 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, @@ -1403,11 +796,3 @@ uvloop = [ {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index 22b569afe..46d6d4994 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -47,12 +47,6 @@ isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.17.0" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/packages/core/minos-microservice-cqrs/Makefile b/packages/core/minos-microservice-cqrs/Makefile index acc861207..ef814b8bc 100644 --- a/packages/core/minos-microservice-cqrs/Makefile +++ b/packages/core/minos-microservice-cqrs/Makefile @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/core/minos-microservice-cqrs/RUNTHETESTS.md b/packages/core/minos-microservice-cqrs/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/core/minos-microservice-cqrs/RUNTHETESTS.md +++ b/packages/core/minos-microservice-cqrs/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/core/minos-microservice-cqrs/SETUP.md b/packages/core/minos-microservice-cqrs/SETUP.md index 8203965c7..e85ca0f64 100644 --- a/packages/core/minos-microservice-cqrs/SETUP.md +++ b/packages/core/minos-microservice-cqrs/SETUP.md @@ -1,5 +1,4 @@ -Set up a development environment -================================= +# Set up a development environment Since we use `poetry` as the default package manager, it must be installed. Please refer to `https://python-poetry.org/docs/#installation`. diff --git a/packages/core/minos-microservice-cqrs/docs/Makefile b/packages/core/minos-microservice-cqrs/docs/Makefile deleted file mode 100644 index 6a53257fb..000000000 --- a/packages/core/minos-microservice-cqrs/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -SPHINXPROJ = minos-microservice-cqrs -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/core/minos-microservice-cqrs/docs/_static/style.css b/packages/core/minos-microservice-cqrs/docs/_static/style.css deleted file mode 100644 index 8aa6c288f..000000000 --- a/packages/core/minos-microservice-cqrs/docs/_static/style.css +++ /dev/null @@ -1,3 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} diff --git a/packages/core/minos-microservice-cqrs/docs/_templates/layout.html b/packages/core/minos-microservice-cqrs/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/core/minos-microservice-cqrs/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/core/minos-microservice-cqrs/docs/authors.md b/packages/core/minos-microservice-cqrs/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/core/minos-microservice-cqrs/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/core/minos-microservice-cqrs/docs/conf.py b/packages/core/minos-microservice-cqrs/docs/conf.py deleted file mode 100755 index 2a67a8be1..000000000 --- a/packages/core/minos-microservice-cqrs/docs/conf.py +++ /dev/null @@ -1,197 +0,0 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# -import os -import sys - -sys.path.insert(0, os.path.abspath("..")) - -import sphinx_rtd_theme - -from minos import ( - cqrs, -) - -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", - "sphinx.ext.viewcode", - "sphinx_rtd_theme", - "m2r2", -] -# Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# -source_suffix = [".rst", ".md"] - -# The master toctree document. -master_doc = "index" - -# General information about the project. -project = "Minos Microservice CQRS" -copyright = "2021, Clariteia" -author = "Minos Framework Devs" - -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. -version = cqrs.__version__ -# The full version, including alpha/beta/rc tags. -release = cqrs.__version__ - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = "sphinx" - -# If true, `todo` and `todoList` produce output, else they produce nothing. -todo_include_todos = False - - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - -html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "cqrs", -# "github_type": "star", -# } - -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ["_static"] - - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. -htmlhelp_basename = "minosdoc" - - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Microservice CQRS Documentation", "Minos Framework Devs", "manual"), -] - - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Microservice CQRS Documentation", [author], 1)] - - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Microservice CQRS Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False -apidoc_module_first = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", -] -# "autodoc typehints" extension - -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/core/minos-microservice-cqrs/docs/history.md b/packages/core/minos-microservice-cqrs/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/core/minos-microservice-cqrs/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/core/minos-microservice-cqrs/docs/index.md b/packages/core/minos-microservice-cqrs/docs/index.md deleted file mode 100644 index f7a299cc4..000000000 --- a/packages/core/minos-microservice-cqrs/docs/index.md +++ /dev/null @@ -1,16 +0,0 @@ -# Welcome to Minos Microservice CQRS's documentation! - -.. toctree:: - :maxdepth: 1 - - readme - runthetests - api/minos - authors - history - -## Indices and tables - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/core/minos-microservice-cqrs/docs/readme.md b/packages/core/minos-microservice-cqrs/docs/readme.md deleted file mode 100644 index 9a7702cfc..000000000 --- a/packages/core/minos-microservice-cqrs/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Readme - -.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-cqrs/docs/runthetests.md b/packages/core/minos-microservice-cqrs/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/core/minos-microservice-cqrs/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py b/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py index e45462e8d..68dd15f80 100644 --- a/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py +++ b/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py @@ -1,3 +1,5 @@ +"""The CQRS pattern of the Minos Framework.""" + __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.6.0" diff --git a/packages/core/minos-microservice-cqrs/poetry.lock b/packages/core/minos-microservice-cqrs/poetry.lock index 270a6d262..9d24c1964 100644 --- a/packages/core/minos-microservice-cqrs/poetry.lock +++ b/packages/core/minos-microservice-cqrs/poetry.lock @@ -34,14 +34,6 @@ psycopg2-binary = ">=2.8.4" [package.extras] sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "async-timeout" version = "4.0.2" @@ -72,20 +64,9 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +77,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -113,40 +94,13 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[[package]] -name = "charset-normalizer" -version = "2.0.12" -description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "dev" -optional = false -python-versions = ">=3.5.0" - -[package.extras] -unicode_backport = ["unicodedata2"] - [[package]] name = "click" -version = "8.0.4" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -194,7 +148,7 @@ python-versions = "*" [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -209,22 +163,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -239,18 +177,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -264,49 +190,6 @@ mccabe = ">=0.6.0,<0.7.0" pycodestyle = ">=2.8.0,<2.9.0" pyflakes = ">=2.4.0,<2.5.0" -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - -[[package]] -name = "idna" -version = "3.3" -description = "Internationalized Domain Names in Applications (IDNA)" -category = "dev" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -329,20 +212,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "lmdb" version = "1.3.0" @@ -351,26 +220,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -441,14 +290,6 @@ psycopg2-binary = "^2.9.3" type = "directory" url = "../minos-microservice-networks" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "mypy-extensions" version = "0.4.3" @@ -457,14 +298,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -492,14 +325,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -524,22 +349,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -572,14 +381,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -612,14 +413,6 @@ tomli = ">=1.0.0" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2.7.2)", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -628,24 +421,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "six" version = "1.16.0" @@ -654,167 +429,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "toml" -version = "0.10.2" -description = "Python Library for Tom's Obvious, Minimal Language" -category = "dev" -optional = false -python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" - [[package]] name = "tomli" version = "2.0.1" @@ -831,19 +445,6 @@ category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - [[package]] name = "uvloop" version = "0.16.0" @@ -857,40 +458,10 @@ dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0 docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "23501a6766a4dd4ee55a8b51c4860646b8408e31948d63ad9517a99f1b6d4894" +content-hash = "e712ea027a58309ae2ac0b989b635899c64a392df531ff10d2efdf6a0eaa1d88" [metadata.files] aiomisc = [ @@ -901,10 +472,6 @@ aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, ] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -917,54 +484,38 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] -charset-normalizer = [ - {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, - {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, -] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1021,50 +572,42 @@ crontab = [ {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, @@ -1084,30 +627,10 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] -idna = [ - {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, - {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, -] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1116,10 +639,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] lmdb = [ {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, @@ -1149,52 +668,6 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -1202,18 +675,10 @@ mccabe = [ minos-microservice-aggregate = [] minos-microservice-common = [] minos-microservice-networks = [] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1256,10 +721,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1268,10 +729,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1342,10 +799,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1354,10 +807,6 @@ pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1393,62 +842,10 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] -toml = [ - {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, - {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, -] tomli = [ {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, @@ -1457,10 +854,6 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, @@ -1479,11 +872,3 @@ uvloop = [ {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index 29c04e203..72d9ca115 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -44,12 +44,6 @@ isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.17.0" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/packages/core/minos-microservice-networks/HISTORY.md b/packages/core/minos-microservice-networks/HISTORY.md index a27f6ed93..f422e8cb8 100644 --- a/packages/core/minos-microservice-networks/HISTORY.md +++ b/packages/core/minos-microservice-networks/HISTORY.md @@ -1,32 +1,26 @@ -History -========== +# History -0.0.3 (2021-05-24) ------------------- +## 0.0.3 (2021-05-24) * renamed classes and removed Minos prefix * Integration of Command and CommandReply with Handler -0.0.4 (2021-05-31) ------------------- +## 0.0.4 (2021-05-31) * Documentation improvement * BugFixes -0.0.5 (2021-05-31) ------------------- +## 0.0.5 (2021-05-31) * BugFixes -0.0.6 (2021-06-02) ------------------- +## 0.0.6 (2021-06-02) * Added Retry functionality at Broker * Added Locked status at Broker * Bugfix -0.0.7 (2021-07-06) ------------------- +## 0.0.7 (2021-07-06) * Added basic approach for Circuit Braker ( Broker and Publisher) * SQL queries refactor ( added support for psycopg method for query building ) @@ -36,48 +30,41 @@ History * Added clients for Minos Discovery Service * Added support for Docker and Docker-Compose -0.0.8 (2021-07-12) ------------------- +## 0.0.8 (2021-07-12) * Add new version support for minos-common * BugFix -0.0.9 (2021-07-12) ------------------- +## 0.0.9 (2021-07-12) * BugFix -0.0.10 (2021-07-26) ------------------- +## 0.0.10 (2021-07-26) * Add `enroute` decorator. * Add `ReplyHandlerPool`. * Fix bug related with `DiscoveryConnector`. * Add `WrappedRequest`. -0.0.11 (2021-07-27) ------------------- +## 0.0.11 (2021-07-27) * Be compatible with `minos-microservice-common==0.1.7`. * Fix bug related with `EventConsumerService`, `CommandConsumerService` and `CommandReplyConsumerService` and the `start` method. * Fix bug related with `get_host_ip` function and some DNS systems. -0.0.12 (2021-08-03) ------------------- +## 0.0.12 (2021-08-03) * Small Improvements * Bugfixes -0.0.13 (2021-08-19) ------------------- +## 0.0.13 (2021-08-19) * Update `DiscoveryConnector` to support auto discoverable endpoint. * Increase the concurrency degree of `Handler.dispatch`. * Rename `RestBuilder` as `RestHandler`. * Refactor `HandlerEntry` -0.0.14 (2021-09-01) ------------------- +## 0.0.14 (2021-09-01) * Unify consumer queues into a single one `consumer_queue`. * Replace periodic checking (active waiting) by a `LISTEN/NOTIFY` approach (reactive) on consumer and producer queue. @@ -86,49 +73,41 @@ History * Improve `Producer` performance keeping kafka connection open between publishing calls. * Implement direct message transferring between `Producer` and `Consumer` for messages send to the same microservice. -0.0.15 (2021-09-02) ------------------- +## 0.0.15 (2021-09-02) * Add support for `__get_enroute__` method by `EnrouteAnalyzer`. -0.0.16 (2021-09-20) ------------------- +## 0.0.16 (2021-09-20) * Add support for `Kong` discovery. * Add support for `minos-microservice-common>=0.1.13`. * Fix bug related with database queues and plain dates (without timezones). -0.0.17 (2021-09-27) ------------------- +## 0.0.17 (2021-09-27) * Add support for multiple handling functions for events. * Fix troubles related with dependency injections. -0.0.18 (2021-10-04) ------------------- +## 0.0.18 (2021-10-04) * Add `PeriodicTask`, `PeriodicTaskScheduler` and `PeriodicTaskSchedulerService`. * Add `@enroute.periodic.event` decorator -0.0.19 (2021-11-03) ------------------- +## 0.0.19 (2021-11-03) * Add `"user"` context variable to be accessible during `Request` handling (same as `Request.user`). * Add support for `Request.user` propagation over `CommandBroker`. -0.1.0 (2021-11-08) ------------------- +## 0.1.0 (2021-11-08) * Add `minos-microservice-common>=0.2.0` compatibility. -0.1.1 (2021-11-09) ------------------- +## 0.1.1 (2021-11-09) * Add `REPLY_TOPIC_CONTEXT_VAR` and integrate with `DynamicHandlerPool`. * Add support for `post_fn` callbacks following the same strategy as in `pre_fn` callbacks. -0.2.0 (2021-11-15) ------------------- +## 0.2.0 (2021-11-15) * Remove dependency to `minos-microservice-aggregate` (now `minos.aggregate` package will require `minos.networks`). * Add support for middleware functions. @@ -136,8 +115,7 @@ History * Migrate `Command`, `CommandReply`, `CommandStatus` and `Event` from `minos.common` to `minos.networks`. * Add support for `minos-microservice-common=^0.3.0` -0.3.0 (2021-11-22) ------------------- +## 0.3.0 (2021-11-22) * Improve `BrokerHandler` dispatching strategy to be more concurrent (using `asyncio.PriorityQueue` and multiple consumers). * Add `send(...)` method to `DynamicBroker` in order to simplify the execution of request-response messages. @@ -152,8 +130,7 @@ History * Rename `Producer` and `ProducerService` as `BrokerProducer` and `BrokerProducerService` respectively. * Rename `HandlerRequest`, `HandlerResponse` and `HandlerResponseException` as `BrokerRequest`, `BrokerResponse` and `BrokerResponseException` respectively. -0.3.1 (2021-11-30) ------------------- +## 0.3.1 (2021-11-30) * Add `identifier: UUID` and `headers: dict[str, str]` attributes to `BrokerMessage`. * Remove `saga: Optional[UUID]` and `service_name: str` attributes from `BrokerMessage`. @@ -161,8 +138,7 @@ History * Add `REQUEST_HEADERS_CONTEXT_VAR`. * Rename `USER_CONTEXT_VAR` and `REPLY_TOPIC_CONTEXT_VAR` as `REQUEST_USER_CONTEXT_VAR` and `REQUEST_REPLY_TOPIC_CONTEXT_VAR` respectively. -0.3.2 (2021-12-27) ------------------- +## 0.3.2 (2021-12-27) * Add `CheckDecorator` (accessible from `EnrouteDecorator.check(...): CheckDecorator` attribute) allowing to set check functions with the `(request: Request) -> bool` prototype to the service handling functions. * Add support for more `Content-Type` values. Currently: `application/json`, `application/x-www-form-encoded`, `avro/binary`, `text/plain` and `application/octet-stream`. @@ -171,8 +147,7 @@ History * Add `Request.has_content: bool` and `Request.has_params: bool` to check for the existence of `content` and `params` respectively. * Add `InMemoryRequest` class that allows to create requests for testing or calling service handling functions directly. -0.4.0 (2022-01-27) ------------------- +## 0.4.0 (2022-01-27) * Add `BrokerDispatcher` to break the direct relationship between `BrokerHandler` and `BrokerPublisher`. * Add `content_type` argument to `RestResponse`'s constructor to be able to retrieve the result in a format other than `json`. @@ -192,37 +167,31 @@ History * Implement a builder pattern on `BrokerPublisher` * Be compatible with `minos-microservice-common~=0.4.0`. -0.4.1 (2022-01-31) ------------------- +## 0.4.1 (2022-01-31) * Update `README.md`. -0.5.0 (2022-02-03) ------------------- +## 0.5.0 (2022-02-03) * Extract `kafka` related code to the `minos-broker-kafka` plugin. * Extract `minos-discovery` related code to the `minos-discovery-minos` plugin. * Minor changes. -0.5.1 (2022-02-03) ------------------- +## 0.5.1 (2022-02-03) * Fix bug related with dependency specification. -0.5.2 (2022-02-08) ------------------- +## 0.5.2 (2022-02-08) * Fix bug related with enroute decorator collisions in which the `MinosRedefinedEnrouteDecoratorException` was not raised. * Minor changes. -0.5.3 (2022-03-04) ------------------- +## 0.5.3 (2022-03-04) * Improve error messages of `BrokerDispatcher`, `RestHandler` and `PeriodicTask`. -0.6.0 (2022-03-28) ------------------- +## 0.6.0 (2022-03-28) * Add `BrokerPort` class and deprecate `BrokerHandlerService`. * Add `BrokerPublisherBuilder` to ease the building of `BrokerPublisher` instances. diff --git a/packages/core/minos-microservice-networks/Makefile b/packages/core/minos-microservice-networks/Makefile index acc861207..ef814b8bc 100644 --- a/packages/core/minos-microservice-networks/Makefile +++ b/packages/core/minos-microservice-networks/Makefile @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/core/minos-microservice-networks/RUNTHETESTS.md b/packages/core/minos-microservice-networks/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/core/minos-microservice-networks/RUNTHETESTS.md +++ b/packages/core/minos-microservice-networks/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/core/minos-microservice-networks/SETUP.md b/packages/core/minos-microservice-networks/SETUP.md index 8203965c7..e85ca0f64 100644 --- a/packages/core/minos-microservice-networks/SETUP.md +++ b/packages/core/minos-microservice-networks/SETUP.md @@ -1,5 +1,4 @@ -Set up a development environment -================================= +# Set up a development environment Since we use `poetry` as the default package manager, it must be installed. Please refer to `https://python-poetry.org/docs/#installation`. diff --git a/packages/core/minos-microservice-networks/docs/Makefile b/packages/core/minos-microservice-networks/docs/Makefile deleted file mode 100644 index befe47ad8..000000000 --- a/packages/core/minos-microservice-networks/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -SPHINXPROJ = minos-microservice-networks -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/core/minos-microservice-networks/docs/_static/style.css b/packages/core/minos-microservice-networks/docs/_static/style.css deleted file mode 100644 index 8aa6c288f..000000000 --- a/packages/core/minos-microservice-networks/docs/_static/style.css +++ /dev/null @@ -1,3 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} diff --git a/packages/core/minos-microservice-networks/docs/_templates/layout.html b/packages/core/minos-microservice-networks/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/core/minos-microservice-networks/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/core/minos-microservice-networks/docs/authors.md b/packages/core/minos-microservice-networks/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/core/minos-microservice-networks/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/core/minos-microservice-networks/docs/conf.py b/packages/core/minos-microservice-networks/docs/conf.py deleted file mode 100755 index f5b306567..000000000 --- a/packages/core/minos-microservice-networks/docs/conf.py +++ /dev/null @@ -1,198 +0,0 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# -import os -import sys - -sys.path.insert(0, os.path.abspath("..")) - -import sphinx_rtd_theme - -from minos import ( - networks, -) - -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", - "sphinx.ext.viewcode", - "sphinx_rtd_theme", - "m2r2", -] -# Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# -source_suffix = [".rst", ".md"] -# source_suffix = '.rst' - -# The master toctree document. -master_doc = "index" - -# General information about the project. -project = "Minos Microservice Network" -copyright = "2021, Clariteia" -author = "Minos Framework Devs" - -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. -version = networks.__version__ -# The full version, including alpha/beta/rc tags. -release = networks.__version__ - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = "sphinx" - -# If true, `todo` and `todoList` produce output, else they produce nothing. -todo_include_todos = False - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - -html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "minos_microservice_network", -# "github_type": "star", -# } - -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ["_static"] - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. -htmlhelp_basename = "minosdoc" - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Microservice Network Documentation", "Minos Framework Devs", "manual"), -] - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Microservice Network Documentation", [author], 1)] - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Microservice Network Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False -apidoc_module_first = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", -] - -# apidoc_excluded_paths = [ -# '../minos/network/testing.py' -# ] - -# "autodoc typehints" extension - -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/core/minos-microservice-networks/docs/history.md b/packages/core/minos-microservice-networks/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/core/minos-microservice-networks/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/core/minos-microservice-networks/docs/index.md b/packages/core/minos-microservice-networks/docs/index.md deleted file mode 100644 index 3dd9c300e..000000000 --- a/packages/core/minos-microservice-networks/docs/index.md +++ /dev/null @@ -1,16 +0,0 @@ -# Welcome to Minos Microservice Network's documentation! - -.. toctree:: - :maxdepth: 1 - - readme - runthetests - api/minos - authors - history - -## Indices and tables - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/core/minos-microservice-networks/docs/readme.md b/packages/core/minos-microservice-networks/docs/readme.md deleted file mode 100644 index 9a7702cfc..000000000 --- a/packages/core/minos-microservice-networks/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Readme - -.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-networks/docs/runthetests.md b/packages/core/minos-microservice-networks/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/core/minos-microservice-networks/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/core/minos-microservice-networks/minos/networks/__init__.py b/packages/core/minos-microservice-networks/minos/networks/__init__.py index a985f31d3..044a35b86 100644 --- a/packages/core/minos-microservice-networks/minos/networks/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/__init__.py @@ -1,3 +1,5 @@ +"""The networks core of the Minos Framework.""" + __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.6.0" diff --git a/packages/core/minos-microservice-networks/poetry.lock b/packages/core/minos-microservice-networks/poetry.lock index b0100b80f..eb9f5022c 100644 --- a/packages/core/minos-microservice-networks/poetry.lock +++ b/packages/core/minos-microservice-networks/poetry.lock @@ -34,14 +34,6 @@ psycopg2-binary = ">=2.8.4" [package.extras] sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "async-timeout" version = "4.0.2" @@ -72,20 +64,9 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +77,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -113,40 +94,13 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[[package]] -name = "charset-normalizer" -version = "2.0.12" -description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "dev" -optional = false -python-versions = ">=3.5.0" - -[package.extras] -unicode_backport = ["unicodedata2"] - [[package]] name = "click" -version = "8.0.4" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -194,7 +148,7 @@ python-versions = "*" [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -209,22 +163,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -239,18 +177,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -264,49 +190,6 @@ mccabe = ">=0.6.0,<0.7.0" pycodestyle = ">=2.8.0,<2.9.0" pyflakes = ">=2.4.0,<2.5.0" -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - -[[package]] -name = "idna" -version = "3.3" -description = "Internationalized Domain Names in Applications (IDNA)" -category = "dev" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -329,20 +212,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "lmdb" version = "1.3.0" @@ -351,26 +220,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -403,14 +252,6 @@ uvloop = "^0.16.0" type = "directory" url = "../minos-microservice-common" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "mypy-extensions" version = "0.4.3" @@ -419,14 +260,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -454,14 +287,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -486,22 +311,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -534,14 +343,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -574,14 +375,6 @@ tomli = ">=1.0.0" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2.7.2)", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -590,24 +383,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "six" version = "1.16.0" @@ -616,167 +391,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "toml" -version = "0.10.2" -description = "Python Library for Tom's Obvious, Minimal Language" -category = "dev" -optional = false -python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" - [[package]] name = "tomli" version = "2.0.1" @@ -793,19 +407,6 @@ category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - [[package]] name = "uvloop" version = "0.16.0" @@ -819,40 +420,10 @@ dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0 docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "ea88425476960ab086eadc6616f36d6cbdc2e2e92e95c4a1cd2f5a4ae7907738" +content-hash = "e42daefcd4268a4e52adb05cc71cacd476f285d0031f5a50c1440f409eadf9a3" [metadata.files] aiomisc = [ @@ -863,10 +434,6 @@ aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, ] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -879,54 +446,38 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] -charset-normalizer = [ - {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, - {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, -] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -983,50 +534,42 @@ crontab = [ {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, @@ -1046,30 +589,10 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] -idna = [ - {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, - {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, -] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1078,10 +601,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] lmdb = [ {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, @@ -1111,69 +630,15 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] minos-microservice-common = [] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1216,10 +681,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1228,10 +689,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1302,10 +759,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1314,10 +767,6 @@ pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1353,62 +802,10 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] -toml = [ - {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, - {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, -] tomli = [ {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, @@ -1417,10 +814,6 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, @@ -1439,11 +832,3 @@ uvloop = [ {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index 0b59df1d1..1c1f5d6e1 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -43,12 +43,6 @@ isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.17.0" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/packages/core/minos-microservice-saga/HISTORY.md b/packages/core/minos-microservice-saga/HISTORY.md index 64aaffbbb..940e9b4b7 100644 --- a/packages/core/minos-microservice-saga/HISTORY.md +++ b/packages/core/minos-microservice-saga/HISTORY.md @@ -1,86 +1,72 @@ -History -======= +# History -0.0.1 (2021-05-12) ------------------- +## 0.0.1 (2021-05-12) * First Release * added support for Saga Instances * Saga Actions -0.0.2 (2021-05-14) ------------------- +## 0.0.2 (2021-05-14) * Moved to Poetry * Added actions for documentation -0.0.3 (2021-05-20) ------------------- +## 0.0.3 (2021-05-20) * Added Dependency injection Container use * Completed Saga Manager -0.0.4 (2021-05-31) ------------------- +## 0.0.4 (2021-05-31) * Bugfixes -0.0.5 (2021-06-02) ------------------- +## 0.0.5 (2021-06-02) * Created SagaContext class * Documentation improvement * implemented __getitem__ and __setitem__ for SagaContext -0.0.6 (2021-07-06) ------------------- +## 0.0.6 (2021-07-06) * Completed the Saga process workflow implementation * Bugfixes * Completed the Compensation process * Added Reply Command to Saga process -0.0.7 (2021-07-12) ------------------- +## 0.0.7 (2021-07-12) * Added update to common * Bugfixes -0.0.8 (2021-07-23) ------------------- +## 0.0.8 (2021-07-23) * Now Sagas can be paused also on memory in addition to on disk. * Improve SagaManager API. -0.0.9 (2021-07-26) ------------------- +## 0.0.9 (2021-07-26) * Add flag to return SagaExecution instances directly from SagaManager -0.0.10 (2021-08-23) ------------------- +## 0.0.10 (2021-08-23) * Support latest `minos-microservice-common` release (`0.1.10`) * Change default `SagaManager` flags to (`pause_on_disk=False, raise_on_error=True, return_execution=True`) * Enrich failed `CommandReply` instances with exception message. * Add `SagaRequest` and `SagaResponse`. -0.0.11 (2021-09-01) ------------------- +## 0.0.11 (2021-09-01) * Deprecate `SagaManager.run` by `Saga` names (the new approach is to directly pass the `Saga` instance). * Remove `name` from `Saga` class. * Minor improvements. -0.0.12 (2021-09-27) ------------------- +## 0.0.12 (2021-09-27) * Fix troubles related with dependency injections. * Remove file headers. * Stop using `NoReturn` everywhere. -0.1.0 (2021-10-08) ------------------- +## 0.1.0 (2021-10-08) * Add `SagaStep.on_error` method to handle errored responses. * Integrate `SagaRequest` and `SagaResponse` into `SagaOperation` definitions. @@ -90,8 +76,7 @@ History * Rename `LocalExecutor` as `Executor`, `OnReplyExecutor` as `ResponseExecutor` and `PublishExecutor` as `RequestExecutor`. * Simplify `SagaException` and heirs names. -0.1.1 (2021-10-19) ------------------- +## 0.1.1 (2021-10-19) * Add `ConditionalSagaStep` and `ConditionalSagaStepExecution` which allow to define conditional logic for steps within the `SagaExecution`. * Add `LocalSagaStep` and `LocalSagaStepExecution` classes which allow to execute local functions within the `SagaExecution`. @@ -100,13 +85,11 @@ History * Add `user` propagation from `SagaManager` to `RequestExecutor`. * Improve `SagaContext` behaviour, allowing to dynamically change field types and also delete them as in any `dict` instance. -0.2.0 (2021-11-08) ------------------- +## 0.2.0 (2021-11-08) * Add compatibility to `minos-microservice-common>=0.2.0`. -0.3.0 (2021-11-15) ------------------- +## 0.3.0 (2021-11-15) * Add `SagaService` class (containing the reply handling logic). * Add `transactional_command` middleware (to extend the saga transactionality to remote steps). @@ -118,71 +101,59 @@ History * Store `service_name: str` as part of `SagaStepExecution` metadata. * Deprecate callback argument on `Saga.commit` method in favor of `Saga.local_step`. -0.3.1 (2021-11-17) ------------------- +## 0.3.1 (2021-11-17) * Improve integration between `ConditionalSagaStep` and `TransactionCommitter` * Add `SagaExecution.commit(...)` and `SagaExecution.reject(...)` methods and `autocommit: bool` and `autoreject: bool` into `SagaExecution.execute(...)` and `SagaExecution.rollback(...)` methods respectively. * Fix concurrent blocks related with a limited amount of `minos.networks.DynamicHandler` instances on the `minos.networks.DynamicHandlerPool`. -0.3.2 (2021-11-23) ------------------- +## 0.3.2 (2021-11-23) * Take advantage of concurrent remote broker calls to improve the `TransactionCommiter` performance. * Expose `autocommit: bool = True` argument on `SagaManager.run(...)` method. * Add support for `minos-microservice-networks=^0.3.0`. -0.3.3 (2021-11-26) ------------------- +## 0.3.3 (2021-11-26) * Fix bug related with empty `ConditionalSagaStep.from_raw` and empty `else_then`. -0.3.4 (2021-11-26) ------------------- +## 0.3.4 (2021-11-26) * Fix bug related with `TransactionCommitter` and `ConditionalSagaStepExecution`. -0.3.5 (2021-11-30) ------------------- +## 0.3.5 (2021-11-30) * Fix bug related with `Transaction` scopes and sub-`Saga` executions launched from `RemoteStep` calls * Add support for `minos-microservice-network~=0.3.1`. -0.4.0 (2022-01-27) ------------------- +## 0.4.0 (2022-01-27) * Be compatible with `minos-microservice-common~=0.4.0`. * Be compatible with `minos-microservice-aggregate~=0.4.0`. * Be compatible with `minos-microservice-networks~=0.4.0`. -0.4.1 (2022-01-31) ------------------- +## 0.4.1 (2022-01-31) * Update `README.md`. -0.5.0 (2022-02-03) ------------------- +## 0.5.0 (2022-02-03) * Minor changes. -0.5.1 (2022-02-03) ------------------- +## 0.5.1 (2022-02-03) * Fix bug related with dependency specification. -0.5.2 (2022-02-08) ------------------- +## 0.5.2 (2022-02-08) * Add compatibility to `minos-microservice-aggregate~=0.5.2`. * Minor changes. -0.5.3 (2022-03-04) ------------------- +## 0.5.3 (2022-03-04) * Improve attribute and item accessors of `SagaContext`. -0.6.0 (2022-03-28) ------------------- +## 0.6.0 (2022-03-28) * Replace `dependency-injector`'s injection classes by the ones provided by the `minos.common.injections` module. * Be compatible with latest `minos.common.Config` API. diff --git a/packages/core/minos-microservice-saga/Makefile b/packages/core/minos-microservice-saga/Makefile index acc861207..ef814b8bc 100644 --- a/packages/core/minos-microservice-saga/Makefile +++ b/packages/core/minos-microservice-saga/Makefile @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/core/minos-microservice-saga/RUNTHETESTS.md b/packages/core/minos-microservice-saga/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/core/minos-microservice-saga/RUNTHETESTS.md +++ b/packages/core/minos-microservice-saga/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/core/minos-microservice-saga/SETUP.md b/packages/core/minos-microservice-saga/SETUP.md index 8203965c7..e85ca0f64 100644 --- a/packages/core/minos-microservice-saga/SETUP.md +++ b/packages/core/minos-microservice-saga/SETUP.md @@ -1,5 +1,4 @@ -Set up a development environment -================================= +# Set up a development environment Since we use `poetry` as the default package manager, it must be installed. Please refer to `https://python-poetry.org/docs/#installation`. diff --git a/packages/core/minos-microservice-saga/docs/Makefile b/packages/core/minos-microservice-saga/docs/Makefile deleted file mode 100644 index f54fcebf7..000000000 --- a/packages/core/minos-microservice-saga/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -SPHINXPROJ = minos-microservice-saga -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/core/minos-microservice-saga/docs/_static/style.css b/packages/core/minos-microservice-saga/docs/_static/style.css deleted file mode 100644 index 8aa6c288f..000000000 --- a/packages/core/minos-microservice-saga/docs/_static/style.css +++ /dev/null @@ -1,3 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} diff --git a/packages/core/minos-microservice-saga/docs/_templates/layout.html b/packages/core/minos-microservice-saga/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/core/minos-microservice-saga/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/core/minos-microservice-saga/docs/authors.md b/packages/core/minos-microservice-saga/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/core/minos-microservice-saga/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/core/minos-microservice-saga/docs/conf.py b/packages/core/minos-microservice-saga/docs/conf.py deleted file mode 100755 index 3d9418dc1..000000000 --- a/packages/core/minos-microservice-saga/docs/conf.py +++ /dev/null @@ -1,197 +0,0 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# -import os -import sys - -sys.path.insert(0, os.path.abspath("..")) - -import sphinx_rtd_theme - -from minos import ( - saga, -) - -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", - "sphinx.ext.viewcode", - "sphinx_rtd_theme", - "m2r2", -] -# Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# -source_suffix = [".rst", ".md"] - -# The master toctree document. -master_doc = "index" - -# General information about the project. -project = "Minos Microservice Saga" -copyright = "2021, Clariteia" -author = "Minos Framework Devs" - -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. -version = saga.__version__ -# The full version, including alpha/beta/rc tags. -release = saga.__version__ - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = "sphinx" - -# If true, `todo` and `todoList` produce output, else they produce nothing. -todo_include_todos = False - - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - -html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "minos_microservice_saga", -# "github_type": "star", -# } - -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ["_static"] - - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. -htmlhelp_basename = "minosdoc" - - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Microservice Saga Documentation", "Minos Framework Devs", "manual"), -] - - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Microservice Saga Documentation", [author], 1)] - - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Microservice Saga Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False -apidoc_module_first = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", -] -# "autodoc typehints" extension - -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/core/minos-microservice-saga/docs/history.md b/packages/core/minos-microservice-saga/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/core/minos-microservice-saga/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/core/minos-microservice-saga/docs/index.md b/packages/core/minos-microservice-saga/docs/index.md deleted file mode 100644 index 3dabc853e..000000000 --- a/packages/core/minos-microservice-saga/docs/index.md +++ /dev/null @@ -1,16 +0,0 @@ -# Welcome to Minos Microservice Saga's documentation! - -.. toctree:: - :maxdepth: 1 - - readme - runthetests - api/minos - authors - history - -## Indices and tables - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/core/minos-microservice-saga/docs/readme.md b/packages/core/minos-microservice-saga/docs/readme.md deleted file mode 100644 index 9a7702cfc..000000000 --- a/packages/core/minos-microservice-saga/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Readme - -.. mdinclude:: ../README.md diff --git a/packages/core/minos-microservice-saga/docs/runthetests.md b/packages/core/minos-microservice-saga/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/core/minos-microservice-saga/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/core/minos-microservice-saga/minos/saga/__init__.py b/packages/core/minos-microservice-saga/minos/saga/__init__.py index 41a2353e0..788625039 100644 --- a/packages/core/minos-microservice-saga/minos/saga/__init__.py +++ b/packages/core/minos-microservice-saga/minos/saga/__init__.py @@ -1,3 +1,5 @@ +"""The SAGA pattern of the Minos Framework.""" + __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.6.0" diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/saga.py b/packages/core/minos-microservice-saga/minos/saga/executions/saga.py index fa0bd94a8..3ae1ed5df 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/saga.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/saga.py @@ -165,7 +165,7 @@ async def execute( :param autocommit: If ``True`` the commit process is performed automatically, otherwise must be performed manually. :param kwargs: Additional named arguments. - :return: A ``SagaContext instance. + :return: A ``SagaContext`` instance. """ if self.status == SagaStatus.Finished: raise SagaExecutionAlreadyExecutedException( diff --git a/packages/core/minos-microservice-saga/poetry.lock b/packages/core/minos-microservice-saga/poetry.lock index 8cf474bb3..1854c5c0e 100644 --- a/packages/core/minos-microservice-saga/poetry.lock +++ b/packages/core/minos-microservice-saga/poetry.lock @@ -34,14 +34,6 @@ psycopg2-binary = ">=2.8.4" [package.extras] sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "async-timeout" version = "4.0.2" @@ -72,20 +64,9 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +77,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -113,40 +94,13 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[[package]] -name = "charset-normalizer" -version = "2.0.12" -description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "dev" -optional = false -python-versions = ">=3.5.0" - -[package.extras] -unicode_backport = ["unicodedata2"] - [[package]] name = "click" -version = "8.0.4" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -194,7 +148,7 @@ python-versions = "*" [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -209,22 +163,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -239,18 +177,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -264,49 +190,6 @@ mccabe = ">=0.6.0,<0.7.0" pycodestyle = ">=2.8.0,<2.9.0" pyflakes = ">=2.4.0,<2.5.0" -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - -[[package]] -name = "idna" -version = "3.3" -description = "Internationalized Domain Names in Applications (IDNA)" -category = "dev" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -329,20 +212,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "lmdb" version = "1.3.0" @@ -351,26 +220,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -441,14 +290,6 @@ psycopg2-binary = "^2.9.3" type = "directory" url = "../minos-microservice-networks" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "mypy-extensions" version = "0.4.3" @@ -457,14 +298,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -492,14 +325,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -524,22 +349,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -572,14 +381,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -612,14 +413,6 @@ tomli = ">=1.0.0" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2.7.2)", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -628,24 +421,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "six" version = "1.16.0" @@ -654,167 +429,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "toml" -version = "0.10.2" -description = "Python Library for Tom's Obvious, Minimal Language" -category = "dev" -optional = false -python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" - [[package]] name = "tomli" version = "2.0.1" @@ -831,19 +445,6 @@ category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - [[package]] name = "uvloop" version = "0.16.0" @@ -857,40 +458,10 @@ dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0 docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "f59b3c5c588ce969df14fed260965c6573d9ab3ba6e755966d45736cf3aeb3c7" +content-hash = "37a602a98cbdba4c07f6773160e53a2f76588e4698b878dda92a069133ae4591" [metadata.files] aiomisc = [ @@ -901,10 +472,6 @@ aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, ] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -917,54 +484,38 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] -charset-normalizer = [ - {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, - {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, -] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1021,50 +572,42 @@ crontab = [ {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, @@ -1084,30 +627,10 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] -idna = [ - {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, - {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, -] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1116,10 +639,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] lmdb = [ {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, @@ -1149,52 +668,6 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -1202,18 +675,10 @@ mccabe = [ minos-microservice-aggregate = [] minos-microservice-common = [] minos-microservice-networks = [] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1256,10 +721,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1268,10 +729,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1342,10 +799,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1354,10 +807,6 @@ pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1393,62 +842,10 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] -toml = [ - {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, - {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, -] tomli = [ {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, @@ -1457,10 +854,6 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, @@ -1479,11 +872,3 @@ uvloop = [ {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index d84cb5294..b9dbaeb62 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -45,12 +45,6 @@ isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.17.0" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/packages/plugins/minos-broker-kafka/Makefile b/packages/plugins/minos-broker-kafka/Makefile index acc861207..ef814b8bc 100644 --- a/packages/plugins/minos-broker-kafka/Makefile +++ b/packages/plugins/minos-broker-kafka/Makefile @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/plugins/minos-broker-kafka/RUNTHETESTS.md b/packages/plugins/minos-broker-kafka/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/plugins/minos-broker-kafka/RUNTHETESTS.md +++ b/packages/plugins/minos-broker-kafka/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/plugins/minos-broker-kafka/SETUP.md b/packages/plugins/minos-broker-kafka/SETUP.md index 8203965c7..e85ca0f64 100644 --- a/packages/plugins/minos-broker-kafka/SETUP.md +++ b/packages/plugins/minos-broker-kafka/SETUP.md @@ -1,5 +1,4 @@ -Set up a development environment -================================= +# Set up a development environment Since we use `poetry` as the default package manager, it must be installed. Please refer to `https://python-poetry.org/docs/#installation`. diff --git a/packages/plugins/minos-broker-kafka/docs/Makefile b/packages/plugins/minos-broker-kafka/docs/Makefile deleted file mode 100644 index 09dee594d..000000000 --- a/packages/plugins/minos-broker-kafka/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -SPHINXPROJ = minos-broker-kafka -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/plugins/minos-broker-kafka/docs/_static/style.css b/packages/plugins/minos-broker-kafka/docs/_static/style.css deleted file mode 100644 index 8aa6c288f..000000000 --- a/packages/plugins/minos-broker-kafka/docs/_static/style.css +++ /dev/null @@ -1,3 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} diff --git a/packages/plugins/minos-broker-kafka/docs/_templates/layout.html b/packages/plugins/minos-broker-kafka/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/plugins/minos-broker-kafka/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/plugins/minos-broker-kafka/docs/authors.md b/packages/plugins/minos-broker-kafka/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/plugins/minos-broker-kafka/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/plugins/minos-broker-kafka/docs/conf.py b/packages/plugins/minos-broker-kafka/docs/conf.py deleted file mode 100755 index fa8cbc601..000000000 --- a/packages/plugins/minos-broker-kafka/docs/conf.py +++ /dev/null @@ -1,191 +0,0 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# -import os -import sys - -sys.path.insert(0, os.path.abspath("..")) - -import sphinx_rtd_theme # noqa - -from minos.plugins import ( - kafka, -) - -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", - "sphinx.ext.viewcode", - "sphinx_rtd_theme", - "m2r2", -] -# Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# -source_suffix = [".rst", ".md"] - -# The master toctree document. -master_doc = "index" - -# General information about the project. -project = "Minos Broker Kafka" -copyright = "2021, Clariteia" -author = "Minos Framework Devs" - -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. -version = kafka.__version__ -# The full version, including alpha/beta/rc tags. -release = kafka.__version__ - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = "sphinx" - -todo_include_todos = False - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - -html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "cqrs", -# "github_type": "star", -# } - -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ["_static"] - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. -htmlhelp_basename = "minosdoc" - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Broker Kafka Documentation", "Minos Framework Devs", "manual"), -] - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Broker Kafka Documentation", [author], 1)] - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Broker Kafka Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False -apidoc_module_first = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", -] -# "autodoc typehints" extension - -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/plugins/minos-broker-kafka/docs/history.md b/packages/plugins/minos-broker-kafka/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/plugins/minos-broker-kafka/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/plugins/minos-broker-kafka/docs/index.md b/packages/plugins/minos-broker-kafka/docs/index.md deleted file mode 100644 index 2b4e1c123..000000000 --- a/packages/plugins/minos-broker-kafka/docs/index.md +++ /dev/null @@ -1,16 +0,0 @@ -# Welcome to Minos Broker Kafka's documentation! - -.. toctree:: - :maxdepth: 1 - - readme - runthetests - api/minos.plugins - authors - history - -## Indices and tables - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/plugins/minos-broker-kafka/docs/readme.md b/packages/plugins/minos-broker-kafka/docs/readme.md deleted file mode 100644 index 9a7702cfc..000000000 --- a/packages/plugins/minos-broker-kafka/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Readme - -.. mdinclude:: ../README.md diff --git a/packages/plugins/minos-broker-kafka/docs/runthetests.md b/packages/plugins/minos-broker-kafka/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/plugins/minos-broker-kafka/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py index 98e5b4a0b..503fd53f7 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py @@ -1,3 +1,5 @@ +"""The kafka plugin of the Minos Framework.""" + __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.6.0" diff --git a/packages/plugins/minos-broker-kafka/poetry.lock b/packages/plugins/minos-broker-kafka/poetry.lock index eb3bdd087..f623057fb 100644 --- a/packages/plugins/minos-broker-kafka/poetry.lock +++ b/packages/plugins/minos-broker-kafka/poetry.lock @@ -48,14 +48,6 @@ psycopg2-binary = ">=2.8.4" [package.extras] sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "async-timeout" version = "4.0.2" @@ -86,20 +78,9 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -110,7 +91,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -127,40 +108,13 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[[package]] -name = "charset-normalizer" -version = "2.0.12" -description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "dev" -optional = false -python-versions = ">=3.5.0" - -[package.extras] -unicode_backport = ["unicodedata2"] - [[package]] name = "click" -version = "8.0.4" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -208,7 +162,7 @@ python-versions = "*" [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -223,22 +177,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -253,18 +191,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -278,49 +204,6 @@ mccabe = ">=0.6.0,<0.7.0" pycodestyle = ">=2.8.0,<2.9.0" pyflakes = ">=2.4.0,<2.5.0" -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - -[[package]] -name = "idna" -version = "3.3" -description = "Internationalized Domain Names in Applications (IDNA)" -category = "dev" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -343,20 +226,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "kafka-python" version = "2.0.2" @@ -376,26 +245,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -447,14 +296,6 @@ psycopg2-binary = "^2.9.3" type = "directory" url = "../../core/minos-microservice-networks" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "mypy-extensions" version = "0.4.3" @@ -463,14 +304,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -498,14 +331,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -530,22 +355,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -578,14 +387,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -618,14 +419,6 @@ toml = "*" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -634,24 +427,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "six" version = "1.16.0" @@ -660,159 +435,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - [[package]] name = "toml" version = "0.10.2" @@ -837,19 +459,6 @@ category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - [[package]] name = "uvloop" version = "0.16.0" @@ -863,40 +472,10 @@ dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0 docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "6d3a08fa514c8d815566449ac760a49957e02fee20cf991a2a7b21b76d91e529" +content-hash = "ecd34b3f2eeddc1b83c628b472b82a382205f731469e4203d210b01f3c68118d" [metadata.files] aiokafka = [ @@ -930,10 +509,6 @@ aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, ] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -946,54 +521,38 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] -charset-normalizer = [ - {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, - {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, -] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1050,50 +609,42 @@ crontab = [ {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, @@ -1113,30 +664,10 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] -idna = [ - {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, - {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, -] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1145,10 +676,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] kafka-python = [ {file = "kafka-python-2.0.2.tar.gz", hash = "sha256:04dfe7fea2b63726cd6f3e79a2d86e709d608d74406638c5da33a01d45a9d7e3"}, {file = "kafka_python-2.0.2-py2.py3-none-any.whl", hash = "sha256:2d92418c7cb1c298fa6c7f0fb3519b520d0d7526ac6cb7ae2a4fc65a51a94b6e"}, @@ -1182,70 +709,16 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] minos-microservice-common = [] minos-microservice-networks = [] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1288,10 +761,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1300,10 +769,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1374,10 +839,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1386,10 +847,6 @@ pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1425,58 +882,10 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] toml = [ {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, @@ -1489,10 +898,6 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, @@ -1511,11 +916,3 @@ uvloop = [ {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] diff --git a/packages/plugins/minos-broker-kafka/pyproject.toml b/packages/plugins/minos-broker-kafka/pyproject.toml index 5b8fa8e37..228259d89 100644 --- a/packages/plugins/minos-broker-kafka/pyproject.toml +++ b/packages/plugins/minos-broker-kafka/pyproject.toml @@ -45,12 +45,6 @@ isort = "^5.8.0" pytest = "^6.2.4" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.12.0" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/packages/plugins/minos-broker-rabbitmq/Makefile b/packages/plugins/minos-broker-rabbitmq/Makefile index 854bc90bc..2016f9e38 100644 --- a/packages/plugins/minos-broker-rabbitmq/Makefile +++ b/packages/plugins/minos-broker-rabbitmq/Makefile @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/plugins/minos-broker-rabbitmq/RUNTHETESTS.md b/packages/plugins/minos-broker-rabbitmq/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/plugins/minos-broker-rabbitmq/RUNTHETESTS.md +++ b/packages/plugins/minos-broker-rabbitmq/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/plugins/minos-broker-rabbitmq/SETUP.md b/packages/plugins/minos-broker-rabbitmq/SETUP.md index 8203965c7..e85ca0f64 100644 --- a/packages/plugins/minos-broker-rabbitmq/SETUP.md +++ b/packages/plugins/minos-broker-rabbitmq/SETUP.md @@ -1,5 +1,4 @@ -Set up a development environment -================================= +# Set up a development environment Since we use `poetry` as the default package manager, it must be installed. Please refer to `https://python-poetry.org/docs/#installation`. diff --git a/packages/plugins/minos-broker-rabbitmq/docs/Makefile b/packages/plugins/minos-broker-rabbitmq/docs/Makefile deleted file mode 100644 index 504a873c8..000000000 --- a/packages/plugins/minos-broker-rabbitmq/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -SPHINXPROJ = minos-broker-rabbitmq -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/plugins/minos-broker-rabbitmq/docs/_static/style.css b/packages/plugins/minos-broker-rabbitmq/docs/_static/style.css deleted file mode 100644 index 8aa6c288f..000000000 --- a/packages/plugins/minos-broker-rabbitmq/docs/_static/style.css +++ /dev/null @@ -1,3 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} diff --git a/packages/plugins/minos-broker-rabbitmq/docs/_templates/layout.html b/packages/plugins/minos-broker-rabbitmq/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/plugins/minos-broker-rabbitmq/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/plugins/minos-broker-rabbitmq/docs/authors.md b/packages/plugins/minos-broker-rabbitmq/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/plugins/minos-broker-rabbitmq/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/plugins/minos-broker-rabbitmq/docs/conf.py b/packages/plugins/minos-broker-rabbitmq/docs/conf.py deleted file mode 100755 index 5f02ccff3..000000000 --- a/packages/plugins/minos-broker-rabbitmq/docs/conf.py +++ /dev/null @@ -1,191 +0,0 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# -import os -import sys - -sys.path.insert(0, os.path.abspath("..")) - -import sphinx_rtd_theme # noqa - -from minos.plugins import ( - rabbitmq, -) - -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", - "sphinx.ext.viewcode", - "sphinx_rtd_theme", - "m2r2", -] -# Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# -source_suffix = [".rst", ".md"] - -# The master toctree document. -master_doc = "index" - -# General information about the project. -project = "Minos Broker RabbitMQ" -copyright = "2021, Clariteia" -author = "Minos Framework Devs" - -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. -version = rabbitmq.__version__ -# The full version, including alpha/beta/rc tags. -release = rabbitmq.__version__ - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = "sphinx" - -todo_include_todos = False - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - -html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "cqrs", -# "github_type": "star", -# } - -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ["_static"] - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. -htmlhelp_basename = "minosdoc" - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Broker RabbitMQ Documentation", "Minos Framework Devs", "manual"), -] - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Broker RabbitMQ Documentation", [author], 1)] - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Broker RabbitMQ Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False -apidoc_module_first = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", -] -# "autodoc typehints" extension - -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/plugins/minos-broker-rabbitmq/docs/history.md b/packages/plugins/minos-broker-rabbitmq/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/plugins/minos-broker-rabbitmq/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/plugins/minos-broker-rabbitmq/docs/index.md b/packages/plugins/minos-broker-rabbitmq/docs/index.md deleted file mode 100644 index ab82e0fab..000000000 --- a/packages/plugins/minos-broker-rabbitmq/docs/index.md +++ /dev/null @@ -1,16 +0,0 @@ -# Welcome to Minos Broker RabbitMQ's documentation! - -.. toctree:: - :maxdepth: 1 - - readme - runthetests - api/minos.plugins - authors - history - -## Indices and tables - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/plugins/minos-broker-rabbitmq/docs/readme.md b/packages/plugins/minos-broker-rabbitmq/docs/readme.md deleted file mode 100644 index 9a7702cfc..000000000 --- a/packages/plugins/minos-broker-rabbitmq/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Readme - -.. mdinclude:: ../README.md diff --git a/packages/plugins/minos-broker-rabbitmq/docs/runthetests.md b/packages/plugins/minos-broker-rabbitmq/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/plugins/minos-broker-rabbitmq/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py b/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py index c9fa00b98..2a7519cf9 100644 --- a/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py +++ b/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py @@ -1,3 +1,5 @@ +"""The rabbitmq plugin of the Minos Framework.""" + __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.6.0" diff --git a/packages/plugins/minos-broker-rabbitmq/poetry.lock b/packages/plugins/minos-broker-rabbitmq/poetry.lock index 45320a44e..64ffc02d1 100644 --- a/packages/plugins/minos-broker-rabbitmq/poetry.lock +++ b/packages/plugins/minos-broker-rabbitmq/poetry.lock @@ -1,6 +1,6 @@ [[package]] name = "aio-pika" -version = "7.1.1" +version = "7.1.2" description = "Wrapper for the aiormq for asyncio and humans." category = "main" optional = false @@ -64,14 +64,6 @@ yarl = "*" [package.extras] develop = ["aiomisc (>=11.0,<12.0)", "coverage (!=4.3)", "coveralls", "pylava", "pytest", "pytest-cov", "tox (>=2.4)"] -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "async-timeout" version = "4.0.2" @@ -102,20 +94,9 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -126,7 +107,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -143,40 +124,13 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[[package]] -name = "charset-normalizer" -version = "2.0.12" -description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "dev" -optional = false -python-versions = ">=3.5.0" - -[package.extras] -unicode_backport = ["unicodedata2"] - [[package]] name = "click" -version = "8.0.4" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -224,7 +178,7 @@ python-versions = "*" [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -239,22 +193,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -269,18 +207,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -294,17 +220,6 @@ mccabe = ">=0.6.0,<0.7.0" pycodestyle = ">=2.8.0,<2.9.0" pyflakes = ">=2.4.0,<2.5.0" -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - [[package]] name = "idna" version = "3.3" @@ -313,30 +228,6 @@ category = "main" optional = false python-versions = ">=3.5" -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -359,20 +250,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "lmdb" version = "1.3.0" @@ -381,26 +258,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -452,14 +309,6 @@ psycopg2-binary = "^2.9.3" type = "directory" url = "../../core/minos-microservice-networks" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "multidict" version = "6.0.2" @@ -476,14 +325,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -523,14 +364,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -555,22 +388,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -603,14 +420,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -643,14 +452,6 @@ toml = "*" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -659,24 +460,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "six" version = "1.16.0" @@ -685,159 +468,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - [[package]] name = "toml" version = "0.10.2" @@ -862,19 +492,6 @@ category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - [[package]] name = "uvloop" version = "0.16.0" @@ -888,24 +505,6 @@ dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0 docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - [[package]] name = "yarl" version = "1.7.2" @@ -918,27 +517,15 @@ python-versions = ">=3.6" idna = ">=2.0" multidict = ">=4.0" -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "d7bf3ca770190476ab5714fbacc3bf086648828a2be5577fc264b6fb2c414daf" +content-hash = "98b33c6e7100a12158c1037e16d702490623ec6b90c1c3b569cb86779dc8b525" [metadata.files] aio-pika = [ - {file = "aio-pika-7.1.1.tar.gz", hash = "sha256:8c990642b2906d0ad5af8807855b2b5c400e3b9b3a5bdc64ba98357bd55051f1"}, - {file = "aio_pika-7.1.1-py3-none-any.whl", hash = "sha256:3af44e29fcad19f700d43d17ba2c536bbf763af9b228f6c0d97e5a9fe3c1bbb7"}, + {file = "aio-pika-7.1.2.tar.gz", hash = "sha256:b754ba114ce3cfbc5fb444c0d41c5f74f5cfff34c2c87fef3eab0ba796ec3e94"}, + {file = "aio_pika-7.1.2-py3-none-any.whl", hash = "sha256:47fbd996d6ff4a8b1ea0148091b9e056c3a581fd4be863801eba8fce690cd243"}, ] aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, @@ -952,10 +539,6 @@ aiormq = [ {file = "aiormq-6.2.3-py3-none-any.whl", hash = "sha256:95f0da57edd55f214a2e6c5b7ac98fa58a7c33911acd0d3315e86926b2dd2605"}, {file = "aiormq-6.2.3.tar.gz", hash = "sha256:db6c1e6e384f1d4dafe19f8df70c6dfc994932b40f4e542690016023ff8e952b"}, ] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -968,54 +551,38 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] -charset-normalizer = [ - {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, - {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, -] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1072,50 +639,42 @@ crontab = [ {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, @@ -1135,30 +694,14 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] idna = [ {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, ] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1167,10 +710,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] lmdb = [ {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, @@ -1200,62 +739,12 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] minos-microservice-common = [] minos-microservice-networks = [] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] multidict = [ {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:0b9e95a740109c6047602f4db4da9949e6c5945cefbad34a1299775ddc9a62e2"}, {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ac0e27844758d7177989ce406acc6a83c16ed4524ebc363c1f748cba184d89d3"}, @@ -1321,10 +810,6 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1370,10 +855,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1382,10 +863,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1456,10 +933,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1468,10 +941,6 @@ pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1507,58 +976,10 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] toml = [ {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, @@ -1571,10 +992,6 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, @@ -1593,10 +1010,6 @@ uvloop = [ {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] yarl = [ {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:f2a8508f7350512434e41065684076f640ecce176d262a7d54f0da41d99c5a95"}, {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:da6df107b9ccfe52d3a48165e48d72db0eca3e3029b5b8cb4fe6ee3cb870ba8b"}, @@ -1671,7 +1084,3 @@ yarl = [ {file = "yarl-1.7.2-cp39-cp39-win_amd64.whl", hash = "sha256:797c2c412b04403d2da075fb93c123df35239cd7b4cc4e0cd9e5839b73f52c58"}, {file = "yarl-1.7.2.tar.gz", hash = "sha256:45399b46d60c253327a460e99856752009fcee5f5d3c80b2f7c0cae1c38d56dd"}, ] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] diff --git a/packages/plugins/minos-broker-rabbitmq/pyproject.toml b/packages/plugins/minos-broker-rabbitmq/pyproject.toml index ef68df5fc..cac8904d2 100644 --- a/packages/plugins/minos-broker-rabbitmq/pyproject.toml +++ b/packages/plugins/minos-broker-rabbitmq/pyproject.toml @@ -43,12 +43,6 @@ isort = "^5.8.0" pytest = "^6.2.4" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.12.0" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/packages/plugins/minos-discovery-minos/Makefile b/packages/plugins/minos-discovery-minos/Makefile index acc861207..ef814b8bc 100644 --- a/packages/plugins/minos-discovery-minos/Makefile +++ b/packages/plugins/minos-discovery-minos/Makefile @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/plugins/minos-discovery-minos/RUNTHETESTS.md b/packages/plugins/minos-discovery-minos/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/plugins/minos-discovery-minos/RUNTHETESTS.md +++ b/packages/plugins/minos-discovery-minos/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/plugins/minos-discovery-minos/SETUP.md b/packages/plugins/minos-discovery-minos/SETUP.md index 8203965c7..e85ca0f64 100644 --- a/packages/plugins/minos-discovery-minos/SETUP.md +++ b/packages/plugins/minos-discovery-minos/SETUP.md @@ -1,5 +1,4 @@ -Set up a development environment -================================= +# Set up a development environment Since we use `poetry` as the default package manager, it must be installed. Please refer to `https://python-poetry.org/docs/#installation`. diff --git a/packages/plugins/minos-discovery-minos/docs/Makefile b/packages/plugins/minos-discovery-minos/docs/Makefile deleted file mode 100644 index 95592d15f..000000000 --- a/packages/plugins/minos-discovery-minos/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -SPHINXPROJ = minos-discovery-minos -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/plugins/minos-discovery-minos/docs/_static/style.css b/packages/plugins/minos-discovery-minos/docs/_static/style.css deleted file mode 100644 index 8aa6c288f..000000000 --- a/packages/plugins/minos-discovery-minos/docs/_static/style.css +++ /dev/null @@ -1,3 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} diff --git a/packages/plugins/minos-discovery-minos/docs/_templates/layout.html b/packages/plugins/minos-discovery-minos/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/plugins/minos-discovery-minos/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/plugins/minos-discovery-minos/docs/authors.md b/packages/plugins/minos-discovery-minos/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/plugins/minos-discovery-minos/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/plugins/minos-discovery-minos/docs/conf.py b/packages/plugins/minos-discovery-minos/docs/conf.py deleted file mode 100755 index 64b4ef650..000000000 --- a/packages/plugins/minos-discovery-minos/docs/conf.py +++ /dev/null @@ -1,194 +0,0 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# -import os -import sys - -sys.path.insert(0, os.path.abspath("..")) - -from minos.plugins import ( - minos_discovery, -) - -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", - "sphinx.ext.viewcode", - "sphinx_rtd_theme", - "m2r2", -] -# Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# -source_suffix = [".rst", ".md"] - -# The master toctree document. -master_doc = "index" - -# General information about the project. -project = "Minos Discovery Minos" -copyright = "2021, Clariteia" -author = "Minos Framework Devs" - -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. -version = minos_discovery.__version__ -# The full version, including alpha/beta/rc tags. -release = minos_discovery.__version__ - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = "sphinx" - -todo_include_todos = False - - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - -html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "cqrs", -# "github_type": "star", -# } - -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ["_static"] - - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. -htmlhelp_basename = "minosdoc" - - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Discovery Minos Documentation", "Minos Framework Devs", "manual"), -] - - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Discovery Minos Documentation", [author], 1)] - - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Discovery Minos Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False -apidoc_module_first = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", -] -# "autodoc typehints" extension - -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/plugins/minos-discovery-minos/docs/history.md b/packages/plugins/minos-discovery-minos/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/plugins/minos-discovery-minos/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/plugins/minos-discovery-minos/docs/index.md b/packages/plugins/minos-discovery-minos/docs/index.md deleted file mode 100644 index 6e892f8fd..000000000 --- a/packages/plugins/minos-discovery-minos/docs/index.md +++ /dev/null @@ -1,16 +0,0 @@ -# Welcome to Minos Discovery Minos's documentation! - -.. toctree:: - :maxdepth: 1 - - readme - runthetests - api/minos.plugins - authors - history - -## Indices and tables - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/plugins/minos-discovery-minos/docs/readme.md b/packages/plugins/minos-discovery-minos/docs/readme.md deleted file mode 100644 index 9a7702cfc..000000000 --- a/packages/plugins/minos-discovery-minos/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Readme - -.. mdinclude:: ../README.md diff --git a/packages/plugins/minos-discovery-minos/docs/runthetests.md b/packages/plugins/minos-discovery-minos/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/plugins/minos-discovery-minos/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py b/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py index c3eddef3b..fa3fdf505 100644 --- a/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py +++ b/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py @@ -1,3 +1,5 @@ +"""The minos-discovery plugin of the Minos Framework.""" + __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.6.0" diff --git a/packages/plugins/minos-discovery-minos/poetry.lock b/packages/plugins/minos-discovery-minos/poetry.lock index 0fb9bb621..e49e2b433 100644 --- a/packages/plugins/minos-discovery-minos/poetry.lock +++ b/packages/plugins/minos-discovery-minos/poetry.lock @@ -65,14 +65,6 @@ python-versions = ">=3.6" [package.dependencies] frozenlist = ">=1.1.0" -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "async-timeout" version = "4.0.2" @@ -103,20 +95,9 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -127,7 +108,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -144,22 +125,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - [[package]] name = "charset-normalizer" version = "2.0.12" @@ -173,11 +138,11 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.0.4" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -225,7 +190,7 @@ python-versions = "*" [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -240,22 +205,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -270,18 +219,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -303,17 +240,6 @@ category = "main" optional = false python-versions = ">=3.7" -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - [[package]] name = "idna" version = "3.3" @@ -322,30 +248,6 @@ category = "main" optional = false python-versions = ">=3.5" -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -368,20 +270,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "lmdb" version = "1.3.0" @@ -390,26 +278,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -461,14 +329,6 @@ psycopg2-binary = "^2.9.3" type = "directory" url = "../../core/minos-microservice-networks" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "multidict" version = "6.0.2" @@ -485,14 +345,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -520,14 +372,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -552,22 +396,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -600,14 +428,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -640,14 +460,6 @@ toml = "*" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -656,24 +468,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "six" version = "1.16.0" @@ -682,159 +476,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - [[package]] name = "toml" version = "0.10.2" @@ -859,19 +500,6 @@ category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - [[package]] name = "uvloop" version = "0.16.0" @@ -885,24 +513,6 @@ dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0 docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - [[package]] name = "yarl" version = "1.7.2" @@ -915,22 +525,10 @@ python-versions = ">=3.6" idna = ">=2.0" multidict = ">=4.0" -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "7a9d17e062dc6ea5bc5f6f84ca6e911bf86dd0bd2cdcd5917f65d990c521928f" +content-hash = "a92374adf66c4b234f53b1d8758750e049f11a9b8d0e5a952d34602579eacf09" [metadata.files] aiohttp = [ @@ -1019,10 +617,6 @@ aiosignal = [ {file = "aiosignal-1.2.0-py3-none-any.whl", hash = "sha256:26e62109036cd181df6e6ad646f91f0dcfd05fe16d0cb924138ff2ab75d64e3a"}, {file = "aiosignal-1.2.0.tar.gz", hash = "sha256:78ed67db6c7b7ced4f98e495e572106d5c432a93e1ddd1bf475e1dc05f5b7df2"}, ] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -1035,54 +629,42 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] charset-normalizer = [ {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1139,50 +721,42 @@ crontab = [ {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, @@ -1202,10 +776,6 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, @@ -1271,22 +841,10 @@ frozenlist = [ {file = "frozenlist-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:772965f773757a6026dea111a15e6e2678fbd6216180f82a48a40b27de1ee2ab"}, {file = "frozenlist-1.3.0.tar.gz", hash = "sha256:ce6f2ba0edb7b0c1d8976565298ad2deba6f8064d2bebb6ffce2ca896eb35b0b"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] idna = [ {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, ] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1295,10 +853,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] lmdb = [ {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, @@ -1328,62 +882,12 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] minos-microservice-common = [] minos-microservice-networks = [] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] multidict = [ {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:0b9e95a740109c6047602f4db4da9949e6c5945cefbad34a1299775ddc9a62e2"}, {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ac0e27844758d7177989ce406acc6a83c16ed4524ebc363c1f748cba184d89d3"}, @@ -1449,10 +953,6 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1495,10 +995,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1507,10 +1003,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1581,10 +1073,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1593,10 +1081,6 @@ pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1632,58 +1116,10 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] toml = [ {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, @@ -1696,10 +1132,6 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, @@ -1718,10 +1150,6 @@ uvloop = [ {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] yarl = [ {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:f2a8508f7350512434e41065684076f640ecce176d262a7d54f0da41d99c5a95"}, {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:da6df107b9ccfe52d3a48165e48d72db0eca3e3029b5b8cb4fe6ee3cb870ba8b"}, @@ -1796,7 +1224,3 @@ yarl = [ {file = "yarl-1.7.2-cp39-cp39-win_amd64.whl", hash = "sha256:797c2c412b04403d2da075fb93c123df35239cd7b4cc4e0cd9e5839b73f52c58"}, {file = "yarl-1.7.2.tar.gz", hash = "sha256:45399b46d60c253327a460e99856752009fcee5f5d3c80b2f7c0cae1c38d56dd"}, ] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] diff --git a/packages/plugins/minos-discovery-minos/pyproject.toml b/packages/plugins/minos-discovery-minos/pyproject.toml index 5a297dc4b..bba53b0fa 100644 --- a/packages/plugins/minos-discovery-minos/pyproject.toml +++ b/packages/plugins/minos-discovery-minos/pyproject.toml @@ -1,7 +1,7 @@ [tool.poetry] name = "minos-discovery-minos" version = "0.6.0" -description = "The minos-discover plugin of the Minos Framework" +description = "The minos-discovery plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" homepage = "https://www.minos.run/" @@ -43,12 +43,6 @@ isort = "^5.8.0" pytest = "^6.2.4" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.12.0" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/packages/plugins/minos-http-aiohttp/Makefile b/packages/plugins/minos-http-aiohttp/Makefile index 854bc90bc..2016f9e38 100644 --- a/packages/plugins/minos-http-aiohttp/Makefile +++ b/packages/plugins/minos-http-aiohttp/Makefile @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/plugins/minos-http-aiohttp/RUNTHETESTS.md b/packages/plugins/minos-http-aiohttp/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/plugins/minos-http-aiohttp/RUNTHETESTS.md +++ b/packages/plugins/minos-http-aiohttp/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/plugins/minos-http-aiohttp/SETUP.md b/packages/plugins/minos-http-aiohttp/SETUP.md index 8203965c7..e85ca0f64 100644 --- a/packages/plugins/minos-http-aiohttp/SETUP.md +++ b/packages/plugins/minos-http-aiohttp/SETUP.md @@ -1,5 +1,4 @@ -Set up a development environment -================================= +# Set up a development environment Since we use `poetry` as the default package manager, it must be installed. Please refer to `https://python-poetry.org/docs/#installation`. diff --git a/packages/plugins/minos-http-aiohttp/docs/Makefile b/packages/plugins/minos-http-aiohttp/docs/Makefile deleted file mode 100644 index fe5d0ed63..000000000 --- a/packages/plugins/minos-http-aiohttp/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = python -msphinx -SPHINXPROJ = minos-http-aiohttp -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/plugins/minos-http-aiohttp/docs/_static/style.css b/packages/plugins/minos-http-aiohttp/docs/_static/style.css deleted file mode 100644 index 8aa6c288f..000000000 --- a/packages/plugins/minos-http-aiohttp/docs/_static/style.css +++ /dev/null @@ -1,3 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} diff --git a/packages/plugins/minos-http-aiohttp/docs/_templates/layout.html b/packages/plugins/minos-http-aiohttp/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/plugins/minos-http-aiohttp/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/plugins/minos-http-aiohttp/docs/authors.md b/packages/plugins/minos-http-aiohttp/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/plugins/minos-http-aiohttp/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/plugins/minos-http-aiohttp/docs/conf.py b/packages/plugins/minos-http-aiohttp/docs/conf.py deleted file mode 100755 index ba6e4a8eb..000000000 --- a/packages/plugins/minos-http-aiohttp/docs/conf.py +++ /dev/null @@ -1,197 +0,0 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# -import os -import sys - -sys.path.insert(0, os.path.abspath("..")) - -import sphinx_rtd_theme - -from minos.plugins import ( - aiohttp, -) - -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", - "sphinx.ext.viewcode", - "sphinx_rtd_theme", - "m2r2", -] -# Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# -source_suffix = [".rst", ".md"] - -# The master toctree document. -master_doc = "index" - -# General information about the project. -project = "Minos Aiohttp" -copyright = "2021, Clariteia" -author = "Clariteia Devs" - -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. -version = aiohttp.__version__ -# The full version, including alpha/beta/rc tags. -release = aiohttp.__version__ - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = "sphinx" - -# If true, `todo` and `todoList` produce output, else they produce nothing. -todo_include_todos = False - - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - -html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "plugins", -# "github_type": "star", -# } - -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ["_static"] - - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. -htmlhelp_basename = "minosdoc" - - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Aiohttp Documentation", "Clariteia Devs", "manual"), -] - - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Aiohttp Documentation", [author], 1)] - - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Aiohttp Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False -apidoc_module_first = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", -] -# "autodoc typehints" extension - -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/plugins/minos-http-aiohttp/docs/history.md b/packages/plugins/minos-http-aiohttp/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/plugins/minos-http-aiohttp/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/plugins/minos-http-aiohttp/docs/index.md b/packages/plugins/minos-http-aiohttp/docs/index.md deleted file mode 100644 index f9e341d25..000000000 --- a/packages/plugins/minos-http-aiohttp/docs/index.md +++ /dev/null @@ -1,17 +0,0 @@ -# Welcome to Minos AIOHTTP's documentation! - -.. toctree:: - :maxdepth: 1 - - readme - runthetests - usage - api/minos.plugins - authors - history - -## Indices and tables - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/plugins/minos-http-aiohttp/docs/readme.md b/packages/plugins/minos-http-aiohttp/docs/readme.md deleted file mode 100644 index 9a7702cfc..000000000 --- a/packages/plugins/minos-http-aiohttp/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Readme - -.. mdinclude:: ../README.md diff --git a/packages/plugins/minos-http-aiohttp/docs/runthetests.md b/packages/plugins/minos-http-aiohttp/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/plugins/minos-http-aiohttp/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py index 9a07f1da2..306d4d301 100644 --- a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py +++ b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py @@ -1,3 +1,5 @@ +"""The aiohttp plugin of the Minos Framework.""" + __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.6.0" diff --git a/packages/plugins/minos-http-aiohttp/poetry.lock b/packages/plugins/minos-http-aiohttp/poetry.lock index aeab732e2..cb3e0e7d3 100644 --- a/packages/plugins/minos-http-aiohttp/poetry.lock +++ b/packages/plugins/minos-http-aiohttp/poetry.lock @@ -65,14 +65,6 @@ python-versions = ">=3.6" [package.dependencies] frozenlist = ">=1.1.0" -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "async-timeout" version = "4.0.2" @@ -103,20 +95,9 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -127,7 +108,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -144,22 +125,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - [[package]] name = "charset-normalizer" version = "2.0.12" @@ -173,11 +138,11 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.0.4" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -225,7 +190,7 @@ python-versions = "*" [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -240,22 +205,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -270,18 +219,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -303,17 +240,6 @@ category = "main" optional = false python-versions = ">=3.7" -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - [[package]] name = "idna" version = "3.3" @@ -322,30 +248,6 @@ category = "main" optional = false python-versions = ">=3.5" -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -368,20 +270,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "lmdb" version = "1.3.0" @@ -390,26 +278,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -461,14 +329,6 @@ psycopg2-binary = "^2.9.3" type = "directory" url = "../../core/minos-microservice-networks" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "multidict" version = "6.0.2" @@ -485,14 +345,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -520,14 +372,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -552,22 +396,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -600,14 +428,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -640,14 +460,6 @@ toml = "*" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -656,24 +468,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "six" version = "1.16.0" @@ -682,159 +476,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - [[package]] name = "toml" version = "0.10.2" @@ -859,19 +500,6 @@ category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - [[package]] name = "uvloop" version = "0.16.0" @@ -885,24 +513,6 @@ dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0 docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - [[package]] name = "yarl" version = "1.7.2" @@ -915,22 +525,10 @@ python-versions = ">=3.6" idna = ">=2.0" multidict = ">=4.0" -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "da8b7c522a577fd73f69a42f29043823eb2510318fbb6e4a90a9d75513f75242" +content-hash = "cf3f1cbfb0802979f6e4c686ffcd7d15a5e62208d38db5738a923a428d91e9d0" [metadata.files] aiohttp = [ @@ -1019,10 +617,6 @@ aiosignal = [ {file = "aiosignal-1.2.0-py3-none-any.whl", hash = "sha256:26e62109036cd181df6e6ad646f91f0dcfd05fe16d0cb924138ff2ab75d64e3a"}, {file = "aiosignal-1.2.0.tar.gz", hash = "sha256:78ed67db6c7b7ced4f98e495e572106d5c432a93e1ddd1bf475e1dc05f5b7df2"}, ] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -1035,54 +629,42 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] charset-normalizer = [ {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1139,50 +721,42 @@ crontab = [ {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, @@ -1202,10 +776,6 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, @@ -1271,22 +841,10 @@ frozenlist = [ {file = "frozenlist-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:772965f773757a6026dea111a15e6e2678fbd6216180f82a48a40b27de1ee2ab"}, {file = "frozenlist-1.3.0.tar.gz", hash = "sha256:ce6f2ba0edb7b0c1d8976565298ad2deba6f8064d2bebb6ffce2ca896eb35b0b"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] idna = [ {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, ] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1295,10 +853,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] lmdb = [ {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, @@ -1328,62 +882,12 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] minos-microservice-common = [] minos-microservice-networks = [] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] multidict = [ {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:0b9e95a740109c6047602f4db4da9949e6c5945cefbad34a1299775ddc9a62e2"}, {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ac0e27844758d7177989ce406acc6a83c16ed4524ebc363c1f748cba184d89d3"}, @@ -1449,10 +953,6 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1495,10 +995,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1507,10 +1003,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1581,10 +1073,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1593,10 +1081,6 @@ pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1632,58 +1116,10 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] toml = [ {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, @@ -1696,10 +1132,6 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, @@ -1718,10 +1150,6 @@ uvloop = [ {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] yarl = [ {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:f2a8508f7350512434e41065684076f640ecce176d262a7d54f0da41d99c5a95"}, {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:da6df107b9ccfe52d3a48165e48d72db0eca3e3029b5b8cb4fe6ee3cb870ba8b"}, @@ -1796,7 +1224,3 @@ yarl = [ {file = "yarl-1.7.2-cp39-cp39-win_amd64.whl", hash = "sha256:797c2c412b04403d2da075fb93c123df35239cd7b4cc4e0cd9e5839b73f52c58"}, {file = "yarl-1.7.2.tar.gz", hash = "sha256:45399b46d60c253327a460e99856752009fcee5f5d3c80b2f7c0cae1c38d56dd"}, ] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] diff --git a/packages/plugins/minos-http-aiohttp/pyproject.toml b/packages/plugins/minos-http-aiohttp/pyproject.toml index 330040d33..c883b3276 100644 --- a/packages/plugins/minos-http-aiohttp/pyproject.toml +++ b/packages/plugins/minos-http-aiohttp/pyproject.toml @@ -1,7 +1,7 @@ [tool.poetry] name = "minos-http-aiohttp" version = "0.6.0" -description = "The aiohttp plugin of the Minos Framework." +description = "The aiohttp plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" homepage = "https://www.minos.run/" @@ -45,12 +45,6 @@ isort = "^5.8.0" pytest = "^6.2.4" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.12.0" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/packages/plugins/minos-router-graphql/Makefile b/packages/plugins/minos-router-graphql/Makefile index 854bc90bc..2016f9e38 100644 --- a/packages/plugins/minos-router-graphql/Makefile +++ b/packages/plugins/minos-router-graphql/Makefile @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/plugins/minos-router-graphql/RUNTHETESTS.md b/packages/plugins/minos-router-graphql/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/plugins/minos-router-graphql/RUNTHETESTS.md +++ b/packages/plugins/minos-router-graphql/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/plugins/minos-router-graphql/SETUP.md b/packages/plugins/minos-router-graphql/SETUP.md index 8203965c7..e85ca0f64 100644 --- a/packages/plugins/minos-router-graphql/SETUP.md +++ b/packages/plugins/minos-router-graphql/SETUP.md @@ -1,5 +1,4 @@ -Set up a development environment -================================= +# Set up a development environment Since we use `poetry` as the default package manager, it must be installed. Please refer to `https://python-poetry.org/docs/#installation`. diff --git a/packages/plugins/minos-router-graphql/docs/Makefile b/packages/plugins/minos-router-graphql/docs/Makefile deleted file mode 100644 index 86af5d733..000000000 --- a/packages/plugins/minos-router-graphql/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = python -msphinx -SPHINXPROJ = minos_rest_aiohttp -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/plugins/minos-router-graphql/docs/_static/style.css b/packages/plugins/minos-router-graphql/docs/_static/style.css deleted file mode 100644 index 8aa6c288f..000000000 --- a/packages/plugins/minos-router-graphql/docs/_static/style.css +++ /dev/null @@ -1,3 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} diff --git a/packages/plugins/minos-router-graphql/docs/_templates/layout.html b/packages/plugins/minos-router-graphql/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/plugins/minos-router-graphql/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/plugins/minos-router-graphql/docs/authors.md b/packages/plugins/minos-router-graphql/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/plugins/minos-router-graphql/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/plugins/minos-router-graphql/docs/conf.py b/packages/plugins/minos-router-graphql/docs/conf.py deleted file mode 100755 index 8ac6c97e2..000000000 --- a/packages/plugins/minos-router-graphql/docs/conf.py +++ /dev/null @@ -1,197 +0,0 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# -import os -import sys - -sys.path.insert(0, os.path.abspath("..")) - -import sphinx_rtd_theme - -from minos.plugins import ( - graphql, -) - -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", - "sphinx.ext.viewcode", - "sphinx_rtd_theme", - "m2r2", -] -# Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# -source_suffix = [".rst", ".md"] - -# The master toctree document. -master_doc = "index" - -# General information about the project. -project = "Minos Router GraphQl" -copyright = "2021, Clariteia" -author = "Clariteia Devs" - -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. -version = graphql.__version__ -# The full version, including alpha/beta/rc tags. -release = graphql.__version__ - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = "sphinx" - -# If true, `todo` and `todoList` produce output, else they produce nothing. -todo_include_todos = False - - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - -html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "plugins", -# "github_type": "star", -# } - -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ["_static"] - - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. -htmlhelp_basename = "minosdoc" - - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Router GraphQl Documentation", "Clariteia Devs", "manual"), -] - - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Router GraphQl Documentation", [author], 1)] - - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Router GraphQl Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False -apidoc_module_first = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", -] -# "autodoc typehints" extension - -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/plugins/minos-router-graphql/docs/history.md b/packages/plugins/minos-router-graphql/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/plugins/minos-router-graphql/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/plugins/minos-router-graphql/docs/index.md b/packages/plugins/minos-router-graphql/docs/index.md deleted file mode 100644 index ee0c06e68..000000000 --- a/packages/plugins/minos-router-graphql/docs/index.md +++ /dev/null @@ -1,17 +0,0 @@ -# GraphQL plugin form Minos framework! -This plugin integrates the official graphql-core library. - -.. toctree:: - :maxdepth: 1 - - readme - runthetests - api/minos.plugins - authors - history - -## Indices and tables - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/plugins/minos-router-graphql/docs/readme.md b/packages/plugins/minos-router-graphql/docs/readme.md deleted file mode 100644 index 9a7702cfc..000000000 --- a/packages/plugins/minos-router-graphql/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Readme - -.. mdinclude:: ../README.md diff --git a/packages/plugins/minos-router-graphql/docs/runthetests.md b/packages/plugins/minos-router-graphql/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/plugins/minos-router-graphql/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py b/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py index b05cceb87..4bf9b2a7c 100644 --- a/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py +++ b/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py @@ -1,3 +1,5 @@ +"""The graphql plugin of the Minos Framework.""" + __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.6.0" diff --git a/packages/plugins/minos-router-graphql/poetry.lock b/packages/plugins/minos-router-graphql/poetry.lock index 462e1c998..ee849c445 100644 --- a/packages/plugins/minos-router-graphql/poetry.lock +++ b/packages/plugins/minos-router-graphql/poetry.lock @@ -34,14 +34,6 @@ psycopg2-binary = ">=2.8.4" [package.extras] sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "async-timeout" version = "4.0.2" @@ -72,20 +64,9 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +77,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -113,40 +94,13 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[[package]] -name = "charset-normalizer" -version = "2.0.12" -description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "dev" -optional = false -python-versions = ">=3.5.0" - -[package.extras] -unicode_backport = ["unicodedata2"] - [[package]] name = "click" -version = "8.0.4" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -194,7 +148,7 @@ python-versions = "*" [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -209,22 +163,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -239,18 +177,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -272,49 +198,6 @@ category = "main" optional = false python-versions = ">=3.6,<4" -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - -[[package]] -name = "idna" -version = "3.3" -description = "Internationalized Domain Names in Applications (IDNA)" -category = "dev" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -337,20 +220,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "lmdb" version = "1.3.0" @@ -359,26 +228,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -430,14 +279,6 @@ psycopg2-binary = "^2.9.3" type = "directory" url = "../../core/minos-microservice-networks" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "mypy-extensions" version = "0.4.3" @@ -446,14 +287,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -481,14 +314,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -513,22 +338,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -561,14 +370,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -601,14 +402,6 @@ toml = "*" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -617,24 +410,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "six" version = "1.16.0" @@ -643,159 +418,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - [[package]] name = "toml" version = "0.10.2" @@ -820,19 +442,6 @@ category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - [[package]] name = "uvloop" version = "0.16.0" @@ -846,40 +455,10 @@ dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0 docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "60bf9166dad901a62c80dae5fe0aed4b0304f633b0261d223ad27c72ec702b88" +content-hash = "a8050f5103cea0140af18113d3faa9a494436b9f2fb5f4618dc909a3d51bd97f" [metadata.files] aiomisc = [ @@ -890,10 +469,6 @@ aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, ] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -906,54 +481,38 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] -charset-normalizer = [ - {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, - {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, -] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1010,50 +569,42 @@ crontab = [ {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, @@ -1073,10 +624,6 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, @@ -1085,22 +632,6 @@ graphql-core = [ {file = "graphql-core-3.2.0.tar.gz", hash = "sha256:86e2a0be008bfde19ef78388de8a725a1d942a9190ca431c24a60837973803ce"}, {file = "graphql_core-3.2.0-py3-none-any.whl", hash = "sha256:0dda7e63676f119bb3d814621190fedad72fda07a8e9ab780bedd9f1957c6dc6"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] -idna = [ - {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, - {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, -] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1109,10 +640,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] lmdb = [ {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, @@ -1142,70 +669,16 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] minos-microservice-common = [] minos-microservice-networks = [] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1248,10 +721,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1260,10 +729,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1334,10 +799,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1346,10 +807,6 @@ pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1385,58 +842,10 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] toml = [ {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, @@ -1449,10 +858,6 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, @@ -1471,11 +876,3 @@ uvloop = [ {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] diff --git a/packages/plugins/minos-router-graphql/pyproject.toml b/packages/plugins/minos-router-graphql/pyproject.toml index 4425d630c..1b4fa7667 100644 --- a/packages/plugins/minos-router-graphql/pyproject.toml +++ b/packages/plugins/minos-router-graphql/pyproject.toml @@ -1,7 +1,7 @@ [tool.poetry] name = "minos-router-graphql" version = "0.6.0" -description = "The graphql plugin of the Minos Framework." +description = "The graphql plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" homepage = "https://www.minos.run/" @@ -43,12 +43,6 @@ isort = "^5.8.0" pytest = "^6.2.4" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.12.0" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] From ebc20efde924ae1503c94c1243dc29dc465587a7 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 31 Mar 2022 14:16:22 +0200 Subject: [PATCH 022/324] Add tests & Reformat --- .../minos/plugins/minos_kong/client.py | 46 +++++++++---------- .../tests/test_minos_discovery/test_client.py | 45 +++++++++++++++--- 2 files changed, 60 insertions(+), 31 deletions(-) diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py b/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py index 4300c9ae6..f5e102944 100644 --- a/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py +++ b/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py @@ -18,7 +18,9 @@ DiscoveryClient, ) -from .utils import Endpoint +from .utils import ( + Endpoint, +) logger = logging.getLogger(__name__) @@ -37,7 +39,9 @@ def __init__( host = "localhost" if port is None: port = 5567 - super().__init__(host, port, circuit_breaker_exceptions=(httpx.HTTPStatusError, *circuit_breaker_exceptions), **kwargs) + super().__init__( + host, port, circuit_breaker_exceptions=(httpx.HTTPStatusError, *circuit_breaker_exceptions), **kwargs + ) async def subscribe( self, host: str, port: int, name: str, endpoints: list[dict[str, str]], *args, **kwargs @@ -54,15 +58,15 @@ async def subscribe( """ fnsr = partial(self._register_service, self.route, name, host, port) - response_service = await self.with_circuit_breaker(fnsr) # register a service - if response_service.status_code == 409: # service already exist + response_service = await self.with_circuit_breaker(fnsr) # register a service + if response_service.status_code == 409: # service already exist # if service already exist, delete and add again fn_delete = partial(self._delete_service, self.route, name) - response_delete = await self.with_circuit_breaker(fn_delete) # delete the service + await self.with_circuit_breaker(fn_delete) # delete the service fnsr = partial(self._register_service, self.route, name, host, port) - response_service = await self.with_circuit_breaker(fnsr) # send the servie subscription again + response_service = await self.with_circuit_breaker(fnsr) # send the servie subscription again - content_service = response_service.json() # get the servie information like the id + content_service = response_service.json() # get the servie information like the id for endpoint in endpoints: endpointClass = Endpoint(endpoint["url"]) @@ -70,25 +74,19 @@ async def subscribe( "protocols": ["http"], "methods": [endpoint["method"]], "paths": [endpointClass.path_as_str], - "service": { - "id": content_service["id"] - } + "service": {"id": content_service["id"]}, } fn = partial(self._subscribe_routes, self.route, data) - response = await self.with_circuit_breaker(fn) # send the route request + response = await self.with_circuit_breaker(fn) # send the route request return response @staticmethod - async def _register_service(discovery_route: str, service_name: str, - microservice_host: str, microservice_port: str) -> httpx.Response: - url = f"{discovery_route}/services" # kong url for service POST or add - data = { - "name": service_name, - "protocol": "http", - "host": microservice_host, - "port": microservice_port - } + async def _register_service( + discovery_route: str, service_name: str, microservice_host: str, microservice_port: str + ) -> httpx.Response: + url = f"{discovery_route}/services" # kong url for service POST or add + data = {"name": service_name, "protocol": "http", "host": microservice_host, "port": microservice_port} async with httpx.AsyncClient() as client: response = await client.post(url, json=data) return response @@ -123,13 +121,13 @@ async def _delete_service(discovery_route: str, service_name) -> httpx.Response: :return: """ async with httpx.AsyncClient() as client: - url_get_route = f"{discovery_route}/services/{service_name}/routes" # url to get the routes + url_get_route = f"{discovery_route}/services/{service_name}/routes" # url to get the routes response_routes = await client.get(url_get_route) json_routes_response = response_routes.json() - if len(json_routes_response["data"]) > 0: # service already have route, routes must be deleted + if len(json_routes_response["data"]) > 0: # service already have route, routes must be deleted for route in json_routes_response["data"]: - url_delete_route = f"{discovery_route}/routes/{route['id']}" # url for routes delete + url_delete_route = f"{discovery_route}/routes/{route['id']}" # url for routes delete await client.delete(url_delete_route) - url_delete_service = f"{discovery_route}/services/{service_name}" # url for service delete + url_delete_service = f"{discovery_route}/services/{service_name}" # url for service delete response_delete_service = await client.delete(url_delete_service) return response_delete_service diff --git a/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py b/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py index 67e83d8f6..295647756 100644 --- a/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py +++ b/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py @@ -1,5 +1,10 @@ import unittest +from uuid import ( + uuid4, +) + import httpx + from minos.plugins.minos_kong import ( MinosKongClient, ) @@ -9,6 +14,11 @@ class TestMinosKongClient(unittest.IsolatedAsyncioTestCase): def setUp(self) -> None: self.client = MinosKongClient("localhost", 8001, circuit_breaker_time=0.1) + @staticmethod + def generate_underscore_uuid(): + name = str(uuid4()) + return name.replace("-", "_") + def test_constructor(self): client = MinosKongClient() self.assertEqual("localhost", client.host) @@ -19,25 +29,44 @@ def test_route(self): self.assertEqual("http://localhost:8001", self.client.route) async def test_subscribe(self): + name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", 5660, "test", [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] + "172.160.16.24", 5660, name, [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] ) self.assertTrue(201 == response.status_code) + async with httpx.AsyncClient() as client: + url = f"http://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual("http", response_data["protocol"]) + async def test_unsubscribe(self): + name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", 5660, "test", [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] + "172.160.16.24", 5660, name, [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] ) self.assertTrue(201 == response.status_code) - response_delete = await self.client.unsubscribe("test") + response_delete = await self.client.unsubscribe(name) self.assertTrue(204 == response_delete.status_code) + async with httpx.AsyncClient() as client: + url = f"http://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + self.assertTrue(404 == response.status_code) + async def test_route_params(self): + expected = ["/foo/.*", "/bar/.*/.*"] response = await self.client.subscribe( - "172.160.16.24", 5660, "test", [{"url": "/foo/{:user}", "method": "POST"}, - {"url": "/bar/{:domain}/{:username}", "method": "GET"}] + "172.160.16.24", + 5660, + "test", + [{"url": "/foo/{:user}", "method": "POST"}, {"url": "/bar/{:domain}/{:username}", "method": "GET"}], ) self.assertTrue(201 == response.status_code) @@ -46,9 +75,11 @@ async def test_route_params(self): url = f"http://{self.client.host}:{self.client.port}/services/test/routes" response = await client.get(url) response_data = response.json() - self.assertGreater(len(response_data['data']), 0) + self.assertTrue(200 == response.status_code) + self.assertGreater(len(response_data["data"]), 0) - self.assertTrue(200 == response.status_code) + for route in response_data["data"]: + self.assertTrue(bool(set(route["paths"]) & set(expected))) if __name__ == "__main__": From 7cd49d5c3d25cad3afe2455973a6d3cab1fe9a4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 31 Mar 2022 14:41:58 +0200 Subject: [PATCH 023/324] ISSUE #332 * Minor change. --- docs/conf.py | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/conf.py b/docs/conf.py index 044ed7176..0dbe83baf 100755 --- a/docs/conf.py +++ b/docs/conf.py @@ -15,7 +15,6 @@ ] extensions = [ - # "sphinxcontrib.apidoc", "sphinx.ext.autodoc", "sphinx.ext.viewcode", "sphinx.ext.intersphinx", From eb538eb293d53d1428ac64b1a88420b9dff63fb8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 31 Mar 2022 17:27:37 +0200 Subject: [PATCH 024/324] ISSUE #346 * Add `PoolFactory` class. --- .../minos/common/__init__.py | 1 + .../minos/common/config/v2.py | 6 ++ .../minos/common/pools.py | 55 +++++++++++++++++++ .../test_config/test_v2/test_base.py | 6 +- .../test_config/test_v2/test_parameterized.py | 2 + 5 files changed, 68 insertions(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 853fce3f1..368511a6b 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -100,6 +100,7 @@ from .pools import ( MinosPool, Pool, + PoolFactory, ) from .ports import ( Port, diff --git a/packages/core/minos-microservice-common/minos/common/config/v2.py b/packages/core/minos-microservice-common/minos/common/config/v2.py index d9a02035b..1f63bb03c 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v2.py +++ b/packages/core/minos-microservice-common/minos/common/config/v2.py @@ -50,6 +50,12 @@ def _get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin]]] partial_ans = list() + from ..pools import ( + PoolFactory, + ) + + partial_ans.append(PoolFactory) # FIXME + with suppress(MinosConfigException): partial_ans.extend(self._get_pools().values()) diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index 417e9d6ae..f2e5aa575 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -1,3 +1,7 @@ +from __future__ import ( + annotations, +) + import logging import warnings from abc import ( @@ -20,6 +24,12 @@ ContextManager, ) +from .config import ( + Config, +) +from .injections import ( + Injectable, +) from .setup import ( SetupMixin, ) @@ -29,6 +39,51 @@ P = TypeVar("P") +@Injectable("pool_factory") +class PoolFactory(SetupMixin): + """TODO""" + + _pools: dict[str, Pool] + + def __init__(self, config: Config, *args, **kwargs): + super().__init__(*args, **kwargs) + self._config = config + self._pools = dict() + + @classmethod + def _from_config(cls, config: Config, **kwargs) -> PoolFactory: + return cls(config, **kwargs) + + async def _destroy(self) -> None: + for pool in self._pools.values(): + await pool.destroy() + await super()._destroy() + + async def get_pool(self, type_: str, key: Optional[str] = None, **kwargs) -> Pool: + """TODO + + :param type_: TODO + :param key: TODO + :param kwargs: TODO + :return: TODO + """ + if key is None: + key = type_ + if key not in self._pools: + self._pools[key] = await self._create_pool(type_, key=key, **kwargs) + return self._pools[key] + + async def _create_pool(self, type_: str, **kwargs) -> Pool: + # noinspection PyTypeChecker + pool_cls: type[Pool] = self._config.get_pools().get(type_) + if pool_cls is None: + raise ValueError + + pool = pool_cls.from_config(self._config, **kwargs) + await pool.setup() + return pool + + class Pool(SetupMixin, PoolBase, Generic[P], ABC): """Base class for Pool implementations in minos""" diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py index 2a565ab84..bf5a1af54 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py @@ -11,6 +11,7 @@ Config, ConfigV2, MinosConfigException, + PoolFactory, ) from tests.utils import ( BASE_PATH, @@ -60,6 +61,7 @@ def test_name(self): def test_injections(self): expected = [ + PoolFactory, FakeLockPool, FakeDatabasePool, FakeBrokerClientPool, @@ -75,9 +77,9 @@ def test_injections(self): ] self.assertEqual(expected, self.config.get_injections()) - def test_injections_not_defined(self): + def test_injections_not_defined(self): # FIXME with patch.object(ConfigV2, "get_by_key", side_effect=MinosConfigException("")): - self.assertEqual(list(), self.config.get_injections()) + self.assertEqual([PoolFactory], self.config.get_injections()) def test_injections_not_injectable(self): side_effect = chain([{"client": "builtins.int"}], cycle([MinosConfigException("")])) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py index 57a9e24c6..42ff0ee0d 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py @@ -6,6 +6,7 @@ from minos.common import ( ConfigV2, + PoolFactory, ) from tests.utils import ( BASE_PATH, @@ -37,6 +38,7 @@ def test_injections_nones(self): config = ConfigV2(self.file_path, interfaces_http={"port": "tests.utils.FakeHttpPort"}) expected = [ + PoolFactory, FakeLockPool, FakeDatabasePool, FakeBrokerClientPool, From 748f335c15c1a91dcf5ebf278e80d35925c93acf Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 31 Mar 2022 20:29:31 +0200 Subject: [PATCH 025/324] Add Konga admin interface --- packages/plugins/minos-kong/tests/docker-compose.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/packages/plugins/minos-kong/tests/docker-compose.yml b/packages/plugins/minos-kong/tests/docker-compose.yml index f807b9044..408b96752 100644 --- a/packages/plugins/minos-kong/tests/docker-compose.yml +++ b/packages/plugins/minos-kong/tests/docker-compose.yml @@ -97,3 +97,15 @@ services: tty: true volumes: - kong_data:/var/lib/postgresql/data + + konga: + image: pantsel/konga + ports: + - 1337:1337 + links: + - kong:kong + container_name: konga + #networks: + # - kong-net + environment: + - NODE_ENV=production From 043854e3d9433a5ef90c848d82a918f0a216a76e Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Thu, 31 Mar 2022 20:47:52 +0200 Subject: [PATCH 026/324] change version --- packages/plugins/minos-kong/HISTORY.md | 4 ++-- .../plugins/minos-kong/minos/plugins/minos_kong/__init__.py | 2 +- packages/plugins/minos-kong/poetry.lock | 6 +++--- packages/plugins/minos-kong/pyproject.toml | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/plugins/minos-kong/HISTORY.md b/packages/plugins/minos-kong/HISTORY.md index 1521d4753..0dfc78464 100644 --- a/packages/plugins/minos-kong/HISTORY.md +++ b/packages/plugins/minos-kong/HISTORY.md @@ -1,5 +1,5 @@ # History -## 0.1.0 (2022-03-30) +## 0.1.0a0 (2022-03-31) -* First Release +* First Alpha release diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/__init__.py b/packages/plugins/minos-kong/minos/plugins/minos_kong/__init__.py index 4c7a7aa16..ade34def9 100644 --- a/packages/plugins/minos-kong/minos/plugins/minos_kong/__init__.py +++ b/packages/plugins/minos-kong/minos/plugins/minos_kong/__init__.py @@ -1,6 +1,6 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.0" +__version__ = "0.1.0a6" from .client import ( MinosKongClient, diff --git a/packages/plugins/minos-kong/poetry.lock b/packages/plugins/minos-kong/poetry.lock index 5f5c584a4..99dbfa891 100644 --- a/packages/plugins/minos-kong/poetry.lock +++ b/packages/plugins/minos-kong/poetry.lock @@ -159,7 +159,7 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.1.0" +version = "8.1.1" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -1034,8 +1034,8 @@ charset-normalizer = [ {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.1.0-py3-none-any.whl", hash = "sha256:19a4baa64da924c5e0cd889aba8e947f280309f1a2ce0947a3e3a7bcb7cc72d6"}, - {file = "click-8.1.0.tar.gz", hash = "sha256:977c213473c7665d3aa092b41ff12063227751c41d7b17165013e10069cc5cd2"}, + {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, + {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, diff --git a/packages/plugins/minos-kong/pyproject.toml b/packages/plugins/minos-kong/pyproject.toml index 6264e9407..a47147d86 100644 --- a/packages/plugins/minos-kong/pyproject.toml +++ b/packages/plugins/minos-kong/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-kong" -version = "0.1.0" +version = "0.1.0a0" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" From e60d8a8ed2bba98ced5571b2d332ddc464077643 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Thu, 31 Mar 2022 21:03:43 +0200 Subject: [PATCH 027/324] added poetry lock and modified dependecies --- packages/plugins/minos-kong/poetry.lock | 430 +++++++++++++++++---- packages/plugins/minos-kong/pyproject.toml | 8 +- 2 files changed, 369 insertions(+), 69 deletions(-) diff --git a/packages/plugins/minos-kong/poetry.lock b/packages/plugins/minos-kong/poetry.lock index 99dbfa891..29f82e8ee 100644 --- a/packages/plugins/minos-kong/poetry.lock +++ b/packages/plugins/minos-kong/poetry.lock @@ -1,6 +1,26 @@ +[[package]] +name = "aiohttp" +version = "3.8.1" +description = "Async http client/server framework (asyncio)" +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +aiosignal = ">=1.1.2" +async-timeout = ">=4.0.0a3,<5.0" +attrs = ">=17.3.0" +charset-normalizer = ">=2.0,<3.0" +frozenlist = ">=1.1.1" +multidict = ">=4.5,<7.0" +yarl = ">=1.0,<2.0" + +[package.extras] +speedups = ["aiodns", "brotli", "cchardet"] + [[package]] name = "aiomisc" -version = "15.7.3" +version = "14.4.6" description = "aiomisc - miscellaneous utils for asyncio" category = "main" optional = false @@ -15,7 +35,7 @@ asgi = ["aiohttp-asgi"] carbon = ["aiocarbon (>=0.15,<1.0)"] contextvars = ["contextvars (>=2.4,<3.0)"] cron = ["croniter (>=0.3.34,<0.4.0)"] -develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-timeout", "coveralls", "croniter (>=0.3.34,<0.4.0)", "fastapi", "freezegun (<1.1)", "mypy (>=0.782,<1.0)", "pylava", "pytest", "pytest-cov (>=3.0,<4.0)", "pytest-freezegun (>=0.4.2,<0.5.0)", "pytest-rst", "pytest-subtests", "rich", "setproctitle", "sphinx-autobuild", "sphinx-intl", "sphinx (>=3.5.1)", "timeout-decorator", "tox (>=2.4)", "types-croniter"] +develop = ["aiocontextvars (==0.2.2)", "aiohttp (<4)", "aiohttp-asgi", "async-timeout", "coverage (==4.5.1)", "coveralls", "croniter (>=0.3.34,<0.4.0)", "fastapi", "freezegun (<1.1)", "mypy (>=0.782,<1.0)", "pylava", "pytest", "pytest-cov (>=2.5.1,<2.6.0)", "pytest-freezegun (>=0.4.2,<0.5.0)", "sphinx (>=3.5.1)", "sphinx-autobuild", "sphinx-intl", "timeout-decorator", "types-croniter", "tox (>=2.4)"] raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] @@ -34,6 +54,17 @@ psycopg2-binary = ">=2.8.4" [package.extras] sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] +[[package]] +name = "aiosignal" +version = "1.2.0" +description = "aiosignal: a list of registered asynchronous callbacks" +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +frozenlist = ">=1.1.0" + [[package]] name = "alabaster" version = "0.7.12" @@ -79,7 +110,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" name = "attrs" version = "21.4.0" description = "Classes Without Boilerplate" -category = "dev" +category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" @@ -281,6 +312,14 @@ mccabe = ">=0.6.0,<0.7.0" pycodestyle = ">=2.8.0,<2.9.0" pyflakes = ">=2.4.0,<2.5.0" +[[package]] +name = "frozenlist" +version = "1.3.0" +description = "A list-like structure which implements collections.abc.MutableSequence" +category = "main" +optional = false +python-versions = ">=3.7" + [[package]] name = "h11" version = "0.12.0" @@ -445,46 +484,38 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.5.3" description = "The common core of the Minos Framework" category = "main" optional = false -python-versions = "^3.9" -develop = true +python-versions = ">=3.9,<4.0" [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" -aiopg = "^1.2.1" -cached-property = "^1.5.2" -dependency-injector = "^4.32.2" -fastavro = "^1.4.0" -lmdb = "^1.2.1" -orjson = "^3.5.2" +aiomisc = ">=14.0.3,<15.0.0" +aiopg = ">=1.2.1,<2.0.0" +cached-property = ">=1.5.2,<2.0.0" +dependency-injector = ">=4.32.2,<5.0.0" +fastavro = ">=1.4.0,<2.0.0" +lmdb = ">=1.2.1,<2.0.0" +orjson = ">=3.5.2,<4.0.0" PyYAML = ">=5.4.1,<7.0.0" -uvloop = "^0.16.0" - -[package.source] -type = "directory" -url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.5.3" description = "The networks core of the Minos Framework" category = "main" optional = false -python-versions = "^3.9" -develop = true +python-versions = ">=3.9,<4.0" [package.dependencies] -aiopg = "^1.2.1" -crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" -psycopg2-binary = "^2.9.3" - -[package.source] -type = "directory" -url = "../../core/minos-microservice-networks" +aiohttp = ">=3.7.4,<4.0.0" +aiomisc = ">=14.0.3,<15.0.0" +aiopg = ">=1.2.1,<2.0.0" +crontab = ">=0.23.0,<0.24.0" +dependency-injector = ">=4.32.2,<5.0.0" +minos-microservice-common = ">=0.5.0,<0.6.0" +orjson = ">=3.6.5,<4.0.0" [[package]] name = "mistune" @@ -494,6 +525,14 @@ category = "dev" optional = false python-versions = "*" +[[package]] +name = "multidict" +version = "6.0.2" +description = "multidict implementation" +category = "main" +optional = false +python-versions = ">=3.7" + [[package]] name = "mypy-extensions" version = "0.4.3" @@ -911,19 +950,6 @@ brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] -[[package]] -name = "uvloop" -version = "0.16.0" -description = "Fast implementation of asyncio event loop on top of libuv" -category = "main" -optional = false -python-versions = ">=3.7" - -[package.extras] -dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)", "aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] -test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] - [[package]] name = "virtualenv" version = "20.14.0" @@ -942,6 +968,18 @@ six = ">=1.9.0,<2" docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] +[[package]] +name = "yarl" +version = "1.7.2" +description = "Yet another URL library" +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +idna = ">=2.0" +multidict = ">=4.0" + [[package]] name = "zipp" version = "3.7.0" @@ -957,17 +995,95 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "6f3959912700b8e1376699eb9a5a8f1b993a35f458368f4b3e2b254b4a37df33" +content-hash = "28a0cea8e8de8fad4b6e9ea3f3debaaeb559b2af4f98b355206d928f3aa706fe" [metadata.files] +aiohttp = [ + {file = "aiohttp-3.8.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1ed0b6477896559f17b9eaeb6d38e07f7f9ffe40b9f0f9627ae8b9926ae260a8"}, + {file = "aiohttp-3.8.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:7dadf3c307b31e0e61689cbf9e06be7a867c563d5a63ce9dca578f956609abf8"}, + {file = "aiohttp-3.8.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:a79004bb58748f31ae1cbe9fa891054baaa46fb106c2dc7af9f8e3304dc30316"}, + {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:12de6add4038df8f72fac606dff775791a60f113a725c960f2bab01d8b8e6b15"}, + {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:6f0d5f33feb5f69ddd57a4a4bd3d56c719a141080b445cbf18f238973c5c9923"}, + {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:eaba923151d9deea315be1f3e2b31cc39a6d1d2f682f942905951f4e40200922"}, + {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:099ebd2c37ac74cce10a3527d2b49af80243e2a4fa39e7bce41617fbc35fa3c1"}, + {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:2e5d962cf7e1d426aa0e528a7e198658cdc8aa4fe87f781d039ad75dcd52c516"}, + {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:fa0ffcace9b3aa34d205d8130f7873fcfefcb6a4dd3dd705b0dab69af6712642"}, + {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:61bfc23df345d8c9716d03717c2ed5e27374e0fe6f659ea64edcd27b4b044cf7"}, + {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:31560d268ff62143e92423ef183680b9829b1b482c011713ae941997921eebc8"}, + {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:01d7bdb774a9acc838e6b8f1d114f45303841b89b95984cbb7d80ea41172a9e3"}, + {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:97ef77eb6b044134c0b3a96e16abcb05ecce892965a2124c566af0fd60f717e2"}, + {file = "aiohttp-3.8.1-cp310-cp310-win32.whl", hash = "sha256:c2aef4703f1f2ddc6df17519885dbfa3514929149d3ff900b73f45998f2532fa"}, + {file = "aiohttp-3.8.1-cp310-cp310-win_amd64.whl", hash = "sha256:713ac174a629d39b7c6a3aa757b337599798da4c1157114a314e4e391cd28e32"}, + {file = "aiohttp-3.8.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:473d93d4450880fe278696549f2e7aed8cd23708c3c1997981464475f32137db"}, + {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99b5eeae8e019e7aad8af8bb314fb908dd2e028b3cdaad87ec05095394cce632"}, + {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3af642b43ce56c24d063325dd2cf20ee012d2b9ba4c3c008755a301aaea720ad"}, + {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c3630c3ef435c0a7c549ba170a0633a56e92629aeed0e707fec832dee313fb7a"}, + {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4a4a4e30bf1edcad13fb0804300557aedd07a92cabc74382fdd0ba6ca2661091"}, + {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6f8b01295e26c68b3a1b90efb7a89029110d3a4139270b24fda961893216c440"}, + {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:a25fa703a527158aaf10dafd956f7d42ac6d30ec80e9a70846253dd13e2f067b"}, + {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:5bfde62d1d2641a1f5173b8c8c2d96ceb4854f54a44c23102e2ccc7e02f003ec"}, + {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:51467000f3647d519272392f484126aa716f747859794ac9924a7aafa86cd411"}, + {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_s390x.whl", hash = "sha256:03a6d5349c9ee8f79ab3ff3694d6ce1cfc3ced1c9d36200cb8f08ba06bd3b782"}, + {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:102e487eeb82afac440581e5d7f8f44560b36cf0bdd11abc51a46c1cd88914d4"}, + {file = "aiohttp-3.8.1-cp36-cp36m-win32.whl", hash = "sha256:4aed991a28ea3ce320dc8ce655875e1e00a11bdd29fe9444dd4f88c30d558602"}, + {file = "aiohttp-3.8.1-cp36-cp36m-win_amd64.whl", hash = "sha256:b0e20cddbd676ab8a64c774fefa0ad787cc506afd844de95da56060348021e96"}, + {file = "aiohttp-3.8.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:37951ad2f4a6df6506750a23f7cbabad24c73c65f23f72e95897bb2cecbae676"}, + {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5c23b1ad869653bc818e972b7a3a79852d0e494e9ab7e1a701a3decc49c20d51"}, + {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:15b09b06dae900777833fe7fc4b4aa426556ce95847a3e8d7548e2d19e34edb8"}, + {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:477c3ea0ba410b2b56b7efb072c36fa91b1e6fc331761798fa3f28bb224830dd"}, + {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:2f2f69dca064926e79997f45b2f34e202b320fd3782f17a91941f7eb85502ee2"}, + {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ef9612483cb35171d51d9173647eed5d0069eaa2ee812793a75373447d487aa4"}, + {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:6d69f36d445c45cda7b3b26afef2fc34ef5ac0cdc75584a87ef307ee3c8c6d00"}, + {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:55c3d1072704d27401c92339144d199d9de7b52627f724a949fc7d5fc56d8b93"}, + {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:b9d00268fcb9f66fbcc7cd9fe423741d90c75ee029a1d15c09b22d23253c0a44"}, + {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:07b05cd3305e8a73112103c834e91cd27ce5b4bd07850c4b4dbd1877d3f45be7"}, + {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:c34dc4958b232ef6188c4318cb7b2c2d80521c9a56c52449f8f93ab7bc2a8a1c"}, + {file = "aiohttp-3.8.1-cp37-cp37m-win32.whl", hash = "sha256:d2f9b69293c33aaa53d923032fe227feac867f81682f002ce33ffae978f0a9a9"}, + {file = "aiohttp-3.8.1-cp37-cp37m-win_amd64.whl", hash = "sha256:6ae828d3a003f03ae31915c31fa684b9890ea44c9c989056fea96e3d12a9fa17"}, + {file = "aiohttp-3.8.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:0c7ebbbde809ff4e970824b2b6cb7e4222be6b95a296e46c03cf050878fc1785"}, + {file = "aiohttp-3.8.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:8b7ef7cbd4fec9a1e811a5de813311ed4f7ac7d93e0fda233c9b3e1428f7dd7b"}, + {file = "aiohttp-3.8.1-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:c3d6a4d0619e09dcd61021debf7059955c2004fa29f48788a3dfaf9c9901a7cd"}, + {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:718626a174e7e467f0558954f94af117b7d4695d48eb980146016afa4b580b2e"}, + {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:589c72667a5febd36f1315aa6e5f56dd4aa4862df295cb51c769d16142ddd7cd"}, + {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2ed076098b171573161eb146afcb9129b5ff63308960aeca4b676d9d3c35e700"}, + {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:086f92daf51a032d062ec5f58af5ca6a44d082c35299c96376a41cbb33034675"}, + {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:11691cf4dc5b94236ccc609b70fec991234e7ef8d4c02dd0c9668d1e486f5abf"}, + {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:31d1e1c0dbf19ebccbfd62eff461518dcb1e307b195e93bba60c965a4dcf1ba0"}, + {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:11a67c0d562e07067c4e86bffc1553f2cf5b664d6111c894671b2b8712f3aba5"}, + {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:bb01ba6b0d3f6c68b89fce7305080145d4877ad3acaed424bae4d4ee75faa950"}, + {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:44db35a9e15d6fe5c40d74952e803b1d96e964f683b5a78c3cc64eb177878155"}, + {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:844a9b460871ee0a0b0b68a64890dae9c415e513db0f4a7e3cab41a0f2fedf33"}, + {file = "aiohttp-3.8.1-cp38-cp38-win32.whl", hash = "sha256:7d08744e9bae2ca9c382581f7dce1273fe3c9bae94ff572c3626e8da5b193c6a"}, + {file = "aiohttp-3.8.1-cp38-cp38-win_amd64.whl", hash = "sha256:04d48b8ce6ab3cf2097b1855e1505181bdd05586ca275f2505514a6e274e8e75"}, + {file = "aiohttp-3.8.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:f5315a2eb0239185af1bddb1abf472d877fede3cc8d143c6cddad37678293237"}, + {file = "aiohttp-3.8.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:a996d01ca39b8dfe77440f3cd600825d05841088fd6bc0144cc6c2ec14cc5f74"}, + {file = "aiohttp-3.8.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:13487abd2f761d4be7c8ff9080de2671e53fff69711d46de703c310c4c9317ca"}, + {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ea302f34477fda3f85560a06d9ebdc7fa41e82420e892fc50b577e35fc6a50b2"}, + {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a2f635ce61a89c5732537a7896b6319a8fcfa23ba09bec36e1b1ac0ab31270d2"}, + {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e999f2d0e12eea01caeecb17b653f3713d758f6dcc770417cf29ef08d3931421"}, + {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0770e2806a30e744b4e21c9d73b7bee18a1cfa3c47991ee2e5a65b887c49d5cf"}, + {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d15367ce87c8e9e09b0f989bfd72dc641bcd04ba091c68cd305312d00962addd"}, + {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:6c7cefb4b0640703eb1069835c02486669312bf2f12b48a748e0a7756d0de33d"}, + {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:71927042ed6365a09a98a6377501af5c9f0a4d38083652bcd2281a06a5976724"}, + {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:28d490af82bc6b7ce53ff31337a18a10498303fe66f701ab65ef27e143c3b0ef"}, + {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:b6613280ccedf24354406caf785db748bebbddcf31408b20c0b48cb86af76866"}, + {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:81e3d8c34c623ca4e36c46524a3530e99c0bc95ed068fd6e9b55cb721d408fb2"}, + {file = "aiohttp-3.8.1-cp39-cp39-win32.whl", hash = "sha256:7187a76598bdb895af0adbd2fb7474d7f6025d170bc0a1130242da817ce9e7d1"}, + {file = "aiohttp-3.8.1-cp39-cp39-win_amd64.whl", hash = "sha256:1c182cb873bc91b411e184dab7a2b664d4fea2743df0e4d57402f7f3fa644bac"}, + {file = "aiohttp-3.8.1.tar.gz", hash = "sha256:fc5471e1a54de15ef71c1bc6ebe80d4dc681ea600e68bfd1cbce40427f0b7578"}, +] aiomisc = [ - {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, - {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, + {file = "aiomisc-14.4.6-py3-none-any.whl", hash = "sha256:beaa248f92acce53857f459499210643274cf06b33c7eb0c9d1f35feaad0d054"}, + {file = "aiomisc-14.4.6.tar.gz", hash = "sha256:a547a94908db9213fd0acde2674973b4a7a986ad82989215f73488903b65746e"}, ] aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, ] +aiosignal = [ + {file = "aiosignal-1.2.0-py3-none-any.whl", hash = "sha256:26e62109036cd181df6e6ad646f91f0dcfd05fe16d0cb924138ff2ab75d64e3a"}, + {file = "aiosignal-1.2.0.tar.gz", hash = "sha256:78ed67db6c7b7ced4f98e495e572106d5c432a93e1ddd1bf475e1dc05f5b7df2"}, +] alabaster = [ {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, @@ -1163,6 +1279,67 @@ flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] +frozenlist = [ + {file = "frozenlist-1.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:d2257aaba9660f78c7b1d8fea963b68f3feffb1a9d5d05a18401ca9eb3e8d0a3"}, + {file = "frozenlist-1.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:4a44ebbf601d7bac77976d429e9bdb5a4614f9f4027777f9e54fd765196e9d3b"}, + {file = "frozenlist-1.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:45334234ec30fc4ea677f43171b18a27505bfb2dba9aca4398a62692c0ea8868"}, + {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:47be22dc27ed933d55ee55845d34a3e4e9f6fee93039e7f8ebadb0c2f60d403f"}, + {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:03a7dd1bfce30216a3f51a84e6dd0e4a573d23ca50f0346634916ff105ba6e6b"}, + {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:691ddf6dc50480ce49f68441f1d16a4c3325887453837036e0fb94736eae1e58"}, + {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:bde99812f237f79eaf3f04ebffd74f6718bbd216101b35ac7955c2d47c17da02"}, + {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6a202458d1298ced3768f5a7d44301e7c86defac162ace0ab7434c2e961166e8"}, + {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b9e3e9e365991f8cc5f5edc1fd65b58b41d0514a6a7ad95ef5c7f34eb49b3d3e"}, + {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:04cb491c4b1c051734d41ea2552fde292f5f3a9c911363f74f39c23659c4af78"}, + {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:436496321dad302b8b27ca955364a439ed1f0999311c393dccb243e451ff66aa"}, + {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:754728d65f1acc61e0f4df784456106e35afb7bf39cfe37227ab00436fb38676"}, + {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:6eb275c6385dd72594758cbe96c07cdb9bd6becf84235f4a594bdf21e3596c9d"}, + {file = "frozenlist-1.3.0-cp310-cp310-win32.whl", hash = "sha256:e30b2f9683812eb30cf3f0a8e9f79f8d590a7999f731cf39f9105a7c4a39489d"}, + {file = "frozenlist-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:f7353ba3367473d1d616ee727945f439e027f0bb16ac1a750219a8344d1d5d3c"}, + {file = "frozenlist-1.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:88aafd445a233dbbf8a65a62bc3249a0acd0d81ab18f6feb461cc5a938610d24"}, + {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4406cfabef8f07b3b3af0f50f70938ec06d9f0fc26cbdeaab431cbc3ca3caeaa"}, + {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:8cf829bd2e2956066dd4de43fd8ec881d87842a06708c035b37ef632930505a2"}, + {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:603b9091bd70fae7be28bdb8aa5c9990f4241aa33abb673390a7f7329296695f"}, + {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:25af28b560e0c76fa41f550eacb389905633e7ac02d6eb3c09017fa1c8cdfde1"}, + {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:94c7a8a9fc9383b52c410a2ec952521906d355d18fccc927fca52ab575ee8b93"}, + {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:65bc6e2fece04e2145ab6e3c47428d1bbc05aede61ae365b2c1bddd94906e478"}, + {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:3f7c935c7b58b0d78c0beea0c7358e165f95f1fd8a7e98baa40d22a05b4a8141"}, + {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:bd89acd1b8bb4f31b47072615d72e7f53a948d302b7c1d1455e42622de180eae"}, + {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:6983a31698490825171be44ffbafeaa930ddf590d3f051e397143a5045513b01"}, + {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:adac9700675cf99e3615eb6a0eb5e9f5a4143c7d42c05cea2e7f71c27a3d0846"}, + {file = "frozenlist-1.3.0-cp37-cp37m-win32.whl", hash = "sha256:0c36e78b9509e97042ef869c0e1e6ef6429e55817c12d78245eb915e1cca7468"}, + {file = "frozenlist-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:57f4d3f03a18facacb2a6bcd21bccd011e3b75d463dc49f838fd699d074fabd1"}, + {file = "frozenlist-1.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:8c905a5186d77111f02144fab5b849ab524f1e876a1e75205cd1386a9be4b00a"}, + {file = "frozenlist-1.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:b5009062d78a8c6890d50b4e53b0ddda31841b3935c1937e2ed8c1bda1c7fb9d"}, + {file = "frozenlist-1.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:2fdc3cd845e5a1f71a0c3518528bfdbfe2efaf9886d6f49eacc5ee4fd9a10953"}, + {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92e650bd09b5dda929523b9f8e7f99b24deac61240ecc1a32aeba487afcd970f"}, + {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:40dff8962b8eba91fd3848d857203f0bd704b5f1fa2b3fc9af64901a190bba08"}, + {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:768efd082074bb203c934e83a61654ed4931ef02412c2fbdecea0cff7ecd0274"}, + {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:006d3595e7d4108a12025ddf415ae0f6c9e736e726a5db0183326fd191b14c5e"}, + {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:871d42623ae15eb0b0e9df65baeee6976b2e161d0ba93155411d58ff27483ad8"}, + {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:aff388be97ef2677ae185e72dc500d19ecaf31b698986800d3fc4f399a5e30a5"}, + {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:9f892d6a94ec5c7b785e548e42722e6f3a52f5f32a8461e82ac3e67a3bd073f1"}, + {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:e982878792c971cbd60ee510c4ee5bf089a8246226dea1f2138aa0bb67aff148"}, + {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:c6c321dd013e8fc20735b92cb4892c115f5cdb82c817b1e5b07f6b95d952b2f0"}, + {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:30530930410855c451bea83f7b272fb1c495ed9d5cc72895ac29e91279401db3"}, + {file = "frozenlist-1.3.0-cp38-cp38-win32.whl", hash = "sha256:40ec383bc194accba825fbb7d0ef3dda5736ceab2375462f1d8672d9f6b68d07"}, + {file = "frozenlist-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:f20baa05eaa2bcd5404c445ec51aed1c268d62600362dc6cfe04fae34a424bd9"}, + {file = "frozenlist-1.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:0437fe763fb5d4adad1756050cbf855bbb2bf0d9385c7bb13d7a10b0dd550486"}, + {file = "frozenlist-1.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b684c68077b84522b5c7eafc1dc735bfa5b341fb011d5552ebe0968e22ed641c"}, + {file = "frozenlist-1.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:93641a51f89473837333b2f8100f3f89795295b858cd4c7d4a1f18e299dc0a4f"}, + {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d6d32ff213aef0fd0bcf803bffe15cfa2d4fde237d1d4838e62aec242a8362fa"}, + {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:31977f84828b5bb856ca1eb07bf7e3a34f33a5cddce981d880240ba06639b94d"}, + {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3c62964192a1c0c30b49f403495911298810bada64e4f03249ca35a33ca0417a"}, + {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:4eda49bea3602812518765810af732229b4291d2695ed24a0a20e098c45a707b"}, + {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:acb267b09a509c1df5a4ca04140da96016f40d2ed183cdc356d237286c971b51"}, + {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:e1e26ac0a253a2907d654a37e390904426d5ae5483150ce3adedb35c8c06614a"}, + {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:f96293d6f982c58ebebb428c50163d010c2f05de0cde99fd681bfdc18d4b2dc2"}, + {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:e84cb61b0ac40a0c3e0e8b79c575161c5300d1d89e13c0e02f76193982f066ed"}, + {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:ff9310f05b9d9c5c4dd472983dc956901ee6cb2c3ec1ab116ecdde25f3ce4951"}, + {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:d26b650b71fdc88065b7a21f8ace70175bcf3b5bdba5ea22df4bfd893e795a3b"}, + {file = "frozenlist-1.3.0-cp39-cp39-win32.whl", hash = "sha256:01a73627448b1f2145bddb6e6c2259988bb8aee0fb361776ff8604b99616cd08"}, + {file = "frozenlist-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:772965f773757a6026dea111a15e6e2678fbd6216180f82a48a40b27de1ee2ab"}, + {file = "frozenlist-1.3.0.tar.gz", hash = "sha256:ce6f2ba0edb7b0c1d8976565298ad2deba6f8064d2bebb6ffce2ca896eb35b0b"}, +] h11 = [ {file = "h11-0.12.0-py3-none-any.whl", hash = "sha256:36a3cb8c0a032f56e2da7084577878a035d3b61d104230d4bd49c0c6b555a9c6"}, {file = "h11-0.12.0.tar.gz", hash = "sha256:47222cb6067e4a307d535814917cd98fd0a57b6788ce715755fa2b6c28b56042"}, @@ -1282,12 +1459,79 @@ mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] -minos-microservice-common = [] -minos-microservice-networks = [] +minos-microservice-common = [ + {file = "minos-microservice-common-0.5.3.tar.gz", hash = "sha256:91e927504c35646626fb4597f5bd65566bc055882ddd3af42cba24ca5fc4c9af"}, + {file = "minos_microservice_common-0.5.3-py3-none-any.whl", hash = "sha256:9eea7eef5abd73a844a4ef12649d8f10323b561e27db20178398e41887e42e85"}, +] +minos-microservice-networks = [ + {file = "minos-microservice-networks-0.5.3.tar.gz", hash = "sha256:9bbad95410d36942ac69a5b7fc5500de24f26e4dff03e894a351c2902d38b5b9"}, + {file = "minos_microservice_networks-0.5.3-py3-none-any.whl", hash = "sha256:3eeef3972cac838414118347511f6d0e0a75d25af374b75af684e6d5d8cb7750"}, +] mistune = [ {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, ] +multidict = [ + {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:0b9e95a740109c6047602f4db4da9949e6c5945cefbad34a1299775ddc9a62e2"}, + {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ac0e27844758d7177989ce406acc6a83c16ed4524ebc363c1f748cba184d89d3"}, + {file = "multidict-6.0.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:041b81a5f6b38244b34dc18c7b6aba91f9cdaf854d9a39e5ff0b58e2b5773b9c"}, + {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5fdda29a3c7e76a064f2477c9aab1ba96fd94e02e386f1e665bca1807fc5386f"}, + {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3368bf2398b0e0fcbf46d85795adc4c259299fec50c1416d0f77c0a843a3eed9"}, + {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f4f052ee022928d34fe1f4d2bc743f32609fb79ed9c49a1710a5ad6b2198db20"}, + {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:225383a6603c086e6cef0f2f05564acb4f4d5f019a4e3e983f572b8530f70c88"}, + {file = "multidict-6.0.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:50bd442726e288e884f7be9071016c15a8742eb689a593a0cac49ea093eef0a7"}, + {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:47e6a7e923e9cada7c139531feac59448f1f47727a79076c0b1ee80274cd8eee"}, + {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:0556a1d4ea2d949efe5fd76a09b4a82e3a4a30700553a6725535098d8d9fb672"}, + {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:626fe10ac87851f4cffecee161fc6f8f9853f0f6f1035b59337a51d29ff3b4f9"}, + {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:8064b7c6f0af936a741ea1efd18690bacfbae4078c0c385d7c3f611d11f0cf87"}, + {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:2d36e929d7f6a16d4eb11b250719c39560dd70545356365b494249e2186bc389"}, + {file = "multidict-6.0.2-cp310-cp310-win32.whl", hash = "sha256:fcb91630817aa8b9bc4a74023e4198480587269c272c58b3279875ed7235c293"}, + {file = "multidict-6.0.2-cp310-cp310-win_amd64.whl", hash = "sha256:8cbf0132f3de7cc6c6ce00147cc78e6439ea736cee6bca4f068bcf892b0fd658"}, + {file = "multidict-6.0.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:05f6949d6169878a03e607a21e3b862eaf8e356590e8bdae4227eedadacf6e51"}, + {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2c2e459f7050aeb7c1b1276763364884595d47000c1cddb51764c0d8976e608"}, + {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d0509e469d48940147e1235d994cd849a8f8195e0bca65f8f5439c56e17872a3"}, + {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:514fe2b8d750d6cdb4712346a2c5084a80220821a3e91f3f71eec11cf8d28fd4"}, + {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19adcfc2a7197cdc3987044e3f415168fc5dc1f720c932eb1ef4f71a2067e08b"}, + {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b9d153e7f1f9ba0b23ad1568b3b9e17301e23b042c23870f9ee0522dc5cc79e8"}, + {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:aef9cc3d9c7d63d924adac329c33835e0243b5052a6dfcbf7732a921c6e918ba"}, + {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:4571f1beddff25f3e925eea34268422622963cd8dc395bb8778eb28418248e43"}, + {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:d48b8ee1d4068561ce8033d2c344cf5232cb29ee1a0206a7b828c79cbc5982b8"}, + {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:45183c96ddf61bf96d2684d9fbaf6f3564d86b34cb125761f9a0ef9e36c1d55b"}, + {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:75bdf08716edde767b09e76829db8c1e5ca9d8bb0a8d4bd94ae1eafe3dac5e15"}, + {file = "multidict-6.0.2-cp37-cp37m-win32.whl", hash = "sha256:a45e1135cb07086833ce969555df39149680e5471c04dfd6a915abd2fc3f6dbc"}, + {file = "multidict-6.0.2-cp37-cp37m-win_amd64.whl", hash = "sha256:6f3cdef8a247d1eafa649085812f8a310e728bdf3900ff6c434eafb2d443b23a"}, + {file = "multidict-6.0.2-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:0327292e745a880459ef71be14e709aaea2f783f3537588fb4ed09b6c01bca60"}, + {file = "multidict-6.0.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:e875b6086e325bab7e680e4316d667fc0e5e174bb5611eb16b3ea121c8951b86"}, + {file = "multidict-6.0.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:feea820722e69451743a3d56ad74948b68bf456984d63c1a92e8347b7b88452d"}, + {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9cc57c68cb9139c7cd6fc39f211b02198e69fb90ce4bc4a094cf5fe0d20fd8b0"}, + {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:497988d6b6ec6ed6f87030ec03280b696ca47dbf0648045e4e1d28b80346560d"}, + {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:89171b2c769e03a953d5969b2f272efa931426355b6c0cb508022976a17fd376"}, + {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:684133b1e1fe91eda8fa7447f137c9490a064c6b7f392aa857bba83a28cfb693"}, + {file = "multidict-6.0.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:fd9fc9c4849a07f3635ccffa895d57abce554b467d611a5009ba4f39b78a8849"}, + {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:e07c8e79d6e6fd37b42f3250dba122053fddb319e84b55dd3a8d6446e1a7ee49"}, + {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:4070613ea2227da2bfb2c35a6041e4371b0af6b0be57f424fe2318b42a748516"}, + {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:47fbeedbf94bed6547d3aa632075d804867a352d86688c04e606971595460227"}, + {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:5774d9218d77befa7b70d836004a768fb9aa4fdb53c97498f4d8d3f67bb9cfa9"}, + {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:2957489cba47c2539a8eb7ab32ff49101439ccf78eab724c828c1a54ff3ff98d"}, + {file = "multidict-6.0.2-cp38-cp38-win32.whl", hash = "sha256:e5b20e9599ba74391ca0cfbd7b328fcc20976823ba19bc573983a25b32e92b57"}, + {file = "multidict-6.0.2-cp38-cp38-win_amd64.whl", hash = "sha256:8004dca28e15b86d1b1372515f32eb6f814bdf6f00952699bdeb541691091f96"}, + {file = "multidict-6.0.2-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:2e4a0785b84fb59e43c18a015ffc575ba93f7d1dbd272b4cdad9f5134b8a006c"}, + {file = "multidict-6.0.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:6701bf8a5d03a43375909ac91b6980aea74b0f5402fbe9428fc3f6edf5d9677e"}, + {file = "multidict-6.0.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:a007b1638e148c3cfb6bf0bdc4f82776cef0ac487191d093cdc316905e504071"}, + {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:07a017cfa00c9890011628eab2503bee5872f27144936a52eaab449be5eaf032"}, + {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c207fff63adcdf5a485969131dc70e4b194327666b7e8a87a97fbc4fd80a53b2"}, + {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:373ba9d1d061c76462d74e7de1c0c8e267e9791ee8cfefcf6b0b2495762c370c"}, + {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bfba7c6d5d7c9099ba21f84662b037a0ffd4a5e6b26ac07d19e423e6fdf965a9"}, + {file = "multidict-6.0.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:19d9bad105dfb34eb539c97b132057a4e709919ec4dd883ece5838bcbf262b80"}, + {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:de989b195c3d636ba000ee4281cd03bb1234635b124bf4cd89eeee9ca8fcb09d"}, + {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:7c40b7bbece294ae3a87c1bc2abff0ff9beef41d14188cda94ada7bcea99b0fb"}, + {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:d16cce709ebfadc91278a1c005e3c17dd5f71f5098bfae1035149785ea6e9c68"}, + {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:a2c34a93e1d2aa35fbf1485e5010337c72c6791407d03aa5f4eed920343dd360"}, + {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:feba80698173761cddd814fa22e88b0661e98cb810f9f986c54aa34d281e4937"}, + {file = "multidict-6.0.2-cp39-cp39-win32.whl", hash = "sha256:23b616fdc3c74c9fe01d76ce0d1ce872d2d396d8fa8e4899398ad64fb5aa214a"}, + {file = "multidict-6.0.2-cp39-cp39-win_amd64.whl", hash = "sha256:4bae31803d708f6f15fd98be6a6ac0b6958fcf68fda3c77a048a4f9073704aae"}, + {file = "multidict-6.0.2.tar.gz", hash = "sha256:5ff3bd75f38e4c43f1f470f2df7a4d430b821c4ce22be384e1459cb57d6bb013"}, +] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, @@ -1551,28 +1795,84 @@ urllib3 = [ {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, ] -uvloop = [ - {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, - {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, - {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:bd53f7f5db562f37cd64a3af5012df8cac2c464c97e732ed556800129505bd64"}, - {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:772206116b9b57cd625c8a88f2413df2fcfd0b496eb188b82a43bed7af2c2ec9"}, - {file = "uvloop-0.16.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:b572256409f194521a9895aef274cea88731d14732343da3ecdb175228881638"}, - {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:04ff57aa137230d8cc968f03481176041ae789308b4d5079118331ab01112450"}, - {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3a19828c4f15687675ea912cc28bbcb48e9bb907c801873bd1519b96b04fb805"}, - {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e814ac2c6f9daf4c36eb8e85266859f42174a4ff0d71b99405ed559257750382"}, - {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:bd8f42ea1ea8f4e84d265769089964ddda95eb2bb38b5cbe26712b0616c3edee"}, - {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:647e481940379eebd314c00440314c81ea547aa636056f554d491e40503c8464"}, - {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e0d26fa5875d43ddbb0d9d79a447d2ace4180d9e3239788208527c4784f7cab"}, - {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:6ccd57ae8db17d677e9e06192e9c9ec4bd2066b77790f9aa7dede2cc4008ee8f"}, - {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:089b4834fd299d82d83a25e3335372f12117a7d38525217c2258e9b9f4578897"}, - {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98d117332cc9e5ea8dfdc2b28b0a23f60370d02e1395f88f40d1effd2cb86c4f"}, - {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, - {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, -] virtualenv = [ {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, ] +yarl = [ + {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:f2a8508f7350512434e41065684076f640ecce176d262a7d54f0da41d99c5a95"}, + {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:da6df107b9ccfe52d3a48165e48d72db0eca3e3029b5b8cb4fe6ee3cb870ba8b"}, + {file = "yarl-1.7.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:a1d0894f238763717bdcfea74558c94e3bc34aeacd3351d769460c1a586a8b05"}, + {file = "yarl-1.7.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfe4b95b7e00c6635a72e2d00b478e8a28bfb122dc76349a06e20792eb53a523"}, + {file = "yarl-1.7.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c145ab54702334c42237a6c6c4cc08703b6aa9b94e2f227ceb3d477d20c36c63"}, + {file = "yarl-1.7.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1ca56f002eaf7998b5fcf73b2421790da9d2586331805f38acd9997743114e98"}, + {file = "yarl-1.7.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:1d3d5ad8ea96bd6d643d80c7b8d5977b4e2fb1bab6c9da7322616fd26203d125"}, + {file = "yarl-1.7.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:167ab7f64e409e9bdd99333fe8c67b5574a1f0495dcfd905bc7454e766729b9e"}, + {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:95a1873b6c0dd1c437fb3bb4a4aaa699a48c218ac7ca1e74b0bee0ab16c7d60d"}, + {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:6152224d0a1eb254f97df3997d79dadd8bb2c1a02ef283dbb34b97d4f8492d23"}, + {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:5bb7d54b8f61ba6eee541fba4b83d22b8a046b4ef4d8eb7f15a7e35db2e1e245"}, + {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:9c1f083e7e71b2dd01f7cd7434a5f88c15213194df38bc29b388ccdf1492b739"}, + {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:f44477ae29025d8ea87ec308539f95963ffdc31a82f42ca9deecf2d505242e72"}, + {file = "yarl-1.7.2-cp310-cp310-win32.whl", hash = "sha256:cff3ba513db55cc6a35076f32c4cdc27032bd075c9faef31fec749e64b45d26c"}, + {file = "yarl-1.7.2-cp310-cp310-win_amd64.whl", hash = "sha256:c9c6d927e098c2d360695f2e9d38870b2e92e0919be07dbe339aefa32a090265"}, + {file = "yarl-1.7.2-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:9b4c77d92d56a4c5027572752aa35082e40c561eec776048330d2907aead891d"}, + {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c01a89a44bb672c38f42b49cdb0ad667b116d731b3f4c896f72302ff77d71656"}, + {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c19324a1c5399b602f3b6e7db9478e5b1adf5cf58901996fc973fe4fccd73eed"}, + {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3abddf0b8e41445426d29f955b24aeecc83fa1072be1be4e0d194134a7d9baee"}, + {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:6a1a9fe17621af43e9b9fcea8bd088ba682c8192d744b386ee3c47b56eaabb2c"}, + {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:8b0915ee85150963a9504c10de4e4729ae700af11df0dc5550e6587ed7891e92"}, + {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:29e0656d5497733dcddc21797da5a2ab990c0cb9719f1f969e58a4abac66234d"}, + {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:bf19725fec28452474d9887a128e98dd67eee7b7d52e932e6949c532d820dc3b"}, + {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:d6f3d62e16c10e88d2168ba2d065aa374e3c538998ed04996cd373ff2036d64c"}, + {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_s390x.whl", hash = "sha256:ac10bbac36cd89eac19f4e51c032ba6b412b3892b685076f4acd2de18ca990aa"}, + {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:aa32aaa97d8b2ed4e54dc65d241a0da1c627454950f7d7b1f95b13985afd6c5d"}, + {file = "yarl-1.7.2-cp36-cp36m-win32.whl", hash = "sha256:87f6e082bce21464857ba58b569370e7b547d239ca22248be68ea5d6b51464a1"}, + {file = "yarl-1.7.2-cp36-cp36m-win_amd64.whl", hash = "sha256:ac35ccde589ab6a1870a484ed136d49a26bcd06b6a1c6397b1967ca13ceb3913"}, + {file = "yarl-1.7.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a467a431a0817a292121c13cbe637348b546e6ef47ca14a790aa2fa8cc93df63"}, + {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6ab0c3274d0a846840bf6c27d2c60ba771a12e4d7586bf550eefc2df0b56b3b4"}, + {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d260d4dc495c05d6600264a197d9d6f7fc9347f21d2594926202fd08cf89a8ba"}, + {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:fc4dd8b01a8112809e6b636b00f487846956402834a7fd59d46d4f4267181c41"}, + {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:c1164a2eac148d85bbdd23e07dfcc930f2e633220f3eb3c3e2a25f6148c2819e"}, + {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:67e94028817defe5e705079b10a8438b8cb56e7115fa01640e9c0bb3edf67332"}, + {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:89ccbf58e6a0ab89d487c92a490cb5660d06c3a47ca08872859672f9c511fc52"}, + {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:8cce6f9fa3df25f55521fbb5c7e4a736683148bcc0c75b21863789e5185f9185"}, + {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:211fcd65c58bf250fb994b53bc45a442ddc9f441f6fec53e65de8cba48ded986"}, + {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:c10ea1e80a697cf7d80d1ed414b5cb8f1eec07d618f54637067ae3c0334133c4"}, + {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:52690eb521d690ab041c3919666bea13ab9fbff80d615ec16fa81a297131276b"}, + {file = "yarl-1.7.2-cp37-cp37m-win32.whl", hash = "sha256:695ba021a9e04418507fa930d5f0704edbce47076bdcfeeaba1c83683e5649d1"}, + {file = "yarl-1.7.2-cp37-cp37m-win_amd64.whl", hash = "sha256:c17965ff3706beedafd458c452bf15bac693ecd146a60a06a214614dc097a271"}, + {file = "yarl-1.7.2-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:fce78593346c014d0d986b7ebc80d782b7f5e19843ca798ed62f8e3ba8728576"}, + {file = "yarl-1.7.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:c2a1ac41a6aa980db03d098a5531f13985edcb451bcd9d00670b03129922cd0d"}, + {file = "yarl-1.7.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:39d5493c5ecd75c8093fa7700a2fb5c94fe28c839c8e40144b7ab7ccba6938c8"}, + {file = "yarl-1.7.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1eb6480ef366d75b54c68164094a6a560c247370a68c02dddb11f20c4c6d3c9d"}, + {file = "yarl-1.7.2-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:5ba63585a89c9885f18331a55d25fe81dc2d82b71311ff8bd378fc8004202ff6"}, + {file = "yarl-1.7.2-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e39378894ee6ae9f555ae2de332d513a5763276a9265f8e7cbaeb1b1ee74623a"}, + {file = "yarl-1.7.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:c0910c6b6c31359d2f6184828888c983d54d09d581a4a23547a35f1d0b9484b1"}, + {file = "yarl-1.7.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6feca8b6bfb9eef6ee057628e71e1734caf520a907b6ec0d62839e8293e945c0"}, + {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:8300401dc88cad23f5b4e4c1226f44a5aa696436a4026e456fe0e5d2f7f486e6"}, + {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:788713c2896f426a4e166b11f4ec538b5736294ebf7d5f654ae445fd44270832"}, + {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:fd547ec596d90c8676e369dd8a581a21227fe9b4ad37d0dc7feb4ccf544c2d59"}, + {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:737e401cd0c493f7e3dd4db72aca11cfe069531c9761b8ea474926936b3c57c8"}, + {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:baf81561f2972fb895e7844882898bda1eef4b07b5b385bcd308d2098f1a767b"}, + {file = "yarl-1.7.2-cp38-cp38-win32.whl", hash = "sha256:ede3b46cdb719c794427dcce9d8beb4abe8b9aa1e97526cc20de9bd6583ad1ef"}, + {file = "yarl-1.7.2-cp38-cp38-win_amd64.whl", hash = "sha256:cc8b7a7254c0fc3187d43d6cb54b5032d2365efd1df0cd1749c0c4df5f0ad45f"}, + {file = "yarl-1.7.2-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:580c1f15500e137a8c37053e4cbf6058944d4c114701fa59944607505c2fe3a0"}, + {file = "yarl-1.7.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:3ec1d9a0d7780416e657f1e405ba35ec1ba453a4f1511eb8b9fbab81cb8b3ce1"}, + {file = "yarl-1.7.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:3bf8cfe8856708ede6a73907bf0501f2dc4e104085e070a41f5d88e7faf237f3"}, + {file = "yarl-1.7.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1be4bbb3d27a4e9aa5f3df2ab61e3701ce8fcbd3e9846dbce7c033a7e8136746"}, + {file = "yarl-1.7.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:534b047277a9a19d858cde163aba93f3e1677d5acd92f7d10ace419d478540de"}, + {file = "yarl-1.7.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c6ddcd80d79c96eb19c354d9dca95291589c5954099836b7c8d29278a7ec0bda"}, + {file = "yarl-1.7.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:9bfcd43c65fbb339dc7086b5315750efa42a34eefad0256ba114cd8ad3896f4b"}, + {file = "yarl-1.7.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f64394bd7ceef1237cc604b5a89bf748c95982a84bcd3c4bbeb40f685c810794"}, + {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:044daf3012e43d4b3538562da94a88fb12a6490652dbc29fb19adfa02cf72eac"}, + {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:368bcf400247318382cc150aaa632582d0780b28ee6053cd80268c7e72796dec"}, + {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:bab827163113177aee910adb1f48ff7af31ee0289f434f7e22d10baf624a6dfe"}, + {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:0cba38120db72123db7c58322fa69e3c0efa933040ffb586c3a87c063ec7cae8"}, + {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:59218fef177296451b23214c91ea3aba7858b4ae3306dde120224cfe0f7a6ee8"}, + {file = "yarl-1.7.2-cp39-cp39-win32.whl", hash = "sha256:1edc172dcca3f11b38a9d5c7505c83c1913c0addc99cd28e993efeaafdfaa18d"}, + {file = "yarl-1.7.2-cp39-cp39-win_amd64.whl", hash = "sha256:797c2c412b04403d2da075fb93c123df35239cd7b4cc4e0cd9e5839b73f52c58"}, + {file = "yarl-1.7.2.tar.gz", hash = "sha256:45399b46d60c253327a460e99856752009fcee5f5d3c80b2f7c0cae1c38d56dd"}, +] zipp = [ {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, diff --git a/packages/plugins/minos-kong/pyproject.toml b/packages/plugins/minos-kong/pyproject.toml index a47147d86..b6b24fa39 100644 --- a/packages/plugins/minos-kong/pyproject.toml +++ b/packages/plugins/minos-kong/pyproject.toml @@ -31,13 +31,13 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.5.0" +minos-microservice-networks = "^0.5.0" httpx = "^0.22.0" [tool.poetry.dev-dependencies] -minos-microservice-common = { path = "../../core/minos-microservice-common", develop = true } -minos-microservice-networks = { path = "../../core/minos-microservice-networks", develop = true } +minos-microservice-common = "^0.5.0" +minos-microservice-networks = "^0.5.0" black = "^22.1" isort = "^5.8.0" pytest = "^6.2.4" From 004e9e67e6ca5b5e274490f0abad4d79f6786739 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 31 Mar 2022 21:07:47 +0200 Subject: [PATCH 028/324] Pass strip_path to kong subscription --- packages/plugins/minos-kong/minos/plugins/minos_kong/client.py | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py b/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py index f5e102944..d52027cd3 100644 --- a/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py +++ b/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py @@ -75,6 +75,7 @@ async def subscribe( "methods": [endpoint["method"]], "paths": [endpointClass.path_as_str], "service": {"id": content_service["id"]}, + "strip_path": False } fn = partial(self._subscribe_routes, self.route, data) response = await self.with_circuit_breaker(fn) # send the route request From f5e82c435fe6f540ffd2a9bb3a7daadad8b0d902 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Apr 2022 04:07:04 +0000 Subject: [PATCH 029/324] Bump black in /packages/core/minos-microservice-cqrs Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../core/minos-microservice-cqrs/poetry.lock | 52 +++++++++---------- .../minos-microservice-cqrs/pyproject.toml | 2 +- 2 files changed, 27 insertions(+), 27 deletions(-) diff --git a/packages/core/minos-microservice-cqrs/poetry.lock b/packages/core/minos-microservice-cqrs/poetry.lock index 270a6d262..f56c492f1 100644 --- a/packages/core/minos-microservice-cqrs/poetry.lock +++ b/packages/core/minos-microservice-cqrs/poetry.lock @@ -85,7 +85,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +96,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -890,7 +890,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "23501a6766a4dd4ee55a8b51c4860646b8408e31948d63ad9517a99f1b6d4894" +content-hash = "b54e7783b6e7f94388d141829c72e622d6b77191bdde3df6acb53d9f4b657f39" [metadata.files] aiomisc = [ @@ -922,29 +922,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index 29c04e203..970e00569 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -39,7 +39,7 @@ minos-microservice-networks = "^0.6.0" minos-microservice-common = { path = "../minos-microservice-common", develop = true } minos-microservice-networks = { path = "../minos-microservice-networks", develop = true } minos-microservice-aggregate = { path = "../minos-microservice-aggregate", develop = true } -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From 65735321ae1bc3f8381ebcb723e2991f53284d2c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Apr 2022 04:07:07 +0000 Subject: [PATCH 030/324] Bump black in /packages/core/minos-microservice-aggregate Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../minos-microservice-aggregate/poetry.lock | 52 +++++++++---------- .../pyproject.toml | 2 +- 2 files changed, 27 insertions(+), 27 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/poetry.lock b/packages/core/minos-microservice-aggregate/poetry.lock index 16f003c05..c0edc7a10 100644 --- a/packages/core/minos-microservice-aggregate/poetry.lock +++ b/packages/core/minos-microservice-aggregate/poetry.lock @@ -85,7 +85,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +96,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -871,7 +871,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "7371da2d5d13ab97d2bd9539bab6c57260134ac0a0859728f2f9a685323002ad" +content-hash = "595b8281b98245ff9fbf794b8aeb92a9ff554d5af9aede9642fcd51485952dc7" [metadata.files] aiomisc = [ @@ -903,29 +903,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index bc41cf257..bd10fb0b8 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -39,7 +39,7 @@ psycopg2-binary = "^2.9.3" [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../minos-microservice-common", develop = true } minos-microservice-networks = { path = "../minos-microservice-networks", develop = true } -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From cbd19a9dd65f9490267f661aef298e186a445991 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Apr 2022 04:07:10 +0000 Subject: [PATCH 031/324] Bump black in /packages/core/minos-microservice-saga Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../core/minos-microservice-saga/poetry.lock | 52 +++++++++---------- .../minos-microservice-saga/pyproject.toml | 2 +- 2 files changed, 27 insertions(+), 27 deletions(-) diff --git a/packages/core/minos-microservice-saga/poetry.lock b/packages/core/minos-microservice-saga/poetry.lock index 8cf474bb3..094d01632 100644 --- a/packages/core/minos-microservice-saga/poetry.lock +++ b/packages/core/minos-microservice-saga/poetry.lock @@ -85,7 +85,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +96,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -890,7 +890,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "f59b3c5c588ce969df14fed260965c6573d9ab3ba6e755966d45736cf3aeb3c7" +content-hash = "7164ecfa0b42883ace81248af84523e575b0a5814f99541de7800401251a10ac" [metadata.files] aiomisc = [ @@ -922,29 +922,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index d84cb5294..b97d55c84 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -40,7 +40,7 @@ cached-property = "^1.5.2" minos-microservice-common = { path = "../minos-microservice-common", develop = true } minos-microservice-networks = { path = "../minos-microservice-networks", develop = true } minos-microservice-aggregate = { path = "../minos-microservice-aggregate", develop = true } -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From 73ebe216110b1a5e4bd3d550acd70767e5a36f36 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Apr 2022 04:07:40 +0000 Subject: [PATCH 032/324] Bump black in /packages/core/minos-microservice-common Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../minos-microservice-common/poetry.lock | 52 +++++++++---------- .../minos-microservice-common/pyproject.toml | 2 +- 2 files changed, 27 insertions(+), 27 deletions(-) diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index 62682cf99..c6ca07a7a 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -85,7 +85,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +96,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -820,7 +820,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "fbf86feb57cef7a80f0568f8da50f945ebeb84d401d32fa5a3bde0bac05febda" +content-hash = "5753a21e12b21b9eec1a7188527e9f17ec7ff624b2796e1b8b413a8beed30948" [metadata.files] aiomisc = [ @@ -852,29 +852,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index 22b569afe..7cdcfb696 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -42,7 +42,7 @@ cached-property = "^1.5.2" uvloop = "^0.16.0" [tool.poetry.dev-dependencies] -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From c8922f85d72da0e0f28186d4fdb8de5c943913ed Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Apr 2022 04:08:18 +0000 Subject: [PATCH 033/324] Bump dependency-injector in /packages/core/minos-microservice-common Bumps [dependency-injector](https://github.com/ets-labs/python-dependency-injector) from 4.39.0 to 4.39.1. - [Release notes](https://github.com/ets-labs/python-dependency-injector/releases) - [Commits](https://github.com/ets-labs/python-dependency-injector/compare/4.39.0...4.39.1) --- updated-dependencies: - dependency-name: dependency-injector dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- .../minos-microservice-common/poetry.lock | 74 +++++++++---------- 1 file changed, 37 insertions(+), 37 deletions(-) diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index 62682cf99..871f322f0 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -186,7 +186,7 @@ toml = ["tomli"] [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -948,42 +948,42 @@ coverage = [ {file = "coverage-6.3.2.tar.gz", hash = "sha256:03e2a7826086b91ef345ff18742ee9fc47a6839ccd517061ef8fa1976e652ce9"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] distlib = [ {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, From 08ae1b7c7faa438f57ad7f1f3a3fdf110282e88a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Apr 2022 04:08:23 +0000 Subject: [PATCH 034/324] Bump black in /packages/core/minos-microservice-networks Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../minos-microservice-networks/poetry.lock | 52 +++++++++---------- .../pyproject.toml | 2 +- 2 files changed, 27 insertions(+), 27 deletions(-) diff --git a/packages/core/minos-microservice-networks/poetry.lock b/packages/core/minos-microservice-networks/poetry.lock index b0100b80f..2de25efbd 100644 --- a/packages/core/minos-microservice-networks/poetry.lock +++ b/packages/core/minos-microservice-networks/poetry.lock @@ -85,7 +85,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +96,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -852,7 +852,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "ea88425476960ab086eadc6616f36d6cbdc2e2e92e95c4a1cd2f5a4ae7907738" +content-hash = "d5f8ad9c8522f5daf4ab000f252e1c0d0dd602adbb8f1976760afb2ed1322def" [metadata.files] aiomisc = [ @@ -884,29 +884,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index 0b59df1d1..a7350c019 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -38,7 +38,7 @@ psycopg2-binary = "^2.9.3" [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../minos-microservice-common", develop = true } -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From c57a2138f42faa2d15c4e0bd3bf3da3c904ec7d9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Apr 2022 04:09:48 +0000 Subject: [PATCH 035/324] Bump black from 22.1.0 to 22.3.0 Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- poetry.lock | 52 +++++++++++++++++++++++++------------------------- pyproject.toml | 2 +- 2 files changed, 27 insertions(+), 27 deletions(-) diff --git a/poetry.lock b/poetry.lock index 6609ea7c0..6e4fa3d74 100644 --- a/poetry.lock +++ b/poetry.lock @@ -160,7 +160,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -171,7 +171,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -1129,7 +1129,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "30fddce08ca9aacf52b35da308a7eb6d6734425b5d5cdc9395d3734effd25e9d" +content-hash = "bd6051aedc0d148b6f175df19b88e2e1b666f807fdbc777d8541549512c17cfd" [metadata.files] aio-pika = [ @@ -1270,29 +1270,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/pyproject.toml b/pyproject.toml index afca500c3..7a174bda9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -18,7 +18,7 @@ minos-broker-rabbitmq = { path = "packages/plugins/minos-broker-rabbitmq", devel minos-http-aiohttp = { path = "packages/plugins/minos-http-aiohttp", develop = true } [tool.poetry.dev-dependencies] -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From e39c741f5b00f0607000b5887100a1ce5c7b9a3d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 08:39:15 +0200 Subject: [PATCH 036/324] ISSUE #346 * Working on `PoolFactory` class. --- .../aggregate/events/repositories/abc.py | 8 +++- .../minos/aggregate/events/repositories/pg.py | 4 +- .../transactions/repositories/abc.py | 11 ++++- .../aggregate/transactions/repositories/pg.py | 4 +- .../minos/common/config/v1.py | 43 ++++++++++++++++++- .../minos/common/config/v2.py | 2 +- .../minos/common/locks.py | 1 - .../minos/common/pools.py | 7 ++- 8 files changed, 65 insertions(+), 15 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py index 2b3c89a28..80d35be76 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py @@ -29,7 +29,7 @@ Lock, LockPool, NotProvidedException, - SetupMixin, + SetupMixin, Config, PoolFactory, ) from minos.networks import ( BrokerMessageV1, @@ -93,6 +93,12 @@ def __init__( self._transaction_repository = transaction_repository self._lock_pool = lock_pool + @classmethod + def _from_config(cls, config: Config, pool_factory: PoolFactory = None, **kwargs) -> EventRepository: + if "lock_pool" not in kwargs and pool_factory is not None: + kwargs["lock_pool"] = pool_factory.get_pool("lock") + return super()._from_config(config, **kwargs) + def transaction(self, **kwargs) -> TransactionEntry: """Build a transaction instance related to the repository. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py index d7a8c9174..f77aede25 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py @@ -41,8 +41,8 @@ class PostgreSqlEventRepository(PostgreSqlMinosDatabase, EventRepository): """PostgreSQL-based implementation of the event repository class in ``Minos``.""" @classmethod - def _from_config(cls, *args, config: Config, **kwargs) -> Optional[EventRepository]: - return cls(*args, **config.get_database_by_name("event"), **kwargs) + def _from_config(cls, config: Config, **kwargs) -> Optional[EventRepository]: + return super()._from_config(config, **config.get_database_by_name("event"), **kwargs) async def _setup(self): """Setup miscellaneous repository thing. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py index 668baf4e6..2ea507d6d 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py @@ -1,3 +1,5 @@ +from __future__ import annotations + from abc import ( ABC, abstractmethod, @@ -19,7 +21,7 @@ Lock, LockPool, NotProvidedException, - SetupMixin, + SetupMixin, Config, PoolFactory, ) from ...exceptions import ( @@ -35,7 +37,6 @@ class TransactionRepository(ABC, SetupMixin): """Transaction Repository base class.""" - @Inject() def __init__(self, lock_pool: LockPool, *args, **kwargs): super().__init__(*args, **kwargs) @@ -44,6 +45,12 @@ def __init__(self, lock_pool: LockPool, *args, **kwargs): self._lock_pool = lock_pool + @classmethod + def _from_config(cls, config: Config, pool_factory: PoolFactory = None, **kwargs) -> TransactionRepository: + if "lock_pool" not in kwargs and pool_factory is not None: + kwargs["lock_pool"] = pool_factory.get_pool("lock") + return super()._from_config(config, **kwargs) + async def submit(self, transaction: TransactionEntry) -> TransactionEntry: """Submit a new or updated transaction to store it on the repository. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py index 599948eab..8bac2fb16 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py @@ -33,8 +33,8 @@ class PostgreSqlTransactionRepository(PostgreSqlMinosDatabase, TransactionReposi """PostgreSql Transaction Repository class.""" @classmethod - def _from_config(cls, *args, config: Config, **kwargs) -> Optional[PostgreSqlTransactionRepository]: - return cls(*args, **config.get_database_by_name("transaction"), **kwargs) + def _from_config(cls, config: Config, **kwargs) -> Optional[PostgreSqlTransactionRepository]: + return super()._from_config(config, **config.get_database_by_name("transaction"), **kwargs) async def _setup(self): await self.submit_query('CREATE EXTENSION IF NOT EXISTS "uuid-ossp";', lock="uuid-ossp") diff --git a/packages/core/minos-microservice-common/minos/common/config/v1.py b/packages/core/minos-microservice-common/minos/common/config/v1.py index fdac15c47..61cba56a3 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v1.py +++ b/packages/core/minos-microservice-common/minos/common/config/v1.py @@ -128,7 +128,21 @@ def _get_injections(self) -> list[type[InjectableMixin]]: except MinosConfigException: injections = list() - injections = [import_module(classname) for classname in injections] + old = [import_module(classname) for classname in injections] + from ..pools import ( + PoolFactory, + ) + + from ..injections import ( + InjectableMixin, + ) + injections = list() + injections.append(PoolFactory) # FIXME + + for type_ in old: + if not issubclass(type_, InjectableMixin): + continue + injections.append(type_) # noinspection PyTypeChecker return injections @@ -217,7 +231,32 @@ def _get_services(self) -> list[type]: return services def _get_pools(self) -> dict[str, type]: - return dict() + try: + pools = self.get_by_key("service.injections") + if isinstance(pools, dict): + pools = list(pools.values()) + except Exception as exc: + raise MinosConfigException(f"The 'broker' interface is not available: {exc!r}") + old = [import_module(classname) for classname in pools] + + from ..pools import Pool + + pools = dict() + + for type_ in old: + if not issubclass(type_, Pool): + continue + label = "unknown" + if "lock" in type_.__name__.lower(): + label = "lock" + elif "postgres" in type_.__name__.lower(): + label = "database" + elif "broker" in type_.__name__.lower(): + label = "broker" + + pools[label] = type_ + + return pools def _get_routers(self) -> list[type]: try: diff --git a/packages/core/minos-microservice-common/minos/common/config/v2.py b/packages/core/minos-microservice-common/minos/common/config/v2.py index 1f63bb03c..0c108a576 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v2.py +++ b/packages/core/minos-microservice-common/minos/common/config/v2.py @@ -96,7 +96,7 @@ def _get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin]]] ): type_ = builder_type elif not issubclass(type_, InjectableMixin): - raise MinosConfigException(f"{type_!r} must be subclass of {InjectableMixin!r}.") + continue # raise MinosConfigException(f"{type_!r} must be subclass of {InjectableMixin!r}.") ans.append(type_) diff --git a/packages/core/minos-microservice-common/minos/common/locks.py b/packages/core/minos-microservice-common/minos/common/locks.py index d52a602dd..87853f84c 100644 --- a/packages/core/minos-microservice-common/minos/common/locks.py +++ b/packages/core/minos-microservice-common/minos/common/locks.py @@ -46,6 +46,5 @@ def hashed_key(self) -> int: return self.key -@Injectable("lock_pool") class LockPool(Pool[Lock], ABC): """Postgres Locking Pool class.""" diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index f2e5aa575..21701a871 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -59,7 +59,7 @@ async def _destroy(self) -> None: await pool.destroy() await super()._destroy() - async def get_pool(self, type_: str, key: Optional[str] = None, **kwargs) -> Pool: + def get_pool(self, type_: str, key: Optional[str] = None, **kwargs) -> Pool: """TODO :param type_: TODO @@ -70,17 +70,16 @@ async def get_pool(self, type_: str, key: Optional[str] = None, **kwargs) -> Poo if key is None: key = type_ if key not in self._pools: - self._pools[key] = await self._create_pool(type_, key=key, **kwargs) + self._pools[key] = self._create_pool(type_, key=key, **kwargs) return self._pools[key] - async def _create_pool(self, type_: str, **kwargs) -> Pool: + def _create_pool(self, type_: str, **kwargs) -> Pool: # noinspection PyTypeChecker pool_cls: type[Pool] = self._config.get_pools().get(type_) if pool_cls is None: raise ValueError pool = pool_cls.from_config(self._config, **kwargs) - await pool.setup() return pool From 9fa572b2ddb78cc878a97e935ba8c4d2ed2172b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 09:48:08 +0200 Subject: [PATCH 037/324] * Do `poetry update`. --- poetry.lock | 96 ++++++++++++++++++++++++++--------------------------- 1 file changed, 48 insertions(+), 48 deletions(-) diff --git a/poetry.lock b/poetry.lock index 6e4fa3d74..54ad45f61 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,6 +1,6 @@ [[package]] name = "aio-pika" -version = "7.1.1" +version = "7.1.2" description = "Wrapper for the aiormq for asyncio and humans." category = "main" optional = false @@ -217,11 +217,11 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.0.4" +version = "8.1.2" description = "Composable command line interface toolkit" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] colorama = {version = "*", markers = "platform_system == \"Windows\""} @@ -269,7 +269,7 @@ python-versions = "*" [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -475,7 +475,7 @@ python-versions = "*" [[package]] name = "minos-broker-kafka" -version = "0.6.0" +version = "0.6.1" description = "The kafka plugin of the Minos Framework" category = "main" optional = false @@ -514,7 +514,7 @@ url = "packages/plugins/minos-broker-rabbitmq" [[package]] name = "minos-discovery-minos" version = "0.6.0" -description = "The minos-discover plugin of the Minos Framework" +description = "The minos-discovery plugin of the Minos Framework" category = "main" optional = false python-versions = "^3.9" @@ -532,7 +532,7 @@ url = "packages/plugins/minos-discovery-minos" [[package]] name = "minos-http-aiohttp" version = "0.6.0" -description = "The aiohttp plugin of the Minos Framework." +description = "The aiohttp plugin of the Minos Framework" category = "main" optional = false python-versions = "^3.9" @@ -570,7 +570,7 @@ url = "packages/core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -1133,8 +1133,8 @@ content-hash = "bd6051aedc0d148b6f175df19b88e2e1b666f807fdbc777d8541549512c17cfd [metadata.files] aio-pika = [ - {file = "aio-pika-7.1.1.tar.gz", hash = "sha256:8c990642b2906d0ad5af8807855b2b5c400e3b9b3a5bdc64ba98357bd55051f1"}, - {file = "aio_pika-7.1.1-py3-none-any.whl", hash = "sha256:3af44e29fcad19f700d43d17ba2c536bbf763af9b228f6c0d97e5a9fe3c1bbb7"}, + {file = "aio-pika-7.1.2.tar.gz", hash = "sha256:b754ba114ce3cfbc5fb444c0d41c5f74f5cfff34c2c87fef3eab0ba796ec3e94"}, + {file = "aio_pika-7.1.2-py3-none-any.whl", hash = "sha256:47fbd996d6ff4a8b1ea0148091b9e056c3a581fd4be863801eba8fce690cd243"}, ] aiohttp = [ {file = "aiohttp-3.8.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1ed0b6477896559f17b9eaeb6d38e07f7f9ffe40b9f0f9627ae8b9926ae260a8"}, @@ -1311,8 +1311,8 @@ charset-normalizer = [ {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.0.4-py3-none-any.whl", hash = "sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1"}, - {file = "click-8.0.4.tar.gz", hash = "sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb"}, + {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, + {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1369,42 +1369,42 @@ crontab = [ {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] distlib = [ {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, From 1ef190c556b60956a301b6a3c64731ff1ca71d9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 10:41:31 +0200 Subject: [PATCH 038/324] * Unify `SETUP.md`. --- .../minos-microservice-aggregate/SETUP.md => SETUP.md | 2 +- packages/core/minos-microservice-common/SETUP.md | 10 ---------- packages/core/minos-microservice-cqrs/SETUP.md | 10 ---------- packages/core/minos-microservice-networks/SETUP.md | 10 ---------- packages/core/minos-microservice-saga/SETUP.md | 10 ---------- packages/plugins/minos-broker-kafka/SETUP.md | 10 ---------- packages/plugins/minos-broker-rabbitmq/SETUP.md | 10 ---------- packages/plugins/minos-discovery-minos/SETUP.md | 10 ---------- packages/plugins/minos-http-aiohttp/SETUP.md | 10 ---------- packages/plugins/minos-router-graphql/SETUP.md | 10 ---------- 10 files changed, 1 insertion(+), 91 deletions(-) rename packages/core/minos-microservice-aggregate/SETUP.md => SETUP.md (83%) delete mode 100644 packages/core/minos-microservice-common/SETUP.md delete mode 100644 packages/core/minos-microservice-cqrs/SETUP.md delete mode 100644 packages/core/minos-microservice-networks/SETUP.md delete mode 100644 packages/core/minos-microservice-saga/SETUP.md delete mode 100644 packages/plugins/minos-broker-kafka/SETUP.md delete mode 100644 packages/plugins/minos-broker-rabbitmq/SETUP.md delete mode 100644 packages/plugins/minos-discovery-minos/SETUP.md delete mode 100644 packages/plugins/minos-http-aiohttp/SETUP.md delete mode 100644 packages/plugins/minos-router-graphql/SETUP.md diff --git a/packages/core/minos-microservice-aggregate/SETUP.md b/SETUP.md similarity index 83% rename from packages/core/minos-microservice-aggregate/SETUP.md rename to SETUP.md index e85ca0f64..dd0f26b3a 100644 --- a/packages/core/minos-microservice-aggregate/SETUP.md +++ b/SETUP.md @@ -5,6 +5,6 @@ Since we use `poetry` as the default package manager, it must be installed. Plea Run `poetry install` to get the dependencies. -Run `pre-commit install` to set the git checks before commiting. +Run `pre-commit install` to set the git checks before committing. Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/core/minos-microservice-common/SETUP.md b/packages/core/minos-microservice-common/SETUP.md deleted file mode 100644 index e85ca0f64..000000000 --- a/packages/core/minos-microservice-common/SETUP.md +++ /dev/null @@ -1,10 +0,0 @@ -# Set up a development environment - -Since we use `poetry` as the default package manager, it must be installed. Please refer to -`https://python-poetry.org/docs/#installation`. - -Run `poetry install` to get the dependencies. - -Run `pre-commit install` to set the git checks before commiting. - -Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/core/minos-microservice-cqrs/SETUP.md b/packages/core/minos-microservice-cqrs/SETUP.md deleted file mode 100644 index e85ca0f64..000000000 --- a/packages/core/minos-microservice-cqrs/SETUP.md +++ /dev/null @@ -1,10 +0,0 @@ -# Set up a development environment - -Since we use `poetry` as the default package manager, it must be installed. Please refer to -`https://python-poetry.org/docs/#installation`. - -Run `poetry install` to get the dependencies. - -Run `pre-commit install` to set the git checks before commiting. - -Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/core/minos-microservice-networks/SETUP.md b/packages/core/minos-microservice-networks/SETUP.md deleted file mode 100644 index e85ca0f64..000000000 --- a/packages/core/minos-microservice-networks/SETUP.md +++ /dev/null @@ -1,10 +0,0 @@ -# Set up a development environment - -Since we use `poetry` as the default package manager, it must be installed. Please refer to -`https://python-poetry.org/docs/#installation`. - -Run `poetry install` to get the dependencies. - -Run `pre-commit install` to set the git checks before commiting. - -Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/core/minos-microservice-saga/SETUP.md b/packages/core/minos-microservice-saga/SETUP.md deleted file mode 100644 index e85ca0f64..000000000 --- a/packages/core/minos-microservice-saga/SETUP.md +++ /dev/null @@ -1,10 +0,0 @@ -# Set up a development environment - -Since we use `poetry` as the default package manager, it must be installed. Please refer to -`https://python-poetry.org/docs/#installation`. - -Run `poetry install` to get the dependencies. - -Run `pre-commit install` to set the git checks before commiting. - -Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/plugins/minos-broker-kafka/SETUP.md b/packages/plugins/minos-broker-kafka/SETUP.md deleted file mode 100644 index e85ca0f64..000000000 --- a/packages/plugins/minos-broker-kafka/SETUP.md +++ /dev/null @@ -1,10 +0,0 @@ -# Set up a development environment - -Since we use `poetry` as the default package manager, it must be installed. Please refer to -`https://python-poetry.org/docs/#installation`. - -Run `poetry install` to get the dependencies. - -Run `pre-commit install` to set the git checks before commiting. - -Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/plugins/minos-broker-rabbitmq/SETUP.md b/packages/plugins/minos-broker-rabbitmq/SETUP.md deleted file mode 100644 index e85ca0f64..000000000 --- a/packages/plugins/minos-broker-rabbitmq/SETUP.md +++ /dev/null @@ -1,10 +0,0 @@ -# Set up a development environment - -Since we use `poetry` as the default package manager, it must be installed. Please refer to -`https://python-poetry.org/docs/#installation`. - -Run `poetry install` to get the dependencies. - -Run `pre-commit install` to set the git checks before commiting. - -Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/plugins/minos-discovery-minos/SETUP.md b/packages/plugins/minos-discovery-minos/SETUP.md deleted file mode 100644 index e85ca0f64..000000000 --- a/packages/plugins/minos-discovery-minos/SETUP.md +++ /dev/null @@ -1,10 +0,0 @@ -# Set up a development environment - -Since we use `poetry` as the default package manager, it must be installed. Please refer to -`https://python-poetry.org/docs/#installation`. - -Run `poetry install` to get the dependencies. - -Run `pre-commit install` to set the git checks before commiting. - -Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/plugins/minos-http-aiohttp/SETUP.md b/packages/plugins/minos-http-aiohttp/SETUP.md deleted file mode 100644 index e85ca0f64..000000000 --- a/packages/plugins/minos-http-aiohttp/SETUP.md +++ /dev/null @@ -1,10 +0,0 @@ -# Set up a development environment - -Since we use `poetry` as the default package manager, it must be installed. Please refer to -`https://python-poetry.org/docs/#installation`. - -Run `poetry install` to get the dependencies. - -Run `pre-commit install` to set the git checks before commiting. - -Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/plugins/minos-router-graphql/SETUP.md b/packages/plugins/minos-router-graphql/SETUP.md deleted file mode 100644 index e85ca0f64..000000000 --- a/packages/plugins/minos-router-graphql/SETUP.md +++ /dev/null @@ -1,10 +0,0 @@ -# Set up a development environment - -Since we use `poetry` as the default package manager, it must be installed. Please refer to -`https://python-poetry.org/docs/#installation`. - -Run `poetry install` to get the dependencies. - -Run `pre-commit install` to set the git checks before commiting. - -Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. From 69290b9e5c10d6cb15b1354b9fafbd2f3405d418 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 12:01:03 +0200 Subject: [PATCH 039/324] ISSUE #346 * Improve integration of `LockPool` and `PoolFactory`. --- .../minos/aggregate/events/repositories/abc.py | 12 +++++------- .../aggregate/transactions/repositories/abc.py | 17 +++++++++-------- 2 files changed, 14 insertions(+), 15 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py index 80d35be76..8d21cbd35 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py @@ -74,12 +74,16 @@ def __init__( self, broker_publisher: BrokerPublisher, transaction_repository: TransactionRepository, - lock_pool: LockPool, + lock_pool: Optional[LockPool] = None, + pool_factory: Optional[PoolFactory] = None, *args, **kwargs, ): super().__init__(*args, **kwargs) + if lock_pool is None and pool_factory is not None: + lock_pool = pool_factory.get_pool("lock") + if broker_publisher is None: raise NotProvidedException("A broker instance is required.") @@ -93,12 +97,6 @@ def __init__( self._transaction_repository = transaction_repository self._lock_pool = lock_pool - @classmethod - def _from_config(cls, config: Config, pool_factory: PoolFactory = None, **kwargs) -> EventRepository: - if "lock_pool" not in kwargs and pool_factory is not None: - kwargs["lock_pool"] = pool_factory.get_pool("lock") - return super()._from_config(config, **kwargs) - def transaction(self, **kwargs) -> TransactionEntry: """Build a transaction instance related to the repository. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py index 2ea507d6d..99e95236f 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py @@ -21,7 +21,8 @@ Lock, LockPool, NotProvidedException, - SetupMixin, Config, PoolFactory, + SetupMixin, + PoolFactory, ) from ...exceptions import ( @@ -37,20 +38,20 @@ class TransactionRepository(ABC, SetupMixin): """Transaction Repository base class.""" - def __init__(self, lock_pool: LockPool, *args, **kwargs): + @Inject() + def __init__( + self, lock_pool: Optional[LockPool] = None, pool_factory: Optional[PoolFactory] = None, *args, **kwargs + ): super().__init__(*args, **kwargs) + if lock_pool is None and pool_factory is not None: + lock_pool = pool_factory.get_pool("lock") + if lock_pool is None: raise NotProvidedException("A lock pool instance is required.") self._lock_pool = lock_pool - @classmethod - def _from_config(cls, config: Config, pool_factory: PoolFactory = None, **kwargs) -> TransactionRepository: - if "lock_pool" not in kwargs and pool_factory is not None: - kwargs["lock_pool"] = pool_factory.get_pool("lock") - return super()._from_config(config, **kwargs) - async def submit(self, transaction: TransactionEntry) -> TransactionEntry: """Submit a new or updated transaction to store it on the repository. From af5d506885103a1fc6d8966d739aed36bbeadca6 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 1 Apr 2022 12:17:25 +0200 Subject: [PATCH 040/324] Add konga volume --- packages/plugins/minos-kong/poetry.lock | 6 +++--- packages/plugins/minos-kong/tests/docker-compose.yml | 2 ++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/packages/plugins/minos-kong/poetry.lock b/packages/plugins/minos-kong/poetry.lock index 29f82e8ee..d67596ea2 100644 --- a/packages/plugins/minos-kong/poetry.lock +++ b/packages/plugins/minos-kong/poetry.lock @@ -190,7 +190,7 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.1.1" +version = "8.1.2" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -1150,8 +1150,8 @@ charset-normalizer = [ {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, - {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, + {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, + {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, diff --git a/packages/plugins/minos-kong/tests/docker-compose.yml b/packages/plugins/minos-kong/tests/docker-compose.yml index 408b96752..d73637ad9 100644 --- a/packages/plugins/minos-kong/tests/docker-compose.yml +++ b/packages/plugins/minos-kong/tests/docker-compose.yml @@ -9,6 +9,7 @@ x-kong-config: &kong-env volumes: kong_data: {} + konga_data: kong_prefix_vol: driver_opts: type: tmpfs @@ -61,6 +62,7 @@ services: KONG_PROXY_ACCESS_LOG: /dev/stdout KONG_PROXY_ERROR_LOG: /dev/stderr KONG_PREFIX: /var/run/kong + KONG_LOG_LEVEL: debug KONG_DECLARATIVE_CONFIG: "/opt/kong/kong.yaml" ports: - "0.0.0.0:8000:8000/tcp" From 36886c7b5d229e7728127a33f8b4b24430935dbf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 12:19:16 +0200 Subject: [PATCH 041/324] ISSUE #144 * Fix typo. --- packages/plugins/minos-kong/minos/plugins/minos_kong/client.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py b/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py index d52027cd3..fed3b3ec3 100644 --- a/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py +++ b/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py @@ -75,7 +75,7 @@ async def subscribe( "methods": [endpoint["method"]], "paths": [endpointClass.path_as_str], "service": {"id": content_service["id"]}, - "strip_path": False + "strip_path": False, } fn = partial(self._subscribe_routes, self.route, data) response = await self.with_circuit_breaker(fn) # send the route request From bfc631a52065c13ac943f7e350ce3c5219294bd2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 12:20:27 +0200 Subject: [PATCH 042/324] ISSUE #144 * Move files. --- packages/plugins/{minos-kong => minos-discovery-kong}/AUTHORS.md | 0 packages/plugins/{minos-kong => minos-discovery-kong}/HISTORY.md | 0 packages/plugins/{minos-kong => minos-discovery-kong}/LICENSE | 0 packages/plugins/{minos-kong => minos-discovery-kong}/Makefile | 0 packages/plugins/{minos-kong => minos-discovery-kong}/README.md | 0 .../plugins/{minos-kong => minos-discovery-kong}/RUNTHETESTS.md | 0 packages/plugins/{minos-kong => minos-discovery-kong}/SETUP.md | 0 .../plugins/{minos-kong => minos-discovery-kong}/docs/Makefile | 0 .../{minos-kong => minos-discovery-kong}/docs/_static/style.css | 0 .../docs/_templates/layout.html | 0 .../plugins/{minos-kong => minos-discovery-kong}/docs/authors.md | 0 .../plugins/{minos-kong => minos-discovery-kong}/docs/conf.py | 0 .../plugins/{minos-kong => minos-discovery-kong}/docs/history.md | 0 .../plugins/{minos-kong => minos-discovery-kong}/docs/index.md | 0 .../plugins/{minos-kong => minos-discovery-kong}/docs/readme.md | 0 .../{minos-kong => minos-discovery-kong}/docs/runthetests.md | 0 .../plugins/{minos-kong => minos-discovery-kong}/docs/usage.md | 0 .../minos/plugins/minos_kong/__init__.py | 0 .../minos/plugins/minos_kong/client.py | 0 .../minos/plugins/minos_kong/utils.py | 0 packages/plugins/{minos-kong => minos-discovery-kong}/poetry.lock | 0 packages/plugins/{minos-kong => minos-discovery-kong}/poetry.toml | 0 .../plugins/{minos-kong => minos-discovery-kong}/pyproject.toml | 0 packages/plugins/{minos-kong => minos-discovery-kong}/setup.cfg | 0 .../plugins/{minos-kong => minos-discovery-kong}/tests/Makefile | 0 .../{minos-kong => minos-discovery-kong}/tests/docker-compose.yml | 0 .../tests/test_minos_discovery/__init__.py | 0 .../tests/test_minos_discovery/test_client.py | 0 28 files changed, 0 insertions(+), 0 deletions(-) rename packages/plugins/{minos-kong => minos-discovery-kong}/AUTHORS.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/HISTORY.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/LICENSE (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/Makefile (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/README.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/RUNTHETESTS.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/SETUP.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/docs/Makefile (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/docs/_static/style.css (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/docs/_templates/layout.html (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/docs/authors.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/docs/conf.py (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/docs/history.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/docs/index.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/docs/readme.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/docs/runthetests.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/docs/usage.md (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/minos/plugins/minos_kong/__init__.py (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/minos/plugins/minos_kong/client.py (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/minos/plugins/minos_kong/utils.py (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/poetry.lock (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/poetry.toml (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/pyproject.toml (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/setup.cfg (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/tests/Makefile (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/tests/docker-compose.yml (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/tests/test_minos_discovery/__init__.py (100%) rename packages/plugins/{minos-kong => minos-discovery-kong}/tests/test_minos_discovery/test_client.py (100%) diff --git a/packages/plugins/minos-kong/AUTHORS.md b/packages/plugins/minos-discovery-kong/AUTHORS.md similarity index 100% rename from packages/plugins/minos-kong/AUTHORS.md rename to packages/plugins/minos-discovery-kong/AUTHORS.md diff --git a/packages/plugins/minos-kong/HISTORY.md b/packages/plugins/minos-discovery-kong/HISTORY.md similarity index 100% rename from packages/plugins/minos-kong/HISTORY.md rename to packages/plugins/minos-discovery-kong/HISTORY.md diff --git a/packages/plugins/minos-kong/LICENSE b/packages/plugins/minos-discovery-kong/LICENSE similarity index 100% rename from packages/plugins/minos-kong/LICENSE rename to packages/plugins/minos-discovery-kong/LICENSE diff --git a/packages/plugins/minos-kong/Makefile b/packages/plugins/minos-discovery-kong/Makefile similarity index 100% rename from packages/plugins/minos-kong/Makefile rename to packages/plugins/minos-discovery-kong/Makefile diff --git a/packages/plugins/minos-kong/README.md b/packages/plugins/minos-discovery-kong/README.md similarity index 100% rename from packages/plugins/minos-kong/README.md rename to packages/plugins/minos-discovery-kong/README.md diff --git a/packages/plugins/minos-kong/RUNTHETESTS.md b/packages/plugins/minos-discovery-kong/RUNTHETESTS.md similarity index 100% rename from packages/plugins/minos-kong/RUNTHETESTS.md rename to packages/plugins/minos-discovery-kong/RUNTHETESTS.md diff --git a/packages/plugins/minos-kong/SETUP.md b/packages/plugins/minos-discovery-kong/SETUP.md similarity index 100% rename from packages/plugins/minos-kong/SETUP.md rename to packages/plugins/minos-discovery-kong/SETUP.md diff --git a/packages/plugins/minos-kong/docs/Makefile b/packages/plugins/minos-discovery-kong/docs/Makefile similarity index 100% rename from packages/plugins/minos-kong/docs/Makefile rename to packages/plugins/minos-discovery-kong/docs/Makefile diff --git a/packages/plugins/minos-kong/docs/_static/style.css b/packages/plugins/minos-discovery-kong/docs/_static/style.css similarity index 100% rename from packages/plugins/minos-kong/docs/_static/style.css rename to packages/plugins/minos-discovery-kong/docs/_static/style.css diff --git a/packages/plugins/minos-kong/docs/_templates/layout.html b/packages/plugins/minos-discovery-kong/docs/_templates/layout.html similarity index 100% rename from packages/plugins/minos-kong/docs/_templates/layout.html rename to packages/plugins/minos-discovery-kong/docs/_templates/layout.html diff --git a/packages/plugins/minos-kong/docs/authors.md b/packages/plugins/minos-discovery-kong/docs/authors.md similarity index 100% rename from packages/plugins/minos-kong/docs/authors.md rename to packages/plugins/minos-discovery-kong/docs/authors.md diff --git a/packages/plugins/minos-kong/docs/conf.py b/packages/plugins/minos-discovery-kong/docs/conf.py similarity index 100% rename from packages/plugins/minos-kong/docs/conf.py rename to packages/plugins/minos-discovery-kong/docs/conf.py diff --git a/packages/plugins/minos-kong/docs/history.md b/packages/plugins/minos-discovery-kong/docs/history.md similarity index 100% rename from packages/plugins/minos-kong/docs/history.md rename to packages/plugins/minos-discovery-kong/docs/history.md diff --git a/packages/plugins/minos-kong/docs/index.md b/packages/plugins/minos-discovery-kong/docs/index.md similarity index 100% rename from packages/plugins/minos-kong/docs/index.md rename to packages/plugins/minos-discovery-kong/docs/index.md diff --git a/packages/plugins/minos-kong/docs/readme.md b/packages/plugins/minos-discovery-kong/docs/readme.md similarity index 100% rename from packages/plugins/minos-kong/docs/readme.md rename to packages/plugins/minos-discovery-kong/docs/readme.md diff --git a/packages/plugins/minos-kong/docs/runthetests.md b/packages/plugins/minos-discovery-kong/docs/runthetests.md similarity index 100% rename from packages/plugins/minos-kong/docs/runthetests.md rename to packages/plugins/minos-discovery-kong/docs/runthetests.md diff --git a/packages/plugins/minos-kong/docs/usage.md b/packages/plugins/minos-discovery-kong/docs/usage.md similarity index 100% rename from packages/plugins/minos-kong/docs/usage.md rename to packages/plugins/minos-discovery-kong/docs/usage.md diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/__init__.py similarity index 100% rename from packages/plugins/minos-kong/minos/plugins/minos_kong/__init__.py rename to packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/__init__.py diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/client.py similarity index 100% rename from packages/plugins/minos-kong/minos/plugins/minos_kong/client.py rename to packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/client.py diff --git a/packages/plugins/minos-kong/minos/plugins/minos_kong/utils.py b/packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/utils.py similarity index 100% rename from packages/plugins/minos-kong/minos/plugins/minos_kong/utils.py rename to packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/utils.py diff --git a/packages/plugins/minos-kong/poetry.lock b/packages/plugins/minos-discovery-kong/poetry.lock similarity index 100% rename from packages/plugins/minos-kong/poetry.lock rename to packages/plugins/minos-discovery-kong/poetry.lock diff --git a/packages/plugins/minos-kong/poetry.toml b/packages/plugins/minos-discovery-kong/poetry.toml similarity index 100% rename from packages/plugins/minos-kong/poetry.toml rename to packages/plugins/minos-discovery-kong/poetry.toml diff --git a/packages/plugins/minos-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml similarity index 100% rename from packages/plugins/minos-kong/pyproject.toml rename to packages/plugins/minos-discovery-kong/pyproject.toml diff --git a/packages/plugins/minos-kong/setup.cfg b/packages/plugins/minos-discovery-kong/setup.cfg similarity index 100% rename from packages/plugins/minos-kong/setup.cfg rename to packages/plugins/minos-discovery-kong/setup.cfg diff --git a/packages/plugins/minos-kong/tests/Makefile b/packages/plugins/minos-discovery-kong/tests/Makefile similarity index 100% rename from packages/plugins/minos-kong/tests/Makefile rename to packages/plugins/minos-discovery-kong/tests/Makefile diff --git a/packages/plugins/minos-kong/tests/docker-compose.yml b/packages/plugins/minos-discovery-kong/tests/docker-compose.yml similarity index 100% rename from packages/plugins/minos-kong/tests/docker-compose.yml rename to packages/plugins/minos-discovery-kong/tests/docker-compose.yml diff --git a/packages/plugins/minos-kong/tests/test_minos_discovery/__init__.py b/packages/plugins/minos-discovery-kong/tests/test_minos_discovery/__init__.py similarity index 100% rename from packages/plugins/minos-kong/tests/test_minos_discovery/__init__.py rename to packages/plugins/minos-discovery-kong/tests/test_minos_discovery/__init__.py diff --git a/packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_minos_discovery/test_client.py similarity index 100% rename from packages/plugins/minos-kong/tests/test_minos_discovery/test_client.py rename to packages/plugins/minos-discovery-kong/tests/test_minos_discovery/test_client.py From 4c526b85076b520e1ca8f1e3c58c19410518876c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 12:34:44 +0200 Subject: [PATCH 043/324] ISSUE #144 * Refactor to use the new docs generation strategy. --- .pre-commit-config.yaml | 7 + docs/index.md | 1 + .../plugins/minos-discovery-kong/Makefile | 7 +- .../minos-discovery-kong/RUNTHETESTS.md | 3 +- .../plugins/minos-discovery-kong/SETUP.md | 11 - .../minos-discovery-kong/docs/Makefile | 20 - .../docs/_static/style.css | 3 - .../docs/_templates/layout.html | 4 - .../minos-discovery-kong/docs/authors.md | 1 - .../plugins/minos-discovery-kong/docs/conf.py | 194 ---- .../minos-discovery-kong/docs/history.md | 1 - .../minos-discovery-kong/docs/index.md | 16 - .../minos-discovery-kong/docs/readme.md | 3 - .../minos-discovery-kong/docs/runthetests.md | 1 - .../minos-discovery-kong/docs/usage.md | 1 - .../plugins/{minos_kong => kong}/__init__.py | 2 +- .../plugins/{minos_kong => kong}/client.py | 4 +- .../plugins/{minos_kong => kong}/utils.py | 0 .../plugins/minos-discovery-kong/poetry.lock | 976 +----------------- .../minos-discovery-kong/pyproject.toml | 16 +- .../__init__.py | 0 .../test_client.py | 10 +- poetry.lock | 133 ++- pyproject.toml | 1 + 24 files changed, 211 insertions(+), 1204 deletions(-) delete mode 100644 packages/plugins/minos-discovery-kong/SETUP.md delete mode 100644 packages/plugins/minos-discovery-kong/docs/Makefile delete mode 100644 packages/plugins/minos-discovery-kong/docs/_static/style.css delete mode 100644 packages/plugins/minos-discovery-kong/docs/_templates/layout.html delete mode 100644 packages/plugins/minos-discovery-kong/docs/authors.md delete mode 100755 packages/plugins/minos-discovery-kong/docs/conf.py delete mode 100644 packages/plugins/minos-discovery-kong/docs/history.md delete mode 100644 packages/plugins/minos-discovery-kong/docs/index.md delete mode 100644 packages/plugins/minos-discovery-kong/docs/readme.md delete mode 100644 packages/plugins/minos-discovery-kong/docs/runthetests.md delete mode 100644 packages/plugins/minos-discovery-kong/docs/usage.md rename packages/plugins/minos-discovery-kong/minos/plugins/{minos_kong => kong}/__init__.py (81%) rename packages/plugins/minos-discovery-kong/minos/plugins/{minos_kong => kong}/client.py (98%) rename packages/plugins/minos-discovery-kong/minos/plugins/{minos_kong => kong}/utils.py (100%) rename packages/plugins/minos-discovery-kong/tests/{test_minos_discovery => test_kong}/__init__.py (100%) rename packages/plugins/minos-discovery-kong/tests/{test_minos_discovery => test_kong}/test_client.py (91%) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 0ec427991..efacc4d24 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -51,6 +51,13 @@ repos: files: ^packages/plugins/minos-discovery-minos/ language: system + - id: kong-discovery-kong-check + pass_filenames: false + entry: make --directory=packages/plugins/kong-discovery-kong check + name: Check kong-discovery-kong + files: ^packages/plugins/kong-discovery-kong/ + language: system + - id: minos-http-aiohttp-check pass_filenames: false entry: make --directory=packages/plugins/minos-http-aiohttp check diff --git a/docs/index.md b/docs/index.md index 2247efc62..63298435e 100644 --- a/docs/index.md +++ b/docs/index.md @@ -32,6 +32,7 @@ Minos is a framework which helps you create [reactive](https://www.reactivemanif minos.plugins.kafka minos.plugins.rabbitmq minos.plugins.minos_discovery + minos.plugins.kong minos.plugins.aiohttp minos.plugins.graphql diff --git a/packages/plugins/minos-discovery-kong/Makefile b/packages/plugins/minos-discovery-kong/Makefile index acc861207..c029df39d 100644 --- a/packages/plugins/minos-discovery-kong/Makefile +++ b/packages/plugins/minos-discovery-kong/Makefile @@ -1,4 +1,4 @@ -.PHONY: docs dist +.PHONY: dist lint: poetry run flake8 @@ -15,10 +15,6 @@ reformat: poetry run black --line-length 120 minos tests poetry run isort minos tests -docs: - rm -rf docs/api - poetry run $(MAKE) --directory=docs html - release: $(MAKE) dist poetry publish @@ -38,5 +34,4 @@ check: $(MAKE) reformat $(MAKE) lint $(MAKE) test - $(MAKE) docs $(MAKE) dist diff --git a/packages/plugins/minos-discovery-kong/RUNTHETESTS.md b/packages/plugins/minos-discovery-kong/RUNTHETESTS.md index 8b5e95b1f..386e2b0e7 100644 --- a/packages/plugins/minos-discovery-kong/RUNTHETESTS.md +++ b/packages/plugins/minos-discovery-kong/RUNTHETESTS.md @@ -1,5 +1,4 @@ -Run the tests -============== +# Run the tests In order to run the tests, please make sure you have the `Docker Engine `_ and `Docker Compose `_ installed. diff --git a/packages/plugins/minos-discovery-kong/SETUP.md b/packages/plugins/minos-discovery-kong/SETUP.md deleted file mode 100644 index 8203965c7..000000000 --- a/packages/plugins/minos-discovery-kong/SETUP.md +++ /dev/null @@ -1,11 +0,0 @@ -Set up a development environment -================================= - -Since we use `poetry` as the default package manager, it must be installed. Please refer to -`https://python-poetry.org/docs/#installation`. - -Run `poetry install` to get the dependencies. - -Run `pre-commit install` to set the git checks before commiting. - -Make yourself sure you are able to run the tests. Refer to the appropriate section in this guide. diff --git a/packages/plugins/minos-discovery-kong/docs/Makefile b/packages/plugins/minos-discovery-kong/docs/Makefile deleted file mode 100644 index 11e69918e..000000000 --- a/packages/plugins/minos-discovery-kong/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -SPHINXPROJ = minos-kong -SOURCEDIR = . -BUILDDIR = _build - -# Put it first so that "make" without argument is like "make help". -help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/packages/plugins/minos-discovery-kong/docs/_static/style.css b/packages/plugins/minos-discovery-kong/docs/_static/style.css deleted file mode 100644 index 8aa6c288f..000000000 --- a/packages/plugins/minos-discovery-kong/docs/_static/style.css +++ /dev/null @@ -1,3 +0,0 @@ -.wy-nav-content { - max-width: 1200px !important; -} diff --git a/packages/plugins/minos-discovery-kong/docs/_templates/layout.html b/packages/plugins/minos-discovery-kong/docs/_templates/layout.html deleted file mode 100644 index b0a448060..000000000 --- a/packages/plugins/minos-discovery-kong/docs/_templates/layout.html +++ /dev/null @@ -1,4 +0,0 @@ -{% extends "!layout.html" %} -{% block extrahead %} - -{% endblock %} \ No newline at end of file diff --git a/packages/plugins/minos-discovery-kong/docs/authors.md b/packages/plugins/minos-discovery-kong/docs/authors.md deleted file mode 100644 index cf16fc494..000000000 --- a/packages/plugins/minos-discovery-kong/docs/authors.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../AUTHORS.md diff --git a/packages/plugins/minos-discovery-kong/docs/conf.py b/packages/plugins/minos-discovery-kong/docs/conf.py deleted file mode 100755 index 783f76876..000000000 --- a/packages/plugins/minos-discovery-kong/docs/conf.py +++ /dev/null @@ -1,194 +0,0 @@ -#!/usr/bin/env python -# -# minos documentation build configuration file, created by -# sphinx-quickstart on Fri Jun 9 13:47:02 2017. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -# If extensions (or modules to document with autodoc) are in another -# directory, add these directories to sys.path here. If the directory is -# relative to the documentation root, use os.path.abspath to make it -# absolute, like shown here. -# -import os -import sys - -sys.path.insert(0, os.path.abspath("..")) - -from minos.plugins import ( - minos_discovery, -) - -# -- General configuration --------------------------------------------- - -# If your documentation needs a minimal Sphinx version, state it here. -# -# needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. - - -extensions = [ - "sphinxcontrib.apidoc", - "sphinx.ext.autodoc", - "sphinx_autodoc_typehints", - "sphinx.ext.viewcode", - "sphinx_rtd_theme", - "m2r2", -] -# Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] - -# The suffix(es) of source filenames. -# You can specify multiple suffix as a list of string: -# -source_suffix = [".rst", ".md"] - -# The master toctree document. -master_doc = "index" - -# General information about the project. -project = "Minos Kong Plugin" -copyright = "2021, Clariteia" -author = "Minos Framework Devs" - -# The version info for the project you're documenting, acts as replacement -# for |version| and |release|, also used in various other places throughout -# the built documents. -# -# The short X.Y version. -version = minos_discovery.__version__ -# The full version, including alpha/beta/rc tags. -release = minos_discovery.__version__ - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -# -# This is also used if you do content translation via gettext catalogs. -# Usually you set "language" from the command line for these cases. -language = None - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -# This patterns also effect to html_static_path and html_extra_path -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = "sphinx" - -todo_include_todos = False - - -# -- Options for HTML output ------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -# - -html_theme = "sphinx_rtd_theme" - -# Theme options are theme-specific and customize the look and feel of a -# theme further. For a list of options available for each theme, see the -# documentation. -# - -# html_theme_options = { -# "codecov_button": True, -# "description": "Reactive microservices for an asynchronous world", -# "github_button": True, -# "github_user": "Clariteia", -# "github_repo": "cqrs", -# "github_type": "star", -# } - -html_sidebars = {"**": ["about.html", "navigation.html", "searchbox.html"]} - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ["_static"] - - -# -- Options for HTMLHelp output --------------------------------------- - -# Output file base name for HTML help builder. -htmlhelp_basename = "minosdoc" - - -# -- Options for LaTeX output ------------------------------------------ - -latex_elements = { - # The paper size ('letterpaper' or 'a4paper'). - # - # 'papersize': 'letterpaper', - # The font size ('10pt', '11pt' or '12pt'). - # - # 'pointsize': '10pt', - # Additional stuff for the LaTeX preamble. - # - # 'preamble': '', - # Latex figure (float) alignment - # - # 'figure_align': 'htbp', -} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto, manual, or own class]). -latex_documents = [ - (master_doc, "minos.tex", "Minos Kong Plugin Documentation", "Minos Framework Devs", "manual"), -] - - -# -- Options for manual page output ------------------------------------ - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [(master_doc, "minos", "Minos Kong Plugin Documentation", [author], 1)] - - -# -- Options for Texinfo output ---------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ( - master_doc, - "minos", - "Minos Kong Plugin Documentation", - author, - "minos", - "One line description of project.", - "Miscellaneous", - ), -] - -# "apidoc" extension -apidoc_module_dir = "../minos" -apidoc_output_dir = "api" -apidoc_separate_modules = True -autodoc_default_options = { - "inherited-members": True, - "special-members": "__init__", - "undoc-members": True, -} - -apidoc_toc_file = False -apidoc_module_first = True -apidoc_extra_args = [ - "--force", - "--implicit-namespaces", -] -# "autodoc typehints" extension - -set_type_checking_flag = True -typehints_fully_qualified = True diff --git a/packages/plugins/minos-discovery-kong/docs/history.md b/packages/plugins/minos-discovery-kong/docs/history.md deleted file mode 100644 index d26e5be83..000000000 --- a/packages/plugins/minos-discovery-kong/docs/history.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../HISTORY.md diff --git a/packages/plugins/minos-discovery-kong/docs/index.md b/packages/plugins/minos-discovery-kong/docs/index.md deleted file mode 100644 index b470bca77..000000000 --- a/packages/plugins/minos-discovery-kong/docs/index.md +++ /dev/null @@ -1,16 +0,0 @@ -# Welcome to Minos Discovery Minos's documentation! - -.. toctree:: - :maxdepth: 2 - - readme - runthetests - usage - api/minos.plugins - authors - history - -# Indices and tables -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/packages/plugins/minos-discovery-kong/docs/readme.md b/packages/plugins/minos-discovery-kong/docs/readme.md deleted file mode 100644 index da72dbef1..000000000 --- a/packages/plugins/minos-discovery-kong/docs/readme.md +++ /dev/null @@ -1,3 +0,0 @@ -# Introduction - -.. mdinclude:: ../README.md diff --git a/packages/plugins/minos-discovery-kong/docs/runthetests.md b/packages/plugins/minos-discovery-kong/docs/runthetests.md deleted file mode 100644 index 309db1b96..000000000 --- a/packages/plugins/minos-discovery-kong/docs/runthetests.md +++ /dev/null @@ -1 +0,0 @@ -.. mdinclude:: ../RUNTHETESTS.md diff --git a/packages/plugins/minos-discovery-kong/docs/usage.md b/packages/plugins/minos-discovery-kong/docs/usage.md deleted file mode 100644 index 8f04b05ad..000000000 --- a/packages/plugins/minos-discovery-kong/docs/usage.md +++ /dev/null @@ -1 +0,0 @@ -# Usage diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py similarity index 81% rename from packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/__init__.py rename to packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index ade34def9..a5a7caf7d 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -3,5 +3,5 @@ __version__ = "0.1.0a6" from .client import ( - MinosKongClient, + KongDiscoveryClient, ) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py similarity index 98% rename from packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/client.py rename to packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index fed3b3ec3..01c183d06 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -25,8 +25,8 @@ logger = logging.getLogger(__name__) -class MinosKongClient(DiscoveryClient, CircuitBreakerMixin): - """Minos Discovery Client class.""" +class KongDiscoveryClient(DiscoveryClient, CircuitBreakerMixin): + """Kong Discovery Client class.""" def __init__( self, diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/utils.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/utils.py similarity index 100% rename from packages/plugins/minos-discovery-kong/minos/plugins/minos_kong/utils.py rename to packages/plugins/minos-discovery-kong/minos/plugins/kong/utils.py diff --git a/packages/plugins/minos-discovery-kong/poetry.lock b/packages/plugins/minos-discovery-kong/poetry.lock index d67596ea2..891e4770d 100644 --- a/packages/plugins/minos-discovery-kong/poetry.lock +++ b/packages/plugins/minos-discovery-kong/poetry.lock @@ -1,26 +1,6 @@ -[[package]] -name = "aiohttp" -version = "3.8.1" -description = "Async http client/server framework (asyncio)" -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -aiosignal = ">=1.1.2" -async-timeout = ">=4.0.0a3,<5.0" -attrs = ">=17.3.0" -charset-normalizer = ">=2.0,<3.0" -frozenlist = ">=1.1.1" -multidict = ">=4.5,<7.0" -yarl = ">=1.0,<2.0" - -[package.extras] -speedups = ["aiodns", "brotli", "cchardet"] - [[package]] name = "aiomisc" -version = "14.4.6" +version = "15.7.3" description = "aiomisc - miscellaneous utils for asyncio" category = "main" optional = false @@ -35,7 +15,7 @@ asgi = ["aiohttp-asgi"] carbon = ["aiocarbon (>=0.15,<1.0)"] contextvars = ["contextvars (>=2.4,<3.0)"] cron = ["croniter (>=0.3.34,<0.4.0)"] -develop = ["aiocontextvars (==0.2.2)", "aiohttp (<4)", "aiohttp-asgi", "async-timeout", "coverage (==4.5.1)", "coveralls", "croniter (>=0.3.34,<0.4.0)", "fastapi", "freezegun (<1.1)", "mypy (>=0.782,<1.0)", "pylava", "pytest", "pytest-cov (>=2.5.1,<2.6.0)", "pytest-freezegun (>=0.4.2,<0.5.0)", "sphinx (>=3.5.1)", "sphinx-autobuild", "sphinx-intl", "timeout-decorator", "types-croniter", "tox (>=2.4)"] +develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-timeout", "coveralls", "croniter (>=0.3.34,<0.4.0)", "fastapi", "freezegun (<1.1)", "mypy (>=0.782,<1.0)", "pylava", "pytest", "pytest-cov (>=3.0,<4.0)", "pytest-freezegun (>=0.4.2,<0.5.0)", "pytest-rst", "pytest-subtests", "rich", "setproctitle", "sphinx-autobuild", "sphinx-intl", "sphinx (>=3.5.1)", "timeout-decorator", "tox (>=2.4)", "types-croniter"] raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] @@ -54,25 +34,6 @@ psycopg2-binary = ">=2.8.4" [package.extras] sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] -[[package]] -name = "aiosignal" -version = "1.2.0" -description = "aiosignal: a list of registered asynchronous callbacks" -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -frozenlist = ">=1.1.0" - -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "anyio" version = "3.5.0" @@ -110,7 +71,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" name = "attrs" version = "21.4.0" description = "Classes Without Boilerplate" -category = "main" +category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" @@ -120,17 +81,6 @@ docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - [[package]] name = "black" version = "22.3.0" @@ -169,14 +119,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - [[package]] name = "charset-normalizer" version = "2.0.12" @@ -257,22 +199,6 @@ flask = ["flask"] pydantic = ["pydantic"] yaml = ["pyyaml"] -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "fastavro" version = "1.4.10" @@ -287,18 +213,6 @@ lz4 = ["lz4"] snappy = ["python-snappy"] zstandard = ["zstandard"] -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - [[package]] name = "flake8" version = "4.0.1" @@ -312,14 +226,6 @@ mccabe = ">=0.6.0,<0.7.0" pycodestyle = ">=2.8.0,<2.9.0" pyflakes = ">=2.4.0,<2.5.0" -[[package]] -name = "frozenlist" -version = "1.3.0" -description = "A list-like structure which implements collections.abc.MutableSequence" -category = "main" -optional = false -python-versions = ">=3.7" - [[package]] name = "h11" version = "0.12.0" @@ -367,17 +273,6 @@ cli = ["click (>=8.0.0,<9.0.0)", "rich (>=10.0.0,<11.0.0)", "pygments (>=2.0.0,< http2 = ["h2 (>=3,<5)"] socks = ["socksio (>=1.0.0,<2.0.0)"] -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - [[package]] name = "idna" version = "3.3" @@ -386,30 +281,6 @@ category = "main" optional = false python-versions = ">=3.5" -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - [[package]] name = "iniconfig" version = "1.1.1" @@ -432,20 +303,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - [[package]] name = "lmdb" version = "1.3.0" @@ -454,26 +311,6 @@ category = "main" optional = false python-versions = "*" -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - [[package]] name = "mccabe" version = "0.6.1" @@ -484,54 +321,46 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.5.3" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false -python-versions = ">=3.9,<4.0" +python-versions = "^3.9" +develop = true [package.dependencies] -aiomisc = ">=14.0.3,<15.0.0" -aiopg = ">=1.2.1,<2.0.0" -cached-property = ">=1.5.2,<2.0.0" -dependency-injector = ">=4.32.2,<5.0.0" -fastavro = ">=1.4.0,<2.0.0" -lmdb = ">=1.2.1,<2.0.0" -orjson = ">=3.5.2,<4.0.0" +aiomisc = ">=14.0.3,<16.0.0" +aiopg = "^1.2.1" +cached-property = "^1.5.2" +dependency-injector = "^4.32.2" +fastavro = "^1.4.0" +lmdb = "^1.2.1" +orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" +uvloop = "^0.16.0" + +[package.source] +type = "directory" +url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.5.3" +version = "0.6.0" description = "The networks core of the Minos Framework" category = "main" optional = false -python-versions = ">=3.9,<4.0" +python-versions = "^3.9" +develop = true [package.dependencies] -aiohttp = ">=3.7.4,<4.0.0" -aiomisc = ">=14.0.3,<15.0.0" -aiopg = ">=1.2.1,<2.0.0" -crontab = ">=0.23.0,<0.24.0" -dependency-injector = ">=4.32.2,<5.0.0" -minos-microservice-common = ">=0.5.0,<0.6.0" -orjson = ">=3.6.5,<4.0.0" +aiopg = "^1.2.1" +crontab = "^0.23.0" +minos-microservice-common = "^0.6.0" +psycopg2-binary = "^2.9.3" -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "multidict" -version = "6.0.2" -description = "multidict implementation" -category = "main" -optional = false -python-versions = ">=3.7" +[package.source] +type = "directory" +url = "../../core/minos-microservice-networks" [[package]] name = "mypy-extensions" @@ -541,14 +370,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "orjson" version = "3.6.7" @@ -576,14 +397,6 @@ category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - [[package]] name = "platformdirs" version = "2.5.1" @@ -608,22 +421,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - [[package]] name = "psycopg2-binary" version = "2.9.3" @@ -656,14 +453,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - [[package]] name = "pyparsing" version = "3.0.7" @@ -696,14 +485,6 @@ toml = "*" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pyyaml" version = "6.0" @@ -712,24 +493,6 @@ category = "main" optional = false python-versions = ">=3.6" -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - [[package]] name = "rfc3986" version = "1.5.0" @@ -760,159 +523,6 @@ category = "main" optional = false python-versions = ">=3.5" -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - [[package]] name = "toml" version = "0.10.2" @@ -938,156 +548,32 @@ optional = false python-versions = ">=3.6" [[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - -[[package]] -name = "yarl" -version = "1.7.2" -description = "Yet another URL library" +name = "uvloop" +version = "0.16.0" +description = "Fast implementation of asyncio event loop on top of libuv" category = "main" optional = false -python-versions = ">=3.6" - -[package.dependencies] -idna = ">=2.0" -multidict = ">=4.0" - -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false python-versions = ">=3.7" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] +dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)", "aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] +docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] +test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "28a0cea8e8de8fad4b6e9ea3f3debaaeb559b2af4f98b355206d928f3aa706fe" +content-hash = "980f2d6f75effa21b4da747805178aec427e22a3dc017bb7f9360b736aa8f4a8" [metadata.files] -aiohttp = [ - {file = "aiohttp-3.8.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1ed0b6477896559f17b9eaeb6d38e07f7f9ffe40b9f0f9627ae8b9926ae260a8"}, - {file = "aiohttp-3.8.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:7dadf3c307b31e0e61689cbf9e06be7a867c563d5a63ce9dca578f956609abf8"}, - {file = "aiohttp-3.8.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:a79004bb58748f31ae1cbe9fa891054baaa46fb106c2dc7af9f8e3304dc30316"}, - {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:12de6add4038df8f72fac606dff775791a60f113a725c960f2bab01d8b8e6b15"}, - {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:6f0d5f33feb5f69ddd57a4a4bd3d56c719a141080b445cbf18f238973c5c9923"}, - {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:eaba923151d9deea315be1f3e2b31cc39a6d1d2f682f942905951f4e40200922"}, - {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:099ebd2c37ac74cce10a3527d2b49af80243e2a4fa39e7bce41617fbc35fa3c1"}, - {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:2e5d962cf7e1d426aa0e528a7e198658cdc8aa4fe87f781d039ad75dcd52c516"}, - {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:fa0ffcace9b3aa34d205d8130f7873fcfefcb6a4dd3dd705b0dab69af6712642"}, - {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:61bfc23df345d8c9716d03717c2ed5e27374e0fe6f659ea64edcd27b4b044cf7"}, - {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:31560d268ff62143e92423ef183680b9829b1b482c011713ae941997921eebc8"}, - {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:01d7bdb774a9acc838e6b8f1d114f45303841b89b95984cbb7d80ea41172a9e3"}, - {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:97ef77eb6b044134c0b3a96e16abcb05ecce892965a2124c566af0fd60f717e2"}, - {file = "aiohttp-3.8.1-cp310-cp310-win32.whl", hash = "sha256:c2aef4703f1f2ddc6df17519885dbfa3514929149d3ff900b73f45998f2532fa"}, - {file = "aiohttp-3.8.1-cp310-cp310-win_amd64.whl", hash = "sha256:713ac174a629d39b7c6a3aa757b337599798da4c1157114a314e4e391cd28e32"}, - {file = "aiohttp-3.8.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:473d93d4450880fe278696549f2e7aed8cd23708c3c1997981464475f32137db"}, - {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99b5eeae8e019e7aad8af8bb314fb908dd2e028b3cdaad87ec05095394cce632"}, - {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3af642b43ce56c24d063325dd2cf20ee012d2b9ba4c3c008755a301aaea720ad"}, - {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c3630c3ef435c0a7c549ba170a0633a56e92629aeed0e707fec832dee313fb7a"}, - {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4a4a4e30bf1edcad13fb0804300557aedd07a92cabc74382fdd0ba6ca2661091"}, - {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6f8b01295e26c68b3a1b90efb7a89029110d3a4139270b24fda961893216c440"}, - {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:a25fa703a527158aaf10dafd956f7d42ac6d30ec80e9a70846253dd13e2f067b"}, - {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:5bfde62d1d2641a1f5173b8c8c2d96ceb4854f54a44c23102e2ccc7e02f003ec"}, - {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:51467000f3647d519272392f484126aa716f747859794ac9924a7aafa86cd411"}, - {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_s390x.whl", hash = "sha256:03a6d5349c9ee8f79ab3ff3694d6ce1cfc3ced1c9d36200cb8f08ba06bd3b782"}, - {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:102e487eeb82afac440581e5d7f8f44560b36cf0bdd11abc51a46c1cd88914d4"}, - {file = "aiohttp-3.8.1-cp36-cp36m-win32.whl", hash = "sha256:4aed991a28ea3ce320dc8ce655875e1e00a11bdd29fe9444dd4f88c30d558602"}, - {file = "aiohttp-3.8.1-cp36-cp36m-win_amd64.whl", hash = "sha256:b0e20cddbd676ab8a64c774fefa0ad787cc506afd844de95da56060348021e96"}, - {file = "aiohttp-3.8.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:37951ad2f4a6df6506750a23f7cbabad24c73c65f23f72e95897bb2cecbae676"}, - {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5c23b1ad869653bc818e972b7a3a79852d0e494e9ab7e1a701a3decc49c20d51"}, - {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:15b09b06dae900777833fe7fc4b4aa426556ce95847a3e8d7548e2d19e34edb8"}, - {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:477c3ea0ba410b2b56b7efb072c36fa91b1e6fc331761798fa3f28bb224830dd"}, - {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:2f2f69dca064926e79997f45b2f34e202b320fd3782f17a91941f7eb85502ee2"}, - {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ef9612483cb35171d51d9173647eed5d0069eaa2ee812793a75373447d487aa4"}, - {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:6d69f36d445c45cda7b3b26afef2fc34ef5ac0cdc75584a87ef307ee3c8c6d00"}, - {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:55c3d1072704d27401c92339144d199d9de7b52627f724a949fc7d5fc56d8b93"}, - {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:b9d00268fcb9f66fbcc7cd9fe423741d90c75ee029a1d15c09b22d23253c0a44"}, - {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:07b05cd3305e8a73112103c834e91cd27ce5b4bd07850c4b4dbd1877d3f45be7"}, - {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:c34dc4958b232ef6188c4318cb7b2c2d80521c9a56c52449f8f93ab7bc2a8a1c"}, - {file = "aiohttp-3.8.1-cp37-cp37m-win32.whl", hash = "sha256:d2f9b69293c33aaa53d923032fe227feac867f81682f002ce33ffae978f0a9a9"}, - {file = "aiohttp-3.8.1-cp37-cp37m-win_amd64.whl", hash = "sha256:6ae828d3a003f03ae31915c31fa684b9890ea44c9c989056fea96e3d12a9fa17"}, - {file = "aiohttp-3.8.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:0c7ebbbde809ff4e970824b2b6cb7e4222be6b95a296e46c03cf050878fc1785"}, - {file = "aiohttp-3.8.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:8b7ef7cbd4fec9a1e811a5de813311ed4f7ac7d93e0fda233c9b3e1428f7dd7b"}, - {file = "aiohttp-3.8.1-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:c3d6a4d0619e09dcd61021debf7059955c2004fa29f48788a3dfaf9c9901a7cd"}, - {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:718626a174e7e467f0558954f94af117b7d4695d48eb980146016afa4b580b2e"}, - {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:589c72667a5febd36f1315aa6e5f56dd4aa4862df295cb51c769d16142ddd7cd"}, - {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2ed076098b171573161eb146afcb9129b5ff63308960aeca4b676d9d3c35e700"}, - {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:086f92daf51a032d062ec5f58af5ca6a44d082c35299c96376a41cbb33034675"}, - {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:11691cf4dc5b94236ccc609b70fec991234e7ef8d4c02dd0c9668d1e486f5abf"}, - {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:31d1e1c0dbf19ebccbfd62eff461518dcb1e307b195e93bba60c965a4dcf1ba0"}, - {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:11a67c0d562e07067c4e86bffc1553f2cf5b664d6111c894671b2b8712f3aba5"}, - {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:bb01ba6b0d3f6c68b89fce7305080145d4877ad3acaed424bae4d4ee75faa950"}, - {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:44db35a9e15d6fe5c40d74952e803b1d96e964f683b5a78c3cc64eb177878155"}, - {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:844a9b460871ee0a0b0b68a64890dae9c415e513db0f4a7e3cab41a0f2fedf33"}, - {file = "aiohttp-3.8.1-cp38-cp38-win32.whl", hash = "sha256:7d08744e9bae2ca9c382581f7dce1273fe3c9bae94ff572c3626e8da5b193c6a"}, - {file = "aiohttp-3.8.1-cp38-cp38-win_amd64.whl", hash = "sha256:04d48b8ce6ab3cf2097b1855e1505181bdd05586ca275f2505514a6e274e8e75"}, - {file = "aiohttp-3.8.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:f5315a2eb0239185af1bddb1abf472d877fede3cc8d143c6cddad37678293237"}, - {file = "aiohttp-3.8.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:a996d01ca39b8dfe77440f3cd600825d05841088fd6bc0144cc6c2ec14cc5f74"}, - {file = "aiohttp-3.8.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:13487abd2f761d4be7c8ff9080de2671e53fff69711d46de703c310c4c9317ca"}, - {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ea302f34477fda3f85560a06d9ebdc7fa41e82420e892fc50b577e35fc6a50b2"}, - {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a2f635ce61a89c5732537a7896b6319a8fcfa23ba09bec36e1b1ac0ab31270d2"}, - {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e999f2d0e12eea01caeecb17b653f3713d758f6dcc770417cf29ef08d3931421"}, - {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0770e2806a30e744b4e21c9d73b7bee18a1cfa3c47991ee2e5a65b887c49d5cf"}, - {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d15367ce87c8e9e09b0f989bfd72dc641bcd04ba091c68cd305312d00962addd"}, - {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:6c7cefb4b0640703eb1069835c02486669312bf2f12b48a748e0a7756d0de33d"}, - {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:71927042ed6365a09a98a6377501af5c9f0a4d38083652bcd2281a06a5976724"}, - {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:28d490af82bc6b7ce53ff31337a18a10498303fe66f701ab65ef27e143c3b0ef"}, - {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:b6613280ccedf24354406caf785db748bebbddcf31408b20c0b48cb86af76866"}, - {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:81e3d8c34c623ca4e36c46524a3530e99c0bc95ed068fd6e9b55cb721d408fb2"}, - {file = "aiohttp-3.8.1-cp39-cp39-win32.whl", hash = "sha256:7187a76598bdb895af0adbd2fb7474d7f6025d170bc0a1130242da817ce9e7d1"}, - {file = "aiohttp-3.8.1-cp39-cp39-win_amd64.whl", hash = "sha256:1c182cb873bc91b411e184dab7a2b664d4fea2743df0e4d57402f7f3fa644bac"}, - {file = "aiohttp-3.8.1.tar.gz", hash = "sha256:fc5471e1a54de15ef71c1bc6ebe80d4dc681ea600e68bfd1cbce40427f0b7578"}, -] aiomisc = [ - {file = "aiomisc-14.4.6-py3-none-any.whl", hash = "sha256:beaa248f92acce53857f459499210643274cf06b33c7eb0c9d1f35feaad0d054"}, - {file = "aiomisc-14.4.6.tar.gz", hash = "sha256:a547a94908db9213fd0acde2674973b4a7a986ad82989215f73488903b65746e"}, + {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, + {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, ] -aiosignal = [ - {file = "aiosignal-1.2.0-py3-none-any.whl", hash = "sha256:26e62109036cd181df6e6ad646f91f0dcfd05fe16d0cb924138ff2ab75d64e3a"}, - {file = "aiosignal-1.2.0.tar.gz", hash = "sha256:78ed67db6c7b7ced4f98e495e572106d5c432a93e1ddd1bf475e1dc05f5b7df2"}, -] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] anyio = [ {file = "anyio-3.5.0-py3-none-any.whl", hash = "sha256:b5fa16c5ff93fa1046f2eeb5bbff2dad4d3514d6cda61d02816dba34fa8c3c2e"}, {file = "anyio-3.5.0.tar.gz", hash = "sha256:a0aeffe2fb1fdf374a8e4b471444f0f3ac4fb9f5a5b542b48824475e0042a5a6"}, @@ -1104,10 +590,6 @@ attrs = [ {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] black = [ {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, @@ -1141,10 +623,6 @@ certifi = [ {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, ] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] charset-normalizer = [ {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, @@ -1245,14 +723,6 @@ dependency-injector = [ {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, -] fastavro = [ {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, @@ -1271,75 +741,10 @@ fastavro = [ {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, ] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] -frozenlist = [ - {file = "frozenlist-1.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:d2257aaba9660f78c7b1d8fea963b68f3feffb1a9d5d05a18401ca9eb3e8d0a3"}, - {file = "frozenlist-1.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:4a44ebbf601d7bac77976d429e9bdb5a4614f9f4027777f9e54fd765196e9d3b"}, - {file = "frozenlist-1.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:45334234ec30fc4ea677f43171b18a27505bfb2dba9aca4398a62692c0ea8868"}, - {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:47be22dc27ed933d55ee55845d34a3e4e9f6fee93039e7f8ebadb0c2f60d403f"}, - {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:03a7dd1bfce30216a3f51a84e6dd0e4a573d23ca50f0346634916ff105ba6e6b"}, - {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:691ddf6dc50480ce49f68441f1d16a4c3325887453837036e0fb94736eae1e58"}, - {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:bde99812f237f79eaf3f04ebffd74f6718bbd216101b35ac7955c2d47c17da02"}, - {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6a202458d1298ced3768f5a7d44301e7c86defac162ace0ab7434c2e961166e8"}, - {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b9e3e9e365991f8cc5f5edc1fd65b58b41d0514a6a7ad95ef5c7f34eb49b3d3e"}, - {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:04cb491c4b1c051734d41ea2552fde292f5f3a9c911363f74f39c23659c4af78"}, - {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:436496321dad302b8b27ca955364a439ed1f0999311c393dccb243e451ff66aa"}, - {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:754728d65f1acc61e0f4df784456106e35afb7bf39cfe37227ab00436fb38676"}, - {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:6eb275c6385dd72594758cbe96c07cdb9bd6becf84235f4a594bdf21e3596c9d"}, - {file = "frozenlist-1.3.0-cp310-cp310-win32.whl", hash = "sha256:e30b2f9683812eb30cf3f0a8e9f79f8d590a7999f731cf39f9105a7c4a39489d"}, - {file = "frozenlist-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:f7353ba3367473d1d616ee727945f439e027f0bb16ac1a750219a8344d1d5d3c"}, - {file = "frozenlist-1.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:88aafd445a233dbbf8a65a62bc3249a0acd0d81ab18f6feb461cc5a938610d24"}, - {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4406cfabef8f07b3b3af0f50f70938ec06d9f0fc26cbdeaab431cbc3ca3caeaa"}, - {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:8cf829bd2e2956066dd4de43fd8ec881d87842a06708c035b37ef632930505a2"}, - {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:603b9091bd70fae7be28bdb8aa5c9990f4241aa33abb673390a7f7329296695f"}, - {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:25af28b560e0c76fa41f550eacb389905633e7ac02d6eb3c09017fa1c8cdfde1"}, - {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:94c7a8a9fc9383b52c410a2ec952521906d355d18fccc927fca52ab575ee8b93"}, - {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:65bc6e2fece04e2145ab6e3c47428d1bbc05aede61ae365b2c1bddd94906e478"}, - {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:3f7c935c7b58b0d78c0beea0c7358e165f95f1fd8a7e98baa40d22a05b4a8141"}, - {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:bd89acd1b8bb4f31b47072615d72e7f53a948d302b7c1d1455e42622de180eae"}, - {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:6983a31698490825171be44ffbafeaa930ddf590d3f051e397143a5045513b01"}, - {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:adac9700675cf99e3615eb6a0eb5e9f5a4143c7d42c05cea2e7f71c27a3d0846"}, - {file = "frozenlist-1.3.0-cp37-cp37m-win32.whl", hash = "sha256:0c36e78b9509e97042ef869c0e1e6ef6429e55817c12d78245eb915e1cca7468"}, - {file = "frozenlist-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:57f4d3f03a18facacb2a6bcd21bccd011e3b75d463dc49f838fd699d074fabd1"}, - {file = "frozenlist-1.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:8c905a5186d77111f02144fab5b849ab524f1e876a1e75205cd1386a9be4b00a"}, - {file = "frozenlist-1.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:b5009062d78a8c6890d50b4e53b0ddda31841b3935c1937e2ed8c1bda1c7fb9d"}, - {file = "frozenlist-1.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:2fdc3cd845e5a1f71a0c3518528bfdbfe2efaf9886d6f49eacc5ee4fd9a10953"}, - {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92e650bd09b5dda929523b9f8e7f99b24deac61240ecc1a32aeba487afcd970f"}, - {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:40dff8962b8eba91fd3848d857203f0bd704b5f1fa2b3fc9af64901a190bba08"}, - {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:768efd082074bb203c934e83a61654ed4931ef02412c2fbdecea0cff7ecd0274"}, - {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:006d3595e7d4108a12025ddf415ae0f6c9e736e726a5db0183326fd191b14c5e"}, - {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:871d42623ae15eb0b0e9df65baeee6976b2e161d0ba93155411d58ff27483ad8"}, - {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:aff388be97ef2677ae185e72dc500d19ecaf31b698986800d3fc4f399a5e30a5"}, - {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:9f892d6a94ec5c7b785e548e42722e6f3a52f5f32a8461e82ac3e67a3bd073f1"}, - {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:e982878792c971cbd60ee510c4ee5bf089a8246226dea1f2138aa0bb67aff148"}, - {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:c6c321dd013e8fc20735b92cb4892c115f5cdb82c817b1e5b07f6b95d952b2f0"}, - {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:30530930410855c451bea83f7b272fb1c495ed9d5cc72895ac29e91279401db3"}, - {file = "frozenlist-1.3.0-cp38-cp38-win32.whl", hash = "sha256:40ec383bc194accba825fbb7d0ef3dda5736ceab2375462f1d8672d9f6b68d07"}, - {file = "frozenlist-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:f20baa05eaa2bcd5404c445ec51aed1c268d62600362dc6cfe04fae34a424bd9"}, - {file = "frozenlist-1.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:0437fe763fb5d4adad1756050cbf855bbb2bf0d9385c7bb13d7a10b0dd550486"}, - {file = "frozenlist-1.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b684c68077b84522b5c7eafc1dc735bfa5b341fb011d5552ebe0968e22ed641c"}, - {file = "frozenlist-1.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:93641a51f89473837333b2f8100f3f89795295b858cd4c7d4a1f18e299dc0a4f"}, - {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d6d32ff213aef0fd0bcf803bffe15cfa2d4fde237d1d4838e62aec242a8362fa"}, - {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:31977f84828b5bb856ca1eb07bf7e3a34f33a5cddce981d880240ba06639b94d"}, - {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3c62964192a1c0c30b49f403495911298810bada64e4f03249ca35a33ca0417a"}, - {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:4eda49bea3602812518765810af732229b4291d2695ed24a0a20e098c45a707b"}, - {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:acb267b09a509c1df5a4ca04140da96016f40d2ed183cdc356d237286c971b51"}, - {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:e1e26ac0a253a2907d654a37e390904426d5ae5483150ce3adedb35c8c06614a"}, - {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:f96293d6f982c58ebebb428c50163d010c2f05de0cde99fd681bfdc18d4b2dc2"}, - {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:e84cb61b0ac40a0c3e0e8b79c575161c5300d1d89e13c0e02f76193982f066ed"}, - {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:ff9310f05b9d9c5c4dd472983dc956901ee6cb2c3ec1ab116ecdde25f3ce4951"}, - {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:d26b650b71fdc88065b7a21f8ace70175bcf3b5bdba5ea22df4bfd893e795a3b"}, - {file = "frozenlist-1.3.0-cp39-cp39-win32.whl", hash = "sha256:01a73627448b1f2145bddb6e6c2259988bb8aee0fb361776ff8604b99616cd08"}, - {file = "frozenlist-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:772965f773757a6026dea111a15e6e2678fbd6216180f82a48a40b27de1ee2ab"}, - {file = "frozenlist-1.3.0.tar.gz", hash = "sha256:ce6f2ba0edb7b0c1d8976565298ad2deba6f8064d2bebb6ffce2ca896eb35b0b"}, -] h11 = [ {file = "h11-0.12.0-py3-none-any.whl", hash = "sha256:36a3cb8c0a032f56e2da7084577878a035d3b61d104230d4bd49c0c6b555a9c6"}, {file = "h11-0.12.0.tar.gz", hash = "sha256:47222cb6067e4a307d535814917cd98fd0a57b6788ce715755fa2b6c28b56042"}, @@ -1352,22 +757,10 @@ httpx = [ {file = "httpx-0.22.0-py3-none-any.whl", hash = "sha256:e35e83d1d2b9b2a609ef367cc4c1e66fd80b750348b20cc9e19d1952fc2ca3f6"}, {file = "httpx-0.22.0.tar.gz", hash = "sha256:d8e778f76d9bbd46af49e7f062467e3157a5a3d2ae4876a4bbfd8a51ed9c9cb4"}, ] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] idna = [ {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, ] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, @@ -1376,10 +769,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] lmdb = [ {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, @@ -1409,137 +798,16 @@ lmdb = [ {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, ] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] -minos-microservice-common = [ - {file = "minos-microservice-common-0.5.3.tar.gz", hash = "sha256:91e927504c35646626fb4597f5bd65566bc055882ddd3af42cba24ca5fc4c9af"}, - {file = "minos_microservice_common-0.5.3-py3-none-any.whl", hash = "sha256:9eea7eef5abd73a844a4ef12649d8f10323b561e27db20178398e41887e42e85"}, -] -minos-microservice-networks = [ - {file = "minos-microservice-networks-0.5.3.tar.gz", hash = "sha256:9bbad95410d36942ac69a5b7fc5500de24f26e4dff03e894a351c2902d38b5b9"}, - {file = "minos_microservice_networks-0.5.3-py3-none-any.whl", hash = "sha256:3eeef3972cac838414118347511f6d0e0a75d25af374b75af684e6d5d8cb7750"}, -] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] -multidict = [ - {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:0b9e95a740109c6047602f4db4da9949e6c5945cefbad34a1299775ddc9a62e2"}, - {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ac0e27844758d7177989ce406acc6a83c16ed4524ebc363c1f748cba184d89d3"}, - {file = "multidict-6.0.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:041b81a5f6b38244b34dc18c7b6aba91f9cdaf854d9a39e5ff0b58e2b5773b9c"}, - {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5fdda29a3c7e76a064f2477c9aab1ba96fd94e02e386f1e665bca1807fc5386f"}, - {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3368bf2398b0e0fcbf46d85795adc4c259299fec50c1416d0f77c0a843a3eed9"}, - {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f4f052ee022928d34fe1f4d2bc743f32609fb79ed9c49a1710a5ad6b2198db20"}, - {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:225383a6603c086e6cef0f2f05564acb4f4d5f019a4e3e983f572b8530f70c88"}, - {file = "multidict-6.0.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:50bd442726e288e884f7be9071016c15a8742eb689a593a0cac49ea093eef0a7"}, - {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:47e6a7e923e9cada7c139531feac59448f1f47727a79076c0b1ee80274cd8eee"}, - {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:0556a1d4ea2d949efe5fd76a09b4a82e3a4a30700553a6725535098d8d9fb672"}, - {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:626fe10ac87851f4cffecee161fc6f8f9853f0f6f1035b59337a51d29ff3b4f9"}, - {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:8064b7c6f0af936a741ea1efd18690bacfbae4078c0c385d7c3f611d11f0cf87"}, - {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:2d36e929d7f6a16d4eb11b250719c39560dd70545356365b494249e2186bc389"}, - {file = "multidict-6.0.2-cp310-cp310-win32.whl", hash = "sha256:fcb91630817aa8b9bc4a74023e4198480587269c272c58b3279875ed7235c293"}, - {file = "multidict-6.0.2-cp310-cp310-win_amd64.whl", hash = "sha256:8cbf0132f3de7cc6c6ce00147cc78e6439ea736cee6bca4f068bcf892b0fd658"}, - {file = "multidict-6.0.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:05f6949d6169878a03e607a21e3b862eaf8e356590e8bdae4227eedadacf6e51"}, - {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2c2e459f7050aeb7c1b1276763364884595d47000c1cddb51764c0d8976e608"}, - {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d0509e469d48940147e1235d994cd849a8f8195e0bca65f8f5439c56e17872a3"}, - {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:514fe2b8d750d6cdb4712346a2c5084a80220821a3e91f3f71eec11cf8d28fd4"}, - {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19adcfc2a7197cdc3987044e3f415168fc5dc1f720c932eb1ef4f71a2067e08b"}, - {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b9d153e7f1f9ba0b23ad1568b3b9e17301e23b042c23870f9ee0522dc5cc79e8"}, - {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:aef9cc3d9c7d63d924adac329c33835e0243b5052a6dfcbf7732a921c6e918ba"}, - {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:4571f1beddff25f3e925eea34268422622963cd8dc395bb8778eb28418248e43"}, - {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:d48b8ee1d4068561ce8033d2c344cf5232cb29ee1a0206a7b828c79cbc5982b8"}, - {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:45183c96ddf61bf96d2684d9fbaf6f3564d86b34cb125761f9a0ef9e36c1d55b"}, - {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:75bdf08716edde767b09e76829db8c1e5ca9d8bb0a8d4bd94ae1eafe3dac5e15"}, - {file = "multidict-6.0.2-cp37-cp37m-win32.whl", hash = "sha256:a45e1135cb07086833ce969555df39149680e5471c04dfd6a915abd2fc3f6dbc"}, - {file = "multidict-6.0.2-cp37-cp37m-win_amd64.whl", hash = "sha256:6f3cdef8a247d1eafa649085812f8a310e728bdf3900ff6c434eafb2d443b23a"}, - {file = "multidict-6.0.2-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:0327292e745a880459ef71be14e709aaea2f783f3537588fb4ed09b6c01bca60"}, - {file = "multidict-6.0.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:e875b6086e325bab7e680e4316d667fc0e5e174bb5611eb16b3ea121c8951b86"}, - {file = "multidict-6.0.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:feea820722e69451743a3d56ad74948b68bf456984d63c1a92e8347b7b88452d"}, - {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9cc57c68cb9139c7cd6fc39f211b02198e69fb90ce4bc4a094cf5fe0d20fd8b0"}, - {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:497988d6b6ec6ed6f87030ec03280b696ca47dbf0648045e4e1d28b80346560d"}, - {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:89171b2c769e03a953d5969b2f272efa931426355b6c0cb508022976a17fd376"}, - {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:684133b1e1fe91eda8fa7447f137c9490a064c6b7f392aa857bba83a28cfb693"}, - {file = "multidict-6.0.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:fd9fc9c4849a07f3635ccffa895d57abce554b467d611a5009ba4f39b78a8849"}, - {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:e07c8e79d6e6fd37b42f3250dba122053fddb319e84b55dd3a8d6446e1a7ee49"}, - {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:4070613ea2227da2bfb2c35a6041e4371b0af6b0be57f424fe2318b42a748516"}, - {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:47fbeedbf94bed6547d3aa632075d804867a352d86688c04e606971595460227"}, - {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:5774d9218d77befa7b70d836004a768fb9aa4fdb53c97498f4d8d3f67bb9cfa9"}, - {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:2957489cba47c2539a8eb7ab32ff49101439ccf78eab724c828c1a54ff3ff98d"}, - {file = "multidict-6.0.2-cp38-cp38-win32.whl", hash = "sha256:e5b20e9599ba74391ca0cfbd7b328fcc20976823ba19bc573983a25b32e92b57"}, - {file = "multidict-6.0.2-cp38-cp38-win_amd64.whl", hash = "sha256:8004dca28e15b86d1b1372515f32eb6f814bdf6f00952699bdeb541691091f96"}, - {file = "multidict-6.0.2-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:2e4a0785b84fb59e43c18a015ffc575ba93f7d1dbd272b4cdad9f5134b8a006c"}, - {file = "multidict-6.0.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:6701bf8a5d03a43375909ac91b6980aea74b0f5402fbe9428fc3f6edf5d9677e"}, - {file = "multidict-6.0.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:a007b1638e148c3cfb6bf0bdc4f82776cef0ac487191d093cdc316905e504071"}, - {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:07a017cfa00c9890011628eab2503bee5872f27144936a52eaab449be5eaf032"}, - {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c207fff63adcdf5a485969131dc70e4b194327666b7e8a87a97fbc4fd80a53b2"}, - {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:373ba9d1d061c76462d74e7de1c0c8e267e9791ee8cfefcf6b0b2495762c370c"}, - {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bfba7c6d5d7c9099ba21f84662b037a0ffd4a5e6b26ac07d19e423e6fdf965a9"}, - {file = "multidict-6.0.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:19d9bad105dfb34eb539c97b132057a4e709919ec4dd883ece5838bcbf262b80"}, - {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:de989b195c3d636ba000ee4281cd03bb1234635b124bf4cd89eeee9ca8fcb09d"}, - {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:7c40b7bbece294ae3a87c1bc2abff0ff9beef41d14188cda94ada7bcea99b0fb"}, - {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:d16cce709ebfadc91278a1c005e3c17dd5f71f5098bfae1035149785ea6e9c68"}, - {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:a2c34a93e1d2aa35fbf1485e5010337c72c6791407d03aa5f4eed920343dd360"}, - {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:feba80698173761cddd814fa22e88b0661e98cb810f9f986c54aa34d281e4937"}, - {file = "multidict-6.0.2-cp39-cp39-win32.whl", hash = "sha256:23b616fdc3c74c9fe01d76ce0d1ce872d2d396d8fa8e4899398ad64fb5aa214a"}, - {file = "multidict-6.0.2-cp39-cp39-win_amd64.whl", hash = "sha256:4bae31803d708f6f15fd98be6a6ac0b6958fcf68fda3c77a048a4f9073704aae"}, - {file = "multidict-6.0.2.tar.gz", hash = "sha256:5ff3bd75f38e4c43f1f470f2df7a4d430b821c4ce22be384e1459cb57d6bb013"}, -] +minos-microservice-common = [] +minos-microservice-networks = [] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] orjson = [ {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, @@ -1582,10 +850,6 @@ pathspec = [ {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] platformdirs = [ {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, @@ -1594,10 +858,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, @@ -1668,10 +928,6 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] pyparsing = [ {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, @@ -1680,10 +936,6 @@ pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, ] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, @@ -1719,10 +971,6 @@ pyyaml = [ {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] rfc3986 = [ {file = "rfc3986-1.5.0-py2.py3-none-any.whl", hash = "sha256:a86d6e1f5b1dc238b218b012df0aa79409667bb209e58da56d0b94704e712a97"}, {file = "rfc3986-1.5.0.tar.gz", hash = "sha256:270aaf10d87d0d4e095063c65bf3ddbc6ee3d0b226328ce21e036f946e421835"}, @@ -1735,50 +983,6 @@ sniffio = [ {file = "sniffio-1.2.0-py3-none-any.whl", hash = "sha256:471b71698eac1c2112a40ce2752bb2f4a4814c22a54a3eed3676bc0f5ca9f663"}, {file = "sniffio-1.2.0.tar.gz", hash = "sha256:c4666eecec1d3f50960c6bdf61ab7bc350648da6c126e3cf6898d8cd4ddcd3de"}, ] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] toml = [ {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, @@ -1791,89 +995,21 @@ typing-extensions = [ {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, ] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] -yarl = [ - {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:f2a8508f7350512434e41065684076f640ecce176d262a7d54f0da41d99c5a95"}, - {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:da6df107b9ccfe52d3a48165e48d72db0eca3e3029b5b8cb4fe6ee3cb870ba8b"}, - {file = "yarl-1.7.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:a1d0894f238763717bdcfea74558c94e3bc34aeacd3351d769460c1a586a8b05"}, - {file = "yarl-1.7.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfe4b95b7e00c6635a72e2d00b478e8a28bfb122dc76349a06e20792eb53a523"}, - {file = "yarl-1.7.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c145ab54702334c42237a6c6c4cc08703b6aa9b94e2f227ceb3d477d20c36c63"}, - {file = "yarl-1.7.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1ca56f002eaf7998b5fcf73b2421790da9d2586331805f38acd9997743114e98"}, - {file = "yarl-1.7.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:1d3d5ad8ea96bd6d643d80c7b8d5977b4e2fb1bab6c9da7322616fd26203d125"}, - {file = "yarl-1.7.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:167ab7f64e409e9bdd99333fe8c67b5574a1f0495dcfd905bc7454e766729b9e"}, - {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:95a1873b6c0dd1c437fb3bb4a4aaa699a48c218ac7ca1e74b0bee0ab16c7d60d"}, - {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:6152224d0a1eb254f97df3997d79dadd8bb2c1a02ef283dbb34b97d4f8492d23"}, - {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:5bb7d54b8f61ba6eee541fba4b83d22b8a046b4ef4d8eb7f15a7e35db2e1e245"}, - {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:9c1f083e7e71b2dd01f7cd7434a5f88c15213194df38bc29b388ccdf1492b739"}, - {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:f44477ae29025d8ea87ec308539f95963ffdc31a82f42ca9deecf2d505242e72"}, - {file = "yarl-1.7.2-cp310-cp310-win32.whl", hash = "sha256:cff3ba513db55cc6a35076f32c4cdc27032bd075c9faef31fec749e64b45d26c"}, - {file = "yarl-1.7.2-cp310-cp310-win_amd64.whl", hash = "sha256:c9c6d927e098c2d360695f2e9d38870b2e92e0919be07dbe339aefa32a090265"}, - {file = "yarl-1.7.2-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:9b4c77d92d56a4c5027572752aa35082e40c561eec776048330d2907aead891d"}, - {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c01a89a44bb672c38f42b49cdb0ad667b116d731b3f4c896f72302ff77d71656"}, - {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c19324a1c5399b602f3b6e7db9478e5b1adf5cf58901996fc973fe4fccd73eed"}, - {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3abddf0b8e41445426d29f955b24aeecc83fa1072be1be4e0d194134a7d9baee"}, - {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:6a1a9fe17621af43e9b9fcea8bd088ba682c8192d744b386ee3c47b56eaabb2c"}, - {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:8b0915ee85150963a9504c10de4e4729ae700af11df0dc5550e6587ed7891e92"}, - {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:29e0656d5497733dcddc21797da5a2ab990c0cb9719f1f969e58a4abac66234d"}, - {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:bf19725fec28452474d9887a128e98dd67eee7b7d52e932e6949c532d820dc3b"}, - {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:d6f3d62e16c10e88d2168ba2d065aa374e3c538998ed04996cd373ff2036d64c"}, - {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_s390x.whl", hash = "sha256:ac10bbac36cd89eac19f4e51c032ba6b412b3892b685076f4acd2de18ca990aa"}, - {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:aa32aaa97d8b2ed4e54dc65d241a0da1c627454950f7d7b1f95b13985afd6c5d"}, - {file = "yarl-1.7.2-cp36-cp36m-win32.whl", hash = "sha256:87f6e082bce21464857ba58b569370e7b547d239ca22248be68ea5d6b51464a1"}, - {file = "yarl-1.7.2-cp36-cp36m-win_amd64.whl", hash = "sha256:ac35ccde589ab6a1870a484ed136d49a26bcd06b6a1c6397b1967ca13ceb3913"}, - {file = "yarl-1.7.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a467a431a0817a292121c13cbe637348b546e6ef47ca14a790aa2fa8cc93df63"}, - {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6ab0c3274d0a846840bf6c27d2c60ba771a12e4d7586bf550eefc2df0b56b3b4"}, - {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d260d4dc495c05d6600264a197d9d6f7fc9347f21d2594926202fd08cf89a8ba"}, - {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:fc4dd8b01a8112809e6b636b00f487846956402834a7fd59d46d4f4267181c41"}, - {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:c1164a2eac148d85bbdd23e07dfcc930f2e633220f3eb3c3e2a25f6148c2819e"}, - {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:67e94028817defe5e705079b10a8438b8cb56e7115fa01640e9c0bb3edf67332"}, - {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:89ccbf58e6a0ab89d487c92a490cb5660d06c3a47ca08872859672f9c511fc52"}, - {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:8cce6f9fa3df25f55521fbb5c7e4a736683148bcc0c75b21863789e5185f9185"}, - {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:211fcd65c58bf250fb994b53bc45a442ddc9f441f6fec53e65de8cba48ded986"}, - {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:c10ea1e80a697cf7d80d1ed414b5cb8f1eec07d618f54637067ae3c0334133c4"}, - {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:52690eb521d690ab041c3919666bea13ab9fbff80d615ec16fa81a297131276b"}, - {file = "yarl-1.7.2-cp37-cp37m-win32.whl", hash = "sha256:695ba021a9e04418507fa930d5f0704edbce47076bdcfeeaba1c83683e5649d1"}, - {file = "yarl-1.7.2-cp37-cp37m-win_amd64.whl", hash = "sha256:c17965ff3706beedafd458c452bf15bac693ecd146a60a06a214614dc097a271"}, - {file = "yarl-1.7.2-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:fce78593346c014d0d986b7ebc80d782b7f5e19843ca798ed62f8e3ba8728576"}, - {file = "yarl-1.7.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:c2a1ac41a6aa980db03d098a5531f13985edcb451bcd9d00670b03129922cd0d"}, - {file = "yarl-1.7.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:39d5493c5ecd75c8093fa7700a2fb5c94fe28c839c8e40144b7ab7ccba6938c8"}, - {file = "yarl-1.7.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1eb6480ef366d75b54c68164094a6a560c247370a68c02dddb11f20c4c6d3c9d"}, - {file = "yarl-1.7.2-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:5ba63585a89c9885f18331a55d25fe81dc2d82b71311ff8bd378fc8004202ff6"}, - {file = "yarl-1.7.2-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e39378894ee6ae9f555ae2de332d513a5763276a9265f8e7cbaeb1b1ee74623a"}, - {file = "yarl-1.7.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:c0910c6b6c31359d2f6184828888c983d54d09d581a4a23547a35f1d0b9484b1"}, - {file = "yarl-1.7.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6feca8b6bfb9eef6ee057628e71e1734caf520a907b6ec0d62839e8293e945c0"}, - {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:8300401dc88cad23f5b4e4c1226f44a5aa696436a4026e456fe0e5d2f7f486e6"}, - {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:788713c2896f426a4e166b11f4ec538b5736294ebf7d5f654ae445fd44270832"}, - {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:fd547ec596d90c8676e369dd8a581a21227fe9b4ad37d0dc7feb4ccf544c2d59"}, - {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:737e401cd0c493f7e3dd4db72aca11cfe069531c9761b8ea474926936b3c57c8"}, - {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:baf81561f2972fb895e7844882898bda1eef4b07b5b385bcd308d2098f1a767b"}, - {file = "yarl-1.7.2-cp38-cp38-win32.whl", hash = "sha256:ede3b46cdb719c794427dcce9d8beb4abe8b9aa1e97526cc20de9bd6583ad1ef"}, - {file = "yarl-1.7.2-cp38-cp38-win_amd64.whl", hash = "sha256:cc8b7a7254c0fc3187d43d6cb54b5032d2365efd1df0cd1749c0c4df5f0ad45f"}, - {file = "yarl-1.7.2-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:580c1f15500e137a8c37053e4cbf6058944d4c114701fa59944607505c2fe3a0"}, - {file = "yarl-1.7.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:3ec1d9a0d7780416e657f1e405ba35ec1ba453a4f1511eb8b9fbab81cb8b3ce1"}, - {file = "yarl-1.7.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:3bf8cfe8856708ede6a73907bf0501f2dc4e104085e070a41f5d88e7faf237f3"}, - {file = "yarl-1.7.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1be4bbb3d27a4e9aa5f3df2ab61e3701ce8fcbd3e9846dbce7c033a7e8136746"}, - {file = "yarl-1.7.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:534b047277a9a19d858cde163aba93f3e1677d5acd92f7d10ace419d478540de"}, - {file = "yarl-1.7.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c6ddcd80d79c96eb19c354d9dca95291589c5954099836b7c8d29278a7ec0bda"}, - {file = "yarl-1.7.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:9bfcd43c65fbb339dc7086b5315750efa42a34eefad0256ba114cd8ad3896f4b"}, - {file = "yarl-1.7.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f64394bd7ceef1237cc604b5a89bf748c95982a84bcd3c4bbeb40f685c810794"}, - {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:044daf3012e43d4b3538562da94a88fb12a6490652dbc29fb19adfa02cf72eac"}, - {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:368bcf400247318382cc150aaa632582d0780b28ee6053cd80268c7e72796dec"}, - {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:bab827163113177aee910adb1f48ff7af31ee0289f434f7e22d10baf624a6dfe"}, - {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:0cba38120db72123db7c58322fa69e3c0efa933040ffb586c3a87c063ec7cae8"}, - {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:59218fef177296451b23214c91ea3aba7858b4ae3306dde120224cfe0f7a6ee8"}, - {file = "yarl-1.7.2-cp39-cp39-win32.whl", hash = "sha256:1edc172dcca3f11b38a9d5c7505c83c1913c0addc99cd28e993efeaafdfaa18d"}, - {file = "yarl-1.7.2-cp39-cp39-win_amd64.whl", hash = "sha256:797c2c412b04403d2da075fb93c123df35239cd7b4cc4e0cd9e5839b73f52c58"}, - {file = "yarl-1.7.2.tar.gz", hash = "sha256:45399b46d60c253327a460e99856752009fcee5f5d3c80b2f7c0cae1c38d56dd"}, -] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, +uvloop = [ + {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, + {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, + {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:bd53f7f5db562f37cd64a3af5012df8cac2c464c97e732ed556800129505bd64"}, + {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:772206116b9b57cd625c8a88f2413df2fcfd0b496eb188b82a43bed7af2c2ec9"}, + {file = "uvloop-0.16.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:b572256409f194521a9895aef274cea88731d14732343da3ecdb175228881638"}, + {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:04ff57aa137230d8cc968f03481176041ae789308b4d5079118331ab01112450"}, + {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3a19828c4f15687675ea912cc28bbcb48e9bb907c801873bd1519b96b04fb805"}, + {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e814ac2c6f9daf4c36eb8e85266859f42174a4ff0d71b99405ed559257750382"}, + {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:bd8f42ea1ea8f4e84d265769089964ddda95eb2bb38b5cbe26712b0616c3edee"}, + {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:647e481940379eebd314c00440314c81ea547aa636056f554d491e40503c8464"}, + {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e0d26fa5875d43ddbb0d9d79a447d2ace4180d9e3239788208527c4784f7cab"}, + {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:6ccd57ae8db17d677e9e06192e9c9ec4bd2066b77790f9aa7dede2cc4008ee8f"}, + {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:089b4834fd299d82d83a25e3335372f12117a7d38525217c2258e9b9f4578897"}, + {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98d117332cc9e5ea8dfdc2b28b0a23f60370d02e1395f88f40d1effd2cb86c4f"}, + {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, + {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index b6b24fa39..ddfff730e 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -1,5 +1,5 @@ [tool.poetry] -name = "minos-kong" +name = "minos-discovery-kong" version = "0.1.0a0" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" readme = "README.md" @@ -31,24 +31,18 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.5.0" -minos-microservice-networks = "^0.5.0" +minos-microservice-common = "^0.6.0" +minos-microservice-networks = "^0.6.0" httpx = "^0.22.0" [tool.poetry.dev-dependencies] -minos-microservice-common = "^0.5.0" -minos-microservice-networks = "^0.5.0" +minos-microservice-common = { path = "../../core/minos-microservice-common", develop = true } +minos-microservice-networks = { path = "../../core/minos-microservice-networks", develop = true } black = "^22.1" isort = "^5.8.0" pytest = "^6.2.4" coverage = "^6.3" flake8 = "^4.0.1" -Sphinx = "^4.0.1" -pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.12.0" -sphinxcontrib-apidoc = "^0.3.0" -sphinx-rtd-theme = "^1.0.0" -m2r2 = "^0.3.2" [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/packages/plugins/minos-discovery-kong/tests/test_minos_discovery/__init__.py b/packages/plugins/minos-discovery-kong/tests/test_kong/__init__.py similarity index 100% rename from packages/plugins/minos-discovery-kong/tests/test_minos_discovery/__init__.py rename to packages/plugins/minos-discovery-kong/tests/test_kong/__init__.py diff --git a/packages/plugins/minos-discovery-kong/tests/test_minos_discovery/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py similarity index 91% rename from packages/plugins/minos-discovery-kong/tests/test_minos_discovery/test_client.py rename to packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 295647756..3b8b7cbfa 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_minos_discovery/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -5,14 +5,14 @@ import httpx -from minos.plugins.minos_kong import ( - MinosKongClient, +from minos.plugins.kong import ( + KongDiscoveryClient, ) -class TestMinosKongClient(unittest.IsolatedAsyncioTestCase): +class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): def setUp(self) -> None: - self.client = MinosKongClient("localhost", 8001, circuit_breaker_time=0.1) + self.client = KongDiscoveryClient("localhost", 8001, circuit_breaker_time=0.1) @staticmethod def generate_underscore_uuid(): @@ -20,7 +20,7 @@ def generate_underscore_uuid(): return name.replace("-", "_") def test_constructor(self): - client = MinosKongClient() + client = KongDiscoveryClient() self.assertEqual("localhost", client.host) self.assertEqual(5567, client.port) diff --git a/poetry.lock b/poetry.lock index 54ad45f61..4f4f02b67 100644 --- a/poetry.lock +++ b/poetry.lock @@ -117,6 +117,23 @@ category = "dev" optional = false python-versions = "*" +[[package]] +name = "anyio" +version = "3.5.0" +description = "High level compatibility layer for multiple asynchronous event loop implementations" +category = "main" +optional = false +python-versions = ">=3.6.2" + +[package.dependencies] +idna = ">=2.8" +sniffio = ">=1.1" + +[package.extras] +doc = ["packaging", "sphinx-rtd-theme", "sphinx-autodoc-typehints (>=1.2.0)"] +test = ["coverage[toml] (>=4.5)", "hypothesis (>=4.0)", "pytest (>=6.0)", "pytest-mock (>=3.6.1)", "trustme", "contextlib2", "uvloop (<0.15)", "mock (>=4)", "uvloop (>=0.15)"] +trio = ["trio (>=0.16)"] + [[package]] name = "async-timeout" version = "4.0.2" @@ -192,7 +209,7 @@ python-versions = "*" name = "certifi" version = "2021.10.8" description = "Python package for providing Mozilla's CA Bundle." -category = "dev" +category = "main" optional = false python-versions = "*" @@ -347,6 +364,53 @@ category = "main" optional = false python-versions = ">=3.7" +[[package]] +name = "h11" +version = "0.12.0" +description = "A pure-Python, bring-your-own-I/O implementation of HTTP/1.1" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "httpcore" +version = "0.14.7" +description = "A minimal low-level HTTP client." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +anyio = ">=3.0.0,<4.0.0" +certifi = "*" +h11 = ">=0.11,<0.13" +sniffio = ">=1.0.0,<2.0.0" + +[package.extras] +http2 = ["h2 (>=3,<5)"] +socks = ["socksio (>=1.0.0,<2.0.0)"] + +[[package]] +name = "httpx" +version = "0.22.0" +description = "The next generation HTTP client." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +certifi = "*" +charset-normalizer = "*" +httpcore = ">=0.14.5,<0.15.0" +rfc3986 = {version = ">=1.3,<2", extras = ["idna2008"]} +sniffio = "*" + +[package.extras] +brotli = ["brotlicffi", "brotli"] +cli = ["click (>=8.0.0,<9.0.0)", "rich (>=10.0.0,<11.0.0)", "pygments (>=2.0.0,<3.0.0)"] +http2 = ["h2 (>=3,<5)"] +socks = ["socksio (>=1.0.0,<2.0.0)"] + [[package]] name = "identify" version = "2.4.12" @@ -511,6 +575,24 @@ minos-microservice-networks = "^0.6.0" type = "directory" url = "packages/plugins/minos-broker-rabbitmq" +[[package]] +name = "minos-discovery-kong" +version = "0.1.0a0" +description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +httpx = "^0.22.0" +minos-microservice-common = "^0.6.0" +minos-microservice-networks = "^0.6.0" + +[package.source] +type = "directory" +url = "packages/plugins/minos-discovery-kong" + [[package]] name = "minos-discovery-minos" version = "0.6.0" @@ -873,6 +955,20 @@ urllib3 = ">=1.21.1,<1.27" socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] +[[package]] +name = "rfc3986" +version = "1.5.0" +description = "Validating URI References per RFC 3986" +category = "main" +optional = false +python-versions = "*" + +[package.dependencies] +idna = {version = "*", optional = true, markers = "extra == \"idna2008\""} + +[package.extras] +idna2008 = ["idna"] + [[package]] name = "six" version = "1.16.0" @@ -881,6 +977,14 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" +[[package]] +name = "sniffio" +version = "1.2.0" +description = "Sniff out which async library your code is running under" +category = "main" +optional = false +python-versions = ">=3.5" + [[package]] name = "snowballstemmer" version = "2.2.0" @@ -1129,7 +1233,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "bd6051aedc0d148b6f175df19b88e2e1b666f807fdbc777d8541549512c17cfd" +content-hash = "4e102ab779801a2396115a74fff13797e569fe6751d8a5f659331d2e7ff6bbf9" [metadata.files] aio-pika = [ @@ -1253,6 +1357,10 @@ alabaster = [ {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, ] +anyio = [ + {file = "anyio-3.5.0-py3-none-any.whl", hash = "sha256:b5fa16c5ff93fa1046f2eeb5bbff2dad4d3514d6cda61d02816dba34fa8c3c2e"}, + {file = "anyio-3.5.0.tar.gz", hash = "sha256:a0aeffe2fb1fdf374a8e4b471444f0f3ac4fb9f5a5b542b48824475e0042a5a6"}, +] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, @@ -1501,6 +1609,18 @@ frozenlist = [ {file = "frozenlist-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:772965f773757a6026dea111a15e6e2678fbd6216180f82a48a40b27de1ee2ab"}, {file = "frozenlist-1.3.0.tar.gz", hash = "sha256:ce6f2ba0edb7b0c1d8976565298ad2deba6f8064d2bebb6ffce2ca896eb35b0b"}, ] +h11 = [ + {file = "h11-0.12.0-py3-none-any.whl", hash = "sha256:36a3cb8c0a032f56e2da7084577878a035d3b61d104230d4bd49c0c6b555a9c6"}, + {file = "h11-0.12.0.tar.gz", hash = "sha256:47222cb6067e4a307d535814917cd98fd0a57b6788ce715755fa2b6c28b56042"}, +] +httpcore = [ + {file = "httpcore-0.14.7-py3-none-any.whl", hash = "sha256:47d772f754359e56dd9d892d9593b6f9870a37aeb8ba51e9a88b09b3d68cfade"}, + {file = "httpcore-0.14.7.tar.gz", hash = "sha256:7503ec1c0f559066e7e39bc4003fd2ce023d01cf51793e3c173b864eb456ead1"}, +] +httpx = [ + {file = "httpx-0.22.0-py3-none-any.whl", hash = "sha256:e35e83d1d2b9b2a609ef367cc4c1e66fd80b750348b20cc9e19d1952fc2ca3f6"}, + {file = "httpx-0.22.0.tar.gz", hash = "sha256:d8e778f76d9bbd46af49e7f062467e3157a5a3d2ae4876a4bbfd8a51ed9c9cb4"}, +] identify = [ {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, @@ -1614,6 +1734,7 @@ mccabe = [ ] minos-broker-kafka = [] minos-broker-rabbitmq = [] +minos-discovery-kong = [] minos-discovery-minos = [] minos-http-aiohttp = [] minos-microservice-aggregate = [] @@ -1880,10 +2001,18 @@ requests = [ {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, ] +rfc3986 = [ + {file = "rfc3986-1.5.0-py2.py3-none-any.whl", hash = "sha256:a86d6e1f5b1dc238b218b012df0aa79409667bb209e58da56d0b94704e712a97"}, + {file = "rfc3986-1.5.0.tar.gz", hash = "sha256:270aaf10d87d0d4e095063c65bf3ddbc6ee3d0b226328ce21e036f946e421835"}, +] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] +sniffio = [ + {file = "sniffio-1.2.0-py3-none-any.whl", hash = "sha256:471b71698eac1c2112a40ce2752bb2f4a4814c22a54a3eed3676bc0f5ca9f663"}, + {file = "sniffio-1.2.0.tar.gz", hash = "sha256:c4666eecec1d3f50960c6bdf61ab7bc350648da6c126e3cf6898d8cd4ddcd3de"}, +] snowballstemmer = [ {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, diff --git a/pyproject.toml b/pyproject.toml index 7a174bda9..dc08ae16e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -14,6 +14,7 @@ minos-microservice-saga = { path = "packages/core/minos-microservice-saga", deve minos-microservice-cqrs = { path = "packages/core/minos-microservice-cqrs", develop = true } minos-broker-kafka = { path = "packages/plugins/minos-broker-kafka", develop = true } minos-discovery-minos = { path = "packages/plugins/minos-discovery-minos", develop = true } +minos-discovery-kong = { path = "packages/plugins/minos-discovery-kong", develop = true } minos-broker-rabbitmq = { path = "packages/plugins/minos-broker-rabbitmq", develop = true } minos-http-aiohttp = { path = "packages/plugins/minos-http-aiohttp", develop = true } From e91fa195887d1b345c85a8fb3b4f2d837578a38a Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 12:40:21 +0200 Subject: [PATCH 044/324] modified poetry --- packages/plugins/minos-kong/poetry.lock | 404 +++------------------ packages/plugins/minos-kong/pyproject.toml | 8 +- 2 files changed, 54 insertions(+), 358 deletions(-) diff --git a/packages/plugins/minos-kong/poetry.lock b/packages/plugins/minos-kong/poetry.lock index 29f82e8ee..5e1603013 100644 --- a/packages/plugins/minos-kong/poetry.lock +++ b/packages/plugins/minos-kong/poetry.lock @@ -1,26 +1,6 @@ -[[package]] -name = "aiohttp" -version = "3.8.1" -description = "Async http client/server framework (asyncio)" -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -aiosignal = ">=1.1.2" -async-timeout = ">=4.0.0a3,<5.0" -attrs = ">=17.3.0" -charset-normalizer = ">=2.0,<3.0" -frozenlist = ">=1.1.1" -multidict = ">=4.5,<7.0" -yarl = ">=1.0,<2.0" - -[package.extras] -speedups = ["aiodns", "brotli", "cchardet"] - [[package]] name = "aiomisc" -version = "14.4.6" +version = "15.7.3" description = "aiomisc - miscellaneous utils for asyncio" category = "main" optional = false @@ -35,7 +15,7 @@ asgi = ["aiohttp-asgi"] carbon = ["aiocarbon (>=0.15,<1.0)"] contextvars = ["contextvars (>=2.4,<3.0)"] cron = ["croniter (>=0.3.34,<0.4.0)"] -develop = ["aiocontextvars (==0.2.2)", "aiohttp (<4)", "aiohttp-asgi", "async-timeout", "coverage (==4.5.1)", "coveralls", "croniter (>=0.3.34,<0.4.0)", "fastapi", "freezegun (<1.1)", "mypy (>=0.782,<1.0)", "pylava", "pytest", "pytest-cov (>=2.5.1,<2.6.0)", "pytest-freezegun (>=0.4.2,<0.5.0)", "sphinx (>=3.5.1)", "sphinx-autobuild", "sphinx-intl", "timeout-decorator", "types-croniter", "tox (>=2.4)"] +develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-timeout", "coveralls", "croniter (>=0.3.34,<0.4.0)", "fastapi", "freezegun (<1.1)", "mypy (>=0.782,<1.0)", "pylava", "pytest", "pytest-cov (>=3.0,<4.0)", "pytest-freezegun (>=0.4.2,<0.5.0)", "pytest-rst", "pytest-subtests", "rich", "setproctitle", "sphinx-autobuild", "sphinx-intl", "sphinx (>=3.5.1)", "timeout-decorator", "tox (>=2.4)", "types-croniter"] raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] @@ -54,17 +34,6 @@ psycopg2-binary = ">=2.8.4" [package.extras] sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] -[[package]] -name = "aiosignal" -version = "1.2.0" -description = "aiosignal: a list of registered asynchronous callbacks" -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -frozenlist = ">=1.1.0" - [[package]] name = "alabaster" version = "0.7.12" @@ -110,7 +79,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" name = "attrs" version = "21.4.0" description = "Classes Without Boilerplate" -category = "main" +category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" @@ -190,7 +159,7 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.1.1" +version = "8.1.2" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -312,14 +281,6 @@ mccabe = ">=0.6.0,<0.7.0" pycodestyle = ">=2.8.0,<2.9.0" pyflakes = ">=2.4.0,<2.5.0" -[[package]] -name = "frozenlist" -version = "1.3.0" -description = "A list-like structure which implements collections.abc.MutableSequence" -category = "main" -optional = false -python-versions = ">=3.7" - [[package]] name = "h11" version = "0.12.0" @@ -484,14 +445,14 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.5.3" +version = "0.6.0" description = "The common core of the Minos Framework" category = "main" optional = false python-versions = ">=3.9,<4.0" [package.dependencies] -aiomisc = ">=14.0.3,<15.0.0" +aiomisc = ">=14.0.3,<16.0.0" aiopg = ">=1.2.1,<2.0.0" cached-property = ">=1.5.2,<2.0.0" dependency-injector = ">=4.32.2,<5.0.0" @@ -499,23 +460,21 @@ fastavro = ">=1.4.0,<2.0.0" lmdb = ">=1.2.1,<2.0.0" orjson = ">=3.5.2,<4.0.0" PyYAML = ">=5.4.1,<7.0.0" +uvloop = ">=0.16.0,<0.17.0" [[package]] name = "minos-microservice-networks" -version = "0.5.3" +version = "0.6.0" description = "The networks core of the Minos Framework" category = "main" optional = false python-versions = ">=3.9,<4.0" [package.dependencies] -aiohttp = ">=3.7.4,<4.0.0" -aiomisc = ">=14.0.3,<15.0.0" aiopg = ">=1.2.1,<2.0.0" crontab = ">=0.23.0,<0.24.0" -dependency-injector = ">=4.32.2,<5.0.0" -minos-microservice-common = ">=0.5.0,<0.6.0" -orjson = ">=3.6.5,<4.0.0" +minos-microservice-common = ">=0.6.0,<0.7.0" +psycopg2-binary = ">=2.9.3,<3.0.0" [[package]] name = "mistune" @@ -525,14 +484,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "multidict" -version = "6.0.2" -description = "multidict implementation" -category = "main" -optional = false -python-versions = ">=3.7" - [[package]] name = "mypy-extensions" version = "0.4.3" @@ -950,6 +901,19 @@ brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] +[[package]] +name = "uvloop" +version = "0.16.0" +description = "Fast implementation of asyncio event loop on top of libuv" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.extras] +dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)", "aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] +docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] +test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] + [[package]] name = "virtualenv" version = "20.14.0" @@ -968,18 +932,6 @@ six = ">=1.9.0,<2" docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] -[[package]] -name = "yarl" -version = "1.7.2" -description = "Yet another URL library" -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -idna = ">=2.0" -multidict = ">=4.0" - [[package]] name = "zipp" version = "3.7.0" @@ -995,95 +947,17 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "28a0cea8e8de8fad4b6e9ea3f3debaaeb559b2af4f98b355206d928f3aa706fe" +content-hash = "07bd71f88b36e01b18398d6f64ad71f32fdce4736c2f9898fbe1dc5c96fb3297" [metadata.files] -aiohttp = [ - {file = "aiohttp-3.8.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1ed0b6477896559f17b9eaeb6d38e07f7f9ffe40b9f0f9627ae8b9926ae260a8"}, - {file = "aiohttp-3.8.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:7dadf3c307b31e0e61689cbf9e06be7a867c563d5a63ce9dca578f956609abf8"}, - {file = "aiohttp-3.8.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:a79004bb58748f31ae1cbe9fa891054baaa46fb106c2dc7af9f8e3304dc30316"}, - {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:12de6add4038df8f72fac606dff775791a60f113a725c960f2bab01d8b8e6b15"}, - {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:6f0d5f33feb5f69ddd57a4a4bd3d56c719a141080b445cbf18f238973c5c9923"}, - {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:eaba923151d9deea315be1f3e2b31cc39a6d1d2f682f942905951f4e40200922"}, - {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:099ebd2c37ac74cce10a3527d2b49af80243e2a4fa39e7bce41617fbc35fa3c1"}, - {file = "aiohttp-3.8.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:2e5d962cf7e1d426aa0e528a7e198658cdc8aa4fe87f781d039ad75dcd52c516"}, - {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:fa0ffcace9b3aa34d205d8130f7873fcfefcb6a4dd3dd705b0dab69af6712642"}, - {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:61bfc23df345d8c9716d03717c2ed5e27374e0fe6f659ea64edcd27b4b044cf7"}, - {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:31560d268ff62143e92423ef183680b9829b1b482c011713ae941997921eebc8"}, - {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:01d7bdb774a9acc838e6b8f1d114f45303841b89b95984cbb7d80ea41172a9e3"}, - {file = "aiohttp-3.8.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:97ef77eb6b044134c0b3a96e16abcb05ecce892965a2124c566af0fd60f717e2"}, - {file = "aiohttp-3.8.1-cp310-cp310-win32.whl", hash = "sha256:c2aef4703f1f2ddc6df17519885dbfa3514929149d3ff900b73f45998f2532fa"}, - {file = "aiohttp-3.8.1-cp310-cp310-win_amd64.whl", hash = "sha256:713ac174a629d39b7c6a3aa757b337599798da4c1157114a314e4e391cd28e32"}, - {file = "aiohttp-3.8.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:473d93d4450880fe278696549f2e7aed8cd23708c3c1997981464475f32137db"}, - {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99b5eeae8e019e7aad8af8bb314fb908dd2e028b3cdaad87ec05095394cce632"}, - {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3af642b43ce56c24d063325dd2cf20ee012d2b9ba4c3c008755a301aaea720ad"}, - {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c3630c3ef435c0a7c549ba170a0633a56e92629aeed0e707fec832dee313fb7a"}, - {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4a4a4e30bf1edcad13fb0804300557aedd07a92cabc74382fdd0ba6ca2661091"}, - {file = "aiohttp-3.8.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6f8b01295e26c68b3a1b90efb7a89029110d3a4139270b24fda961893216c440"}, - {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:a25fa703a527158aaf10dafd956f7d42ac6d30ec80e9a70846253dd13e2f067b"}, - {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:5bfde62d1d2641a1f5173b8c8c2d96ceb4854f54a44c23102e2ccc7e02f003ec"}, - {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:51467000f3647d519272392f484126aa716f747859794ac9924a7aafa86cd411"}, - {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_s390x.whl", hash = "sha256:03a6d5349c9ee8f79ab3ff3694d6ce1cfc3ced1c9d36200cb8f08ba06bd3b782"}, - {file = "aiohttp-3.8.1-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:102e487eeb82afac440581e5d7f8f44560b36cf0bdd11abc51a46c1cd88914d4"}, - {file = "aiohttp-3.8.1-cp36-cp36m-win32.whl", hash = "sha256:4aed991a28ea3ce320dc8ce655875e1e00a11bdd29fe9444dd4f88c30d558602"}, - {file = "aiohttp-3.8.1-cp36-cp36m-win_amd64.whl", hash = "sha256:b0e20cddbd676ab8a64c774fefa0ad787cc506afd844de95da56060348021e96"}, - {file = "aiohttp-3.8.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:37951ad2f4a6df6506750a23f7cbabad24c73c65f23f72e95897bb2cecbae676"}, - {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5c23b1ad869653bc818e972b7a3a79852d0e494e9ab7e1a701a3decc49c20d51"}, - {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:15b09b06dae900777833fe7fc4b4aa426556ce95847a3e8d7548e2d19e34edb8"}, - {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:477c3ea0ba410b2b56b7efb072c36fa91b1e6fc331761798fa3f28bb224830dd"}, - {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:2f2f69dca064926e79997f45b2f34e202b320fd3782f17a91941f7eb85502ee2"}, - {file = "aiohttp-3.8.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ef9612483cb35171d51d9173647eed5d0069eaa2ee812793a75373447d487aa4"}, - {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:6d69f36d445c45cda7b3b26afef2fc34ef5ac0cdc75584a87ef307ee3c8c6d00"}, - {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:55c3d1072704d27401c92339144d199d9de7b52627f724a949fc7d5fc56d8b93"}, - {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:b9d00268fcb9f66fbcc7cd9fe423741d90c75ee029a1d15c09b22d23253c0a44"}, - {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:07b05cd3305e8a73112103c834e91cd27ce5b4bd07850c4b4dbd1877d3f45be7"}, - {file = "aiohttp-3.8.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:c34dc4958b232ef6188c4318cb7b2c2d80521c9a56c52449f8f93ab7bc2a8a1c"}, - {file = "aiohttp-3.8.1-cp37-cp37m-win32.whl", hash = "sha256:d2f9b69293c33aaa53d923032fe227feac867f81682f002ce33ffae978f0a9a9"}, - {file = "aiohttp-3.8.1-cp37-cp37m-win_amd64.whl", hash = "sha256:6ae828d3a003f03ae31915c31fa684b9890ea44c9c989056fea96e3d12a9fa17"}, - {file = "aiohttp-3.8.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:0c7ebbbde809ff4e970824b2b6cb7e4222be6b95a296e46c03cf050878fc1785"}, - {file = "aiohttp-3.8.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:8b7ef7cbd4fec9a1e811a5de813311ed4f7ac7d93e0fda233c9b3e1428f7dd7b"}, - {file = "aiohttp-3.8.1-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:c3d6a4d0619e09dcd61021debf7059955c2004fa29f48788a3dfaf9c9901a7cd"}, - {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:718626a174e7e467f0558954f94af117b7d4695d48eb980146016afa4b580b2e"}, - {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:589c72667a5febd36f1315aa6e5f56dd4aa4862df295cb51c769d16142ddd7cd"}, - {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2ed076098b171573161eb146afcb9129b5ff63308960aeca4b676d9d3c35e700"}, - {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:086f92daf51a032d062ec5f58af5ca6a44d082c35299c96376a41cbb33034675"}, - {file = "aiohttp-3.8.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:11691cf4dc5b94236ccc609b70fec991234e7ef8d4c02dd0c9668d1e486f5abf"}, - {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:31d1e1c0dbf19ebccbfd62eff461518dcb1e307b195e93bba60c965a4dcf1ba0"}, - {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:11a67c0d562e07067c4e86bffc1553f2cf5b664d6111c894671b2b8712f3aba5"}, - {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:bb01ba6b0d3f6c68b89fce7305080145d4877ad3acaed424bae4d4ee75faa950"}, - {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:44db35a9e15d6fe5c40d74952e803b1d96e964f683b5a78c3cc64eb177878155"}, - {file = "aiohttp-3.8.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:844a9b460871ee0a0b0b68a64890dae9c415e513db0f4a7e3cab41a0f2fedf33"}, - {file = "aiohttp-3.8.1-cp38-cp38-win32.whl", hash = "sha256:7d08744e9bae2ca9c382581f7dce1273fe3c9bae94ff572c3626e8da5b193c6a"}, - {file = "aiohttp-3.8.1-cp38-cp38-win_amd64.whl", hash = "sha256:04d48b8ce6ab3cf2097b1855e1505181bdd05586ca275f2505514a6e274e8e75"}, - {file = "aiohttp-3.8.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:f5315a2eb0239185af1bddb1abf472d877fede3cc8d143c6cddad37678293237"}, - {file = "aiohttp-3.8.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:a996d01ca39b8dfe77440f3cd600825d05841088fd6bc0144cc6c2ec14cc5f74"}, - {file = "aiohttp-3.8.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:13487abd2f761d4be7c8ff9080de2671e53fff69711d46de703c310c4c9317ca"}, - {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ea302f34477fda3f85560a06d9ebdc7fa41e82420e892fc50b577e35fc6a50b2"}, - {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a2f635ce61a89c5732537a7896b6319a8fcfa23ba09bec36e1b1ac0ab31270d2"}, - {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e999f2d0e12eea01caeecb17b653f3713d758f6dcc770417cf29ef08d3931421"}, - {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0770e2806a30e744b4e21c9d73b7bee18a1cfa3c47991ee2e5a65b887c49d5cf"}, - {file = "aiohttp-3.8.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d15367ce87c8e9e09b0f989bfd72dc641bcd04ba091c68cd305312d00962addd"}, - {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:6c7cefb4b0640703eb1069835c02486669312bf2f12b48a748e0a7756d0de33d"}, - {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:71927042ed6365a09a98a6377501af5c9f0a4d38083652bcd2281a06a5976724"}, - {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:28d490af82bc6b7ce53ff31337a18a10498303fe66f701ab65ef27e143c3b0ef"}, - {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:b6613280ccedf24354406caf785db748bebbddcf31408b20c0b48cb86af76866"}, - {file = "aiohttp-3.8.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:81e3d8c34c623ca4e36c46524a3530e99c0bc95ed068fd6e9b55cb721d408fb2"}, - {file = "aiohttp-3.8.1-cp39-cp39-win32.whl", hash = "sha256:7187a76598bdb895af0adbd2fb7474d7f6025d170bc0a1130242da817ce9e7d1"}, - {file = "aiohttp-3.8.1-cp39-cp39-win_amd64.whl", hash = "sha256:1c182cb873bc91b411e184dab7a2b664d4fea2743df0e4d57402f7f3fa644bac"}, - {file = "aiohttp-3.8.1.tar.gz", hash = "sha256:fc5471e1a54de15ef71c1bc6ebe80d4dc681ea600e68bfd1cbce40427f0b7578"}, -] aiomisc = [ - {file = "aiomisc-14.4.6-py3-none-any.whl", hash = "sha256:beaa248f92acce53857f459499210643274cf06b33c7eb0c9d1f35feaad0d054"}, - {file = "aiomisc-14.4.6.tar.gz", hash = "sha256:a547a94908db9213fd0acde2674973b4a7a986ad82989215f73488903b65746e"}, + {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, + {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, ] -aiosignal = [ - {file = "aiosignal-1.2.0-py3-none-any.whl", hash = "sha256:26e62109036cd181df6e6ad646f91f0dcfd05fe16d0cb924138ff2ab75d64e3a"}, - {file = "aiosignal-1.2.0.tar.gz", hash = "sha256:78ed67db6c7b7ced4f98e495e572106d5c432a93e1ddd1bf475e1dc05f5b7df2"}, -] alabaster = [ {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, @@ -1150,8 +1024,8 @@ charset-normalizer = [ {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, - {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, + {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, + {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1279,67 +1153,6 @@ flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] -frozenlist = [ - {file = "frozenlist-1.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:d2257aaba9660f78c7b1d8fea963b68f3feffb1a9d5d05a18401ca9eb3e8d0a3"}, - {file = "frozenlist-1.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:4a44ebbf601d7bac77976d429e9bdb5a4614f9f4027777f9e54fd765196e9d3b"}, - {file = "frozenlist-1.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:45334234ec30fc4ea677f43171b18a27505bfb2dba9aca4398a62692c0ea8868"}, - {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:47be22dc27ed933d55ee55845d34a3e4e9f6fee93039e7f8ebadb0c2f60d403f"}, - {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:03a7dd1bfce30216a3f51a84e6dd0e4a573d23ca50f0346634916ff105ba6e6b"}, - {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:691ddf6dc50480ce49f68441f1d16a4c3325887453837036e0fb94736eae1e58"}, - {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:bde99812f237f79eaf3f04ebffd74f6718bbd216101b35ac7955c2d47c17da02"}, - {file = "frozenlist-1.3.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6a202458d1298ced3768f5a7d44301e7c86defac162ace0ab7434c2e961166e8"}, - {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b9e3e9e365991f8cc5f5edc1fd65b58b41d0514a6a7ad95ef5c7f34eb49b3d3e"}, - {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:04cb491c4b1c051734d41ea2552fde292f5f3a9c911363f74f39c23659c4af78"}, - {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:436496321dad302b8b27ca955364a439ed1f0999311c393dccb243e451ff66aa"}, - {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:754728d65f1acc61e0f4df784456106e35afb7bf39cfe37227ab00436fb38676"}, - {file = "frozenlist-1.3.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:6eb275c6385dd72594758cbe96c07cdb9bd6becf84235f4a594bdf21e3596c9d"}, - {file = "frozenlist-1.3.0-cp310-cp310-win32.whl", hash = "sha256:e30b2f9683812eb30cf3f0a8e9f79f8d590a7999f731cf39f9105a7c4a39489d"}, - {file = "frozenlist-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:f7353ba3367473d1d616ee727945f439e027f0bb16ac1a750219a8344d1d5d3c"}, - {file = "frozenlist-1.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:88aafd445a233dbbf8a65a62bc3249a0acd0d81ab18f6feb461cc5a938610d24"}, - {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4406cfabef8f07b3b3af0f50f70938ec06d9f0fc26cbdeaab431cbc3ca3caeaa"}, - {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:8cf829bd2e2956066dd4de43fd8ec881d87842a06708c035b37ef632930505a2"}, - {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:603b9091bd70fae7be28bdb8aa5c9990f4241aa33abb673390a7f7329296695f"}, - {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:25af28b560e0c76fa41f550eacb389905633e7ac02d6eb3c09017fa1c8cdfde1"}, - {file = "frozenlist-1.3.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:94c7a8a9fc9383b52c410a2ec952521906d355d18fccc927fca52ab575ee8b93"}, - {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:65bc6e2fece04e2145ab6e3c47428d1bbc05aede61ae365b2c1bddd94906e478"}, - {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:3f7c935c7b58b0d78c0beea0c7358e165f95f1fd8a7e98baa40d22a05b4a8141"}, - {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:bd89acd1b8bb4f31b47072615d72e7f53a948d302b7c1d1455e42622de180eae"}, - {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:6983a31698490825171be44ffbafeaa930ddf590d3f051e397143a5045513b01"}, - {file = "frozenlist-1.3.0-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:adac9700675cf99e3615eb6a0eb5e9f5a4143c7d42c05cea2e7f71c27a3d0846"}, - {file = "frozenlist-1.3.0-cp37-cp37m-win32.whl", hash = "sha256:0c36e78b9509e97042ef869c0e1e6ef6429e55817c12d78245eb915e1cca7468"}, - {file = "frozenlist-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:57f4d3f03a18facacb2a6bcd21bccd011e3b75d463dc49f838fd699d074fabd1"}, - {file = "frozenlist-1.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:8c905a5186d77111f02144fab5b849ab524f1e876a1e75205cd1386a9be4b00a"}, - {file = "frozenlist-1.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:b5009062d78a8c6890d50b4e53b0ddda31841b3935c1937e2ed8c1bda1c7fb9d"}, - {file = "frozenlist-1.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:2fdc3cd845e5a1f71a0c3518528bfdbfe2efaf9886d6f49eacc5ee4fd9a10953"}, - {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92e650bd09b5dda929523b9f8e7f99b24deac61240ecc1a32aeba487afcd970f"}, - {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:40dff8962b8eba91fd3848d857203f0bd704b5f1fa2b3fc9af64901a190bba08"}, - {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:768efd082074bb203c934e83a61654ed4931ef02412c2fbdecea0cff7ecd0274"}, - {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:006d3595e7d4108a12025ddf415ae0f6c9e736e726a5db0183326fd191b14c5e"}, - {file = "frozenlist-1.3.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:871d42623ae15eb0b0e9df65baeee6976b2e161d0ba93155411d58ff27483ad8"}, - {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:aff388be97ef2677ae185e72dc500d19ecaf31b698986800d3fc4f399a5e30a5"}, - {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:9f892d6a94ec5c7b785e548e42722e6f3a52f5f32a8461e82ac3e67a3bd073f1"}, - {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:e982878792c971cbd60ee510c4ee5bf089a8246226dea1f2138aa0bb67aff148"}, - {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:c6c321dd013e8fc20735b92cb4892c115f5cdb82c817b1e5b07f6b95d952b2f0"}, - {file = "frozenlist-1.3.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:30530930410855c451bea83f7b272fb1c495ed9d5cc72895ac29e91279401db3"}, - {file = "frozenlist-1.3.0-cp38-cp38-win32.whl", hash = "sha256:40ec383bc194accba825fbb7d0ef3dda5736ceab2375462f1d8672d9f6b68d07"}, - {file = "frozenlist-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:f20baa05eaa2bcd5404c445ec51aed1c268d62600362dc6cfe04fae34a424bd9"}, - {file = "frozenlist-1.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:0437fe763fb5d4adad1756050cbf855bbb2bf0d9385c7bb13d7a10b0dd550486"}, - {file = "frozenlist-1.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b684c68077b84522b5c7eafc1dc735bfa5b341fb011d5552ebe0968e22ed641c"}, - {file = "frozenlist-1.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:93641a51f89473837333b2f8100f3f89795295b858cd4c7d4a1f18e299dc0a4f"}, - {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d6d32ff213aef0fd0bcf803bffe15cfa2d4fde237d1d4838e62aec242a8362fa"}, - {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:31977f84828b5bb856ca1eb07bf7e3a34f33a5cddce981d880240ba06639b94d"}, - {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3c62964192a1c0c30b49f403495911298810bada64e4f03249ca35a33ca0417a"}, - {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:4eda49bea3602812518765810af732229b4291d2695ed24a0a20e098c45a707b"}, - {file = "frozenlist-1.3.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:acb267b09a509c1df5a4ca04140da96016f40d2ed183cdc356d237286c971b51"}, - {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:e1e26ac0a253a2907d654a37e390904426d5ae5483150ce3adedb35c8c06614a"}, - {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:f96293d6f982c58ebebb428c50163d010c2f05de0cde99fd681bfdc18d4b2dc2"}, - {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:e84cb61b0ac40a0c3e0e8b79c575161c5300d1d89e13c0e02f76193982f066ed"}, - {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:ff9310f05b9d9c5c4dd472983dc956901ee6cb2c3ec1ab116ecdde25f3ce4951"}, - {file = "frozenlist-1.3.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:d26b650b71fdc88065b7a21f8ace70175bcf3b5bdba5ea22df4bfd893e795a3b"}, - {file = "frozenlist-1.3.0-cp39-cp39-win32.whl", hash = "sha256:01a73627448b1f2145bddb6e6c2259988bb8aee0fb361776ff8604b99616cd08"}, - {file = "frozenlist-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:772965f773757a6026dea111a15e6e2678fbd6216180f82a48a40b27de1ee2ab"}, - {file = "frozenlist-1.3.0.tar.gz", hash = "sha256:ce6f2ba0edb7b0c1d8976565298ad2deba6f8064d2bebb6ffce2ca896eb35b0b"}, -] h11 = [ {file = "h11-0.12.0-py3-none-any.whl", hash = "sha256:36a3cb8c0a032f56e2da7084577878a035d3b61d104230d4bd49c0c6b555a9c6"}, {file = "h11-0.12.0.tar.gz", hash = "sha256:47222cb6067e4a307d535814917cd98fd0a57b6788ce715755fa2b6c28b56042"}, @@ -1460,78 +1273,17 @@ mccabe = [ {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] minos-microservice-common = [ - {file = "minos-microservice-common-0.5.3.tar.gz", hash = "sha256:91e927504c35646626fb4597f5bd65566bc055882ddd3af42cba24ca5fc4c9af"}, - {file = "minos_microservice_common-0.5.3-py3-none-any.whl", hash = "sha256:9eea7eef5abd73a844a4ef12649d8f10323b561e27db20178398e41887e42e85"}, + {file = "minos-microservice-common-0.6.0.tar.gz", hash = "sha256:6faae0c4bae605b5671a317cb75349faa1fe49421475254f53913ab3597dc24a"}, + {file = "minos_microservice_common-0.6.0-py3-none-any.whl", hash = "sha256:3c09167aeae31b57451968d27ab94d67473f1276bca5b8701a89f85b37730571"}, ] minos-microservice-networks = [ - {file = "minos-microservice-networks-0.5.3.tar.gz", hash = "sha256:9bbad95410d36942ac69a5b7fc5500de24f26e4dff03e894a351c2902d38b5b9"}, - {file = "minos_microservice_networks-0.5.3-py3-none-any.whl", hash = "sha256:3eeef3972cac838414118347511f6d0e0a75d25af374b75af684e6d5d8cb7750"}, + {file = "minos-microservice-networks-0.6.0.tar.gz", hash = "sha256:c1240fefdab20549afd6cd014a6262c75dde94ca2181f3dff3a9c2d9d59369d0"}, + {file = "minos_microservice_networks-0.6.0-py3-none-any.whl", hash = "sha256:52dee56c57bed9521272d94b30bb0660001c11b0be90a2b079196a1252def047"}, ] mistune = [ {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, ] -multidict = [ - {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:0b9e95a740109c6047602f4db4da9949e6c5945cefbad34a1299775ddc9a62e2"}, - {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ac0e27844758d7177989ce406acc6a83c16ed4524ebc363c1f748cba184d89d3"}, - {file = "multidict-6.0.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:041b81a5f6b38244b34dc18c7b6aba91f9cdaf854d9a39e5ff0b58e2b5773b9c"}, - {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5fdda29a3c7e76a064f2477c9aab1ba96fd94e02e386f1e665bca1807fc5386f"}, - {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3368bf2398b0e0fcbf46d85795adc4c259299fec50c1416d0f77c0a843a3eed9"}, - {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f4f052ee022928d34fe1f4d2bc743f32609fb79ed9c49a1710a5ad6b2198db20"}, - {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:225383a6603c086e6cef0f2f05564acb4f4d5f019a4e3e983f572b8530f70c88"}, - {file = "multidict-6.0.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:50bd442726e288e884f7be9071016c15a8742eb689a593a0cac49ea093eef0a7"}, - {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:47e6a7e923e9cada7c139531feac59448f1f47727a79076c0b1ee80274cd8eee"}, - {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:0556a1d4ea2d949efe5fd76a09b4a82e3a4a30700553a6725535098d8d9fb672"}, - {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:626fe10ac87851f4cffecee161fc6f8f9853f0f6f1035b59337a51d29ff3b4f9"}, - {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:8064b7c6f0af936a741ea1efd18690bacfbae4078c0c385d7c3f611d11f0cf87"}, - {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:2d36e929d7f6a16d4eb11b250719c39560dd70545356365b494249e2186bc389"}, - {file = "multidict-6.0.2-cp310-cp310-win32.whl", hash = "sha256:fcb91630817aa8b9bc4a74023e4198480587269c272c58b3279875ed7235c293"}, - {file = "multidict-6.0.2-cp310-cp310-win_amd64.whl", hash = "sha256:8cbf0132f3de7cc6c6ce00147cc78e6439ea736cee6bca4f068bcf892b0fd658"}, - {file = "multidict-6.0.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:05f6949d6169878a03e607a21e3b862eaf8e356590e8bdae4227eedadacf6e51"}, - {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2c2e459f7050aeb7c1b1276763364884595d47000c1cddb51764c0d8976e608"}, - {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d0509e469d48940147e1235d994cd849a8f8195e0bca65f8f5439c56e17872a3"}, - {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:514fe2b8d750d6cdb4712346a2c5084a80220821a3e91f3f71eec11cf8d28fd4"}, - {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19adcfc2a7197cdc3987044e3f415168fc5dc1f720c932eb1ef4f71a2067e08b"}, - {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b9d153e7f1f9ba0b23ad1568b3b9e17301e23b042c23870f9ee0522dc5cc79e8"}, - {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:aef9cc3d9c7d63d924adac329c33835e0243b5052a6dfcbf7732a921c6e918ba"}, - {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:4571f1beddff25f3e925eea34268422622963cd8dc395bb8778eb28418248e43"}, - {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:d48b8ee1d4068561ce8033d2c344cf5232cb29ee1a0206a7b828c79cbc5982b8"}, - {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:45183c96ddf61bf96d2684d9fbaf6f3564d86b34cb125761f9a0ef9e36c1d55b"}, - {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:75bdf08716edde767b09e76829db8c1e5ca9d8bb0a8d4bd94ae1eafe3dac5e15"}, - {file = "multidict-6.0.2-cp37-cp37m-win32.whl", hash = "sha256:a45e1135cb07086833ce969555df39149680e5471c04dfd6a915abd2fc3f6dbc"}, - {file = "multidict-6.0.2-cp37-cp37m-win_amd64.whl", hash = "sha256:6f3cdef8a247d1eafa649085812f8a310e728bdf3900ff6c434eafb2d443b23a"}, - {file = "multidict-6.0.2-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:0327292e745a880459ef71be14e709aaea2f783f3537588fb4ed09b6c01bca60"}, - {file = "multidict-6.0.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:e875b6086e325bab7e680e4316d667fc0e5e174bb5611eb16b3ea121c8951b86"}, - {file = "multidict-6.0.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:feea820722e69451743a3d56ad74948b68bf456984d63c1a92e8347b7b88452d"}, - {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9cc57c68cb9139c7cd6fc39f211b02198e69fb90ce4bc4a094cf5fe0d20fd8b0"}, - {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:497988d6b6ec6ed6f87030ec03280b696ca47dbf0648045e4e1d28b80346560d"}, - {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:89171b2c769e03a953d5969b2f272efa931426355b6c0cb508022976a17fd376"}, - {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:684133b1e1fe91eda8fa7447f137c9490a064c6b7f392aa857bba83a28cfb693"}, - {file = "multidict-6.0.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:fd9fc9c4849a07f3635ccffa895d57abce554b467d611a5009ba4f39b78a8849"}, - {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:e07c8e79d6e6fd37b42f3250dba122053fddb319e84b55dd3a8d6446e1a7ee49"}, - {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:4070613ea2227da2bfb2c35a6041e4371b0af6b0be57f424fe2318b42a748516"}, - {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:47fbeedbf94bed6547d3aa632075d804867a352d86688c04e606971595460227"}, - {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:5774d9218d77befa7b70d836004a768fb9aa4fdb53c97498f4d8d3f67bb9cfa9"}, - {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:2957489cba47c2539a8eb7ab32ff49101439ccf78eab724c828c1a54ff3ff98d"}, - {file = "multidict-6.0.2-cp38-cp38-win32.whl", hash = "sha256:e5b20e9599ba74391ca0cfbd7b328fcc20976823ba19bc573983a25b32e92b57"}, - {file = "multidict-6.0.2-cp38-cp38-win_amd64.whl", hash = "sha256:8004dca28e15b86d1b1372515f32eb6f814bdf6f00952699bdeb541691091f96"}, - {file = "multidict-6.0.2-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:2e4a0785b84fb59e43c18a015ffc575ba93f7d1dbd272b4cdad9f5134b8a006c"}, - {file = "multidict-6.0.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:6701bf8a5d03a43375909ac91b6980aea74b0f5402fbe9428fc3f6edf5d9677e"}, - {file = "multidict-6.0.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:a007b1638e148c3cfb6bf0bdc4f82776cef0ac487191d093cdc316905e504071"}, - {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:07a017cfa00c9890011628eab2503bee5872f27144936a52eaab449be5eaf032"}, - {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c207fff63adcdf5a485969131dc70e4b194327666b7e8a87a97fbc4fd80a53b2"}, - {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:373ba9d1d061c76462d74e7de1c0c8e267e9791ee8cfefcf6b0b2495762c370c"}, - {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bfba7c6d5d7c9099ba21f84662b037a0ffd4a5e6b26ac07d19e423e6fdf965a9"}, - {file = "multidict-6.0.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:19d9bad105dfb34eb539c97b132057a4e709919ec4dd883ece5838bcbf262b80"}, - {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:de989b195c3d636ba000ee4281cd03bb1234635b124bf4cd89eeee9ca8fcb09d"}, - {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:7c40b7bbece294ae3a87c1bc2abff0ff9beef41d14188cda94ada7bcea99b0fb"}, - {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:d16cce709ebfadc91278a1c005e3c17dd5f71f5098bfae1035149785ea6e9c68"}, - {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:a2c34a93e1d2aa35fbf1485e5010337c72c6791407d03aa5f4eed920343dd360"}, - {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:feba80698173761cddd814fa22e88b0661e98cb810f9f986c54aa34d281e4937"}, - {file = "multidict-6.0.2-cp39-cp39-win32.whl", hash = "sha256:23b616fdc3c74c9fe01d76ce0d1ce872d2d396d8fa8e4899398ad64fb5aa214a"}, - {file = "multidict-6.0.2-cp39-cp39-win_amd64.whl", hash = "sha256:4bae31803d708f6f15fd98be6a6ac0b6958fcf68fda3c77a048a4f9073704aae"}, - {file = "multidict-6.0.2.tar.gz", hash = "sha256:5ff3bd75f38e4c43f1f470f2df7a4d430b821c4ce22be384e1459cb57d6bb013"}, -] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, @@ -1795,84 +1547,28 @@ urllib3 = [ {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, ] +uvloop = [ + {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, + {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, + {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:bd53f7f5db562f37cd64a3af5012df8cac2c464c97e732ed556800129505bd64"}, + {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:772206116b9b57cd625c8a88f2413df2fcfd0b496eb188b82a43bed7af2c2ec9"}, + {file = "uvloop-0.16.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:b572256409f194521a9895aef274cea88731d14732343da3ecdb175228881638"}, + {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:04ff57aa137230d8cc968f03481176041ae789308b4d5079118331ab01112450"}, + {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3a19828c4f15687675ea912cc28bbcb48e9bb907c801873bd1519b96b04fb805"}, + {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e814ac2c6f9daf4c36eb8e85266859f42174a4ff0d71b99405ed559257750382"}, + {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:bd8f42ea1ea8f4e84d265769089964ddda95eb2bb38b5cbe26712b0616c3edee"}, + {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:647e481940379eebd314c00440314c81ea547aa636056f554d491e40503c8464"}, + {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e0d26fa5875d43ddbb0d9d79a447d2ace4180d9e3239788208527c4784f7cab"}, + {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:6ccd57ae8db17d677e9e06192e9c9ec4bd2066b77790f9aa7dede2cc4008ee8f"}, + {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:089b4834fd299d82d83a25e3335372f12117a7d38525217c2258e9b9f4578897"}, + {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98d117332cc9e5ea8dfdc2b28b0a23f60370d02e1395f88f40d1effd2cb86c4f"}, + {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, + {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, +] virtualenv = [ {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, ] -yarl = [ - {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:f2a8508f7350512434e41065684076f640ecce176d262a7d54f0da41d99c5a95"}, - {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:da6df107b9ccfe52d3a48165e48d72db0eca3e3029b5b8cb4fe6ee3cb870ba8b"}, - {file = "yarl-1.7.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:a1d0894f238763717bdcfea74558c94e3bc34aeacd3351d769460c1a586a8b05"}, - {file = "yarl-1.7.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfe4b95b7e00c6635a72e2d00b478e8a28bfb122dc76349a06e20792eb53a523"}, - {file = "yarl-1.7.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c145ab54702334c42237a6c6c4cc08703b6aa9b94e2f227ceb3d477d20c36c63"}, - {file = "yarl-1.7.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1ca56f002eaf7998b5fcf73b2421790da9d2586331805f38acd9997743114e98"}, - {file = "yarl-1.7.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:1d3d5ad8ea96bd6d643d80c7b8d5977b4e2fb1bab6c9da7322616fd26203d125"}, - {file = "yarl-1.7.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:167ab7f64e409e9bdd99333fe8c67b5574a1f0495dcfd905bc7454e766729b9e"}, - {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:95a1873b6c0dd1c437fb3bb4a4aaa699a48c218ac7ca1e74b0bee0ab16c7d60d"}, - {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:6152224d0a1eb254f97df3997d79dadd8bb2c1a02ef283dbb34b97d4f8492d23"}, - {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:5bb7d54b8f61ba6eee541fba4b83d22b8a046b4ef4d8eb7f15a7e35db2e1e245"}, - {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:9c1f083e7e71b2dd01f7cd7434a5f88c15213194df38bc29b388ccdf1492b739"}, - {file = "yarl-1.7.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:f44477ae29025d8ea87ec308539f95963ffdc31a82f42ca9deecf2d505242e72"}, - {file = "yarl-1.7.2-cp310-cp310-win32.whl", hash = "sha256:cff3ba513db55cc6a35076f32c4cdc27032bd075c9faef31fec749e64b45d26c"}, - {file = "yarl-1.7.2-cp310-cp310-win_amd64.whl", hash = "sha256:c9c6d927e098c2d360695f2e9d38870b2e92e0919be07dbe339aefa32a090265"}, - {file = "yarl-1.7.2-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:9b4c77d92d56a4c5027572752aa35082e40c561eec776048330d2907aead891d"}, - {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c01a89a44bb672c38f42b49cdb0ad667b116d731b3f4c896f72302ff77d71656"}, - {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c19324a1c5399b602f3b6e7db9478e5b1adf5cf58901996fc973fe4fccd73eed"}, - {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3abddf0b8e41445426d29f955b24aeecc83fa1072be1be4e0d194134a7d9baee"}, - {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:6a1a9fe17621af43e9b9fcea8bd088ba682c8192d744b386ee3c47b56eaabb2c"}, - {file = "yarl-1.7.2-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:8b0915ee85150963a9504c10de4e4729ae700af11df0dc5550e6587ed7891e92"}, - {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:29e0656d5497733dcddc21797da5a2ab990c0cb9719f1f969e58a4abac66234d"}, - {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:bf19725fec28452474d9887a128e98dd67eee7b7d52e932e6949c532d820dc3b"}, - {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:d6f3d62e16c10e88d2168ba2d065aa374e3c538998ed04996cd373ff2036d64c"}, - {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_s390x.whl", hash = "sha256:ac10bbac36cd89eac19f4e51c032ba6b412b3892b685076f4acd2de18ca990aa"}, - {file = "yarl-1.7.2-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:aa32aaa97d8b2ed4e54dc65d241a0da1c627454950f7d7b1f95b13985afd6c5d"}, - {file = "yarl-1.7.2-cp36-cp36m-win32.whl", hash = "sha256:87f6e082bce21464857ba58b569370e7b547d239ca22248be68ea5d6b51464a1"}, - {file = "yarl-1.7.2-cp36-cp36m-win_amd64.whl", hash = "sha256:ac35ccde589ab6a1870a484ed136d49a26bcd06b6a1c6397b1967ca13ceb3913"}, - {file = "yarl-1.7.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a467a431a0817a292121c13cbe637348b546e6ef47ca14a790aa2fa8cc93df63"}, - {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6ab0c3274d0a846840bf6c27d2c60ba771a12e4d7586bf550eefc2df0b56b3b4"}, - {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d260d4dc495c05d6600264a197d9d6f7fc9347f21d2594926202fd08cf89a8ba"}, - {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:fc4dd8b01a8112809e6b636b00f487846956402834a7fd59d46d4f4267181c41"}, - {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:c1164a2eac148d85bbdd23e07dfcc930f2e633220f3eb3c3e2a25f6148c2819e"}, - {file = "yarl-1.7.2-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:67e94028817defe5e705079b10a8438b8cb56e7115fa01640e9c0bb3edf67332"}, - {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:89ccbf58e6a0ab89d487c92a490cb5660d06c3a47ca08872859672f9c511fc52"}, - {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:8cce6f9fa3df25f55521fbb5c7e4a736683148bcc0c75b21863789e5185f9185"}, - {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:211fcd65c58bf250fb994b53bc45a442ddc9f441f6fec53e65de8cba48ded986"}, - {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:c10ea1e80a697cf7d80d1ed414b5cb8f1eec07d618f54637067ae3c0334133c4"}, - {file = "yarl-1.7.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:52690eb521d690ab041c3919666bea13ab9fbff80d615ec16fa81a297131276b"}, - {file = "yarl-1.7.2-cp37-cp37m-win32.whl", hash = "sha256:695ba021a9e04418507fa930d5f0704edbce47076bdcfeeaba1c83683e5649d1"}, - {file = "yarl-1.7.2-cp37-cp37m-win_amd64.whl", hash = "sha256:c17965ff3706beedafd458c452bf15bac693ecd146a60a06a214614dc097a271"}, - {file = "yarl-1.7.2-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:fce78593346c014d0d986b7ebc80d782b7f5e19843ca798ed62f8e3ba8728576"}, - {file = "yarl-1.7.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:c2a1ac41a6aa980db03d098a5531f13985edcb451bcd9d00670b03129922cd0d"}, - {file = "yarl-1.7.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:39d5493c5ecd75c8093fa7700a2fb5c94fe28c839c8e40144b7ab7ccba6938c8"}, - {file = "yarl-1.7.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1eb6480ef366d75b54c68164094a6a560c247370a68c02dddb11f20c4c6d3c9d"}, - {file = "yarl-1.7.2-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:5ba63585a89c9885f18331a55d25fe81dc2d82b71311ff8bd378fc8004202ff6"}, - {file = "yarl-1.7.2-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e39378894ee6ae9f555ae2de332d513a5763276a9265f8e7cbaeb1b1ee74623a"}, - {file = "yarl-1.7.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:c0910c6b6c31359d2f6184828888c983d54d09d581a4a23547a35f1d0b9484b1"}, - {file = "yarl-1.7.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6feca8b6bfb9eef6ee057628e71e1734caf520a907b6ec0d62839e8293e945c0"}, - {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:8300401dc88cad23f5b4e4c1226f44a5aa696436a4026e456fe0e5d2f7f486e6"}, - {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:788713c2896f426a4e166b11f4ec538b5736294ebf7d5f654ae445fd44270832"}, - {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:fd547ec596d90c8676e369dd8a581a21227fe9b4ad37d0dc7feb4ccf544c2d59"}, - {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:737e401cd0c493f7e3dd4db72aca11cfe069531c9761b8ea474926936b3c57c8"}, - {file = "yarl-1.7.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:baf81561f2972fb895e7844882898bda1eef4b07b5b385bcd308d2098f1a767b"}, - {file = "yarl-1.7.2-cp38-cp38-win32.whl", hash = "sha256:ede3b46cdb719c794427dcce9d8beb4abe8b9aa1e97526cc20de9bd6583ad1ef"}, - {file = "yarl-1.7.2-cp38-cp38-win_amd64.whl", hash = "sha256:cc8b7a7254c0fc3187d43d6cb54b5032d2365efd1df0cd1749c0c4df5f0ad45f"}, - {file = "yarl-1.7.2-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:580c1f15500e137a8c37053e4cbf6058944d4c114701fa59944607505c2fe3a0"}, - {file = "yarl-1.7.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:3ec1d9a0d7780416e657f1e405ba35ec1ba453a4f1511eb8b9fbab81cb8b3ce1"}, - {file = "yarl-1.7.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:3bf8cfe8856708ede6a73907bf0501f2dc4e104085e070a41f5d88e7faf237f3"}, - {file = "yarl-1.7.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1be4bbb3d27a4e9aa5f3df2ab61e3701ce8fcbd3e9846dbce7c033a7e8136746"}, - {file = "yarl-1.7.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:534b047277a9a19d858cde163aba93f3e1677d5acd92f7d10ace419d478540de"}, - {file = "yarl-1.7.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c6ddcd80d79c96eb19c354d9dca95291589c5954099836b7c8d29278a7ec0bda"}, - {file = "yarl-1.7.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:9bfcd43c65fbb339dc7086b5315750efa42a34eefad0256ba114cd8ad3896f4b"}, - {file = "yarl-1.7.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f64394bd7ceef1237cc604b5a89bf748c95982a84bcd3c4bbeb40f685c810794"}, - {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:044daf3012e43d4b3538562da94a88fb12a6490652dbc29fb19adfa02cf72eac"}, - {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:368bcf400247318382cc150aaa632582d0780b28ee6053cd80268c7e72796dec"}, - {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:bab827163113177aee910adb1f48ff7af31ee0289f434f7e22d10baf624a6dfe"}, - {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:0cba38120db72123db7c58322fa69e3c0efa933040ffb586c3a87c063ec7cae8"}, - {file = "yarl-1.7.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:59218fef177296451b23214c91ea3aba7858b4ae3306dde120224cfe0f7a6ee8"}, - {file = "yarl-1.7.2-cp39-cp39-win32.whl", hash = "sha256:1edc172dcca3f11b38a9d5c7505c83c1913c0addc99cd28e993efeaafdfaa18d"}, - {file = "yarl-1.7.2-cp39-cp39-win_amd64.whl", hash = "sha256:797c2c412b04403d2da075fb93c123df35239cd7b4cc4e0cd9e5839b73f52c58"}, - {file = "yarl-1.7.2.tar.gz", hash = "sha256:45399b46d60c253327a460e99856752009fcee5f5d3c80b2f7c0cae1c38d56dd"}, -] zipp = [ {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, diff --git a/packages/plugins/minos-kong/pyproject.toml b/packages/plugins/minos-kong/pyproject.toml index b6b24fa39..0840043a6 100644 --- a/packages/plugins/minos-kong/pyproject.toml +++ b/packages/plugins/minos-kong/pyproject.toml @@ -31,13 +31,13 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.5.0" -minos-microservice-networks = "^0.5.0" +minos-microservice-common = "^0.6.0" +minos-microservice-networks = "^0.6.0" httpx = "^0.22.0" [tool.poetry.dev-dependencies] -minos-microservice-common = "^0.5.0" -minos-microservice-networks = "^0.5.0" +minos-microservice-common = "^0.6.0" +minos-microservice-networks = "^0.6.0" black = "^22.1" isort = "^5.8.0" pytest = "^6.2.4" From f9c2b575c81ddd35dc289deffbf0c3480a890906 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 12:52:49 +0200 Subject: [PATCH 045/324] * Fix annoying `DeprecationWarning` message. --- .../minos/networks/brokers/collections/queues/pg.py | 2 +- .../test_subscribers/test_queued/test_queues/test_pg.py | 5 +---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py index fa3de8baf..dbf043838 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py @@ -35,12 +35,12 @@ ) from minos.common import ( + Builder, Config, PostgreSqlMinosDatabase, ) from ....utils import ( - Builder, consume_queue, ) from ...messages import ( diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py index 45e7c9786..bbf82b846 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py @@ -1,5 +1,4 @@ import unittest -import warnings from asyncio import ( sleep, ) @@ -91,9 +90,7 @@ def setUp(self) -> None: self.config = Config(CONFIG_FILE_PATH) def test_build(self): - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - builder = PostgreSqlBrokerSubscriberQueueBuilder().with_config(self.config).with_topics({"one", "two"}) + builder = PostgreSqlBrokerSubscriberQueueBuilder().with_config(self.config).with_topics({"one", "two"}) subscriber = builder.build() self.assertIsInstance(subscriber, PostgreSqlBrokerSubscriberQueue) From 4440eeae6a969eeadc3e4d9bdca463d5930b659f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 13:10:29 +0200 Subject: [PATCH 046/324] ISSUE #346 * Start using `PoolFactory` to get a `BrokerClientPool`. --- .../minos/aggregate/entities/refs/resolvers.py | 16 +++++++++++++++- .../minos/aggregate/events/repositories/abc.py | 2 +- .../minos/networks/brokers/pools.py | 9 ++++++--- .../minos/saga/executions/commit.py | 13 +++++++++++-- .../minos/saga/manager.py | 15 +++++++++++++-- 5 files changed, 46 insertions(+), 9 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/resolvers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/resolvers.py index ba92a2ab6..dd41fcc58 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/resolvers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/resolvers.py @@ -10,6 +10,7 @@ ) from typing import ( Any, + Optional, Union, ) from uuid import ( @@ -19,6 +20,8 @@ from minos.common import ( Inject, Model, + NotProvidedException, + PoolFactory, ) from minos.networks import ( BrokerClient, @@ -45,7 +48,18 @@ class RefResolver: # noinspection PyUnusedLocal @Inject() - def __init__(self, broker_pool: BrokerClientPool, **kwargs): + def __init__( + self, + broker_pool: Optional[BrokerClientPool] = None, + pool_factory: Optional[PoolFactory] = None, + **kwargs, + ): + if broker_pool is None and pool_factory is not None: + broker_pool = pool_factory.get_pool("broker") + + if broker_pool is None: + raise NotProvidedException(f"A {BrokerClientPool!r} instance is required.") + self.broker_pool = broker_pool # noinspection PyUnusedLocal diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py index 8d21cbd35..da9c3c27f 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py @@ -29,7 +29,7 @@ Lock, LockPool, NotProvidedException, - SetupMixin, Config, PoolFactory, + SetupMixin, PoolFactory, ) from minos.networks import ( BrokerMessageV1, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py b/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py index 66df5475c..8b2e15696 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py @@ -14,7 +14,6 @@ from minos.common import ( Config, - Injectable, Pool, ) @@ -28,12 +27,16 @@ logger = logging.getLogger(__name__) -@Injectable("broker_pool") class BrokerClientPool(Pool): """Broker Client Pool class.""" def __init__( - self, instance_kwargs: dict[str, Any], maxsize: int = 5, recycle: Optional[int] = 3600, *args, **kwargs + self, + instance_kwargs: dict[str, Any], + maxsize: int = 5, + recycle: Optional[int] = 3600, + *args, + **kwargs, ): super().__init__(maxsize=maxsize, recycle=recycle, *args, **kwargs) self._instance_kwargs = instance_kwargs diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/commit.py b/packages/core/minos-microservice-saga/minos/saga/executions/commit.py index 2f38a867e..07e67e08b 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/commit.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/commit.py @@ -2,6 +2,7 @@ from asyncio import ( gather, ) +from typing import Optional from uuid import ( UUID, ) @@ -11,7 +12,7 @@ ) from minos.common import ( - Inject, + Inject, PoolFactory, NotProvidedException, ) from minos.networks import ( BrokerClient, @@ -38,10 +39,18 @@ def __init__( self, execution_uuid: UUID, executed_steps: list[SagaStepExecution], - broker_pool: BrokerClientPool, broker_publisher: BrokerPublisher, + broker_pool: Optional[BrokerClientPool] = None, + pool_factory: Optional[PoolFactory] = None, **kwargs, ): + + if broker_pool is None and pool_factory is not None: + broker_pool = pool_factory.get_pool("broker") + + if broker_pool is None: + raise NotProvidedException(f"A {BrokerClientPool!r} instance is required.") + self.executed_steps = executed_steps self.execution_uuid = execution_uuid diff --git a/packages/core/minos-microservice-saga/minos/saga/manager.py b/packages/core/minos-microservice-saga/minos/saga/manager.py index 605171737..df529e100 100644 --- a/packages/core/minos-microservice-saga/minos/saga/manager.py +++ b/packages/core/minos-microservice-saga/minos/saga/manager.py @@ -24,6 +24,7 @@ Injectable, NotProvidedException, SetupMixin, + PoolFactory, ) from minos.networks import ( REQUEST_HEADERS_CONTEXT_VAR, @@ -63,12 +64,22 @@ class SagaManager(SetupMixin): """ @Inject() - def __init__(self, storage: SagaExecutionStorage, broker_pool: BrokerClientPool, *args, **kwargs): + def __init__( + self, + storage: SagaExecutionStorage, + broker_pool: Optional[BrokerClientPool] = None, + pool_factory: Optional[PoolFactory] = None, + *args, + **kwargs, + ): super().__init__(*args, **kwargs) self.storage = storage + if broker_pool is None and pool_factory is not None: + broker_pool = pool_factory.get_pool("broker") + if broker_pool is None: - raise NotProvidedException("A handler pool instance is required.") + raise NotProvidedException(f"A {BrokerClientPool!r} instance is required.") self.broker_pool = broker_pool From 57f71401a53e73ddf65ce3d77a425b413a52b771 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 13:12:25 +0200 Subject: [PATCH 047/324] ISSUE #346 * Reformat code. --- .../minos/aggregate/events/repositories/abc.py | 3 ++- .../minos/aggregate/transactions/repositories/abc.py | 6 ++++-- .../minos/common/config/v1.py | 10 ++++++---- .../minos-microservice-common/minos/common/locks.py | 3 --- .../minos/saga/executions/commit.py | 8 ++++++-- .../core/minos-microservice-saga/minos/saga/manager.py | 2 +- 6 files changed, 19 insertions(+), 13 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py index da9c3c27f..f3fd7f593 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py @@ -29,7 +29,8 @@ Lock, LockPool, NotProvidedException, - SetupMixin, PoolFactory, + PoolFactory, + SetupMixin, ) from minos.networks import ( BrokerMessageV1, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py index 99e95236f..6149b96fa 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/abc.py @@ -1,4 +1,6 @@ -from __future__ import annotations +from __future__ import ( + annotations, +) from abc import ( ABC, @@ -21,8 +23,8 @@ Lock, LockPool, NotProvidedException, - SetupMixin, PoolFactory, + SetupMixin, ) from ...exceptions import ( diff --git a/packages/core/minos-microservice-common/minos/common/config/v1.py b/packages/core/minos-microservice-common/minos/common/config/v1.py index 61cba56a3..2032dc713 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v1.py +++ b/packages/core/minos-microservice-common/minos/common/config/v1.py @@ -129,13 +129,13 @@ def _get_injections(self) -> list[type[InjectableMixin]]: injections = list() old = [import_module(classname) for classname in injections] + from ..injections import ( + InjectableMixin, + ) from ..pools import ( PoolFactory, ) - from ..injections import ( - InjectableMixin, - ) injections = list() injections.append(PoolFactory) # FIXME @@ -239,7 +239,9 @@ def _get_pools(self) -> dict[str, type]: raise MinosConfigException(f"The 'broker' interface is not available: {exc!r}") old = [import_module(classname) for classname in pools] - from ..pools import Pool + from ..pools import ( + Pool, + ) pools = dict() diff --git a/packages/core/minos-microservice-common/minos/common/locks.py b/packages/core/minos-microservice-common/minos/common/locks.py index 87853f84c..90d148b28 100644 --- a/packages/core/minos-microservice-common/minos/common/locks.py +++ b/packages/core/minos-microservice-common/minos/common/locks.py @@ -16,9 +16,6 @@ cached_property, ) -from .injections import ( - Injectable, -) from .pools import ( Pool, ) diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/commit.py b/packages/core/minos-microservice-saga/minos/saga/executions/commit.py index 07e67e08b..63e36a56f 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/commit.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/commit.py @@ -2,7 +2,9 @@ from asyncio import ( gather, ) -from typing import Optional +from typing import ( + Optional, +) from uuid import ( UUID, ) @@ -12,7 +14,9 @@ ) from minos.common import ( - Inject, PoolFactory, NotProvidedException, + Inject, + NotProvidedException, + PoolFactory, ) from minos.networks import ( BrokerClient, diff --git a/packages/core/minos-microservice-saga/minos/saga/manager.py b/packages/core/minos-microservice-saga/minos/saga/manager.py index df529e100..fb56e6cf1 100644 --- a/packages/core/minos-microservice-saga/minos/saga/manager.py +++ b/packages/core/minos-microservice-saga/minos/saga/manager.py @@ -23,8 +23,8 @@ Inject, Injectable, NotProvidedException, - SetupMixin, PoolFactory, + SetupMixin, ) from minos.networks import ( REQUEST_HEADERS_CONTEXT_VAR, From 1107770d945712a79f0af76d874911f4d9323d0d Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 1 Apr 2022 13:23:13 +0200 Subject: [PATCH 048/324] ISSUE #144 --- .../minos-discovery-kong-publish.yml | 33 +++++ .../workflows/minos-discovery-kong-tests.yml | 124 ++++++++++++++++++ 2 files changed, 157 insertions(+) create mode 100644 .github/workflows/minos-discovery-kong-publish.yml create mode 100644 .github/workflows/minos-discovery-kong-tests.yml diff --git a/.github/workflows/minos-discovery-kong-publish.yml b/.github/workflows/minos-discovery-kong-publish.yml new file mode 100644 index 000000000..b40da4f9a --- /dev/null +++ b/.github/workflows/minos-discovery-kong-publish.yml @@ -0,0 +1,33 @@ +name: "Publish: minos-discovery-kong" + +on: + push: + branches: + - '*.*.x' + paths: + - 'packages/plugins/minos-discovery-kong/**' + +jobs: + deploy: + runs-on: ubuntu-latest + container: python:3.9-buster + defaults: + run: + working-directory: packages/plugins/minos-discovery-kong + + steps: + + - name: Check out repository code + uses: actions/checkout@v2 + + - name: Install Poetry + uses: snok/install-poetry@v1 + + - name: Install dependencies + run: make install + + - name: Publish package + run: make release + env: + POETRY_HTTP_BASIC_PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }} + POETRY_HTTP_BASIC_PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }} diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml new file mode 100644 index 000000000..4f527e714 --- /dev/null +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -0,0 +1,124 @@ +name: "Test: minos-discovery-kong" + +on: + push: + branches: + - main + - '*.*.x' + pull_request: + paths: + - 'packages/plugins/minos-discovery-kong/**' + - 'packages/core/minos-microservice-networks/**' + - 'packages/core/minos-microservice-common/**' + +jobs: + build: + runs-on: ubuntu-latest + container: python:3.9-buster + defaults: + run: + working-directory: packages/plugins/minos-discovery-kong + + services: + kong-migrations: + image: kong/kong-gateway:2.8.0.0-alpine + command: kong migrations bootstrap + depends_on: + - db + environment: + KONG_DATABASE: postgres + KONG_PG_DATABASE: kong + KONG_PG_HOST: db + KONG_PG_USER: kong + KONG_PG_PASSWORD: kong + restart: on-failure + + kong-migrations-up: + image: kong/kong-gateway:2.8.0.0-alpine + command: kong migrations up && kong migrations finish + depends_on: + - db + environment: + KONG_DATABASE: postgres + KONG_PG_DATABASE: kong + KONG_PG_HOST: db + KONG_PG_USER: kong + KONG_PG_PASSWORD: kong + restart: on-failure + + kong: + image: kong/kong-gateway:2.8.0.0-alpine + user: kong + environment: + KONG_DATABASE: postgres + KONG_PG_DATABASE: kong + KONG_PG_HOST: db + KONG_PG_USER: kong + KONG_PG_PASSWORD: kong + KONG_ADMIN_ACCESS_LOG: /dev/stdout + KONG_ADMIN_ERROR_LOG: /dev/stderr + KONG_PROXY_LISTEN: 0.0.0.0:8000 + KONG_ADMIN_LISTEN: 0.0.0.0:8001 + KONG_PROXY_ACCESS_LOG: /dev/stdout + KONG_PROXY_ERROR_LOG: /dev/stderr + KONG_PREFIX: /var/run/kong + KONG_LOG_LEVEL: debug + KONG_DECLARATIVE_CONFIG: "/opt/kong/kong.yaml" + ports: + - "0.0.0.0:8000:8000/tcp" + - "0.0.0.0:8443:8443/tcp" + - "127.0.0.1:8001:8001/tcp" + - "127.0.0.1:8444:8444/tcp" + healthcheck: + test: [ "CMD", "kong", "health" ] + interval: 10s + timeout: 10s + retries: 10 + restart: on-failure:5 + read_only: true + security_opt: + - no-new-privileges + + db: + image: postgres:9.5 + environment: + POSTGRES_DB: kong + POSTGRES_USER: kong + POSTGRES_PASSWORD: kong + healthcheck: + test: [ "CMD", "pg_isready", "-U", "kong" ] + interval: 30s + timeout: 30s + retries: 3 + restart: on-failure + stdin_open: true + tty: true + + steps: + - name: Check out repository code + uses: actions/checkout@v2 + + - name: Install Poetry + uses: snok/install-poetry@v1 + + - name: Install dependencies + run: make install + + - name: Lint package + run: make lint + + - name: Test package with coverage + run: make coverage + + - name: Publish coverage + uses: codecov/codecov-action@v2 + with: + token: ${{ secrets.CODECOV_TOKEN }} + files: ./packages/plugins/minos-discovery-kong/coverage.xml + fail_ci_if_error: true + + - name: Generate documentation + run: make docs + + - name: Generate build + run: make dist From 5d9f21088c9752129f19dca70ccab98560e988d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 13:33:56 +0200 Subject: [PATCH 049/324] ISSUE #346 * Integrate `PoolFactory` into `PostgreSqlMinosDatabase`. --- .../minos/common/database/abc.py | 85 ++++--------------- .../minos/common/database/pools.py | 4 - 2 files changed, 15 insertions(+), 74 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 942c863ac..1cebec3ef 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -15,9 +15,15 @@ Cursor, ) +from ..exceptions import ( + NotProvidedException, +) from ..injections import ( Inject, ) +from ..pools import ( + PoolFactory, +) from ..setup import ( SetupMixin, ) @@ -32,71 +38,22 @@ class PostgreSqlMinosDatabase(SetupMixin): """PostgreSql Minos Database base class.""" + @Inject() def __init__( self, - database: str, - host: Optional[str] = None, - port: Optional[int] = None, - user: Optional[str] = None, - password: Optional[str] = None, + pool: Optional[PostgreSqlPool] = None, + pool_factory: Optional[PoolFactory] = None, *args, **kwargs, ): - super().__init__(*args, **kwargs) - self._database = database - self._host = host - self._port = port - self._user = user - self._password = password + super().__init__(*args, **kwargs, pool_factory=pool_factory) + if pool is None and pool_factory is not None: + pool = pool_factory.get_pool("database") - self._pool = None - self._owned_pool = False + if pool is None: + raise NotProvidedException(f"A {PostgreSqlPool!r} instance is required.") - @property - def database(self) -> str: - """Get the database's database. - - :return: A ``str`` value. - """ - return self.pool.database - - @property - def host(self) -> str: - """Get the database's host. - - :return: A ``str`` value. - """ - return self.pool.host - - @property - def port(self) -> int: - """Get the database's port. - - :return: An ``int`` value. - """ - return self.pool.port - - @property - def user(self) -> str: - """Get the database's user. - - :return: A ``str`` value. - """ - return self.pool.user - - @property - def password(self) -> str: - """Get the database's password. - - :return: A ``str`` value. - """ - return self.pool.password - - async def _destroy(self) -> None: - if self._owned_pool: - await self._pool.destroy() - self._pool = None - self._owned_pool = False + self._pool = pool async def submit_query_and_fetchone(self, *args, **kwargs) -> tuple: """Submit a SQL query and gets the first response. @@ -217,16 +174,4 @@ def pool(self) -> PostgreSqlPool: :return: A ``Pool`` object. """ - if self._pool is None: - self._pool, self._owned_pool = self._build_pool() return self._pool - - @Inject() - def _build_pool(self, pool: PostgreSqlPool = None) -> tuple[PostgreSqlPool, bool]: - if pool is not None: - return pool, False - - pool = PostgreSqlPool( - host=self._host, port=self._port, database=self._database, user=self._user, password=self._password - ) - return pool, True diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 7dfcc5138..5d47ac357 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -20,9 +20,6 @@ OperationalError, ) -from ..injections import ( - Injectable, -) from ..locks import ( LockPool, ) @@ -36,7 +33,6 @@ logger = logging.getLogger(__name__) -@Injectable("postgresql_pool") class PostgreSqlPool(Pool[ContextManager]): """Postgres Pool class.""" From ccd3df2469b0aa983814b77dd42d86f29d101cba Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 1 Apr 2022 13:35:04 +0200 Subject: [PATCH 050/324] ISSUE #144 --- .../tests/test_kong/test_client.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 3b8b7cbfa..c0f87a0bf 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -8,6 +8,7 @@ from minos.plugins.kong import ( KongDiscoveryClient, ) +PROTOCOL = "http" class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): @@ -26,7 +27,7 @@ def test_constructor(self): def test_route(self): # noinspection HttpUrlsUsage - self.assertEqual("http://localhost:8001", self.client.route) + self.assertEqual(f"{PROTOCOL}://localhost:8001", self.client.route) async def test_subscribe(self): name = self.generate_underscore_uuid() @@ -36,13 +37,13 @@ async def test_subscribe(self): self.assertTrue(201 == response.status_code) async with httpx.AsyncClient() as client: - url = f"http://{self.client.host}:{self.client.port}/services/{name}" + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" response = await client.get(url) response_data = response.json() self.assertTrue(200 == response.status_code) self.assertEqual(5660, response_data["port"]) self.assertEqual("172.160.16.24", response_data["host"]) - self.assertEqual("http", response_data["protocol"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) async def test_unsubscribe(self): name = self.generate_underscore_uuid() @@ -56,7 +57,7 @@ async def test_unsubscribe(self): self.assertTrue(204 == response_delete.status_code) async with httpx.AsyncClient() as client: - url = f"http://{self.client.host}:{self.client.port}/services/{name}" + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" response = await client.get(url) self.assertTrue(404 == response.status_code) @@ -72,7 +73,7 @@ async def test_route_params(self): self.assertTrue(201 == response.status_code) async with httpx.AsyncClient() as client: - url = f"http://{self.client.host}:{self.client.port}/services/test/routes" + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/test/routes" response = await client.get(url) response_data = response.json() self.assertTrue(200 == response.status_code) From 7ba14e80aec75c0da765ea5cb48095e249c2e4ee Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Fri, 1 Apr 2022 11:35:18 +0000 Subject: [PATCH 051/324] Restyled by black --- .../plugins/minos-discovery-kong/tests/test_kong/test_client.py | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index c0f87a0bf..9107cddb5 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -8,6 +8,7 @@ from minos.plugins.kong import ( KongDiscoveryClient, ) + PROTOCOL = "http" From 2bdd6977cf7cf7990c223320fe9041eae11558f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 13:37:21 +0200 Subject: [PATCH 052/324] ISSUE #346 * Rename `PostgreSqlMinosDatabase` as `DatabaseMixin`. --- .../minos/aggregate/events/repositories/pg.py | 4 ++-- .../minos/aggregate/snapshots/pg/abc.py | 4 ++-- .../aggregate/transactions/repositories/pg.py | 4 ++-- .../minos/common/__init__.py | 1 + .../minos/common/database/__init__.py | 1 + .../minos/common/database/abc.py | 13 ++++++++++- .../test_common/test_database/test_abc.py | 22 +++++++++---------- .../networks/brokers/collections/queues/pg.py | 4 ++-- .../filtered/validators/duplicates/pg.py | 4 ++-- .../test_collections/test_queues/test_pg.py | 4 ++-- 10 files changed, 37 insertions(+), 24 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py index f77aede25..43dff88d1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py @@ -23,7 +23,7 @@ from minos.common import ( NULL_UUID, Config, - PostgreSqlMinosDatabase, + DatabaseMixin, ) from ...exceptions import ( @@ -37,7 +37,7 @@ ) -class PostgreSqlEventRepository(PostgreSqlMinosDatabase, EventRepository): +class PostgreSqlEventRepository(DatabaseMixin, EventRepository): """PostgreSQL-based implementation of the event repository class in ``Minos``.""" @classmethod diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py index 0d1f2173a..6f835a15a 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py @@ -9,11 +9,11 @@ from minos.common import ( Config, - PostgreSqlMinosDatabase, + DatabaseMixin, ) -class PostgreSqlSnapshotSetup(PostgreSqlMinosDatabase): +class PostgreSqlSnapshotSetup(DatabaseMixin): """Minos Snapshot Setup Class""" @classmethod diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py index 8bac2fb16..eee96b7fa 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py @@ -15,7 +15,7 @@ from minos.common import ( Config, - PostgreSqlMinosDatabase, + DatabaseMixin, ) from ...exceptions import ( @@ -29,7 +29,7 @@ ) -class PostgreSqlTransactionRepository(PostgreSqlMinosDatabase, TransactionRepository): +class PostgreSqlTransactionRepository(DatabaseMixin, TransactionRepository): """PostgreSql Transaction Repository class.""" @classmethod diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 195ec79e9..2589379d8 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -14,6 +14,7 @@ MinosConfig, ) from .database import ( + DatabaseMixin, PostgreSqlLock, PostgreSqlLockPool, PostgreSqlMinosDatabase, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index a68d00810..0003ac601 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -1,4 +1,5 @@ from .abc import ( + DatabaseMixin, PostgreSqlMinosDatabase, ) from .locks import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 1cebec3ef..5719e762a 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -1,3 +1,4 @@ +import warnings from collections.abc import ( Hashable, ) @@ -35,7 +36,7 @@ ) -class PostgreSqlMinosDatabase(SetupMixin): +class DatabaseMixin(SetupMixin): """PostgreSql Minos Database base class.""" @Inject() @@ -175,3 +176,13 @@ def pool(self) -> PostgreSqlPool: :return: A ``Pool`` object. """ return self._pool + + +class PostgreSqlMinosDatabase(DatabaseMixin): + """TODO""" + + def __new__(cls, *args, **kwargs): + warnings.warn( + f"{PostgreSqlMinosDatabase!r} has been deprecated. Use {DatabaseMixin} instead.", DeprecationWarning + ) + return super().__new__(cls, *args, **kwargs) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index ff3629df0..b1d307933 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -4,8 +4,8 @@ import aiopg from minos.common import ( + DatabaseMixin, DependencyInjector, - PostgreSqlMinosDatabase, PostgreSqlPool, ) from minos.common.testing import ( @@ -20,7 +20,7 @@ class TestPostgreSqlMinosDatabase(PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def test_constructor(self): - pool = PostgreSqlMinosDatabase("foo") + pool = DatabaseMixin("foo") self.assertEqual("foo", pool.database) self.assertEqual("postgres", pool.user) self.assertEqual("", pool.password) @@ -28,7 +28,7 @@ def test_constructor(self): self.assertEqual(5432, pool.port) def test_constructor_extended(self): - database = PostgreSqlMinosDatabase(**self.repository_db) + database = DatabaseMixin(**self.repository_db) self.assertEqual(self.repository_db["host"], database.host) self.assertEqual(self.repository_db["port"], database.port) self.assertEqual(self.repository_db["database"], database.database) @@ -36,20 +36,20 @@ def test_constructor_extended(self): self.assertEqual(self.repository_db["password"], database.password) async def test_pool(self): - async with PostgreSqlMinosDatabase(**self.repository_db) as database: + async with DatabaseMixin(**self.repository_db) as database: self.assertIsInstance(database.pool, PostgreSqlPool) async def test_pool_with_dependency_injections(self): injector = DependencyInjector(self.config, [PostgreSqlPool]) await injector.wire_and_setup_injections(modules=[sys.modules[__name__]]) - async with PostgreSqlMinosDatabase(**self.repository_db) as database: + async with DatabaseMixin(**self.repository_db) as database: self.assertEqual(injector.postgresql_pool, database.pool) await injector.unwire_and_destroy_injections() async def test_submit_query(self): - async with PostgreSqlMinosDatabase(**self.repository_db) as database: + async with DatabaseMixin(**self.repository_db) as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") async with aiopg.connect(**self.repository_db) as connection: @@ -58,7 +58,7 @@ async def test_submit_query(self): self.assertTrue((await cursor.fetchone())[0]) async def test_submit_query_locked(self): - async with PostgreSqlMinosDatabase(**self.repository_db) as database: + async with DatabaseMixin(**self.repository_db) as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);", lock=1234) async with aiopg.connect(**self.repository_db) as connection: @@ -67,7 +67,7 @@ async def test_submit_query_locked(self): self.assertTrue((await cursor.fetchone())[0]) async def test_submit_query_and_fetchone(self): - async with PostgreSqlMinosDatabase(**self.repository_db) as database: + async with DatabaseMixin(**self.repository_db) as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") @@ -76,7 +76,7 @@ async def test_submit_query_and_fetchone(self): self.assertEqual((3,), observed) async def test_submit_query_and_iter(self): - async with PostgreSqlMinosDatabase(**self.repository_db) as database: + async with DatabaseMixin(**self.repository_db) as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") @@ -85,7 +85,7 @@ async def test_submit_query_and_iter(self): self.assertEqual([(3,), (4,), (5,)], observed) async def test_submit_query_and_iter_streaming_mode_true(self): - async with PostgreSqlMinosDatabase(**self.repository_db) as database: + async with DatabaseMixin(**self.repository_db) as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") @@ -94,7 +94,7 @@ async def test_submit_query_and_iter_streaming_mode_true(self): self.assertEqual([(3,), (4,), (5,)], observed) async def test_submit_query_and_iter_locked(self): - async with PostgreSqlMinosDatabase(**self.repository_db) as database: + async with DatabaseMixin(**self.repository_db) as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py index dbf043838..dc53280bd 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py @@ -37,7 +37,7 @@ from minos.common import ( Builder, Config, - PostgreSqlMinosDatabase, + DatabaseMixin, ) from ....utils import ( @@ -53,7 +53,7 @@ logger = logging.getLogger(__name__) -class PostgreSqlBrokerQueue(BrokerQueue, PostgreSqlMinosDatabase): +class PostgreSqlBrokerQueue(BrokerQueue, DatabaseMixin): """PostgreSql Broker Queue class.""" _queue: PriorityQueue[_Entry] diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py index fb2ee854d..e1a2394af 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py @@ -19,7 +19,7 @@ from minos.common import ( Builder, Config, - PostgreSqlMinosDatabase, + DatabaseMixin, ) from .abc import ( @@ -27,7 +27,7 @@ ) -class PostgreSqlBrokerSubscriberDuplicateValidator(BrokerSubscriberDuplicateValidator, PostgreSqlMinosDatabase): +class PostgreSqlBrokerSubscriberDuplicateValidator(BrokerSubscriberDuplicateValidator, DatabaseMixin): """PostgreSql Broker Subscriber Duplicate Detector class.""" def __init__( diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index 8a87f1f6a..d47b76674 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -8,7 +8,7 @@ ) from minos.common import ( - PostgreSqlMinosDatabase, + DatabaseMixin, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -41,7 +41,7 @@ def setUp(self) -> None: self.query_factory = _PostgreSqlBrokerQueueQueryFactory() def test_is_subclass(self): - self.assertTrue(issubclass(PostgreSqlBrokerQueue, (BrokerQueue, PostgreSqlMinosDatabase))) + self.assertTrue(issubclass(PostgreSqlBrokerQueue, (BrokerQueue, DatabaseMixin))) def test_constructor(self): queue = PostgreSqlBrokerQueue("foo_db", query_factory=self.query_factory) From 904ee3eda5c758e60f10d8848a65a19e1e61b098 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 13:49:40 +0200 Subject: [PATCH 053/324] ISSUE #346 * Rename `PostgreSqlPool` as `DatabaseClientPool`. * Rename `PostgreSqlLockPool` as `DatabaseLockPool`. --- .../minos/common/__init__.py | 2 ++ .../minos/common/database/__init__.py | 2 ++ .../minos/common/database/abc.py | 8 +++--- .../minos/common/database/pools.py | 27 ++++++++++++++++--- .../test_common/test_database/test_abc.py | 6 ++--- .../test_common/test_database/test_pools.py | 10 +++---- .../tests/test_cqrs/test_services.py | 4 +-- 7 files changed, 41 insertions(+), 18 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 2589379d8..5ac3a6818 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -14,6 +14,8 @@ MinosConfig, ) from .database import ( + DatabaseClientPool, + DatabaseLockPool, DatabaseMixin, PostgreSqlLock, PostgreSqlLockPool, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index 0003ac601..128b038aa 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -6,6 +6,8 @@ PostgreSqlLock, ) from .pools import ( + DatabaseClientPool, + DatabaseLockPool, PostgreSqlLockPool, PostgreSqlPool, ) diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 5719e762a..ff1b78c9e 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -32,7 +32,7 @@ PostgreSqlLock, ) from .pools import ( - PostgreSqlPool, + DatabaseClientPool, ) @@ -42,7 +42,7 @@ class DatabaseMixin(SetupMixin): @Inject() def __init__( self, - pool: Optional[PostgreSqlPool] = None, + pool: Optional[DatabaseClientPool] = None, pool_factory: Optional[PoolFactory] = None, *args, **kwargs, @@ -52,7 +52,7 @@ def __init__( pool = pool_factory.get_pool("database") if pool is None: - raise NotProvidedException(f"A {PostgreSqlPool!r} instance is required.") + raise NotProvidedException(f"A {DatabaseClientPool!r} instance is required.") self._pool = pool @@ -170,7 +170,7 @@ async def _fn_exit(cursor: Cursor): return ContextManager(_fn_enter, _fn_exit) @property - def pool(self) -> PostgreSqlPool: + def pool(self) -> DatabaseClientPool: """Get the connections pool. :return: A ``Pool`` object. diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 5d47ac357..9bc195df6 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -1,4 +1,5 @@ import logging +import warnings from asyncio import ( sleep, ) @@ -33,8 +34,8 @@ logger = logging.getLogger(__name__) -class PostgreSqlPool(Pool[ContextManager]): - """Postgres Pool class.""" +class DatabaseClientPool(Pool[ContextManager]): + """Database Client Pool class.""" def __init__( self, @@ -98,8 +99,16 @@ async def _check_instance(self, instance: Optional[Connection]) -> bool: return not instance.closed -class PostgreSqlLockPool(LockPool, PostgreSqlPool): - """Postgres Locking Pool class.""" +class PostgreSqlPool(DatabaseClientPool): + """TODO""" + + def __new__(cls, *args, **kwargs): + warnings.warn(f"{PostgreSqlPool!r} has been deprecated. Use {DatabaseClientPool} instead.", DeprecationWarning) + return super().__new__(cls, *args, **kwargs) + + +class DatabaseLockPool(LockPool, DatabaseClientPool): + """Database Lock Pool class.""" def acquire(self, key: Hashable, *args, **kwargs) -> PostgreSqlLock: """Acquire a new lock. @@ -108,3 +117,13 @@ def acquire(self, key: Hashable, *args, **kwargs) -> PostgreSqlLock: :return: A ``PostgreSqlLock`` instance. """ return PostgreSqlLock(super().acquire(), key, *args, **kwargs) + + +class PostgreSqlLockPool(DatabaseLockPool): + """TODO""" + + def __new__(cls, *args, **kwargs): + warnings.warn( + f"{PostgreSqlLockPool!r} has been deprecated. Use {DatabaseLockPool} instead.", DeprecationWarning + ) + return super().__new__(cls, *args, **kwargs) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index b1d307933..0a26fef8e 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -4,9 +4,9 @@ import aiopg from minos.common import ( + DatabaseClientPool, DatabaseMixin, DependencyInjector, - PostgreSqlPool, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -37,10 +37,10 @@ def test_constructor_extended(self): async def test_pool(self): async with DatabaseMixin(**self.repository_db) as database: - self.assertIsInstance(database.pool, PostgreSqlPool) + self.assertIsInstance(database.pool, DatabaseClientPool) async def test_pool_with_dependency_injections(self): - injector = DependencyInjector(self.config, [PostgreSqlPool]) + injector = DependencyInjector(self.config, [DatabaseClientPool]) await injector.wire_and_setup_injections(modules=[sys.modules[__name__]]) async with DatabaseMixin(**self.repository_db) as database: diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index 15e26fb64..ae0fb07b7 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -13,9 +13,9 @@ ) from minos.common import ( + DatabaseClientPool, + DatabaseLockPool, PostgreSqlLock, - PostgreSqlLockPool, - PostgreSqlPool, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -30,10 +30,10 @@ class TestPostgreSqlPool(PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() - self.pool = PostgreSqlPool.from_config(self.config) + self.pool = DatabaseClientPool.from_config(self.config) def test_constructor(self): - pool = PostgreSqlPool("foo") + pool = DatabaseClientPool("foo") self.assertEqual("foo", pool.database) self.assertEqual("postgres", pool.user) self.assertEqual("", pool.password) @@ -87,7 +87,7 @@ class TestPostgreSqlLockPool(PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() - self.pool = PostgreSqlLockPool.from_config(self.config) + self.pool = DatabaseLockPool.from_config(self.config) async def asyncSetUp(self): await super().asyncSetUp() diff --git a/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py b/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py index 25b6c5635..f96a207f8 100644 --- a/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py +++ b/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py @@ -7,8 +7,8 @@ ) from minos.common import ( + DatabaseLockPool, DependencyInjector, - PostgreSqlLockPool, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -38,7 +38,7 @@ class TestService(PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() - self.lock_pool = PostgreSqlLockPool.from_config(self.config) + self.lock_pool = DatabaseLockPool.from_config(self.config) self.injector = DependencyInjector(self.config, [BrokerClientPool]) self.injector.wire_injections(modules=[sys.modules[__name__]]) From 0d2069924babd381bcb4acbbdde3bbd9222835c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 1 Apr 2022 13:52:58 +0200 Subject: [PATCH 054/324] ISSUE #346 * Rename `PostgreSqlLock` as `DatabaseLock`. --- .../minos/common/__init__.py | 1 + .../minos/common/database/__init__.py | 1 + .../minos/common/database/abc.py | 4 ++-- .../minos/common/database/locks.py | 13 +++++++++++-- .../minos/common/database/pools.py | 6 +++--- .../tests/test_common/test_database/test_locks.py | 14 +++++++------- .../tests/test_common/test_database/test_pools.py | 4 ++-- 7 files changed, 27 insertions(+), 16 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 5ac3a6818..b99dfc9cd 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -15,6 +15,7 @@ ) from .database import ( DatabaseClientPool, + DatabaseLock, DatabaseLockPool, DatabaseMixin, PostgreSqlLock, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index 128b038aa..f485369b7 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -3,6 +3,7 @@ PostgreSqlMinosDatabase, ) from .locks import ( + DatabaseLock, PostgreSqlLock, ) from .pools import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index ff1b78c9e..ff723f01b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -29,7 +29,7 @@ SetupMixin, ) from .locks import ( - PostgreSqlLock, + DatabaseLock, ) from .pools import ( DatabaseClientPool, @@ -137,7 +137,7 @@ def locked_cursor(self, key: Hashable, *args, **kwargs) -> AsyncContextManager[C :param kwargs: Additional named arguments. :return: A Cursor wrapped into an asynchronous context manager. """ - lock = PostgreSqlLock(self.pool.acquire(), key, *args, **kwargs) + lock = DatabaseLock(self.pool.acquire(), key, *args, **kwargs) async def _fn_enter(): await lock.__aenter__() diff --git a/packages/core/minos-microservice-common/minos/common/database/locks.py b/packages/core/minos-microservice-common/minos/common/database/locks.py index d97f64809..20ddf528c 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks.py @@ -1,3 +1,4 @@ +import warnings from collections.abc import ( Hashable, ) @@ -16,8 +17,8 @@ ) -class PostgreSqlLock(Lock): - """ "PostgreSql Lock class.""" +class DatabaseLock(Lock): + """Database Lock class.""" cursor: Optional[Cursor] @@ -44,3 +45,11 @@ async def __aexit__(self, exc_type, exc_val, exc_tb): self.cursor.close() self.cursor = None await self.wrapped_connection.__aexit__(exc_type, exc_val, exc_tb) + + +class PostgreSqlLock(DatabaseLock): + """TODO""" + + def __new__(cls, *args, **kwargs): + warnings.warn(f"{PostgreSqlLock!r} has been deprecated. Use {DatabaseLock} instead.", DeprecationWarning) + return super().__new__(cls, *args, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 9bc195df6..95c96cd47 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -28,7 +28,7 @@ Pool, ) from .locks import ( - PostgreSqlLock, + DatabaseLock, ) logger = logging.getLogger(__name__) @@ -110,13 +110,13 @@ def __new__(cls, *args, **kwargs): class DatabaseLockPool(LockPool, DatabaseClientPool): """Database Lock Pool class.""" - def acquire(self, key: Hashable, *args, **kwargs) -> PostgreSqlLock: + def acquire(self, key: Hashable, *args, **kwargs) -> DatabaseLock: """Acquire a new lock. :param key: The key to be used for locking. :return: A ``PostgreSqlLock`` instance. """ - return PostgreSqlLock(super().acquire(), key, *args, **kwargs) + return DatabaseLock(super().acquire(), key, *args, **kwargs) class PostgreSqlLockPool(DatabaseLockPool): diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py index d6a777a2f..a8de481ad 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py @@ -6,8 +6,8 @@ ) from minos.common import ( + DatabaseLock, Lock, - PostgreSqlLock, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -21,31 +21,31 @@ class TestPostgreSqlLock(PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def test_base(self): - self.assertTrue(issubclass(PostgreSqlLock, Lock)) + self.assertTrue(issubclass(DatabaseLock, Lock)) async def test_wrapped_connection(self): wrapped_connection = aiopg.connect(**self.repository_db) - lock = PostgreSqlLock(wrapped_connection, "foo") + lock = DatabaseLock(wrapped_connection, "foo") self.assertEqual(wrapped_connection, lock.wrapped_connection) async def test_key(self): wrapped_connection = aiopg.connect(**self.repository_db) - lock = PostgreSqlLock(wrapped_connection, "foo") + lock = DatabaseLock(wrapped_connection, "foo") self.assertEqual("foo", lock.key) async def test_key_raises(self): wrapped_connection = aiopg.connect(**self.repository_db) with self.assertRaises(ValueError): - PostgreSqlLock(wrapped_connection, []) + DatabaseLock(wrapped_connection, []) async def test_hashed_key(self): wrapped_connection = aiopg.connect(**self.repository_db) - lock = PostgreSqlLock(wrapped_connection, "foo") + lock = DatabaseLock(wrapped_connection, "foo") self.assertEqual(hash("foo"), lock.hashed_key) async def test_cursor(self): wrapped_connection = aiopg.connect(**self.repository_db) - async with PostgreSqlLock(wrapped_connection, "foo") as lock: + async with DatabaseLock(wrapped_connection, "foo") as lock: self.assertIsInstance(lock.cursor, Cursor) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index ae0fb07b7..7095de548 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -14,8 +14,8 @@ from minos.common import ( DatabaseClientPool, + DatabaseLock, DatabaseLockPool, - PostgreSqlLock, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -99,7 +99,7 @@ async def asyncTearDown(self): async def test_acquire(self): async with self.pool.acquire("foo") as lock: - self.assertIsInstance(lock, PostgreSqlLock) + self.assertIsInstance(lock, DatabaseLock) self.assertEqual("foo", lock.key) From 32d21bbcb10e15a9cb20d47fbc0ab4e8c933948c Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 1 Apr 2022 14:14:24 +0200 Subject: [PATCH 055/324] ISSUE #144 --- .../workflows/minos-discovery-kong-tests.yml | 80 ++----------------- 1 file changed, 5 insertions(+), 75 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 4f527e714..a027f2f97 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -19,82 +19,12 @@ jobs: run: working-directory: packages/plugins/minos-discovery-kong - services: - kong-migrations: - image: kong/kong-gateway:2.8.0.0-alpine - command: kong migrations bootstrap - depends_on: - - db - environment: - KONG_DATABASE: postgres - KONG_PG_DATABASE: kong - KONG_PG_HOST: db - KONG_PG_USER: kong - KONG_PG_PASSWORD: kong - restart: on-failure - - kong-migrations-up: - image: kong/kong-gateway:2.8.0.0-alpine - command: kong migrations up && kong migrations finish - depends_on: - - db - environment: - KONG_DATABASE: postgres - KONG_PG_DATABASE: kong - KONG_PG_HOST: db - KONG_PG_USER: kong - KONG_PG_PASSWORD: kong - restart: on-failure - - kong: - image: kong/kong-gateway:2.8.0.0-alpine - user: kong - environment: - KONG_DATABASE: postgres - KONG_PG_DATABASE: kong - KONG_PG_HOST: db - KONG_PG_USER: kong - KONG_PG_PASSWORD: kong - KONG_ADMIN_ACCESS_LOG: /dev/stdout - KONG_ADMIN_ERROR_LOG: /dev/stderr - KONG_PROXY_LISTEN: 0.0.0.0:8000 - KONG_ADMIN_LISTEN: 0.0.0.0:8001 - KONG_PROXY_ACCESS_LOG: /dev/stdout - KONG_PROXY_ERROR_LOG: /dev/stderr - KONG_PREFIX: /var/run/kong - KONG_LOG_LEVEL: debug - KONG_DECLARATIVE_CONFIG: "/opt/kong/kong.yaml" - ports: - - "0.0.0.0:8000:8000/tcp" - - "0.0.0.0:8443:8443/tcp" - - "127.0.0.1:8001:8001/tcp" - - "127.0.0.1:8444:8444/tcp" - healthcheck: - test: [ "CMD", "kong", "health" ] - interval: 10s - timeout: 10s - retries: 10 - restart: on-failure:5 - read_only: true - security_opt: - - no-new-privileges - - db: - image: postgres:9.5 - environment: - POSTGRES_DB: kong - POSTGRES_USER: kong - POSTGRES_PASSWORD: kong - healthcheck: - test: [ "CMD", "pg_isready", "-U", "kong" ] - interval: 30s - timeout: 30s - retries: 3 - restart: on-failure - stdin_open: true - tty: true - steps: + - name: Fire up Docker Compose setup with Kong & do some checks + run: | + docker-compose -f /tests/docker-compose.yml up -d + echo "Let's wait until Kong is available (we need to improve this)" + sleep 10 - name: Check out repository code uses: actions/checkout@v2 From 64e692bcb40c09ae81896651299d6c6646482769 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 1 Apr 2022 14:18:08 +0200 Subject: [PATCH 056/324] ISSUE #144 --- .github/workflows/minos-discovery-kong-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index a027f2f97..7657df1b9 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -22,7 +22,7 @@ jobs: steps: - name: Fire up Docker Compose setup with Kong & do some checks run: | - docker-compose -f /tests/docker-compose.yml up -d + docker-compose -f packages/plugins/minos-discovery-kong/tests/docker-compose.yml up -d echo "Let's wait until Kong is available (we need to improve this)" sleep 10 - name: Check out repository code From 1aded805e585e7257fb0a04d7f5b2877de4d9c88 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 1 Apr 2022 14:21:40 +0200 Subject: [PATCH 057/324] ISSUE #144 --- .github/workflows/minos-discovery-kong-tests.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 7657df1b9..df2aba730 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -21,10 +21,8 @@ jobs: steps: - name: Fire up Docker Compose setup with Kong & do some checks - run: | - docker-compose -f packages/plugins/minos-discovery-kong/tests/docker-compose.yml up -d - echo "Let's wait until Kong is available (we need to improve this)" - sleep 10 + run: docker-compose -f "tests/docker-compose.yml" up -d --build + - name: Check out repository code uses: actions/checkout@v2 @@ -52,3 +50,7 @@ jobs: - name: Generate build run: make dist + + - name: Stop containers + if: always() + run: docker-compose -f "tests/docker-compose.yml" down From 4f203714d2c73c7f228af809510b59a55a070d83 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 14:33:57 +0200 Subject: [PATCH 058/324] removed lock --- packages/plugins/minos-kong/poetry.lock | 1575 ----------------------- 1 file changed, 1575 deletions(-) delete mode 100644 packages/plugins/minos-kong/poetry.lock diff --git a/packages/plugins/minos-kong/poetry.lock b/packages/plugins/minos-kong/poetry.lock deleted file mode 100644 index 5e1603013..000000000 --- a/packages/plugins/minos-kong/poetry.lock +++ /dev/null @@ -1,1575 +0,0 @@ -[[package]] -name = "aiomisc" -version = "15.7.3" -description = "aiomisc - miscellaneous utils for asyncio" -category = "main" -optional = false -python-versions = "*" - -[package.dependencies] -colorlog = "*" - -[package.extras] -aiohttp = ["aiohttp"] -asgi = ["aiohttp-asgi"] -carbon = ["aiocarbon (>=0.15,<1.0)"] -contextvars = ["contextvars (>=2.4,<3.0)"] -cron = ["croniter (>=0.3.34,<0.4.0)"] -develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-timeout", "coveralls", "croniter (>=0.3.34,<0.4.0)", "fastapi", "freezegun (<1.1)", "mypy (>=0.782,<1.0)", "pylava", "pytest", "pytest-cov (>=3.0,<4.0)", "pytest-freezegun (>=0.4.2,<0.5.0)", "pytest-rst", "pytest-subtests", "rich", "setproctitle", "sphinx-autobuild", "sphinx-intl", "sphinx (>=3.5.1)", "timeout-decorator", "tox (>=2.4)", "types-croniter"] -raven = ["raven-aiohttp"] -uvloop = ["uvloop (>=0.14,<1)"] - -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - -[[package]] -name = "alabaster" -version = "0.7.12" -description = "A configurable sidebar-enabled Sphinx theme" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "anyio" -version = "3.5.0" -description = "High level compatibility layer for multiple asynchronous event loop implementations" -category = "main" -optional = false -python-versions = ">=3.6.2" - -[package.dependencies] -idna = ">=2.8" -sniffio = ">=1.1" - -[package.extras] -doc = ["packaging", "sphinx-rtd-theme", "sphinx-autodoc-typehints (>=1.2.0)"] -test = ["coverage[toml] (>=4.5)", "hypothesis (>=4.0)", "pytest (>=6.0)", "pytest-mock (>=3.6.1)", "trustme", "contextlib2", "uvloop (<0.15)", "mock (>=4)", "uvloop (>=0.15)"] -trio = ["trio (>=0.16)"] - -[[package]] -name = "async-timeout" -version = "4.0.2" -description = "Timeout context manager for asyncio programs" -category = "main" -optional = false -python-versions = ">=3.6" - -[[package]] -name = "atomicwrites" -version = "1.4.0" -description = "Atomic file writes." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "attrs" -version = "21.4.0" -description = "Classes Without Boilerplate" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - -[package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] - -[[package]] -name = "babel" -version = "2.9.1" -description = "Internationalization utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.dependencies] -pytz = ">=2015.7" - -[[package]] -name = "black" -version = "22.3.0" -description = "The uncompromising code formatter." -category = "dev" -optional = false -python-versions = ">=3.6.2" - -[package.dependencies] -click = ">=8.0.0" -mypy-extensions = ">=0.4.3" -pathspec = ">=0.9.0" -platformdirs = ">=2" -tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} -typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} - -[package.extras] -colorama = ["colorama (>=0.4.3)"] -d = ["aiohttp (>=3.7.4)"] -jupyter = ["ipython (>=7.8.0)", "tokenize-rt (>=3.2.0)"] -uvloop = ["uvloop (>=0.15.2)"] - -[[package]] -name = "cached-property" -version = "1.5.2" -description = "A decorator for caching properties in classes." -category = "main" -optional = false -python-versions = "*" - -[[package]] -name = "certifi" -version = "2021.10.8" -description = "Python package for providing Mozilla's CA Bundle." -category = "main" -optional = false -python-versions = "*" - -[[package]] -name = "cfgv" -version = "3.3.1" -description = "Validate configuration and produce human readable error messages." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[[package]] -name = "charset-normalizer" -version = "2.0.12" -description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "main" -optional = false -python-versions = ">=3.5.0" - -[package.extras] -unicode_backport = ["unicodedata2"] - -[[package]] -name = "click" -version = "8.1.2" -description = "Composable command line interface toolkit" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -colorama = {version = "*", markers = "platform_system == \"Windows\""} - -[[package]] -name = "colorama" -version = "0.4.4" -description = "Cross-platform colored terminal text." -category = "main" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - -[[package]] -name = "colorlog" -version = "6.6.0" -description = "Add colours to the output of Python's logging module." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -colorama = {version = "*", markers = "sys_platform == \"win32\""} - -[package.extras] -development = ["black", "flake8", "mypy", "pytest", "types-colorama"] - -[[package]] -name = "coverage" -version = "6.3.2" -description = "Code coverage measurement for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -toml = ["tomli"] - -[[package]] -name = "crontab" -version = "0.23.0" -description = "Parse and use crontab schedules in Python" -category = "main" -optional = false -python-versions = "*" - -[[package]] -name = "dependency-injector" -version = "4.39.1" -description = "Dependency injection framework for Python" -category = "main" -optional = false -python-versions = "*" - -[package.dependencies] -six = ">=1.7.0,<=1.16.0" - -[package.extras] -aiohttp = ["aiohttp"] -flask = ["flask"] -pydantic = ["pydantic"] -yaml = ["pyyaml"] - -[[package]] -name = "distlib" -version = "0.3.4" -description = "Distribution utilities" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "docutils" -version = "0.17.1" -description = "Docutils -- Python Documentation Utilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - -[[package]] -name = "fastavro" -version = "1.4.10" -description = "Fast read/write of AVRO files" -category = "main" -optional = false -python-versions = ">=3.7" - -[package.extras] -codecs = ["python-snappy", "zstandard", "lz4"] -lz4 = ["lz4"] -snappy = ["python-snappy"] -zstandard = ["zstandard"] - -[[package]] -name = "filelock" -version = "3.6.0" -description = "A platform independent file lock." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo (>=2021.8.17b43)", "sphinx (>=4.1)", "sphinx-autodoc-typehints (>=1.12)"] -testing = ["covdefaults (>=1.2.0)", "coverage (>=4)", "pytest (>=4)", "pytest-cov", "pytest-timeout (>=1.4.2)"] - -[[package]] -name = "flake8" -version = "4.0.1" -description = "the modular source code checker: pep8 pyflakes and co" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -mccabe = ">=0.6.0,<0.7.0" -pycodestyle = ">=2.8.0,<2.9.0" -pyflakes = ">=2.4.0,<2.5.0" - -[[package]] -name = "h11" -version = "0.12.0" -description = "A pure-Python, bring-your-own-I/O implementation of HTTP/1.1" -category = "main" -optional = false -python-versions = ">=3.6" - -[[package]] -name = "httpcore" -version = "0.14.7" -description = "A minimal low-level HTTP client." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -anyio = ">=3.0.0,<4.0.0" -certifi = "*" -h11 = ">=0.11,<0.13" -sniffio = ">=1.0.0,<2.0.0" - -[package.extras] -http2 = ["h2 (>=3,<5)"] -socks = ["socksio (>=1.0.0,<2.0.0)"] - -[[package]] -name = "httpx" -version = "0.22.0" -description = "The next generation HTTP client." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -certifi = "*" -charset-normalizer = "*" -httpcore = ">=0.14.5,<0.15.0" -rfc3986 = {version = ">=1.3,<2", extras = ["idna2008"]} -sniffio = "*" - -[package.extras] -brotli = ["brotlicffi", "brotli"] -cli = ["click (>=8.0.0,<9.0.0)", "rich (>=10.0.0,<11.0.0)", "pygments (>=2.0.0,<3.0.0)"] -http2 = ["h2 (>=3,<5)"] -socks = ["socksio (>=1.0.0,<2.0.0)"] - -[[package]] -name = "identify" -version = "2.4.12" -description = "File identification library for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -license = ["ukkonen"] - -[[package]] -name = "idna" -version = "3.3" -description = "Internationalized Domain Names in Applications (IDNA)" -category = "main" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "imagesize" -version = "1.3.0" -description = "Getting image size from png/jpeg/jpeg2000/gif file" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "importlib-metadata" -version = "4.11.3" -description = "Read metadata from Python packages" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -zipp = ">=0.5" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] -perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] - -[[package]] -name = "iniconfig" -version = "1.1.1" -description = "iniconfig: brain-dead simple config-ini parsing" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "isort" -version = "5.10.1" -description = "A Python utility / library to sort Python imports." -category = "dev" -optional = false -python-versions = ">=3.6.1,<4.0" - -[package.extras] -pipfile_deprecated_finder = ["pipreqs", "requirementslib"] -requirements_deprecated_finder = ["pipreqs", "pip-api"] -colors = ["colorama (>=0.4.3,<0.5.0)"] -plugins = ["setuptools"] - -[[package]] -name = "jinja2" -version = "3.1.1" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - -[[package]] -name = "m2r2" -version = "0.3.2" -description = "Markdown and reStructuredText in a single file." -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -docutils = "*" -mistune = "0.8.4" - -[[package]] -name = "markupsafe" -version = "2.1.1" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "mccabe" -version = "0.6.1" -description = "McCabe checker, plugin for flake8" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "minos-microservice-common" -version = "0.6.0" -description = "The common core of the Minos Framework" -category = "main" -optional = false -python-versions = ">=3.9,<4.0" - -[package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" -aiopg = ">=1.2.1,<2.0.0" -cached-property = ">=1.5.2,<2.0.0" -dependency-injector = ">=4.32.2,<5.0.0" -fastavro = ">=1.4.0,<2.0.0" -lmdb = ">=1.2.1,<2.0.0" -orjson = ">=3.5.2,<4.0.0" -PyYAML = ">=5.4.1,<7.0.0" -uvloop = ">=0.16.0,<0.17.0" - -[[package]] -name = "minos-microservice-networks" -version = "0.6.0" -description = "The networks core of the Minos Framework" -category = "main" -optional = false -python-versions = ">=3.9,<4.0" - -[package.dependencies] -aiopg = ">=1.2.1,<2.0.0" -crontab = ">=0.23.0,<0.24.0" -minos-microservice-common = ">=0.6.0,<0.7.0" -psycopg2-binary = ">=2.9.3,<3.0.0" - -[[package]] -name = "mistune" -version = "0.8.4" -description = "The fastest markdown parser in pure Python" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "mypy-extensions" -version = "0.4.3" -description = "Experimental type system extensions for programs checked with the mypy typechecker." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "nodeenv" -version = "1.6.0" -description = "Node.js virtual environment builder" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "orjson" -version = "3.6.7" -description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" -category = "main" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "packaging" -version = "21.3" -description = "Core utilities for Python packages" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" - -[[package]] -name = "pathspec" -version = "0.9.0" -description = "Utility library for gitignore style pattern matching of file paths." -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[[package]] -name = "pbr" -version = "5.8.1" -description = "Python Build Reasonableness" -category = "dev" -optional = false -python-versions = ">=2.6" - -[[package]] -name = "platformdirs" -version = "2.5.1" -description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] - -[[package]] -name = "pluggy" -version = "1.0.0" -description = "plugin and hook calling mechanisms for python" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -dev = ["pre-commit", "tox"] -testing = ["pytest", "pytest-benchmark"] - -[[package]] -name = "pre-commit" -version = "2.17.0" -description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" -optional = false -python-versions = ">=3.6.1" - -[package.dependencies] -cfgv = ">=2.0.0" -identify = ">=1.0.0" -nodeenv = ">=0.11.1" -pyyaml = ">=5.1" -toml = "*" -virtualenv = ">=20.0.8" - -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - -[[package]] -name = "py" -version = "1.11.0" -description = "library with cross-python path, ini-parsing, io, code, log facilities" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - -[[package]] -name = "pycodestyle" -version = "2.8.0" -description = "Python style guide checker" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - -[[package]] -name = "pyflakes" -version = "2.4.0" -description = "passive checker of Python programs" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "pygments" -version = "2.11.2" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -diagrams = ["jinja2", "railroad-diagrams"] - -[[package]] -name = "pytest" -version = "6.2.5" -description = "pytest: simple powerful testing with Python" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -atomicwrites = {version = ">=1.0", markers = "sys_platform == \"win32\""} -attrs = ">=19.2.0" -colorama = {version = "*", markers = "sys_platform == \"win32\""} -iniconfig = "*" -packaging = "*" -pluggy = ">=0.12,<2.0" -py = ">=1.8.2" -toml = "*" - -[package.extras] -testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] - -[[package]] -name = "pytz" -version = "2022.1" -description = "World timezone definitions, modern and historical" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "pyyaml" -version = "6.0" -description = "YAML parser and emitter for Python" -category = "main" -optional = false -python-versions = ">=3.6" - -[[package]] -name = "requests" -version = "2.27.1" -description = "Python HTTP for Humans." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" - -[package.dependencies] -certifi = ">=2017.4.17" -charset-normalizer = {version = ">=2.0.0,<2.1.0", markers = "python_version >= \"3\""} -idna = {version = ">=2.5,<4", markers = "python_version >= \"3\""} -urllib3 = ">=1.21.1,<1.27" - -[package.extras] -socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"] -use_chardet_on_py3 = ["chardet (>=3.0.2,<5)"] - -[[package]] -name = "rfc3986" -version = "1.5.0" -description = "Validating URI References per RFC 3986" -category = "main" -optional = false -python-versions = "*" - -[package.dependencies] -idna = {version = "*", optional = true, markers = "extra == \"idna2008\""} - -[package.extras] -idna2008 = ["idna"] - -[[package]] -name = "six" -version = "1.16.0" -description = "Python 2 and 3 compatibility utilities" -category = "main" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" - -[[package]] -name = "sniffio" -version = "1.2.0" -description = "Sniff out which async library your code is running under" -category = "main" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "snowballstemmer" -version = "2.2.0" -description = "This package provides 29 stemmers for 28 languages generated from Snowball algorithms." -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "sphinx" -version = "4.5.0" -description = "Python documentation generator" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -alabaster = ">=0.7,<0.8" -babel = ">=1.3" -colorama = {version = ">=0.3.5", markers = "sys_platform == \"win32\""} -docutils = ">=0.14,<0.18" -imagesize = "*" -importlib-metadata = {version = ">=4.4", markers = "python_version < \"3.10\""} -Jinja2 = ">=2.3" -packaging = "*" -Pygments = ">=2.0" -requests = ">=2.5.0" -snowballstemmer = ">=1.1" -sphinxcontrib-applehelp = "*" -sphinxcontrib-devhelp = "*" -sphinxcontrib-htmlhelp = ">=2.0.0" -sphinxcontrib-jsmath = "*" -sphinxcontrib-qthelp = "*" -sphinxcontrib-serializinghtml = ">=1.1.5" - -[package.extras] -docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] - -[[package]] -name = "sphinx-autodoc-typehints" -version = "1.17.0" -description = "Type hints (PEP 484) support for the Sphinx autodoc extension" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -Sphinx = ">=4" - -[package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] - -[[package]] -name = "sphinx-rtd-theme" -version = "1.0.0" -description = "Read the Docs theme for Sphinx" -category = "dev" -optional = false -python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" - -[package.dependencies] -docutils = "<0.18" -sphinx = ">=1.6" - -[package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] - -[[package]] -name = "sphinxcontrib-apidoc" -version = "0.3.0" -description = "A Sphinx extension for running 'sphinx-apidoc' on each build" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -pbr = "*" -Sphinx = ">=1.6.0" - -[[package]] -name = "sphinxcontrib-applehelp" -version = "1.0.2" -description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-devhelp" -version = "1.0.2" -description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-htmlhelp" -version = "2.0.0" -description = "sphinxcontrib-htmlhelp is a sphinx extension which renders HTML help files" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] - -[[package]] -name = "sphinxcontrib-jsmath" -version = "1.0.1" -description = "A sphinx extension which renders display math in HTML via JavaScript" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -test = ["pytest", "flake8", "mypy"] - -[[package]] -name = "sphinxcontrib-qthelp" -version = "1.0.3" -description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "sphinxcontrib-serializinghtml" -version = "1.1.5" -description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle)." -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest"] - -[[package]] -name = "toml" -version = "0.10.2" -description = "Python Library for Tom's Obvious, Minimal Language" -category = "dev" -optional = false -python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" - -[[package]] -name = "tomli" -version = "2.0.1" -description = "A lil' TOML parser" -category = "dev" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" -category = "dev" -optional = false -python-versions = ">=3.6" - -[[package]] -name = "urllib3" -version = "1.26.9" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" - -[package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "ipaddress"] -socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] - -[[package]] -name = "uvloop" -version = "0.16.0" -description = "Fast implementation of asyncio event loop on top of libuv" -category = "main" -optional = false -python-versions = ">=3.7" - -[package.extras] -dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)", "aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] -docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] -test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] - -[[package]] -name = "virtualenv" -version = "20.14.0" -description = "Virtual Python Environment builder" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" - -[package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)", "packaging (>=20.0)"] - -[[package]] -name = "zipp" -version = "3.7.0" -description = "Backport of pathlib-compatible object wrapper for zip files" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] - -[metadata] -lock-version = "1.1" -python-versions = "^3.9" -content-hash = "07bd71f88b36e01b18398d6f64ad71f32fdce4736c2f9898fbe1dc5c96fb3297" - -[metadata.files] -aiomisc = [ - {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, - {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, -] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] -alabaster = [ - {file = "alabaster-0.7.12-py2.py3-none-any.whl", hash = "sha256:446438bdcca0e05bd45ea2de1668c1d9b032e1a9154c2c259092d77031ddd359"}, - {file = "alabaster-0.7.12.tar.gz", hash = "sha256:a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02"}, -] -anyio = [ - {file = "anyio-3.5.0-py3-none-any.whl", hash = "sha256:b5fa16c5ff93fa1046f2eeb5bbff2dad4d3514d6cda61d02816dba34fa8c3c2e"}, - {file = "anyio-3.5.0.tar.gz", hash = "sha256:a0aeffe2fb1fdf374a8e4b471444f0f3ac4fb9f5a5b542b48824475e0042a5a6"}, -] -async-timeout = [ - {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, - {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, -] -atomicwrites = [ - {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, - {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, -] -attrs = [ - {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, - {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, -] -babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, -] -black = [ - {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, - {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, - {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, - {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, - {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, - {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, - {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, - {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, - {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, - {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, - {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, - {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, - {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, - {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, - {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, - {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, - {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, - {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, - {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, - {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, - {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, - {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, - {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, -] -cached-property = [ - {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, - {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, -] -certifi = [ - {file = "certifi-2021.10.8-py2.py3-none-any.whl", hash = "sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"}, - {file = "certifi-2021.10.8.tar.gz", hash = "sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872"}, -] -cfgv = [ - {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, - {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, -] -charset-normalizer = [ - {file = "charset-normalizer-2.0.12.tar.gz", hash = "sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597"}, - {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, -] -click = [ - {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, - {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, -] -colorama = [ - {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, - {file = "colorama-0.4.4.tar.gz", hash = "sha256:5941b2b48a20143d2267e95b1c2a7603ce057ee39fd88e7329b0c292aa16869b"}, -] -colorlog = [ - {file = "colorlog-6.6.0-py2.py3-none-any.whl", hash = "sha256:351c51e866c86c3217f08e4b067a7974a678be78f07f85fc2d55b8babde6d94e"}, - {file = "colorlog-6.6.0.tar.gz", hash = "sha256:344f73204009e4c83c5b6beb00b3c45dc70fcdae3c80db919e0a4171d006fde8"}, -] -coverage = [ - {file = "coverage-6.3.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:9b27d894748475fa858f9597c0ee1d4829f44683f3813633aaf94b19cb5453cf"}, - {file = "coverage-6.3.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:37d1141ad6b2466a7b53a22e08fe76994c2d35a5b6b469590424a9953155afac"}, - {file = "coverage-6.3.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f9987b0354b06d4df0f4d3e0ec1ae76d7ce7cbca9a2f98c25041eb79eec766f1"}, - {file = "coverage-6.3.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:26e2deacd414fc2f97dd9f7676ee3eaecd299ca751412d89f40bc01557a6b1b4"}, - {file = "coverage-6.3.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4dd8bafa458b5c7d061540f1ee9f18025a68e2d8471b3e858a9dad47c8d41903"}, - {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:46191097ebc381fbf89bdce207a6c107ac4ec0890d8d20f3360345ff5976155c"}, - {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:6f89d05e028d274ce4fa1a86887b071ae1755082ef94a6740238cd7a8178804f"}, - {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:58303469e9a272b4abdb9e302a780072c0633cdcc0165db7eec0f9e32f901e05"}, - {file = "coverage-6.3.2-cp310-cp310-win32.whl", hash = "sha256:2fea046bfb455510e05be95e879f0e768d45c10c11509e20e06d8fcaa31d9e39"}, - {file = "coverage-6.3.2-cp310-cp310-win_amd64.whl", hash = "sha256:a2a8b8bcc399edb4347a5ca8b9b87e7524c0967b335fbb08a83c8421489ddee1"}, - {file = "coverage-6.3.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:f1555ea6d6da108e1999b2463ea1003fe03f29213e459145e70edbaf3e004aaa"}, - {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e5f4e1edcf57ce94e5475fe09e5afa3e3145081318e5fd1a43a6b4539a97e518"}, - {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7a15dc0a14008f1da3d1ebd44bdda3e357dbabdf5a0b5034d38fcde0b5c234b7"}, - {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:21b7745788866028adeb1e0eca3bf1101109e2dc58456cb49d2d9b99a8c516e6"}, - {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:8ce257cac556cb03be4a248d92ed36904a59a4a5ff55a994e92214cde15c5bad"}, - {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:b0be84e5a6209858a1d3e8d1806c46214e867ce1b0fd32e4ea03f4bd8b2e3359"}, - {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:acf53bc2cf7282ab9b8ba346746afe703474004d9e566ad164c91a7a59f188a4"}, - {file = "coverage-6.3.2-cp37-cp37m-win32.whl", hash = "sha256:8bdde1177f2311ee552f47ae6e5aa7750c0e3291ca6b75f71f7ffe1f1dab3dca"}, - {file = "coverage-6.3.2-cp37-cp37m-win_amd64.whl", hash = "sha256:b31651d018b23ec463e95cf10070d0b2c548aa950a03d0b559eaa11c7e5a6fa3"}, - {file = "coverage-6.3.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:07e6db90cd9686c767dcc593dff16c8c09f9814f5e9c51034066cad3373b914d"}, - {file = "coverage-6.3.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:2c6dbb42f3ad25760010c45191e9757e7dce981cbfb90e42feef301d71540059"}, - {file = "coverage-6.3.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c76aeef1b95aff3905fb2ae2d96e319caca5b76fa41d3470b19d4e4a3a313512"}, - {file = "coverage-6.3.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:8cf5cfcb1521dc3255d845d9dca3ff204b3229401994ef8d1984b32746bb45ca"}, - {file = "coverage-6.3.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8fbbdc8d55990eac1b0919ca69eb5a988a802b854488c34b8f37f3e2025fa90d"}, - {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ec6bc7fe73a938933d4178c9b23c4e0568e43e220aef9472c4f6044bfc6dd0f0"}, - {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:9baff2a45ae1f17c8078452e9e5962e518eab705e50a0aa8083733ea7d45f3a6"}, - {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:fd9e830e9d8d89b20ab1e5af09b32d33e1a08ef4c4e14411e559556fd788e6b2"}, - {file = "coverage-6.3.2-cp38-cp38-win32.whl", hash = "sha256:f7331dbf301b7289013175087636bbaf5b2405e57259dd2c42fdcc9fcc47325e"}, - {file = "coverage-6.3.2-cp38-cp38-win_amd64.whl", hash = "sha256:68353fe7cdf91f109fc7d474461b46e7f1f14e533e911a2a2cbb8b0fc8613cf1"}, - {file = "coverage-6.3.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b78e5afb39941572209f71866aa0b206c12f0109835aa0d601e41552f9b3e620"}, - {file = "coverage-6.3.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:4e21876082ed887baed0146fe222f861b5815455ada3b33b890f4105d806128d"}, - {file = "coverage-6.3.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:34626a7eee2a3da12af0507780bb51eb52dca0e1751fd1471d0810539cefb536"}, - {file = "coverage-6.3.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1ebf730d2381158ecf3dfd4453fbca0613e16eaa547b4170e2450c9707665ce7"}, - {file = "coverage-6.3.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dd6fe30bd519694b356cbfcaca9bd5c1737cddd20778c6a581ae20dc8c04def2"}, - {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:96f8a1cb43ca1422f36492bebe63312d396491a9165ed3b9231e778d43a7fca4"}, - {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:dd035edafefee4d573140a76fdc785dc38829fe5a455c4bb12bac8c20cfc3d69"}, - {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:5ca5aeb4344b30d0bec47481536b8ba1181d50dbe783b0e4ad03c95dc1296684"}, - {file = "coverage-6.3.2-cp39-cp39-win32.whl", hash = "sha256:f5fa5803f47e095d7ad8443d28b01d48c0359484fec1b9d8606d0e3282084bc4"}, - {file = "coverage-6.3.2-cp39-cp39-win_amd64.whl", hash = "sha256:9548f10d8be799551eb3a9c74bbf2b4934ddb330e08a73320123c07f95cc2d92"}, - {file = "coverage-6.3.2-pp36.pp37.pp38-none-any.whl", hash = "sha256:18d520c6860515a771708937d2f78f63cc47ab3b80cb78e86573b0a760161faf"}, - {file = "coverage-6.3.2.tar.gz", hash = "sha256:03e2a7826086b91ef345ff18742ee9fc47a6839ccd517061ef8fa1976e652ce9"}, -] -crontab = [ - {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, -] -dependency-injector = [ - {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, - {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, - {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, - {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, - {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, - {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, - {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, - {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, - {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, - {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, - {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, - {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, - {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, - {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, - {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, - {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, - {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, - {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, - {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, - {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, - {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, - {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, - {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, - {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, - {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, - {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, - {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, - {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, - {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, - {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, - {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, - {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, - {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, - {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, - {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, - {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, -] -distlib = [ - {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, - {file = "distlib-0.3.4.zip", hash = "sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"}, -] -docutils = [ - {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, - {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, -] -fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, -] -filelock = [ - {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, - {file = "filelock-3.6.0.tar.gz", hash = "sha256:9cd540a9352e432c7246a48fe4e8712b10acb1df2ad1f30e8c070b82ae1fed85"}, -] -flake8 = [ - {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, - {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, -] -h11 = [ - {file = "h11-0.12.0-py3-none-any.whl", hash = "sha256:36a3cb8c0a032f56e2da7084577878a035d3b61d104230d4bd49c0c6b555a9c6"}, - {file = "h11-0.12.0.tar.gz", hash = "sha256:47222cb6067e4a307d535814917cd98fd0a57b6788ce715755fa2b6c28b56042"}, -] -httpcore = [ - {file = "httpcore-0.14.7-py3-none-any.whl", hash = "sha256:47d772f754359e56dd9d892d9593b6f9870a37aeb8ba51e9a88b09b3d68cfade"}, - {file = "httpcore-0.14.7.tar.gz", hash = "sha256:7503ec1c0f559066e7e39bc4003fd2ce023d01cf51793e3c173b864eb456ead1"}, -] -httpx = [ - {file = "httpx-0.22.0-py3-none-any.whl", hash = "sha256:e35e83d1d2b9b2a609ef367cc4c1e66fd80b750348b20cc9e19d1952fc2ca3f6"}, - {file = "httpx-0.22.0.tar.gz", hash = "sha256:d8e778f76d9bbd46af49e7f062467e3157a5a3d2ae4876a4bbfd8a51ed9c9cb4"}, -] -identify = [ - {file = "identify-2.4.12-py2.py3-none-any.whl", hash = "sha256:5f06b14366bd1facb88b00540a1de05b69b310cbc2654db3c7e07fa3a4339323"}, - {file = "identify-2.4.12.tar.gz", hash = "sha256:3f3244a559290e7d3deb9e9adc7b33594c1bc85a9dd82e0f1be519bf12a1ec17"}, -] -idna = [ - {file = "idna-3.3-py3-none-any.whl", hash = "sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff"}, - {file = "idna-3.3.tar.gz", hash = "sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"}, -] -imagesize = [ - {file = "imagesize-1.3.0-py2.py3-none-any.whl", hash = "sha256:1db2f82529e53c3e929e8926a1fa9235aa82d0bd0c580359c67ec31b2fddaa8c"}, - {file = "imagesize-1.3.0.tar.gz", hash = "sha256:cd1750d452385ca327479d45b64d9c7729ecf0b3969a58148298c77092261f9d"}, -] -importlib-metadata = [ - {file = "importlib_metadata-4.11.3-py3-none-any.whl", hash = "sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6"}, - {file = "importlib_metadata-4.11.3.tar.gz", hash = "sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539"}, -] -iniconfig = [ - {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, - {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, -] -isort = [ - {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, - {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, -] -jinja2 = [ - {file = "Jinja2-3.1.1-py3-none-any.whl", hash = "sha256:539835f51a74a69f41b848a9645dbdc35b4f20a3b601e2d9a7e22947b15ff119"}, - {file = "Jinja2-3.1.1.tar.gz", hash = "sha256:640bed4bb501cbd17194b3cace1dc2126f5b619cf068a726b98192a0fde74ae9"}, -] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] -m2r2 = [ - {file = "m2r2-0.3.2-py3-none-any.whl", hash = "sha256:d3684086b61b4bebe2307f15189495360f05a123c9bda2a66462649b7ca236aa"}, - {file = "m2r2-0.3.2.tar.gz", hash = "sha256:ccd95b052dcd1ac7442ecb3111262b2001c10e4119b459c34c93ac7a5c2c7868"}, -] -markupsafe = [ - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"}, - {file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"}, - {file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"}, - {file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"}, - {file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"}, - {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, -] -mccabe = [ - {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, - {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, -] -minos-microservice-common = [ - {file = "minos-microservice-common-0.6.0.tar.gz", hash = "sha256:6faae0c4bae605b5671a317cb75349faa1fe49421475254f53913ab3597dc24a"}, - {file = "minos_microservice_common-0.6.0-py3-none-any.whl", hash = "sha256:3c09167aeae31b57451968d27ab94d67473f1276bca5b8701a89f85b37730571"}, -] -minos-microservice-networks = [ - {file = "minos-microservice-networks-0.6.0.tar.gz", hash = "sha256:c1240fefdab20549afd6cd014a6262c75dde94ca2181f3dff3a9c2d9d59369d0"}, - {file = "minos_microservice_networks-0.6.0-py3-none-any.whl", hash = "sha256:52dee56c57bed9521272d94b30bb0660001c11b0be90a2b079196a1252def047"}, -] -mistune = [ - {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, - {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, -] -mypy-extensions = [ - {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, - {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, -] -nodeenv = [ - {file = "nodeenv-1.6.0-py2.py3-none-any.whl", hash = "sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"}, - {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, -] -orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, -] -packaging = [ - {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, - {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, -] -pathspec = [ - {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, - {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, -] -pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, -] -platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, -] -pluggy = [ - {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, - {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, -] -pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, -] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] -py = [ - {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, - {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, -] -pycodestyle = [ - {file = "pycodestyle-2.8.0-py2.py3-none-any.whl", hash = "sha256:720f8b39dde8b293825e7ff02c475f3077124006db4f440dcbc9a20b76548a20"}, - {file = "pycodestyle-2.8.0.tar.gz", hash = "sha256:eddd5847ef438ea1c7870ca7eb78a9d47ce0cdb4851a5523949f2601d0cbbe7f"}, -] -pyflakes = [ - {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, - {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, -] -pygments = [ - {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, - {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, -] -pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, -] -pytest = [ - {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, - {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, -] -pytz = [ - {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, - {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, -] -pyyaml = [ - {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, - {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, - {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, - {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b"}, - {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, - {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, - {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, - {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, - {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, - {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, - {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4"}, - {file = "PyYAML-6.0-cp36-cp36m-win32.whl", hash = "sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293"}, - {file = "PyYAML-6.0-cp36-cp36m-win_amd64.whl", hash = "sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57"}, - {file = "PyYAML-6.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c"}, - {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0"}, - {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4"}, - {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9"}, - {file = "PyYAML-6.0-cp37-cp37m-win32.whl", hash = "sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737"}, - {file = "PyYAML-6.0-cp37-cp37m-win_amd64.whl", hash = "sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d"}, - {file = "PyYAML-6.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b"}, - {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba"}, - {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34"}, - {file = "PyYAML-6.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287"}, - {file = "PyYAML-6.0-cp38-cp38-win32.whl", hash = "sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78"}, - {file = "PyYAML-6.0-cp38-cp38-win_amd64.whl", hash = "sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07"}, - {file = "PyYAML-6.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b"}, - {file = "PyYAML-6.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174"}, - {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803"}, - {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3"}, - {file = "PyYAML-6.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0"}, - {file = "PyYAML-6.0-cp39-cp39-win32.whl", hash = "sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb"}, - {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, - {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, -] -requests = [ - {file = "requests-2.27.1-py2.py3-none-any.whl", hash = "sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d"}, - {file = "requests-2.27.1.tar.gz", hash = "sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61"}, -] -rfc3986 = [ - {file = "rfc3986-1.5.0-py2.py3-none-any.whl", hash = "sha256:a86d6e1f5b1dc238b218b012df0aa79409667bb209e58da56d0b94704e712a97"}, - {file = "rfc3986-1.5.0.tar.gz", hash = "sha256:270aaf10d87d0d4e095063c65bf3ddbc6ee3d0b226328ce21e036f946e421835"}, -] -six = [ - {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, - {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, -] -sniffio = [ - {file = "sniffio-1.2.0-py3-none-any.whl", hash = "sha256:471b71698eac1c2112a40ce2752bb2f4a4814c22a54a3eed3676bc0f5ca9f663"}, - {file = "sniffio-1.2.0.tar.gz", hash = "sha256:c4666eecec1d3f50960c6bdf61ab7bc350648da6c126e3cf6898d8cd4ddcd3de"}, -] -snowballstemmer = [ - {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, - {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, -] -sphinx = [ - {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, - {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, -] -sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, -] -sphinx-rtd-theme = [ - {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, - {file = "sphinx_rtd_theme-1.0.0.tar.gz", hash = "sha256:eec6d497e4c2195fa0e8b2016b337532b8a699a68bcb22a512870e16925c6a5c"}, -] -sphinxcontrib-apidoc = [ - {file = "sphinxcontrib-apidoc-0.3.0.tar.gz", hash = "sha256:729bf592cf7b7dd57c4c05794f732dc026127275d785c2a5494521fdde773fb9"}, - {file = "sphinxcontrib_apidoc-0.3.0-py2.py3-none-any.whl", hash = "sha256:6671a46b2c6c5b0dca3d8a147849d159065e50443df79614f921b42fbd15cb09"}, -] -sphinxcontrib-applehelp = [ - {file = "sphinxcontrib-applehelp-1.0.2.tar.gz", hash = "sha256:a072735ec80e7675e3f432fcae8610ecf509c5f1869d17e2eecff44389cdbc58"}, - {file = "sphinxcontrib_applehelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:806111e5e962be97c29ec4c1e7fe277bfd19e9652fb1a4392105b43e01af885a"}, -] -sphinxcontrib-devhelp = [ - {file = "sphinxcontrib-devhelp-1.0.2.tar.gz", hash = "sha256:ff7f1afa7b9642e7060379360a67e9c41e8f3121f2ce9164266f61b9f4b338e4"}, - {file = "sphinxcontrib_devhelp-1.0.2-py2.py3-none-any.whl", hash = "sha256:8165223f9a335cc1af7ffe1ed31d2871f325254c0423bc0c4c7cd1c1e4734a2e"}, -] -sphinxcontrib-htmlhelp = [ - {file = "sphinxcontrib-htmlhelp-2.0.0.tar.gz", hash = "sha256:f5f8bb2d0d629f398bf47d0d69c07bc13b65f75a81ad9e2f71a63d4b7a2f6db2"}, - {file = "sphinxcontrib_htmlhelp-2.0.0-py2.py3-none-any.whl", hash = "sha256:d412243dfb797ae3ec2b59eca0e52dac12e75a241bf0e4eb861e450d06c6ed07"}, -] -sphinxcontrib-jsmath = [ - {file = "sphinxcontrib-jsmath-1.0.1.tar.gz", hash = "sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8"}, - {file = "sphinxcontrib_jsmath-1.0.1-py2.py3-none-any.whl", hash = "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178"}, -] -sphinxcontrib-qthelp = [ - {file = "sphinxcontrib-qthelp-1.0.3.tar.gz", hash = "sha256:4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"}, - {file = "sphinxcontrib_qthelp-1.0.3-py2.py3-none-any.whl", hash = "sha256:bd9fc24bcb748a8d51fd4ecaade681350aa63009a347a8c14e637895444dfab6"}, -] -sphinxcontrib-serializinghtml = [ - {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, - {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, -] -toml = [ - {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, - {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, -] -tomli = [ - {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, - {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, -] -typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, -] -urllib3 = [ - {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, - {file = "urllib3-1.26.9.tar.gz", hash = "sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"}, -] -uvloop = [ - {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, - {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, - {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:bd53f7f5db562f37cd64a3af5012df8cac2c464c97e732ed556800129505bd64"}, - {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:772206116b9b57cd625c8a88f2413df2fcfd0b496eb188b82a43bed7af2c2ec9"}, - {file = "uvloop-0.16.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:b572256409f194521a9895aef274cea88731d14732343da3ecdb175228881638"}, - {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:04ff57aa137230d8cc968f03481176041ae789308b4d5079118331ab01112450"}, - {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3a19828c4f15687675ea912cc28bbcb48e9bb907c801873bd1519b96b04fb805"}, - {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e814ac2c6f9daf4c36eb8e85266859f42174a4ff0d71b99405ed559257750382"}, - {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:bd8f42ea1ea8f4e84d265769089964ddda95eb2bb38b5cbe26712b0616c3edee"}, - {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:647e481940379eebd314c00440314c81ea547aa636056f554d491e40503c8464"}, - {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e0d26fa5875d43ddbb0d9d79a447d2ace4180d9e3239788208527c4784f7cab"}, - {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:6ccd57ae8db17d677e9e06192e9c9ec4bd2066b77790f9aa7dede2cc4008ee8f"}, - {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:089b4834fd299d82d83a25e3335372f12117a7d38525217c2258e9b9f4578897"}, - {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98d117332cc9e5ea8dfdc2b28b0a23f60370d02e1395f88f40d1effd2cb86c4f"}, - {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, - {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, -] -virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, -] -zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, -] From 15bd27583a2b94dde02252b2dde0213d7bf4e841 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 1 Apr 2022 14:39:01 +0200 Subject: [PATCH 059/324] ISSUE #144 --- .github/workflows/minos-discovery-kong-tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index df2aba730..ddcef015c 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -21,7 +21,7 @@ jobs: steps: - name: Fire up Docker Compose setup with Kong & do some checks - run: docker-compose -f "tests/docker-compose.yml" up -d --build + run: docker-compose -f "./tests/docker-compose.yml" up -d --build - name: Check out repository code uses: actions/checkout@v2 @@ -53,4 +53,4 @@ jobs: - name: Stop containers if: always() - run: docker-compose -f "tests/docker-compose.yml" down + run: docker-compose -f "./tests/docker-compose.yml" down From 29062726996db884ca1a9f7e0b46ea6a3cbbcc52 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 15:38:40 +0200 Subject: [PATCH 060/324] modified action for kong plugin --- .../workflows/minos-discovery-kong-tests.yml | 38 ++++++++++++++++++- 1 file changed, 36 insertions(+), 2 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index df2aba730..5c00307ac 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -15,13 +15,47 @@ jobs: build: runs-on: ubuntu-latest container: python:3.9-buster + services: + postgres: + image: postgres:9.5 + env: + POSTGRES_DB: kong + POSTGRES_USER: kong + POSTGRES_PASSWORD: kong + ports: + # Maps tcp port 5432 on service container to the host + - 5432:5432 defaults: run: working-directory: packages/plugins/minos-discovery-kong steps: - - name: Fire up Docker Compose setup with Kong & do some checks - run: docker-compose -f "tests/docker-compose.yml" up -d --build + - name: Download Kong dependencies pre-install + run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-ubuntu-$(lsb_release -sc)/ default all" | sudo tee /etc/apt/sources.list.d/kong.list + + - name: Install dependencies and install Kong + run: sudo apt-get update && apt install kong-enterprise-edition=2.8.0.0 + + - name: Set env variables + run: | + echo "KONG_DATABASE=postgres" >> $GITHUB_ENV + echo "KONG_PG_DATABASE=kong" >> $GITHUB_ENV + echo "KONG_PG_HOST=postgres" >> $GITHUB_ENV + echo "KONG_PG_USER=kong" >> $GITHUB_ENV + echo "KONG_PG_PASSWORD=kong" >> $GITHUB_ENV + echo "KONG_ADMIN_ACCESS_LOG=/dev/stdout" >> $GITHUB_ENV + echo "KONG_ADMIN_ERROR_LOG=/dev/stderr" >> $GITHUB_ENV + echo "KONG_PROXY_LISTEN=0.0.0.0:8000" >> $GITHUB_ENV + echo "KONG_ADMIN_LISTEN=0.0.0.0:8001" >> $GITHUB_ENV + echo "KONG_PROXY_ACCESS_LOG=/dev/stdout" >> $GITHUB_ENV + echo "KONG_PROXY_ERROR_LOG=/dev/stderr" >> $GITHUB_ENV + echo "KONG_LOG_LEVEL=debug" >> $GITHUB_ENV + + - name: Kong Migration + run: kong migrations bootstrap && kong migrations up && kong migrations finish + + - name: Kong Start + run: kong start - name: Check out repository code uses: actions/checkout@v2 From 8e6665e7b31947e5a82bf423ecdaac10a81bbd3c Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 15:43:58 +0200 Subject: [PATCH 061/324] update the way to install kong package --- .github/workflows/minos-discovery-kong-tests.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 5ee0c851e..fab62a069 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -31,10 +31,10 @@ jobs: steps: - name: Download Kong dependencies pre-install - run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-ubuntu-$(lsb_release -sc)/ default all" | sudo tee /etc/apt/sources.list.d/kong.list + run: curl -Lo kong-enterprise-edition-2.8.0.0.all.deb "https://download.konghq.com/gateway-2.x-ubuntu-$(lsb_release -cs)/pool/all/k/kong-enterprise-edition/kong_2.8.0.0_all.deb" - - name: Install dependencies and install Kong - run: sudo apt-get update && apt install kong-enterprise-edition=2.8.0.0 + - name: Install Kong package + run: sudo dpkg -i kong-enterprise-edition-2.8.0.0.all.deb - name: Set env variables run: | From ac99b825906836a83fb42daad7af314eeb71c181 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 15:59:29 +0200 Subject: [PATCH 062/324] still working on actions for kong plugin modified the container --- .../workflows/minos-discovery-kong-tests.yml | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index fab62a069..9132743d3 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -14,7 +14,7 @@ on: jobs: build: runs-on: ubuntu-latest - container: python:3.9-buster + container: ubuntu-latest services: postgres: image: postgres:9.5 @@ -30,11 +30,14 @@ jobs: working-directory: packages/plugins/minos-discovery-kong steps: - - name: Download Kong dependencies pre-install - run: curl -Lo kong-enterprise-edition-2.8.0.0.all.deb "https://download.konghq.com/gateway-2.x-ubuntu-$(lsb_release -cs)/pool/all/k/kong-enterprise-edition/kong_2.8.0.0_all.deb" + - name: Install Python 3.9 + run: sudo apt install software-properties-common && sudo add-apt-repository ppa:deadsnakes/ppa && sudo apt install python3.9 - - name: Install Kong package - run: sudo dpkg -i kong-enterprise-edition-2.8.0.0.all.deb + - name: Prepare APT for kong installation + run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-ubuntu-$(lsb_release -sc)/ default all" | sudo tee /etc/apt/sources.list.d/kong.list + + - name: Install kong + run: sudo apt-get update && apt install -y kong-enterprise-edition=2.8.0.0 - name: Set env variables run: | @@ -84,7 +87,3 @@ jobs: - name: Generate build run: make dist - - - name: Stop containers - if: always() - run: docker-compose -f "./tests/docker-compose.yml" down From eed9ff07f01b8af65d7ca7f7427cbfe6a6782e45 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 16:01:18 +0200 Subject: [PATCH 063/324] modified the container name --- .github/workflows/minos-discovery-kong-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 9132743d3..361f50f23 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -14,7 +14,7 @@ on: jobs: build: runs-on: ubuntu-latest - container: ubuntu-latest + container: ubuntu:latest services: postgres: image: postgres:9.5 From e812a83014006a2f8cd3cae7b8f8cad85fe81665 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 1 Apr 2022 16:05:58 +0200 Subject: [PATCH 064/324] ISSUE #144 --- .../minos-discovery-kong/tests/test_kong/test_client.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 9107cddb5..fa6cb2c42 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -5,6 +5,8 @@ import httpx +import os + from minos.plugins.kong import ( KongDiscoveryClient, ) @@ -13,8 +15,11 @@ class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): + KONG_HOST = os.getenv('KONG_HOST', "localhost") + KONG_PORT = os.getenv('KONG_PORT', 8001) + def setUp(self) -> None: - self.client = KongDiscoveryClient("localhost", 8001, circuit_breaker_time=0.1) + self.client = KongDiscoveryClient(self.KONG_HOST, self.KONG_PORT, circuit_breaker_time=0.1) @staticmethod def generate_underscore_uuid(): From f00fd2527ac7ffb462bf1bb4ae5255afd797e99d Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 1 Apr 2022 16:10:08 +0200 Subject: [PATCH 065/324] ISSUE #144 --- .../plugins/minos-discovery-kong/tests/test_kong/test_client.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index fa6cb2c42..168251634 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -33,7 +33,7 @@ def test_constructor(self): def test_route(self): # noinspection HttpUrlsUsage - self.assertEqual(f"{PROTOCOL}://localhost:8001", self.client.route) + self.assertEqual(f"{PROTOCOL}://{self.client.host}:{self.client.port}", self.client.route) async def test_subscribe(self): name = self.generate_underscore_uuid() From 4d93c54865c7e03e5b3e611d52a2c9d9e546da7a Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 16:24:13 +0200 Subject: [PATCH 066/324] modified tu buster python the container image --- .github/workflows/minos-discovery-kong-tests.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 361f50f23..5f34893bb 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -14,7 +14,7 @@ on: jobs: build: runs-on: ubuntu-latest - container: ubuntu:latest + container: python:3.9-buster services: postgres: image: postgres:9.5 @@ -30,11 +30,8 @@ jobs: working-directory: packages/plugins/minos-discovery-kong steps: - - name: Install Python 3.9 - run: sudo apt install software-properties-common && sudo add-apt-repository ppa:deadsnakes/ppa && sudo apt install python3.9 - - name: Prepare APT for kong installation - run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-ubuntu-$(lsb_release -sc)/ default all" | sudo tee /etc/apt/sources.list.d/kong.list + run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-ubuntu-$(lsb_release -sc)/ default all" | tee /etc/apt/sources.list.d/kong.list - name: Install kong run: sudo apt-get update && apt install -y kong-enterprise-edition=2.8.0.0 From 33e0da64f744dea483b24c0474cf2272995a4d39 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 16:28:33 +0200 Subject: [PATCH 067/324] still working on th action --- .github/workflows/minos-discovery-kong-tests.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 5f34893bb..c1adbd567 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -30,8 +30,11 @@ jobs: working-directory: packages/plugins/minos-discovery-kong steps: - - name: Prepare APT for kong installation - run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-ubuntu-$(lsb_release -sc)/ default all" | tee /etc/apt/sources.list.d/kong.list + - name: Install dependencies + run: apt install curl lsb-release apt-transport-https + + - name: Update apt list + run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-debian-$(lsb_release -sc)/ default all" | sudo tee /etc/apt/sources.list.d/kong.list - name: Install kong run: sudo apt-get update && apt install -y kong-enterprise-edition=2.8.0.0 From f6444eaff20c90c5bd5d7c805ab8558fc4cd58bd Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 16:29:52 +0200 Subject: [PATCH 068/324] still the same --- .github/workflows/minos-discovery-kong-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index c1adbd567..738a6db66 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -31,7 +31,7 @@ jobs: steps: - name: Install dependencies - run: apt install curl lsb-release apt-transport-https + run: sudo apt-get install -y curl lsb-release apt-transport-https - name: Update apt list run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-debian-$(lsb_release -sc)/ default all" | sudo tee /etc/apt/sources.list.d/kong.list From 499b1d161d413e8610451b9778146dde0d2a83c7 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 16:48:28 +0200 Subject: [PATCH 069/324] removed container --- .github/workflows/minos-discovery-kong-tests.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 738a6db66..c2096d5f0 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -14,7 +14,6 @@ on: jobs: build: runs-on: ubuntu-latest - container: python:3.9-buster services: postgres: image: postgres:9.5 @@ -31,7 +30,7 @@ jobs: steps: - name: Install dependencies - run: sudo apt-get install -y curl lsb-release apt-transport-https + run: sudo apt install -y curl lsb-release apt-transport-https - name: Update apt list run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-debian-$(lsb_release -sc)/ default all" | sudo tee /etc/apt/sources.list.d/kong.list From d24c3e31a39731b8190b6407ad7d3912834f8c4f Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 16:50:58 +0200 Subject: [PATCH 070/324] intent to start the working apt --- .github/workflows/minos-discovery-kong-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index c2096d5f0..d8fb15fd9 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -30,7 +30,7 @@ jobs: steps: - name: Install dependencies - run: sudo apt install -y curl lsb-release apt-transport-https + run: sudo apt install curl lsb-release apt-transport-https - name: Update apt list run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-debian-$(lsb_release -sc)/ default all" | sudo tee /etc/apt/sources.list.d/kong.list From 42401cce30a1335d84650d63147425eb18e19eac Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 16:57:52 +0200 Subject: [PATCH 071/324] moved checkout --- .github/workflows/minos-discovery-kong-tests.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index d8fb15fd9..4875ca14f 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -29,6 +29,9 @@ jobs: working-directory: packages/plugins/minos-discovery-kong steps: + - name: Check out repository code + uses: actions/checkout@v2 + - name: Install dependencies run: sudo apt install curl lsb-release apt-transport-https @@ -59,9 +62,6 @@ jobs: - name: Kong Start run: kong start - - name: Check out repository code - uses: actions/checkout@v2 - - name: Install Poetry uses: snok/install-poetry@v1 From 4ce5c151844b8c75db634b1be9be1d4ab35d1b0e Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 17:01:47 +0200 Subject: [PATCH 072/324] reintro of container --- .github/workflows/minos-discovery-kong-tests.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 4875ca14f..57e407b35 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -14,6 +14,7 @@ on: jobs: build: runs-on: ubuntu-latest + container: python:3.9-buster services: postgres: image: postgres:9.5 From 7404cbd604a47ff9f5b4b3ea2ea48ecfed114952 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 17:04:14 +0200 Subject: [PATCH 073/324] removed sudo --- .github/workflows/minos-discovery-kong-tests.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 57e407b35..96712b50a 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -34,13 +34,13 @@ jobs: uses: actions/checkout@v2 - name: Install dependencies - run: sudo apt install curl lsb-release apt-transport-https + run: apt install -y curl lsb-release apt-transport-https - name: Update apt list - run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-debian-$(lsb_release -sc)/ default all" | sudo tee /etc/apt/sources.list.d/kong.list + run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-debian-$(lsb_release -sc)/ default all" | tee /etc/apt/sources.list.d/kong.list - name: Install kong - run: sudo apt-get update && apt install -y kong-enterprise-edition=2.8.0.0 + run: apt-get update && apt install -y kong-enterprise-edition=2.8.0.0 - name: Set env variables run: | From abb3b731f301dad8aa89dcfb8871a833afd28d8f Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 17:08:36 +0200 Subject: [PATCH 074/324] removed lsb-release --- .github/workflows/minos-discovery-kong-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 96712b50a..dce1e7ba9 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -34,7 +34,7 @@ jobs: uses: actions/checkout@v2 - name: Install dependencies - run: apt install -y curl lsb-release apt-transport-https + run: apt install -y curl apt-transport-https - name: Update apt list run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-debian-$(lsb_release -sc)/ default all" | tee /etc/apt/sources.list.d/kong.list From 586b0100ce5f9279d4a5186275f904ab987f2663 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 17:14:04 +0200 Subject: [PATCH 075/324] added buster --- .github/workflows/minos-discovery-kong-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index dce1e7ba9..5c87922ef 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -37,7 +37,7 @@ jobs: run: apt install -y curl apt-transport-https - name: Update apt list - run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-debian-$(lsb_release -sc)/ default all" | tee /etc/apt/sources.list.d/kong.list + run: echo "deb [trusted=yes] https://download.konghq.com/gateway-2.x-debian-buster/ default all" | tee /etc/apt/sources.list.d/kong.list - name: Install kong run: apt-get update && apt install -y kong-enterprise-edition=2.8.0.0 From 08e7663f01ee8e1bb166b64a9991b1170719b136 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 17:22:38 +0200 Subject: [PATCH 076/324] removed doc generation --- .github/workflows/minos-discovery-kong-tests.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/minos-discovery-kong-tests.yml b/.github/workflows/minos-discovery-kong-tests.yml index 5c87922ef..241ae75cb 100644 --- a/.github/workflows/minos-discovery-kong-tests.yml +++ b/.github/workflows/minos-discovery-kong-tests.yml @@ -82,8 +82,5 @@ jobs: files: ./packages/plugins/minos-discovery-kong/coverage.xml fail_ci_if_error: true - - name: Generate documentation - run: make docs - - name: Generate build run: make dist From e275b48279bc0d36f0d4b1a8420be0c67284d7b6 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Fri, 1 Apr 2022 15:22:51 +0000 Subject: [PATCH 077/324] Restyled by black --- .../minos-discovery-kong/tests/test_kong/test_client.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 168251634..e788bf9a6 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -15,8 +15,8 @@ class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): - KONG_HOST = os.getenv('KONG_HOST', "localhost") - KONG_PORT = os.getenv('KONG_PORT', 8001) + KONG_HOST = os.getenv("KONG_HOST", "localhost") + KONG_PORT = os.getenv("KONG_PORT", 8001) def setUp(self) -> None: self.client = KongDiscoveryClient(self.KONG_HOST, self.KONG_PORT, circuit_breaker_time=0.1) From 52a450d0c6a72a76275c818940cc889a6901a4c7 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Fri, 1 Apr 2022 15:22:53 +0000 Subject: [PATCH 078/324] Restyled by isort --- .../minos-discovery-kong/tests/test_kong/test_client.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index e788bf9a6..4b739142c 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -1,3 +1,4 @@ +import os import unittest from uuid import ( uuid4, @@ -5,8 +6,6 @@ import httpx -import os - from minos.plugins.kong import ( KongDiscoveryClient, ) From 59725029d8228542affd894b79860bc6a99091db Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 18:00:48 +0200 Subject: [PATCH 079/324] added more coverage --- .../tests/test_kong/test_client.py | 3 ++- .../tests/test_kong/test_utils.py | 18 ++++++++++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 4b739142c..0b8499416 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -37,7 +37,8 @@ def test_route(self): async def test_subscribe(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", 5660, name, [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] + "172.160.16.24", 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, + {"url": "/bar", "method": "GET"}] ) self.assertTrue(201 == response.status_code) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py new file mode 100644 index 000000000..42a77facb --- /dev/null +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py @@ -0,0 +1,18 @@ +import unittest + +from minos.plugins.kong.utils import Endpoint, PathPart + + +class TestKongDiscoveryUtils(unittest.IsolatedAsyncioTestCase): + + def test_endpoint_constructor(self) -> None: + endopoint = Endpoint("minos/plugin") + self.assertIsInstance(endopoint, Endpoint) + self.assertEqual(endopoint.path_as_str, "minos/plugin") + self.assertEqual(endopoint.path[0].name, 'minos') + + def test_path_constructor(self) -> None: + pathpart = PathPart("minos") + self.assertIsInstance(pathpart, PathPart) + self.assertEqual(pathpart.name, "minos") + self.assertEqual(pathpart.is_generic, False) From a371369b1aa2583206d4685106c5be0f0c56bf8e Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 18:05:16 +0200 Subject: [PATCH 080/324] improved coverage --- .../tests/test_kong/test_client.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 0b8499416..0042caea0 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -34,6 +34,21 @@ def test_route(self): # noinspection HttpUrlsUsage self.assertEqual(f"{PROTOCOL}://{self.client.host}:{self.client.port}", self.client.route) + async def test_already_exist_subscribe(self): + name = self.generate_underscore_uuid() + + response = await self.client.subscribe( + "172.160.16.24", 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, + {"url": "/bar", "method": "GET"}] + ) + self.assertTrue(201 == response.status_code) + + response = await self.client.subscribe( + "172.160.16.24", 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, + {"url": "/bar", "method": "GET"}] + ) + self.assertTrue(201 == response.status_code) + async def test_subscribe(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( From b63a5f6656f3f1003fb974ff086e501f66ca9b55 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Fri, 1 Apr 2022 16:05:25 +0000 Subject: [PATCH 081/324] Restyled by black --- .../tests/test_kong/test_client.py | 20 ++++++++++++------- .../tests/test_kong/test_utils.py | 3 +-- 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 0042caea0..dcdbc2a26 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -38,22 +38,28 @@ async def test_already_exist_subscribe(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, - {"url": "/bar", "method": "GET"}] + "172.160.16.24", + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], ) self.assertTrue(201 == response.status_code) response = await self.client.subscribe( - "172.160.16.24", 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, - {"url": "/bar", "method": "GET"}] + "172.160.16.24", + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], ) self.assertTrue(201 == response.status_code) - + async def test_subscribe(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, - {"url": "/bar", "method": "GET"}] + "172.160.16.24", + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], ) self.assertTrue(201 == response.status_code) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py index 42a77facb..3680bc508 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py @@ -4,12 +4,11 @@ class TestKongDiscoveryUtils(unittest.IsolatedAsyncioTestCase): - def test_endpoint_constructor(self) -> None: endopoint = Endpoint("minos/plugin") self.assertIsInstance(endopoint, Endpoint) self.assertEqual(endopoint.path_as_str, "minos/plugin") - self.assertEqual(endopoint.path[0].name, 'minos') + self.assertEqual(endopoint.path[0].name, "minos") def test_path_constructor(self) -> None: pathpart = PathPart("minos") From a20c17cca17609cfc7a0f355f3e130933b9afdd6 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Fri, 1 Apr 2022 16:05:25 +0000 Subject: [PATCH 082/324] Restyled by isort --- .../minos-discovery-kong/tests/test_kong/test_utils.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py index 3680bc508..79dab4025 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py @@ -1,6 +1,9 @@ import unittest -from minos.plugins.kong.utils import Endpoint, PathPart +from minos.plugins.kong.utils import ( + Endpoint, + PathPart, +) class TestKongDiscoveryUtils(unittest.IsolatedAsyncioTestCase): From 5138ef4d9452a3a29fc577d0253eb87479022682 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Fri, 1 Apr 2022 18:37:00 +0200 Subject: [PATCH 083/324] updated the version of minos-discovery-kong --- .../plugins/minos-discovery-kong/minos/plugins/kong/__init__.py | 2 +- packages/plugins/minos-discovery-kong/pyproject.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index a5a7caf7d..63ad749a2 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -1,6 +1,6 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.1.0a6" +__version__ = "0.1.0" from .client import ( KongDiscoveryClient, diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index ddfff730e..2abaf7969 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-kong" -version = "0.1.0a0" +version = "0.1.0" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" From 3b12d0dd8d3cc8fbfdc2a412a004f28986c028da Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Sat, 2 Apr 2022 12:05:52 +0200 Subject: [PATCH 084/324] pre-alpha release --- packages/plugins/minos-discovery-kong/README.md | 2 +- .../minos-discovery-kong/minos/plugins/kong/__init__.py | 2 +- packages/plugins/minos-discovery-kong/pyproject.toml | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/README.md b/packages/plugins/minos-discovery-kong/README.md index a76d57c00..436d42909 100644 --- a/packages/plugins/minos-discovery-kong/README.md +++ b/packages/plugins/minos-discovery-kong/README.md @@ -11,7 +11,7 @@ [![Stack Overflow](https://img.shields.io/badge/Stack%20Overflow-Ask%20a%20question-green)](https://stackoverflow.com/questions/tagged/minos) ## Summary - +Pre-Alpha release, use at your own risk Minos Kong is a plugin that integrate minos micorservices with Kong API Gateway ## Installation diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index 63ad749a2..7cd96f503 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -1,6 +1,6 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.1.0" +__version__ = "0.1.0a1" from .client import ( KongDiscoveryClient, diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index 2abaf7969..f94170c90 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-kong" -version = "0.1.0" +version = "0.1.0a1" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -19,6 +19,7 @@ keywords = [ "minos", "microservice", "saga", + "kong" ] packages = [ { include = "minos" } From 58abaa8a748f43afa0dbed819ed7d9a7f3bcd5a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 09:08:18 +0200 Subject: [PATCH 085/324] ISSUE #346 * Fix bug related with deprecation warning. --- .../minos/common/database/abc.py | 44 ++++++++++++++++++- .../minos/common/database/locks.py | 4 +- .../minos/common/database/pools.py | 13 +++--- 3 files changed, 50 insertions(+), 11 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index ff723f01b..6520de8d8 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -56,6 +56,46 @@ def __init__( self._pool = pool + @property + def database(self) -> str: + """Get the database's database. + + :return: A ``str`` value. + """ + return self.pool.database + + @property + def host(self) -> str: + """Get the database's host. + + :return: A ``str`` value. + """ + return self.pool.host + + @property + def port(self) -> int: + """Get the database's port. + + :return: An ``int`` value. + """ + return self.pool.port + + @property + def user(self) -> str: + """Get the database's user. + + :return: A ``str`` value. + """ + return self.pool.user + + @property + def password(self) -> str: + """Get the database's password. + + :return: A ``str`` value. + """ + return self.pool.password + async def submit_query_and_fetchone(self, *args, **kwargs) -> tuple: """Submit a SQL query and gets the first response. @@ -181,8 +221,8 @@ def pool(self) -> DatabaseClientPool: class PostgreSqlMinosDatabase(DatabaseMixin): """TODO""" - def __new__(cls, *args, **kwargs): + def __init__(self, *args, **kwargs): warnings.warn( f"{PostgreSqlMinosDatabase!r} has been deprecated. Use {DatabaseMixin} instead.", DeprecationWarning ) - return super().__new__(cls, *args, **kwargs) + super().__init__(*args, **kwargs) \ No newline at end of file diff --git a/packages/core/minos-microservice-common/minos/common/database/locks.py b/packages/core/minos-microservice-common/minos/common/database/locks.py index 20ddf528c..09fdfe8ab 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks.py @@ -50,6 +50,6 @@ async def __aexit__(self, exc_type, exc_val, exc_tb): class PostgreSqlLock(DatabaseLock): """TODO""" - def __new__(cls, *args, **kwargs): + def __init__(self, *args, **kwargs): warnings.warn(f"{PostgreSqlLock!r} has been deprecated. Use {DatabaseLock} instead.", DeprecationWarning) - return super().__new__(cls, *args, **kwargs) + super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 95c96cd47..6b8c56121 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -102,9 +102,9 @@ async def _check_instance(self, instance: Optional[Connection]) -> bool: class PostgreSqlPool(DatabaseClientPool): """TODO""" - def __new__(cls, *args, **kwargs): + def __init__(self, *args, **kwargs): warnings.warn(f"{PostgreSqlPool!r} has been deprecated. Use {DatabaseClientPool} instead.", DeprecationWarning) - return super().__new__(cls, *args, **kwargs) + super().__init__(*args, **kwargs) class DatabaseLockPool(LockPool, DatabaseClientPool): @@ -122,8 +122,7 @@ def acquire(self, key: Hashable, *args, **kwargs) -> DatabaseLock: class PostgreSqlLockPool(DatabaseLockPool): """TODO""" - def __new__(cls, *args, **kwargs): - warnings.warn( - f"{PostgreSqlLockPool!r} has been deprecated. Use {DatabaseLockPool} instead.", DeprecationWarning - ) - return super().__new__(cls, *args, **kwargs) + def __init__(self, *args, **kwargs): + warnings.warn(f"{PostgreSqlLockPool!r} has been deprecated. Use {PostgreSqlLockPool} instead.", + DeprecationWarning) + super().__init__(*args, **kwargs) From 022b3ffada87ab85d2bef954cd8f2f16f1582e03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 09:09:22 +0200 Subject: [PATCH 086/324] ISSUE #346 * Parameterize `default_classes`. * Fix tests from `minos-microservice-saga`. --- .../minos/common/pools.py | 20 +++++++++++++++---- .../test_saga/test_executions/test_commit.py | 7 +++++++ .../tests/test_saga/test_manager.py | 4 ++-- .../minos-microservice-saga/tests/utils.py | 13 ++++++------ 4 files changed, 32 insertions(+), 12 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index 21701a871..80762e6f1 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -45,9 +45,13 @@ class PoolFactory(SetupMixin): _pools: dict[str, Pool] - def __init__(self, config: Config, *args, **kwargs): + def __init__(self, config: Config, default_classes: dict[str, type[Pool]] = None, *args, **kwargs): super().__init__(*args, **kwargs) + if default_classes is None: + default_classes = dict() + self._config = config + self._default_classes = default_classes self._pools = dict() @classmethod @@ -75,12 +79,20 @@ def get_pool(self, type_: str, key: Optional[str] = None, **kwargs) -> Pool: def _create_pool(self, type_: str, **kwargs) -> Pool: # noinspection PyTypeChecker - pool_cls: type[Pool] = self._config.get_pools().get(type_) + pool_cls = self._get_pool_class(type_) + pool = pool_cls.from_config(self._config, **kwargs) + return pool + + def _get_pool_class(self, type_: str) -> type[Pool]: + pool_cls = self._default_classes.get(type_) + + if pool_cls is None: + pool_cls = self._config.get_pools().get(type_) + if pool_cls is None: raise ValueError - pool = pool_cls.from_config(self._config, **kwargs) - return pool + return pool_cls class Pool(SetupMixin, PoolBase, Generic[P], ABC): diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py index d11e11ae4..f8e197627 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py @@ -3,6 +3,9 @@ uuid4, ) +from minos.common import ( + NotProvidedException, +) from minos.networks import ( BrokerMessage, BrokerMessageV1, @@ -53,6 +56,10 @@ def setUp(self) -> None: self.committer = TransactionCommitter(self.execution_uuid, self.executed_steps) + def test_constructor_without_broker(self): + with self.assertRaises(NotProvidedException): + TransactionCommitter(self.execution_uuid, self.executed_steps, broker_pool=None, pool_factory=None) + def test_transactions(self): expected = [ (self.execution_uuid, "bar"), diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py index 122f988d8..bb40153de 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py @@ -79,9 +79,9 @@ def test_constructor(self): self.assertIsInstance(self.manager.storage, SagaExecutionStorage) self.assertIsInstance(self.manager, SagaManager) - def test_constructor_without_handler(self): + def test_constructor_without_broker(self): with self.assertRaises(NotProvidedException): - SagaManager.from_config(self.config, broker_pool=None) + SagaManager.from_config(self.config, broker_pool=None, pool_factory=None) async def test_context_manager(self): async with self.manager as saga_manager: diff --git a/packages/core/minos-microservice-saga/tests/utils.py b/packages/core/minos-microservice-saga/tests/utils.py index 1abb6ebb8..4f26a96e3 100644 --- a/packages/core/minos-microservice-saga/tests/utils.py +++ b/packages/core/minos-microservice-saga/tests/utils.py @@ -21,6 +21,7 @@ DependencyInjector, Lock, LockPool, + PoolFactory, SetupMixin, ) from minos.networks import ( @@ -46,15 +47,16 @@ def setUp(self) -> None: self.config = Config(CONFIG_FILE_PATH) - self.broker_pool = BrokerClientPool.from_config(CONFIG_FILE_PATH) + self.pool_factory = PoolFactory.from_config( + CONFIG_FILE_PATH, default_classes={"broker": BrokerClientPool, "lock": FakeLockPool} + ) self.broker_publisher = InMemoryBrokerPublisher() self.broker_subscriber_builder = InMemoryBrokerSubscriberBuilder() - self.lock_pool = FakeLockPool() - self.transaction_repository = InMemoryTransactionRepository(lock_pool=self.lock_pool) + self.transaction_repository = InMemoryTransactionRepository(lock_pool=self.pool_factory.get_pool("lock")) self.event_repository = InMemoryEventRepository( broker_publisher=self.broker_publisher, transaction_repository=self.transaction_repository, - lock_pool=self.lock_pool, + lock_pool=self.pool_factory.get_pool("lock"), ) self.snapshot_repository = InMemorySnapshotRepository( event_repository=self.event_repository, transaction_repository=self.transaction_repository @@ -63,10 +65,9 @@ def setUp(self) -> None: self.injector = DependencyInjector( self.config, [ - self.broker_pool, + self.pool_factory, self.broker_publisher, self.broker_subscriber_builder, - self.lock_pool, self.transaction_repository, self.event_repository, self.snapshot_repository, From d6870f30f70a82e61c6f3cb254105ba97dbc3540 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 09:15:32 +0200 Subject: [PATCH 087/324] ISSUE #346 * Reformat code. --- .../minos-microservice-common/minos/common/database/abc.py | 2 +- .../minos-microservice-common/minos/common/database/pools.py | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 6520de8d8..358bbdf75 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -225,4 +225,4 @@ def __init__(self, *args, **kwargs): warnings.warn( f"{PostgreSqlMinosDatabase!r} has been deprecated. Use {DatabaseMixin} instead.", DeprecationWarning ) - super().__init__(*args, **kwargs) \ No newline at end of file + super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 6b8c56121..ef2ca0efc 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -123,6 +123,7 @@ class PostgreSqlLockPool(DatabaseLockPool): """TODO""" def __init__(self, *args, **kwargs): - warnings.warn(f"{PostgreSqlLockPool!r} has been deprecated. Use {PostgreSqlLockPool} instead.", - DeprecationWarning) + warnings.warn( + f"{PostgreSqlLockPool!r} has been deprecated. Use {PostgreSqlLockPool} instead.", DeprecationWarning + ) super().__init__(*args, **kwargs) From 8769cb74c52c5761841d536d07bf94602202b3bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 09:21:36 +0200 Subject: [PATCH 088/324] ISSUE #346 * Fix broken tests from `minos-broker-kafka`. --- .../tests/test_kafka/test_publisher.py | 15 ++++++++++++++- .../tests/test_kafka/test_subscriber.py | 18 ++++++++++++++++-- 2 files changed, 30 insertions(+), 3 deletions(-) diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py index c734086da..485843d6c 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py @@ -13,6 +13,7 @@ from minos.common import ( Config, + DatabaseClientPool, ) from minos.networks import ( BrokerMessage, @@ -152,10 +153,22 @@ def test_build(self): class TestPostgreSqlQueuedKafkaBrokerPublisher(unittest.IsolatedAsyncioTestCase): + def setUp(self) -> None: + super().setUp() + self.database_pool = DatabaseClientPool.from_config(CONFIG_FILE_PATH) + + async def asyncSetUp(self) -> None: + await super().asyncSetUp() + await self.database_pool.setup() + + async def asyncTearDown(self) -> None: + await self.database_pool.destroy() + await super().asyncTearDown() + def test_from_config(self): with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) - publisher = PostgreSqlQueuedKafkaBrokerPublisher.from_config(CONFIG_FILE_PATH) + publisher = PostgreSqlQueuedKafkaBrokerPublisher.from_config(CONFIG_FILE_PATH, pool=self.database_pool) self.assertIsInstance(publisher, PostgreSqlQueuedKafkaBrokerPublisher) self.assertIsInstance(publisher.impl, KafkaBrokerPublisher) self.assertIsInstance(publisher.queue, PostgreSqlBrokerPublisherQueue) diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py index edf432502..d59e8c553 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py @@ -21,6 +21,7 @@ from minos.common import ( Config, + DatabaseClientPool, ) from minos.networks import ( BrokerMessageV1, @@ -250,15 +251,28 @@ def test_build(self): self.assertEqual(common_config["port"], subscriber.port) -class TestPostgreSqlQueuedKafkaBrokerSubscriberBuilder(unittest.TestCase): +class TestPostgreSqlQueuedKafkaBrokerSubscriberBuilder(unittest.IsolatedAsyncioTestCase): def setUp(self) -> None: + super().setUp() self.config = Config(CONFIG_FILE_PATH) + self.database_pool = DatabaseClientPool.from_config(CONFIG_FILE_PATH) + + async def asyncSetUp(self) -> None: + await super().asyncSetUp() + await self.database_pool.setup() + + async def asyncTearDown(self) -> None: + await self.database_pool.destroy() + await super().asyncTearDown() def test_build(self): with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) builder = ( - PostgreSqlQueuedKafkaBrokerSubscriberBuilder().with_config(self.config).with_topics({"one", "two"}) + PostgreSqlQueuedKafkaBrokerSubscriberBuilder() + .with_config(self.config) + .with_topics({"one", "two"}) + .with_kwargs({"pool": self.database_pool}) ) subscriber = builder.build() From 7045fd27326bd742ecb5641bbf64205cde561652 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 09:26:46 +0200 Subject: [PATCH 089/324] ISSUE #346 * Fix broken tests from `minos-microservice-cqrs`. --- .../tests/test_cqrs/test_services.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py b/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py index f96a207f8..bb3448cfc 100644 --- a/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py +++ b/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py @@ -9,6 +9,7 @@ from minos.common import ( DatabaseLockPool, DependencyInjector, + PoolFactory, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -18,7 +19,6 @@ Service, ) from minos.networks import ( - BrokerClientPool, BrokerCommandEnrouteDecorator, BrokerQueryEnrouteDecorator, InMemoryRequest, @@ -40,7 +40,7 @@ def setUp(self) -> None: self.lock_pool = DatabaseLockPool.from_config(self.config) - self.injector = DependencyInjector(self.config, [BrokerClientPool]) + self.injector = DependencyInjector(self.config, [PoolFactory]) self.injector.wire_injections(modules=[sys.modules[__name__]]) self.service = FakeService(config=self.config, lock_pool=self.lock_pool) @@ -51,7 +51,7 @@ def tearDown(self) -> None: async def test_constructor(self): self.assertEqual(self.config, self.service.config) self.assertEqual(self.lock_pool, self.service.lock_pool) - self.assertEqual(self.injector.broker_pool, self.service.broker_pool) + self.assertEqual(self.injector.pool_factory, self.service.pool_factory) with self.assertRaises(AttributeError): self.service.event_repository From ba8feb4d288da4563978503decf1c67cf5e0f419 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 10:34:00 +0200 Subject: [PATCH 090/324] ISSUE #346 * Fix broken tests from `minos-microservice-aggregate`. --- .../aggregate/entities/refs/resolvers.py | 4 +-- .../test_entities/test_refs/test_resolvers.py | 6 +++++ .../test_events/test_repositories/test_abc.py | 8 +++--- .../test_events/test_repositories/test_pg.py | 14 +++++----- .../test_snapshots/test_pg/test_abc.py | 3 ++- .../test_repositories/test_abc.py | 6 ++--- .../test_repositories/test_pg.py | 12 ++++----- .../tests/utils.py | 26 ++++++++++++++----- .../minos/common/config/v1.py | 10 ++++--- .../minos/common/database/abc.py | 4 +-- 10 files changed, 57 insertions(+), 36 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/resolvers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/resolvers.py index dd41fcc58..cdfb86b7f 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/resolvers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/resolvers.py @@ -57,8 +57,8 @@ def __init__( if broker_pool is None and pool_factory is not None: broker_pool = pool_factory.get_pool("broker") - if broker_pool is None: - raise NotProvidedException(f"A {BrokerClientPool!r} instance is required.") + if not isinstance(broker_pool, BrokerClientPool): + raise NotProvidedException(f"A {BrokerClientPool!r} instance is required. Obtained: {broker_pool}") self.broker_pool = broker_pool diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_resolvers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_resolvers.py index 52a173dad..a64bf7666 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_resolvers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_resolvers.py @@ -11,6 +11,7 @@ ) from minos.common import ( ModelType, + NotProvidedException, ) from minos.networks import ( BrokerMessageV1, @@ -34,6 +35,11 @@ def setUp(self) -> None: self.another_uuid = uuid4() self.value = Foo(self.uuid, 1, another=Ref(self.another_uuid)) + def test_broker_pool_not_provided(self): + with self.assertRaises(NotProvidedException): + # noinspection PyArgumentEqualDefault + RefResolver(broker_pool=None, pool_factory=None) + async def test_resolve(self): self.broker_subscriber_builder.with_messages( [BrokerMessageV1("", BrokerMessageV1Payload([Bar(self.value.another.uuid, 1)]))] diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py index acc80f29c..e613b38b4 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py @@ -78,7 +78,7 @@ def test_constructor(self): repository = _EventRepository() self.assertEqual(self.broker_publisher, repository._broker_publisher) self.assertEqual(self.transaction_repository, repository._transaction_repository) - self.assertEqual(self.lock_pool, repository._lock_pool) + self.assertEqual(self.pool_factory.get_pool("lock"), repository._lock_pool) async def test_constructor_raises(self): with self.assertRaises(NotProvidedException): @@ -88,8 +88,8 @@ async def test_constructor_raises(self): # noinspection PyTypeChecker _EventRepository(transaction_repository=None) with self.assertRaises(NotProvidedException): - # noinspection PyTypeChecker - _EventRepository(lock_pool=None) + # noinspection PyArgumentEqualDefault + _EventRepository(lock_pool=None, pool_factory=None) def test_transaction(self): uuid = uuid4() @@ -455,7 +455,7 @@ def test_write_lock(self): expected = FakeLock() mock = MagicMock(return_value=expected) - self.lock_pool.acquire = mock + self.pool_factory.get_pool("lock").acquire = mock self.assertEqual(expected, self.event_repository.write_lock()) self.assertEqual([call("aggregate_event_write_lock")], mock.call_args_list) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index bb04300c0..bbd643149 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -6,6 +6,9 @@ EventRepository, PostgreSqlEventRepository, ) +from minos.common import ( + DatabaseClientPool, +) from minos.common.testing import ( PostgresAsyncTestCase, ) @@ -44,13 +47,10 @@ def build_event_repository(self) -> EventRepository: return PostgreSqlEventRepository(**self.repository_db) def test_constructor(self): - repository = PostgreSqlEventRepository("database", "host", 1234, "user", "password") - self.assertIsInstance(repository, EventRepository) - self.assertEqual("host", repository.host) - self.assertEqual(1234, repository.port) - self.assertEqual("database", repository.database) - self.assertEqual("user", repository.user) - self.assertEqual("password", repository.password) + pool = DatabaseClientPool.from_config(self.config) + repository = PostgreSqlEventRepository(pool) + self.assertIsInstance(repository, PostgreSqlEventRepository) + self.assertEqual(pool, repository.pool) def test_from_config(self): repository = PostgreSqlEventRepository.from_config(self.config) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py index 68f30c705..3f5733f7a 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py @@ -10,10 +10,11 @@ ) from tests.utils import ( CONFIG_FILE_PATH, + MinosTestCase, ) -class TestPostgreSqlSnapshotSetup(PostgresAsyncTestCase): +class TestPostgreSqlSnapshotSetup(MinosTestCase, PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH async def test_setup_snapshot_table(self): diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py index 84d473cd9..562a54baa 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py @@ -48,8 +48,8 @@ def setUp(self) -> None: async def test_constructor_raises(self): with self.assertRaises(NotProvidedException): - # noinspection PyTypeChecker - _TransactionRepository(lock_pool=None) + # noinspection PyArgumentEqualDefault + _TransactionRepository(lock_pool=None, pool_factory=None) def test_abstract(self): self.assertTrue(issubclass(TransactionRepository, (ABC, SetupMixin))) @@ -69,7 +69,7 @@ def test_write_lock(self): expected = FakeLock() mock = MagicMock(return_value=expected) - self.lock_pool.acquire = mock + self.pool_factory.get_pool("lock").acquire = mock self.assertEqual(expected, self.transaction_repository.write_lock()) self.assertEqual(1, mock.call_count) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index 2bcace111..af269810d 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -12,6 +12,9 @@ TransactionRepositoryConflictException, TransactionStatus, ) +from minos.common import ( + DatabaseClientPool, +) from minos.common.testing import ( PostgresAsyncTestCase, ) @@ -43,13 +46,10 @@ async def test_subclass(self) -> None: self.assertTrue(issubclass(PostgreSqlTransactionRepository, TransactionRepository)) def test_constructor(self): - repository = PostgreSqlTransactionRepository("database", "host", 1234, "user", "password") + pool = DatabaseClientPool.from_config(self.config) + repository = PostgreSqlTransactionRepository(pool) self.assertIsInstance(repository, PostgreSqlTransactionRepository) - self.assertEqual("host", repository.host) - self.assertEqual(1234, repository.port) - self.assertEqual("database", repository.database) - self.assertEqual("user", repository.user) - self.assertEqual("password", repository.password) + self.assertEqual(pool, repository.pool) def test_from_config(self): repository = PostgreSqlTransactionRepository.from_config(self.config) diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 1e327c4f8..57697a0fc 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -30,9 +30,12 @@ ValueObjectSet, ) from minos.common import ( + Config, + DatabaseClientPool, DependencyInjector, Lock, LockPool, + PoolFactory, ) from minos.networks import ( BrokerClientPool, @@ -47,27 +50,32 @@ class MinosTestCase(unittest.IsolatedAsyncioTestCase, ABC): def setUp(self) -> None: super().setUp() - self.broker_pool = BrokerClientPool.from_config(CONFIG_FILE_PATH) + + if not hasattr(self, "config"): + self.config = self.get_config() + + self.pool_factory = PoolFactory.from_config( + self.config, + default_classes={"broker": BrokerClientPool, "lock": FakeLockPool, "database": DatabaseClientPool}, + ) self.broker_publisher = InMemoryBrokerPublisher() self.broker_subscriber_builder = InMemoryBrokerSubscriberBuilder() - self.lock_pool = FakeLockPool() - self.transaction_repository = InMemoryTransactionRepository(lock_pool=self.lock_pool) + self.transaction_repository = InMemoryTransactionRepository(lock_pool=self.pool_factory.get_pool("lock")) self.event_repository = InMemoryEventRepository( broker_publisher=self.broker_publisher, transaction_repository=self.transaction_repository, - lock_pool=self.lock_pool, + lock_pool=self.pool_factory.get_pool("lock"), ) self.snapshot_repository = InMemorySnapshotRepository( event_repository=self.event_repository, transaction_repository=self.transaction_repository ) self.injector = DependencyInjector( - None, + self.config, [ - self.broker_pool, + self.pool_factory, self.broker_publisher, self.broker_subscriber_builder, - self.lock_pool, self.transaction_repository, self.event_repository, self.snapshot_repository, @@ -75,6 +83,10 @@ def setUp(self) -> None: ) self.injector.wire_injections() + def get_config(self): + """ "TODO""" + return Config(CONFIG_FILE_PATH) + async def asyncSetUp(self): await super().asyncSetUp() diff --git a/packages/core/minos-microservice-common/minos/common/config/v1.py b/packages/core/minos-microservice-common/minos/common/config/v1.py index 2032dc713..7c65bb687 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v1.py +++ b/packages/core/minos-microservice-common/minos/common/config/v1.py @@ -233,10 +233,12 @@ def _get_services(self) -> list[type]: def _get_pools(self) -> dict[str, type]: try: pools = self.get_by_key("service.injections") - if isinstance(pools, dict): - pools = list(pools.values()) - except Exception as exc: - raise MinosConfigException(f"The 'broker' interface is not available: {exc!r}") + except Exception: + pools = list() + + if isinstance(pools, dict): + pools = list(pools.values()) + old = [import_module(classname) for classname in pools] from ..pools import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 358bbdf75..219f3ba26 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -51,8 +51,8 @@ def __init__( if pool is None and pool_factory is not None: pool = pool_factory.get_pool("database") - if pool is None: - raise NotProvidedException(f"A {DatabaseClientPool!r} instance is required.") + if not isinstance(pool, DatabaseClientPool): + raise NotProvidedException(f"A {DatabaseClientPool!r} instance is required. Obtained: {pool}") self._pool = pool From 640b0ce9627f3eff4341aee2bd11cc045bc9ebe7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 11:14:54 +0200 Subject: [PATCH 091/324] ISSUE #346 * Fix broken tests from `minos-microservice-networks`. --- .../test_events/test_repositories/test_pg.py | 43 +----------- .../tests/utils.py | 70 ++++++------------- .../minos/common/testing.py | 61 +++++++++++++++- .../test_collections/test_queues/test_pg.py | 4 +- .../test_queued/test_queues/test_pg.py | 8 +-- 5 files changed, 88 insertions(+), 98 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index bbd643149..a920f832c 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -16,32 +16,11 @@ EventRepositorySelectTestCase, EventRepositorySubmitTestCase, ) -from tests.utils import ( - CONFIG_FILE_PATH, -) -class TestPostgreSqlEventRepositorySubmit(PostgresAsyncTestCase, EventRepositorySubmitTestCase): +class TestPostgreSqlEventRepositorySubmit(EventRepositorySubmitTestCase, PostgresAsyncTestCase): __test__ = True - CONFIG_FILE_PATH = CONFIG_FILE_PATH - - def setUp(self) -> None: - PostgresAsyncTestCase.setUp(self) - EventRepositorySubmitTestCase.setUp(self) - - async def asyncSetUp(self): - await PostgresAsyncTestCase.asyncSetUp(self) - await EventRepositorySubmitTestCase.asyncSetUp(self) - - def tearDown(self): - EventRepositorySubmitTestCase.tearDown(self) - PostgresAsyncTestCase.tearDown(self) - - async def asyncTearDown(self): - await EventRepositorySelectTestCase.asyncTearDown(self) - await PostgresAsyncTestCase.asyncTearDown(self) - def build_event_repository(self) -> EventRepository: """Fort testing purposes.""" return PostgreSqlEventRepository(**self.repository_db) @@ -71,27 +50,9 @@ async def test_setup(self): self.assertTrue(response) -class TestPostgreSqlRepositorySelect(PostgresAsyncTestCase, EventRepositorySelectTestCase): +class TestPostgreSqlRepositorySelect(EventRepositorySelectTestCase, PostgresAsyncTestCase): __test__ = True - CONFIG_FILE_PATH = CONFIG_FILE_PATH - - def setUp(self) -> None: - PostgresAsyncTestCase.setUp(self) - EventRepositorySelectTestCase.setUp(self) - - async def asyncSetUp(self): - await PostgresAsyncTestCase.asyncSetUp(self) - await EventRepositorySelectTestCase.asyncSetUp(self) - - def tearDown(self): - EventRepositorySelectTestCase.tearDown(self) - PostgresAsyncTestCase.tearDown(self) - - async def asyncTearDown(self): - await EventRepositorySelectTestCase.asyncTearDown(self) - await PostgresAsyncTestCase.asyncTearDown(self) - def build_event_repository(self) -> EventRepository: """Fort testing purposes.""" return PostgreSqlEventRepository(**self.repository_db) diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 57697a0fc..577a3fa42 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -43,63 +43,39 @@ InMemoryBrokerSubscriberBuilder, ) +from minos.common.testing import MinosTestCase as MinosTestCaseBase + BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" -class MinosTestCase(unittest.IsolatedAsyncioTestCase, ABC): - def setUp(self) -> None: - super().setUp() - - if not hasattr(self, "config"): - self.config = self.get_config() +class MinosTestCase(MinosTestCaseBase, ABC): + CONFIG_FILE_PATH = CONFIG_FILE_PATH - self.pool_factory = PoolFactory.from_config( + def get_injections(self): + pool_factory = PoolFactory.from_config( self.config, default_classes={"broker": BrokerClientPool, "lock": FakeLockPool, "database": DatabaseClientPool}, ) - self.broker_publisher = InMemoryBrokerPublisher() - self.broker_subscriber_builder = InMemoryBrokerSubscriberBuilder() - self.transaction_repository = InMemoryTransactionRepository(lock_pool=self.pool_factory.get_pool("lock")) - self.event_repository = InMemoryEventRepository( - broker_publisher=self.broker_publisher, - transaction_repository=self.transaction_repository, - lock_pool=self.pool_factory.get_pool("lock"), - ) - self.snapshot_repository = InMemorySnapshotRepository( - event_repository=self.event_repository, transaction_repository=self.transaction_repository + broker_publisher = InMemoryBrokerPublisher() + broker_subscriber_builder = InMemoryBrokerSubscriberBuilder() + transaction_repository = InMemoryTransactionRepository(lock_pool=pool_factory.get_pool("lock")) + event_repository = InMemoryEventRepository( + broker_publisher=broker_publisher, + transaction_repository=transaction_repository, + lock_pool=pool_factory.get_pool("lock"), ) - - self.injector = DependencyInjector( - self.config, - [ - self.pool_factory, - self.broker_publisher, - self.broker_subscriber_builder, - self.transaction_repository, - self.event_repository, - self.snapshot_repository, - ], + snapshot_repository = InMemorySnapshotRepository( + event_repository=event_repository, transaction_repository=transaction_repository ) - self.injector.wire_injections() - - def get_config(self): - """ "TODO""" - return Config(CONFIG_FILE_PATH) - - async def asyncSetUp(self): - await super().asyncSetUp() - - await self.injector.setup_injections() - - async def asyncTearDown(self): - await self.injector.destroy_injections() - - await super().asyncTearDown() - - def tearDown(self) -> None: - self.injector.unwire_injections() - super().tearDown() + return [ + pool_factory, + broker_publisher, + broker_subscriber_builder, + transaction_repository, + event_repository, + snapshot_repository, + ] class FakeAsyncIterator: diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index c879b5fbb..2e0a6d845 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -17,12 +17,57 @@ from .config import ( Config, ) +from .database import ( + DatabaseClientPool, +) +from .injections import ( + DependencyInjector, +) +from .pools import ( + PoolFactory, +) -class PostgresAsyncTestCase(unittest.IsolatedAsyncioTestCase): +class MinosTestCase(unittest.IsolatedAsyncioTestCase): CONFIG_FILE_PATH: Path def setUp(self) -> None: + super().setUp() + + self.config = self.get_config() + self.injector = DependencyInjector(self.config, self.get_injections()) + self.injector.wire_injections() + + def get_config(self): + """ "TODO""" + return Config(self.CONFIG_FILE_PATH) + + def get_injections(self): + return [] + + async def asyncSetUp(self): + await super().asyncSetUp() + await self.injector.setup_injections() + + async def asyncTearDown(self): + await self.injector.destroy_injections() + await super().asyncTearDown() + + def tearDown(self) -> None: + self.injector.unwire_injections() + super().tearDown() + + def __getattr__(self, item): + if item != "injector": + return getattr(self.injector, item) + raise AttributeError + + +class PostgresAsyncTestCase(MinosTestCase): + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self._uuid = uuid4() self._config = Config(self.CONFIG_FILE_PATH) @@ -38,7 +83,8 @@ def setUp(self) -> None: self.broker_queue_db = self._meta_broker_queue_db | self._test_db self.snapshot_db = self._meta_snapshot_db | self._test_db - self.config = Config( + def get_config(self): + return Config( self.CONFIG_FILE_PATH, repository_database=self.repository_db["database"], repository_user=self.repository_db["user"], @@ -48,6 +94,13 @@ def setUp(self) -> None: snapshot_user=self.snapshot_db["user"], ) + def get_injections(self): + return [ + PoolFactory.from_config( + self.config, default_classes={"database": DatabaseClientPool}, + ) + ] + async def asyncSetUp(self): pairs = self._drop_duplicates( [ @@ -70,7 +123,11 @@ async def _setup_database(self, meta: dict[str, Any], test: dict[str, Any]) -> N template = "CREATE DATABASE {database} WITH OWNER = {user};" await cursor.execute(template.format(**test)) + await super().asyncSetUp() + async def asyncTearDown(self): + await super().asyncTearDown() + pairs = self._drop_duplicates( [ (self._meta_repository_db, self.repository_db), diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index d47b76674..e10f62262 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -44,8 +44,8 @@ def test_is_subclass(self): self.assertTrue(issubclass(PostgreSqlBrokerQueue, (BrokerQueue, DatabaseMixin))) def test_constructor(self): - queue = PostgreSqlBrokerQueue("foo_db", query_factory=self.query_factory) - self.assertEqual("foo_db", queue.database) + queue = PostgreSqlBrokerQueue(query_factory=self.query_factory) + self.assertEqual(self.pool_factory.get_pool("database"), queue.pool) self.assertEqual(self.query_factory, queue.query_factory) self.assertEqual(2, queue.retry) self.assertEqual(1000, queue.records) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py index bbf82b846..013e55830 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py @@ -7,9 +7,6 @@ patch, ) -from minos.common import ( - Config, -) from minos.common.testing import ( PostgresAsyncTestCase, ) @@ -85,9 +82,8 @@ def test_build_table_name(self): self.assertEqual("broker_subscriber_queue", self.factory.build_table_name()) -class TestPostgreSqlBrokerSubscriberQueueBuilder(unittest.TestCase): - def setUp(self) -> None: - self.config = Config(CONFIG_FILE_PATH) +class TestPostgreSqlBrokerSubscriberQueueBuilder(PostgresAsyncTestCase): + CONFIG_FILE_PATH = CONFIG_FILE_PATH def test_build(self): builder = PostgreSqlBrokerSubscriberQueueBuilder().with_config(self.config).with_topics({"one", "two"}) From 716c99b13fa47267f55605a9a3a3e6c993fbf2ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 11:17:24 +0200 Subject: [PATCH 092/324] ISSUE #346 * Minor fixes. --- packages/core/minos-microservice-aggregate/tests/utils.py | 5 +---- .../core/minos-microservice-common/minos/common/testing.py | 7 +------ 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 577a3fa42..4d64f2880 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -30,21 +30,18 @@ ValueObjectSet, ) from minos.common import ( - Config, DatabaseClientPool, - DependencyInjector, Lock, LockPool, PoolFactory, ) +from minos.common.testing import MinosTestCase as MinosTestCaseBase from minos.networks import ( BrokerClientPool, InMemoryBrokerPublisher, InMemoryBrokerSubscriberBuilder, ) -from minos.common.testing import MinosTestCase as MinosTestCaseBase - BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index 2e0a6d845..fd6fd88d7 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -64,7 +64,6 @@ def __getattr__(self, item): class PostgresAsyncTestCase(MinosTestCase): - def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) @@ -95,11 +94,7 @@ def get_config(self): ) def get_injections(self): - return [ - PoolFactory.from_config( - self.config, default_classes={"database": DatabaseClientPool}, - ) - ] + return [PoolFactory.from_config(self.config, default_classes={"database": DatabaseClientPool})] async def asyncSetUp(self): pairs = self._drop_duplicates( From abab49ea85ed392f187289fc9d11ebbdceb8566f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 11:22:22 +0200 Subject: [PATCH 093/324] ISSUE #346 * Update `DependencyInjector` tests. --- .../test_injections/test_injectors.py | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_injections/test_injectors.py b/packages/core/minos-microservice-common/tests/test_common/test_injections/test_injectors.py index 9d8f9464a..c8db7de00 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_injections/test_injectors.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_injections/test_injectors.py @@ -12,11 +12,11 @@ from minos.common import ( Config, DependencyInjector, + PoolFactory, classname, ) from tests.utils import ( CONFIG_FILE_PATH, - FakeLockPool, ) @@ -25,17 +25,17 @@ def setUp(self) -> None: self.config = Config(CONFIG_FILE_PATH) def test_from_str(self): - injector = DependencyInjector(self.config, [classname(FakeLockPool)]) - self.assertIsInstance(injector.lock_pool, FakeLockPool) + injector = DependencyInjector(self.config, [classname(PoolFactory)]) + self.assertIsInstance(injector.pool_factory, PoolFactory) def test_from_type(self): - injector = DependencyInjector(self.config, [FakeLockPool]) - self.assertIsInstance(injector.lock_pool, FakeLockPool) + injector = DependencyInjector(self.config, [PoolFactory]) + self.assertIsInstance(injector.pool_factory, PoolFactory) def test_from_instance(self): - instance = FakeLockPool() + instance = PoolFactory.from_config(self.config) injector = DependencyInjector(self.config, [instance]) - self.assertEqual(instance, injector.lock_pool) + self.assertEqual(instance, injector.pool_factory) def test_raises_building(self): injector = DependencyInjector(self.config, ["path.to.LockPool"]) @@ -52,16 +52,16 @@ def test_container(self): self.assertIsInstance(injector.container, Container) self.assertEqual(self.config, injector.container.config()) - def test_container_lock_pool(self): - injector = DependencyInjector(self.config, [FakeLockPool]) - self.assertEqual(injector.lock_pool, injector.container.lock_pool()) + def test_container_pool_factory(self): + injector = DependencyInjector(self.config, [PoolFactory]) + self.assertEqual(injector.pool_factory, injector.container.pool_factory()) async def test_wire_unwire(self): from minos.common.injections import ( decorators, ) - injector = DependencyInjector(self.config, [FakeLockPool]) + injector = DependencyInjector(self.config, [PoolFactory]) mock = MagicMock() injector.container.wire = mock @@ -79,7 +79,7 @@ async def test_wire_unwire_with_modules(self): decorators, ) - injector = DependencyInjector(self.config, [FakeLockPool]) + injector = DependencyInjector(self.config, [PoolFactory]) mock = MagicMock() injector.container.wire = mock From c210abb1ad2e4d464c1dc77fdcf1d9ca478b9e2a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 11:30:11 +0200 Subject: [PATCH 094/324] ISSUE #346 * Update `DatabaseMixin` tests. --- .../test_common/test_database/test_abc.py | 77 +++++++++++-------- 1 file changed, 45 insertions(+), 32 deletions(-) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index 0a26fef8e..e81a7bdd9 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -6,7 +6,7 @@ from minos.common import ( DatabaseClientPool, DatabaseMixin, - DependencyInjector, + DependencyInjector, PoolFactory, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -16,40 +16,53 @@ ) -class TestPostgreSqlMinosDatabase(PostgresAsyncTestCase): +# noinspection SqlNoDataSourceInspection +class TestDatabaseMixin(PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def test_constructor(self): - pool = DatabaseMixin("foo") - self.assertEqual("foo", pool.database) - self.assertEqual("postgres", pool.user) - self.assertEqual("", pool.password) - self.assertEqual("localhost", pool.host) - self.assertEqual(5432, pool.port) - - def test_constructor_extended(self): - database = DatabaseMixin(**self.repository_db) - self.assertEqual(self.repository_db["host"], database.host) - self.assertEqual(self.repository_db["port"], database.port) - self.assertEqual(self.repository_db["database"], database.database) - self.assertEqual(self.repository_db["user"], database.user) - self.assertEqual(self.repository_db["password"], database.password) + pool = DatabaseClientPool.from_config(self.config) + database = DatabaseMixin(pool) + self.assertEqual(pool, database.pool) + + async def test_constructor_with_pool_factory(self): + pool_factory = PoolFactory(self.config, {"database": DatabaseClientPool}) + # noinspection PyTypeChecker + database = DatabaseMixin(pool_factory=pool_factory) + # noinspection PyUnresolvedReferences + self.assertEqual(pool_factory.get_pool("database"), database.pool) + + def test_database(self): + pool = DatabaseClientPool.from_config(self.config) + database = DatabaseMixin(pool) + self.assertEqual(pool.database, database.database) + + def test_user(self): + pool = DatabaseClientPool.from_config(self.config) + database = DatabaseMixin(pool) + self.assertEqual(pool.user, database.user) + + def test_password(self): + pool = DatabaseClientPool.from_config(self.config) + database = DatabaseMixin(pool) + self.assertEqual(pool.password, database.password) + + def test_host(self): + pool = DatabaseClientPool.from_config(self.config) + database = DatabaseMixin(pool) + self.assertEqual(pool.host, database.host) + + def test_port(self): + pool = DatabaseClientPool.from_config(self.config) + database = DatabaseMixin(pool) + self.assertEqual(pool.port, database.port) async def test_pool(self): - async with DatabaseMixin(**self.repository_db) as database: + async with DatabaseMixin() as database: self.assertIsInstance(database.pool, DatabaseClientPool) - async def test_pool_with_dependency_injections(self): - injector = DependencyInjector(self.config, [DatabaseClientPool]) - await injector.wire_and_setup_injections(modules=[sys.modules[__name__]]) - - async with DatabaseMixin(**self.repository_db) as database: - self.assertEqual(injector.postgresql_pool, database.pool) - - await injector.unwire_and_destroy_injections() - async def test_submit_query(self): - async with DatabaseMixin(**self.repository_db) as database: + async with DatabaseMixin() as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") async with aiopg.connect(**self.repository_db) as connection: @@ -58,7 +71,7 @@ async def test_submit_query(self): self.assertTrue((await cursor.fetchone())[0]) async def test_submit_query_locked(self): - async with DatabaseMixin(**self.repository_db) as database: + async with DatabaseMixin() as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);", lock=1234) async with aiopg.connect(**self.repository_db) as connection: @@ -67,7 +80,7 @@ async def test_submit_query_locked(self): self.assertTrue((await cursor.fetchone())[0]) async def test_submit_query_and_fetchone(self): - async with DatabaseMixin(**self.repository_db) as database: + async with DatabaseMixin() as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") @@ -76,7 +89,7 @@ async def test_submit_query_and_fetchone(self): self.assertEqual((3,), observed) async def test_submit_query_and_iter(self): - async with DatabaseMixin(**self.repository_db) as database: + async with DatabaseMixin() as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") @@ -85,7 +98,7 @@ async def test_submit_query_and_iter(self): self.assertEqual([(3,), (4,), (5,)], observed) async def test_submit_query_and_iter_streaming_mode_true(self): - async with DatabaseMixin(**self.repository_db) as database: + async with DatabaseMixin() as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") @@ -94,7 +107,7 @@ async def test_submit_query_and_iter_streaming_mode_true(self): self.assertEqual([(3,), (4,), (5,)], observed) async def test_submit_query_and_iter_locked(self): - async with DatabaseMixin(**self.repository_db) as database: + async with DatabaseMixin() as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") From e703077c6639eb10eb9cc4325ee8b5586b22af09 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 11:55:16 +0200 Subject: [PATCH 095/324] ISSUE #346 * Fix all broken tests. --- .../minos/common/config/v1.py | 47 +------------------ .../minos/common/config/v2.py | 26 +++++----- .../minos/common/database/pools.py | 2 + .../minos/common/locks.py | 4 ++ .../test_config/test_v1/test_base.py | 2 +- .../test_config/test_v2/test_base.py | 22 ++++----- .../test_config/test_v2/test_parameterized.py | 3 -- .../minos/networks/brokers/pools.py | 9 ++-- 8 files changed, 35 insertions(+), 80 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/config/v1.py b/packages/core/minos-microservice-common/minos/common/config/v1.py index 7c65bb687..fdac15c47 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v1.py +++ b/packages/core/minos-microservice-common/minos/common/config/v1.py @@ -128,21 +128,7 @@ def _get_injections(self) -> list[type[InjectableMixin]]: except MinosConfigException: injections = list() - old = [import_module(classname) for classname in injections] - from ..injections import ( - InjectableMixin, - ) - from ..pools import ( - PoolFactory, - ) - - injections = list() - injections.append(PoolFactory) # FIXME - - for type_ in old: - if not issubclass(type_, InjectableMixin): - continue - injections.append(type_) + injections = [import_module(classname) for classname in injections] # noinspection PyTypeChecker return injections @@ -231,36 +217,7 @@ def _get_services(self) -> list[type]: return services def _get_pools(self) -> dict[str, type]: - try: - pools = self.get_by_key("service.injections") - except Exception: - pools = list() - - if isinstance(pools, dict): - pools = list(pools.values()) - - old = [import_module(classname) for classname in pools] - - from ..pools import ( - Pool, - ) - - pools = dict() - - for type_ in old: - if not issubclass(type_, Pool): - continue - label = "unknown" - if "lock" in type_.__name__.lower(): - label = "lock" - elif "postgres" in type_.__name__.lower(): - label = "database" - elif "broker" in type_.__name__.lower(): - label = "broker" - - pools[label] = type_ - - return pools + return dict() def _get_routers(self) -> list[type]: try: diff --git a/packages/core/minos-microservice-common/minos/common/config/v2.py b/packages/core/minos-microservice-common/minos/common/config/v2.py index 0c108a576..43addf001 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v2.py +++ b/packages/core/minos-microservice-common/minos/common/config/v2.py @@ -50,14 +50,8 @@ def _get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin]]] partial_ans = list() - from ..pools import ( - PoolFactory, - ) - - partial_ans.append(PoolFactory) # FIXME - with suppress(MinosConfigException): - partial_ans.extend(self._get_pools().values()) + partial_ans.append(self._get_pools().get("factory")) with suppress(MinosConfigException): partial_ans.append(self._get_interfaces().get("http").get("connector")) @@ -96,7 +90,7 @@ def _get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin]]] ): type_ = builder_type elif not issubclass(type_, InjectableMixin): - continue # raise MinosConfigException(f"{type_!r} must be subclass of {InjectableMixin!r}.") + raise MinosConfigException(f"{type_!r} must be subclass of {InjectableMixin!r}.") ans.append(type_) @@ -154,14 +148,22 @@ def _parse_periodic_interface(data: dict[str, Any]) -> dict[str, Any]: return data def _get_pools(self) -> dict[str, type]: + from ..pools import ( + PoolFactory, + ) + factory = PoolFactory + try: - data = self.get_by_key("pools") + types = self.get_by_key("pools") except MinosConfigException: - data = dict() + types = dict() - data = {name: import_module(classname) for name, classname in data.items()} + types = {name: import_module(classname) for name, classname in types.items()} - return data + return { + "factory": factory, + "types": types, + } def _get_routers(self) -> list[type]: try: diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index ef2ca0efc..d34520f67 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -21,6 +21,7 @@ OperationalError, ) +from ..injections import Injectable from ..locks import ( LockPool, ) @@ -119,6 +120,7 @@ def acquire(self, key: Hashable, *args, **kwargs) -> DatabaseLock: return DatabaseLock(super().acquire(), key, *args, **kwargs) +@Injectable("postgresql_pool") class PostgreSqlLockPool(DatabaseLockPool): """TODO""" diff --git a/packages/core/minos-microservice-common/minos/common/locks.py b/packages/core/minos-microservice-common/minos/common/locks.py index 90d148b28..d52a602dd 100644 --- a/packages/core/minos-microservice-common/minos/common/locks.py +++ b/packages/core/minos-microservice-common/minos/common/locks.py @@ -16,6 +16,9 @@ cached_property, ) +from .injections import ( + Injectable, +) from .pools import ( Pool, ) @@ -43,5 +46,6 @@ def hashed_key(self) -> int: return self.key +@Injectable("lock_pool") class LockPool(Pool[Lock], ABC): """Postgres Locking Pool class.""" diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py index f73eb24dc..1f24377ea 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py @@ -6,7 +6,7 @@ from minos.common import ( Config, ConfigV1, - MinosConfigException, + MinosConfigException, PoolFactory, ) from tests.utils import ( BASE_PATH, diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py index bf5a1af54..de818ffa0 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py @@ -1,8 +1,4 @@ import unittest -from itertools import ( - chain, - cycle, -) from unittest.mock import ( patch, ) @@ -62,9 +58,6 @@ def test_name(self): def test_injections(self): expected = [ PoolFactory, - FakeLockPool, - FakeDatabasePool, - FakeBrokerClientPool, FakeHttpConnector, FakeBrokerPublisher, FakeBrokerSubscriberBuilder(FakeBrokerSubscriber), @@ -82,8 +75,7 @@ def test_injections_not_defined(self): # FIXME self.assertEqual([PoolFactory], self.config.get_injections()) def test_injections_not_injectable(self): - side_effect = chain([{"client": "builtins.int"}], cycle([MinosConfigException("")])) - with patch.object(ConfigV2, "get_by_key", side_effect=side_effect): + with patch.object(ConfigV2, "_get_pools", return_value={"factory": int}): with self.assertRaises(MinosConfigException): self.config.get_injections() @@ -147,15 +139,19 @@ def test_interface_unknown(self): def test_pools(self): expected = { - "broker": FakeBrokerClientPool, - "database": FakeDatabasePool, - "lock": FakeLockPool, + "factory": PoolFactory, + "types": { + "broker": FakeBrokerClientPool, + "database": FakeDatabasePool, + "lock": FakeLockPool, + } } self.assertEqual(expected, self.config.get_pools()) def test_pools_not_defined(self): + expected = {"factory": PoolFactory, "types": {}} with patch.object(ConfigV2, "get_by_key", side_effect=MinosConfigException("")): - self.assertEqual(dict(), self.config.get_pools()) + self.assertEqual(expected, self.config.get_pools()) def test_services(self): self.assertEqual([float, int], self.config.get_services()) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py index 42ff0ee0d..c8fca6c71 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py @@ -39,9 +39,6 @@ def test_injections_nones(self): expected = [ PoolFactory, - FakeLockPool, - FakeDatabasePool, - FakeBrokerClientPool, FakeBrokerPublisher, FakeBrokerSubscriberBuilder(FakeBrokerSubscriber), FakeEventRepository, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py b/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py index 8b2e15696..66df5475c 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py @@ -14,6 +14,7 @@ from minos.common import ( Config, + Injectable, Pool, ) @@ -27,16 +28,12 @@ logger = logging.getLogger(__name__) +@Injectable("broker_pool") class BrokerClientPool(Pool): """Broker Client Pool class.""" def __init__( - self, - instance_kwargs: dict[str, Any], - maxsize: int = 5, - recycle: Optional[int] = 3600, - *args, - **kwargs, + self, instance_kwargs: dict[str, Any], maxsize: int = 5, recycle: Optional[int] = 3600, *args, **kwargs ): super().__init__(maxsize=maxsize, recycle=recycle, *args, **kwargs) self._instance_kwargs = instance_kwargs From 9d874c9533179e65542bd13b30558ccf90b0ad3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 12:06:07 +0200 Subject: [PATCH 096/324] ISSUE #346 * Improve tests. --- .../minos/common/testing.py | 5 +- .../minos-microservice-saga/tests/utils.py | 66 +++++++------------ .../tests/test_kafka/test_publisher.py | 20 ++---- .../tests/test_kafka/test_subscriber.py | 24 ++----- 4 files changed, 38 insertions(+), 77 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index fd6fd88d7..e4ad52227 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -64,8 +64,7 @@ def __getattr__(self, item): class PostgresAsyncTestCase(MinosTestCase): - def __init__(self, *args, **kwargs): - super().__init__(*args, **kwargs) + def setUp(self): self._uuid = uuid4() self._config = Config(self.CONFIG_FILE_PATH) @@ -82,6 +81,8 @@ def __init__(self, *args, **kwargs): self.broker_queue_db = self._meta_broker_queue_db | self._test_db self.snapshot_db = self._meta_snapshot_db | self._test_db + super().setUp() + def get_config(self): return Config( self.CONFIG_FILE_PATH, diff --git a/packages/core/minos-microservice-saga/tests/utils.py b/packages/core/minos-microservice-saga/tests/utils.py index 4f26a96e3..94c2dc24b 100644 --- a/packages/core/minos-microservice-saga/tests/utils.py +++ b/packages/core/minos-microservice-saga/tests/utils.py @@ -24,6 +24,7 @@ PoolFactory, SetupMixin, ) +from minos.common.testing import MinosTestCase as MinosTestCaseBase from minos.networks import ( BrokerClientPool, InMemoryBrokerPublisher, @@ -41,53 +42,32 @@ DB_PATH = BASE_PATH / "test_db.lmdb" -class MinosTestCase(unittest.IsolatedAsyncioTestCase): - def setUp(self) -> None: - super().setUp() +class MinosTestCase(MinosTestCaseBase): + CONFIG_FILE_PATH = CONFIG_FILE_PATH - self.config = Config(CONFIG_FILE_PATH) - - self.pool_factory = PoolFactory.from_config( - CONFIG_FILE_PATH, default_classes={"broker": BrokerClientPool, "lock": FakeLockPool} - ) - self.broker_publisher = InMemoryBrokerPublisher() - self.broker_subscriber_builder = InMemoryBrokerSubscriberBuilder() - self.transaction_repository = InMemoryTransactionRepository(lock_pool=self.pool_factory.get_pool("lock")) - self.event_repository = InMemoryEventRepository( - broker_publisher=self.broker_publisher, - transaction_repository=self.transaction_repository, - lock_pool=self.pool_factory.get_pool("lock"), + def get_injections(self): + pool_factory = PoolFactory.from_config( + self.config, default_classes={"broker": BrokerClientPool, "lock": FakeLockPool} ) - self.snapshot_repository = InMemorySnapshotRepository( - event_repository=self.event_repository, transaction_repository=self.transaction_repository + broker_publisher = InMemoryBrokerPublisher() + broker_subscriber_builder = InMemoryBrokerSubscriberBuilder() + transaction_repository = InMemoryTransactionRepository(lock_pool=pool_factory.get_pool("lock")) + event_repository = InMemoryEventRepository( + broker_publisher=broker_publisher, + transaction_repository=transaction_repository, + lock_pool=pool_factory.get_pool("lock"), ) - - self.injector = DependencyInjector( - self.config, - [ - self.pool_factory, - self.broker_publisher, - self.broker_subscriber_builder, - self.transaction_repository, - self.event_repository, - self.snapshot_repository, - ], + snapshot_repository = InMemorySnapshotRepository( + event_repository=event_repository, transaction_repository=transaction_repository ) - self.injector.wire_injections() - - async def asyncSetUp(self): - await super().asyncSetUp() - - await self.injector.setup_injections() - - async def asyncTearDown(self): - await self.injector.destroy_injections() - - await super().asyncTearDown() - - def tearDown(self) -> None: - self.injector.unwire_injections() - super().tearDown() + return [ + pool_factory, + broker_publisher, + broker_subscriber_builder, + transaction_repository, + event_repository, + snapshot_repository, + ] class FakeBrokerPublisher(SetupMixin): diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py index 485843d6c..e0ce016ae 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py @@ -13,7 +13,9 @@ from minos.common import ( Config, - DatabaseClientPool, +) +from minos.common.testing import ( + PostgresAsyncTestCase, ) from minos.networks import ( BrokerMessage, @@ -152,23 +154,13 @@ def test_build(self): self.assertEqual(common_config["port"], publisher.port) -class TestPostgreSqlQueuedKafkaBrokerPublisher(unittest.IsolatedAsyncioTestCase): - def setUp(self) -> None: - super().setUp() - self.database_pool = DatabaseClientPool.from_config(CONFIG_FILE_PATH) - - async def asyncSetUp(self) -> None: - await super().asyncSetUp() - await self.database_pool.setup() - - async def asyncTearDown(self) -> None: - await self.database_pool.destroy() - await super().asyncTearDown() +class TestPostgreSqlQueuedKafkaBrokerPublisher(PostgresAsyncTestCase): + CONFIG_FILE_PATH = CONFIG_FILE_PATH def test_from_config(self): with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) - publisher = PostgreSqlQueuedKafkaBrokerPublisher.from_config(CONFIG_FILE_PATH, pool=self.database_pool) + publisher = PostgreSqlQueuedKafkaBrokerPublisher.from_config(CONFIG_FILE_PATH) self.assertIsInstance(publisher, PostgreSqlQueuedKafkaBrokerPublisher) self.assertIsInstance(publisher.impl, KafkaBrokerPublisher) self.assertIsInstance(publisher.queue, PostgreSqlBrokerPublisherQueue) diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py index d59e8c553..f4d615381 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py @@ -21,7 +21,9 @@ from minos.common import ( Config, - DatabaseClientPool, +) +from minos.common.testing import ( + PostgresAsyncTestCase, ) from minos.networks import ( BrokerMessageV1, @@ -251,28 +253,14 @@ def test_build(self): self.assertEqual(common_config["port"], subscriber.port) -class TestPostgreSqlQueuedKafkaBrokerSubscriberBuilder(unittest.IsolatedAsyncioTestCase): - def setUp(self) -> None: - super().setUp() - self.config = Config(CONFIG_FILE_PATH) - self.database_pool = DatabaseClientPool.from_config(CONFIG_FILE_PATH) - - async def asyncSetUp(self) -> None: - await super().asyncSetUp() - await self.database_pool.setup() - - async def asyncTearDown(self) -> None: - await self.database_pool.destroy() - await super().asyncTearDown() +class TestPostgreSqlQueuedKafkaBrokerSubscriberBuilder(PostgresAsyncTestCase): + CONFIG_FILE_PATH = CONFIG_FILE_PATH def test_build(self): with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) builder = ( - PostgreSqlQueuedKafkaBrokerSubscriberBuilder() - .with_config(self.config) - .with_topics({"one", "two"}) - .with_kwargs({"pool": self.database_pool}) + PostgreSqlQueuedKafkaBrokerSubscriberBuilder().with_config(self.config).with_topics({"one", "two"}) ) subscriber = builder.build() From 77609ed356ee1a23c1353c17065dc26565bc4284 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 12:08:57 +0200 Subject: [PATCH 097/324] ISSUE #346 * Rename `MinosTestCase` as `MinosSagaTestCase`. --- .../tests/test_saga/test_executions/test_commit.py | 4 ++-- .../test_saga/test_executions/test_executors/test_abc.py | 4 ++-- .../test_executions/test_executors/test_local.py | 4 ++-- .../test_executions/test_executors/test_request.py | 4 ++-- .../test_executions/test_executors/test_response.py | 4 ++-- .../test_saga/test_executions/test_saga/test_execute.py | 4 ++-- .../test_saga/test_executions/test_saga/test_raw.py | 4 ++-- .../test_executions/test_steps/test_conditional.py | 4 ++-- .../test_saga/test_executions/test_steps/test_local.py | 4 ++-- .../test_saga/test_executions/test_steps/test_remote.py | 4 ++-- .../tests/test_saga/test_executions/test_storage.py | 4 ++-- .../tests/test_saga/test_manager.py | 4 ++-- .../tests/test_saga/test_middleware.py | 4 ++-- .../tests/test_saga/test_services.py | 4 ++-- .../tests/test_saga/test_utils.py | 4 ++-- packages/core/minos-microservice-saga/tests/utils.py | 9 ++++----- 16 files changed, 34 insertions(+), 35 deletions(-) diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py index f8e197627..a49ed6aad 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py @@ -23,11 +23,11 @@ TransactionCommitter, ) from tests.utils import ( - MinosTestCase, + MinosSagaTestCase, ) -class TestTransactionCommitter(MinosTestCase): +class TestTransactionCommitter(MinosSagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_abc.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_abc.py index aa8532f7f..edc5f41f5 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_abc.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_abc.py @@ -12,11 +12,11 @@ SagaOperation, ) from tests.utils import ( - MinosTestCase, + MinosSagaTestCase, ) -class TestExecutor(MinosTestCase): +class TestExecutor(MinosSagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_local.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_local.py index 63cb6bf5d..9c34e125a 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_local.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_local.py @@ -15,13 +15,13 @@ ) from tests.utils import ( Foo, - MinosTestCase, + MinosSagaTestCase, create_payment, create_payment_raises, ) -class TestLocalExecutor(MinosTestCase): +class TestLocalExecutor(MinosSagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_request.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_request.py index 08775242a..df6bc5eb8 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_request.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_request.py @@ -24,12 +24,12 @@ ) from tests.utils import ( Foo, - MinosTestCase, + MinosSagaTestCase, send_create_product, ) -class TestRequestExecutor(MinosTestCase): +class TestRequestExecutor(MinosSagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_response.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_response.py index 2f7acb4b3..be87abab7 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_response.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_response.py @@ -17,12 +17,12 @@ ) from tests.utils import ( Foo, - MinosTestCase, + MinosSagaTestCase, handle_ticket_success, ) -class TestResponseExecutor(MinosTestCase): +class TestResponseExecutor(MinosSagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_execute.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_execute.py index 8252ab940..9d4d9c34e 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_execute.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_execute.py @@ -27,7 +27,7 @@ ) from tests.utils import ( Foo, - MinosTestCase, + MinosSagaTestCase, handle_order_success, handle_ticket_success, handle_ticket_success_raises, @@ -38,7 +38,7 @@ ) -class TestSagaExecution(MinosTestCase): +class TestSagaExecution(MinosSagaTestCase): def setUp(self) -> None: super().setUp() self.saga = ( diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_raw.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_raw.py index b23136ffc..74f905d7c 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_raw.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_raw.py @@ -17,11 +17,11 @@ from tests.utils import ( ADD_ORDER, Foo, - MinosTestCase, + MinosSagaTestCase, ) -class TestSagaExecution(MinosTestCase): +class TestSagaExecution(MinosSagaTestCase): def setUp(self) -> None: super().setUp() self.user = uuid4() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_conditional.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_conditional.py index 907f2d22e..573ad6b6c 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_conditional.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_conditional.py @@ -25,7 +25,7 @@ ) from tests.utils import ( Foo, - MinosTestCase, + MinosSagaTestCase, handle_order_success, handle_ticket_success_raises, send_create_order, @@ -41,7 +41,7 @@ def _is_two(context): return context["option"] == 2 -class TestConditionalSageStepExecution(MinosTestCase): +class TestConditionalSageStepExecution(MinosSagaTestCase): def setUp(self) -> None: super().setUp() self.execute_kwargs = { diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_local.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_local.py index 9b714c2e7..8df8b86b6 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_local.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_local.py @@ -15,14 +15,14 @@ SagaStepStatus, ) from tests.utils import ( - MinosTestCase, + MinosSagaTestCase, create_payment, create_payment_raises, delete_payment, ) -class TestLocalSagaStepExecution(MinosTestCase): +class TestLocalSagaStepExecution(MinosSagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_remote.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_remote.py index 0bc8c6e6d..44f9de546 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_remote.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_remote.py @@ -19,7 +19,7 @@ ) from tests.utils import ( Foo, - MinosTestCase, + MinosSagaTestCase, handle_ticket_error, handle_ticket_error_raises, handle_ticket_success, @@ -30,7 +30,7 @@ ) -class TestRemoteSagaStepExecution(MinosTestCase): +class TestRemoteSagaStepExecution(MinosSagaTestCase): def setUp(self) -> None: super().setUp() self.execute_kwargs = { diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py index 53673e61a..41c098b47 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py @@ -14,11 +14,11 @@ ADD_ORDER, DB_PATH, Foo, - MinosTestCase, + MinosSagaTestCase, ) -class TestSagaExecutionStorage(MinosTestCase): +class TestSagaExecutionStorage(MinosSagaTestCase): DB_PATH = DB_PATH async def asyncSetUp(self) -> None: diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py index bb40153de..4a9a58dae 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py @@ -38,11 +38,11 @@ DB_PATH, DELETE_ORDER, Foo, - MinosTestCase, + MinosSagaTestCase, ) -class TestSagaManager(MinosTestCase): +class TestSagaManager(MinosSagaTestCase): DB_PATH = DB_PATH async def asyncSetUp(self) -> None: diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_middleware.py b/packages/core/minos-microservice-saga/tests/test_saga/test_middleware.py index 45df4d9f7..2d2495320 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_middleware.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_middleware.py @@ -19,7 +19,7 @@ transactional_command, ) from tests.utils import ( - MinosTestCase, + MinosSagaTestCase, ) @@ -30,7 +30,7 @@ async def _fn(request: Request) -> Response: Raw = namedtuple("Raw", ["headers", "content"]) -class TestMiddleware(MinosTestCase): +class TestMiddleware(MinosSagaTestCase): async def test_transactional_command_unused(self): # noinspection PyTypeChecker request = BrokerRequest(Raw({"transactions": None}, "foo")) diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_services.py b/packages/core/minos-microservice-saga/tests/test_saga/test_services.py index a646cc52c..30dfc76dc 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_services.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_services.py @@ -24,11 +24,11 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - MinosTestCase, + MinosSagaTestCase, ) -class TestSagaService(MinosTestCase): +class TestSagaService(MinosSagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_utils.py b/packages/core/minos-microservice-saga/tests/test_saga/test_utils.py index 9caa61e32..f5ed045c0 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_utils.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_utils.py @@ -7,11 +7,11 @@ get_service_name, ) from tests.utils import ( - MinosTestCase, + MinosSagaTestCase, ) -class TestUtils(MinosTestCase): +class TestUtils(MinosSagaTestCase): def test_get_service_name(self): self.assertEqual("order", get_service_name()) diff --git a/packages/core/minos-microservice-saga/tests/utils.py b/packages/core/minos-microservice-saga/tests/utils.py index 94c2dc24b..dfa2af534 100644 --- a/packages/core/minos-microservice-saga/tests/utils.py +++ b/packages/core/minos-microservice-saga/tests/utils.py @@ -2,7 +2,6 @@ annotations, ) -import unittest from pathlib import ( Path, ) @@ -16,15 +15,15 @@ InMemoryTransactionRepository, ) from minos.common import ( - Config, DeclarativeModel, - DependencyInjector, Lock, LockPool, PoolFactory, SetupMixin, ) -from minos.common.testing import MinosTestCase as MinosTestCaseBase +from minos.common.testing import ( + MinosTestCase, +) from minos.networks import ( BrokerClientPool, InMemoryBrokerPublisher, @@ -42,7 +41,7 @@ DB_PATH = BASE_PATH / "test_db.lmdb" -class MinosTestCase(MinosTestCaseBase): +class MinosSagaTestCase(MinosTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def get_injections(self): From 0d4f172a11cf23a17ff51c0937d55d6b5e7a85ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 12:10:47 +0200 Subject: [PATCH 098/324] ISSUE #346 * Rename `MinosTestCase` as `AggregateTestCase`. --- .../tests/test_aggregate/test_aggregate.py | 4 ++-- .../test_entities/test_models/test_root/test_base.py | 4 ++-- .../test_entities/test_models/test_root/test_broker.py | 4 ++-- .../test_models/test_root/test_differences.py | 4 ++-- .../test_models/test_root/test_not_provided.py | 4 ++-- .../test_models/test_root/test_with_postgresql.py | 4 ++-- .../test_entities/test_refs/test_injectors.py | 4 ++-- .../test_aggregate/test_entities/test_refs/test_models.py | 4 ++-- .../test_entities/test_refs/test_resolvers.py | 4 ++-- .../tests/test_aggregate/test_events/test_fields.py | 4 ++-- .../tests/test_aggregate/test_events/test_models.py | 4 ++-- .../test_events/test_repositories/test_abc.py | 4 ++-- .../tests/test_aggregate/test_snapshots/test_entries.py | 4 ++-- .../tests/test_aggregate/test_snapshots/test_memory.py | 4 ++-- .../test_aggregate/test_snapshots/test_pg/test_abc.py | 4 ++-- .../test_aggregate/test_snapshots/test_pg/test_api.py | 4 ++-- .../test_aggregate/test_snapshots/test_pg/test_readers.py | 4 ++-- .../test_aggregate/test_snapshots/test_pg/test_writers.py | 4 ++-- .../tests/test_aggregate/test_snapshots/test_services.py | 4 ++-- .../tests/test_aggregate/test_transactions/test_entries.py | 4 ++-- .../test_transactions/test_repositories/test_abc.py | 4 ++-- .../test_transactions/test_repositories/test_memory.py | 6 +++--- .../test_transactions/test_repositories/test_pg.py | 6 +++--- .../test_aggregate/test_transactions/test_services.py | 4 ++-- .../tests/testcases/event_repository.py | 4 ++-- packages/core/minos-microservice-aggregate/tests/utils.py | 7 ++++--- 26 files changed, 56 insertions(+), 55 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_aggregate.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_aggregate.py index 89e6fd82a..b40b46a90 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_aggregate.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_aggregate.py @@ -11,13 +11,13 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - MinosTestCase, + AggregateTestCase, Order, OrderAggregate, ) -class TestAggregate(MinosTestCase): +class TestAggregate(AggregateTestCase): async def test_root(self): async with OrderAggregate.from_config(CONFIG_FILE_PATH) as aggregate: self.assertEqual(Order, aggregate.root) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_base.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_base.py index 4634fb8f9..f29f54354 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_base.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_base.py @@ -19,11 +19,11 @@ ) from tests.utils import ( Car, - MinosTestCase, + AggregateTestCase, ) -class TestRootEntity(MinosTestCase): +class TestRootEntity(AggregateTestCase): async def test_create(self): observed = await Car.create(doors=3, color="blue") expected = Car( diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_broker.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_broker.py index f94810954..3ab2959fd 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_broker.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_broker.py @@ -15,12 +15,12 @@ ) from tests.utils import ( Car, - MinosTestCase, + AggregateTestCase, Owner, ) -class TestRootEntityBroker(MinosTestCase): +class TestRootEntityBroker(AggregateTestCase): async def test_create(self): car = await Car.create(doors=3, color="blue") diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_differences.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_differences.py index 8fb49716e..203d429a1 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_differences.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_differences.py @@ -14,11 +14,11 @@ ) from tests.utils import ( Car, - MinosTestCase, + AggregateTestCase, ) -class TestRootEntityDifferences(MinosTestCase): +class TestRootEntityDifferences(AggregateTestCase): async def asyncSetUp(self) -> None: self.uuid = uuid4() self.uuid_another = uuid4() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_not_provided.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_not_provided.py index 1ea55bd1e..20dea3e5f 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_not_provided.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_not_provided.py @@ -11,11 +11,11 @@ ) from tests.utils import ( Car, - MinosTestCase, + AggregateTestCase, ) -class TestRootEntityNotProvided(MinosTestCase): +class TestRootEntityNotProvided(AggregateTestCase): async def test_create_raises(self): with self.assertRaises(NotProvidedException): await Car.create(doors=3, color="blue", _event_repository=None) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py index 898590f95..497d4ddc0 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py @@ -14,14 +14,14 @@ from tests.utils import ( CONFIG_FILE_PATH, Car, - MinosTestCase, + AggregateTestCase, Order, OrderItem, Review, ) -class TestExternalEntityWithPostgreSql(MinosTestCase, PostgresAsyncTestCase): +class TestExternalEntityWithPostgreSql(AggregateTestCase, PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def setUp(self): diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_injectors.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_injectors.py index f88b5d0a7..2053a601a 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_injectors.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_injectors.py @@ -13,11 +13,11 @@ ) from tests.utils import ( Car, - MinosTestCase, + AggregateTestCase, ) -class TestRefInjector(MinosTestCase): +class TestRefInjector(AggregateTestCase): async def test_simple(self): model = await Car.create(3, "test") mapper = {model.uuid: model} diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_models.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_models.py index 073427bcc..c82b06229 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_models.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_models.py @@ -25,7 +25,7 @@ ModelType, ) from tests.utils import ( - MinosTestCase, + AggregateTestCase, ) FakeMessage = ModelType.build("FakeMessage", {"content": Any}) @@ -34,7 +34,7 @@ Foo = ModelType.build("Foo", {"another": Ref[Bar]}) -class TestRef(MinosTestCase): +class TestRef(AggregateTestCase): def test_subclass(self): # noinspection PyTypeHints self.assertTrue(issubclass(Ref, (DeclarativeModel, UUID, Generic))) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_resolvers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_resolvers.py index a64bf7666..f19bfcc8b 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_resolvers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_resolvers.py @@ -19,14 +19,14 @@ BrokerMessageV1Status, ) from tests.utils import ( - MinosTestCase, + AggregateTestCase, ) Bar = ModelType.build("Bar", {"uuid": UUID, "version": int}) Foo = ModelType.build("Foo", {"uuid": UUID, "version": int, "another": Ref[Bar]}) -class TestRefResolver(MinosTestCase): +class TestRefResolver(AggregateTestCase): def setUp(self) -> None: super().setUp() self.resolver = RefResolver() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_fields.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_fields.py index 25fbf55d5..153fca955 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_fields.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_fields.py @@ -26,12 +26,12 @@ ) from tests.utils import ( Car, - MinosTestCase, + AggregateTestCase, Owner, ) -class TestFieldDiffContainer(MinosTestCase): +class TestFieldDiffContainer(AggregateTestCase): async def asyncSetUp(self) -> None: await super().asyncSetUp() self.car_one = Car(3, "blue", id=1, version=1) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_models.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_models.py index d79712314..e3e22e64c 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_models.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_models.py @@ -20,12 +20,12 @@ ) from tests.utils import ( Car, - MinosTestCase, + AggregateTestCase, Owner, ) -class TestEvent(MinosTestCase): +class TestEvent(AggregateTestCase): async def asyncSetUp(self) -> None: await super().asyncSetUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py index e613b38b4..519b502a0 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py @@ -43,7 +43,7 @@ from tests.utils import ( FakeAsyncIterator, FakeLock, - MinosTestCase, + AggregateTestCase, ) @@ -62,7 +62,7 @@ async def _offset(self) -> int: return 0 -class TestEventRepository(MinosTestCase): +class TestEventRepository(AggregateTestCase): def setUp(self) -> None: super().setUp() self.event_repository = _EventRepository() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py index 58cb2e9fc..3939ade7e 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py @@ -14,11 +14,11 @@ ) from tests.utils import ( Car, - MinosTestCase, + AggregateTestCase, ) -class TestSnapshotEntry(MinosTestCase): +class TestSnapshotEntry(AggregateTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py index c37257891..e14a877f0 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py @@ -25,11 +25,11 @@ ) from tests.utils import ( Car, - MinosTestCase, + AggregateTestCase, ) -class TestInMemorySnapshotRepository(MinosTestCase): +class TestInMemorySnapshotRepository(AggregateTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py index 3f5733f7a..8f0d839fd 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py @@ -10,11 +10,11 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - MinosTestCase, + AggregateTestCase, ) -class TestPostgreSqlSnapshotSetup(MinosTestCase, PostgresAsyncTestCase): +class TestPostgreSqlSnapshotSetup(AggregateTestCase, PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH async def test_setup_snapshot_table(self): diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py index f23f68edf..a580c5544 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py @@ -22,11 +22,11 @@ from tests.utils import ( CONFIG_FILE_PATH, FakeAsyncIterator, - MinosTestCase, + AggregateTestCase, ) -class TestPostgreSqlSnapshotRepository(MinosTestCase, PostgresAsyncTestCase): +class TestPostgreSqlSnapshotRepository(AggregateTestCase, PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def setUp(self) -> None: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py index 6f6db70de..08460edb7 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py @@ -27,11 +27,11 @@ from tests.utils import ( CONFIG_FILE_PATH, Car, - MinosTestCase, + AggregateTestCase, ) -class TestPostgreSqlSnapshotReader(MinosTestCase, PostgresAsyncTestCase): +class TestPostgreSqlSnapshotReader(AggregateTestCase, PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def setUp(self) -> None: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py index eb8fbab0a..95796e79c 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py @@ -35,11 +35,11 @@ from tests.utils import ( CONFIG_FILE_PATH, Car, - MinosTestCase, + AggregateTestCase, ) -class TestPostgreSqlSnapshotWriter(MinosTestCase, PostgresAsyncTestCase): +class TestPostgreSqlSnapshotWriter(AggregateTestCase, PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def setUp(self) -> None: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py index 4e36a15b4..40b1c9d0f 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py @@ -27,14 +27,14 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - MinosTestCase, + AggregateTestCase, Order, ) Agg = ModelType.build("Agg", {"uuid": UUID}) -class TestSnapshotService(MinosTestCase, PostgresAsyncTestCase): +class TestSnapshotService(AggregateTestCase, PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def setUp(self) -> None: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py index e6d387c6f..6f3188331 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py @@ -24,11 +24,11 @@ ) from tests.utils import ( FakeAsyncIterator, - MinosTestCase, + AggregateTestCase, ) -class TestTransactionEntry(MinosTestCase): +class TestTransactionEntry(AggregateTestCase): def test_constructor(self): transaction = TransactionEntry() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py index 562a54baa..9fa530d36 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py @@ -27,7 +27,7 @@ from tests.utils import ( FakeAsyncIterator, FakeLock, - MinosTestCase, + AggregateTestCase, ) @@ -41,7 +41,7 @@ def _select(self, **kwargs) -> AsyncIterator[TransactionEntry]: """For testing purposes.""" -class TestTransactionRepository(MinosTestCase): +class TestTransactionRepository(AggregateTestCase): def setUp(self) -> None: super().setUp() self.transaction_repository = _TransactionRepository() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py index b16339df3..394666700 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py @@ -11,11 +11,11 @@ TransactionStatus, ) from tests.utils import ( - MinosTestCase, + AggregateTestCase, ) -class TestInMemoryTransactionRepository(MinosTestCase): +class TestInMemoryTransactionRepository(AggregateTestCase): def setUp(self) -> None: super().setUp() self.uuid = uuid4() @@ -116,7 +116,7 @@ async def test_select_empty(self): self.assertEqual(expected, observed) -class TestInMemoryTransactionRepositorySelect(MinosTestCase): +class TestInMemoryTransactionRepositorySelect(AggregateTestCase): def setUp(self) -> None: super().setUp() self.uuid_1 = uuid4() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index af269810d..a5a6100a6 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -20,11 +20,11 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - MinosTestCase, + AggregateTestCase, ) -class TestPostgreSqlTransactionRepository(MinosTestCase, PostgresAsyncTestCase): +class TestPostgreSqlTransactionRepository(AggregateTestCase, PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def setUp(self) -> None: @@ -153,7 +153,7 @@ async def test_submit_rejected_raises(self): await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.REJECTED, 34)) -class TestPostgreSqlTransactionRepositorySelect(MinosTestCase, PostgresAsyncTestCase): +class TestPostgreSqlTransactionRepositorySelect(AggregateTestCase, PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def setUp(self) -> None: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py index 849615a78..d7c60b3db 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py @@ -33,11 +33,11 @@ from tests.utils import ( CONFIG_FILE_PATH, FakeAsyncIterator, - MinosTestCase, + AggregateTestCase, ) -class TestSnapshotService(MinosTestCase, PostgresAsyncTestCase): +class TestSnapshotService(AggregateTestCase, PostgresAsyncTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def setUp(self) -> None: diff --git a/packages/core/minos-microservice-aggregate/tests/testcases/event_repository.py b/packages/core/minos-microservice-aggregate/tests/testcases/event_repository.py index bbbddc800..3ff98508a 100644 --- a/packages/core/minos-microservice-aggregate/tests/testcases/event_repository.py +++ b/packages/core/minos-microservice-aggregate/tests/testcases/event_repository.py @@ -29,11 +29,11 @@ current_datetime, ) from tests.utils import ( - MinosTestCase, + AggregateTestCase, ) -class EventRepositoryTestCase(MinosTestCase): +class EventRepositoryTestCase(AggregateTestCase): def setUp(self) -> None: super().setUp() self.uuid = uuid4() diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 4d64f2880..891da9776 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -2,7 +2,6 @@ annotations, ) -import unittest from abc import ( ABC, ) @@ -35,7 +34,9 @@ LockPool, PoolFactory, ) -from minos.common.testing import MinosTestCase as MinosTestCaseBase +from minos.common.testing import ( + MinosTestCase, +) from minos.networks import ( BrokerClientPool, InMemoryBrokerPublisher, @@ -46,7 +47,7 @@ CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" -class MinosTestCase(MinosTestCaseBase, ABC): +class AggregateTestCase(MinosTestCase, ABC): CONFIG_FILE_PATH = CONFIG_FILE_PATH def get_injections(self): From 8d4afed34509277a64d366acee2985e906eb8bb5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 12:11:33 +0200 Subject: [PATCH 099/324] ISSUE #346 * Rename `MinosSagaTestCase` as `SagaTestCase`. --- .../tests/test_saga/test_executions/test_commit.py | 4 ++-- .../test_saga/test_executions/test_executors/test_abc.py | 4 ++-- .../test_saga/test_executions/test_executors/test_local.py | 4 ++-- .../test_saga/test_executions/test_executors/test_request.py | 4 ++-- .../test_saga/test_executions/test_executors/test_response.py | 4 ++-- .../tests/test_saga/test_executions/test_saga/test_execute.py | 4 ++-- .../tests/test_saga/test_executions/test_saga/test_raw.py | 4 ++-- .../test_saga/test_executions/test_steps/test_conditional.py | 4 ++-- .../tests/test_saga/test_executions/test_steps/test_local.py | 4 ++-- .../tests/test_saga/test_executions/test_steps/test_remote.py | 4 ++-- .../tests/test_saga/test_executions/test_storage.py | 4 ++-- .../minos-microservice-saga/tests/test_saga/test_manager.py | 4 ++-- .../tests/test_saga/test_middleware.py | 4 ++-- .../minos-microservice-saga/tests/test_saga/test_services.py | 4 ++-- .../minos-microservice-saga/tests/test_saga/test_utils.py | 4 ++-- packages/core/minos-microservice-saga/tests/utils.py | 2 +- 16 files changed, 31 insertions(+), 31 deletions(-) diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py index a49ed6aad..efaad6109 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_commit.py @@ -23,11 +23,11 @@ TransactionCommitter, ) from tests.utils import ( - MinosSagaTestCase, + SagaTestCase, ) -class TestTransactionCommitter(MinosSagaTestCase): +class TestTransactionCommitter(SagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_abc.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_abc.py index edc5f41f5..b6b1dcaf2 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_abc.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_abc.py @@ -12,11 +12,11 @@ SagaOperation, ) from tests.utils import ( - MinosSagaTestCase, + SagaTestCase, ) -class TestExecutor(MinosSagaTestCase): +class TestExecutor(SagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_local.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_local.py index 9c34e125a..df43aef6e 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_local.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_local.py @@ -15,13 +15,13 @@ ) from tests.utils import ( Foo, - MinosSagaTestCase, + SagaTestCase, create_payment, create_payment_raises, ) -class TestLocalExecutor(MinosSagaTestCase): +class TestLocalExecutor(SagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_request.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_request.py index df6bc5eb8..e8478f43d 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_request.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_request.py @@ -24,12 +24,12 @@ ) from tests.utils import ( Foo, - MinosSagaTestCase, + SagaTestCase, send_create_product, ) -class TestRequestExecutor(MinosSagaTestCase): +class TestRequestExecutor(SagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_response.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_response.py index be87abab7..12c6d68c4 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_response.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_executors/test_response.py @@ -17,12 +17,12 @@ ) from tests.utils import ( Foo, - MinosSagaTestCase, + SagaTestCase, handle_ticket_success, ) -class TestResponseExecutor(MinosSagaTestCase): +class TestResponseExecutor(SagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_execute.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_execute.py index 9d4d9c34e..966ea4c4b 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_execute.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_execute.py @@ -27,7 +27,7 @@ ) from tests.utils import ( Foo, - MinosSagaTestCase, + SagaTestCase, handle_order_success, handle_ticket_success, handle_ticket_success_raises, @@ -38,7 +38,7 @@ ) -class TestSagaExecution(MinosSagaTestCase): +class TestSagaExecution(SagaTestCase): def setUp(self) -> None: super().setUp() self.saga = ( diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_raw.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_raw.py index 74f905d7c..aa94efea6 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_raw.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_saga/test_raw.py @@ -17,11 +17,11 @@ from tests.utils import ( ADD_ORDER, Foo, - MinosSagaTestCase, + SagaTestCase, ) -class TestSagaExecution(MinosSagaTestCase): +class TestSagaExecution(SagaTestCase): def setUp(self) -> None: super().setUp() self.user = uuid4() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_conditional.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_conditional.py index 573ad6b6c..0690cd6e1 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_conditional.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_conditional.py @@ -25,7 +25,7 @@ ) from tests.utils import ( Foo, - MinosSagaTestCase, + SagaTestCase, handle_order_success, handle_ticket_success_raises, send_create_order, @@ -41,7 +41,7 @@ def _is_two(context): return context["option"] == 2 -class TestConditionalSageStepExecution(MinosSagaTestCase): +class TestConditionalSageStepExecution(SagaTestCase): def setUp(self) -> None: super().setUp() self.execute_kwargs = { diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_local.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_local.py index 8df8b86b6..2a0122045 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_local.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_local.py @@ -15,14 +15,14 @@ SagaStepStatus, ) from tests.utils import ( - MinosSagaTestCase, + SagaTestCase, create_payment, create_payment_raises, delete_payment, ) -class TestLocalSagaStepExecution(MinosSagaTestCase): +class TestLocalSagaStepExecution(SagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_remote.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_remote.py index 44f9de546..b7f7c920f 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_remote.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_steps/test_remote.py @@ -19,7 +19,7 @@ ) from tests.utils import ( Foo, - MinosSagaTestCase, + SagaTestCase, handle_ticket_error, handle_ticket_error_raises, handle_ticket_success, @@ -30,7 +30,7 @@ ) -class TestRemoteSagaStepExecution(MinosSagaTestCase): +class TestRemoteSagaStepExecution(SagaTestCase): def setUp(self) -> None: super().setUp() self.execute_kwargs = { diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py index 41c098b47..8c174118d 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py @@ -14,11 +14,11 @@ ADD_ORDER, DB_PATH, Foo, - MinosSagaTestCase, + SagaTestCase, ) -class TestSagaExecutionStorage(MinosSagaTestCase): +class TestSagaExecutionStorage(SagaTestCase): DB_PATH = DB_PATH async def asyncSetUp(self) -> None: diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py index 4a9a58dae..ca4fec8a4 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py @@ -38,11 +38,11 @@ DB_PATH, DELETE_ORDER, Foo, - MinosSagaTestCase, + SagaTestCase, ) -class TestSagaManager(MinosSagaTestCase): +class TestSagaManager(SagaTestCase): DB_PATH = DB_PATH async def asyncSetUp(self) -> None: diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_middleware.py b/packages/core/minos-microservice-saga/tests/test_saga/test_middleware.py index 2d2495320..d18ab3ede 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_middleware.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_middleware.py @@ -19,7 +19,7 @@ transactional_command, ) from tests.utils import ( - MinosSagaTestCase, + SagaTestCase, ) @@ -30,7 +30,7 @@ async def _fn(request: Request) -> Response: Raw = namedtuple("Raw", ["headers", "content"]) -class TestMiddleware(MinosSagaTestCase): +class TestMiddleware(SagaTestCase): async def test_transactional_command_unused(self): # noinspection PyTypeChecker request = BrokerRequest(Raw({"transactions": None}, "foo")) diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_services.py b/packages/core/minos-microservice-saga/tests/test_saga/test_services.py index 30dfc76dc..98c2f2196 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_services.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_services.py @@ -24,11 +24,11 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - MinosSagaTestCase, + SagaTestCase, ) -class TestSagaService(MinosSagaTestCase): +class TestSagaService(SagaTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_utils.py b/packages/core/minos-microservice-saga/tests/test_saga/test_utils.py index f5ed045c0..e9d6c04d8 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_utils.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_utils.py @@ -7,11 +7,11 @@ get_service_name, ) from tests.utils import ( - MinosSagaTestCase, + SagaTestCase, ) -class TestUtils(MinosSagaTestCase): +class TestUtils(SagaTestCase): def test_get_service_name(self): self.assertEqual("order", get_service_name()) diff --git a/packages/core/minos-microservice-saga/tests/utils.py b/packages/core/minos-microservice-saga/tests/utils.py index dfa2af534..7cf3cf6a9 100644 --- a/packages/core/minos-microservice-saga/tests/utils.py +++ b/packages/core/minos-microservice-saga/tests/utils.py @@ -41,7 +41,7 @@ DB_PATH = BASE_PATH / "test_db.lmdb" -class MinosSagaTestCase(MinosTestCase): +class SagaTestCase(MinosTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def get_injections(self): From f81e988b444988e17cab5ba718d1ec4f1d2fc113 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 12:12:48 +0200 Subject: [PATCH 100/324] ISSUE #346 * Rename `MinosTestCase` as `CommonTestCase`. --- packages/core/minos-microservice-aggregate/tests/utils.py | 4 ++-- .../core/minos-microservice-common/minos/common/testing.py | 4 ++-- packages/core/minos-microservice-saga/tests/utils.py | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 891da9776..a25b0234b 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -35,7 +35,7 @@ PoolFactory, ) from minos.common.testing import ( - MinosTestCase, + CommonTestCase, ) from minos.networks import ( BrokerClientPool, @@ -47,7 +47,7 @@ CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" -class AggregateTestCase(MinosTestCase, ABC): +class AggregateTestCase(CommonTestCase, ABC): CONFIG_FILE_PATH = CONFIG_FILE_PATH def get_injections(self): diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index e4ad52227..3dd605b11 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -28,7 +28,7 @@ ) -class MinosTestCase(unittest.IsolatedAsyncioTestCase): +class CommonTestCase(unittest.IsolatedAsyncioTestCase): CONFIG_FILE_PATH: Path def setUp(self) -> None: @@ -63,7 +63,7 @@ def __getattr__(self, item): raise AttributeError -class PostgresAsyncTestCase(MinosTestCase): +class PostgresAsyncTestCase(CommonTestCase): def setUp(self): self._uuid = uuid4() diff --git a/packages/core/minos-microservice-saga/tests/utils.py b/packages/core/minos-microservice-saga/tests/utils.py index 7cf3cf6a9..2b15beada 100644 --- a/packages/core/minos-microservice-saga/tests/utils.py +++ b/packages/core/minos-microservice-saga/tests/utils.py @@ -22,7 +22,7 @@ SetupMixin, ) from minos.common.testing import ( - MinosTestCase, + CommonTestCase, ) from minos.networks import ( BrokerClientPool, @@ -41,7 +41,7 @@ DB_PATH = BASE_PATH / "test_db.lmdb" -class SagaTestCase(MinosTestCase): +class SagaTestCase(CommonTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def get_injections(self): From 0dc445aa97ea7ecb9d2456a2117cc7d5e244275f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 12:17:08 +0200 Subject: [PATCH 101/324] ISSUE #346 * Reformat code. --- .../test_entities/test_models/test_root/test_base.py | 2 +- .../test_entities/test_models/test_root/test_broker.py | 2 +- .../test_entities/test_models/test_root/test_differences.py | 2 +- .../test_entities/test_models/test_root/test_not_provided.py | 2 +- .../test_models/test_root/test_with_postgresql.py | 2 +- .../test_aggregate/test_entities/test_refs/test_injectors.py | 2 +- .../tests/test_aggregate/test_events/test_fields.py | 2 +- .../tests/test_aggregate/test_events/test_models.py | 2 +- .../test_aggregate/test_events/test_repositories/test_abc.py | 2 +- .../tests/test_aggregate/test_snapshots/test_entries.py | 2 +- .../tests/test_aggregate/test_snapshots/test_memory.py | 2 +- .../tests/test_aggregate/test_snapshots/test_pg/test_api.py | 2 +- .../test_aggregate/test_snapshots/test_pg/test_readers.py | 2 +- .../test_aggregate/test_snapshots/test_pg/test_writers.py | 2 +- .../tests/test_aggregate/test_transactions/test_entries.py | 2 +- .../test_transactions/test_repositories/test_abc.py | 2 +- .../tests/test_aggregate/test_transactions/test_services.py | 2 +- .../core/minos-microservice-common/minos/common/config/v2.py | 1 + .../minos-microservice-common/minos/common/database/pools.py | 4 +++- .../tests/test_common/test_config/test_v1/test_base.py | 3 ++- .../tests/test_common/test_config/test_v2/test_base.py | 2 +- .../tests/test_common/test_database/test_abc.py | 3 ++- 22 files changed, 26 insertions(+), 21 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_base.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_base.py index f29f54354..455b410d5 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_base.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_base.py @@ -18,8 +18,8 @@ current_datetime, ) from tests.utils import ( - Car, AggregateTestCase, + Car, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_broker.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_broker.py index 3ab2959fd..c9143461a 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_broker.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_broker.py @@ -14,8 +14,8 @@ BrokerMessageV1, ) from tests.utils import ( - Car, AggregateTestCase, + Car, Owner, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_differences.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_differences.py index 203d429a1..0e2f5f1bb 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_differences.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_differences.py @@ -13,8 +13,8 @@ current_datetime, ) from tests.utils import ( - Car, AggregateTestCase, + Car, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_not_provided.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_not_provided.py index 20dea3e5f..bad23aa57 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_not_provided.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_not_provided.py @@ -10,8 +10,8 @@ NotProvidedException, ) from tests.utils import ( - Car, AggregateTestCase, + Car, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py index 497d4ddc0..6de10e234 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py @@ -13,8 +13,8 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - Car, AggregateTestCase, + Car, Order, OrderItem, Review, diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_injectors.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_injectors.py index 2053a601a..c1572f1c2 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_injectors.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_refs/test_injectors.py @@ -12,8 +12,8 @@ ModelType, ) from tests.utils import ( - Car, AggregateTestCase, + Car, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_fields.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_fields.py index 153fca955..333d8705a 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_fields.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_fields.py @@ -25,8 +25,8 @@ ModelType, ) from tests.utils import ( - Car, AggregateTestCase, + Car, Owner, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_models.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_models.py index e3e22e64c..b1b2de705 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_models.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_models.py @@ -19,8 +19,8 @@ current_datetime, ) from tests.utils import ( - Car, AggregateTestCase, + Car, Owner, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py index 519b502a0..19e0d76af 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py @@ -41,9 +41,9 @@ BrokerMessageV1, ) from tests.utils import ( + AggregateTestCase, FakeAsyncIterator, FakeLock, - AggregateTestCase, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py index 3939ade7e..a3408b759 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py @@ -13,8 +13,8 @@ SnapshotEntry, ) from tests.utils import ( - Car, AggregateTestCase, + Car, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py index e14a877f0..d0a5887a0 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py @@ -24,8 +24,8 @@ NotProvidedException, ) from tests.utils import ( - Car, AggregateTestCase, + Car, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py index a580c5544..10d39d063 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py @@ -21,8 +21,8 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - FakeAsyncIterator, AggregateTestCase, + FakeAsyncIterator, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py index 08460edb7..f6af35893 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py @@ -26,8 +26,8 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - Car, AggregateTestCase, + Car, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py index 95796e79c..f2c2f6199 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py @@ -34,8 +34,8 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - Car, AggregateTestCase, + Car, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py index 6f3188331..32eb6d7fd 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py @@ -23,8 +23,8 @@ NULL_UUID, ) from tests.utils import ( - FakeAsyncIterator, AggregateTestCase, + FakeAsyncIterator, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py index 9fa530d36..56f4013c5 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_abc.py @@ -25,9 +25,9 @@ SetupMixin, ) from tests.utils import ( + AggregateTestCase, FakeAsyncIterator, FakeLock, - AggregateTestCase, ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py index d7c60b3db..f1ed225cd 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py @@ -32,8 +32,8 @@ ) from tests.utils import ( CONFIG_FILE_PATH, - FakeAsyncIterator, AggregateTestCase, + FakeAsyncIterator, ) diff --git a/packages/core/minos-microservice-common/minos/common/config/v2.py b/packages/core/minos-microservice-common/minos/common/config/v2.py index 43addf001..fac0436a5 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v2.py +++ b/packages/core/minos-microservice-common/minos/common/config/v2.py @@ -151,6 +151,7 @@ def _get_pools(self) -> dict[str, type]: from ..pools import ( PoolFactory, ) + factory = PoolFactory try: diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index d34520f67..e7837c253 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -21,7 +21,9 @@ OperationalError, ) -from ..injections import Injectable +from ..injections import ( + Injectable, +) from ..locks import ( LockPool, ) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py index 1f24377ea..4285a98e8 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py @@ -6,7 +6,8 @@ from minos.common import ( Config, ConfigV1, - MinosConfigException, PoolFactory, + MinosConfigException, + PoolFactory, ) from tests.utils import ( BASE_PATH, diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py index de818ffa0..7518a3b83 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py @@ -144,7 +144,7 @@ def test_pools(self): "broker": FakeBrokerClientPool, "database": FakeDatabasePool, "lock": FakeLockPool, - } + }, } self.assertEqual(expected, self.config.get_pools()) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index e81a7bdd9..3814eec78 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -6,7 +6,8 @@ from minos.common import ( DatabaseClientPool, DatabaseMixin, - DependencyInjector, PoolFactory, + DependencyInjector, + PoolFactory, ) from minos.common.testing import ( PostgresAsyncTestCase, From c69ce6ef7452b392eed762738a829e55b2268c4f Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Mon, 4 Apr 2022 12:33:59 +0200 Subject: [PATCH 102/324] ISSUE #363 --- .../plugins/minos-discovery-kong/README.md | 37 +++++++++++++++++-- 1 file changed, 34 insertions(+), 3 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/README.md b/packages/plugins/minos-discovery-kong/README.md index 436d42909..f411085ea 100644 --- a/packages/plugins/minos-discovery-kong/README.md +++ b/packages/plugins/minos-discovery-kong/README.md @@ -19,7 +19,7 @@ Minos Kong is a plugin that integrate minos micorservices with Kong API Gateway Install the dependency: ```shell -pip install minos-kong +pip install minos-discovery-kong ``` Modify `config.yml` file: @@ -28,12 +28,43 @@ Modify `config.yml` file: ... discovery: connector: minos.networks.DiscoveryConnector - client: minos.plugins.minos_kong.MinosKongClient + client: minos.plugins.kong.KongDiscoveryClient host: localhost - port: 5567 + port: 8001 ... ``` +## How to +The above configuration is sufficient for the microservice to subscribe on startup and unsubscribe on shutdown. +Therefore, all you would have to do would be to make your requests against: + +`http://localhost:8000/your_endpoint` + +## Kong official documentation +### Official docs +You can get read the official docs [here](https://docs.konghq.com/gateway/2.8.x/admin-api/). + +### Postman + +You can get the official postman collection for postman [here](https://documenter.getpostman.com/view/10587735/SzS7QS2c#intro). + +## Konga - Administrative interface +For development purposes you can add open-source administrative section by using next docker service: +```yaml +services: + ... + konga: + image: pantsel/konga + ports: + - 1337:1337 + links: + - kong:kong + container_name: konga + environment: + - NODE_ENV=production +``` + +You can get read the official docs [here](https://pantsel.github.io/konga/). ## Documentation The official API Reference is publicly available at the [GitHub Pages](https://minos-framework.github.io/minos-python). From 9a31859deee89fa30ce992fc16d1dcceacecfc6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 12:46:53 +0200 Subject: [PATCH 103/324] ISSUE #346 * Improve tests. --- .../test_root/test_with_postgresql.py | 3 --- .../test_snapshots/test_pg/test_abc.py | 3 --- .../test_snapshots/test_pg/test_api.py | 3 --- .../test_snapshots/test_pg/test_queries.py | 6 ++--- .../test_snapshots/test_pg/test_readers.py | 3 --- .../test_snapshots/test_pg/test_writers.py | 3 --- .../test_snapshots/test_services.py | 3 --- .../test_repositories/test_pg.py | 5 ----- .../test_transactions/test_services.py | 3 --- .../tests/utils.py | 7 +++--- .../minos/common/testing.py | 22 ++++++++++++++----- .../test_config/test_v1/test_base.py | 1 - .../test_config/test_v2/test_parameterized.py | 3 --- .../test_common/test_database/test_abc.py | 8 ++----- .../test_common/test_database/test_locks.py | 6 ++--- .../test_common/test_database/test_pools.py | 10 +++------ .../tests/test_common/test_launchers.py | 5 ++--- .../minos-microservice-common/tests/utils.py | 8 +++++++ .../test_brokers/test_clients.py | 6 ++--- .../test_collections/test_queues/test_pg.py | 6 ++--- .../test_dispatchers/test_impl.py | 6 ++--- .../test_brokers/test_handlers/test_ports.py | 10 ++++----- .../test_networks/test_brokers/test_pools.py | 6 ++--- .../test_queued/test_queues/test_pg.py | 6 ++--- .../test_duplicates/test_pg.py | 6 ++--- .../test_queued/test_queues/test_pg.py | 10 +++------ .../test_discovery/test_connectors.py | 13 +++++------ .../test_scheduling/test_ports.py | 10 ++++----- .../tests/utils.py | 11 ++++++++++ .../minos-microservice-saga/tests/utils.py | 7 +++--- 30 files changed, 84 insertions(+), 115 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py index 6de10e234..e2fc15abb 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py @@ -12,7 +12,6 @@ PostgresAsyncTestCase, ) from tests.utils import ( - CONFIG_FILE_PATH, AggregateTestCase, Car, Order, @@ -22,8 +21,6 @@ class TestExternalEntityWithPostgreSql(AggregateTestCase, PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - def setUp(self): super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py index 8f0d839fd..655ec8c7b 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py @@ -9,14 +9,11 @@ PostgresAsyncTestCase, ) from tests.utils import ( - CONFIG_FILE_PATH, AggregateTestCase, ) class TestPostgreSqlSnapshotSetup(AggregateTestCase, PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - async def test_setup_snapshot_table(self): async with PostgreSqlSnapshotSetup.from_config(self.config): async with aiopg.connect(**self.snapshot_db) as connection: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py index 10d39d063..0fb1c6245 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py @@ -20,15 +20,12 @@ PostgresAsyncTestCase, ) from tests.utils import ( - CONFIG_FILE_PATH, AggregateTestCase, FakeAsyncIterator, ) class TestPostgreSqlSnapshotRepository(AggregateTestCase, PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py index 6c60efd9c..f6ad4cbfb 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py @@ -34,13 +34,11 @@ PostgresAsyncTestCase, ) from tests.utils import ( - CONFIG_FILE_PATH, + AggregateTestCase, ) -class TestPostgreSqlSnapshotQueryBuilder(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestPostgreSqlSnapshotQueryBuilder(AggregateTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.classname = "path.to.Product" diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py index f6af35893..6ffe0cdcf 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py @@ -25,15 +25,12 @@ PostgresAsyncTestCase, ) from tests.utils import ( - CONFIG_FILE_PATH, AggregateTestCase, Car, ) class TestPostgreSqlSnapshotReader(AggregateTestCase, PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py index f2c2f6199..811d3448c 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py @@ -33,15 +33,12 @@ PostgresAsyncTestCase, ) from tests.utils import ( - CONFIG_FILE_PATH, AggregateTestCase, Car, ) class TestPostgreSqlSnapshotWriter(AggregateTestCase, PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - def setUp(self) -> None: super().setUp() self.uuid_1 = uuid4() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py index 40b1c9d0f..3afa310bd 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py @@ -26,7 +26,6 @@ ResponseException, ) from tests.utils import ( - CONFIG_FILE_PATH, AggregateTestCase, Order, ) @@ -35,8 +34,6 @@ class TestSnapshotService(AggregateTestCase, PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index a5a6100a6..783d9dec3 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -19,14 +19,11 @@ PostgresAsyncTestCase, ) from tests.utils import ( - CONFIG_FILE_PATH, AggregateTestCase, ) class TestPostgreSqlTransactionRepository(AggregateTestCase, PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - def setUp(self) -> None: super().setUp() @@ -154,8 +151,6 @@ async def test_submit_rejected_raises(self): class TestPostgreSqlTransactionRepositorySelect(AggregateTestCase, PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - def setUp(self) -> None: super().setUp() self.uuid_1 = uuid4() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py index f1ed225cd..06315bde2 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py @@ -31,15 +31,12 @@ ResponseException, ) from tests.utils import ( - CONFIG_FILE_PATH, AggregateTestCase, FakeAsyncIterator, ) class TestSnapshotService(AggregateTestCase, PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index a25b0234b..1c18b0b79 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -35,7 +35,7 @@ PoolFactory, ) from minos.common.testing import ( - CommonTestCase, + MinosTestCase, ) from minos.networks import ( BrokerClientPool, @@ -47,8 +47,9 @@ CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" -class AggregateTestCase(CommonTestCase, ABC): - CONFIG_FILE_PATH = CONFIG_FILE_PATH +class AggregateTestCase(MinosTestCase, ABC): + def get_config_file_path(self): + return CONFIG_FILE_PATH def get_injections(self): pool_factory = PoolFactory.from_config( diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index 3dd605b11..09f15111b 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -1,4 +1,8 @@ import unittest +import warnings +from abc import ( + ABC, +) from itertools import ( starmap, ) @@ -28,7 +32,7 @@ ) -class CommonTestCase(unittest.IsolatedAsyncioTestCase): +class MinosTestCase(unittest.IsolatedAsyncioTestCase, ABC): CONFIG_FILE_PATH: Path def setUp(self) -> None: @@ -40,7 +44,15 @@ def setUp(self) -> None: def get_config(self): """ "TODO""" - return Config(self.CONFIG_FILE_PATH) + return Config(self.get_config_file_path()) + + def get_config_file_path(self) -> Path: + """TODO""" + warnings.warn( + "`CONFIG_FILE_PATH` variable has been deprecated by `get_config_file_path` method", + DeprecationWarning, + ) + return self.CONFIG_FILE_PATH def get_injections(self): return [] @@ -63,11 +75,11 @@ def __getattr__(self, item): raise AttributeError -class PostgresAsyncTestCase(CommonTestCase): +class PostgresAsyncTestCase(MinosTestCase, ABC): def setUp(self): self._uuid = uuid4() - self._config = Config(self.CONFIG_FILE_PATH) + self._config = Config(self.get_config_file_path()) self._meta_repository_db = self._config.get_database_by_name("aggregate") @@ -85,7 +97,7 @@ def setUp(self): def get_config(self): return Config( - self.CONFIG_FILE_PATH, + self.get_config_file_path(), repository_database=self.repository_db["database"], repository_user=self.repository_db["user"], broker_queue_database=self.broker_queue_db["database"], diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py index 4285a98e8..f73eb24dc 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py @@ -7,7 +7,6 @@ Config, ConfigV1, MinosConfigException, - PoolFactory, ) from tests.utils import ( BASE_PATH, diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py index c8fca6c71..742773958 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_parameterized.py @@ -10,15 +10,12 @@ ) from tests.utils import ( BASE_PATH, - FakeBrokerClientPool, FakeBrokerPublisher, FakeBrokerSubscriber, FakeBrokerSubscriberBuilder, FakeCustomInjection, - FakeDatabasePool, FakeDiscoveryConnector, FakeEventRepository, - FakeLockPool, FakeSagaManager, FakeSnapshotRepository, FakeTransactionRepository, diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index 3814eec78..2bb3779b9 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -1,4 +1,3 @@ -import sys import unittest import aiopg @@ -6,21 +5,18 @@ from minos.common import ( DatabaseClientPool, DatabaseMixin, - DependencyInjector, PoolFactory, ) from minos.common.testing import ( PostgresAsyncTestCase, ) from tests.utils import ( - CONFIG_FILE_PATH, + CommonTestCase, ) # noinspection SqlNoDataSourceInspection -class TestDatabaseMixin(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestDatabaseMixin(CommonTestCase, PostgresAsyncTestCase): def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) database = DatabaseMixin(pool) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py index a8de481ad..4721438d6 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py @@ -13,13 +13,11 @@ PostgresAsyncTestCase, ) from tests.utils import ( - CONFIG_FILE_PATH, + CommonTestCase, ) -class TestPostgreSqlLock(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestPostgreSqlLock(CommonTestCase, PostgresAsyncTestCase): def test_base(self): self.assertTrue(issubclass(DatabaseLock, Lock)) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index 7095de548..945118a88 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -21,13 +21,11 @@ PostgresAsyncTestCase, ) from tests.utils import ( - CONFIG_FILE_PATH, + CommonTestCase, ) -class TestPostgreSqlPool(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestPostgreSqlPool(CommonTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.pool = DatabaseClientPool.from_config(self.config) @@ -82,9 +80,7 @@ def _side_effect(*args, **kwargs): self.assertIsInstance(connection, Connection) -class TestPostgreSqlLockPool(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestPostgreSqlLockPool(CommonTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.pool = DatabaseLockPool.from_config(self.config) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_launchers.py b/packages/core/minos-microservice-common/tests/test_common/test_launchers.py index 14a42a639..39d010cf1 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_launchers.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_launchers.py @@ -20,6 +20,7 @@ ) from tests.utils import ( CONFIG_FILE_PATH, + CommonTestCase, FakeEntrypoint, FakeLoop, ) @@ -39,9 +40,7 @@ async def _stop(self, err: Exception = None) -> None: """For testing purposes.""" -class TestEntrypointLauncher(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestEntrypointLauncher(CommonTestCase, PostgresAsyncTestCase): def setUp(self): super().setUp() self.injections = list() diff --git a/packages/core/minos-microservice-common/tests/utils.py b/packages/core/minos-microservice-common/tests/utils.py index e7b4ea6fe..b1107a06c 100644 --- a/packages/core/minos-microservice-common/tests/utils.py +++ b/packages/core/minos-microservice-common/tests/utils.py @@ -10,11 +10,19 @@ LockPool, Port, ) +from minos.common.testing import ( + MinosTestCase, +) BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "config" / "v1.yml" +class CommonTestCase(MinosTestCase): + def get_config_file_path(self) -> Path: + return CONFIG_FILE_PATH + + class FakeEntrypoint: """For testing purposes.""" diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_clients.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_clients.py index 21651fdcc..52ede53ae 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_clients.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_clients.py @@ -24,14 +24,12 @@ MinosHandlerNotFoundEnoughEntriesException, ) from tests.utils import ( - CONFIG_FILE_PATH, FakeModel, + NetworksTestCase, ) -class TestBrokerClient(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestBrokerClient(NetworksTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.topic = "fooReply" diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index e10f62262..52735d889 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -23,7 +23,7 @@ PostgreSqlBrokerQueueQueryFactory, ) from tests.utils import ( - CONFIG_FILE_PATH, + NetworksTestCase, ) @@ -33,9 +33,7 @@ def build_table_name(self) -> str: return "test_table" -class TestPostgreSqlBrokerQueue(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestPostgreSqlBrokerQueue(NetworksTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.query_factory = _PostgreSqlBrokerQueueQueryFactory() diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_dispatchers/test_impl.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_dispatchers/test_impl.py index 9aa6e2ac5..f7224a039 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_dispatchers/test_impl.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_dispatchers/test_impl.py @@ -31,8 +31,8 @@ Response, ) from tests.utils import ( - CONFIG_FILE_PATH, FakeModel, + NetworksTestCase, ) @@ -58,9 +58,7 @@ async def _fn_raises_exception(request: Request) -> Response: raise ValueError -class TestBrokerDispatcher(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestBrokerDispatcher(NetworksTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_handlers/test_ports.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_handlers/test_ports.py index 3d64a9b35..d4f5221ba 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_handlers/test_ports.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_handlers/test_ports.py @@ -18,13 +18,11 @@ InMemoryBrokerSubscriberBuilder, ) from tests.utils import ( - CONFIG_FILE_PATH, + NetworksTestCase, ) -class TestBrokerPort(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestBrokerPort(NetworksTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.publisher = InMemoryBrokerPublisher.from_config(self.config) @@ -66,14 +64,14 @@ async def test_start_stop(self): self.assertEqual(1, destroy_mock.call_count) -class TestBrokerHandlerService(unittest.TestCase): +class TestBrokerHandlerService(NetworksTestCase): def test_is_subclass(self): self.assertTrue(issubclass(BrokerHandlerService, BrokerPort)) def test_warnings(self): with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) - port = BrokerHandlerService(config=CONFIG_FILE_PATH) + port = BrokerHandlerService(config=self.config) self.assertIsInstance(port, BrokerPort) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_pools.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_pools.py index 08c08da7c..020812099 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_pools.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_pools.py @@ -11,13 +11,11 @@ InMemoryBrokerSubscriberBuilder, ) from tests.utils import ( - CONFIG_FILE_PATH, + NetworksTestCase, ) -class TestBrokerClientPool(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestBrokerClientPool(NetworksTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.publisher = InMemoryBrokerPublisher.from_config(self.config) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py index 5f385108b..8118d49cf 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py @@ -10,13 +10,11 @@ PostgreSqlBrokerQueue, ) from tests.utils import ( - CONFIG_FILE_PATH, + NetworksTestCase, ) -class TestPostgreSqlBrokerPublisherQueue(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestPostgreSqlBrokerPublisherQueue(NetworksTestCase, PostgresAsyncTestCase): def test_is_subclass(self): self.assertTrue(issubclass(PostgreSqlBrokerPublisherQueue, (PostgreSqlBrokerQueue, BrokerPublisherQueue))) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py index 7996b8e74..5c294b2d3 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py @@ -11,13 +11,11 @@ PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, ) from tests.utils import ( - CONFIG_FILE_PATH, + NetworksTestCase, ) -class TestPostgreSqlBrokerSubscriberDuplicateValidator(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestPostgreSqlBrokerSubscriberDuplicateValidator(NetworksTestCase, PostgresAsyncTestCase): def test_is_subclass(self): self.assertTrue(issubclass(PostgreSqlBrokerSubscriberDuplicateValidator, BrokerSubscriberValidator)) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py index 013e55830..922467aec 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py @@ -20,13 +20,11 @@ PostgreSqlBrokerSubscriberQueueQueryFactory, ) from tests.utils import ( - CONFIG_FILE_PATH, + NetworksTestCase, ) -class TestPostgreSqlBrokerSubscriberQueue(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestPostgreSqlBrokerSubscriberQueue(NetworksTestCase, PostgresAsyncTestCase): def test_is_subclass(self): self.assertTrue(issubclass(PostgreSqlBrokerSubscriberQueue, (PostgreSqlBrokerQueue, BrokerSubscriberQueue))) @@ -82,9 +80,7 @@ def test_build_table_name(self): self.assertEqual("broker_subscriber_queue", self.factory.build_table_name()) -class TestPostgreSqlBrokerSubscriberQueueBuilder(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestPostgreSqlBrokerSubscriberQueueBuilder(NetworksTestCase, PostgresAsyncTestCase): def test_build(self): builder = PostgreSqlBrokerSubscriberQueueBuilder().with_config(self.config).with_topics({"one", "two"}) subscriber = builder.build() diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py index a709f25f5..78baa5c2d 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py @@ -15,15 +15,14 @@ get_host_ip, ) from tests.utils import ( - CONFIG_FILE_PATH, + NetworksTestCase, ) -class TestDiscoveryConnector(unittest.IsolatedAsyncioTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestDiscoveryConnector(NetworksTestCase): def setUp(self) -> None: - self.config = Config(self.CONFIG_FILE_PATH) + super().setUp() + self.ip = get_host_ip() self.discovery = DiscoveryConnector.from_config(config=self.config) @@ -37,12 +36,12 @@ def test_constructor(self): self.assertEqual(8080, connector.port) def test_config_minos_client_does_not_exist(self): - config = Config(self.CONFIG_FILE_PATH, minos_discovery_client="wrong-client") + config = Config(self.get_config_file_path(), minos_discovery_client="wrong-client") with self.assertRaises(MinosImportException): DiscoveryConnector.from_config(config=config) def test_config_minos_client_not_supported(self): - config = Config(self.CONFIG_FILE_PATH, minos_discovery_client="minos.common.Model") + config = Config(self.get_config_file_path(), minos_discovery_client="minos.common.Model") with self.assertRaises(MinosInvalidDiscoveryClient): DiscoveryConnector.from_config(config) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_scheduling/test_ports.py b/packages/core/minos-microservice-networks/tests/test_networks/test_scheduling/test_ports.py index 04a9833d5..92b1a1234 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_scheduling/test_ports.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_scheduling/test_ports.py @@ -16,13 +16,11 @@ PeriodicTaskSchedulerService, ) from tests.utils import ( - CONFIG_FILE_PATH, + NetworksTestCase, ) -class TestPeriodicPort(PostgresAsyncTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - +class TestPeriodicPort(NetworksTestCase, PostgresAsyncTestCase): def test_is_instance(self): service = PeriodicPort(config=self.config) self.assertIsInstance(service, Port) @@ -64,14 +62,14 @@ async def test_start_stop(self): self.assertEqual(1, destroy_mock.call_count) -class TestPeriodicTaskSchedulerService(unittest.TestCase): +class TestPeriodicTaskSchedulerService(NetworksTestCase): def test_is_subclass(self): self.assertTrue(issubclass(PeriodicTaskSchedulerService, PeriodicPort)) def test_warnings(self): with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) - port = PeriodicTaskSchedulerService(config=CONFIG_FILE_PATH) + port = PeriodicTaskSchedulerService(config=self.config) self.assertIsInstance(port, PeriodicPort) diff --git a/packages/core/minos-microservice-networks/tests/utils.py b/packages/core/minos-microservice-networks/tests/utils.py index bf0e2bea9..c1636a784 100644 --- a/packages/core/minos-microservice-networks/tests/utils.py +++ b/packages/core/minos-microservice-networks/tests/utils.py @@ -1,3 +1,6 @@ +from abc import ( + ABC, +) from datetime import ( timedelta, ) @@ -16,6 +19,9 @@ from minos.common import ( DeclarativeModel, ) +from minos.common.testing import ( + MinosTestCase, +) from minos.networks import ( EnrouteDecorator, HttpConnector, @@ -29,6 +35,11 @@ CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" +class NetworksTestCase(MinosTestCase, ABC): + def get_config_file_path(self): + return CONFIG_FILE_PATH + + @total_ordering class FakeModel(DeclarativeModel): """For testing purposes""" diff --git a/packages/core/minos-microservice-saga/tests/utils.py b/packages/core/minos-microservice-saga/tests/utils.py index 2b15beada..44ba22a74 100644 --- a/packages/core/minos-microservice-saga/tests/utils.py +++ b/packages/core/minos-microservice-saga/tests/utils.py @@ -22,7 +22,7 @@ SetupMixin, ) from minos.common.testing import ( - CommonTestCase, + MinosTestCase, ) from minos.networks import ( BrokerClientPool, @@ -41,8 +41,9 @@ DB_PATH = BASE_PATH / "test_db.lmdb" -class SagaTestCase(CommonTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH +class SagaTestCase(MinosTestCase): + def get_config_file_path(self): + return CONFIG_FILE_PATH def get_injections(self): pool_factory = PoolFactory.from_config( From 00691f5a6f0cd32fbfcb7f10407fa75eb04ee228 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 13:03:40 +0200 Subject: [PATCH 104/324] ISSUE #346 * Increase coverage. --- .../minos/common/testing.py | 31 +++++++++--------- .../tests/test_common/test_testing.py | 32 +++++++++++++++++++ 2 files changed, 47 insertions(+), 16 deletions(-) create mode 100644 packages/core/minos-microservice-common/tests/test_common/test_testing.py diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index 09f15111b..f8dc1694f 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -1,8 +1,10 @@ import unittest -import warnings from abc import ( ABC, ) +from contextlib import ( + suppress, +) from itertools import ( starmap, ) @@ -11,6 +13,7 @@ ) from typing import ( Any, + Union, ) from uuid import ( uuid4, @@ -26,6 +29,7 @@ ) from .injections import ( DependencyInjector, + InjectableMixin, ) from .pools import ( PoolFactory, @@ -42,26 +46,20 @@ def setUp(self) -> None: self.injector = DependencyInjector(self.config, self.get_injections()) self.injector.wire_injections() - def get_config(self): - """ "TODO""" + def get_config(self) -> Config: return Config(self.get_config_file_path()) def get_config_file_path(self) -> Path: - """TODO""" - warnings.warn( - "`CONFIG_FILE_PATH` variable has been deprecated by `get_config_file_path` method", - DeprecationWarning, - ) return self.CONFIG_FILE_PATH - def get_injections(self): + def get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin], str]]: return [] - async def asyncSetUp(self): + async def asyncSetUp(self) -> None: await super().asyncSetUp() await self.injector.setup_injections() - async def asyncTearDown(self): + async def asyncTearDown(self) -> None: await self.injector.destroy_injections() await super().asyncTearDown() @@ -69,10 +67,11 @@ def tearDown(self) -> None: self.injector.unwire_injections() super().tearDown() - def __getattr__(self, item): + def __getattr__(self, item: str) -> Any: if item != "injector": - return getattr(self.injector, item) - raise AttributeError + with suppress(Exception): + return getattr(self.injector, item) + raise AttributeError(f"{type(self).__name__!r} does not contain the {item!r} attribute.") class PostgresAsyncTestCase(MinosTestCase, ABC): @@ -95,7 +94,7 @@ def setUp(self): super().setUp() - def get_config(self): + def get_config(self) -> Config: return Config( self.get_config_file_path(), repository_database=self.repository_db["database"], @@ -106,7 +105,7 @@ def get_config(self): snapshot_user=self.snapshot_db["user"], ) - def get_injections(self): + def get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin], str]]: return [PoolFactory.from_config(self.config, default_classes={"database": DatabaseClientPool})] async def asyncSetUp(self): diff --git a/packages/core/minos-microservice-common/tests/test_common/test_testing.py b/packages/core/minos-microservice-common/tests/test_common/test_testing.py new file mode 100644 index 000000000..815d77d5b --- /dev/null +++ b/packages/core/minos-microservice-common/tests/test_common/test_testing.py @@ -0,0 +1,32 @@ +import unittest + +from minos.common import ( + Config, + DependencyInjector, +) +from minos.common.testing import ( + MinosTestCase, +) +from tests.utils import ( + CONFIG_FILE_PATH, +) + + +class MyMinosTestCase(MinosTestCase): + CONFIG_FILE_PATH = CONFIG_FILE_PATH + + +class TestMinosTestCase(unittest.IsolatedAsyncioTestCase): + def test_config(self): + test_case = MyMinosTestCase() + test_case.setUp() + self.assertIsInstance(test_case.config, Config) + + def test_injector(self): + test_case = MyMinosTestCase() + test_case.setUp() + self.assertIsInstance(test_case.injector, DependencyInjector) + + +if __name__ == "__main__": + unittest.main() From 28479cf7044e4468fa217d9d618eab3369877608 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 13:31:43 +0200 Subject: [PATCH 105/324] ISSUE #346 * Refactor `PostgresAsyncTestCase`. --- .../test_events/test_repositories/test_pg.py | 12 ++-- .../test_snapshots/test_pg/test_abc.py | 4 +- .../test_snapshots/test_pg/test_queries.py | 2 +- .../test_repositories/test_pg.py | 6 +- .../minos/common/testing.py | 63 +++++++++---------- .../tests/test_common/test_config/test_abc.py | 17 +++-- .../test_common/test_database/test_abc.py | 4 +- .../test_common/test_database/test_locks.py | 10 +-- .../tests/test_common/test_launchers.py | 2 +- .../tests/test_common/test_pools.py | 34 ++++++---- .../minos-microservice-common/tests/utils.py | 2 +- 11 files changed, 83 insertions(+), 73 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index a920f832c..2f4440f98 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -21,9 +21,10 @@ class TestPostgreSqlEventRepositorySubmit(EventRepositorySubmitTestCase, PostgresAsyncTestCase): __test__ = True - def build_event_repository(self) -> EventRepository: + @staticmethod + def build_event_repository() -> EventRepository: """Fort testing purposes.""" - return PostgreSqlEventRepository(**self.repository_db) + return PostgreSqlEventRepository() def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) @@ -41,7 +42,7 @@ def test_from_config(self): self.assertEqual(repository_config["port"], repository.port) async def test_setup(self): - async with aiopg.connect(**self.repository_db) as connection: + async with aiopg.connect(**self.config.get_default_database()) as connection: async with connection.cursor() as cursor: await cursor.execute( "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_event');" @@ -53,9 +54,10 @@ async def test_setup(self): class TestPostgreSqlRepositorySelect(EventRepositorySelectTestCase, PostgresAsyncTestCase): __test__ = True - def build_event_repository(self) -> EventRepository: + @staticmethod + def build_event_repository() -> EventRepository: """Fort testing purposes.""" - return PostgreSqlEventRepository(**self.repository_db) + return PostgreSqlEventRepository() if __name__ == "__main__": diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py index 655ec8c7b..ace68416c 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py @@ -16,7 +16,7 @@ class TestPostgreSqlSnapshotSetup(AggregateTestCase, PostgresAsyncTestCase): async def test_setup_snapshot_table(self): async with PostgreSqlSnapshotSetup.from_config(self.config): - async with aiopg.connect(**self.snapshot_db) as connection: + async with aiopg.connect(**self.config.get_default_database()) as connection: async with connection.cursor() as cursor: await cursor.execute( "SELECT EXISTS (SELECT FROM pg_tables " @@ -27,7 +27,7 @@ async def test_setup_snapshot_table(self): async def test_setup_snapshot_aux_offset_table(self): async with PostgreSqlSnapshotSetup.from_config(self.config): - async with aiopg.connect(**self.snapshot_db) as connection: + async with aiopg.connect(**self.config.get_default_database()) as connection: async with connection.cursor() as cursor: await cursor.execute( "SELECT EXISTS (SELECT FROM pg_tables WHERE " diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py index f6ad4cbfb..d4583827d 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py @@ -426,7 +426,7 @@ async def test_build_complex(self): self.assertEqual(self._flatten_parameters(expected_parameters), self._flatten_parameters(observed[1])) async def _flatten_query(self, query) -> str: - async with aiopg.connect(**self.snapshot_db) as connection: + async with aiopg.connect(**self.config.get_default_database()) as connection: return query.as_string(connection.raw) @staticmethod diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index 783d9dec3..adb59c69c 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -27,7 +27,7 @@ class TestPostgreSqlTransactionRepository(AggregateTestCase, PostgresAsyncTestCa def setUp(self) -> None: super().setUp() - self.transaction_repository = PostgreSqlTransactionRepository(**self.repository_db) + self.transaction_repository = PostgreSqlTransactionRepository() self.uuid = uuid4() @@ -58,7 +58,7 @@ def test_from_config(self): self.assertEqual(repository_config["password"], repository.password) async def test_setup(self): - async with aiopg.connect(**self.repository_db) as connection: + async with aiopg.connect(**self.config.get_default_database()) as connection: async with connection.cursor() as cursor: await cursor.execute( "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_transaction');" @@ -159,7 +159,7 @@ def setUp(self) -> None: self.uuid_4 = uuid4() self.uuid_5 = uuid4() - self.transaction_repository = PostgreSqlTransactionRepository(**self.repository_db) + self.transaction_repository = PostgreSqlTransactionRepository() self.entries = [ TransactionEntry(self.uuid_1, TransactionStatus.PENDING, 12), diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index f8dc1694f..75e28cebd 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -74,50 +74,47 @@ def __getattr__(self, item: str) -> Any: raise AttributeError(f"{type(self).__name__!r} does not contain the {item!r} attribute.") +# noinspection SqlNoDataSourceInspection class PostgresAsyncTestCase(MinosTestCase, ABC): def setUp(self): - - self._uuid = uuid4() self._config = Config(self.get_config_file_path()) + self._uuid = uuid4() + self._test_db = {"database": f"test_db_{self._uuid.hex}", "user": f"test_user_{self._uuid.hex}"} + super().setUp() - self._meta_repository_db = self._config.get_database_by_name("aggregate") + @property + def repository_db(self) -> dict[str, Any]: + return self.config.get_database_by_name("aggregate") | self._test_db - self._meta_broker_queue_db = self._config.get_database_by_name("broker") + @property + def broker_queue_db(self) -> dict[str, Any]: + return self.config.get_database_by_name("broker") | self._test_db - self._meta_snapshot_db = self._config.get_database_by_name("aggregate") + @property + def snapshot_db(self) -> dict[str, Any]: + return self.config.get_database_by_name("aggregate") | self._test_db - self._test_db = {"database": f"test_db_{self._uuid.hex}", "user": f"test_user_{self._uuid.hex}"} + def get_config(self) -> Config: + config = Config(self.get_config_file_path()) - self.repository_db = self._meta_repository_db | self._test_db - self.broker_queue_db = self._meta_broker_queue_db | self._test_db - self.snapshot_db = self._meta_snapshot_db | self._test_db + base_fn = config.get_databases - super().setUp() + def _fn(): + return {k: (v | self._test_db) for k, v in base_fn().items()} - def get_config(self) -> Config: - return Config( - self.get_config_file_path(), - repository_database=self.repository_db["database"], - repository_user=self.repository_db["user"], - broker_queue_database=self.broker_queue_db["database"], - broker_queue_user=self.broker_queue_db["user"], - snapshot_database=self.snapshot_db["database"], - snapshot_user=self.snapshot_db["user"], - ) + config.get_databases = _fn + return config def get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin], str]]: return [PoolFactory.from_config(self.config, default_classes={"database": DatabaseClientPool})] async def asyncSetUp(self): pairs = self._drop_duplicates( - [ - (self._meta_repository_db, self.repository_db), - (self._meta_broker_queue_db, self.broker_queue_db), - (self._meta_snapshot_db, self.snapshot_db), - ] + [(db, self._test_db) for db in self._config.get_databases().values() if "database" in db] ) + for meta, test in pairs: - await self._setup_database(dict(meta), dict(test)) + await self._setup_database(meta, test) async def _setup_database(self, meta: dict[str, Any], test: dict[str, Any]) -> None: await self._teardown_database(meta, test) @@ -125,10 +122,10 @@ async def _setup_database(self, meta: dict[str, Any], test: dict[str, Any]) -> N async with aiopg.connect(**meta) as connection: async with connection.cursor() as cursor: template = "CREATE ROLE {user} WITH SUPERUSER CREATEDB LOGIN ENCRYPTED PASSWORD {password!r};" - await cursor.execute(template.format(**test)) + await cursor.execute(template.format(**(meta | test))) template = "CREATE DATABASE {database} WITH OWNER = {user};" - await cursor.execute(template.format(**test)) + await cursor.execute(template.format(**(meta | test))) await super().asyncSetUp() @@ -136,11 +133,7 @@ async def asyncTearDown(self): await super().asyncTearDown() pairs = self._drop_duplicates( - [ - (self._meta_repository_db, self.repository_db), - (self._meta_broker_queue_db, self.broker_queue_db), - (self._meta_snapshot_db, self.snapshot_db), - ] + [(db, self._test_db) for db in self._config.get_databases().values() if "database" in db] ) for meta, test in pairs: @@ -159,7 +152,7 @@ async def _teardown_database(meta: dict[str, Any], test: dict[str, Any]) -> None async with aiopg.connect(**meta) as connection: async with connection.cursor() as cursor: template = "DROP DATABASE IF EXISTS {database}" - await cursor.execute(template.format(**test)) + await cursor.execute(template.format(**(meta | test))) template = "DROP ROLE IF EXISTS {user};" - await cursor.execute(template.format(**test)) + await cursor.execute(template.format(**(meta | test))) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_abc.py index df62c39e0..f8c6077bf 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_abc.py @@ -18,7 +18,7 @@ MinosConfigException, ) from tests.utils import ( - CONFIG_FILE_PATH, + BASE_PATH, ) @@ -69,7 +69,8 @@ def _get_saga(self) -> dict[str, Any]: class TestConfig(unittest.TestCase): def setUp(self) -> None: super().setUp() - self.config = _Config(CONFIG_FILE_PATH) + self.file_path = BASE_PATH / "config" / "v1.yml" + self.config = _Config(self.file_path) def test_is_subclass(self): self.assertTrue(issubclass(Config, InjectableMixin)) @@ -78,10 +79,10 @@ def test_get_injectable_name(self): self.assertTrue("config", _Config.get_injectable_name()) def test_file_path(self): - self.assertEqual(CONFIG_FILE_PATH, self.config.file_path) + self.assertEqual(self.file_path, self.config.file_path) def test_file_path_from_str(self): - self.assertEqual(CONFIG_FILE_PATH, _Config(str(CONFIG_FILE_PATH)).file_path) + self.assertEqual(self.file_path, _Config(str(self.file_path)).file_path) def test_file_raises(self): with self.assertRaises(MinosConfigException): @@ -215,7 +216,7 @@ def test_get_saga(self): self.assertEqual([call()], mock.call_args_list) def test_new(self): - config = Config(CONFIG_FILE_PATH) + config = Config(self.file_path) self.assertIsInstance(config, ConfigV1) def test_new_raises(self): @@ -224,13 +225,17 @@ def test_new_raises(self): class TestMinosConfig(unittest.TestCase): + def setUp(self) -> None: + super().setUp() + self.file_path = BASE_PATH / "config" / "v1.yml" + def test_is_subclass(self): self.assertTrue(issubclass(MinosConfig, Config)) def test_warnings(self): with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) - config = MinosConfig(CONFIG_FILE_PATH) + config = MinosConfig(self.file_path) self.assertIsInstance(config, Config) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index 2bb3779b9..1d0f54940 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -62,7 +62,7 @@ async def test_submit_query(self): async with DatabaseMixin() as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") - async with aiopg.connect(**self.repository_db) as connection: + async with aiopg.connect(**self.config.get_default_database()) as connection: async with connection.cursor() as cursor: await cursor.execute("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") self.assertTrue((await cursor.fetchone())[0]) @@ -71,7 +71,7 @@ async def test_submit_query_locked(self): async with DatabaseMixin() as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);", lock=1234) - async with aiopg.connect(**self.repository_db) as connection: + async with aiopg.connect(**self.config.get_default_database()) as connection: async with connection.cursor() as cursor: await cursor.execute("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") self.assertTrue((await cursor.fetchone())[0]) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py index 4721438d6..1a834aa24 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py @@ -22,27 +22,27 @@ def test_base(self): self.assertTrue(issubclass(DatabaseLock, Lock)) async def test_wrapped_connection(self): - wrapped_connection = aiopg.connect(**self.repository_db) + wrapped_connection = aiopg.connect(**self.config.get_default_database()) lock = DatabaseLock(wrapped_connection, "foo") self.assertEqual(wrapped_connection, lock.wrapped_connection) async def test_key(self): - wrapped_connection = aiopg.connect(**self.repository_db) + wrapped_connection = aiopg.connect(**self.config.get_default_database()) lock = DatabaseLock(wrapped_connection, "foo") self.assertEqual("foo", lock.key) async def test_key_raises(self): - wrapped_connection = aiopg.connect(**self.repository_db) + wrapped_connection = aiopg.connect(**self.config.get_default_database()) with self.assertRaises(ValueError): DatabaseLock(wrapped_connection, []) async def test_hashed_key(self): - wrapped_connection = aiopg.connect(**self.repository_db) + wrapped_connection = aiopg.connect(**self.config.get_default_database()) lock = DatabaseLock(wrapped_connection, "foo") self.assertEqual(hash("foo"), lock.hashed_key) async def test_cursor(self): - wrapped_connection = aiopg.connect(**self.repository_db) + wrapped_connection = aiopg.connect(**self.config.get_default_database()) async with DatabaseLock(wrapped_connection, "foo") as lock: self.assertIsInstance(lock.cursor, Cursor) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_launchers.py b/packages/core/minos-microservice-common/tests/test_common/test_launchers.py index 39d010cf1..b876792b1 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_launchers.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_launchers.py @@ -59,7 +59,7 @@ def test_from_config(self): launcher = EntrypointLauncher.from_config(self.config) self.assertIsInstance(launcher, EntrypointLauncher) self.assertEqual(self.config, launcher.config) - self.assertEqual(12, len(launcher.injections)) + self.assertEqual(len(self.config.get_injections()), len(launcher.injections)) for injection in launcher.injections.values(): self.assertIsInstance(injection, InjectableMixin) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_pools.py index a31df2f72..154ae89be 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_pools.py @@ -19,22 +19,18 @@ from minos.common import ( MinosPool, Pool, + PoolFactory, SetupMixin, ) +from tests.utils import ( + CommonTestCase, +) -class _Pool(Pool): - def __init__(self): - super().__init__() - self.create_instance_call_count = 0 - self.destroy_instance_call_count = 0 - - async def _create_instance(self): - self.create_instance_call_count += 1 - return "foo" - - async def _destroy_instance(self, instance: t.Any) -> None: - self.destroy_instance_call_count += 1 +class TestPoolFactory(CommonTestCase): + def test_constructor(self): + factory = PoolFactory.from_config(self.config) + self.assertIsInstance(factory, PoolFactory) class TestPool(unittest.IsolatedAsyncioTestCase): @@ -70,6 +66,20 @@ async def _fn2(p): self.assertEqual(1, pool_mock.call_count) +class _Pool(Pool): + def __init__(self): + super().__init__() + self.create_instance_call_count = 0 + self.destroy_instance_call_count = 0 + + async def _create_instance(self): + self.create_instance_call_count += 1 + return "foo" + + async def _destroy_instance(self, instance: t.Any) -> None: + self.destroy_instance_call_count += 1 + + class TestMinosPool(unittest.IsolatedAsyncioTestCase): def test_is_subclass(self): self.assertTrue(issubclass(MinosPool, SetupMixin)) diff --git a/packages/core/minos-microservice-common/tests/utils.py b/packages/core/minos-microservice-common/tests/utils.py index b1107a06c..fb4f622a1 100644 --- a/packages/core/minos-microservice-common/tests/utils.py +++ b/packages/core/minos-microservice-common/tests/utils.py @@ -15,7 +15,7 @@ ) BASE_PATH = Path(__file__).parent -CONFIG_FILE_PATH = BASE_PATH / "config" / "v1.yml" +CONFIG_FILE_PATH = BASE_PATH / "config" / "v2.yml" class CommonTestCase(MinosTestCase): From 6bd67908d7325cc13d6d0ca68aeef821cc841860 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 14:44:11 +0200 Subject: [PATCH 106/324] ISSUE #346 * Fix broken tests. --- .github/workflows/minos-microservice-common-tests.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/minos-microservice-common-tests.yml b/.github/workflows/minos-microservice-common-tests.yml index 637130b43..92e2af7f5 100644 --- a/.github/workflows/minos-microservice-common-tests.yml +++ b/.github/workflows/minos-microservice-common-tests.yml @@ -29,9 +29,8 @@ jobs: options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 env: - MINOS_BROKER_QUEUE_HOST: postgres - MINOS_REPOSITORY_HOST: postgres - MINOS_SNAPSHOT_HOST: postgres + MINOS_DATABASES_DEFAULT_HOST: postgres + MINOS_DATABASES_QUERY_HOST: postgres steps: - name: Check out repository code From 3656a6608920b0486f9ed388749ca73b26158f23 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 15:14:35 +0200 Subject: [PATCH 107/324] ISSUE #346 * Increase coverage. * Fix bug related with `PostgresAsyncTestCase`. --- .../minos/common/pools.py | 4 +- .../minos/common/testing.py | 45 +++------- .../test_common/test_database/test_abc.py | 21 +++++ .../test_common/test_database/test_locks.py | 17 +++- .../test_common/test_database/test_pools.py | 29 ++++++- .../tests/test_common/test_testing.py | 82 ++++++++++++++++++- 6 files changed, 158 insertions(+), 40 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index 80762e6f1..77c9a4991 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -90,7 +90,9 @@ def _get_pool_class(self, type_: str) -> type[Pool]: pool_cls = self._config.get_pools().get(type_) if pool_cls is None: - raise ValueError + raise ValueError( + f"There is not any provided {type!r} to build pools that matches the given type: {type_!r}" + ) return pool_cls diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index 75e28cebd..77512146e 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -1,13 +1,11 @@ import unittest +import warnings from abc import ( ABC, ) from contextlib import ( suppress, ) -from itertools import ( - starmap, -) from pathlib import ( Path, ) @@ -77,21 +75,24 @@ def __getattr__(self, item: str) -> Any: # noinspection SqlNoDataSourceInspection class PostgresAsyncTestCase(MinosTestCase, ABC): def setUp(self): - self._config = Config(self.get_config_file_path()) + self.base_config = Config(self.get_config_file_path()) self._uuid = uuid4() self._test_db = {"database": f"test_db_{self._uuid.hex}", "user": f"test_user_{self._uuid.hex}"} super().setUp() @property def repository_db(self) -> dict[str, Any]: + warnings.warn("'repository_db' attribute has been deprecated.", DeprecationWarning) return self.config.get_database_by_name("aggregate") | self._test_db @property def broker_queue_db(self) -> dict[str, Any]: + warnings.warn("'broker_queue_db' attribute has been deprecated.", DeprecationWarning) return self.config.get_database_by_name("broker") | self._test_db @property def snapshot_db(self) -> dict[str, Any]: + warnings.warn("'snapshot_db' attribute has been deprecated.", DeprecationWarning) return self.config.get_database_by_name("aggregate") | self._test_db def get_config(self) -> Config: @@ -109,15 +110,15 @@ def get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin], s return [PoolFactory.from_config(self.config, default_classes={"database": DatabaseClientPool})] async def asyncSetUp(self): - pairs = self._drop_duplicates( - [(db, self._test_db) for db in self._config.get_databases().values() if "database" in db] - ) + await self._create_database(self.base_config.get_default_database(), self._test_db) + await super().asyncSetUp() - for meta, test in pairs: - await self._setup_database(meta, test) + async def asyncTearDown(self): + await super().asyncTearDown() + await self._drop_database(self.base_config.get_default_database(), self._test_db) - async def _setup_database(self, meta: dict[str, Any], test: dict[str, Any]) -> None: - await self._teardown_database(meta, test) + async def _create_database(self, meta: dict[str, Any], test: dict[str, Any]) -> None: + await self._drop_database(meta, test) async with aiopg.connect(**meta) as connection: async with connection.cursor() as cursor: @@ -127,28 +128,8 @@ async def _setup_database(self, meta: dict[str, Any], test: dict[str, Any]) -> N template = "CREATE DATABASE {database} WITH OWNER = {user};" await cursor.execute(template.format(**(meta | test))) - await super().asyncSetUp() - - async def asyncTearDown(self): - await super().asyncTearDown() - - pairs = self._drop_duplicates( - [(db, self._test_db) for db in self._config.get_databases().values() if "database" in db] - ) - - for meta, test in pairs: - await self._teardown_database(meta, test) - - @staticmethod - def _drop_duplicates(items: list[(dict, dict)]): - items = starmap(lambda a, b: (tuple(a.items()), tuple(b.items())), items) - items = set(items) - items = starmap(lambda a, b: (dict(a), dict(b)), items) - items = list(items) - return items - @staticmethod - async def _teardown_database(meta: dict[str, Any], test: dict[str, Any]) -> None: + async def _drop_database(meta: dict[str, Any], test: dict[str, Any]) -> None: async with aiopg.connect(**meta) as connection: async with connection.cursor() as cursor: template = "DROP DATABASE IF EXISTS {database}" diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index 1d0f54940..2613c602f 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -1,11 +1,14 @@ import unittest +import warnings import aiopg from minos.common import ( DatabaseClientPool, DatabaseMixin, + NotProvidedException, PoolFactory, + PostgreSqlMinosDatabase, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -29,6 +32,11 @@ async def test_constructor_with_pool_factory(self): # noinspection PyUnresolvedReferences self.assertEqual(pool_factory.get_pool("database"), database.pool) + async def test_constructor_raises(self): + with self.assertRaises(NotProvidedException): + # noinspection PyArgumentEqualDefault + DatabaseMixin(pool=None, pool_factory=None) + def test_database(self): pool = DatabaseClientPool.from_config(self.config) database = DatabaseMixin(pool) @@ -113,5 +121,18 @@ async def test_submit_query_and_iter_locked(self): self.assertEqual([(3,), (4,), (5,)], observed) +class TestPostgreSqlMinosDatabase(CommonTestCase, PostgresAsyncTestCase): + def test_is_subclass(self): + self.assertTrue(issubclass(PostgreSqlMinosDatabase, DatabaseMixin)) + + def test_warnings(self): + pool = DatabaseClientPool.from_config(self.config) + + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + database = PostgreSqlMinosDatabase(pool) + self.assertIsInstance(database, DatabaseMixin) + + if __name__ == "__main__": unittest.main() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py index 1a834aa24..d03a33418 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py @@ -1,4 +1,5 @@ import unittest +import warnings import aiopg from aiopg import ( @@ -8,6 +9,7 @@ from minos.common import ( DatabaseLock, Lock, + PostgreSqlLock, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -17,7 +19,7 @@ ) -class TestPostgreSqlLock(CommonTestCase, PostgresAsyncTestCase): +class TestDatabaseLock(CommonTestCase, PostgresAsyncTestCase): def test_base(self): self.assertTrue(issubclass(DatabaseLock, Lock)) @@ -47,5 +49,18 @@ async def test_cursor(self): self.assertIsInstance(lock.cursor, Cursor) +class TestPostgreSqlLock(CommonTestCase, PostgresAsyncTestCase): + def test_is_subclass(self): + self.assertTrue(issubclass(PostgreSqlLock, DatabaseLock)) + + async def test_warnings(self): + wrapped_connection = aiopg.connect(**self.config.get_default_database()) + + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + lock = PostgreSqlLock(wrapped_connection, "foo") + self.assertIsInstance(lock, DatabaseLock) + + if __name__ == "__main__": unittest.main() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index 945118a88..061f1c118 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -1,4 +1,5 @@ import unittest +import warnings from unittest.mock import ( PropertyMock, patch, @@ -16,6 +17,8 @@ DatabaseClientPool, DatabaseLock, DatabaseLockPool, + PostgreSqlLockPool, + PostgreSqlPool, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -25,7 +28,7 @@ ) -class TestPostgreSqlPool(CommonTestCase, PostgresAsyncTestCase): +class TestDatabaseClientPool(CommonTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.pool = DatabaseClientPool.from_config(self.config) @@ -80,7 +83,18 @@ def _side_effect(*args, **kwargs): self.assertIsInstance(connection, Connection) -class TestPostgreSqlLockPool(CommonTestCase, PostgresAsyncTestCase): +class TestPostgreSqlPool(CommonTestCase, PostgresAsyncTestCase): + def test_is_subclass(self): + self.assertTrue(issubclass(PostgreSqlPool, DatabaseClientPool)) + + def test_warnings(self): + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + pool = PostgreSqlPool.from_config(self.config) + self.assertIsInstance(pool, DatabaseClientPool) + + +class TestDatabaseLockPool(CommonTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.pool = DatabaseLockPool.from_config(self.config) @@ -99,5 +113,16 @@ async def test_acquire(self): self.assertEqual("foo", lock.key) +class TestPostgreSqlLockPool(CommonTestCase, PostgresAsyncTestCase): + def test_is_subclass(self): + self.assertTrue(issubclass(PostgreSqlLockPool, DatabaseLockPool)) + + def test_warnings(self): + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + pool = PostgreSqlLockPool.from_config(self.config) + self.assertIsInstance(pool, DatabaseLockPool) + + if __name__ == "__main__": unittest.main() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_testing.py b/packages/core/minos-microservice-common/tests/test_common/test_testing.py index 815d77d5b..25ba78584 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_testing.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_testing.py @@ -1,4 +1,5 @@ import unittest +import warnings from minos.common import ( Config, @@ -6,16 +7,13 @@ ) from minos.common.testing import ( MinosTestCase, + PostgresAsyncTestCase, ) from tests.utils import ( CONFIG_FILE_PATH, ) -class MyMinosTestCase(MinosTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - - class TestMinosTestCase(unittest.IsolatedAsyncioTestCase): def test_config(self): test_case = MyMinosTestCase() @@ -28,5 +26,81 @@ def test_injector(self): self.assertIsInstance(test_case.injector, DependencyInjector) +class MyMinosTestCase(MinosTestCase): + CONFIG_FILE_PATH = CONFIG_FILE_PATH + + +class TestPostgresAsyncTestCase(unittest.IsolatedAsyncioTestCase): + def test_repository_db(self): + test_case = MyPostgresAsyncTestCase() + test_case.setUp() + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + self.assertEqual( + { + k: v + for k, v in test_case.base_config.get_database_by_name("aggregate").items() + if k not in {"database", "user"} + }, + {k: v for k, v in test_case.repository_db.items() if k not in {"database", "user"}}, + ) + self.assertNotEqual( + test_case.base_config.get_database_by_name("aggregate")["database"], + test_case.repository_db["database"], + ) + self.assertNotEqual( + test_case.base_config.get_database_by_name("aggregate")["user"], + test_case.repository_db["user"], + ) + + def test_broker_queue_db(self): + test_case = MyPostgresAsyncTestCase() + test_case.setUp() + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + self.assertEqual( + { + k: v + for k, v in test_case.base_config.get_database_by_name("broker").items() + if k not in {"database", "user"} + }, + {k: v for k, v in test_case.broker_queue_db.items() if k not in {"database", "user"}}, + ) + self.assertNotEqual( + test_case.base_config.get_database_by_name("broker")["database"], + test_case.broker_queue_db["database"], + ) + self.assertNotEqual( + test_case.base_config.get_database_by_name("broker")["user"], + test_case.broker_queue_db["user"], + ) + + def test_snapshot_db(self): + test_case = MyPostgresAsyncTestCase() + test_case.setUp() + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + self.assertEqual( + { + k: v + for k, v in test_case.base_config.get_database_by_name("aggregate").items() + if k not in {"database", "user"} + }, + {k: v for k, v in test_case.snapshot_db.items() if k not in {"database", "user"}}, + ) + self.assertNotEqual( + test_case.base_config.get_database_by_name("aggregate")["database"], + test_case.broker_queue_db["database"], + ) + self.assertNotEqual( + test_case.base_config.get_database_by_name("aggregate")["user"], + test_case.broker_queue_db["user"], + ) + + +class MyPostgresAsyncTestCase(PostgresAsyncTestCase): + CONFIG_FILE_PATH = CONFIG_FILE_PATH + + if __name__ == "__main__": unittest.main() From 0aca88fc60be02a863a71dd892d4f3cd21171091 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 15:25:24 +0200 Subject: [PATCH 108/324] ISSUE #346 * Minor improvements. --- .../minos/common/config/v2.py | 14 ++++++-------- .../test_common/test_config/test_v2/test_base.py | 7 +++---- 2 files changed, 9 insertions(+), 12 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/config/v2.py b/packages/core/minos-microservice-common/minos/common/config/v2.py index fac0436a5..6a3fa4238 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v2.py +++ b/packages/core/minos-microservice-common/minos/common/config/v2.py @@ -148,21 +148,19 @@ def _parse_periodic_interface(data: dict[str, Any]) -> dict[str, Any]: return data def _get_pools(self) -> dict[str, type]: - from ..pools import ( - PoolFactory, - ) - - factory = PoolFactory - try: types = self.get_by_key("pools") except MinosConfigException: - types = dict() + return dict() types = {name: import_module(classname) for name, classname in types.items()} + from ..pools import ( + PoolFactory, + ) + return { - "factory": factory, + "factory": PoolFactory, "types": types, } diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py index 7518a3b83..ff0d2bc8d 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py @@ -70,9 +70,9 @@ def test_injections(self): ] self.assertEqual(expected, self.config.get_injections()) - def test_injections_not_defined(self): # FIXME + def test_injections_not_defined(self): with patch.object(ConfigV2, "get_by_key", side_effect=MinosConfigException("")): - self.assertEqual([PoolFactory], self.config.get_injections()) + self.assertEqual(list(), self.config.get_injections()) def test_injections_not_injectable(self): with patch.object(ConfigV2, "_get_pools", return_value={"factory": int}): @@ -149,9 +149,8 @@ def test_pools(self): self.assertEqual(expected, self.config.get_pools()) def test_pools_not_defined(self): - expected = {"factory": PoolFactory, "types": {}} with patch.object(ConfigV2, "get_by_key", side_effect=MinosConfigException("")): - self.assertEqual(expected, self.config.get_pools()) + self.assertEqual(dict(), self.config.get_pools()) def test_services(self): self.assertEqual([float, int], self.config.get_services()) From 72d290709e39ea47b2a9eabc707e119f81a354ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 16:27:50 +0200 Subject: [PATCH 109/324] ISSUE #346 * Increase coverage. --- .../minos/common/pools.py | 4 +-- .../tests/test_common/test_pools.py | 34 +++++++++++++++++-- 2 files changed, 33 insertions(+), 5 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index 77c9a4991..c66ec5423 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -79,11 +79,11 @@ def get_pool(self, type_: str, key: Optional[str] = None, **kwargs) -> Pool: def _create_pool(self, type_: str, **kwargs) -> Pool: # noinspection PyTypeChecker - pool_cls = self._get_pool_class(type_) + pool_cls = self._get_pool_cls(type_) pool = pool_cls.from_config(self._config, **kwargs) return pool - def _get_pool_class(self, type_: str) -> type[Pool]: + def _get_pool_cls(self, type_: str) -> type[Pool]: pool_cls = self._default_classes.get(type_) if pool_cls is None: diff --git a/packages/core/minos-microservice-common/tests/test_common/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_pools.py index 154ae89be..b1bfbc03e 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_pools.py @@ -24,13 +24,41 @@ ) from tests.utils import ( CommonTestCase, + FakeLockPool, ) class TestPoolFactory(CommonTestCase): - def test_constructor(self): - factory = PoolFactory.from_config(self.config) - self.assertIsInstance(factory, PoolFactory) + + def setUp(self): + super().setUp() + self.factory = PoolFactory(self.config, {"lock": FakeLockPool}) + + def test_from_config(self): + self.assertIsInstance(PoolFactory.from_config(self.config), PoolFactory) + + async def asyncTearDown(self): + await self.factory.destroy() + await super().asyncTearDown() + + def test_get_pool(self): + lock = self.factory.get_pool("lock") + self.assertIsInstance(lock, FakeLockPool) + self.assertEqual(lock, self.factory.get_pool("lock")) + + def test_get_pool_with_key(self): + lock_a = self.factory.get_pool("lock", "a") + lock_b = self.factory.get_pool("lock", "b") + self.assertIsInstance(lock_a, FakeLockPool) + self.assertIsInstance(lock_b, FakeLockPool) + + self.assertNotEqual(lock_a, lock_b) + self.assertEqual(lock_a, self.factory.get_pool("lock", "a")) + self.assertEqual(lock_b, self.factory.get_pool("lock", "b")) + + def test_get_pool_raises(self): + with self.assertRaises(ValueError): + self.factory.get_pool("something") class TestPool(unittest.IsolatedAsyncioTestCase): From d956d1bca7dbc4b4baff59f7c7d4d5fc0c3d652b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 16:32:25 +0200 Subject: [PATCH 110/324] ISSUE #346 * Add missing docstring. --- .../minos/common/database/abc.py | 2 +- .../minos/common/database/locks.py | 2 +- .../minos/common/database/pools.py | 6 +++--- .../minos-microservice-common/minos/common/pools.py | 12 ++++++------ .../tests/test_common/test_pools.py | 1 - 5 files changed, 11 insertions(+), 12 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 219f3ba26..84b6e2ca5 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -219,7 +219,7 @@ def pool(self) -> DatabaseClientPool: class PostgreSqlMinosDatabase(DatabaseMixin): - """TODO""" + """PostgreSql Minos Database class.""" def __init__(self, *args, **kwargs): warnings.warn( diff --git a/packages/core/minos-microservice-common/minos/common/database/locks.py b/packages/core/minos-microservice-common/minos/common/database/locks.py index 09fdfe8ab..842798c5b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks.py @@ -48,7 +48,7 @@ async def __aexit__(self, exc_type, exc_val, exc_tb): class PostgreSqlLock(DatabaseLock): - """TODO""" + """PostgreSql Lock class.""" def __init__(self, *args, **kwargs): warnings.warn(f"{PostgreSqlLock!r} has been deprecated. Use {DatabaseLock} instead.", DeprecationWarning) diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index e7837c253..9a6d4d41e 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -102,8 +102,9 @@ async def _check_instance(self, instance: Optional[Connection]) -> bool: return not instance.closed +@Injectable("postgresql_pool") class PostgreSqlPool(DatabaseClientPool): - """TODO""" + """PostgreSql Pool class.""" def __init__(self, *args, **kwargs): warnings.warn(f"{PostgreSqlPool!r} has been deprecated. Use {DatabaseClientPool} instead.", DeprecationWarning) @@ -122,9 +123,8 @@ def acquire(self, key: Hashable, *args, **kwargs) -> DatabaseLock: return DatabaseLock(super().acquire(), key, *args, **kwargs) -@Injectable("postgresql_pool") class PostgreSqlLockPool(DatabaseLockPool): - """TODO""" + """PostgreSql Lock Pool class""" def __init__(self, *args, **kwargs): warnings.warn( diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index c66ec5423..140469d07 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -41,7 +41,7 @@ @Injectable("pool_factory") class PoolFactory(SetupMixin): - """TODO""" + """Pool Factory class.""" _pools: dict[str, Pool] @@ -64,12 +64,12 @@ async def _destroy(self) -> None: await super()._destroy() def get_pool(self, type_: str, key: Optional[str] = None, **kwargs) -> Pool: - """TODO + """Get a pool from the factory. - :param type_: TODO - :param key: TODO - :param kwargs: TODO - :return: TODO + :param type_: The type of the pool. + :param key: An optional key that identifies the pool. + :param kwargs: Additional named arguments. + :return: A ``Pool`` instance. """ if key is None: key = type_ diff --git a/packages/core/minos-microservice-common/tests/test_common/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_pools.py index b1bfbc03e..dbd6dea4e 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_pools.py @@ -29,7 +29,6 @@ class TestPoolFactory(CommonTestCase): - def setUp(self): super().setUp() self.factory = PoolFactory(self.config, {"lock": FakeLockPool}) From 6115bba093020913779efac8d65cded837793e3a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 16:55:34 +0200 Subject: [PATCH 111/324] ISSUE #346 * Add retro-compatibility. --- .../minos/common/database/abc.py | 23 +++++++++--- .../minos/common/pools.py | 2 +- .../test_common/test_database/test_abc.py | 37 ++++++++++++++++--- 3 files changed, 49 insertions(+), 13 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 84b6e2ca5..0419c8bdc 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -33,6 +33,7 @@ ) from .pools import ( DatabaseClientPool, + PostgreSqlPool, ) @@ -42,19 +43,24 @@ class DatabaseMixin(SetupMixin): @Inject() def __init__( self, - pool: Optional[DatabaseClientPool] = None, + database_pool: Optional[DatabaseClientPool] = None, pool_factory: Optional[PoolFactory] = None, + postgresql_pool: Optional[PostgreSqlPool] = None, *args, **kwargs, ): super().__init__(*args, **kwargs, pool_factory=pool_factory) - if pool is None and pool_factory is not None: - pool = pool_factory.get_pool("database") + if database_pool is None and pool_factory is not None: + database_pool = pool_factory.get_pool("database") - if not isinstance(pool, DatabaseClientPool): - raise NotProvidedException(f"A {DatabaseClientPool!r} instance is required. Obtained: {pool}") + if database_pool is None and postgresql_pool is not None: + warnings.warn("'postgresql_pool' argument has been deprecated", DeprecationWarning) + database_pool = postgresql_pool - self._pool = pool + if not isinstance(database_pool, DatabaseClientPool): + raise NotProvidedException(f"A {DatabaseClientPool!r} instance is required. Obtained: {database_pool}") + + self._pool = database_pool @property def database(self) -> str: @@ -62,6 +68,7 @@ def database(self) -> str: :return: A ``str`` value. """ + warnings.warn("'database' has been deprecated. Use 'pool.database' instead.", DeprecationWarning) return self.pool.database @property @@ -70,6 +77,7 @@ def host(self) -> str: :return: A ``str`` value. """ + warnings.warn("'host' has been deprecated. Use 'pool.host' instead.", DeprecationWarning) return self.pool.host @property @@ -78,6 +86,7 @@ def port(self) -> int: :return: An ``int`` value. """ + warnings.warn("'port' has been deprecated. Use 'pool.port' instead.", DeprecationWarning) return self.pool.port @property @@ -86,6 +95,7 @@ def user(self) -> str: :return: A ``str`` value. """ + warnings.warn("'user' has been deprecated. Use 'pool.user' instead.", DeprecationWarning) return self.pool.user @property @@ -94,6 +104,7 @@ def password(self) -> str: :return: A ``str`` value. """ + warnings.warn("'password' has been deprecated. Use 'pool.password' instead.", DeprecationWarning) return self.pool.password async def submit_query_and_fetchone(self, *args, **kwargs) -> tuple: diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index 140469d07..c0f5a78c5 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -87,7 +87,7 @@ def _get_pool_cls(self, type_: str) -> type[Pool]: pool_cls = self._default_classes.get(type_) if pool_cls is None: - pool_cls = self._config.get_pools().get(type_) + pool_cls = self._config.get_pools().get("types", dict()).get(type_) if pool_cls is None: raise ValueError( diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index 2613c602f..df0c70c2e 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -9,6 +9,7 @@ NotProvidedException, PoolFactory, PostgreSqlMinosDatabase, + PostgreSqlPool, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -35,32 +36,56 @@ async def test_constructor_with_pool_factory(self): async def test_constructor_raises(self): with self.assertRaises(NotProvidedException): # noinspection PyArgumentEqualDefault - DatabaseMixin(pool=None, pool_factory=None) + DatabaseMixin(database_pool=None, pool_factory=None) + + async def test_constructor_with_postgresql_pool(self): + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + pool = PostgreSqlPool.from_config(self.config) + # noinspection PyTypeChecker,PyArgumentEqualDefault + database = DatabaseMixin(database_pool=None, pool_factory=None, postgresql_pool=pool) + + self.assertEqual(pool, database.pool) def test_database(self): pool = DatabaseClientPool.from_config(self.config) database = DatabaseMixin(pool) - self.assertEqual(pool.database, database.database) + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + # noinspection PyDeprecation + self.assertEqual(pool.database, database.database) def test_user(self): pool = DatabaseClientPool.from_config(self.config) database = DatabaseMixin(pool) - self.assertEqual(pool.user, database.user) + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + # noinspection PyDeprecation + self.assertEqual(pool.user, database.user) def test_password(self): pool = DatabaseClientPool.from_config(self.config) database = DatabaseMixin(pool) - self.assertEqual(pool.password, database.password) + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + # noinspection PyDeprecation + self.assertEqual(pool.password, database.password) def test_host(self): pool = DatabaseClientPool.from_config(self.config) database = DatabaseMixin(pool) - self.assertEqual(pool.host, database.host) + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + # noinspection PyDeprecation + self.assertEqual(pool.host, database.host) def test_port(self): pool = DatabaseClientPool.from_config(self.config) database = DatabaseMixin(pool) - self.assertEqual(pool.port, database.port) + with warnings.catch_warnings(): + warnings.simplefilter("ignore", DeprecationWarning) + # noinspection PyDeprecation + self.assertEqual(pool.port, database.port) async def test_pool(self): async with DatabaseMixin() as database: From 76d454953b2d71ac4841c1a93b11cc8a1aed649d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 18:26:26 +0200 Subject: [PATCH 112/324] ISSUE #367 * Minor changes. --- .../minos/aggregate/snapshots/pg/readers.py | 12 +----------- .../networks/brokers/collections/queues/pg.py | 17 +++++++++-------- 2 files changed, 10 insertions(+), 19 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py index 7ec0eff9d..492438fce 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py @@ -128,15 +128,5 @@ async def find_entries( qb = PostgreSqlSnapshotQueryBuilder(name, condition, ordering, limit, transaction_uuids, exclude_deleted) query, parameters = qb.build() - async with self.cursor() as cursor: - # noinspection PyTypeChecker - await cursor.execute(query, parameters) - if streaming_mode: - async for row in cursor: - # noinspection PyArgumentList - yield SnapshotEntry(*row) - return - else: - rows = await cursor.fetchall() - for row in rows: + async for row in self.submit_query_and_iter(query, parameters, streaming_mode=streaming_mode): yield SnapshotEntry(*row) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py index dc53280bd..9f8c8c7f9 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py @@ -175,14 +175,15 @@ async def _dequeue(self) -> BrokerMessage: self._queue.task_done() async def _run(self, max_wait: Optional[float] = 60.0) -> NoReturn: - async with self.cursor() as cursor: - await self._listen_entries(cursor) - try: - while self._run_task is not None: - await self._wait_for_entries(cursor, max_wait) - await self._dequeue_batch(cursor) - finally: - await self._unlisten_entries(cursor) + async with self.pool.acquire() as client: + async with client.cursor() as cursor: + await self._listen_entries(cursor) + try: + while self._run_task is not None: + await self._wait_for_entries(cursor, max_wait) + await self._dequeue_batch(cursor) + finally: + await self._unlisten_entries(cursor) async def _listen_entries(self, cursor: Cursor) -> None: # noinspection PyTypeChecker From 2123374e9961aa07092f468bc974e3e765531863 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 4 Apr 2022 20:40:07 +0200 Subject: [PATCH 113/324] ISSUE #367 * Working on clients. --- .../minos/common/__init__.py | 2 + .../minos/common/database/__init__.py | 4 + .../minos/common/database/abc.py | 117 +------- .../minos/common/database/clients/__init__.py | 7 + .../minos/common/database/clients/abc.py | 59 ++++ .../minos/common/database/clients/aiopg.py | 259 ++++++++++++++++++ .../minos/common/database/locks.py | 34 +-- .../common/database/operations/__init__.py | 6 + .../minos/common/database/operations/abc.py | 7 + .../minos/common/database/operations/aiopg.py | 15 + .../minos/common/database/pools.py | 64 ++--- .../minos/common/pools.py | 3 +- .../minos/common/setup.py | 4 +- .../test_common/test_database/test_locks.py | 35 +-- .../test_common/test_database/test_pools.py | 14 +- 15 files changed, 433 insertions(+), 197 deletions(-) create mode 100644 packages/core/minos-microservice-common/minos/common/database/clients/__init__.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/clients/abc.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/operations/__init__.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/operations/abc.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index b99dfc9cd..64285beb4 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -14,6 +14,8 @@ MinosConfig, ) from .database import ( + AiopgDatabaseClient, + DatabaseClient, DatabaseClientPool, DatabaseLock, DatabaseLockPool, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index f485369b7..23eadb29e 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -2,6 +2,10 @@ DatabaseMixin, PostgreSqlMinosDatabase, ) +from .clients import ( + AiopgDatabaseClient, + DatabaseClient, +) from .locks import ( DatabaseLock, PostgreSqlLock, diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 0419c8bdc..b8bf5fea2 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -1,21 +1,9 @@ import warnings -from collections.abc import ( - Hashable, -) from typing import ( - Any, - AsyncContextManager, AsyncIterator, Optional, ) -from aiomisc.pool import ( - ContextManager, -) -from aiopg import ( - Cursor, -) - from ..exceptions import ( NotProvidedException, ) @@ -28,9 +16,6 @@ from ..setup import ( SetupMixin, ) -from .locks import ( - DatabaseLock, -) from .pools import ( DatabaseClientPool, PostgreSqlPool, @@ -114,111 +99,31 @@ async def submit_query_and_fetchone(self, *args, **kwargs) -> tuple: :param kwargs: Additional named arguments. :return: This method does not return anything. """ - return await self.submit_query_and_iter(*args, **kwargs).__anext__() + async with self.pool.acquire() as client: + return await client.submit_query_and_fetchone(*args, **kwargs) # noinspection PyUnusedLocal - async def submit_query_and_iter( - self, - operation: Any, - parameters: Any = None, - *, - timeout: Optional[float] = None, - lock: Optional[int] = None, - streaming_mode: bool = False, - **kwargs, - ) -> AsyncIterator[tuple]: + async def submit_query_and_iter(self, *args, **kwargs) -> AsyncIterator[tuple]: """Submit a SQL query and return an asynchronous iterator. - :param operation: Query to be executed. - :param parameters: Parameters to be projected into the query. - :param timeout: An optional timeout. - :param lock: Optional key to perform the query with locking. If not set, the query is performed without any - lock. - :param streaming_mode: If ``True`` the data fetching is performed in streaming mode, that is iterating over the - cursor and yielding once a time (requires an opening connection to do that). Otherwise, all the data is - fetched and keep in memory before yielding it. + :param args: Additional positional arguments. :param kwargs: Additional named arguments. :return: This method does not return anything. """ - if lock is None: - context_manager = self.cursor() - else: - context_manager = self.locked_cursor(lock) - - async with context_manager as cursor: - await cursor.execute(operation=operation, parameters=parameters, timeout=timeout) - - if streaming_mode: - async for row in cursor: - yield row - return - - rows = await cursor.fetchall() - - for row in rows: - yield row + async with self.pool.acquire() as client: + async for value in client.submit_query_and_iter(*args, **kwargs): + yield value # noinspection PyUnusedLocal - async def submit_query( - self, operation: Any, parameters: Any = None, *, timeout: Optional[float] = None, lock: Any = None, **kwargs - ) -> None: + async def submit_query(self, *args, **kwargs) -> None: """Submit a SQL query. - :param operation: Query to be executed. - :param parameters: Parameters to be projected into the query. - :param timeout: An optional timeout. - :param lock: Optional key to perform the query with locking. If not set, the query is performed without any - lock. - :param kwargs: Additional named arguments. - :return: This method does not return anything. - """ - if lock is None: - context_manager = self.cursor() - else: - context_manager = self.locked_cursor(lock) - - async with context_manager as cursor: - await cursor.execute(operation=operation, parameters=parameters, timeout=timeout) - - def locked_cursor(self, key: Hashable, *args, **kwargs) -> AsyncContextManager[Cursor]: - """Get a new locked cursor. - - :param key: The key to be used for locking. :param args: Additional positional arguments. :param kwargs: Additional named arguments. - :return: A Cursor wrapped into an asynchronous context manager. - """ - lock = DatabaseLock(self.pool.acquire(), key, *args, **kwargs) - - async def _fn_enter(): - await lock.__aenter__() - return lock.cursor - - async def _fn_exit(_): - await lock.__aexit__(None, None, None) - - return ContextManager(_fn_enter, _fn_exit) - - def cursor(self, *args, **kwargs) -> AsyncContextManager[Cursor]: - """Get a new cursor. - - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. - :return: A Cursor wrapped into an asynchronous context manager. + :return: This method does not return anything. """ - acquired = self.pool.acquire() - - async def _fn_enter(): - connection = await acquired.__aenter__() - cursor = await connection.cursor(*args, **kwargs).__aenter__() - return cursor - - async def _fn_exit(cursor: Cursor): - if not cursor.closed: - cursor.close() - await acquired.__aexit__(None, None, None) - - return ContextManager(_fn_enter, _fn_exit) + async with self.pool.acquire() as client: + return await client.submit_query(*args, **kwargs) @property def pool(self) -> DatabaseClientPool: diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py new file mode 100644 index 000000000..193e019e7 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py @@ -0,0 +1,7 @@ +from .abc import ( + DatabaseClient, + UnableToConnectException, +) +from .aiopg import ( + AiopgDatabaseClient, +) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py new file mode 100644 index 000000000..f7ba9a6bb --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -0,0 +1,59 @@ +from abc import ( + ABC, + abstractmethod, +) +from collections.abc import ( + AsyncIterator, +) +from typing import ( + Any, + Optional, +) + +from ...setup import ( + SetupMixin, +) + + +class DatabaseClient(ABC, SetupMixin): + """TODO""" + + @abstractmethod + async def is_valid(self, **kwargs) -> bool: + """TODO""" + + @abstractmethod + async def submit_query( + self, operation: Any, parameters: Any = None, *, timeout: Optional[float] = None, lock: Any = None, **kwargs + ) -> None: + """TODO""" + + @abstractmethod + async def submit_query_and_fetchone( + self, + operation: Any, + parameters: Any = None, + *, + timeout: Optional[float] = None, + lock: Optional[int] = None, + streaming_mode: bool = False, + **kwargs, + ) -> Any: + """TODO""" + + @abstractmethod + def submit_query_and_iter( + self, + operation: Any, + parameters: Any = None, + *, + timeout: Optional[float] = None, + lock: Optional[int] = None, + streaming_mode: bool = False, + **kwargs, + ) -> AsyncIterator[Any]: + """TODO""" + + +class UnableToConnectException(Exception): + """TODO""" diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py new file mode 100644 index 000000000..656e82362 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -0,0 +1,259 @@ +import logging +from collections.abc import ( + AsyncIterator, + Hashable, +) +from typing import ( + Any, + Optional, +) + +import aiopg +from aiomisc.pool import ( + AsyncContextManager, + ContextManager, +) +from aiopg import ( + Connection, + Cursor, +) +from psycopg2 import ( + OperationalError, +) + +from .abc import ( + DatabaseClient, + UnableToConnectException, +) + +logger = logging.getLogger(__name__) + + +class AiopgDatabaseClient(DatabaseClient): + """TODO""" + + def __init__( + self, + database: str, + host: Optional[str] = None, + port: Optional[int] = None, + user: Optional[str] = None, + password: Optional[str] = None, + *args, + **kwargs, + ): + super().__init__(*args, **kwargs) + + if host is None: + host = "localhost" + if port is None: + port = 5432 + if user is None: + user = "postgres" + if password is None: + password = "" + + self._database = database + self._host = host + self._port = port + self._user = user + self._password = password + + self._connection = None + self._cursor = None + self._cursor_wrapper = None + + async def _setup(self) -> None: + await super()._setup() + await self._create_connection() + + async def _destroy(self) -> None: + await self._close_connection() + await super()._destroy() + + async def _create_connection(self): + try: + self._connection = await aiopg.connect( + host=self.host, port=self.port, dbname=self.database, user=self.user, password=self.password + ) + except OperationalError as exc: + logger.warning(f"There was an {exc!r} while trying to get a database connection.") + raise UnableToConnectException + + logger.debug(f"Created {self.database!r} database connection identified by {id(self._connection)}!") + + async def _close_connection(self): + if self._connection is not None and not self._connection.closed: + await self._connection.close() + self._connection = None + logger.debug(f"Destroyed {self.database!r} database connection identified by {id(self._connection)}!") + + async def is_valid(self): + """TODO""" + if self._connection is None: + return False + + try: + # This operation connects to the database and raises an exception if something goes wrong. + self._connection.isolation_level + except OperationalError: + return False + + return not self._connection.closed + + async def submit_query_and_fetchone(self, *args, **kwargs) -> tuple: + """Submit a SQL query and gets the first response. + + :param args: Additional positional arguments. + :param kwargs: Additional named arguments. + :return: This method does not return anything. + """ + return await self.submit_query_and_iter(*args, **kwargs).__anext__() + + # noinspection PyUnusedLocal + async def submit_query_and_iter( + self, + operation: Any, + parameters: Any = None, + *, + timeout: Optional[float] = None, + lock: Optional[int] = None, + streaming_mode: bool = False, + **kwargs, + ) -> AsyncIterator[tuple]: + """Submit a SQL query and return an asynchronous iterator. + + :param operation: Query to be executed. + :param parameters: Parameters to be projected into the query. + :param timeout: An optional timeout. + :param lock: Optional key to perform the query with locking. If not set, the query is performed without any + lock. + :param streaming_mode: If ``True`` the data fetching is performed in streaming mode, that is iterating over the + cursor and yielding once a time (requires an opening connection to do that). Otherwise, all the data is + fetched and keep in memory before yielding it. + :param kwargs: Additional named arguments. + :return: This method does not return anything. + """ + if lock is None: + context_manager = self.cursor() + else: + context_manager = self.locked_cursor(lock) + + async with context_manager as cursor: + await cursor.execute(operation=operation, parameters=parameters, timeout=timeout) + + if streaming_mode: + async for row in cursor: + yield row + return + + rows = await cursor.fetchall() + + for row in rows: + yield row + + # noinspection PyUnusedLocal + async def submit_query( + self, operation: Any, parameters: Any = None, *, timeout: Optional[float] = None, lock: Any = None, **kwargs + ) -> None: + """Submit a SQL query. + + :param operation: Query to be executed. + :param parameters: Parameters to be projected into the query. + :param timeout: An optional timeout. + :param lock: Optional key to perform the query with locking. If not set, the query is performed without any + lock. + :param kwargs: Additional named arguments. + :return: This method does not return anything. + """ + if lock is None: + context_manager = self.cursor() + else: + context_manager = self.locked_cursor(lock) + + async with context_manager as cursor: + await cursor.execute(operation=operation, parameters=parameters, timeout=timeout) + + def locked_cursor(self, key: Hashable, *args, **kwargs) -> AsyncContextManager[Cursor]: + """Get a new locked cursor. + + :param key: The key to be used for locking. + :param args: Additional positional arguments. + :param kwargs: Additional named arguments. + :return: A Cursor wrapped into an asynchronous context manager. + """ + from ..locks import ( + DatabaseLock, + ) + + lock = DatabaseLock(self, key, *args, **kwargs) + context_manager = self.cursor() + + async def _fn_enter(): + await lock.__aenter__() + return await context_manager.__aenter__() + + async def _fn_exit(_): + await context_manager.__aexit__(None, None, None) + await lock.__aexit__(None, None, None) + + return ContextManager(_fn_enter, _fn_exit) + + def cursor(self, *args, **kwargs) -> AsyncContextManager[Cursor]: + """Get a new cursor. + + :param args: Additional positional arguments. + :param kwargs: Additional named arguments. + :return: A Cursor wrapped into an asynchronous context manager. + """ + connection: Connection = self._connection + + async def _fn_enter(): + cursor = await connection.cursor(*args, **kwargs).__aenter__() + return cursor + + async def _fn_exit(cursor: Cursor): + if not cursor.closed: + cursor.close() + + return ContextManager(_fn_enter, _fn_exit) + + @property + def database(self) -> str: + """Get the database's database. + + :return: A ``str`` value. + """ + return self._database + + @property + def host(self) -> str: + """Get the database's host. + + :return: A ``str`` value. + """ + return self._host + + @property + def port(self) -> int: + """Get the database's port. + + :return: An ``int`` value. + """ + return self._port + + @property + def user(self) -> str: + """Get the database's user. + + :return: A ``str`` value. + """ + return self._user + + @property + def password(self) -> str: + """Get the database's password. + + :return: A ``str`` value. + """ + return self._password diff --git a/packages/core/minos-microservice-common/minos/common/database/locks.py b/packages/core/minos-microservice-common/minos/common/database/locks.py index 842798c5b..c0add2fb0 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks.py @@ -2,49 +2,29 @@ from collections.abc import ( Hashable, ) -from typing import ( - AsyncContextManager, - Optional, -) - -from aiopg import ( - Connection, - Cursor, -) from ..locks import ( Lock, ) +from .clients import ( + DatabaseClient, +) class DatabaseLock(Lock): """Database Lock class.""" - cursor: Optional[Cursor] - - def __init__(self, wrapped_connection: AsyncContextManager[Connection], key: Hashable, *args, **kwargs): + def __init__(self, client: DatabaseClient, key: Hashable, *args, **kwargs): super().__init__(key, *args, **kwargs) - self.wrapped_connection = wrapped_connection - self.cursor = None - - self._args = args - self._kwargs = kwargs + self.client = client async def __aenter__(self): - connection = await self.wrapped_connection.__aenter__() - cursor = await connection.cursor(*self._args, **self._kwargs).__aenter__() - - self.cursor = cursor - await self.cursor.execute("select pg_advisory_lock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) + await self.client.submit_query("select pg_advisory_lock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) return self async def __aexit__(self, exc_type, exc_val, exc_tb): - await self.cursor.execute("select pg_advisory_unlock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) - if not self.cursor.closed: - self.cursor.close() - self.cursor = None - await self.wrapped_connection.__aexit__(exc_type, exc_val, exc_tb) + await self.client.submit_query("select pg_advisory_unlock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) class PostgreSqlLock(DatabaseLock): diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py new file mode 100644 index 000000000..4b1401fee --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py @@ -0,0 +1,6 @@ +from .abc import ( + DatabaseOperation, +) +from .aiopg import ( + AiopgDatabaseOperation, +) diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py new file mode 100644 index 000000000..5ea21ccc5 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py @@ -0,0 +1,7 @@ +from abc import ( + ABC, +) + + +class DatabaseOperation(ABC): + """TODO""" diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py new file mode 100644 index 000000000..d8a67e386 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py @@ -0,0 +1,15 @@ +from typing import ( + Any, +) + +from .abc import ( + DatabaseOperation, +) + + +class AiopgDatabaseOperation(DatabaseOperation): + """TODO""" + + def __init__(self, query: str, arguments: dict[str, Any]): + self.query = query + self.arguments = arguments diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 9a6d4d41e..fd4d9bf81 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -10,16 +10,9 @@ Optional, ) -import aiopg from aiomisc.pool import ( ContextManager, ) -from aiopg import ( - Connection, -) -from psycopg2 import ( - OperationalError, -) from ..injections import ( Injectable, @@ -30,6 +23,11 @@ from ..pools import ( Pool, ) +from .clients import ( + AiopgDatabaseClient, + DatabaseClient, + UnableToConnectException, +) from .locks import ( DatabaseLock, ) @@ -37,7 +35,7 @@ logger = logging.getLogger(__name__) -class DatabaseClientPool(Pool[ContextManager]): +class DatabaseClientPool(Pool[DatabaseClient]): """Database Client Pool class.""" def __init__( @@ -71,35 +69,28 @@ def __init__( def _from_config(cls, *args, config, **kwargs): return cls(*args, **config.get_default_database(), **kwargs) - async def _create_instance(self) -> Optional[Connection]: + async def _create_instance(self) -> Optional[DatabaseClient]: + instance = AiopgDatabaseClient( + host=self.host, port=self.port, database=self.database, user=self.user, password=self.password + ) + try: - connection = await aiopg.connect( - host=self.host, port=self.port, dbname=self.database, user=self.user, password=self.password - ) - except OperationalError as exc: - logger.warning(f"There was an {exc!r} while trying to get a database connection.") + await instance.setup() + except UnableToConnectException: await sleep(1) return None - logger.info(f"Created {self.database!r} database connection identified by {id(connection)}!") - return connection + logger.info(f"Created {instance!r}!") + return instance - async def _destroy_instance(self, instance: Connection): - if not instance.closed: - await instance.close() - logger.info(f"Destroyed {self.database!r} database connection identified by {id(instance)}!") + async def _destroy_instance(self, instance: DatabaseClient): + logger.info(f"Destroyed {instance!r}!") + await instance.destroy() - async def _check_instance(self, instance: Optional[Connection]) -> bool: + async def _check_instance(self, instance: Optional[DatabaseClient]) -> bool: if instance is None: return False - - try: - # This operation connects to the database and raises an exception if something goes wrong. - instance.isolation_level - except OperationalError: - return False - - return not instance.closed + return await instance.is_valid() @Injectable("postgresql_pool") @@ -111,7 +102,7 @@ def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) -class DatabaseLockPool(LockPool, DatabaseClientPool): +class DatabaseLockPool(DatabaseClientPool, LockPool): """Database Lock Pool class.""" def acquire(self, key: Hashable, *args, **kwargs) -> DatabaseLock: @@ -120,7 +111,18 @@ def acquire(self, key: Hashable, *args, **kwargs) -> DatabaseLock: :param key: The key to be used for locking. :return: A ``PostgreSqlLock`` instance. """ - return DatabaseLock(super().acquire(), key, *args, **kwargs) + acquired = super().acquire() + + async def _fn_enter(): + client = await acquired.__aenter__() + return await DatabaseLock(client, key, *args, **kwargs).__aenter__() + + async def _fn_exit(lock: DatabaseLock): + await lock.__aexit__(None, None, None) + await acquired.__aexit__(None, None, None) + + # noinspection PyTypeChecker + return ContextManager(_fn_enter, _fn_exit) class PostgreSqlLockPool(DatabaseLockPool): diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index c0f5a78c5..63408013f 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -12,6 +12,7 @@ ) from typing import ( Any, + AsyncContextManager, Generic, Optional, TypeVar, @@ -130,7 +131,7 @@ async def __release(self, instance: Any) -> Any: # pragma: no cover await self._PoolBase__release(instance) logger.debug(f"Released instance: {instance!r}") - def acquire(self, *args, **kwargs) -> P: + def acquire(self, *args, **kwargs) -> AsyncContextManager[P]: """Acquire a new instance wrapped on an asynchronous context manager. :param args: Additional positional arguments. diff --git a/packages/core/minos-microservice-common/minos/common/setup.py b/packages/core/minos-microservice-common/minos/common/setup.py index 0832a3f59..87ae933f0 100644 --- a/packages/core/minos-microservice-common/minos/common/setup.py +++ b/packages/core/minos-microservice-common/minos/common/setup.py @@ -94,7 +94,7 @@ async def setup(self) -> None: :return: This method does not return anything. """ if not self._already_setup: - logger.info(f"Setting up a {type(self).__name__!r} instance...") + logger.debug(f"Setting up a {type(self).__name__!r} instance...") await self._setup() self._already_setup = True @@ -110,7 +110,7 @@ async def destroy(self) -> None: :return: This method does not return anything. """ if self._already_setup: - logger.info(f"Destroying a {type(self).__name__!r} instance...") + logger.debug(f"Destroying a {type(self).__name__!r} instance...") await self._destroy() self._already_setup = False diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py index d03a33418..19ff08541 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py @@ -1,12 +1,8 @@ import unittest import warnings -import aiopg -from aiopg import ( - Cursor, -) - from minos.common import ( + AiopgDatabaseClient, DatabaseLock, Lock, PostgreSqlLock, @@ -23,42 +19,37 @@ class TestDatabaseLock(CommonTestCase, PostgresAsyncTestCase): def test_base(self): self.assertTrue(issubclass(DatabaseLock, Lock)) - async def test_wrapped_connection(self): - wrapped_connection = aiopg.connect(**self.config.get_default_database()) - lock = DatabaseLock(wrapped_connection, "foo") - self.assertEqual(wrapped_connection, lock.wrapped_connection) + async def test_client(self): + client = AiopgDatabaseClient(**self.config.get_default_database()) + lock = DatabaseLock(client, "foo") + self.assertEqual(client, lock.client) async def test_key(self): - wrapped_connection = aiopg.connect(**self.config.get_default_database()) - lock = DatabaseLock(wrapped_connection, "foo") + client = AiopgDatabaseClient(**self.config.get_default_database()) + lock = DatabaseLock(client, "foo") self.assertEqual("foo", lock.key) async def test_key_raises(self): - wrapped_connection = aiopg.connect(**self.config.get_default_database()) + client = AiopgDatabaseClient(**self.config.get_default_database()) with self.assertRaises(ValueError): - DatabaseLock(wrapped_connection, []) + DatabaseLock(client, []) async def test_hashed_key(self): - wrapped_connection = aiopg.connect(**self.config.get_default_database()) - lock = DatabaseLock(wrapped_connection, "foo") + client = AiopgDatabaseClient(**self.config.get_default_database()) + lock = DatabaseLock(client, "foo") self.assertEqual(hash("foo"), lock.hashed_key) - async def test_cursor(self): - wrapped_connection = aiopg.connect(**self.config.get_default_database()) - async with DatabaseLock(wrapped_connection, "foo") as lock: - self.assertIsInstance(lock.cursor, Cursor) - class TestPostgreSqlLock(CommonTestCase, PostgresAsyncTestCase): def test_is_subclass(self): self.assertTrue(issubclass(PostgreSqlLock, DatabaseLock)) async def test_warnings(self): - wrapped_connection = aiopg.connect(**self.config.get_default_database()) + client = AiopgDatabaseClient(**self.config.get_default_database()) with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) - lock = PostgreSqlLock(wrapped_connection, "foo") + lock = PostgreSqlLock(client, "foo") self.assertIsInstance(lock, DatabaseLock) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index 061f1c118..6792dc4ec 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -6,14 +6,12 @@ ) import aiopg -from aiopg import ( - Connection, -) from psycopg2 import ( OperationalError, ) from minos.common import ( + DatabaseClient, DatabaseClientPool, DatabaseLock, DatabaseLockPool, @@ -59,14 +57,14 @@ def test_from_config(self): async def test_acquire(self): async with self.pool.acquire() as c1: - self.assertIsInstance(c1, Connection) + self.assertIsInstance(c1, DatabaseClient) async with self.pool.acquire() as c2: self.assertEqual(c1, c2) async def test_acquire_with_error(self): with patch("aiopg.Connection.isolation_level", new_callable=PropertyMock, side_effect=(OperationalError, None)): - async with self.pool.acquire() as connection: - self.assertIsInstance(connection, Connection) + async with self.pool.acquire() as client: + self.assertIsInstance(client, DatabaseClient) async def test_acquire_with_connection_error(self): executed = [False] @@ -79,8 +77,8 @@ def _side_effect(*args, **kwargs): return original(*args, **kwargs) with patch("aiopg.connect", side_effect=_side_effect): - async with self.pool.acquire() as connection: - self.assertIsInstance(connection, Connection) + async with self.pool.acquire() as client: + self.assertIsInstance(client, DatabaseClient) class TestPostgreSqlPool(CommonTestCase, PostgresAsyncTestCase): From 39fc6edc28f195de7927710f13072a97a2af1159 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 08:50:56 +0200 Subject: [PATCH 114/324] ISSUE #367 * Use `AiopgDatabaseClient` directly on `PostgresAsyncTestCase`. --- .../minos/common/testing.py | 25 +++++----------- .../tests/test_common/test_testing.py | 30 ++++++++----------- 2 files changed, 20 insertions(+), 35 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index 77512146e..c560d78bf 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -17,13 +17,12 @@ uuid4, ) -import aiopg - from .config import ( Config, ) from .database import ( DatabaseClientPool, + AiopgDatabaseClient, ) from .injections import ( DependencyInjector, @@ -77,7 +76,7 @@ class PostgresAsyncTestCase(MinosTestCase, ABC): def setUp(self): self.base_config = Config(self.get_config_file_path()) self._uuid = uuid4() - self._test_db = {"database": f"test_db_{self._uuid.hex}", "user": f"test_user_{self._uuid.hex}"} + self._test_db = {"database": f"test_db_{self._uuid.hex}"} super().setUp() @property @@ -120,20 +119,12 @@ async def asyncTearDown(self): async def _create_database(self, meta: dict[str, Any], test: dict[str, Any]) -> None: await self._drop_database(meta, test) - async with aiopg.connect(**meta) as connection: - async with connection.cursor() as cursor: - template = "CREATE ROLE {user} WITH SUPERUSER CREATEDB LOGIN ENCRYPTED PASSWORD {password!r};" - await cursor.execute(template.format(**(meta | test))) - - template = "CREATE DATABASE {database} WITH OWNER = {user};" - await cursor.execute(template.format(**(meta | test))) + async with AiopgDatabaseClient(**meta) as client: + template = "CREATE DATABASE {database} WITH OWNER = {user};" + await client.submit_query(template.format(**(meta | test))) @staticmethod async def _drop_database(meta: dict[str, Any], test: dict[str, Any]) -> None: - async with aiopg.connect(**meta) as connection: - async with connection.cursor() as cursor: - template = "DROP DATABASE IF EXISTS {database}" - await cursor.execute(template.format(**(meta | test))) - - template = "DROP ROLE IF EXISTS {user};" - await cursor.execute(template.format(**(meta | test))) + async with AiopgDatabaseClient(**meta) as client: + template = "DROP DATABASE IF EXISTS {database}" + await client.submit_query(template.format(**(meta | test))) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_testing.py b/packages/core/minos-microservice-common/tests/test_common/test_testing.py index 25ba78584..363f0a1be 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_testing.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_testing.py @@ -36,66 +36,60 @@ def test_repository_db(self): test_case.setUp() with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) + # noinspection PyDeprecation self.assertEqual( { k: v for k, v in test_case.base_config.get_database_by_name("aggregate").items() - if k not in {"database", "user"} + if k not in {"database"} }, - {k: v for k, v in test_case.repository_db.items() if k not in {"database", "user"}}, + {k: v for k, v in test_case.repository_db.items() if k not in {"database"}}, ) + # noinspection PyDeprecation self.assertNotEqual( test_case.base_config.get_database_by_name("aggregate")["database"], test_case.repository_db["database"], ) - self.assertNotEqual( - test_case.base_config.get_database_by_name("aggregate")["user"], - test_case.repository_db["user"], - ) def test_broker_queue_db(self): test_case = MyPostgresAsyncTestCase() test_case.setUp() with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) + # noinspection PyDeprecation self.assertEqual( { k: v for k, v in test_case.base_config.get_database_by_name("broker").items() - if k not in {"database", "user"} + if k not in {"database"} }, - {k: v for k, v in test_case.broker_queue_db.items() if k not in {"database", "user"}}, + {k: v for k, v in test_case.broker_queue_db.items() if k not in {"database"}}, ) + # noinspection PyDeprecation self.assertNotEqual( test_case.base_config.get_database_by_name("broker")["database"], test_case.broker_queue_db["database"], ) - self.assertNotEqual( - test_case.base_config.get_database_by_name("broker")["user"], - test_case.broker_queue_db["user"], - ) def test_snapshot_db(self): test_case = MyPostgresAsyncTestCase() test_case.setUp() with warnings.catch_warnings(): warnings.simplefilter("ignore", DeprecationWarning) + # noinspection PyDeprecation self.assertEqual( { k: v for k, v in test_case.base_config.get_database_by_name("aggregate").items() - if k not in {"database", "user"} + if k not in {"database"} }, - {k: v for k, v in test_case.snapshot_db.items() if k not in {"database", "user"}}, + {k: v for k, v in test_case.snapshot_db.items() if k not in {"database"}}, ) + # noinspection PyDeprecation self.assertNotEqual( test_case.base_config.get_database_by_name("aggregate")["database"], test_case.broker_queue_db["database"], ) - self.assertNotEqual( - test_case.base_config.get_database_by_name("aggregate")["user"], - test_case.broker_queue_db["user"], - ) class MyPostgresAsyncTestCase(PostgresAsyncTestCase): From be692f8128bc822b8cc27ede59bb78f2c6bea2a7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 09:11:54 +0200 Subject: [PATCH 115/324] ISSUE #346 * Fix bug related with a blocking status related with pool dependencies. --- .../minos-microservice-common/minos/common/pools.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index c0f5a78c5..d95ddca67 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -8,6 +8,7 @@ ABC, ) from asyncio import ( + gather, sleep, ) from typing import ( @@ -59,10 +60,15 @@ def _from_config(cls, config: Config, **kwargs) -> PoolFactory: return cls(config, **kwargs) async def _destroy(self) -> None: - for pool in self._pools.values(): - await pool.destroy() + await self._destroy_pools() await super()._destroy() + async def _destroy_pools(self): + logger.debug("Destroying pools...") + futures = (pool.destroy() for pool in self._pools.values()) + await gather(*futures) + logger.debug("Destroyed pools!") + def get_pool(self, type_: str, key: Optional[str] = None, **kwargs) -> Pool: """Get a pool from the factory. @@ -145,6 +151,7 @@ async def _destroy(self) -> None: logger.info("Waiting for instances releasing...") while len(self._used): await sleep(0.1) + logger.info("Released instances!") await self.close() From 5102f3cd74709dcc0b6cea4f3941a4042d8c6f40 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 09:13:57 +0200 Subject: [PATCH 116/324] ISSUE #367 * Reformat code. --- packages/core/minos-microservice-common/minos/common/testing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index c560d78bf..1ca046455 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -21,8 +21,8 @@ Config, ) from .database import ( - DatabaseClientPool, AiopgDatabaseClient, + DatabaseClientPool, ) from .injections import ( DependencyInjector, From 4034515f4250b4ace306911f773ccd233f46a2b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 09:16:43 +0200 Subject: [PATCH 117/324] ISSUE #367 * Minor change. --- .../minos/common/database/pools.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index fd4d9bf81..daff1069a 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -14,6 +14,9 @@ ContextManager, ) +from ..config import ( + Config, +) from ..injections import ( Injectable, ) @@ -66,8 +69,8 @@ def __init__( self.password = password @classmethod - def _from_config(cls, *args, config, **kwargs): - return cls(*args, **config.get_default_database(), **kwargs) + def _from_config(cls, config: Config, key: Optional[str] = None, **kwargs): + return cls(**config.get_default_database(), **kwargs) async def _create_instance(self) -> Optional[DatabaseClient]: instance = AiopgDatabaseClient( From 71978f28a21974b7a66f179f0003e414138b2d1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 09:23:17 +0200 Subject: [PATCH 118/324] ISSUE #367 * Remove accessors from `DatabaseMixin`. --- .../test_events/test_repositories/test_pg.py | 6 +-- .../test_snapshots/test_pg/test_readers.py | 6 +-- .../test_snapshots/test_pg/test_writers.py | 6 +-- .../test_repositories/test_pg.py | 6 +-- .../minos/common/database/abc.py | 45 ------------------- .../test_common/test_database/test_abc.py | 40 ----------------- 6 files changed, 4 insertions(+), 105 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index 2f4440f98..ec71a3979 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -35,11 +35,7 @@ def test_constructor(self): def test_from_config(self): repository = PostgreSqlEventRepository.from_config(self.config) repository_config = self.config.get_database_by_name("event") - self.assertEqual(repository_config["database"], repository.database) - self.assertEqual(repository_config["user"], repository.user) - self.assertEqual(repository_config["password"], repository.password) - self.assertEqual(repository_config["host"], repository.host) - self.assertEqual(repository_config["port"], repository.port) + self.assertEqual(repository_config["database"], repository.pool.database) async def test_setup(self): async with aiopg.connect(**self.config.get_default_database()) as connection: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py index 6ffe0cdcf..800e058d8 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py @@ -95,11 +95,7 @@ def test_type(self): def test_from_config(self): reader = PostgreSqlSnapshotReader.from_config(self.config) snapshot_config = self.config.get_database_by_name("snapshot") - self.assertEqual(snapshot_config["host"], reader.host) - self.assertEqual(snapshot_config["port"], reader.port) - self.assertEqual(snapshot_config["database"], reader.database) - self.assertEqual(snapshot_config["user"], reader.user) - self.assertEqual(snapshot_config["password"], reader.password) + self.assertEqual(snapshot_config["database"], reader.pool.database) async def test_find_by_uuid(self): condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py index 811d3448c..4cd0f2de0 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py @@ -102,11 +102,7 @@ def test_type(self): def test_from_config(self): snapshot_config = self.config.get_database_by_name("snapshot") - self.assertEqual(snapshot_config["host"], self.writer.host) - self.assertEqual(snapshot_config["port"], self.writer.port) - self.assertEqual(snapshot_config["database"], self.writer.database) - self.assertEqual(snapshot_config["user"], self.writer.user) - self.assertEqual(snapshot_config["password"], self.writer.password) + self.assertEqual(snapshot_config["database"], self.writer.pool.database) def test_from_config_raises(self): with self.assertRaises(NotProvidedException): diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index adb59c69c..e66c76ded 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -51,11 +51,7 @@ def test_constructor(self): def test_from_config(self): repository = PostgreSqlTransactionRepository.from_config(self.config) repository_config = self.config.get_database_by_name("event") - self.assertEqual(repository_config["host"], repository.host) - self.assertEqual(repository_config["port"], repository.port) - self.assertEqual(repository_config["database"], repository.database) - self.assertEqual(repository_config["user"], repository.user) - self.assertEqual(repository_config["password"], repository.password) + self.assertEqual(repository_config["database"], repository.pool.database) async def test_setup(self): async with aiopg.connect(**self.config.get_default_database()) as connection: diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 0419c8bdc..3db192334 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -62,51 +62,6 @@ def __init__( self._pool = database_pool - @property - def database(self) -> str: - """Get the database's database. - - :return: A ``str`` value. - """ - warnings.warn("'database' has been deprecated. Use 'pool.database' instead.", DeprecationWarning) - return self.pool.database - - @property - def host(self) -> str: - """Get the database's host. - - :return: A ``str`` value. - """ - warnings.warn("'host' has been deprecated. Use 'pool.host' instead.", DeprecationWarning) - return self.pool.host - - @property - def port(self) -> int: - """Get the database's port. - - :return: An ``int`` value. - """ - warnings.warn("'port' has been deprecated. Use 'pool.port' instead.", DeprecationWarning) - return self.pool.port - - @property - def user(self) -> str: - """Get the database's user. - - :return: A ``str`` value. - """ - warnings.warn("'user' has been deprecated. Use 'pool.user' instead.", DeprecationWarning) - return self.pool.user - - @property - def password(self) -> str: - """Get the database's password. - - :return: A ``str`` value. - """ - warnings.warn("'password' has been deprecated. Use 'pool.password' instead.", DeprecationWarning) - return self.pool.password - async def submit_query_and_fetchone(self, *args, **kwargs) -> tuple: """Submit a SQL query and gets the first response. diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index df0c70c2e..13fa4af99 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -47,46 +47,6 @@ async def test_constructor_with_postgresql_pool(self): self.assertEqual(pool, database.pool) - def test_database(self): - pool = DatabaseClientPool.from_config(self.config) - database = DatabaseMixin(pool) - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - # noinspection PyDeprecation - self.assertEqual(pool.database, database.database) - - def test_user(self): - pool = DatabaseClientPool.from_config(self.config) - database = DatabaseMixin(pool) - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - # noinspection PyDeprecation - self.assertEqual(pool.user, database.user) - - def test_password(self): - pool = DatabaseClientPool.from_config(self.config) - database = DatabaseMixin(pool) - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - # noinspection PyDeprecation - self.assertEqual(pool.password, database.password) - - def test_host(self): - pool = DatabaseClientPool.from_config(self.config) - database = DatabaseMixin(pool) - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - # noinspection PyDeprecation - self.assertEqual(pool.host, database.host) - - def test_port(self): - pool = DatabaseClientPool.from_config(self.config) - database = DatabaseMixin(pool) - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - # noinspection PyDeprecation - self.assertEqual(pool.port, database.port) - async def test_pool(self): async with DatabaseMixin() as database: self.assertIsInstance(database.pool, DatabaseClientPool) From 29dc30212cd1aace7a24d35531398d93e40925b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 10:38:54 +0200 Subject: [PATCH 119/324] ISSUE #367 * Add state to `AiopgDatabaseClient`. --- .../minos/common/database/abc.py | 8 +- .../minos/common/database/clients/abc.py | 37 ++---- .../minos/common/database/clients/aiopg.py | 121 ++++++++---------- .../minos/common/database/locks.py | 4 +- .../minos/common/database/pools.py | 3 + .../minos/common/pools.py | 4 + .../minos/common/testing.py | 4 +- .../networks/brokers/collections/queues/pg.py | 56 ++++---- .../brokers/subscribers/queued/queues/pg.py | 30 +++-- 9 files changed, 127 insertions(+), 140 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 33bc30149..ab4cce92e 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -55,7 +55,8 @@ async def submit_query_and_fetchone(self, *args, **kwargs) -> tuple: :return: This method does not return anything. """ async with self.pool.acquire() as client: - return await client.submit_query_and_fetchone(*args, **kwargs) + await client.execute(*args, **kwargs) + return await client.fetch_one(*args, **kwargs) # noinspection PyUnusedLocal async def submit_query_and_iter(self, *args, **kwargs) -> AsyncIterator[tuple]: @@ -66,7 +67,8 @@ async def submit_query_and_iter(self, *args, **kwargs) -> AsyncIterator[tuple]: :return: This method does not return anything. """ async with self.pool.acquire() as client: - async for value in client.submit_query_and_iter(*args, **kwargs): + await client.execute(*args, **kwargs) + async for value in client.fetch_all(*args, **kwargs): yield value # noinspection PyUnusedLocal @@ -78,7 +80,7 @@ async def submit_query(self, *args, **kwargs) -> None: :return: This method does not return anything. """ async with self.pool.acquire() as client: - return await client.submit_query(*args, **kwargs) + return await client.execute(*args, **kwargs) @property def pool(self) -> DatabaseClientPool: diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index f7ba9a6bb..e8ce916a2 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -2,12 +2,14 @@ ABC, abstractmethod, ) +from asyncio import ( + Queue, +) from collections.abc import ( AsyncIterator, ) from typing import ( Any, - Optional, ) from ...setup import ( @@ -22,36 +24,23 @@ class DatabaseClient(ABC, SetupMixin): async def is_valid(self, **kwargs) -> bool: """TODO""" + async def reset(self, **kwargs) -> None: + """TODO""" + + @property @abstractmethod - async def submit_query( - self, operation: Any, parameters: Any = None, *, timeout: Optional[float] = None, lock: Any = None, **kwargs - ) -> None: + def notifications(self) -> Queue: """TODO""" @abstractmethod - async def submit_query_and_fetchone( - self, - operation: Any, - parameters: Any = None, - *, - timeout: Optional[float] = None, - lock: Optional[int] = None, - streaming_mode: bool = False, - **kwargs, - ) -> Any: + async def execute(self, *args, **kwargs) -> None: """TODO""" + async def fetch_one(self, *args, **kwargs) -> Any: + return await self.fetch_all(*args, **kwargs).__anext__() + @abstractmethod - def submit_query_and_iter( - self, - operation: Any, - parameters: Any = None, - *, - timeout: Optional[float] = None, - lock: Optional[int] = None, - streaming_mode: bool = False, - **kwargs, - ) -> AsyncIterator[Any]: + def fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: """TODO""" diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index 656e82362..e6123c7be 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -1,9 +1,17 @@ +from __future__ import ( + annotations, +) + import logging +from asyncio import ( + Queue, +) from collections.abc import ( AsyncIterator, Hashable, ) from typing import ( + TYPE_CHECKING, Any, Optional, ) @@ -11,7 +19,6 @@ import aiopg from aiomisc.pool import ( AsyncContextManager, - ContextManager, ) from aiopg import ( Connection, @@ -26,12 +33,21 @@ UnableToConnectException, ) +if TYPE_CHECKING: + from ..locks import ( + DatabaseLock, + ) + logger = logging.getLogger(__name__) class AiopgDatabaseClient(DatabaseClient): """TODO""" + _connection: Optional[Connection] + _cursor: Optional[Cursor] + _lock: Optional[DatabaseLock] + def __init__( self, database: str, @@ -60,14 +76,16 @@ def __init__( self._password = password self._connection = None + + self._lock = None self._cursor = None - self._cursor_wrapper = None async def _setup(self) -> None: await super()._setup() await self._create_connection() async def _destroy(self) -> None: + await self.reset() await self._close_connection() await super()._destroy() @@ -101,21 +119,18 @@ async def is_valid(self): return not self._connection.closed - async def submit_query_and_fetchone(self, *args, **kwargs) -> tuple: - """Submit a SQL query and gets the first response. + async def reset(self, **kwargs) -> None: + """TODO""" + await self._destroy_cursor(**kwargs) - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. - :return: This method does not return anything. - """ - return await self.submit_query_and_iter(*args, **kwargs).__anext__() + @property + def notifications(self) -> Queue: + return self._connection.notifies # noinspection PyUnusedLocal - async def submit_query_and_iter( + async def fetch_all( self, - operation: Any, - parameters: Any = None, - *, + *args, timeout: Optional[float] = None, lock: Optional[int] = None, streaming_mode: bool = False, @@ -123,8 +138,6 @@ async def submit_query_and_iter( ) -> AsyncIterator[tuple]: """Submit a SQL query and return an asynchronous iterator. - :param operation: Query to be executed. - :param parameters: Parameters to be projected into the query. :param timeout: An optional timeout. :param lock: Optional key to perform the query with locking. If not set, the query is performed without any lock. @@ -134,26 +147,20 @@ async def submit_query_and_iter( :param kwargs: Additional named arguments. :return: This method does not return anything. """ - if lock is None: - context_manager = self.cursor() - else: - context_manager = self.locked_cursor(lock) + await self._create_cursor() - async with context_manager as cursor: - await cursor.execute(operation=operation, parameters=parameters, timeout=timeout) + if streaming_mode: + async for row in self._cursor: + yield row + return - if streaming_mode: - async for row in cursor: - yield row - return - - rows = await cursor.fetchall() + rows = await self._cursor.fetchall() for row in rows: yield row # noinspection PyUnusedLocal - async def submit_query( + async def execute( self, operation: Any, parameters: Any = None, *, timeout: Optional[float] = None, lock: Any = None, **kwargs ) -> None: """Submit a SQL query. @@ -166,38 +173,30 @@ async def submit_query( :param kwargs: Additional named arguments. :return: This method does not return anything. """ - if lock is None: - context_manager = self.cursor() - else: - context_manager = self.locked_cursor(lock) - - async with context_manager as cursor: - await cursor.execute(operation=operation, parameters=parameters, timeout=timeout) + await self._create_cursor() + await self._cursor.execute(operation=operation, parameters=parameters, timeout=timeout) - def locked_cursor(self, key: Hashable, *args, **kwargs) -> AsyncContextManager[Cursor]: - """Get a new locked cursor. + async def _create_cursor(self, *args, lock: Optional[Hashable] = None, **kwargs): + if self._cursor is None: + self._cursor = await self._connection.cursor(*args, **kwargs) - :param key: The key to be used for locking. - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. - :return: A Cursor wrapped into an asynchronous context manager. - """ - from ..locks import ( - DatabaseLock, - ) - - lock = DatabaseLock(self, key, *args, **kwargs) - context_manager = self.cursor() + if lock is not None and self._lock is None: + from ..locks import ( + DatabaseLock, + ) - async def _fn_enter(): - await lock.__aenter__() - return await context_manager.__aenter__() + self._lock = DatabaseLock(self, lock, *args, **kwargs) + await self._lock.__aenter__() - async def _fn_exit(_): - await context_manager.__aexit__(None, None, None) - await lock.__aexit__(None, None, None) + async def _destroy_cursor(self, **kwargs): + if self._lock is not None: + await self._lock.__aexit__(None, None, None) + self._lock = None - return ContextManager(_fn_enter, _fn_exit) + if self._cursor is not None: + if self._cursor.closed: + self._cursor.close() + self._cursor = None def cursor(self, *args, **kwargs) -> AsyncContextManager[Cursor]: """Get a new cursor. @@ -206,17 +205,7 @@ def cursor(self, *args, **kwargs) -> AsyncContextManager[Cursor]: :param kwargs: Additional named arguments. :return: A Cursor wrapped into an asynchronous context manager. """ - connection: Connection = self._connection - - async def _fn_enter(): - cursor = await connection.cursor(*args, **kwargs).__aenter__() - return cursor - - async def _fn_exit(cursor: Cursor): - if not cursor.closed: - cursor.close() - - return ContextManager(_fn_enter, _fn_exit) + return self._cursor @property def database(self) -> str: diff --git a/packages/core/minos-microservice-common/minos/common/database/locks.py b/packages/core/minos-microservice-common/minos/common/database/locks.py index c0add2fb0..b22d3f9e4 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks.py @@ -20,11 +20,11 @@ def __init__(self, client: DatabaseClient, key: Hashable, *args, **kwargs): self.client = client async def __aenter__(self): - await self.client.submit_query("select pg_advisory_lock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) + await self.client.execute("select pg_advisory_lock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) return self async def __aexit__(self, exc_type, exc_val, exc_tb): - await self.client.submit_query("select pg_advisory_unlock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) + await self.client.execute("select pg_advisory_unlock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) class PostgreSqlLock(DatabaseLock): diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index daff1069a..ae784264f 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -95,6 +95,9 @@ async def _check_instance(self, instance: Optional[DatabaseClient]) -> bool: return False return await instance.is_valid() + async def _release_instance(self, instance: DatabaseClient) -> None: + await instance.reset() + @Injectable("postgresql_pool") class PostgreSqlPool(DatabaseClientPool): diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index 08a46cedc..bcd426d48 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -134,6 +134,7 @@ async def __acquire(self) -> Any: # pragma: no cover # noinspection PyUnresolvedReferences async def __release(self, instance: Any) -> Any: # pragma: no cover + await self._release_instance(instance) await self._PoolBase__release(instance) logger.debug(f"Released instance: {instance!r}") @@ -159,6 +160,9 @@ async def _destroy(self) -> None: async def _check_instance(self, instance: P) -> bool: return True + async def _release_instance(self, instance: P) -> None: + pass + class MinosPool(Pool, Generic[P], ABC): """MinosPool class.""" diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index 1ca046455..4791b2713 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -121,10 +121,10 @@ async def _create_database(self, meta: dict[str, Any], test: dict[str, Any]) -> async with AiopgDatabaseClient(**meta) as client: template = "CREATE DATABASE {database} WITH OWNER = {user};" - await client.submit_query(template.format(**(meta | test))) + await client.execute(template.format(**(meta | test))) @staticmethod async def _drop_database(meta: dict[str, Any], test: dict[str, Any]) -> None: async with AiopgDatabaseClient(**meta) as client: template = "DROP DATABASE IF EXISTS {database}" - await client.submit_query(template.format(**(meta | test))) + await client.execute(template.format(**(meta | test))) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py index 9f8c8c7f9..628187edd 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py @@ -24,9 +24,6 @@ Optional, ) -from aiopg import ( - Cursor, -) from cached_property import ( cached_property, ) @@ -37,6 +34,7 @@ from minos.common import ( Builder, Config, + DatabaseClient, DatabaseMixin, ) @@ -176,41 +174,40 @@ async def _dequeue(self) -> BrokerMessage: async def _run(self, max_wait: Optional[float] = 60.0) -> NoReturn: async with self.pool.acquire() as client: - async with client.cursor() as cursor: - await self._listen_entries(cursor) - try: - while self._run_task is not None: - await self._wait_for_entries(cursor, max_wait) - await self._dequeue_batch(cursor) - finally: - await self._unlisten_entries(cursor) + await self._listen_entries(client) + try: + while self._run_task is not None: + await self._wait_for_entries(client, max_wait) + await self._dequeue_batch(client) + finally: + await self._unlisten_entries(client) - async def _listen_entries(self, cursor: Cursor) -> None: + async def _listen_entries(self, client: DatabaseClient) -> None: # noinspection PyTypeChecker - await cursor.execute(self._query_factory.build_listen()) + await client.execute(self._query_factory.build_listen()) - async def _unlisten_entries(self, cursor: Cursor) -> None: - if not cursor.closed: + async def _unlisten_entries(self, client: DatabaseClient) -> None: + if not client.already_destroyed: # noinspection PyTypeChecker - await cursor.execute(self._query_factory.build_unlisten()) + await client.execute(self._query_factory.build_unlisten()) - async def _wait_for_entries(self, cursor: Cursor, max_wait: Optional[float]) -> None: + async def _wait_for_entries(self, client: DatabaseClient, max_wait: Optional[float]) -> None: while True: - if await self._get_count(cursor): + if await self._get_count(client): return with suppress(TimeoutError): - return await wait_for(consume_queue(cursor.connection.notifies, self._records), max_wait) + return await wait_for(consume_queue(client.notifications, self._records), max_wait) - async def _get_count(self, cursor: Cursor) -> int: + async def _get_count(self, client: DatabaseClient) -> int: # noinspection PyTypeChecker - await cursor.execute(self._query_factory.build_count_not_processed(), (self._retry,)) - count = (await cursor.fetchone())[0] + await client.execute(self._query_factory.build_count_not_processed(), (self._retry,)) + count = (await client.fetch_one())[0] return count - async def _dequeue_batch(self, cursor: Cursor) -> None: - async with cursor.begin(): - rows = await self._dequeue_rows(cursor) + async def _dequeue_batch(self, client: DatabaseClient) -> None: + async with client._cursor.begin(): # FIXME + rows = await self._dequeue_rows(client) if not len(rows): return @@ -218,17 +215,18 @@ async def _dequeue_batch(self, cursor: Cursor) -> None: entries = [_Entry(*row) for row in rows] # noinspection PyTypeChecker - await cursor.execute(self._query_factory.build_mark_processing(), (tuple(entry.id_ for entry in entries),)) + await client.execute(self._query_factory.build_mark_processing(), (tuple(entry.id_ for entry in entries),)) for entry in entries: await self._queue.put(entry) - async def _dequeue_rows(self, cursor: Cursor) -> list[Any]: + async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: # noinspection PyTypeChecker - await cursor.execute(self._query_factory.build_select_not_processed(), (self._retry, self._records)) - return await cursor.fetchall() + await client.execute(self._query_factory.build_select_not_processed(), (self._retry, self._records)) + return [row async for row in client.fetch_all()] +# noinspection SqlResolve,SqlNoDataSourceInspection class PostgreSqlBrokerQueueQueryFactory(ABC): """PostgreSql Broker Queue Query Factory class.""" diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py index 1cd1cdeec..3a3804622 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py @@ -8,14 +8,15 @@ Optional, ) -from aiopg import ( - Cursor, -) from psycopg2.sql import ( SQL, Identifier, ) +from minos.common import ( + DatabaseClient, +) + from ....collections import ( PostgreSqlBrokerQueue, PostgreSqlBrokerQueueBuilder, @@ -45,29 +46,30 @@ def __init__( async def _notify_enqueued(self, message: BrokerMessage) -> None: await self.submit_query(self._query_factory.build_notify().format(Identifier(message.topic))) - async def _listen_entries(self, cursor: Cursor) -> None: + async def _listen_entries(self, client: DatabaseClient) -> None: for topic in self.topics: - await cursor.execute(self._query_factory.build_listen().format(Identifier(topic))) + await client.execute(self._query_factory.build_listen().format(Identifier(topic))) - async def _unlisten_entries(self, cursor: Cursor) -> None: - if not cursor.closed: + async def _unlisten_entries(self, client: DatabaseClient) -> None: + if not client.already_destroyed: for topic in self.topics: - await cursor.execute(self._query_factory.build_unlisten().format(Identifier(topic))) + await client.execute(self._query_factory.build_unlisten().format(Identifier(topic))) - async def _get_count(self, cursor: Cursor) -> int: + async def _get_count(self, client: DatabaseClient) -> int: # noinspection PyTypeChecker - await cursor.execute(self._query_factory.build_count_not_processed(), (self._retry, tuple(self.topics))) - count = (await cursor.fetchone())[0] + await client.execute(self._query_factory.build_count_not_processed(), (self._retry, tuple(self.topics))) + count = (await client.fetch_one())[0] return count - async def _dequeue_rows(self, cursor: Cursor) -> list[Any]: + async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: # noinspection PyTypeChecker - await cursor.execute( + await client.execute( self._query_factory.build_select_not_processed(), (self._retry, tuple(self.topics), self._records) ) - return await cursor.fetchall() + return [row async for row in client.fetch_all()] +# noinspection SqlNoDataSourceInspection,SqlResolve class PostgreSqlBrokerSubscriberQueueQueryFactory(PostgreSqlBrokerQueueQueryFactory): """PostgreSql Broker Subscriber Queue Query Factory class.""" From fa00b7bb9524454a64bced5890b694ccfd3357c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 10:41:20 +0200 Subject: [PATCH 120/324] ISSUE #367 * Remove deprecated properties. --- .../minos/common/testing.py | 16 ----- .../tests/test_common/test_testing.py | 60 +------------------ 2 files changed, 1 insertion(+), 75 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index 4791b2713..6bbdba801 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -1,5 +1,4 @@ import unittest -import warnings from abc import ( ABC, ) @@ -79,21 +78,6 @@ def setUp(self): self._test_db = {"database": f"test_db_{self._uuid.hex}"} super().setUp() - @property - def repository_db(self) -> dict[str, Any]: - warnings.warn("'repository_db' attribute has been deprecated.", DeprecationWarning) - return self.config.get_database_by_name("aggregate") | self._test_db - - @property - def broker_queue_db(self) -> dict[str, Any]: - warnings.warn("'broker_queue_db' attribute has been deprecated.", DeprecationWarning) - return self.config.get_database_by_name("broker") | self._test_db - - @property - def snapshot_db(self) -> dict[str, Any]: - warnings.warn("'snapshot_db' attribute has been deprecated.", DeprecationWarning) - return self.config.get_database_by_name("aggregate") | self._test_db - def get_config(self) -> Config: config = Config(self.get_config_file_path()) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_testing.py b/packages/core/minos-microservice-common/tests/test_common/test_testing.py index 363f0a1be..e807461ae 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_testing.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_testing.py @@ -31,65 +31,7 @@ class MyMinosTestCase(MinosTestCase): class TestPostgresAsyncTestCase(unittest.IsolatedAsyncioTestCase): - def test_repository_db(self): - test_case = MyPostgresAsyncTestCase() - test_case.setUp() - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - # noinspection PyDeprecation - self.assertEqual( - { - k: v - for k, v in test_case.base_config.get_database_by_name("aggregate").items() - if k not in {"database"} - }, - {k: v for k, v in test_case.repository_db.items() if k not in {"database"}}, - ) - # noinspection PyDeprecation - self.assertNotEqual( - test_case.base_config.get_database_by_name("aggregate")["database"], - test_case.repository_db["database"], - ) - - def test_broker_queue_db(self): - test_case = MyPostgresAsyncTestCase() - test_case.setUp() - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - # noinspection PyDeprecation - self.assertEqual( - { - k: v - for k, v in test_case.base_config.get_database_by_name("broker").items() - if k not in {"database"} - }, - {k: v for k, v in test_case.broker_queue_db.items() if k not in {"database"}}, - ) - # noinspection PyDeprecation - self.assertNotEqual( - test_case.base_config.get_database_by_name("broker")["database"], - test_case.broker_queue_db["database"], - ) - - def test_snapshot_db(self): - test_case = MyPostgresAsyncTestCase() - test_case.setUp() - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - # noinspection PyDeprecation - self.assertEqual( - { - k: v - for k, v in test_case.base_config.get_database_by_name("aggregate").items() - if k not in {"database"} - }, - {k: v for k, v in test_case.snapshot_db.items() if k not in {"database"}}, - ) - # noinspection PyDeprecation - self.assertNotEqual( - test_case.base_config.get_database_by_name("aggregate")["database"], - test_case.broker_queue_db["database"], - ) + pass class MyPostgresAsyncTestCase(PostgresAsyncTestCase): From 97d91dd1547432c1267c3a8a4c1315b2720e5654 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 10:58:04 +0200 Subject: [PATCH 121/324] ISSUE #367 * Fix minor bugs. --- .../minos/common/database/clients/aiopg.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index e6123c7be..32d5ed4a4 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -3,9 +3,6 @@ ) import logging -from asyncio import ( - Queue, -) from collections.abc import ( AsyncIterator, Hashable, @@ -24,6 +21,7 @@ Connection, Cursor, ) +from aiopg.utils import ClosableQueue from psycopg2 import ( OperationalError, ) @@ -124,7 +122,7 @@ async def reset(self, **kwargs) -> None: await self._destroy_cursor(**kwargs) @property - def notifications(self) -> Queue: + def notifications(self) -> ClosableQueue: return self._connection.notifies # noinspection PyUnusedLocal @@ -173,7 +171,7 @@ async def execute( :param kwargs: Additional named arguments. :return: This method does not return anything. """ - await self._create_cursor() + await self._create_cursor(lock=lock) await self._cursor.execute(operation=operation, parameters=parameters, timeout=timeout) async def _create_cursor(self, *args, lock: Optional[Hashable] = None, **kwargs): From d66a1819a63f3e69c88f9a493c426e083778cedc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 11:52:04 +0200 Subject: [PATCH 122/324] ISSUE #367 * Restrict max concurrency. --- .../minos/networks/brokers/handlers/impl.py | 2 +- .../minos/networks/http/connectors.py | 61 +++++++++++-------- .../minos/saga/executions/saga.py | 7 ++- 3 files changed, 43 insertions(+), 27 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/handlers/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/handlers/impl.py index b26cb5831..17340e926 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/handlers/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/handlers/impl.py @@ -38,7 +38,7 @@ class BrokerHandler(SetupMixin): """Broker Handler class.""" def __init__( - self, dispatcher: BrokerDispatcher, subscriber: BrokerSubscriber, concurrency: int = 15, *args, **kwargs + self, dispatcher: BrokerDispatcher, subscriber: BrokerSubscriber, concurrency: int = 5, *args, **kwargs ): super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-networks/minos/networks/http/connectors.py b/packages/core/minos-microservice-networks/minos/networks/http/connectors.py index 5163d1571..fc9bd6f4a 100644 --- a/packages/core/minos-microservice-networks/minos/networks/http/connectors.py +++ b/packages/core/minos-microservice-networks/minos/networks/http/connectors.py @@ -8,6 +8,9 @@ ABC, abstractmethod, ) +from asyncio import ( + Semaphore, +) from collections.abc import ( Callable, ) @@ -56,7 +59,14 @@ class HttpConnector(ABC, SetupMixin, Generic[RawRequest, RawResponse]): """Http Application base class.""" - def __init__(self, adapter: HttpAdapter, host: Optional[str] = None, port: Optional[int] = None, **kwargs): + def __init__( + self, + adapter: HttpAdapter, + host: Optional[str] = None, + port: Optional[int] = None, + max_connections: int = 5, + **kwargs, + ): super().__init__(**kwargs) if host is None: host = "0.0.0.0" @@ -67,6 +77,8 @@ def __init__(self, adapter: HttpAdapter, host: Optional[str] = None, port: Optio self._host = host self._port = port + self._semaphore = Semaphore(max_connections) + @classmethod def _from_config(cls, config: Config, **kwargs) -> HttpConnector: http_config = config.get_interface_by_name("http") @@ -138,29 +150,30 @@ def adapt_callback( @wraps(callback) async def _wrapper(raw: RawRequest) -> RawResponse: - logger.info(f"Dispatching '{raw!s}'...") - - request = await self._build_request(raw) - token = REQUEST_USER_CONTEXT_VAR.set(request.user) - - # noinspection PyBroadException - try: - response = callback(request) - if isawaitable(response): - response = await response - - return await self._build_response(response) - - except ResponseException as exc: - tb = traceback.format_exc() - logger.error(f"Raised an application exception:\n {tb}") - return await self._build_error_response(tb, exc.status) - except Exception: - tb = traceback.format_exc() - logger.exception(f"Raised a system exception:\n {tb}") - return await self._build_error_response(tb, 500) - finally: - REQUEST_USER_CONTEXT_VAR.reset(token) + async with self._semaphore: + logger.info(f"Dispatching '{raw!s}'...") + + request = await self._build_request(raw) + token = REQUEST_USER_CONTEXT_VAR.set(request.user) + + # noinspection PyBroadException + try: + response = callback(request) + if isawaitable(response): + response = await response + + return await self._build_response(response) + + except ResponseException as exc: + tb = traceback.format_exc() + logger.error(f"Raised an application exception:\n {tb}") + return await self._build_error_response(tb, exc.status) + except Exception: + tb = traceback.format_exc() + logger.exception(f"Raised a system exception:\n {tb}") + return await self._build_error_response(tb, 500) + finally: + REQUEST_USER_CONTEXT_VAR.reset(token) return _wrapper diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/saga.py b/packages/core/minos-microservice-saga/minos/saga/executions/saga.py index 3ae1ed5df..6c0c6548e 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/saga.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/saga.py @@ -4,6 +4,9 @@ import logging import warnings +from asyncio import ( + shield, +) from contextlib import ( suppress, ) @@ -262,7 +265,7 @@ async def commit(self, *args, **kwargs) -> None: committer = TransactionCommitter(self.uuid, self.executed_steps, *args, **kwargs) try: - await committer.commit() + await shield(committer.commit()) except Exception as exc: # FIXME: Exception is too broad logger.warning(f"There was an exception on {TransactionCommitter.__name__!r} commit: {exc!r}") with suppress(SagaRollbackExecutionException): @@ -279,7 +282,7 @@ async def reject(self, *args, **kwargs) -> None: """ committer = TransactionCommitter(self.uuid, self.executed_steps, *args, **kwargs) try: - await committer.reject() + await shield(committer.reject()) except Exception as exc: logger.warning(f"There was an exception on {TransactionCommitter.__name__!r} rejection: {exc!r}") raise SagaFailedCommitCallbackException(exc) From 56b42b5f45d2d2b6fb17365fd5629b61c2a140f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 11:55:28 +0200 Subject: [PATCH 123/324] ISSUE #367 * Reformat code. --- .../minos/common/database/clients/aiopg.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index 32d5ed4a4..40e795c7e 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -21,7 +21,9 @@ Connection, Cursor, ) -from aiopg.utils import ClosableQueue +from aiopg.utils import ( + ClosableQueue, +) from psycopg2 import ( OperationalError, ) From 2d30b150e38323ab2b345a618ca7f2c242ef10c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 12:25:29 +0200 Subject: [PATCH 124/324] ISSUE #367 * Add `DatabaseClientBuilder`. --- .../minos/common/__init__.py | 2 + .../minos/common/database/__init__.py | 2 + .../minos/common/database/clients/__init__.py | 1 + .../minos/common/database/clients/abc.py | 37 +++++++++++++-- .../common/database/operations/__init__.py | 6 --- .../minos/common/database/operations/abc.py | 7 --- .../minos/common/database/operations/aiopg.py | 15 ------ .../minos/common/database/pools.py | 46 ++++++++----------- .../test_common/test_database/test_pools.py | 20 ++++---- .../tests/test_common/test_testing.py | 1 - 10 files changed, 65 insertions(+), 72 deletions(-) delete mode 100644 packages/core/minos-microservice-common/minos/common/database/operations/__init__.py delete mode 100644 packages/core/minos-microservice-common/minos/common/database/operations/abc.py delete mode 100644 packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 64285beb4..6d99f1e65 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -16,6 +16,7 @@ from .database import ( AiopgDatabaseClient, DatabaseClient, + DatabaseClientBuilder, DatabaseClientPool, DatabaseLock, DatabaseLockPool, @@ -24,6 +25,7 @@ PostgreSqlLockPool, PostgreSqlMinosDatabase, PostgreSqlPool, + UnableToConnectException, ) from .datetime import ( NULL_DATETIME, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index 23eadb29e..defc25d46 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -5,6 +5,8 @@ from .clients import ( AiopgDatabaseClient, DatabaseClient, + DatabaseClientBuilder, + UnableToConnectException, ) from .locks import ( DatabaseLock, diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py index 193e019e7..519d872c1 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py @@ -1,5 +1,6 @@ from .abc import ( DatabaseClient, + DatabaseClientBuilder, UnableToConnectException, ) from .aiopg import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index e8ce916a2..756d595d7 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -1,3 +1,7 @@ +from __future__ import ( + annotations, +) + from abc import ( ABC, abstractmethod, @@ -10,16 +14,25 @@ ) from typing import ( Any, + Optional, ) -from ...setup import ( - SetupMixin, +from ...builders import ( + BuildableMixin, + Builder, +) +from ...config import ( + Config, ) -class DatabaseClient(ABC, SetupMixin): +class DatabaseClient(ABC, BuildableMixin): """TODO""" + @classmethod + def _from_config(cls, config: Config, key: Optional[str] = None, **kwargs) -> DatabaseClient: + return super()._from_config(config, **config.get_database_by_name(key), **kwargs) + @abstractmethod async def is_valid(self, **kwargs) -> bool: """TODO""" @@ -44,5 +57,23 @@ def fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: """TODO""" +class DatabaseClientBuilder(Builder[DatabaseClient]): + """TODO""" + + def with_key(self, key) -> DatabaseClientBuilder: + """TODO""" + self.kwargs["key"] = key + return self + + def with_config(self, config: Config) -> DatabaseClientBuilder: + """TODO""" + database_config = config.get_database_by_name(self.kwargs.get("key")) + self.kwargs |= database_config + return self + + +DatabaseClient.set_builder(DatabaseClientBuilder) + + class UnableToConnectException(Exception): """TODO""" diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py deleted file mode 100644 index 4b1401fee..000000000 --- a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py +++ /dev/null @@ -1,6 +0,0 @@ -from .abc import ( - DatabaseOperation, -) -from .aiopg import ( - AiopgDatabaseOperation, -) diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py deleted file mode 100644 index 5ea21ccc5..000000000 --- a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py +++ /dev/null @@ -1,7 +0,0 @@ -from abc import ( - ABC, -) - - -class DatabaseOperation(ABC): - """TODO""" diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py deleted file mode 100644 index d8a67e386..000000000 --- a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py +++ /dev/null @@ -1,15 +0,0 @@ -from typing import ( - Any, -) - -from .abc import ( - DatabaseOperation, -) - - -class AiopgDatabaseOperation(DatabaseOperation): - """TODO""" - - def __init__(self, query: str, arguments: dict[str, Any]): - self.query = query - self.arguments = arguments diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index ae784264f..98718eb08 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -29,6 +29,7 @@ from .clients import ( AiopgDatabaseClient, DatabaseClient, + DatabaseClientBuilder, UnableToConnectException, ) from .locks import ( @@ -41,41 +42,22 @@ class DatabaseClientPool(Pool[DatabaseClient]): """Database Client Pool class.""" - def __init__( - self, - database: str, - host: Optional[str] = None, - port: Optional[int] = None, - user: Optional[str] = None, - password: Optional[str] = None, - *args, - **kwargs, - ): + def __init__(self, client_builder: DatabaseClientBuilder, *args, **kwargs): super().__init__(*args, **kwargs) - if host is None: - host = "localhost" - if port is None: - port = 5432 - if user is None: - user = "postgres" - if password is None: - password = "" - - self.database = database - self.host = host - self.port = port - self.user = user - self.password = password + self._client_builder = client_builder @classmethod def _from_config(cls, config: Config, key: Optional[str] = None, **kwargs): - return cls(**config.get_default_database(), **kwargs) + client_cls = config.get_database_by_name(key).get("client", AiopgDatabaseClient) + # noinspection PyTypeChecker + base_builder: DatabaseClientBuilder = client_cls.get_builder() + client_builder = base_builder.with_key(key).with_config(config) + + return cls(client_builder=client_builder, **kwargs) async def _create_instance(self) -> Optional[DatabaseClient]: - instance = AiopgDatabaseClient( - host=self.host, port=self.port, database=self.database, user=self.user, password=self.password - ) + instance = self._client_builder.build() try: await instance.setup() @@ -98,6 +80,14 @@ async def _check_instance(self, instance: Optional[DatabaseClient]) -> bool: async def _release_instance(self, instance: DatabaseClient) -> None: await instance.reset() + @property + def client_builder(self) -> DatabaseClientBuilder: + """Get the client builder class. + + :return: A ``DatabaseClientBuilder`` instance. + """ + return self._client_builder + @Injectable("postgresql_pool") class PostgreSqlPool(DatabaseClientPool): diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index 6792dc4ec..3f61b0803 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -11,7 +11,9 @@ ) from minos.common import ( + AiopgDatabaseClient, DatabaseClient, + DatabaseClientBuilder, DatabaseClientPool, DatabaseLock, DatabaseLockPool, @@ -32,12 +34,9 @@ def setUp(self) -> None: self.pool = DatabaseClientPool.from_config(self.config) def test_constructor(self): - pool = DatabaseClientPool("foo") - self.assertEqual("foo", pool.database) - self.assertEqual("postgres", pool.user) - self.assertEqual("", pool.password) - self.assertEqual("localhost", pool.host) - self.assertEqual(5432, pool.port) + builder = DatabaseClientBuilder() + pool = DatabaseClientPool(builder) + self.assertEqual(builder, pool.client_builder) async def asyncSetUp(self): await super().asyncSetUp() @@ -48,12 +47,9 @@ async def asyncTearDown(self): await super().asyncTearDown() def test_from_config(self): - repository_config = self.config.get_database_by_name("event") - self.assertEqual(repository_config["database"], self.pool.database) - self.assertEqual(repository_config["user"], self.pool.user) - self.assertEqual(repository_config["password"], self.pool.password) - self.assertEqual(repository_config["host"], self.pool.host) - self.assertEqual(repository_config["port"], self.pool.port) + pool = DatabaseClientPool.from_config(self.config, key="event") + self.assertIsInstance(pool.client_builder, DatabaseClientBuilder) + self.assertEqual(AiopgDatabaseClient, pool.client_builder.instance_cls) async def test_acquire(self): async with self.pool.acquire() as c1: diff --git a/packages/core/minos-microservice-common/tests/test_common/test_testing.py b/packages/core/minos-microservice-common/tests/test_common/test_testing.py index e807461ae..bfb899baf 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_testing.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_testing.py @@ -1,5 +1,4 @@ import unittest -import warnings from minos.common import ( Config, From 2822e446c9ee1546bd8191424604cb4dbf4e1b57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 12:37:40 +0200 Subject: [PATCH 125/324] ISSUE #367 * Add support for `DatabaseClient` setup from config file. --- .../core/minos-microservice-common/minos/common/config/v1.py | 2 ++ .../core/minos-microservice-common/minos/common/config/v2.py | 3 +++ 2 files changed, 5 insertions(+) diff --git a/packages/core/minos-microservice-common/minos/common/config/v1.py b/packages/core/minos-microservice-common/minos/common/config/v1.py index fdac15c47..d61366029 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v1.py +++ b/packages/core/minos-microservice-common/minos/common/config/v1.py @@ -282,6 +282,8 @@ def _get_database_by_name(self, prefix: str): data = self.get_by_key(prefix) data.pop("records", None) data.pop("retry", None) + if "client" in data: + data["client"] = import_module(data["client"]) return data def _get_discovery(self) -> dict[str, Any]: diff --git a/packages/core/minos-microservice-common/minos/common/config/v2.py b/packages/core/minos-microservice-common/minos/common/config/v2.py index 6a3fa4238..ff6c04a76 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v2.py +++ b/packages/core/minos-microservice-common/minos/common/config/v2.py @@ -99,6 +99,9 @@ def _get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin]]] def _get_databases(self) -> dict[str, dict[str, Any]]: data = deepcopy(self.get_by_key("databases")) + for database in data.values(): + if "client" in database: + database["client"] = import_module(database["client"]) return data def _get_interfaces(self) -> dict[str, dict[str, Any]]: From 05a47652cca81fcf9a87418d62ca2c0806d78ee6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 12:38:08 +0200 Subject: [PATCH 126/324] ISSUE #367 * Remove unnecessary transaction. --- .../networks/brokers/collections/queues/pg.py | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py index 628187edd..a829d26e9 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py @@ -206,19 +206,18 @@ async def _get_count(self, client: DatabaseClient) -> int: return count async def _dequeue_batch(self, client: DatabaseClient) -> None: - async with client._cursor.begin(): # FIXME - rows = await self._dequeue_rows(client) + rows = await self._dequeue_rows(client) - if not len(rows): - return + if not len(rows): + return - entries = [_Entry(*row) for row in rows] + entries = [_Entry(*row) for row in rows] - # noinspection PyTypeChecker - await client.execute(self._query_factory.build_mark_processing(), (tuple(entry.id_ for entry in entries),)) + # noinspection PyTypeChecker + await client.execute(self._query_factory.build_mark_processing(), (tuple(entry.id_ for entry in entries),)) - for entry in entries: - await self._queue.put(entry) + for entry in entries: + await self._queue.put(entry) async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: # noinspection PyTypeChecker From 81c3a5b88eabe4c78e9c97ad89b846a245ccb55b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 14:09:12 +0200 Subject: [PATCH 127/324] ISSUE #367 * Clarify exception log. --- packages/core/minos-microservice-saga/minos/saga/manager.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-saga/minos/saga/manager.py b/packages/core/minos-microservice-saga/minos/saga/manager.py index fb56e6cf1..590b46e9f 100644 --- a/packages/core/minos-microservice-saga/minos/saga/manager.py +++ b/packages/core/minos-microservice-saga/minos/saga/manager.py @@ -181,7 +181,7 @@ async def _run( self.storage.store(execution) if raise_on_error: raise exc - logger.warning(f"The execution identified by {execution.uuid!s} failed: {exc.exception!r}") + logger.exception(f"The execution identified by {execution.uuid!s} failed") finally: if (headers := REQUEST_HEADERS_CONTEXT_VAR.get()) is not None: related_services = reduce(or_, (s.related_services for s in execution.executed_steps), set()) From e2042e3c9f3933a48872fb9bf0baa438e5754b30 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 14:10:45 +0200 Subject: [PATCH 128/324] ISSUE #367 * Fix broken tests. * Work on the multi-database case. --- .../minos/aggregate/events/repositories/pg.py | 2 +- .../minos/aggregate/snapshots/pg/abc.py | 2 +- .../minos/aggregate/snapshots/pg/api.py | 2 +- .../aggregate/transactions/repositories/pg.py | 2 +- .../test_events/test_repositories/test_pg.py | 5 ++--- .../test_snapshots/test_pg/test_readers.py | 6 ++++-- .../test_snapshots/test_pg/test_writers.py | 4 ++-- .../test_repositories/test_pg.py | 3 +-- .../minos/common/database/abc.py | 3 ++- .../minos/common/database/clients/abc.py | 10 +++++----- .../minos/common/database/pools.py | 8 +++++--- .../minos/common/pools.py | 15 ++++++++------- .../networks/brokers/collections/queues/pg.py | 4 ++-- .../filtered/validators/duplicates/pg.py | 2 +- 14 files changed, 36 insertions(+), 32 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py index 43dff88d1..13fad3562 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py @@ -42,7 +42,7 @@ class PostgreSqlEventRepository(DatabaseMixin, EventRepository): @classmethod def _from_config(cls, config: Config, **kwargs) -> Optional[EventRepository]: - return super()._from_config(config, **config.get_database_by_name("event"), **kwargs) + return super()._from_config(config, database_key=None, **kwargs) async def _setup(self): """Setup miscellaneous repository thing. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py index 6f835a15a..88246d393 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py @@ -18,7 +18,7 @@ class PostgreSqlSnapshotSetup(DatabaseMixin): @classmethod def _from_config(cls: Type[T], config: Config, **kwargs) -> T: - return cls(**config.get_database_by_name("snapshot"), **kwargs) + return cls(database_key=None, **kwargs) async def _setup(self) -> None: await self.submit_query('CREATE EXTENSION IF NOT EXISTS "uuid-ossp";', lock="uuid-ossp") diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/api.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/api.py index 9a6357171..2ed9c1c73 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/api.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/api.py @@ -51,7 +51,7 @@ def _from_config(cls, config: Config, **kwargs) -> PostgreSqlSnapshotRepository: if "writer" not in kwargs: kwargs["writer"] = PostgreSqlSnapshotWriter.from_config(config, **kwargs) - return cls(**config.get_database_by_name("snapshot"), **kwargs) + return cls(database_key=None, **kwargs) async def _setup(self) -> None: await self.writer.setup() diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py index eee96b7fa..0a1281a39 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py @@ -34,7 +34,7 @@ class PostgreSqlTransactionRepository(DatabaseMixin, TransactionRepository): @classmethod def _from_config(cls, config: Config, **kwargs) -> Optional[PostgreSqlTransactionRepository]: - return super()._from_config(config, **config.get_database_by_name("transaction"), **kwargs) + return super()._from_config(config, database_key=None, **kwargs) async def _setup(self): await self.submit_query('CREATE EXTENSION IF NOT EXISTS "uuid-ossp";', lock="uuid-ossp") diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index ec71a3979..f7d44f741 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -30,12 +30,11 @@ def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) repository = PostgreSqlEventRepository(pool) self.assertIsInstance(repository, PostgreSqlEventRepository) - self.assertEqual(pool, repository.pool) + self.assertIsInstance(repository.pool, DatabaseClientPool) def test_from_config(self): repository = PostgreSqlEventRepository.from_config(self.config) - repository_config = self.config.get_database_by_name("event") - self.assertEqual(repository_config["database"], repository.pool.database) + self.assertIsInstance(repository.pool, DatabaseClientPool) async def test_setup(self): async with aiopg.connect(**self.config.get_default_database()) as connection: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py index 800e058d8..bba2f9999 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py @@ -21,6 +21,9 @@ TransactionEntry, TransactionStatus, ) +from minos.common import ( + DatabaseClientPool, +) from minos.common.testing import ( PostgresAsyncTestCase, ) @@ -94,8 +97,7 @@ def test_type(self): def test_from_config(self): reader = PostgreSqlSnapshotReader.from_config(self.config) - snapshot_config = self.config.get_database_by_name("snapshot") - self.assertEqual(snapshot_config["database"], reader.pool.database) + self.assertIsInstance(reader.pool, DatabaseClientPool) async def test_find_by_uuid(self): condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py index 4cd0f2de0..e393903b5 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py @@ -26,6 +26,7 @@ TransactionStatus, ) from minos.common import ( + DatabaseClientPool, NotProvidedException, current_datetime, ) @@ -101,8 +102,7 @@ def test_type(self): self.assertTrue(issubclass(PostgreSqlSnapshotWriter, PostgreSqlSnapshotSetup)) def test_from_config(self): - snapshot_config = self.config.get_database_by_name("snapshot") - self.assertEqual(snapshot_config["database"], self.writer.pool.database) + self.assertIsInstance(self.writer.pool, DatabaseClientPool) def test_from_config_raises(self): with self.assertRaises(NotProvidedException): diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index e66c76ded..5ece614c7 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -50,8 +50,7 @@ def test_constructor(self): def test_from_config(self): repository = PostgreSqlTransactionRepository.from_config(self.config) - repository_config = self.config.get_database_by_name("event") - self.assertEqual(repository_config["database"], repository.pool.database) + self.assertIsInstance(repository.pool, DatabaseClientPool) async def test_setup(self): async with aiopg.connect(**self.config.get_default_database()) as connection: diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index ab4cce92e..9c06a070b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -30,13 +30,14 @@ def __init__( self, database_pool: Optional[DatabaseClientPool] = None, pool_factory: Optional[PoolFactory] = None, + database_key: Optional[str] = None, postgresql_pool: Optional[PostgreSqlPool] = None, *args, **kwargs, ): super().__init__(*args, **kwargs, pool_factory=pool_factory) if database_pool is None and pool_factory is not None: - database_pool = pool_factory.get_pool("database") + database_pool = pool_factory.get_pool(type_="database", identifier=database_key) if database_pool is None and postgresql_pool is not None: warnings.warn("'postgresql_pool' argument has been deprecated", DeprecationWarning) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 756d595d7..424f559f9 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -30,8 +30,8 @@ class DatabaseClient(ABC, BuildableMixin): """TODO""" @classmethod - def _from_config(cls, config: Config, key: Optional[str] = None, **kwargs) -> DatabaseClient: - return super()._from_config(config, **config.get_database_by_name(key), **kwargs) + def _from_config(cls, config: Config, name: Optional[str] = None, **kwargs) -> DatabaseClient: + return super()._from_config(config, **config.get_database_by_name(name), **kwargs) @abstractmethod async def is_valid(self, **kwargs) -> bool: @@ -60,14 +60,14 @@ def fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: class DatabaseClientBuilder(Builder[DatabaseClient]): """TODO""" - def with_key(self, key) -> DatabaseClientBuilder: + def with_name(self, name: str) -> DatabaseClientBuilder: """TODO""" - self.kwargs["key"] = key + self.kwargs["name"] = name return self def with_config(self, config: Config) -> DatabaseClientBuilder: """TODO""" - database_config = config.get_database_by_name(self.kwargs.get("key")) + database_config = config.get_database_by_name(self.kwargs.get("name")) self.kwargs |= database_config return self diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 98718eb08..a363ba7d3 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -48,11 +48,11 @@ def __init__(self, client_builder: DatabaseClientBuilder, *args, **kwargs): self._client_builder = client_builder @classmethod - def _from_config(cls, config: Config, key: Optional[str] = None, **kwargs): - client_cls = config.get_database_by_name(key).get("client", AiopgDatabaseClient) + def _from_config(cls, config: Config, identifier: Optional[str] = None, **kwargs): + client_cls = config.get_database_by_name(identifier).get("client", AiopgDatabaseClient) # noinspection PyTypeChecker base_builder: DatabaseClientBuilder = client_cls.get_builder() - client_builder = base_builder.with_key(key).with_config(config) + client_builder = base_builder.with_name(identifier).with_config(config) return cls(client_builder=client_builder, **kwargs) @@ -69,6 +69,8 @@ async def _create_instance(self) -> Optional[DatabaseClient]: return instance async def _destroy_instance(self, instance: DatabaseClient): + if instance is None: + return logger.info(f"Destroyed {instance!r}!") await instance.destroy() diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index bcd426d48..c78ee6eed 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -45,7 +45,7 @@ class PoolFactory(SetupMixin): """Pool Factory class.""" - _pools: dict[str, Pool] + _pools: dict[tuple[str, ...], Pool] def __init__(self, config: Config, default_classes: dict[str, type[Pool]] = None, *args, **kwargs): super().__init__(*args, **kwargs) @@ -70,18 +70,18 @@ async def _destroy_pools(self): await gather(*futures) logger.debug("Destroyed pools!") - def get_pool(self, type_: str, key: Optional[str] = None, **kwargs) -> Pool: + def get_pool(self, type_: str, identifier: Optional[str] = None, **kwargs) -> Pool: """Get a pool from the factory. :param type_: The type of the pool. - :param key: An optional key that identifies the pool. + :param identifier: An optional key that identifies the pool. :param kwargs: Additional named arguments. :return: A ``Pool`` instance. """ - if key is None: - key = type_ + key = (type_, identifier) if key not in self._pools: - self._pools[key] = self._create_pool(type_, key=key, **kwargs) + logger.debug(f"Creating the {key!r} pool...") + self._pools[key] = self._create_pool(type_, identifier=identifier, **kwargs) return self._pools[key] def _create_pool(self, type_: str, **kwargs) -> Pool: @@ -108,7 +108,8 @@ class Pool(SetupMixin, PoolBase, Generic[P], ABC): """Base class for Pool implementations in minos""" def __init__(self, *args, maxsize: int = 10, recycle: Optional[int] = 300, already_setup: bool = True, **kwargs): - super().__init__(*args, maxsize=maxsize, recycle=recycle, already_setup=already_setup, **kwargs) + SetupMixin.__init__(self, *args, already_setup=already_setup, **kwargs) + PoolBase.__init__(self, maxsize=maxsize, recycle=recycle) # noinspection PyUnresolvedReferences async def __acquire(self) -> Any: # pragma: no cover diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py index a829d26e9..1316e280b 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py @@ -107,7 +107,7 @@ def query_factory(self) -> PostgreSqlBrokerQueueQueryFactory: def _from_config(cls, config: Config, **kwargs) -> PostgreSqlBrokerQueue: broker_interface = config.get_interface_by_name("broker") queue_config = broker_interface.get("common", dict()).get("queue", dict()) - database_config = config.get_database_by_name("broker") + database_config = {"database_key": None} return cls(**(kwargs | database_config | queue_config)) @@ -361,7 +361,7 @@ def with_config(self, config: Config): :param config: The config to be set. :return: This method return the builder instance. """ - self.kwargs |= config.get_database_by_name("broker") + self.kwargs |= {"database_key": None} self.kwargs |= config.get_interface_by_name("broker").get("common", dict()).get("queue", dict()) return super().with_config(config) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py index e1a2394af..1c6163786 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py @@ -77,7 +77,7 @@ def with_config(self, config: Config): :param config: The config to be set. :return: This method return the builder instance. """ - self.kwargs |= config.get_database_by_name("broker") + self.kwargs |= {"database_key": None} return super().with_config(config) From b30075a42db69cfdc5b0642135d4fd634ed36f3e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 15:33:44 +0200 Subject: [PATCH 129/324] ISSUE #367 * Remove `aiopg` imports outside the related code. --- .../test_events/test_repositories/test_pg.py | 15 +++++---- .../test_snapshots/test_pg/test_abc.py | 31 +++++++++---------- .../test_snapshots/test_pg/test_queries.py | 6 ++-- .../test_repositories/test_pg.py | 15 +++++---- .../minos/common/database/clients/aiopg.py | 20 +++++++----- .../tests/config/v1.yml | 1 + .../tests/config/v2.yml | 1 + .../test_common/test_database/test_abc.py | 19 +++++------- .../test_collections/test_queues/test_pg.py | 9 ++++-- .../test_queued/test_queues/test_pg.py | 11 +++++-- 10 files changed, 68 insertions(+), 60 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index f7d44f741..af034f447 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -1,12 +1,11 @@ import unittest -import aiopg - from minos.aggregate import ( EventRepository, PostgreSqlEventRepository, ) from minos.common import ( + AiopgDatabaseClient, DatabaseClientPool, ) from minos.common.testing import ( @@ -18,6 +17,7 @@ ) +# noinspection SqlNoDataSourceInspection class TestPostgreSqlEventRepositorySubmit(EventRepositorySubmitTestCase, PostgresAsyncTestCase): __test__ = True @@ -37,12 +37,11 @@ def test_from_config(self): self.assertIsInstance(repository.pool, DatabaseClientPool) async def test_setup(self): - async with aiopg.connect(**self.config.get_default_database()) as connection: - async with connection.cursor() as cursor: - await cursor.execute( - "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_event');" - ) - response = (await cursor.fetchone())[0] + async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + await client.execute( + "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_event');" + ) + response = (await client.fetchone())[0] self.assertTrue(response) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py index ace68416c..207afc7c1 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py @@ -1,10 +1,11 @@ import unittest -import aiopg - from minos.aggregate import ( PostgreSqlSnapshotSetup, ) +from minos.common import ( + AiopgDatabaseClient, +) from minos.common.testing import ( PostgresAsyncTestCase, ) @@ -13,27 +14,25 @@ ) +# noinspection SqlNoDataSourceInspection class TestPostgreSqlSnapshotSetup(AggregateTestCase, PostgresAsyncTestCase): async def test_setup_snapshot_table(self): async with PostgreSqlSnapshotSetup.from_config(self.config): - async with aiopg.connect(**self.config.get_default_database()) as connection: - async with connection.cursor() as cursor: - await cursor.execute( - "SELECT EXISTS (SELECT FROM pg_tables " - "WHERE schemaname = 'public' AND tablename = 'snapshot');" - ) - observed = (await cursor.fetchone())[0] + async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + await client.execute( + "SELECT EXISTS (SELECT FROM pg_tables WHERE schemaname = 'public' AND tablename = 'snapshot');" + ) + observed = (await client.fetch_one())[0] self.assertEqual(True, observed) async def test_setup_snapshot_aux_offset_table(self): async with PostgreSqlSnapshotSetup.from_config(self.config): - async with aiopg.connect(**self.config.get_default_database()) as connection: - async with connection.cursor() as cursor: - await cursor.execute( - "SELECT EXISTS (SELECT FROM pg_tables WHERE " - "schemaname = 'public' AND tablename = 'snapshot_aux_offset');" - ) - observed = (await cursor.fetchone())[0] + async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + await client.execute( + "SELECT EXISTS (SELECT FROM pg_tables WHERE " + "schemaname = 'public' AND tablename = 'snapshot_aux_offset');" + ) + observed = (await client.fetch_one())[0] self.assertEqual(True, observed) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py index d4583827d..467cdd3f3 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py @@ -7,7 +7,6 @@ uuid4, ) -import aiopg from psycopg2.extras import ( Json, ) @@ -29,6 +28,7 @@ ) from minos.common import ( NULL_UUID, + AiopgDatabaseClient, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -426,8 +426,8 @@ async def test_build_complex(self): self.assertEqual(self._flatten_parameters(expected_parameters), self._flatten_parameters(observed[1])) async def _flatten_query(self, query) -> str: - async with aiopg.connect(**self.config.get_default_database()) as connection: - return query.as_string(connection.raw) + async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + return query.as_string(client.connection.raw) @staticmethod def _flatten_parameters(parameters) -> dict: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index 5ece614c7..e0bd9225d 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -3,8 +3,6 @@ uuid4, ) -import aiopg - from minos.aggregate import ( PostgreSqlTransactionRepository, TransactionEntry, @@ -13,6 +11,7 @@ TransactionStatus, ) from minos.common import ( + AiopgDatabaseClient, DatabaseClientPool, ) from minos.common.testing import ( @@ -23,6 +22,7 @@ ) +# noinspection SqlNoDataSourceInspection class TestPostgreSqlTransactionRepository(AggregateTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() @@ -53,12 +53,11 @@ def test_from_config(self): self.assertIsInstance(repository.pool, DatabaseClientPool) async def test_setup(self): - async with aiopg.connect(**self.config.get_default_database()) as connection: - async with connection.cursor() as cursor: - await cursor.execute( - "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_transaction');" - ) - response = (await cursor.fetchone())[0] + async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + await client.execute( + "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_transaction');" + ) + response = (await client.fetch_one())[0] self.assertTrue(response) async def test_submit(self): diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index 40e795c7e..b971bf699 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -14,9 +14,6 @@ ) import aiopg -from aiomisc.pool import ( - AsyncContextManager, -) from aiopg import ( Connection, Cursor, @@ -198,15 +195,22 @@ async def _destroy_cursor(self, **kwargs): self._cursor.close() self._cursor = None - def cursor(self, *args, **kwargs) -> AsyncContextManager[Cursor]: - """Get a new cursor. + @property + def cursor(self) -> Optional[Cursor]: + """Get the cursor. - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. - :return: A Cursor wrapped into an asynchronous context manager. + :return: A ``Cursor`` instance. """ return self._cursor + @property + def connection(self) -> Optional[Connection]: + """Get the connection. + + :return: A ``Connection`` instance. + """ + return self._connection + @property def database(self) -> str: """Get the database's database. diff --git a/packages/core/minos-microservice-common/tests/config/v1.yml b/packages/core/minos-microservice-common/tests/config/v1.yml index cf45e9211..0b124e10c 100644 --- a/packages/core/minos-microservice-common/tests/config/v1.yml +++ b/packages/core/minos-microservice-common/tests/config/v1.yml @@ -19,6 +19,7 @@ service: - tests.utils.FakeSagaManager - tests.utils.FakeCustomInjection repository: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-common/tests/config/v2.yml b/packages/core/minos-microservice-common/tests/config/v2.yml index 8c7771bd0..af4e8dfc9 100644 --- a/packages/core/minos-microservice-common/tests/config/v2.yml +++ b/packages/core/minos-microservice-common/tests/config/v2.yml @@ -6,6 +6,7 @@ serializer: client: tests.utils.FakeSerializer databases: default: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index 13fa4af99..5570d154a 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -1,9 +1,8 @@ import unittest import warnings -import aiopg - from minos.common import ( + AiopgDatabaseClient, DatabaseClientPool, DatabaseMixin, NotProvidedException, @@ -19,7 +18,7 @@ ) -# noinspection SqlNoDataSourceInspection +# noinspection SqlNoDataSourceInspection,SqlResolve class TestDatabaseMixin(CommonTestCase, PostgresAsyncTestCase): def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) @@ -55,19 +54,17 @@ async def test_submit_query(self): async with DatabaseMixin() as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") - async with aiopg.connect(**self.config.get_default_database()) as connection: - async with connection.cursor() as cursor: - await cursor.execute("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") - self.assertTrue((await cursor.fetchone())[0]) + async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + await client.execute("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") + self.assertTrue((await client.fetch_one())[0]) async def test_submit_query_locked(self): async with DatabaseMixin() as database: await database.submit_query("CREATE TABLE foo (id INT NOT NULL);", lock=1234) - async with aiopg.connect(**self.config.get_default_database()) as connection: - async with connection.cursor() as cursor: - await cursor.execute("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") - self.assertTrue((await cursor.fetchone())[0]) + async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + await client.execute("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") + self.assertTrue((await client.fetch_one())[0]) async def test_submit_query_and_fetchone(self): async with DatabaseMixin() as database: diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index 52735d889..dd4c065ab 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -8,6 +8,7 @@ ) from minos.common import ( + AiopgDatabaseClient, DatabaseMixin, ) from minos.common.testing import ( @@ -23,6 +24,7 @@ PostgreSqlBrokerQueueQueryFactory, ) from tests.utils import ( + FakeAsyncIterator, NetworksTestCase, ) @@ -85,9 +87,10 @@ async def test_dequeue_with_count(self): BrokerMessageV1("bar", BrokerMessageV1Payload("foo")), ] - with patch( - "aiopg.Cursor.fetchall", - return_value=[[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]], + with patch.object( + AiopgDatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]]), ): async with PostgreSqlBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: queue._get_count = AsyncMock(side_effect=[3, 0]) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py index 922467aec..d7446dd47 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py @@ -7,6 +7,9 @@ patch, ) +from minos.common import ( + AiopgDatabaseClient, +) from minos.common.testing import ( PostgresAsyncTestCase, ) @@ -20,6 +23,7 @@ PostgreSqlBrokerSubscriberQueueQueryFactory, ) from tests.utils import ( + FakeAsyncIterator, NetworksTestCase, ) @@ -46,9 +50,10 @@ async def test_dequeue_with_count(self): BrokerMessageV1("bar", BrokerMessageV1Payload("foo")), ] - with patch( - "aiopg.Cursor.fetchall", - return_value=[[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]], + with patch.object( + AiopgDatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]]), ): async with PostgreSqlBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: queue._get_count = AsyncMock(side_effect=[3, 0]) From f323369db3a51a7e3051dcce1d7619fb2f2f9c23 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 15:45:01 +0200 Subject: [PATCH 130/324] ISSUE #367 * Minor improvements related with exceptions. --- .../minos/aggregate/events/repositories/pg.py | 6 ++---- .../minos/common/__init__.py | 2 ++ .../minos/common/database/__init__.py | 2 ++ .../minos/common/database/clients/__init__.py | 2 ++ .../minos/common/database/clients/abc.py | 14 +++++++++++++- .../minos/common/database/clients/aiopg.py | 12 +++++++++--- .../filtered/validators/duplicates/pg.py | 7 +++---- 7 files changed, 33 insertions(+), 12 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py index 13fad3562..ef7be6b61 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py @@ -10,9 +10,6 @@ UUID, ) -from psycopg2 import ( - IntegrityError, -) from psycopg2.sql import ( SQL, Composable, @@ -24,6 +21,7 @@ NULL_UUID, Config, DatabaseMixin, + IntegrityException, ) from ...exceptions import ( @@ -65,7 +63,7 @@ async def _submit(self, entry: EventEntry, **kwargs) -> EventEntry: try: response = await self.submit_query_and_fetchone(query, params, lock=lock) - except IntegrityError: + except IntegrityException: raise EventRepositoryConflictException( f"{entry!r} could not be submitted due to a key (uuid, version, transaction) collision", await self.offset, diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 6d99f1e65..ab15312d5 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -17,10 +17,12 @@ AiopgDatabaseClient, DatabaseClient, DatabaseClientBuilder, + DatabaseClientException, DatabaseClientPool, DatabaseLock, DatabaseLockPool, DatabaseMixin, + IntegrityException, PostgreSqlLock, PostgreSqlLockPool, PostgreSqlMinosDatabase, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index defc25d46..da4b4d0ff 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -6,6 +6,8 @@ AiopgDatabaseClient, DatabaseClient, DatabaseClientBuilder, + DatabaseClientException, + IntegrityException, UnableToConnectException, ) from .locks import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py index 519d872c1..6ebd5a09c 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py @@ -1,6 +1,8 @@ from .abc import ( DatabaseClient, DatabaseClientBuilder, + DatabaseClientException, + IntegrityException, UnableToConnectException, ) from .aiopg import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 424f559f9..de74cc332 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -24,6 +24,9 @@ from ...config import ( Config, ) +from ...exceptions import ( + MinosException, +) class DatabaseClient(ABC, BuildableMixin): @@ -50,6 +53,7 @@ async def execute(self, *args, **kwargs) -> None: """TODO""" async def fetch_one(self, *args, **kwargs) -> Any: + """TODO""" return await self.fetch_all(*args, **kwargs).__anext__() @abstractmethod @@ -75,5 +79,13 @@ def with_config(self, config: Config) -> DatabaseClientBuilder: DatabaseClient.set_builder(DatabaseClientBuilder) -class UnableToConnectException(Exception): +class DatabaseClientException(MinosException): + """TODO""" + + +class UnableToConnectException(DatabaseClientException): + """TODO""" + + +class IntegrityException(DatabaseClientException): """TODO""" diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index b971bf699..60d1f2e1a 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -22,11 +22,13 @@ ClosableQueue, ) from psycopg2 import ( + IntegrityError, OperationalError, ) from .abc import ( DatabaseClient, + IntegrityException, UnableToConnectException, ) @@ -92,8 +94,9 @@ async def _create_connection(self): host=self.host, port=self.port, dbname=self.database, user=self.user, password=self.password ) except OperationalError as exc: - logger.warning(f"There was an {exc!r} while trying to get a database connection.") - raise UnableToConnectException + msg = f"There was an {exc!r} while trying to get a database connection." + logger.warning(msg) + raise UnableToConnectException(msg) logger.debug(f"Created {self.database!r} database connection identified by {id(self._connection)}!") @@ -171,7 +174,10 @@ async def execute( :return: This method does not return anything. """ await self._create_cursor(lock=lock) - await self._cursor.execute(operation=operation, parameters=parameters, timeout=timeout) + try: + await self._cursor.execute(operation=operation, parameters=parameters, timeout=timeout) + except IntegrityError as exc: + raise IntegrityException(f"The requested operation raised a integrity error: {exc!r}") async def _create_cursor(self, *args, lock: Optional[Hashable] = None, **kwargs): if self._cursor is None: diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py index 1c6163786..557092370 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py @@ -9,9 +9,6 @@ UUID, ) -from psycopg2 import ( - IntegrityError, -) from psycopg2.sql import ( SQL, ) @@ -20,6 +17,7 @@ Builder, Config, DatabaseMixin, + IntegrityException, ) from .abc import ( @@ -64,7 +62,7 @@ async def _is_unique(self, topic: str, uuid: UUID) -> bool: try: await self.submit_query(self._query_factory.build_insert_row(), {"topic": topic, "uuid": uuid}) return True - except IntegrityError: + except IntegrityException: return False @@ -84,6 +82,7 @@ def with_config(self, config: Config): PostgreSqlBrokerSubscriberDuplicateValidator.set_builder(PostgreSqlBrokerSubscriberDuplicateValidatorBuilder) +# noinspection SqlNoDataSourceInspection class PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory: """PostgreSql Broker Subscriber Duplicate Detector Query Factory class.""" From f5540ad14c927ffb8e6321d4bfeada32f48a4c0c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 16:05:52 +0200 Subject: [PATCH 131/324] ISSUE #367 * move streaming_mode management from `DatabaseClient` to `SnapshotReader`. --- .../minos/aggregate/snapshots/pg/readers.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py index 492438fce..290cfa111 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py @@ -128,5 +128,10 @@ async def find_entries( qb = PostgreSqlSnapshotQueryBuilder(name, condition, ordering, limit, transaction_uuids, exclude_deleted) query, parameters = qb.build() - async for row in self.submit_query_and_iter(query, parameters, streaming_mode=streaming_mode): - yield SnapshotEntry(*row) + async_iterable = self.submit_query_and_iter(query, parameters) + if streaming_mode: + async for row in async_iterable: + yield SnapshotEntry(*row) + else: + for row in [row async for row in async_iterable]: + yield SnapshotEntry(*row) From cc4bc7997045aebf7ae6c0695dbc361ba9733e87 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 16:29:59 +0200 Subject: [PATCH 132/324] ISSUE #367 * Add tests for `AiopgDatabaseClient`. --- .../minos/common/database/clients/aiopg.py | 56 +++--- .../test_database/test_clients/__init__.py | 0 .../test_database/test_clients/test_aiopg.py | 176 ++++++++++++++++++ 3 files changed, 210 insertions(+), 22 deletions(-) create mode 100644 packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/__init__.py create mode 100644 packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index 60d1f2e1a..c1e2ef8a2 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -41,7 +41,7 @@ class AiopgDatabaseClient(DatabaseClient): - """TODO""" + """Aiopg Database Client class.""" _connection: Optional[Connection] _cursor: Optional[Cursor] @@ -106,8 +106,11 @@ async def _close_connection(self): self._connection = None logger.debug(f"Destroyed {self.database!r} database connection identified by {id(self._connection)}!") - async def is_valid(self): - """TODO""" + async def is_valid(self) -> bool: + """Check if the instance is valid. + + :return: ``True`` if it is valid or ``False`` otherwise. + """ if self._connection is None: return False @@ -120,12 +123,12 @@ async def is_valid(self): return not self._connection.closed async def reset(self, **kwargs) -> None: - """TODO""" - await self._destroy_cursor(**kwargs) + """Reset the current instance status. - @property - def notifications(self) -> ClosableQueue: - return self._connection.notifies + :param kwargs: Additional named parameters. + :return: This method does not return anything. + """ + await self._destroy_cursor(**kwargs) # noinspection PyUnusedLocal async def fetch_all( @@ -133,7 +136,6 @@ async def fetch_all( *args, timeout: Optional[float] = None, lock: Optional[int] = None, - streaming_mode: bool = False, **kwargs, ) -> AsyncIterator[tuple]: """Submit a SQL query and return an asynchronous iterator. @@ -141,22 +143,12 @@ async def fetch_all( :param timeout: An optional timeout. :param lock: Optional key to perform the query with locking. If not set, the query is performed without any lock. - :param streaming_mode: If ``True`` the data fetching is performed in streaming mode, that is iterating over the - cursor and yielding once a time (requires an opening connection to do that). Otherwise, all the data is - fetched and keep in memory before yielding it. :param kwargs: Additional named arguments. :return: This method does not return anything. """ await self._create_cursor() - if streaming_mode: - async for row in self._cursor: - yield row - return - - rows = await self._cursor.fetchall() - - for row in rows: + async for row in self._cursor: yield row # noinspection PyUnusedLocal @@ -183,7 +175,11 @@ async def _create_cursor(self, *args, lock: Optional[Hashable] = None, **kwargs) if self._cursor is None: self._cursor = await self._connection.cursor(*args, **kwargs) - if lock is not None and self._lock is None: + if lock is not None: + if self._lock is not None: + if self._lock.key != lock: + raise ValueError(f"Only one lock per instance is supported. Currently locked with {self._lock!r}") + return from ..locks import ( DatabaseLock, ) @@ -197,10 +193,18 @@ async def _destroy_cursor(self, **kwargs): self._lock = None if self._cursor is not None: - if self._cursor.closed: + if not self._cursor.closed: self._cursor.close() self._cursor = None + @property + def lock(self) -> Optional[DatabaseLock]: + """Get the lock. + + :return: A ``DatabaseLock`` instance. + """ + return self._lock + @property def cursor(self) -> Optional[Cursor]: """Get the cursor. @@ -209,6 +213,14 @@ def cursor(self) -> Optional[Cursor]: """ return self._cursor + @property + def notifications(self) -> ClosableQueue: + """Get the notifications queue. + + :return: A ``ClosableQueue`` instance. + """ + return self._connection.notifies + @property def connection(self) -> Optional[Connection]: """Get the connection. diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/__init__.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py new file mode 100644 index 000000000..15582a14a --- /dev/null +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py @@ -0,0 +1,176 @@ +import unittest +from unittest.mock import ( + PropertyMock, + call, + patch, +) + +import aiopg +from aiopg import ( + Connection, + Cursor, +) +from psycopg2 import ( + IntegrityError, + OperationalError, +) + +from minos.common import ( + AiopgDatabaseClient, + DatabaseLock, + IntegrityException, + UnableToConnectException, +) +from minos.common.testing import ( + PostgresAsyncTestCase, +) +from tests.utils import ( + CommonTestCase, +) + + +# noinspection SqlNoDataSourceInspection +class TestAiopgDatabaseClient(CommonTestCase, PostgresAsyncTestCase): + def setUp(self): + super().setUp() + self.sql = "SELECT * FROM information_schema.tables" + + def test_constructor(self): + client = AiopgDatabaseClient("foo") + self.assertEqual("foo", client.database) + self.assertEqual("postgres", client.user) + self.assertEqual("", client.password) + self.assertEqual("localhost", client.host) + self.assertEqual(5432, client.port) + + def test_from_config(self): + default_database = self.config.get_default_database() + client = AiopgDatabaseClient.from_config(self.config) + self.assertEqual(default_database["database"], client.database) + self.assertEqual(default_database["user"], client.user) + self.assertEqual(default_database["password"], client.password) + self.assertEqual(default_database["host"], client.host) + self.assertEqual(default_database["port"], client.port) + + async def test_is_valid_true(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + self.assertTrue(client.is_valid()) + + async def test_is_valid_false_not_setup(self): + client = AiopgDatabaseClient.from_config(self.config) + self.assertFalse(await client.is_valid()) + + async def test_is_valid_false_operational_error(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + with patch.object(Connection, "isolation_level", new_callable=PropertyMock, side_effect=OperationalError): + self.assertFalse(await client.is_valid()) + + async def test_is_valid_false_closed(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + with patch.object(Connection, "closed", new_callable=PropertyMock, return_valud=False): + self.assertFalse(await client.is_valid()) + + async def test_connection(self): + client = AiopgDatabaseClient.from_config(self.config) + self.assertIsNone(client.connection) + async with client: + self.assertIsInstance(client.connection, Connection) + self.assertIsNone(client.connection) + + async def test_connection_raises(self): + with patch.object(aiopg, "connect", new_callable=PropertyMock, side_effect=OperationalError): + with self.assertRaises(UnableToConnectException): + async with AiopgDatabaseClient.from_config(self.config): + pass + + async def test_notifications(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + self.assertEqual(client.connection.notifies, client.notifications) + + async def test_cursor(self): + client = AiopgDatabaseClient.from_config(self.config) + self.assertIsNone(client.cursor) + async with client: + self.assertIsNone(client.cursor) + await client.execute("SELECT * FROM information_schema.tables") + self.assertIsInstance(client.cursor, Cursor) + + self.assertIsNone(client.cursor) + + async def test_cursor_reset(self): + client = AiopgDatabaseClient.from_config(self.config) + async with client: + await client.execute("SELECT * FROM information_schema.tables") + self.assertIsInstance(client.cursor, Cursor) + await client.reset() + self.assertIsNone(client.cursor) + + async def test_lock(self): + client = AiopgDatabaseClient.from_config(self.config) + self.assertIsNone(client.lock) + async with client: + self.assertIsNone(client.lock) + await client.execute(self.sql, lock="foo") + self.assertIsInstance(client.lock, DatabaseLock) + + self.assertIsNone(client.lock) + + async def test_lock_reset(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + await client.execute(self.sql, lock="foo") + self.assertIsInstance(client.lock, DatabaseLock) + await client.reset() + self.assertIsNone(client.lock) + + async def test_execute(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + with patch.object(Cursor, "execute") as execute_mock: + await client.execute(self.sql) + self.assertEqual( + [call(operation=self.sql, parameters=None, timeout=None)], + execute_mock.call_args_list, + ) + + async def test_execute_with_lock(self): + with patch.object(DatabaseLock, "__aenter__") as enter_lock_mock: + with patch.object(DatabaseLock, "__aexit__") as exit_lock_mock: + async with AiopgDatabaseClient.from_config(self.config) as client: + await client.execute(self.sql, lock="foo") + self.assertEqual(1, enter_lock_mock.call_count) + self.assertEqual(0, exit_lock_mock.call_count) + enter_lock_mock.reset_mock() + exit_lock_mock.reset_mock() + self.assertEqual(0, enter_lock_mock.call_count) + self.assertEqual(1, exit_lock_mock.call_count) + + async def test_execute_with_lock_multiple(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + await client.execute(self.sql, lock="foo") + await client.execute(self.sql, lock="foo") + with self.assertRaises(ValueError): + await client.execute(self.sql, lock="bar") + + async def test_execute_raises_integrity(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + with patch.object(Cursor, "execute", side_effect=IntegrityError): + with self.assertRaises(IntegrityException): + await client.execute(self.sql) + + async def test_fetch_one(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + await client.execute(self.sql) + observed = await client.fetch_one() + self.assertIsInstance(observed, tuple) + + async def test_fetch_all(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + await client.execute(self.sql) + observed = [value async for value in client.fetch_all()] + + self.assertGreater(len(observed), 0) + for obs in observed: + self.assertIsInstance(obs, tuple) + + +if __name__ == "__main__": + unittest.main() From 25760d4325f5356fefc8606d50a08a5cea368ff9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 5 Apr 2022 16:59:55 +0200 Subject: [PATCH 133/324] ISSUE #367 * Increase coverage up to "100%". * Improve `Lock` API. --- .../tests/utils.py | 7 +- .../minos/common/database/clients/__init__.py | 8 +- .../minos/common/database/clients/abc.py | 74 ++++++++++++------- .../minos/common/database/clients/aiopg.py | 10 ++- .../common/database/clients/exceptions.py | 15 ++++ .../minos/common/database/locks.py | 13 +++- .../minos/common/database/pools.py | 2 +- .../minos/common/locks.py | 27 ++++++- .../test_database/test_clients/test_abc.py | 45 +++++++++++ .../test_database/test_clients/test_aiopg.py | 6 +- .../test_common/test_database/test_pools.py | 43 +++++------ .../minos-microservice-common/tests/utils.py | 7 +- .../minos-microservice-saga/tests/utils.py | 7 +- 13 files changed, 189 insertions(+), 75 deletions(-) create mode 100644 packages/core/minos-microservice-common/minos/common/database/clients/exceptions.py create mode 100644 packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 1c18b0b79..908121875 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -101,8 +101,11 @@ def __init__(self, key=None, *args, **kwargs): key = "fake" super().__init__(key, *args, **kwargs) - async def __aexit__(self, exc_type, exc_val, exc_tb): - return + async def acquire(self) -> None: + """For testing purposes.""" + + async def release(self): + """For testing purposes.""" class FakeLockPool(LockPool): diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py index 6ebd5a09c..a2884b3c4 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py @@ -1,10 +1,12 @@ from .abc import ( DatabaseClient, DatabaseClientBuilder, - DatabaseClientException, - IntegrityException, - UnableToConnectException, ) from .aiopg import ( AiopgDatabaseClient, ) +from .exceptions import ( + DatabaseClientException, + IntegrityException, + UnableToConnectException, +) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index de74cc332..3e11f203b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -24,13 +24,10 @@ from ...config import ( Config, ) -from ...exceptions import ( - MinosException, -) class DatabaseClient(ABC, BuildableMixin): - """TODO""" + """Database Client base class.""" @classmethod def _from_config(cls, config: Config, name: Optional[str] = None, **kwargs) -> DatabaseClient: @@ -38,54 +35,75 @@ def _from_config(cls, config: Config, name: Optional[str] = None, **kwargs) -> D @abstractmethod async def is_valid(self, **kwargs) -> bool: - """TODO""" + """Check if the instance is valid. + + :return: ``True`` if it is valid or ``False`` otherwise. + """ async def reset(self, **kwargs) -> None: - """TODO""" + """Reset the current instance status. - @property - @abstractmethod - def notifications(self) -> Queue: - """TODO""" + :param kwargs: Additional named parameters. + :return: This method does not return anything. + """ @abstractmethod async def execute(self, *args, **kwargs) -> None: - """TODO""" + """Execute an operation. + + :param args: Additional positional arguments. + :param kwargs: Additional named arguments. + :return: This method does not return anything. + """ async def fetch_one(self, *args, **kwargs) -> Any: - """TODO""" + """Fetch one value. + + :param args: Additional positional arguments. + :param kwargs: Additional named arguments. + :return: This method does not return anything. + """ return await self.fetch_all(*args, **kwargs).__anext__() @abstractmethod def fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: - """TODO""" + """Fetch all values with an asynchronous iterator. + + :param args: Additional positional arguments. + :param kwargs: Additional named arguments. + :return: This method does not return anything. + """ + + @property + @abstractmethod + def notifications(self) -> Queue: + """Get the notifications queue. + + :return: A ``Queue`` instance. + """ class DatabaseClientBuilder(Builder[DatabaseClient]): - """TODO""" + """Database Client Builder class.""" def with_name(self, name: str) -> DatabaseClientBuilder: - """TODO""" + """Set name. + + :param name: The name to be added. + :return: This method return the builder instance. + """ self.kwargs["name"] = name return self def with_config(self, config: Config) -> DatabaseClientBuilder: - """TODO""" + """Set config. + + :param config: The config to be set. + :return: This method return the builder instance. + """ database_config = config.get_database_by_name(self.kwargs.get("name")) self.kwargs |= database_config return self DatabaseClient.set_builder(DatabaseClientBuilder) - - -class DatabaseClientException(MinosException): - """TODO""" - - -class UnableToConnectException(DatabaseClientException): - """TODO""" - - -class IntegrityException(DatabaseClientException): - """TODO""" diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index c1e2ef8a2..64f3e2fb1 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -28,6 +28,8 @@ from .abc import ( DatabaseClient, +) +from .exceptions import ( IntegrityException, UnableToConnectException, ) @@ -138,7 +140,7 @@ async def fetch_all( lock: Optional[int] = None, **kwargs, ) -> AsyncIterator[tuple]: - """Submit a SQL query and return an asynchronous iterator. + """Fetch all values with an asynchronous iterator. :param timeout: An optional timeout. :param lock: Optional key to perform the query with locking. If not set, the query is performed without any @@ -155,7 +157,7 @@ async def fetch_all( async def execute( self, operation: Any, parameters: Any = None, *, timeout: Optional[float] = None, lock: Any = None, **kwargs ) -> None: - """Submit a SQL query. + """Execute an operation. :param operation: Query to be executed. :param parameters: Parameters to be projected into the query. @@ -185,11 +187,11 @@ async def _create_cursor(self, *args, lock: Optional[Hashable] = None, **kwargs) ) self._lock = DatabaseLock(self, lock, *args, **kwargs) - await self._lock.__aenter__() + await self._lock.acquire() async def _destroy_cursor(self, **kwargs): if self._lock is not None: - await self._lock.__aexit__(None, None, None) + await self._lock.release() self._lock = None if self._cursor is not None: diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/exceptions.py b/packages/core/minos-microservice-common/minos/common/database/clients/exceptions.py new file mode 100644 index 000000000..d638a738c --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/clients/exceptions.py @@ -0,0 +1,15 @@ +from ...exceptions import ( + MinosException, +) + + +class DatabaseClientException(MinosException): + """Base exception for database client.""" + + +class UnableToConnectException(DatabaseClientException): + """Exception to be raised when database client is not able to connect to the database.""" + + +class IntegrityException(DatabaseClientException): + """Exception to be raised when an integrity check is not satisfied.""" diff --git a/packages/core/minos-microservice-common/minos/common/database/locks.py b/packages/core/minos-microservice-common/minos/common/database/locks.py index b22d3f9e4..1a0a8ae18 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks.py @@ -19,11 +19,18 @@ def __init__(self, client: DatabaseClient, key: Hashable, *args, **kwargs): self.client = client - async def __aenter__(self): + async def acquire(self) -> None: + """Acquire the lock. + + :return: This method does not return anything. + """ await self.client.execute("select pg_advisory_lock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) - return self - async def __aexit__(self, exc_type, exc_val, exc_tb): + async def release(self) -> None: + """Release the lock. + + :return: This method does not return anything. + """ await self.client.execute("select pg_advisory_unlock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index a363ba7d3..926fca84c 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -62,7 +62,7 @@ async def _create_instance(self) -> Optional[DatabaseClient]: try: await instance.setup() except UnableToConnectException: - await sleep(1) + await sleep(0.1) return None logger.info(f"Created {instance!r}!") diff --git a/packages/core/minos-microservice-common/minos/common/locks.py b/packages/core/minos-microservice-common/minos/common/locks.py index d52a602dd..1366370e2 100644 --- a/packages/core/minos-microservice-common/minos/common/locks.py +++ b/packages/core/minos-microservice-common/minos/common/locks.py @@ -4,13 +4,11 @@ from abc import ( ABC, + abstractmethod, ) from collections.abc import ( Hashable, ) -from contextlib import ( - AbstractAsyncContextManager, -) from cached_property import ( cached_property, @@ -24,7 +22,7 @@ ) -class Lock(AbstractAsyncContextManager): +class Lock(ABC): """Lock base class.""" key: Hashable @@ -35,6 +33,27 @@ def __init__(self, key: Hashable, *args, **kwargs): self.key = key + async def __aenter__(self) -> Lock: + await self.acquire() + return self + + async def __aexit__(self, exc_type, exc_val, exc_tb): + await self.release() + + @abstractmethod + async def acquire(self) -> None: + """Acquire the lock. + + :return: This method does not return anything. + """ + + @abstractmethod + async def release(self): + """Release the lock. + + :return: This method does not return anything. + """ + @cached_property def hashed_key(self) -> int: """Get the hashed key. diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py new file mode 100644 index 000000000..e2b89d150 --- /dev/null +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -0,0 +1,45 @@ +import unittest +from abc import ( + ABC, +) + +from minos.common import ( + AiopgDatabaseClient, + BuildableMixin, + DatabaseClient, + DatabaseClientBuilder, +) +from tests.utils import ( + CommonTestCase, +) + + +class TestDatabaseClient(unittest.IsolatedAsyncioTestCase): + def test_abstract(self): + self.assertTrue(issubclass(DatabaseClient, (ABC, BuildableMixin))) + # noinspection PyUnresolvedReferences + self.assertEqual({"notifications", "is_valid", "execute", "fetch_all"}, DatabaseClient.__abstractmethods__) + + def test_get_builder(self): + self.assertIsInstance(DatabaseClient.get_builder(), DatabaseClientBuilder) + + +class TestDatabaseClientBuilder(CommonTestCase): + def test_with_name(self): + builder = DatabaseClientBuilder(AiopgDatabaseClient).with_name("query") + self.assertEqual({"name": "query"}, builder.kwargs) + + def test_with_config(self): + builder = DatabaseClientBuilder(AiopgDatabaseClient).with_name("query").with_config(self.config) + self.assertEqual({"name": "query"} | self.config.get_database_by_name("query"), builder.kwargs) + + def test_build(self): + builder = DatabaseClientBuilder(AiopgDatabaseClient).with_name("query").with_config(self.config) + client = builder.build() + + self.assertIsInstance(client, AiopgDatabaseClient) + self.assertEqual(self.config.get_database_by_name("query")["database"], client.database) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py index 15582a14a..13a64e58a 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py @@ -54,7 +54,7 @@ def test_from_config(self): async def test_is_valid_true(self): async with AiopgDatabaseClient.from_config(self.config) as client: - self.assertTrue(client.is_valid()) + self.assertTrue(await client.is_valid()) async def test_is_valid_false_not_setup(self): client = AiopgDatabaseClient.from_config(self.config) @@ -132,8 +132,8 @@ async def test_execute(self): ) async def test_execute_with_lock(self): - with patch.object(DatabaseLock, "__aenter__") as enter_lock_mock: - with patch.object(DatabaseLock, "__aexit__") as exit_lock_mock: + with patch.object(DatabaseLock, "acquire") as enter_lock_mock: + with patch.object(DatabaseLock, "release") as exit_lock_mock: async with AiopgDatabaseClient.from_config(self.config) as client: await client.execute(self.sql, lock="foo") self.assertEqual(1, enter_lock_mock.call_count) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index 3f61b0803..fe7ff66ce 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -1,15 +1,9 @@ import unittest import warnings from unittest.mock import ( - PropertyMock, patch, ) -import aiopg -from psycopg2 import ( - OperationalError, -) - from minos.common import ( AiopgDatabaseClient, DatabaseClient, @@ -19,6 +13,7 @@ DatabaseLockPool, PostgreSqlLockPool, PostgreSqlPool, + UnableToConnectException, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -51,30 +46,32 @@ def test_from_config(self): self.assertIsInstance(pool.client_builder, DatabaseClientBuilder) self.assertEqual(AiopgDatabaseClient, pool.client_builder.instance_cls) - async def test_acquire(self): + async def test_acquire_once(self): async with self.pool.acquire() as c1: self.assertIsInstance(c1, DatabaseClient) + + async def test_acquire_multiple_recycle(self): + async with self.pool.acquire() as c1: + pass async with self.pool.acquire() as c2: self.assertEqual(c1, c2) - async def test_acquire_with_error(self): - with patch("aiopg.Connection.isolation_level", new_callable=PropertyMock, side_effect=(OperationalError, None)): - async with self.pool.acquire() as client: - self.assertIsInstance(client, DatabaseClient) + async def test_acquire_multiple_same_time(self): + async with self.pool.acquire() as c1: + async with self.pool.acquire() as c2: + self.assertNotEqual(c1, c2) + + async def test_acquire_with_reset(self): + with patch.object(AiopgDatabaseClient, "reset") as reset_mock: + async with self.pool.acquire(): + self.assertEqual(0, reset_mock.call_count) + self.assertEqual(1, reset_mock.call_count) async def test_acquire_with_connection_error(self): - executed = [False] - original = aiopg.connect - - def _side_effect(*args, **kwargs): - if not executed[0]: - executed[0] = True - raise OperationalError - return original(*args, **kwargs) - - with patch("aiopg.connect", side_effect=_side_effect): - async with self.pool.acquire() as client: - self.assertIsInstance(client, DatabaseClient) + with patch.object(AiopgDatabaseClient, "_create_connection", side_effect=(UnableToConnectException(""), None)): + with patch.object(AiopgDatabaseClient, "is_valid", return_value=True): + async with self.pool.acquire() as client: + self.assertIsInstance(client, AiopgDatabaseClient) class TestPostgreSqlPool(CommonTestCase, PostgresAsyncTestCase): diff --git a/packages/core/minos-microservice-common/tests/utils.py b/packages/core/minos-microservice-common/tests/utils.py index fb4f622a1..d54835fe6 100644 --- a/packages/core/minos-microservice-common/tests/utils.py +++ b/packages/core/minos-microservice-common/tests/utils.py @@ -73,8 +73,11 @@ def __init__(self, key=None, *args, **kwargs): key = "fake" super().__init__(key, *args, **kwargs) - async def __aexit__(self, exc_type, exc_val, exc_tb): - return + async def acquire(self) -> None: + """For testing purposes.""" + + async def release(self): + """For testing purposes.""" class FakeLockPool(LockPool): diff --git a/packages/core/minos-microservice-saga/tests/utils.py b/packages/core/minos-microservice-saga/tests/utils.py index 44ba22a74..f8234e5b6 100644 --- a/packages/core/minos-microservice-saga/tests/utils.py +++ b/packages/core/minos-microservice-saga/tests/utils.py @@ -85,8 +85,11 @@ def __init__(self, key=None, *args, **kwargs): key = "fake" super().__init__(key, *args, **kwargs) - async def __aexit__(self, exc_type, exc_val, exc_tb): - return + async def acquire(self) -> None: + """For testing purposes.""" + + async def release(self): + """For testing purposes.""" class FakeLockPool(LockPool): From 9744e15b48679a5f3f5a2204e701e78cf2535383 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 09:30:24 +0200 Subject: [PATCH 134/324] ISSUE #367 * Fix bug. --- .../test_aggregate/test_events/test_repositories/test_pg.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index af034f447..a215d5c73 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -41,7 +41,7 @@ async def test_setup(self): await client.execute( "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_event');" ) - response = (await client.fetchone())[0] + response = (await client.fetch_one())[0] self.assertTrue(response) From cc9a55d03b32216a8b9db20e15311c8c6b7ac100 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 09:30:46 +0200 Subject: [PATCH 135/324] ISSUE #367 * Improve `DatabaseClient` class. --- .../minos/common/database/clients/abc.py | 29 +++++- .../minos/common/database/clients/aiopg.py | 41 +------- .../test_database/test_clients/test_abc.py | 93 ++++++++++++++++++- 3 files changed, 122 insertions(+), 41 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 3e11f203b..5e48da019 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -33,12 +33,16 @@ class DatabaseClient(ABC, BuildableMixin): def _from_config(cls, config: Config, name: Optional[str] = None, **kwargs) -> DatabaseClient: return super()._from_config(config, **config.get_database_by_name(name), **kwargs) - @abstractmethod async def is_valid(self, **kwargs) -> bool: """Check if the instance is valid. :return: ``True`` if it is valid or ``False`` otherwise. """ + return await self._is_valid(**kwargs) + + @abstractmethod + async def _is_valid(self, **kwargs) -> bool: + raise NotImplementedError async def reset(self, **kwargs) -> None: """Reset the current instance status. @@ -46,8 +50,12 @@ async def reset(self, **kwargs) -> None: :param kwargs: Additional named parameters. :return: This method does not return anything. """ + return await self._reset(**kwargs) @abstractmethod + async def _reset(self, **kwargs) -> None: + raise NotImplementedError + async def execute(self, *args, **kwargs) -> None: """Execute an operation. @@ -55,6 +63,11 @@ async def execute(self, *args, **kwargs) -> None: :param kwargs: Additional named arguments. :return: This method does not return anything. """ + await self._execute(*args, **kwargs) + + @abstractmethod + async def _execute(self, *args, **kwargs) -> None: + raise NotImplementedError async def fetch_one(self, *args, **kwargs) -> Any: """Fetch one value. @@ -65,22 +78,30 @@ async def fetch_one(self, *args, **kwargs) -> Any: """ return await self.fetch_all(*args, **kwargs).__anext__() - @abstractmethod def fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: """Fetch all values with an asynchronous iterator. - :param args: Additional positional arguments. :param kwargs: Additional named arguments. :return: This method does not return anything. """ + return self._fetch_all(*args, **kwargs) - @property @abstractmethod + def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: + raise NotImplementedError + + @property def notifications(self) -> Queue: """Get the notifications queue. :return: A ``Queue`` instance. """ + return self._notifications + + @property + @abstractmethod + def _notifications(self) -> Queue: + raise NotImplementedError class DatabaseClientBuilder(Builder[DatabaseClient]): diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index 64f3e2fb1..551a279b6 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -108,11 +108,7 @@ async def _close_connection(self): self._connection = None logger.debug(f"Destroyed {self.database!r} database connection identified by {id(self._connection)}!") - async def is_valid(self) -> bool: - """Check if the instance is valid. - - :return: ``True`` if it is valid or ``False`` otherwise. - """ + async def _is_valid(self) -> bool: if self._connection is None: return False @@ -124,49 +120,26 @@ async def is_valid(self) -> bool: return not self._connection.closed - async def reset(self, **kwargs) -> None: - """Reset the current instance status. - - :param kwargs: Additional named parameters. - :return: This method does not return anything. - """ + async def _reset(self, **kwargs) -> None: await self._destroy_cursor(**kwargs) # noinspection PyUnusedLocal - async def fetch_all( + async def _fetch_all( self, *args, timeout: Optional[float] = None, lock: Optional[int] = None, **kwargs, ) -> AsyncIterator[tuple]: - """Fetch all values with an asynchronous iterator. - - :param timeout: An optional timeout. - :param lock: Optional key to perform the query with locking. If not set, the query is performed without any - lock. - :param kwargs: Additional named arguments. - :return: This method does not return anything. - """ await self._create_cursor() async for row in self._cursor: yield row # noinspection PyUnusedLocal - async def execute( + async def _execute( self, operation: Any, parameters: Any = None, *, timeout: Optional[float] = None, lock: Any = None, **kwargs ) -> None: - """Execute an operation. - - :param operation: Query to be executed. - :param parameters: Parameters to be projected into the query. - :param timeout: An optional timeout. - :param lock: Optional key to perform the query with locking. If not set, the query is performed without any - lock. - :param kwargs: Additional named arguments. - :return: This method does not return anything. - """ await self._create_cursor(lock=lock) try: await self._cursor.execute(operation=operation, parameters=parameters, timeout=timeout) @@ -216,11 +189,7 @@ def cursor(self) -> Optional[Cursor]: return self._cursor @property - def notifications(self) -> ClosableQueue: - """Get the notifications queue. - - :return: A ``ClosableQueue`` instance. - """ + def _notifications(self) -> ClosableQueue: return self._connection.notifies @property diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index e2b89d150..0ef24717e 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -2,6 +2,20 @@ from abc import ( ABC, ) +from asyncio import ( + Queue, +) +from typing import ( + Any, + AsyncIterator, +) +from unittest.mock import ( + AsyncMock, + MagicMock, + PropertyMock, + call, + patch, +) from minos.common import ( AiopgDatabaseClient, @@ -11,18 +25,95 @@ ) from tests.utils import ( CommonTestCase, + FakeAsyncIterator, ) +class _DatabaseClient(DatabaseClient): + """For testing purposes.""" + + async def _is_valid(self, **kwargs) -> bool: + """For testing purposes.""" + + async def _reset(self, **kwargs) -> None: + """For testing purposes.""" + + async def _execute(self, *args, **kwargs) -> None: + """For testing purposes.""" + + def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: + """For testing purposes.""" + + # noinspection PyPropertyDefinition + @property + def _notifications(self) -> Queue: + """For testing purposes.""" + + class TestDatabaseClient(unittest.IsolatedAsyncioTestCase): def test_abstract(self): self.assertTrue(issubclass(DatabaseClient, (ABC, BuildableMixin))) + expected = {"_notifications", "_is_valid", "_execute", "_fetch_all", "_reset"} # noinspection PyUnresolvedReferences - self.assertEqual({"notifications", "is_valid", "execute", "fetch_all"}, DatabaseClient.__abstractmethods__) + self.assertEqual(expected, DatabaseClient.__abstractmethods__) def test_get_builder(self): self.assertIsInstance(DatabaseClient.get_builder(), DatabaseClientBuilder) + async def test_is_valid(self): + mock = AsyncMock(side_effect=[True, False]) + client = _DatabaseClient() + client._is_valid = mock + + self.assertEqual(True, await client.is_valid()) + self.assertEqual(False, await client.is_valid()) + + self.assertEqual([call(), call()], mock.call_args_list) + + async def test_reset(self): + mock = AsyncMock() + client = _DatabaseClient() + client._reset = mock + + await client.reset() + + self.assertEqual([call()], mock.call_args_list) + + async def test_execute(self): + mock = AsyncMock() + client = _DatabaseClient() + client._execute = mock + + await client.execute("foo") + + self.assertEqual([call("foo")], mock.call_args_list) + + async def test_fetch_all(self): + mock = MagicMock(return_value=FakeAsyncIterator(["one", "two"])) + client = _DatabaseClient() + client._fetch_all = mock + + self.assertEqual(["one", "two"], [v async for v in client.fetch_all()]) + + self.assertEqual([call()], mock.call_args_list) + + async def test_fetch_one(self): + mock = MagicMock(return_value=FakeAsyncIterator(["one", "two"])) + client = _DatabaseClient() + client._fetch_all = mock + + self.assertEqual("one", await client.fetch_one()) + + self.assertEqual([call()], mock.call_args_list) + + async def test_notifications(self): + expected = Queue() + client = _DatabaseClient() + with patch.object(_DatabaseClient, "_notifications", new_callable=PropertyMock, return_value=expected) as mock: + self.assertEqual(expected, client.notifications) + + self.assertEqual([call()], mock.call_args_list) + class TestDatabaseClientBuilder(CommonTestCase): def test_with_name(self): From e8df1cbfdbf7ebdce6ad7350e177796c2cd9126a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 09:18:56 +0200 Subject: [PATCH 136/324] ISSUE #371 * Add `DatabaseOperation`. * Add `AiopgDatabaseOperation`. * Add `ComposedDatabaseOperation`. * Add `EventRepositoryOperationFactory`. * Add `AiopgEventRepositoryOperationFactory`. * Refactor `PostgreSqlEventRepository` as `DatabaseEventRepository`. --- .../minos/aggregate/__init__.py | 3 + .../minos/aggregate/events/__init__.py | 3 + .../aggregate/events/repositories/__init__.py | 9 +- .../events/repositories/database/__init__.py | 8 + .../database/factories/__init__.py | 6 + .../repositories/database/factories/abc.py | 68 +++++ .../repositories/database/factories/aiopg.py | 236 ++++++++++++++++++ .../events/repositories/database/impl.py | 92 +++++++ .../minos/aggregate/events/repositories/pg.py | 235 ----------------- .../minos/common/__init__.py | 3 + .../minos/common/database/__init__.py | 5 + .../minos/common/database/clients/abc.py | 40 ++- .../minos/common/database/clients/aiopg.py | 65 ++--- .../common/database/operations/__init__.py | 7 + .../minos/common/database/operations/abc.py | 22 ++ .../minos/common/database/operations/aiopg.py | 29 +++ .../test_database/test_clients/test_abc.py | 3 +- 17 files changed, 551 insertions(+), 283 deletions(-) create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py delete mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/operations/__init__.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/operations/abc.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index 95ec86a09..3580bc9c2 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -29,9 +29,12 @@ RootEntity, ) from .events import ( + AiopgEventRepositoryOperationFactory, + DatabaseEventRepository, Event, EventEntry, EventRepository, + EventRepositoryOperationFactory, FieldDiff, FieldDiffContainer, IncrementalFieldDiff, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py index 7dcf102ef..235db363c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py @@ -10,7 +10,10 @@ Event, ) from .repositories import ( + AiopgEventRepositoryOperationFactory, + DatabaseEventRepository, EventRepository, + EventRepositoryOperationFactory, InMemoryEventRepository, PostgreSqlEventRepository, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py index c95c37099..878602383 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py @@ -1,9 +1,12 @@ from .abc import ( EventRepository, ) +from .database import ( + AiopgEventRepositoryOperationFactory, + DatabaseEventRepository, + EventRepositoryOperationFactory, + PostgreSqlEventRepository, +) from .memory import ( InMemoryEventRepository, ) -from .pg import ( - PostgreSqlEventRepository, -) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py new file mode 100644 index 000000000..13004bbcb --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py @@ -0,0 +1,8 @@ +from .factories import ( + AiopgEventRepositoryOperationFactory, + EventRepositoryOperationFactory, +) +from .impl import ( + DatabaseEventRepository, + PostgreSqlEventRepository, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py new file mode 100644 index 000000000..8bc76f7ea --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py @@ -0,0 +1,6 @@ +from .abc import ( + EventRepositoryOperationFactory, +) +from .aiopg import ( + AiopgEventRepositoryOperationFactory, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py new file mode 100644 index 000000000..7fa4104cc --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py @@ -0,0 +1,68 @@ +from abc import ( + abstractmethod, +) +from typing import ( + Optional, +) +from uuid import ( + UUID, +) + +from minos.common import ( + DatabaseOperation, + datetime, +) + +from .....actions import ( + Action, +) + + +class EventRepositoryOperationFactory: + """TODO""" + + @abstractmethod + def build_create_table(self) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_submit_row( + self, + transaction_uuids: tuple[UUID], + uuid: UUID, + action: Action, + name: str, + version: int, + data: bytes, + created_at: datetime, + transaction_uuid: UUID, + lock: Optional[str], + **kwargs, + ) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_select_rows( + self, + uuid: Optional[UUID] = None, + name: Optional[str] = None, + version: Optional[int] = None, + version_lt: Optional[int] = None, + version_gt: Optional[int] = None, + version_le: Optional[int] = None, + version_ge: Optional[int] = None, + id: Optional[int] = None, + id_lt: Optional[int] = None, + id_gt: Optional[int] = None, + id_le: Optional[int] = None, + id_ge: Optional[int] = None, + transaction_uuid: Optional[UUID] = None, + transaction_uuid_ne: Optional[UUID] = None, + transaction_uuid_in: Optional[tuple[UUID, ...]] = None, + **kwargs, + ) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_select_max_id(self) -> DatabaseOperation: + """TODO""" diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py new file mode 100644 index 000000000..b45719c13 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py @@ -0,0 +1,236 @@ +from typing import ( + Optional, +) +from uuid import ( + UUID, +) + +from psycopg2.sql import ( + SQL, + Literal, + Placeholder, +) + +from minos.common import ( + AiopgDatabaseOperation, + ComposedDatabaseOperation, + DatabaseOperation, + datetime, +) + +from .....actions import ( + Action, +) +from .abc import ( + EventRepositoryOperationFactory, +) + + +# noinspection SqlNoDataSourceInspection,SqlResolve,PyMethodMayBeStatic +class AiopgEventRepositoryOperationFactory(EventRepositoryOperationFactory): + """TODO""" + + def build_create_table(self) -> DatabaseOperation: + """TODO""" + return ComposedDatabaseOperation( + [ + AiopgDatabaseOperation( + 'CREATE EXTENSION IF NOT EXISTS "uuid-ossp";', + lock="aggregate_event", + ), + AiopgDatabaseOperation( + """ + DO + $$ + BEGIN + IF NOT EXISTS(SELECT * + FROM pg_type typ + INNER JOIN pg_namespace nsp + ON nsp.oid = typ.typnamespace + WHERE nsp.nspname = current_schema() + AND typ.typname = 'action_type') THEN + CREATE TYPE action_type AS ENUM ('create', 'update', 'delete'); + END IF; + END; + $$ + LANGUAGE plpgsql; + """, + lock="aggregate_event", + ), + AiopgDatabaseOperation( + """ + CREATE TABLE IF NOT EXISTS aggregate_event ( + id BIGSERIAL PRIMARY KEY, + action ACTION_TYPE NOT NULL, + uuid UUID NOT NULL, + name TEXT NOT NULL, + version INT NOT NULL, + data BYTEA NOT NULL, + created_at TIMESTAMPTZ NOT NULL, + transaction_uuid UUID NOT NULL DEFAULT uuid_nil(), + UNIQUE (uuid, version, transaction_uuid) + ); + """, + lock="aggregate_event", + ), + ] + ) + + def build_submit_row( + self, + transaction_uuids: tuple[UUID], + uuid: UUID, + action: Action, + name: str, + version: int, + data: bytes, + created_at: datetime, + transaction_uuid: UUID, + lock: Optional[str], + **kwargs, + ) -> DatabaseOperation: + """TODO""" + insert_values = SQL( + """ + INSERT INTO aggregate_event (id, action, uuid, name, version, data, created_at, transaction_uuid) + VALUES ( + default, + %(action)s, + CASE %(uuid)s WHEN uuid_nil() THEN uuid_generate_v4() ELSE %(uuid)s END, + %(name)s, + ( + SELECT (CASE WHEN %(version)s IS NULL THEN 1 + COALESCE(MAX(t2.version), 0) ELSE %(version)s END) + FROM ( + SELECT DISTINCT ON (t1.uuid) t1.version + FROM ( {from_parts} ) AS t1 + ORDER BY t1.uuid, t1.transaction_index DESC + ) AS t2 + ), + %(data)s, + (CASE WHEN %(created_at)s IS NULL THEN NOW() ELSE %(created_at)s END), + %(transaction_uuid)s + ) + RETURNING id, uuid, version, created_at; + """ + ) + + select_transaction = SQL( + """ + SELECT {index} AS transaction_index, uuid, MAX(version) AS version + FROM aggregate_event + WHERE uuid = %(uuid)s AND transaction_uuid = {transaction_uuid} + GROUP BY uuid + """ + ) + + from_query_parts = list() + parameters = dict() + for index, transaction_uuid in enumerate(transaction_uuids, start=1): + transaction_name = f"transaction_uuid_{index}" + parameters[transaction_name] = transaction_uuid + + from_query_parts.append( + select_transaction.format(index=Literal(index), transaction_uuid=Placeholder(transaction_name)) + ) + + from_query = SQL(" UNION ALL ").join(from_query_parts) + + query = insert_values.format(from_parts=from_query) + + parameters |= { + "uuid": uuid, + "action": action, + "name": name, + "version": version, + "data": data, + "created_at": created_at, + "transaction_uuid": transaction_uuid, + } + + return AiopgDatabaseOperation(query, parameters, lock) + + def build_select_rows( + self, + uuid: Optional[UUID] = None, + name: Optional[str] = None, + version: Optional[int] = None, + version_lt: Optional[int] = None, + version_gt: Optional[int] = None, + version_le: Optional[int] = None, + version_ge: Optional[int] = None, + id: Optional[int] = None, + id_lt: Optional[int] = None, + id_gt: Optional[int] = None, + id_le: Optional[int] = None, + id_ge: Optional[int] = None, + transaction_uuid: Optional[UUID] = None, + transaction_uuid_ne: Optional[UUID] = None, + transaction_uuid_in: Optional[tuple[UUID, ...]] = None, + **kwargs, + ) -> DatabaseOperation: + """TODO""" + + _select_all = """ + SELECT uuid, name, version, data, id, action, created_at, transaction_uuid + FROM aggregate_event + """ + + conditions = list() + + if uuid is not None: + conditions.append("uuid = %(uuid)s") + if name is not None: + conditions.append("name = %(name)s") + if version is not None: + conditions.append("version = %(version)s") + if version_lt is not None: + conditions.append("version < %(version_lt)s") + if version_gt is not None: + conditions.append("version > %(version_gt)s") + if version_le is not None: + conditions.append("version <= %(version_le)s") + if version_ge is not None: + conditions.append("version >= %(version_ge)s") + if id is not None: + conditions.append("id = %(id)s") + if id_lt is not None: + conditions.append("id < %(id_lt)s") + if id_gt is not None: + conditions.append("id > %(id_gt)s") + if id_le is not None: + conditions.append("id <= %(id_le)s") + if id_ge is not None: + conditions.append("id >= %(id_ge)s") + if transaction_uuid is not None: + conditions.append("transaction_uuid = %(transaction_uuid)s") + if transaction_uuid_ne is not None: + conditions.append("transaction_uuid <> %(transaction_uuid_ne)s") + if transaction_uuid_in is not None: + conditions.append("transaction_uuid IN %(transaction_uuid_in)s") + + if not conditions: + return AiopgDatabaseOperation("{_select_all} ORDER BY id;") + + return AiopgDatabaseOperation( + f"{_select_all} WHERE {' AND '.join(conditions)} ORDER BY id;", + { + "uuid": uuid, + "name": name, + "version": version, + "version_lt": version_lt, + "version_gt": version_gt, + "version_le": version_le, + "version_ge": version_ge, + "id_lt": id_lt, + "id_gt": id_gt, + "id_le": id_le, + "id_ge": id_ge, + "transaction_uuid": transaction_uuid, + "transaction_uuid_ne": transaction_uuid_ne, + "transaction_uuid_in": transaction_uuid_in, + }, + ) + + def build_select_max_id(self) -> DatabaseOperation: + """TODO""" + return AiopgDatabaseOperation("SELECT MAX(id) FROM aggregate_event;".strip()) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py new file mode 100644 index 000000000..e2fa0e0bb --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -0,0 +1,92 @@ +from __future__ import ( + annotations, +) + +from typing import ( + AsyncIterator, + Optional, +) + +from minos.common import ( + NULL_UUID, + Config, + DatabaseMixin, + DatabaseOperation, + IntegrityException, +) + +from ....exceptions import ( + EventRepositoryConflictException, +) +from ...entries import ( + EventEntry, +) +from ..abc import ( + EventRepository, +) +from .factories import ( + AiopgEventRepositoryOperationFactory, +) + + +class DatabaseEventRepository(DatabaseMixin, EventRepository): + """PostgreSQL-based implementation of the event repository class in ``Minos``.""" + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self.operation_factory = AiopgEventRepositoryOperationFactory() + + @classmethod + def _from_config(cls, config: Config, **kwargs) -> Optional[EventRepository]: + return super()._from_config(config, database_key=None, **kwargs) + + async def _setup(self): + """Setup miscellaneous repository thing. + + In the PostgreSQL case, configures the needed table to be used to store the data. + + :return: This method does not return anything. + """ + operation = self.operation_factory.build_create_table() + await self.submit_query(operation) + + async def _submit(self, entry: EventEntry, **kwargs) -> EventEntry: + operation = await self._build_submit_operation(entry) + + try: + response = await self.submit_query_and_fetchone(operation) + except IntegrityException: + raise EventRepositoryConflictException( + f"{entry!r} could not be submitted due to a key (uuid, version, transaction) collision", + await self.offset, + ) + + entry.id, entry.uuid, entry.version, entry.created_at = response + return entry + + async def _build_submit_operation(self, entry: EventEntry) -> DatabaseOperation: + lock = None + if entry.uuid != NULL_UUID: + lock = entry.uuid.int & (1 << 32) - 1 + + if entry.transaction_uuid != NULL_UUID: + transaction = await self._transaction_repository.get(uuid=entry.transaction_uuid) + transaction_uuids = await transaction.uuids + else: + transaction_uuids = (NULL_UUID,) + + return self.operation_factory.build_submit_row(transaction_uuids=transaction_uuids, **entry.as_raw(), lock=lock) + + async def _select(self, **kwargs) -> AsyncIterator[EventEntry]: + operation = self.operation_factory.build_select_rows(**kwargs) + async for row in self.submit_query_and_iter(operation, kwargs, **kwargs): + yield EventEntry(*row) + + @property + async def _offset(self) -> int: + operation = self.operation_factory.build_select_max_id() + return (await self.submit_query_and_fetchone(operation))[0] or 0 + + +class PostgreSqlEventRepository(DatabaseEventRepository): + """TODO""" diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py deleted file mode 100644 index ef7be6b61..000000000 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/pg.py +++ /dev/null @@ -1,235 +0,0 @@ -from __future__ import ( - annotations, -) - -from typing import ( - AsyncIterator, - Optional, -) -from uuid import ( - UUID, -) - -from psycopg2.sql import ( - SQL, - Composable, - Literal, - Placeholder, -) - -from minos.common import ( - NULL_UUID, - Config, - DatabaseMixin, - IntegrityException, -) - -from ...exceptions import ( - EventRepositoryConflictException, -) -from ..entries import ( - EventEntry, -) -from .abc import ( - EventRepository, -) - - -class PostgreSqlEventRepository(DatabaseMixin, EventRepository): - """PostgreSQL-based implementation of the event repository class in ``Minos``.""" - - @classmethod - def _from_config(cls, config: Config, **kwargs) -> Optional[EventRepository]: - return super()._from_config(config, database_key=None, **kwargs) - - async def _setup(self): - """Setup miscellaneous repository thing. - - In the PostgreSQL case, configures the needed table to be used to store the data. - - :return: This method does not return anything. - """ - await self.submit_query('CREATE EXTENSION IF NOT EXISTS "uuid-ossp";', lock="uuid-ossp") - - await self.submit_query(_CREATE_ACTION_ENUM_QUERY, lock="aggregate_event") - await self.submit_query(_CREATE_TABLE_QUERY, lock="aggregate_event") - - async def _submit(self, entry: EventEntry, **kwargs) -> EventEntry: - lock = None - if entry.uuid != NULL_UUID: - lock = entry.uuid.int & (1 << 32) - 1 - - query, params = await self._build_query(entry) - - try: - response = await self.submit_query_and_fetchone(query, params, lock=lock) - except IntegrityException: - raise EventRepositoryConflictException( - f"{entry!r} could not be submitted due to a key (uuid, version, transaction) collision", - await self.offset, - ) - - entry.id, entry.uuid, entry.version, entry.created_at = response - return entry - - async def _build_query(self, entry: EventEntry) -> tuple[Composable, dict[str, UUID]]: - if entry.transaction_uuid != NULL_UUID: - transaction = await self._transaction_repository.get(uuid=entry.transaction_uuid) - transaction_uuids = await transaction.uuids - else: - transaction_uuids = (NULL_UUID,) - - from_query_parts = list() - parameters = dict() - for index, transaction_uuid in enumerate(transaction_uuids, start=1): - name = f"transaction_uuid_{index}" - parameters[name] = transaction_uuid - - from_query_parts.append( - _SELECT_TRANSACTION_CHUNK.format(index=Literal(index), transaction_uuid=Placeholder(name)) - ) - - from_query = SQL(" UNION ALL ").join(from_query_parts) - - query = _INSERT_VALUES_QUERY.format(from_parts=from_query) - - return query, parameters | entry.as_raw() - - async def _select(self, **kwargs) -> AsyncIterator[EventEntry]: - query = self._build_select_query(**kwargs) - async for row in self.submit_query_and_iter(query, kwargs, **kwargs): - yield EventEntry(*row) - - # noinspection PyUnusedLocal - @staticmethod - def _build_select_query( - uuid: Optional[UUID] = None, - name: Optional[str] = None, - version: Optional[int] = None, - version_lt: Optional[int] = None, - version_gt: Optional[int] = None, - version_le: Optional[int] = None, - version_ge: Optional[int] = None, - id: Optional[int] = None, - id_lt: Optional[int] = None, - id_gt: Optional[int] = None, - id_le: Optional[int] = None, - id_ge: Optional[int] = None, - transaction_uuid: Optional[UUID] = None, - transaction_uuid_ne: Optional[UUID] = None, - transaction_uuid_in: Optional[tuple[UUID, ...]] = None, - **kwargs, - ) -> str: - conditions = list() - - if uuid is not None: - conditions.append("uuid = %(uuid)s") - if name is not None: - conditions.append("name = %(name)s") - if version is not None: - conditions.append("version = %(version)s") - if version_lt is not None: - conditions.append("version < %(version_lt)s") - if version_gt is not None: - conditions.append("version > %(version_gt)s") - if version_le is not None: - conditions.append("version <= %(version_le)s") - if version_ge is not None: - conditions.append("version >= %(version_ge)s") - if id is not None: - conditions.append("id = %(id)s") - if id_lt is not None: - conditions.append("id < %(id_lt)s") - if id_gt is not None: - conditions.append("id > %(id_gt)s") - if id_le is not None: - conditions.append("id <= %(id_le)s") - if id_ge is not None: - conditions.append("id >= %(id_ge)s") - if transaction_uuid is not None: - conditions.append("transaction_uuid = %(transaction_uuid)s") - if transaction_uuid_ne is not None: - conditions.append("transaction_uuid <> %(transaction_uuid_ne)s") - if transaction_uuid_in is not None: - conditions.append("transaction_uuid IN %(transaction_uuid_in)s") - - if not conditions: - return f"{_SELECT_ALL_ENTRIES_QUERY} ORDER BY id;" - - return f"{_SELECT_ALL_ENTRIES_QUERY} WHERE {' AND '.join(conditions)} ORDER BY id;" - - @property - async def _offset(self) -> int: - return (await self.submit_query_and_fetchone(_SELECT_MAX_ID_QUERY))[0] or 0 - - -_CREATE_ACTION_ENUM_QUERY = """ -DO -$$ - BEGIN - IF NOT EXISTS(SELECT * - FROM pg_type typ - INNER JOIN pg_namespace nsp - ON nsp.oid = typ.typnamespace - WHERE nsp.nspname = current_schema() - AND typ.typname = 'action_type') THEN - CREATE TYPE action_type AS ENUM ('create', 'update', 'delete'); - END IF; - END; -$$ -LANGUAGE plpgsql; -""".strip() - -_CREATE_TABLE_QUERY = """ -CREATE TABLE IF NOT EXISTS aggregate_event ( - id BIGSERIAL PRIMARY KEY, - action ACTION_TYPE NOT NULL, - uuid UUID NOT NULL, - name TEXT NOT NULL, - version INT NOT NULL, - data BYTEA NOT NULL, - created_at TIMESTAMPTZ NOT NULL, - transaction_uuid UUID NOT NULL DEFAULT uuid_nil(), - UNIQUE (uuid, version, transaction_uuid) -); -""".strip() - -_INSERT_VALUES_QUERY = SQL( - """ -INSERT INTO aggregate_event (id, action, uuid, name, version, data, created_at, transaction_uuid) -VALUES ( - default, - %(action)s, - CASE %(uuid)s WHEN uuid_nil() THEN uuid_generate_v4() ELSE %(uuid)s END, - %(name)s, - ( - SELECT (CASE WHEN %(version)s IS NULL THEN 1 + COALESCE(MAX(t2.version), 0) ELSE %(version)s END) - FROM ( - SELECT DISTINCT ON (t1.uuid) t1.version - FROM ( {from_parts} ) AS t1 - ORDER BY t1.uuid, t1.transaction_index DESC - ) AS t2 - ), - %(data)s, - (CASE WHEN %(created_at)s IS NULL THEN NOW() ELSE %(created_at)s END), - %(transaction_uuid)s -) -RETURNING id, uuid, version, created_at; - """ -) - -_SELECT_TRANSACTION_CHUNK = SQL( - """ -SELECT {index} AS transaction_index, uuid, MAX(version) AS version -FROM aggregate_event -WHERE uuid = %(uuid)s AND transaction_uuid = {transaction_uuid} -GROUP BY uuid - """ -) - -_SELECT_ALL_ENTRIES_QUERY = """ -SELECT uuid, name, version, data, id, action, created_at, transaction_uuid -FROM aggregate_event -""".strip() - -_SELECT_MAX_ID_QUERY = "SELECT MAX(id) FROM aggregate_event;".strip() diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index ab15312d5..21dcfe346 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -15,6 +15,8 @@ ) from .database import ( AiopgDatabaseClient, + AiopgDatabaseOperation, + ComposedDatabaseOperation, DatabaseClient, DatabaseClientBuilder, DatabaseClientException, @@ -22,6 +24,7 @@ DatabaseLock, DatabaseLockPool, DatabaseMixin, + DatabaseOperation, IntegrityException, PostgreSqlLock, PostgreSqlLockPool, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index da4b4d0ff..3f38227e0 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -14,6 +14,11 @@ DatabaseLock, PostgreSqlLock, ) +from .operations import ( + AiopgDatabaseOperation, + ComposedDatabaseOperation, + DatabaseOperation, +) from .pools import ( DatabaseClientPool, DatabaseLockPool, diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 3e11f203b..dcdd35c82 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -24,6 +24,10 @@ from ...config import ( Config, ) +from ..operations import ( + ComposedDatabaseOperation, + DatabaseOperation, +) class DatabaseClient(ABC, BuildableMixin): @@ -33,12 +37,16 @@ class DatabaseClient(ABC, BuildableMixin): def _from_config(cls, config: Config, name: Optional[str] = None, **kwargs) -> DatabaseClient: return super()._from_config(config, **config.get_database_by_name(name), **kwargs) - @abstractmethod async def is_valid(self, **kwargs) -> bool: """Check if the instance is valid. :return: ``True`` if it is valid or ``False`` otherwise. """ + return await self._is_valid(**kwargs) + + @abstractmethod + async def _is_valid(self, **kwargs) -> bool: + raise NotImplementedError async def reset(self, **kwargs) -> None: """Reset the current instance status. @@ -46,15 +54,29 @@ async def reset(self, **kwargs) -> None: :param kwargs: Additional named parameters. :return: This method does not return anything. """ + return await self._reset(**kwargs) @abstractmethod - async def execute(self, *args, **kwargs) -> None: + async def _reset(self, **kwargs) -> None: + raise NotImplementedError + + async def execute(self, operation: DatabaseOperation, *args, **kwargs) -> None: """Execute an operation. + :param operation: TODO :param args: Additional positional arguments. :param kwargs: Additional named arguments. :return: This method does not return anything. """ + if isinstance(operation, ComposedDatabaseOperation): + for op in operation.operations: + await self._execute(op, *args, **kwargs) + else: + await self._execute(operation, *args, **kwargs) + + @abstractmethod + async def _execute(self, *args, **kwargs) -> None: + raise NotImplementedError async def fetch_one(self, *args, **kwargs) -> Any: """Fetch one value. @@ -65,22 +87,30 @@ async def fetch_one(self, *args, **kwargs) -> Any: """ return await self.fetch_all(*args, **kwargs).__anext__() - @abstractmethod def fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: """Fetch all values with an asynchronous iterator. - :param args: Additional positional arguments. :param kwargs: Additional named arguments. :return: This method does not return anything. """ + return self._fetch_all(*args, **kwargs) - @property @abstractmethod + def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: + raise NotImplementedError + + @property def notifications(self) -> Queue: """Get the notifications queue. :return: A ``Queue`` instance. """ + return self._notifications + + @property + @abstractmethod + def _notifications(self) -> Queue: + raise NotImplementedError class DatabaseClientBuilder(Builder[DatabaseClient]): diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index 64f3e2fb1..aa9485edf 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -11,6 +11,7 @@ TYPE_CHECKING, Any, Optional, + Union, ) import aiopg @@ -25,7 +26,14 @@ IntegrityError, OperationalError, ) +from psycopg2.sql import ( + Composable, +) +from ..operations import ( + AiopgDatabaseOperation, + DatabaseOperation, +) from .abc import ( DatabaseClient, ) @@ -108,11 +116,7 @@ async def _close_connection(self): self._connection = None logger.debug(f"Destroyed {self.database!r} database connection identified by {id(self._connection)}!") - async def is_valid(self) -> bool: - """Check if the instance is valid. - - :return: ``True`` if it is valid or ``False`` otherwise. - """ + async def _is_valid(self) -> bool: if self._connection is None: return False @@ -124,49 +128,36 @@ async def is_valid(self) -> bool: return not self._connection.closed - async def reset(self, **kwargs) -> None: - """Reset the current instance status. - - :param kwargs: Additional named parameters. - :return: This method does not return anything. - """ + async def _reset(self, **kwargs) -> None: await self._destroy_cursor(**kwargs) # noinspection PyUnusedLocal - async def fetch_all( + async def _fetch_all( self, *args, - timeout: Optional[float] = None, - lock: Optional[int] = None, **kwargs, ) -> AsyncIterator[tuple]: - """Fetch all values with an asynchronous iterator. - - :param timeout: An optional timeout. - :param lock: Optional key to perform the query with locking. If not set, the query is performed without any - lock. - :param kwargs: Additional named arguments. - :return: This method does not return anything. - """ await self._create_cursor() async for row in self._cursor: yield row # noinspection PyUnusedLocal - async def execute( - self, operation: Any, parameters: Any = None, *, timeout: Optional[float] = None, lock: Any = None, **kwargs + async def _execute( + self, + operation: Union[str, Composable, AiopgDatabaseOperation], + parameters: Any = None, + *, + timeout: Optional[float] = None, + lock: Any = None, + **kwargs, ) -> None: - """Execute an operation. - - :param operation: Query to be executed. - :param parameters: Parameters to be projected into the query. - :param timeout: An optional timeout. - :param lock: Optional key to perform the query with locking. If not set, the query is performed without any - lock. - :param kwargs: Additional named arguments. - :return: This method does not return anything. - """ + if isinstance(operation, DatabaseOperation): + if isinstance(operation, AiopgDatabaseOperation): + operation, parameters, lock = operation.query, operation.parameters, operation.lock + else: + raise ValueError(f"The operation is not supported: {operation!r}") + await self._create_cursor(lock=lock) try: await self._cursor.execute(operation=operation, parameters=parameters, timeout=timeout) @@ -216,11 +207,7 @@ def cursor(self) -> Optional[Cursor]: return self._cursor @property - def notifications(self) -> ClosableQueue: - """Get the notifications queue. - - :return: A ``ClosableQueue`` instance. - """ + def _notifications(self) -> ClosableQueue: return self._connection.notifies @property diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py new file mode 100644 index 000000000..9ba6002c2 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py @@ -0,0 +1,7 @@ +from .abc import ( + ComposedDatabaseOperation, + DatabaseOperation, +) +from .aiopg import ( + AiopgDatabaseOperation, +) diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py new file mode 100644 index 000000000..3f4b67781 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py @@ -0,0 +1,22 @@ +from __future__ import ( + annotations, +) + +from abc import ( + ABC, +) +from collections.abc import ( + Iterable, +) + + +class DatabaseOperation(ABC): + """TODO""" + + +class ComposedDatabaseOperation(DatabaseOperation): + """TODO""" + + def __init__(self, operations: Iterable[DatabaseOperation]): + super().__init__() + self.operations = operations diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py new file mode 100644 index 000000000..e724c5337 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py @@ -0,0 +1,29 @@ +from collections.abc import ( + Hashable, +) +from typing import ( + Any, + Optional, + Union, +) + +from psycopg2.sql import ( + Composable, +) + +from .abc import ( + DatabaseOperation, +) + + +class AiopgDatabaseOperation(DatabaseOperation): + """TODO""" + + def __init__( + self, query: Union[str, Composable], parameters: dict[str, Any] = None, lock: Optional[Hashable] = None + ): + if parameters is None: + parameters = dict() + self.query = query + self.parameters = parameters + self.lock = lock diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index e2b89d150..e98cc4485 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -17,8 +17,9 @@ class TestDatabaseClient(unittest.IsolatedAsyncioTestCase): def test_abstract(self): self.assertTrue(issubclass(DatabaseClient, (ABC, BuildableMixin))) + expected = {"_notifications", "_is_valid", "_execute", "_fetch_all", "_reset"} # noinspection PyUnresolvedReferences - self.assertEqual({"notifications", "is_valid", "execute", "fetch_all"}, DatabaseClient.__abstractmethods__) + self.assertEqual(expected, DatabaseClient.__abstractmethods__) def test_get_builder(self): self.assertIsInstance(DatabaseClient.get_builder(), DatabaseClientBuilder) From 02036b76888d80f6ad2adb62d72c9da641443901 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 10:09:13 +0200 Subject: [PATCH 137/324] ISSUE #371 * Fix broken tests. --- .../repositories/database/factories/abc.py | 1 + .../repositories/database/factories/aiopg.py | 52 +++++++++++-------- .../events/repositories/database/impl.py | 17 +++++- 3 files changed, 46 insertions(+), 24 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py index 7fa4104cc..63019249d 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py @@ -41,6 +41,7 @@ def build_submit_row( ) -> DatabaseOperation: """TODO""" + # noinspection PyShadowingBuiltins @abstractmethod def build_select_rows( self, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py index b45719c13..2a802f608 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py @@ -1,4 +1,8 @@ +from collections.abc import ( + Iterable, +) from typing import ( + Any, Optional, ) from uuid import ( @@ -7,6 +11,7 @@ from psycopg2.sql import ( SQL, + Composable, Literal, Placeholder, ) @@ -113,7 +118,24 @@ def build_submit_row( RETURNING id, uuid, version, created_at; """ ) + insert_parameters = { + "uuid": uuid, + "action": action, + "name": name, + "version": version, + "data": data, + "created_at": created_at, + "transaction_uuid": transaction_uuid, + } + + from_sql, from_parameters = self._build_submit_from(transaction_uuids) + + query = insert_values.format(from_parts=from_sql) + parameters = from_parameters | insert_parameters + return AiopgDatabaseOperation(query, parameters, lock) + + def _build_submit_from(self, transaction_uuids: Iterable[UUID]) -> tuple[Composable, dict[str, Any]]: select_transaction = SQL( """ SELECT {index} AS transaction_index, uuid, MAX(version) AS version @@ -122,33 +144,18 @@ def build_submit_row( GROUP BY uuid """ ) - from_query_parts = list() parameters = dict() for index, transaction_uuid in enumerate(transaction_uuids, start=1): - transaction_name = f"transaction_uuid_{index}" - parameters[transaction_name] = transaction_uuid + name = f"transaction_uuid_{index}" + parameters[name] = transaction_uuid - from_query_parts.append( - select_transaction.format(index=Literal(index), transaction_uuid=Placeholder(transaction_name)) - ) - - from_query = SQL(" UNION ALL ").join(from_query_parts) + from_query_parts.append(select_transaction.format(index=Literal(index), transaction_uuid=Placeholder(name))) - query = insert_values.format(from_parts=from_query) - - parameters |= { - "uuid": uuid, - "action": action, - "name": name, - "version": version, - "data": data, - "created_at": created_at, - "transaction_uuid": transaction_uuid, - } - - return AiopgDatabaseOperation(query, parameters, lock) + query = SQL(" UNION ALL ").join(from_query_parts) + return query, parameters + # noinspection PyShadowingBuiltins def build_select_rows( self, uuid: Optional[UUID] = None, @@ -209,7 +216,7 @@ def build_select_rows( conditions.append("transaction_uuid IN %(transaction_uuid_in)s") if not conditions: - return AiopgDatabaseOperation("{_select_all} ORDER BY id;") + return AiopgDatabaseOperation(f"{_select_all} ORDER BY id;") return AiopgDatabaseOperation( f"{_select_all} WHERE {' AND '.join(conditions)} ORDER BY id;", @@ -221,6 +228,7 @@ def build_select_rows( "version_gt": version_gt, "version_le": version_le, "version_ge": version_ge, + "id": id, "id_lt": id_lt, "id_gt": id_gt, "id_le": id_le, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index e2fa0e0bb..83f7f3457 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -2,6 +2,7 @@ annotations, ) +import warnings from typing import ( AsyncIterator, Optional, @@ -26,15 +27,19 @@ ) from .factories import ( AiopgEventRepositoryOperationFactory, + EventRepositoryOperationFactory, ) class DatabaseEventRepository(DatabaseMixin, EventRepository): """PostgreSQL-based implementation of the event repository class in ``Minos``.""" - def __init__(self, *args, **kwargs): + def __init__(self, *args, operation_factory: Optional[EventRepositoryOperationFactory] = None, **kwargs): super().__init__(*args, **kwargs) - self.operation_factory = AiopgEventRepositoryOperationFactory() + if operation_factory is None: + operation_factory = AiopgEventRepositoryOperationFactory() + + self.operation_factory = operation_factory @classmethod def _from_config(cls, config: Config, **kwargs) -> Optional[EventRepository]: @@ -90,3 +95,11 @@ async def _offset(self) -> int: class PostgreSqlEventRepository(DatabaseEventRepository): """TODO""" + + def __init__(self, *args, **kwargs): + warnings.warn( + f"{PostgreSqlEventRepository!r} has been deprecated. Use {DatabaseEventRepository} instead.", + DeprecationWarning, + ) + kwargs["operation_factory"] = AiopgEventRepositoryOperationFactory() + super().__init__(*args, **kwargs) From d624b0c5116b06b3db4dcb2c9267c39adba26d82 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 10:36:41 +0200 Subject: [PATCH 138/324] ISSUE #371 * Refactor `PostgreSqlTransactionRepository` as `DatabaseTransactionRepository`. * Add `TransactionRepositoryOperationFactory`. * Add `AiopgTransactionRepositoryOperationFactory`. --- .../minos/aggregate/__init__.py | 3 + .../repositories/database/factories/aiopg.py | 2 +- .../minos/aggregate/transactions/__init__.py | 3 + .../transactions/repositories/__init__.py | 9 +- .../repositories/database/__init__.py | 8 + .../database/factories/__init__.py | 6 + .../repositories/database/factories/abc.py | 66 ++++++ .../repositories/database/factories/aiopg.py | 198 ++++++++++++++++++ .../repositories/database/impl.py | 81 +++++++ .../aggregate/transactions/repositories/pg.py | 178 ---------------- .../test_root/test_with_postgresql.py | 4 +- .../test_repositories/test_pg.py | 14 +- 12 files changed, 381 insertions(+), 191 deletions(-) create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py delete mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index 3580bc9c2..987e9aad8 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -72,10 +72,13 @@ ) from .transactions import ( TRANSACTION_CONTEXT_VAR, + AiopgTransactionRepositoryOperationFactory, + DatabaseTransactionRepository, InMemoryTransactionRepository, PostgreSqlTransactionRepository, TransactionEntry, TransactionRepository, + TransactionRepositoryOperationFactory, TransactionService, TransactionStatus, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py index 2a802f608..d95df6d51 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py @@ -41,7 +41,7 @@ def build_create_table(self) -> DatabaseOperation: [ AiopgDatabaseOperation( 'CREATE EXTENSION IF NOT EXISTS "uuid-ossp";', - lock="aggregate_event", + lock="uuid-ossp", ), AiopgDatabaseOperation( """ diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py index 07c5c8cfb..9e94e6b16 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py @@ -6,9 +6,12 @@ TransactionStatus, ) from .repositories import ( + AiopgTransactionRepositoryOperationFactory, + DatabaseTransactionRepository, InMemoryTransactionRepository, PostgreSqlTransactionRepository, TransactionRepository, + TransactionRepositoryOperationFactory, ) from .services import ( TransactionService, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py index 2d69d49fe..0f2ccd8cb 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py @@ -1,9 +1,12 @@ from .abc import ( TransactionRepository, ) +from .database import ( + AiopgTransactionRepositoryOperationFactory, + DatabaseTransactionRepository, + PostgreSqlTransactionRepository, + TransactionRepositoryOperationFactory, +) from .memory import ( InMemoryTransactionRepository, ) -from .pg import ( - PostgreSqlTransactionRepository, -) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py new file mode 100644 index 000000000..4a22ce8ce --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py @@ -0,0 +1,8 @@ +from .factories import ( + AiopgTransactionRepositoryOperationFactory, + TransactionRepositoryOperationFactory, +) +from .impl import ( + DatabaseTransactionRepository, + PostgreSqlTransactionRepository, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py new file mode 100644 index 000000000..ba24761b9 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py @@ -0,0 +1,6 @@ +from .abc import ( + TransactionRepositoryOperationFactory, +) +from .aiopg import ( + AiopgTransactionRepositoryOperationFactory, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py new file mode 100644 index 000000000..f1685115c --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py @@ -0,0 +1,66 @@ +from __future__ import ( + annotations, +) + +from abc import ( + ABC, + abstractmethod, +) +from typing import ( + TYPE_CHECKING, + Optional, +) +from uuid import ( + UUID, +) + +from minos.common import ( + DatabaseOperation, + datetime, +) + +if TYPE_CHECKING: + from ....entries import ( + TransactionStatus, + ) + + +class TransactionRepositoryOperationFactory(ABC): + """TODO""" + + @abstractmethod + def build_create_table(self) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_submit_row( + self, + uuid: UUID, + destination_uuid: UUID, + status: TransactionStatus, + event_offset: int, + ) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_select_rows( + self, + uuid: Optional[UUID] = None, + uuid_ne: Optional[UUID] = None, + uuid_in: Optional[tuple[UUID]] = None, + destination_uuid: Optional[UUID] = None, + status: Optional[str] = None, + status_in: Optional[tuple[str]] = None, + event_offset: Optional[int] = None, + event_offset_lt: Optional[int] = None, + event_offset_gt: Optional[int] = None, + event_offset_le: Optional[int] = None, + event_offset_ge: Optional[int] = None, + updated_at: Optional[datetime] = None, + updated_at_lt: Optional[datetime] = None, + updated_at_gt: Optional[datetime] = None, + updated_at_le: Optional[datetime] = None, + updated_at_ge: Optional[datetime] = None, + **kwargs, + ) -> DatabaseOperation: + """TODO""" diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py new file mode 100644 index 000000000..6e90b3fbb --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py @@ -0,0 +1,198 @@ +from __future__ import ( + annotations, +) + +from typing import ( + TYPE_CHECKING, + Optional, +) +from uuid import ( + UUID, +) + +from minos.common import ( + AiopgDatabaseOperation, + ComposedDatabaseOperation, + DatabaseOperation, + datetime, +) + +from .abc import ( + TransactionRepositoryOperationFactory, +) + +if TYPE_CHECKING: + from ....entries import ( + TransactionStatus, + ) + + +# noinspection SqlNoDataSourceInspection,SqlResolve,PyMethodMayBeStatic +class AiopgTransactionRepositoryOperationFactory(TransactionRepositoryOperationFactory): + """TODO""" + + def build_create_table(self) -> DatabaseOperation: + """TODO""" + + return ComposedDatabaseOperation( + [ + AiopgDatabaseOperation( + 'CREATE EXTENSION IF NOT EXISTS "uuid-ossp";', + lock="uuid-ossp", + ), + AiopgDatabaseOperation( + """ + DO + $$ + BEGIN + IF NOT EXISTS(SELECT * + FROM pg_type typ + INNER JOIN pg_namespace nsp + ON nsp.oid = typ.typnamespace + WHERE nsp.nspname = current_schema() + AND typ.typname = 'transaction_status') THEN + CREATE TYPE transaction_status AS ENUM ( + 'pending', 'reserving', 'reserved', 'committing', 'committed', 'rejected' + ); + END IF; + END; + $$ + LANGUAGE plpgsql; + """, + lock=hash("aggregate_transaction_enum"), + ), + AiopgDatabaseOperation( + """ + CREATE TABLE IF NOT EXISTS aggregate_transaction ( + uuid UUID PRIMARY KEY, + destination_uuid UUID NOT NULL, + status TRANSACTION_STATUS NOT NULL, + event_offset INTEGER, + updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW() + ); + """, + lock=hash("aggregate_transaction"), + ), + ] + ) + + def build_submit_row( + self, + uuid: UUID, + destination_uuid: UUID, + status: TransactionStatus, + event_offset: int, + ) -> DatabaseOperation: + """TODO""" + params = { + "uuid": uuid, + "destination_uuid": destination_uuid, + "status": status, + "event_offset": event_offset, + } + + return AiopgDatabaseOperation( + """ + INSERT INTO aggregate_transaction (uuid, destination_uuid, status, event_offset) + VALUES (%(uuid)s, %(destination_uuid)s, %(status)s, %(event_offset)s) + ON CONFLICT (uuid) + DO + UPDATE SET status = %(status)s, event_offset = %(event_offset)s, updated_at = NOW() + WHERE (aggregate_destination_uuid = %(destination_uuid)s) + AND (NOT (aggregate_status = 'pending' AND %(status)s NOT IN ('pending', 'reserving', 'rejected'))) + AND (NOT (aggregate_status = 'reserving' AND %(status)s NOT IN ('reserved', 'rejected'))) + AND (NOT (aggregate_status = 'reserved' AND %(status)s NOT IN ('committing', 'rejected'))) + AND (NOT (aggregate_status = 'committing' AND %(status)s NOT IN ('committed'))) + AND (NOT (aggregate_status = 'committed')) + AND (NOT (aggregate_status = 'rejected')) + RETURNING updated_at; + """, + params, + lock=uuid.int & (1 << 32) - 1, + ) + + def build_select_rows( + self, + uuid: Optional[UUID] = None, + uuid_ne: Optional[UUID] = None, + uuid_in: Optional[tuple[UUID]] = None, + destination_uuid: Optional[UUID] = None, + status: Optional[str] = None, + status_in: Optional[tuple[str]] = None, + event_offset: Optional[int] = None, + event_offset_lt: Optional[int] = None, + event_offset_gt: Optional[int] = None, + event_offset_le: Optional[int] = None, + event_offset_ge: Optional[int] = None, + updated_at: Optional[datetime] = None, + updated_at_lt: Optional[datetime] = None, + updated_at_gt: Optional[datetime] = None, + updated_at_le: Optional[datetime] = None, + updated_at_ge: Optional[datetime] = None, + **kwargs, + ) -> DatabaseOperation: + """TODO""" + conditions = list() + + if uuid is not None: + conditions.append("uuid = %(uuid)s") + if uuid_ne is not None: + conditions.append("uuid <> %(uuid_ne)s") + if uuid_in is not None: + conditions.append("uuid IN %(uuid_in)s") + if destination_uuid is not None: + conditions.append("destination_uuid = %(destination_uuid)s") + if status is not None: + conditions.append("status = %(status)s") + if status_in is not None: + conditions.append("status IN %(status_in)s") + if event_offset is not None: + conditions.append("event_offset = %(event_offset)s") + if event_offset_lt is not None: + conditions.append("event_offset < %(event_offset_lt)s") + if event_offset_gt is not None: + conditions.append("event_offset > %(event_offset_gt)s") + if event_offset_le is not None: + conditions.append("event_offset <= %(event_offset_le)s") + if event_offset_ge is not None: + conditions.append("event_offset >= %(event_offset_ge)s") + if updated_at is not None: + conditions.append("updated_at = %(updated_at)s") + if updated_at_lt is not None: + conditions.append("updated_at < %(updated_at_lt)s") + if updated_at_gt is not None: + conditions.append("updated_at > %(updated_at_gt)s") + if updated_at_le is not None: + conditions.append("updated_at <= %(updated_at_le)s") + if updated_at_ge is not None: + conditions.append("updated_at >= %(updated_at_ge)s") + + select_all = """ + SELECT uuid, status, event_offset, destination_uuid, updated_at + FROM aggregate_transaction + """.strip() + + if not conditions: + return AiopgDatabaseOperation(f"{select_all} ORDER BY event_offset;") + + return AiopgDatabaseOperation( + f"{select_all} WHERE {' AND '.join(conditions)} ORDER BY event_offset;", + { + "uuid": uuid, + "uuid_ne": uuid_ne, + "uuid_in": uuid_in, + "destination_uuid": destination_uuid, + "status": status, + "status_in": status_in, + "event_offset": event_offset, + "event_offset_lt": event_offset_lt, + "event_offset_gt": event_offset_gt, + "event_offset_le": event_offset_le, + "event_offset_ge": event_offset_ge, + "updated_at": updated_at, + "updated_at_lt": updated_at_lt, + "updated_at_gt": updated_at_gt, + "updated_at_le": updated_at_le, + "updated_at_ge": updated_at_ge, + }, + ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py new file mode 100644 index 000000000..721ada70c --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -0,0 +1,81 @@ +from __future__ import ( + annotations, +) + +import warnings +from typing import ( + AsyncIterator, + Optional, +) + +from minos.common import ( + Config, + DatabaseMixin, +) + +from ....exceptions import ( + TransactionRepositoryConflictException, +) +from ...entries import ( + TransactionEntry, +) +from ..abc import ( + TransactionRepository, +) +from .factories import ( + AiopgTransactionRepositoryOperationFactory, + TransactionRepositoryOperationFactory, +) + + +class DatabaseTransactionRepository(DatabaseMixin, TransactionRepository): + """PostgreSql Transaction Repository class.""" + + def __init__(self, *args, operation_factory: Optional[TransactionRepositoryOperationFactory] = None, **kwargs): + super().__init__(*args, **kwargs) + if operation_factory is None: + operation_factory = AiopgTransactionRepositoryOperationFactory() + + self.operation_factory = operation_factory + + @classmethod + def _from_config(cls, config: Config, **kwargs) -> DatabaseTransactionRepository: + return super()._from_config(config, database_key=None, **kwargs) + + async def _setup(self): + operation = self.operation_factory.build_create_table() + await self.submit_query(operation) + + async def _submit(self, transaction: TransactionEntry) -> TransactionEntry: + operation = self.operation_factory.build_submit_row( + uuid=transaction.uuid, + destination_uuid=transaction.destination_uuid, + status=transaction.status, + event_offset=transaction.event_offset, + ) + + try: + updated_at = await self.submit_query_and_fetchone(operation) + except StopAsyncIteration: + raise TransactionRepositoryConflictException( + f"{transaction!r} status is invalid respect to the previous one." + ) + transaction.updated_at = updated_at + return transaction + + async def _select(self, **kwargs) -> AsyncIterator[TransactionEntry]: + operation = self.operation_factory.build_select_rows(**kwargs) + async for row in self.submit_query_and_iter(operation, **kwargs): + yield TransactionEntry(*row, transaction_repository=self) + + +class PostgreSqlTransactionRepository(DatabaseTransactionRepository): + """TODO""" + + def __init__(self, *args, **kwargs): + warnings.warn( + f"{PostgreSqlTransactionRepository!r} has been deprecated. Use {DatabaseTransactionRepository} instead.", + DeprecationWarning, + ) + kwargs["operation_factory"] = AiopgTransactionRepositoryOperationFactory() + super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py deleted file mode 100644 index 0a1281a39..000000000 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/pg.py +++ /dev/null @@ -1,178 +0,0 @@ -from __future__ import ( - annotations, -) - -from datetime import ( - datetime, -) -from typing import ( - AsyncIterator, - Optional, -) -from uuid import ( - UUID, -) - -from minos.common import ( - Config, - DatabaseMixin, -) - -from ...exceptions import ( - TransactionRepositoryConflictException, -) -from ..entries import ( - TransactionEntry, -) -from .abc import ( - TransactionRepository, -) - - -class PostgreSqlTransactionRepository(DatabaseMixin, TransactionRepository): - """PostgreSql Transaction Repository class.""" - - @classmethod - def _from_config(cls, config: Config, **kwargs) -> Optional[PostgreSqlTransactionRepository]: - return super()._from_config(config, database_key=None, **kwargs) - - async def _setup(self): - await self.submit_query('CREATE EXTENSION IF NOT EXISTS "uuid-ossp";', lock="uuid-ossp") - - await self.submit_query(_CREATE_TRANSACTION_STATUS_ENUM_QUERY, lock=hash("aggregate_transaction_enum")) - await self.submit_query(_CREATE_TRANSACTION_TABLE_QUERY, lock=hash("aggregate_transaction")) - - async def _submit(self, transaction: TransactionEntry) -> TransactionEntry: - params = { - "uuid": transaction.uuid, - "destination_uuid": transaction.destination_uuid, - "status": transaction.status, - "event_offset": transaction.event_offset, - } - try: - updated_at = await self.submit_query_and_fetchone( - _INSERT_TRANSACTIONS_VALUES_QUERY, params, lock=transaction.uuid.int & (1 << 32) - 1 - ) - except StopAsyncIteration: - raise TransactionRepositoryConflictException( - f"{transaction!r} status is invalid respect to the previous one." - ) - transaction.updated_at = updated_at - return transaction - - async def _select(self, **kwargs) -> AsyncIterator[TransactionEntry]: - query = self._build_select_query(**kwargs) - async for row in self.submit_query_and_iter(query, kwargs, **kwargs): - yield TransactionEntry(*row, transaction_repository=self) - - # noinspection PyUnusedLocal - @staticmethod - def _build_select_query( - uuid: Optional[UUID] = None, - uuid_ne: Optional[UUID] = None, - uuid_in: Optional[tuple[UUID]] = None, - destination_uuid: Optional[UUID] = None, - status: Optional[str] = None, - status_in: Optional[tuple[str]] = None, - event_offset: Optional[int] = None, - event_offset_lt: Optional[int] = None, - event_offset_gt: Optional[int] = None, - event_offset_le: Optional[int] = None, - event_offset_ge: Optional[int] = None, - updated_at: Optional[datetime] = None, - updated_at_lt: Optional[datetime] = None, - updated_at_gt: Optional[datetime] = None, - updated_at_le: Optional[datetime] = None, - updated_at_ge: Optional[datetime] = None, - **kwargs, - ) -> str: - conditions = list() - - if uuid is not None: - conditions.append("uuid = %(uuid)s") - if uuid_ne is not None: - conditions.append("uuid <> %(uuid_ne)s") - if uuid_in is not None: - conditions.append("uuid IN %(uuid_in)s") - if destination_uuid is not None: - conditions.append("destination_uuid = %(destination_uuid)s") - if status is not None: - conditions.append("status = %(status)s") - if status_in is not None: - conditions.append("status IN %(status_in)s") - if event_offset is not None: - conditions.append("event_offset = %(event_offset)s") - if event_offset_lt is not None: - conditions.append("event_offset < %(event_offset_lt)s") - if event_offset_gt is not None: - conditions.append("event_offset > %(event_offset_gt)s") - if event_offset_le is not None: - conditions.append("event_offset <= %(event_offset_le)s") - if event_offset_ge is not None: - conditions.append("event_offset >= %(event_offset_ge)s") - if updated_at is not None: - conditions.append("updated_at = %(updated_at)s") - if updated_at_lt is not None: - conditions.append("updated_at < %(updated_at_lt)s") - if updated_at_gt is not None: - conditions.append("updated_at > %(updated_at_gt)s") - if updated_at_le is not None: - conditions.append("updated_at <= %(updated_at_le)s") - if updated_at_ge is not None: - conditions.append("updated_at >= %(updated_at_ge)s") - - if not conditions: - return f"{_SELECT_ALL_TRANSACTIONS_QUERY} ORDER BY event_offset;" - - return f"{_SELECT_ALL_TRANSACTIONS_QUERY} WHERE {' AND '.join(conditions)} ORDER BY event_offset;" - - -_CREATE_TRANSACTION_STATUS_ENUM_QUERY = """ -DO -$$ - BEGIN - IF NOT EXISTS(SELECT * - FROM pg_type typ - INNER JOIN pg_namespace nsp - ON nsp.oid = typ.typnamespace - WHERE nsp.nspname = current_schema() - AND typ.typname = 'transaction_status') THEN - CREATE TYPE transaction_status AS ENUM ( - 'pending', 'reserving', 'reserved', 'committing', 'committed', 'rejected' - ); - END IF; - END; -$$ -LANGUAGE plpgsql; -""".strip() - -_CREATE_TRANSACTION_TABLE_QUERY = """ -CREATE TABLE IF NOT EXISTS aggregate_transaction ( - uuid UUID PRIMARY KEY, - destination_uuid UUID NOT NULL, - status TRANSACTION_STATUS NOT NULL, - event_offset INTEGER, - updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW() -); -""".strip() - -_INSERT_TRANSACTIONS_VALUES_QUERY = """ -INSERT INTO aggregate_transaction (uuid, destination_uuid, status, event_offset) -VALUES (%(uuid)s, %(destination_uuid)s, %(status)s, %(event_offset)s) -ON CONFLICT (uuid) -DO - UPDATE SET status = %(status)s, event_offset = %(event_offset)s, updated_at = NOW() -WHERE (aggregate_transaction.destination_uuid = %(destination_uuid)s) - AND (NOT (aggregate_transaction.status = 'pending' AND %(status)s NOT IN ('pending', 'reserving', 'rejected'))) - AND (NOT (aggregate_transaction.status = 'reserving' AND %(status)s NOT IN ('reserved', 'rejected'))) - AND (NOT (aggregate_transaction.status = 'reserved' AND %(status)s NOT IN ('committing', 'rejected'))) - AND (NOT (aggregate_transaction.status = 'committing' AND %(status)s NOT IN ('committed'))) - AND (NOT (aggregate_transaction.status = 'committed')) - AND (NOT (aggregate_transaction.status = 'rejected')) -RETURNING updated_at; -""".strip() - -_SELECT_ALL_TRANSACTIONS_QUERY = """ -SELECT uuid, status, event_offset, destination_uuid, updated_at -FROM aggregate_transaction -""".strip() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py index e2fc15abb..0ed5f3b97 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py @@ -2,10 +2,10 @@ from minos.aggregate import ( AlreadyDeletedException, + DatabaseTransactionRepository, EntitySet, PostgreSqlEventRepository, PostgreSqlSnapshotRepository, - PostgreSqlTransactionRepository, ValueObjectSet, ) from minos.common.testing import ( @@ -24,7 +24,7 @@ class TestExternalEntityWithPostgreSql(AggregateTestCase, PostgresAsyncTestCase) def setUp(self): super().setUp() - self.transaction_repository = PostgreSqlTransactionRepository.from_config(self.config) + self.transaction_repository = DatabaseTransactionRepository.from_config(self.config) self.event_repository = PostgreSqlEventRepository.from_config( self.config, transaction_repository=self.transaction_repository diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index e0bd9225d..f5c38bf83 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -4,7 +4,7 @@ ) from minos.aggregate import ( - PostgreSqlTransactionRepository, + DatabaseTransactionRepository, TransactionEntry, TransactionRepository, TransactionRepositoryConflictException, @@ -27,7 +27,7 @@ class TestPostgreSqlTransactionRepository(AggregateTestCase, PostgresAsyncTestCa def setUp(self) -> None: super().setUp() - self.transaction_repository = PostgreSqlTransactionRepository() + self.transaction_repository = DatabaseTransactionRepository() self.uuid = uuid4() @@ -40,16 +40,16 @@ async def asyncTearDown(self) -> None: await super().asyncTearDown() async def test_subclass(self) -> None: - self.assertTrue(issubclass(PostgreSqlTransactionRepository, TransactionRepository)) + self.assertTrue(issubclass(DatabaseTransactionRepository, TransactionRepository)) def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) - repository = PostgreSqlTransactionRepository(pool) - self.assertIsInstance(repository, PostgreSqlTransactionRepository) + repository = DatabaseTransactionRepository(pool) + self.assertIsInstance(repository, DatabaseTransactionRepository) self.assertEqual(pool, repository.pool) def test_from_config(self): - repository = PostgreSqlTransactionRepository.from_config(self.config) + repository = DatabaseTransactionRepository.from_config(self.config) self.assertIsInstance(repository.pool, DatabaseClientPool) async def test_setup(self): @@ -153,7 +153,7 @@ def setUp(self) -> None: self.uuid_4 = uuid4() self.uuid_5 = uuid4() - self.transaction_repository = PostgreSqlTransactionRepository() + self.transaction_repository = DatabaseTransactionRepository() self.entries = [ TransactionEntry(self.uuid_1, TransactionStatus.PENDING, 12), From aa324b3ae1b3aac44d8f5938800b4aed2e9a144c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 10:51:45 +0200 Subject: [PATCH 139/324] ISSUE #367 * Improve `DatabaseClient`'s lock behavior. --- .../minos/common/database/clients/aiopg.py | 34 +++++++++++-------- .../test_database/test_clients/test_aiopg.py | 12 +++++-- 2 files changed, 30 insertions(+), 16 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index 551a279b6..e96ad655e 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -151,27 +151,33 @@ async def _create_cursor(self, *args, lock: Optional[Hashable] = None, **kwargs) self._cursor = await self._connection.cursor(*args, **kwargs) if lock is not None: - if self._lock is not None: - if self._lock.key != lock: - raise ValueError(f"Only one lock per instance is supported. Currently locked with {self._lock!r}") - return - from ..locks import ( - DatabaseLock, - ) - - self._lock = DatabaseLock(self, lock, *args, **kwargs) - await self._lock.acquire() + await self._create_lock(lock) async def _destroy_cursor(self, **kwargs): - if self._lock is not None: - await self._lock.release() - self._lock = None - + await self._destroy_lock() if self._cursor is not None: if not self._cursor.closed: self._cursor.close() self._cursor = None + async def _create_lock(self, lock: Hashable, *args, **kwargs): + if self._lock is not None and self._lock.key == lock: + return + await self._destroy_lock() + + from ..locks import ( + DatabaseLock, + ) + + self._lock = DatabaseLock(self, lock, *args, **kwargs) + await self._lock.acquire() + + async def _destroy_lock(self): + if self._lock is not None: + logger.debug(f"Destroying {self.lock!r}...") + await self._lock.release() + self._lock = None + @property def lock(self) -> Optional[DatabaseLock]: """Get the lock. diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py index 13a64e58a..ee28deae3 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py @@ -145,10 +145,18 @@ async def test_execute_with_lock(self): async def test_execute_with_lock_multiple(self): async with AiopgDatabaseClient.from_config(self.config) as client: + self.assertIsNone(client.lock) + await client.execute(self.sql, lock="foo") + foo_lock = client.lock + self.assertIsInstance(foo_lock, DatabaseLock) + await client.execute(self.sql, lock="foo") - with self.assertRaises(ValueError): - await client.execute(self.sql, lock="bar") + self.assertEqual(foo_lock, client.lock) + + await client.execute(self.sql, lock="bar") + self.assertNotEqual(foo_lock, client.lock) + self.assertIsInstance(client.lock, DatabaseLock) async def test_execute_raises_integrity(self): async with AiopgDatabaseClient.from_config(self.config) as client: From 13672b3978ef8500d4ff4e15fd30f560e4dd88e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 11:13:49 +0200 Subject: [PATCH 140/324] ISSUE #371 * Fix bug related with a query. --- .../repositories/database/factories/aiopg.py | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py index 6e90b3fbb..5b574656c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py @@ -59,7 +59,7 @@ def build_create_table(self) -> DatabaseOperation: $$ LANGUAGE plpgsql; """, - lock=hash("aggregate_transaction_enum"), + lock="aggregate_transaction_enum", ), AiopgDatabaseOperation( """ @@ -71,7 +71,7 @@ def build_create_table(self) -> DatabaseOperation: updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW() ); """, - lock=hash("aggregate_transaction"), + lock="aggregate_transaction", ), ] ) @@ -93,18 +93,18 @@ def build_submit_row( return AiopgDatabaseOperation( """ - INSERT INTO aggregate_transaction (uuid, destination_uuid, status, event_offset) + INSERT INTO aggregate_transaction AS t (uuid, destination_uuid, status, event_offset) VALUES (%(uuid)s, %(destination_uuid)s, %(status)s, %(event_offset)s) ON CONFLICT (uuid) DO UPDATE SET status = %(status)s, event_offset = %(event_offset)s, updated_at = NOW() - WHERE (aggregate_destination_uuid = %(destination_uuid)s) - AND (NOT (aggregate_status = 'pending' AND %(status)s NOT IN ('pending', 'reserving', 'rejected'))) - AND (NOT (aggregate_status = 'reserving' AND %(status)s NOT IN ('reserved', 'rejected'))) - AND (NOT (aggregate_status = 'reserved' AND %(status)s NOT IN ('committing', 'rejected'))) - AND (NOT (aggregate_status = 'committing' AND %(status)s NOT IN ('committed'))) - AND (NOT (aggregate_status = 'committed')) - AND (NOT (aggregate_status = 'rejected')) + WHERE (t.destination_uuid = %(destination_uuid)s) + AND (NOT (t.status = 'pending' AND %(status)s NOT IN ('pending', 'reserving', 'rejected'))) + AND (NOT (t.status = 'reserving' AND %(status)s NOT IN ('reserved', 'rejected'))) + AND (NOT (t.status = 'reserved' AND %(status)s NOT IN ('committing', 'rejected'))) + AND (NOT (t.status = 'committing' AND %(status)s NOT IN ('committed'))) + AND (NOT (t.status = 'committed')) + AND (NOT (t.status = 'rejected')) RETURNING updated_at; """, params, From d701d173eecab9bd19a50d8fd92bb59877886caf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 12:42:07 +0200 Subject: [PATCH 141/324] ISSUE #371 * Refactor `PostgreSqlBrokerSubscriberDuplicateValidator`. --- .../validators/duplicates/__init__.py | 2 +- .../duplicates/database/__init__.py | 7 + .../duplicates/database/factories/__init__.py | 3 + .../duplicates/database/factories/abc.py | 0 .../duplicates/database/factories/aiopg.py | 56 ++++++++ .../validators/duplicates/database/impl.py | 76 ++++++++++ .../filtered/validators/duplicates/pg.py | 131 ------------------ 7 files changed, 143 insertions(+), 132 deletions(-) create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py delete mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py index 114d74268..5d6055ce4 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py @@ -4,7 +4,7 @@ from .memory import ( InMemoryBrokerSubscriberDuplicateValidator, ) -from .pg import ( +from .database import ( PostgreSqlBrokerSubscriberDuplicateValidator, PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py new file mode 100644 index 000000000..2506b7845 --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py @@ -0,0 +1,7 @@ +from .impl import ( + PostgreSqlBrokerSubscriberDuplicateValidator, + PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, +) +from .factories import ( + PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py new file mode 100644 index 000000000..013bb3bac --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py @@ -0,0 +1,3 @@ +from .aiopg import ( + PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, +) \ No newline at end of file diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py new file mode 100644 index 000000000..f0f08cc7f --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py @@ -0,0 +1,56 @@ +from uuid import UUID + +from psycopg2.sql import SQL + +from minos.common import AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation + + +# noinspection SqlNoDataSourceInspection,SqlResolve +class PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory: + """PostgreSql Broker Subscriber Duplicate Detector Query Factory class.""" + + @staticmethod + def build_table_name() -> str: + """Build the table name. + + :return: A ``str`` instance. + """ + return "broker_subscriber_processed_messages" + + def build_create_table(self) -> DatabaseOperation: + """Build the "create table" query. + + :return: A ``SQL`` instance. + """ + return ComposedDatabaseOperation( + [ + AiopgDatabaseOperation( + SQL('CREATE EXTENSION IF NOT EXISTS "uuid-ossp";'), + lock="uuid-ossp", + ), + AiopgDatabaseOperation( + SQL( + f"CREATE TABLE IF NOT EXISTS {self.build_table_name()} (" + " topic VARCHAR(255) NOT NULL, " + " uuid UUID NOT NULL, " + " created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()," + " PRIMARY KEY (topic, uuid)" + ")" + ), + lock=self.build_table_name(), + ), + ] + ) + + def build_insert_row(self, topic: str, uuid: UUID) -> AiopgDatabaseOperation: + """Build the "insert row" query. + + :return: A ``SQL`` instance. + """ + return AiopgDatabaseOperation( + SQL(f"INSERT INTO {self.build_table_name()}(topic, uuid) VALUES(%(topic)s, %(uuid)s)"), + { + "topic": topic, + "uuid": uuid, + }, + ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py new file mode 100644 index 000000000..f05134356 --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py @@ -0,0 +1,76 @@ +from __future__ import ( + annotations, +) + +from typing import ( + Optional, +) +from uuid import ( + UUID, +) + +from minos.common import ( + Builder, + Config, + DatabaseMixin, + IntegrityException, +) + +from ..abc import ( + BrokerSubscriberDuplicateValidator, +) +from .factories import ( + PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, +) + + +class PostgreSqlBrokerSubscriberDuplicateValidator(BrokerSubscriberDuplicateValidator, DatabaseMixin): + """PostgreSql Broker Subscriber Duplicate Detector class.""" + + def __init__( + self, query_factory: Optional[PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory] = None, *args, **kwargs + ): + if query_factory is None: + query_factory = PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory() + super().__init__(*args, **kwargs) + self._query_factory = query_factory + + async def _setup(self) -> None: + await super()._setup() + await self._create_table() + + async def _create_table(self) -> None: + operation = self._query_factory.build_create_table() + await self.submit_query(operation) + + @property + def query_factory(self) -> PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory: + """Get the query factory. + + :return: A ``PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory`` instance. + """ + return self._query_factory + + async def _is_unique(self, topic: str, uuid: UUID) -> bool: + operation = self._query_factory.build_insert_row(topic, uuid) + try: + await self.submit_query(operation) + return True + except IntegrityException: + return False + + +class PostgreSqlBrokerSubscriberDuplicateValidatorBuilder(Builder[PostgreSqlBrokerSubscriberDuplicateValidator]): + """PostgreSql Broker Subscriber Duplicate Detector Builder class.""" + + def with_config(self, config: Config): + """Set config. + + :param config: The config to be set. + :return: This method return the builder instance. + """ + self.kwargs |= {"database_key": None} + return super().with_config(config) + + +PostgreSqlBrokerSubscriberDuplicateValidator.set_builder(PostgreSqlBrokerSubscriberDuplicateValidatorBuilder) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py deleted file mode 100644 index 557092370..000000000 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/pg.py +++ /dev/null @@ -1,131 +0,0 @@ -from __future__ import ( - annotations, -) - -from typing import ( - Optional, -) -from uuid import ( - UUID, -) - -from psycopg2.sql import ( - SQL, -) - -from minos.common import ( - Builder, - Config, - DatabaseMixin, - IntegrityException, -) - -from .abc import ( - BrokerSubscriberDuplicateValidator, -) - - -class PostgreSqlBrokerSubscriberDuplicateValidator(BrokerSubscriberDuplicateValidator, DatabaseMixin): - """PostgreSql Broker Subscriber Duplicate Detector class.""" - - def __init__( - self, query_factory: Optional[PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory] = None, *args, **kwargs - ): - if query_factory is None: - query_factory = PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory() - super().__init__(*args, **kwargs) - self._query_factory = query_factory - - async def _setup(self) -> None: - await super()._setup() - await self._create_table() - - async def _create_table(self) -> None: - await self.submit_query( - self._query_factory.build_activate_uuid_extension(), - lock=self._query_factory.build_uuid_extension_name(), - ) - await self.submit_query( - self._query_factory.build_create_table(), - lock=self._query_factory.build_table_name(), - ) - - @property - def query_factory(self) -> PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory: - """Get the query factory. - - :return: A ``PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory`` instance. - """ - return self._query_factory - - async def _is_unique(self, topic: str, uuid: UUID) -> bool: - try: - await self.submit_query(self._query_factory.build_insert_row(), {"topic": topic, "uuid": uuid}) - return True - except IntegrityException: - return False - - -class PostgreSqlBrokerSubscriberDuplicateValidatorBuilder(Builder[PostgreSqlBrokerSubscriberDuplicateValidator]): - """PostgreSql Broker Subscriber Duplicate Detector Builder class.""" - - def with_config(self, config: Config): - """Set config. - - :param config: The config to be set. - :return: This method return the builder instance. - """ - self.kwargs |= {"database_key": None} - return super().with_config(config) - - -PostgreSqlBrokerSubscriberDuplicateValidator.set_builder(PostgreSqlBrokerSubscriberDuplicateValidatorBuilder) - - -# noinspection SqlNoDataSourceInspection -class PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory: - """PostgreSql Broker Subscriber Duplicate Detector Query Factory class.""" - - @staticmethod - def build_uuid_extension_name() -> str: - """Build the uuid extension name. - - :return: A ``str`` instance. - """ - return "uuid-ossp" - - def build_activate_uuid_extension(self) -> SQL: - """Build activate uuid extension query. - - :return: A ``SQL`` instance. - """ - return SQL(f'CREATE EXTENSION IF NOT EXISTS "{self.build_uuid_extension_name()}";') - - @staticmethod - def build_table_name() -> str: - """Build the table name. - - :return: A ``str`` instance. - """ - return "broker_subscriber_processed_messages" - - def build_create_table(self) -> SQL: - """Build the "create table" query. - - :return: A ``SQL`` instance. - """ - return SQL( - f"CREATE TABLE IF NOT EXISTS {self.build_table_name()} (" - " topic VARCHAR(255) NOT NULL, " - " uuid UUID NOT NULL, " - " created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()," - " PRIMARY KEY (topic, uuid)" - ")" - ) - - def build_insert_row(self) -> SQL: - """Build the "insert row" query. - - :return: A ``SQL`` instance. - """ - return SQL(f"INSERT INTO {self.build_table_name()}(topic, uuid) VALUES(%(topic)s, %(uuid)s)") From 9ec8b65563d98535131d3c585520ac048b71f9c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 12:46:58 +0200 Subject: [PATCH 142/324] ISSUE #367 * Remove `notifications` from `DatabaseClient`. --- .../minos/common/database/clients/abc.py | 16 --------------- .../minos/common/database/clients/aiopg.py | 7 ------- .../test_database/test_clients/test_abc.py | 20 +------------------ .../test_database/test_clients/test_aiopg.py | 4 ---- .../networks/brokers/collections/queues/pg.py | 2 +- 5 files changed, 2 insertions(+), 47 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 5e48da019..afcab26fc 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -6,9 +6,6 @@ ABC, abstractmethod, ) -from asyncio import ( - Queue, -) from collections.abc import ( AsyncIterator, ) @@ -90,19 +87,6 @@ def fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: raise NotImplementedError - @property - def notifications(self) -> Queue: - """Get the notifications queue. - - :return: A ``Queue`` instance. - """ - return self._notifications - - @property - @abstractmethod - def _notifications(self) -> Queue: - raise NotImplementedError - class DatabaseClientBuilder(Builder[DatabaseClient]): """Database Client Builder class.""" diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index e96ad655e..7a3e4a470 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -18,9 +18,6 @@ Connection, Cursor, ) -from aiopg.utils import ( - ClosableQueue, -) from psycopg2 import ( IntegrityError, OperationalError, @@ -194,10 +191,6 @@ def cursor(self) -> Optional[Cursor]: """ return self._cursor - @property - def _notifications(self) -> ClosableQueue: - return self._connection.notifies - @property def connection(self) -> Optional[Connection]: """Get the connection. diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index 0ef24717e..69f948785 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -2,9 +2,6 @@ from abc import ( ABC, ) -from asyncio import ( - Queue, -) from typing import ( Any, AsyncIterator, @@ -12,9 +9,7 @@ from unittest.mock import ( AsyncMock, MagicMock, - PropertyMock, call, - patch, ) from minos.common import ( @@ -44,16 +39,11 @@ async def _execute(self, *args, **kwargs) -> None: def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: """For testing purposes.""" - # noinspection PyPropertyDefinition - @property - def _notifications(self) -> Queue: - """For testing purposes.""" - class TestDatabaseClient(unittest.IsolatedAsyncioTestCase): def test_abstract(self): self.assertTrue(issubclass(DatabaseClient, (ABC, BuildableMixin))) - expected = {"_notifications", "_is_valid", "_execute", "_fetch_all", "_reset"} + expected = {"_is_valid", "_execute", "_fetch_all", "_reset"} # noinspection PyUnresolvedReferences self.assertEqual(expected, DatabaseClient.__abstractmethods__) @@ -106,14 +96,6 @@ async def test_fetch_one(self): self.assertEqual([call()], mock.call_args_list) - async def test_notifications(self): - expected = Queue() - client = _DatabaseClient() - with patch.object(_DatabaseClient, "_notifications", new_callable=PropertyMock, return_value=expected) as mock: - self.assertEqual(expected, client.notifications) - - self.assertEqual([call()], mock.call_args_list) - class TestDatabaseClientBuilder(CommonTestCase): def test_with_name(self): diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py index ee28deae3..1dc7f261e 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py @@ -83,10 +83,6 @@ async def test_connection_raises(self): async with AiopgDatabaseClient.from_config(self.config): pass - async def test_notifications(self): - async with AiopgDatabaseClient.from_config(self.config) as client: - self.assertEqual(client.connection.notifies, client.notifications) - async def test_cursor(self): client = AiopgDatabaseClient.from_config(self.config) self.assertIsNone(client.cursor) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py index 1316e280b..69d44cf9a 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py @@ -197,7 +197,7 @@ async def _wait_for_entries(self, client: DatabaseClient, max_wait: Optional[flo return with suppress(TimeoutError): - return await wait_for(consume_queue(client.notifications, self._records), max_wait) + return await wait_for(consume_queue(client.connection.notifies, self._records), max_wait) async def _get_count(self, client: DatabaseClient) -> int: # noinspection PyTypeChecker From 2a10dfde97aa79a21fbd64570250c505c0f5850f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 13:08:55 +0200 Subject: [PATCH 143/324] ISSUE #371 * Replace Postgres' listen/notify by `asyncio.Event`. --- .../networks/brokers/collections/queues/pg.py | 80 ++++++------------- .../validators/duplicates/__init__.py | 6 +- .../duplicates/database/__init__.py | 6 +- .../duplicates/database/factories/__init__.py | 2 +- .../duplicates/database/factories/aiopg.py | 14 +++- .../brokers/subscribers/queued/queues/pg.py | 45 ++--------- 6 files changed, 48 insertions(+), 105 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py index 69d44cf9a..0aca93711 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py @@ -9,6 +9,7 @@ ) from asyncio import ( CancelledError, + Event, PriorityQueue, QueueEmpty, TimeoutError, @@ -38,9 +39,6 @@ DatabaseMixin, ) -from ....utils import ( - consume_queue, -) from ...messages import ( BrokerMessage, ) @@ -78,6 +76,7 @@ def __init__( self._queue = PriorityQueue(maxsize=records) self._run_task = None + self._enqueued_event = Event() @property def retry(self) -> int: @@ -150,8 +149,9 @@ async def _enqueue(self, message: BrokerMessage) -> None: await self.submit_query_and_fetchone(self._query_factory.build_insert(), (message.topic, message.avro_bytes)) await self._notify_enqueued(message) + # noinspection PyUnusedLocal async def _notify_enqueued(self, message: BrokerMessage) -> None: - await self.submit_query(self._query_factory.build_notify()) + self._enqueued_event.set() async def _dequeue(self) -> BrokerMessage: while True: @@ -173,48 +173,39 @@ async def _dequeue(self) -> BrokerMessage: self._queue.task_done() async def _run(self, max_wait: Optional[float] = 60.0) -> NoReturn: - async with self.pool.acquire() as client: - await self._listen_entries(client) - try: - while self._run_task is not None: - await self._wait_for_entries(client, max_wait) - await self._dequeue_batch(client) - finally: - await self._unlisten_entries(client) + while self._run_task is not None: + await self._wait_for_entries(max_wait) + await self._dequeue_batch() - async def _listen_entries(self, client: DatabaseClient) -> None: - # noinspection PyTypeChecker - await client.execute(self._query_factory.build_listen()) - - async def _unlisten_entries(self, client: DatabaseClient) -> None: - if not client.already_destroyed: - # noinspection PyTypeChecker - await client.execute(self._query_factory.build_unlisten()) - - async def _wait_for_entries(self, client: DatabaseClient, max_wait: Optional[float]) -> None: + async def _wait_for_entries(self, max_wait: Optional[float]) -> None: while True: - if await self._get_count(client): + if await self._get_count(): return with suppress(TimeoutError): - return await wait_for(consume_queue(client.connection.notifies, self._records), max_wait) + return await wait_for(self._wait_enqueued(), max_wait) + + async def _wait_enqueued(self) -> None: + await self._enqueued_event.wait() + self._enqueued_event.clear() - async def _get_count(self, client: DatabaseClient) -> int: + async def _get_count(self) -> int: # noinspection PyTypeChecker - await client.execute(self._query_factory.build_count_not_processed(), (self._retry,)) - count = (await client.fetch_one())[0] + row = await self.submit_query_and_fetchone(self._query_factory.build_count_not_processed(), (self._retry,)) + count = row[0] return count - async def _dequeue_batch(self, client: DatabaseClient) -> None: - rows = await self._dequeue_rows(client) + async def _dequeue_batch(self) -> None: + async with self.pool.acquire() as client: + rows = await self._dequeue_rows(client) - if not len(rows): - return + if not len(rows): + return - entries = [_Entry(*row) for row in rows] + entries = [_Entry(*row) for row in rows] - # noinspection PyTypeChecker - await client.execute(self._query_factory.build_mark_processing(), (tuple(entry.id_ for entry in entries),)) + # noinspection PyTypeChecker + await client.execute(self._query_factory.build_mark_processing(), (tuple(entry.id_ for entry in entries),)) for entry in entries: await self._queue.put(entry) @@ -277,27 +268,6 @@ def build_mark_processing(self) -> SQL: """ return SQL(f"UPDATE {self.build_table_name()} SET processing = TRUE WHERE id IN %s") - def build_notify(self) -> SQL: - """Build the "notify" query. - - :return: A ``SQL`` instance. - """ - return SQL(f"NOTIFY {self.build_table_name()}") - - def build_listen(self) -> SQL: - """Build the "listen" query. - - :return: A ``SQL`` instance. - """ - return SQL(f"LISTEN {self.build_table_name()}") - - def build_unlisten(self) -> SQL: - """Build the "unlisten" query. - - :return: A ``SQL`` instance. - """ - return SQL(f"UNLISTEN {self.build_table_name()}") - def build_count_not_processed(self) -> SQL: """Build the "count not processed" query. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py index 5d6055ce4..61867b5aa 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py @@ -1,11 +1,11 @@ from .abc import ( BrokerSubscriberDuplicateValidator, ) -from .memory import ( - InMemoryBrokerSubscriberDuplicateValidator, -) from .database import ( PostgreSqlBrokerSubscriberDuplicateValidator, PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, ) +from .memory import ( + InMemoryBrokerSubscriberDuplicateValidator, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py index 2506b7845..73b7ae821 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py @@ -1,7 +1,7 @@ +from .factories import ( + PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, +) from .impl import ( PostgreSqlBrokerSubscriberDuplicateValidator, PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, ) -from .factories import ( - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, -) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py index 013bb3bac..0b61d1d4c 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py @@ -1,3 +1,3 @@ from .aiopg import ( PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, -) \ No newline at end of file +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py index f0f08cc7f..780b3dcf7 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py @@ -1,8 +1,16 @@ -from uuid import UUID +from uuid import ( + UUID, +) -from psycopg2.sql import SQL +from psycopg2.sql import ( + SQL, +) -from minos.common import AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation +from minos.common import ( + AiopgDatabaseOperation, + ComposedDatabaseOperation, + DatabaseOperation, +) # noinspection SqlNoDataSourceInspection,SqlResolve diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py index 3a3804622..0f60649ef 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py @@ -10,7 +10,6 @@ from psycopg2.sql import ( SQL, - Identifier, ) from minos.common import ( @@ -22,9 +21,6 @@ PostgreSqlBrokerQueueBuilder, PostgreSqlBrokerQueueQueryFactory, ) -from ....messages import ( - BrokerMessage, -) from .abc import ( BrokerSubscriberQueue, BrokerSubscriberQueueBuilder, @@ -43,22 +39,12 @@ def __init__( query_factory = PostgreSqlBrokerSubscriberQueueQueryFactory() super().__init__(topics, *args, query_factory=query_factory, **kwargs) - async def _notify_enqueued(self, message: BrokerMessage) -> None: - await self.submit_query(self._query_factory.build_notify().format(Identifier(message.topic))) - - async def _listen_entries(self, client: DatabaseClient) -> None: - for topic in self.topics: - await client.execute(self._query_factory.build_listen().format(Identifier(topic))) - - async def _unlisten_entries(self, client: DatabaseClient) -> None: - if not client.already_destroyed: - for topic in self.topics: - await client.execute(self._query_factory.build_unlisten().format(Identifier(topic))) - - async def _get_count(self, client: DatabaseClient) -> int: + async def _get_count(self) -> int: # noinspection PyTypeChecker - await client.execute(self._query_factory.build_count_not_processed(), (self._retry, tuple(self.topics))) - count = (await client.fetch_one())[0] + row = await self.submit_query_and_fetchone( + self._query_factory.build_count_not_processed(), (self._retry, tuple(self.topics)) + ) + count = row[0] return count async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: @@ -80,27 +66,6 @@ def build_table_name(self) -> str: """ return "broker_subscriber_queue" - def build_notify(self) -> SQL: - """Build the "notify" query. - - :return: A ``SQL`` instance. - """ - return SQL("NOTIFY {}") - - def build_listen(self) -> SQL: - """Build the "listen" query. - - :return: A ``SQL`` instance. - """ - return SQL("LISTEN {}") - - def build_unlisten(self) -> SQL: - """Build the "unlisten" query. - - :return: A ``SQL`` instance. - """ - return SQL("UNLISTEN {}") - def build_count_not_processed(self) -> SQL: """Build the "count not processed" query. From 1e2f90f4b0df2a4bc47308c8422e2d5f85daa359 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 13:39:24 +0200 Subject: [PATCH 144/324] ISSUE #371 * Refactor `PostgreSqlBrokerQueue`. --- .../brokers/collections/queues/__init__.py | 8 +- .../collections/queues/database/__init__.py | 7 + .../queues/database/factories/__init__.py | 3 + .../queues/database/factories/abc.py | 0 .../queues/database/factories/aiopg.py | 125 ++++++++++++++++++ .../queues/{pg.py => database/impl.py} | 124 +++-------------- .../subscribers/queued/queues/__init__.py | 10 +- .../queued/queues/database/__init__.py | 7 + .../queues/database/factories/__init__.py | 3 + .../queued/queues/database/factories/aiopg.py | 61 +++++++++ .../queued/queues/database/impl.py | 63 +++++++++ .../brokers/subscribers/queued/queues/pg.py | 100 -------------- 12 files changed, 299 insertions(+), 212 deletions(-) create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py rename packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/{pg.py => database/impl.py} (63%) create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py delete mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py index 6bba1e258..6af27b461 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py @@ -1,11 +1,11 @@ from .abc import ( BrokerQueue, ) -from .memory import ( - InMemoryBrokerQueue, -) -from .pg import ( +from .database import ( PostgreSqlBrokerQueue, PostgreSqlBrokerQueueBuilder, PostgreSqlBrokerQueueQueryFactory, ) +from .memory import ( + InMemoryBrokerQueue, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py new file mode 100644 index 000000000..07ce83a2e --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py @@ -0,0 +1,7 @@ +from .factories import ( + PostgreSqlBrokerQueueQueryFactory, +) +from .impl import ( + PostgreSqlBrokerQueue, + PostgreSqlBrokerQueueBuilder, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py new file mode 100644 index 000000000..bcbfb3743 --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py @@ -0,0 +1,3 @@ +from .aiopg import ( + PostgreSqlBrokerQueueQueryFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py new file mode 100644 index 000000000..bbe6bd8d1 --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py @@ -0,0 +1,125 @@ +from abc import ( + ABC, + abstractmethod, +) +from collections.abc import ( + Iterable, +) + +from psycopg2.sql import ( + SQL, +) + +from minos.common import ( + AiopgDatabaseOperation, + DatabaseOperation, +) + + +# noinspection SqlResolve,SqlNoDataSourceInspection,SqlNoDataSourceInspection,SqlResolve +class PostgreSqlBrokerQueueQueryFactory(ABC): + """PostgreSql Broker Queue Query Factory class.""" + + @abstractmethod + def build_table_name(self) -> str: + """Get the table name. + + :return: A ``str`` value. + """ + raise NotImplementedError + + def build_create_table(self) -> DatabaseOperation: + """Build the "create table" query. + + :return: A ``SQL`` instance. + """ + return AiopgDatabaseOperation( + SQL( + f"CREATE TABLE IF NOT EXISTS {self.build_table_name()} (" + "id BIGSERIAL NOT NULL PRIMARY KEY, " + "topic VARCHAR(255) NOT NULL, " + "data BYTEA NOT NULL, " + "retry INTEGER NOT NULL DEFAULT 0, " + "processing BOOL NOT NULL DEFAULT FALSE, " + "created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(), " + "updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW())" + ), + lock=self.build_table_name(), + ) + + def build_update_not_processed(self, id_: int) -> DatabaseOperation: + """Build the "update not processed" query. + + :return: A ``SQL`` instance. + """ + return AiopgDatabaseOperation( + SQL( + f"UPDATE {self.build_table_name()} " + "SET processing = FALSE, retry = retry + 1, updated_at = NOW() WHERE id = %(id)s" + ), + {"id": id_}, + ) + + def build_delete_processed(self, id_: int) -> DatabaseOperation: + """Build the "delete processed" query. + + :return: A ``SQL`` instance. + """ + return AiopgDatabaseOperation( + SQL(f"DELETE FROM {self.build_table_name()} WHERE id = %(id)s"), + {"id": id_}, + ) + + def build_mark_processing(self, ids: Iterable[int]) -> DatabaseOperation: + """ + + :return: A ``SQL`` instance. + """ + return AiopgDatabaseOperation( + SQL(f"UPDATE {self.build_table_name()} SET processing = TRUE WHERE id IN %(ids)s"), + {"ids": tuple(ids)}, + ) + + def build_count_not_processed(self, retry: int, *args, **kwargs) -> DatabaseOperation: + """Build the "count not processed" query. + + :return: + """ + return AiopgDatabaseOperation( + SQL( + f"SELECT COUNT(*) FROM (SELECT id FROM {self.build_table_name()} " + "WHERE NOT processing AND retry < %(retry)s FOR UPDATE SKIP LOCKED) s" + ), + {"retry": retry}, + ) + + def build_insert(self, topic: str, data: bytes) -> DatabaseOperation: + """Build the "insert" query. + + :return: A ``SQL`` instance. + """ + return AiopgDatabaseOperation( + SQL(f"INSERT INTO {self.build_table_name()} (topic, data) VALUES (%(topic)s, %(data)s) RETURNING id"), + {"topic": topic, "data": data}, + ) + + def build_select_not_processed(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: + """Build the "select not processed" query. + + :return: A ``SQL`` instance. + """ + return AiopgDatabaseOperation( + SQL( + "SELECT id, data " + f"FROM {self.build_table_name()} " + "WHERE NOT processing AND retry < %(retry)s " + "ORDER BY created_at " + "LIMIT %(records)s " + "FOR UPDATE " + "SKIP LOCKED" + ), + { + "retry": retry, + "records": records, + }, + ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py similarity index 63% rename from packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py rename to packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index 0aca93711..90f74e74c 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -3,10 +3,6 @@ ) import logging -from abc import ( - ABC, - abstractmethod, -) from asyncio import ( CancelledError, Event, @@ -28,9 +24,6 @@ from cached_property import ( cached_property, ) -from psycopg2.sql import ( - SQL, -) from minos.common import ( Builder, @@ -39,12 +32,15 @@ DatabaseMixin, ) -from ...messages import ( +from ....messages import ( BrokerMessage, ) -from .abc import ( +from ..abc import ( BrokerQueue, ) +from .factories import ( + PostgreSqlBrokerQueueQueryFactory, +) logger = logging.getLogger(__name__) @@ -121,7 +117,8 @@ async def _destroy(self) -> None: await super()._destroy() async def _create_table(self) -> None: - await self.submit_query(self._query_factory.build_create_table(), lock=self._query_factory.build_table_name()) + operation = self._query_factory.build_create_table() + await self.submit_query(operation) async def _start_run(self) -> None: if self._run_task is None: @@ -142,11 +139,13 @@ async def _flush_queue(self): entry = self._queue.get_nowait() except QueueEmpty: break - await self.submit_query(self._query_factory.build_update_not_processed(), (entry.id_,)) + operation = self._query_factory.build_update_not_processed(entry.id_) + await self.submit_query(operation) self._queue.task_done() async def _enqueue(self, message: BrokerMessage) -> None: - await self.submit_query_and_fetchone(self._query_factory.build_insert(), (message.topic, message.avro_bytes)) + operation = self._query_factory.build_insert(message.topic, message.avro_bytes) + await self.submit_query_and_fetchone(operation) await self._notify_enqueued(message) # noinspection PyUnusedLocal @@ -164,10 +163,12 @@ async def _dequeue(self) -> BrokerMessage: logger.warning( f"There was a problem while trying to deserialize the entry with {entry.id_!r} id: {exc}" ) - await self.submit_query(self._query_factory.build_update_not_processed(), (entry.id_,)) + operation = self._query_factory.build_update_not_processed(entry.id_) + await self.submit_query(operation) continue - await self.submit_query(self._query_factory.build_delete_processed(), (entry.id_,)) + operation = self._query_factory.build_delete_processed(entry.id_) + await self.submit_query(operation) return message finally: self._queue.task_done() @@ -191,7 +192,8 @@ async def _wait_enqueued(self) -> None: async def _get_count(self) -> int: # noinspection PyTypeChecker - row = await self.submit_query_and_fetchone(self._query_factory.build_count_not_processed(), (self._retry,)) + operation = self._query_factory.build_count_not_processed(self.retry) + row = await self.submit_query_and_fetchone(operation) count = row[0] return count @@ -204,103 +206,19 @@ async def _dequeue_batch(self) -> None: entries = [_Entry(*row) for row in rows] - # noinspection PyTypeChecker - await client.execute(self._query_factory.build_mark_processing(), (tuple(entry.id_ for entry in entries),)) + ids = tuple(entry.id_ for entry in entries) + operation = self._query_factory.build_mark_processing(ids) + await client.execute(operation) for entry in entries: await self._queue.put(entry) async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: # noinspection PyTypeChecker - await client.execute(self._query_factory.build_select_not_processed(), (self._retry, self._records)) + await client.execute(self._query_factory.build_select_not_processed(self._retry, self._records)) return [row async for row in client.fetch_all()] -# noinspection SqlResolve,SqlNoDataSourceInspection -class PostgreSqlBrokerQueueQueryFactory(ABC): - """PostgreSql Broker Queue Query Factory class.""" - - @abstractmethod - def build_table_name(self) -> str: - """Get the table name. - - :return: A ``str`` value. - """ - raise NotImplementedError - - def build_create_table(self) -> SQL: - """Build the "create table" query. - - :return: A ``SQL`` instance. - """ - return SQL( - f"CREATE TABLE IF NOT EXISTS {self.build_table_name()} (" - "id BIGSERIAL NOT NULL PRIMARY KEY, " - "topic VARCHAR(255) NOT NULL, " - "data BYTEA NOT NULL, " - "retry INTEGER NOT NULL DEFAULT 0, " - "processing BOOL NOT NULL DEFAULT FALSE, " - "created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(), " - "updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW())" - ) - - def build_update_not_processed(self) -> SQL: - """Build the "update not processed" query. - - :return: A ``SQL`` instance. - """ - return SQL( - f"UPDATE {self.build_table_name()} " - "SET processing = FALSE, retry = retry + 1, updated_at = NOW() WHERE id = %s" - ) - - def build_delete_processed(self) -> SQL: - """Build the "delete processed" query. - - :return: A ``SQL`` instance. - """ - return SQL(f"DELETE FROM {self.build_table_name()} WHERE id = %s") - - def build_mark_processing(self) -> SQL: - """ - - :return: A ``SQL`` instance. - """ - return SQL(f"UPDATE {self.build_table_name()} SET processing = TRUE WHERE id IN %s") - - def build_count_not_processed(self) -> SQL: - """Build the "count not processed" query. - - :return: - """ - return SQL( - f"SELECT COUNT(*) FROM (SELECT id FROM {self.build_table_name()} " - "WHERE NOT processing AND retry < %s FOR UPDATE SKIP LOCKED) s" - ) - - def build_insert(self) -> SQL: - """Build the "insert" query. - - :return: A ``SQL`` instance. - """ - return SQL(f"INSERT INTO {self.build_table_name()} (topic, data) VALUES (%s, %s) RETURNING id") - - def build_select_not_processed(self) -> SQL: - """Build the "select not processed" query. - - :return: A ``SQL`` instance. - """ - return SQL( - "SELECT id, data " - f"FROM {self.build_table_name()} " - "WHERE NOT processing AND retry < %s " - "ORDER BY created_at " - "LIMIT %s " - "FOR UPDATE " - "SKIP LOCKED" - ) - - class _Entry: def __init__(self, id_: int, data_bytes: bytes): self.id_ = id_ diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py index b1396e194..e94cfbd15 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py @@ -2,12 +2,12 @@ BrokerSubscriberQueue, BrokerSubscriberQueueBuilder, ) -from .memory import ( - InMemoryBrokerSubscriberQueue, - InMemoryBrokerSubscriberQueueBuilder, -) -from .pg import ( +from .database import ( PostgreSqlBrokerSubscriberQueue, PostgreSqlBrokerSubscriberQueueBuilder, PostgreSqlBrokerSubscriberQueueQueryFactory, ) +from .memory import ( + InMemoryBrokerSubscriberQueue, + InMemoryBrokerSubscriberQueueBuilder, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py new file mode 100644 index 000000000..4bbdf989d --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py @@ -0,0 +1,7 @@ +from .factories import ( + PostgreSqlBrokerSubscriberQueueQueryFactory, +) +from .impl import ( + PostgreSqlBrokerSubscriberQueue, + PostgreSqlBrokerSubscriberQueueBuilder, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py new file mode 100644 index 000000000..9a2ef153d --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py @@ -0,0 +1,3 @@ +from .aiopg import ( + PostgreSqlBrokerSubscriberQueueQueryFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py new file mode 100644 index 000000000..edb2bd4db --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py @@ -0,0 +1,61 @@ +from collections.abc import ( + Iterable, +) + +from psycopg2.sql import ( + SQL, +) + +from minos.common import ( + AiopgDatabaseOperation, + DatabaseOperation, +) +from minos.networks.brokers.collections import ( + PostgreSqlBrokerQueueQueryFactory, +) + + +# noinspection SqlNoDataSourceInspection,SqlResolve,PyTypeChecker,PyArgumentList +class PostgreSqlBrokerSubscriberQueueQueryFactory(PostgreSqlBrokerQueueQueryFactory): + """PostgreSql Broker Subscriber Queue Query Factory class.""" + + def build_table_name(self) -> str: + """Get the table name. + + :return: A ``str`` value. + """ + return "broker_subscriber_queue" + + def build_count_not_processed( + self, retry: int, topics: Iterable[str] = tuple(), *args, **kwargs + ) -> DatabaseOperation: + """Build the "count not processed" query. + + :return: + """ + return AiopgDatabaseOperation( + SQL( + f"SELECT COUNT(*) FROM (SELECT id FROM {self.build_table_name()} " + "WHERE NOT processing AND retry < %(retry)s AND topic IN %(topics)s FOR UPDATE SKIP LOCKED) s" + ), + {"retry": retry, "topics": tuple(topics)}, + ) + + def build_select_not_processed( + self, retry: int, records: int, topics: Iterable[str] = tuple(), *args, **kwargs + ) -> DatabaseOperation: + """Build the "select not processed" query. + + :return: A ``SQL`` instance. + """ + return AiopgDatabaseOperation( + SQL( + "SELECT id, data " + f"FROM {self.build_table_name()} " + "WHERE NOT processing AND retry < %(retry)s AND topic IN %(topics)s " + "ORDER BY created_at " + "LIMIT %(records)s " + "FOR UPDATE SKIP LOCKED" + ), + {"retry": retry, "topics": tuple(topics), "records": records}, + ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py new file mode 100644 index 000000000..932b0ea6a --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py @@ -0,0 +1,63 @@ +from __future__ import ( + annotations, +) + +import logging +from typing import ( + Any, + Optional, +) + +from minos.common import ( + DatabaseClient, +) + +from .....collections import ( + PostgreSqlBrokerQueue, + PostgreSqlBrokerQueueBuilder, +) +from ..abc import ( + BrokerSubscriberQueue, + BrokerSubscriberQueueBuilder, +) +from .factories import ( + PostgreSqlBrokerSubscriberQueueQueryFactory, +) + +logger = logging.getLogger(__name__) + + +class PostgreSqlBrokerSubscriberQueue(PostgreSqlBrokerQueue, BrokerSubscriberQueue): + """PostgreSql Broker Subscriber Queue class.""" + + def __init__( + self, + topics: set[str], + *args, + query_factory: Optional[PostgreSqlBrokerSubscriberQueueQueryFactory] = None, + **kwargs, + ): + if query_factory is None: + query_factory = PostgreSqlBrokerSubscriberQueueQueryFactory() + super().__init__(topics, *args, query_factory=query_factory, **kwargs) + + async def _get_count(self) -> int: + # noinspection PyTypeChecker + operation = self._query_factory.build_count_not_processed(self._retry, self.topics) + row = await self.submit_query_and_fetchone(operation) + count = row[0] + return count + + async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: + # noinspection PyTypeChecker + await client.execute(self._query_factory.build_select_not_processed(self._retry, self._records, self.topics)) + return [row async for row in client.fetch_all()] + + +class PostgreSqlBrokerSubscriberQueueBuilder( + BrokerSubscriberQueueBuilder[PostgreSqlBrokerSubscriberQueue], PostgreSqlBrokerQueueBuilder +): + """PostgreSql Broker Subscriber Queue Builder class.""" + + +PostgreSqlBrokerSubscriberQueue.set_builder(PostgreSqlBrokerSubscriberQueueBuilder) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py deleted file mode 100644 index 0f60649ef..000000000 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/pg.py +++ /dev/null @@ -1,100 +0,0 @@ -from __future__ import ( - annotations, -) - -import logging -from typing import ( - Any, - Optional, -) - -from psycopg2.sql import ( - SQL, -) - -from minos.common import ( - DatabaseClient, -) - -from ....collections import ( - PostgreSqlBrokerQueue, - PostgreSqlBrokerQueueBuilder, - PostgreSqlBrokerQueueQueryFactory, -) -from .abc import ( - BrokerSubscriberQueue, - BrokerSubscriberQueueBuilder, -) - -logger = logging.getLogger(__name__) - - -class PostgreSqlBrokerSubscriberQueue(PostgreSqlBrokerQueue, BrokerSubscriberQueue): - """PostgreSql Broker Subscriber Queue class.""" - - def __init__( - self, topics: set[str], *args, query_factory: Optional[PostgreSqlBrokerQueueQueryFactory] = None, **kwargs - ): - if query_factory is None: - query_factory = PostgreSqlBrokerSubscriberQueueQueryFactory() - super().__init__(topics, *args, query_factory=query_factory, **kwargs) - - async def _get_count(self) -> int: - # noinspection PyTypeChecker - row = await self.submit_query_and_fetchone( - self._query_factory.build_count_not_processed(), (self._retry, tuple(self.topics)) - ) - count = row[0] - return count - - async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - # noinspection PyTypeChecker - await client.execute( - self._query_factory.build_select_not_processed(), (self._retry, tuple(self.topics), self._records) - ) - return [row async for row in client.fetch_all()] - - -# noinspection SqlNoDataSourceInspection,SqlResolve -class PostgreSqlBrokerSubscriberQueueQueryFactory(PostgreSqlBrokerQueueQueryFactory): - """PostgreSql Broker Subscriber Queue Query Factory class.""" - - def build_table_name(self) -> str: - """Get the table name. - - :return: A ``str`` value. - """ - return "broker_subscriber_queue" - - def build_count_not_processed(self) -> SQL: - """Build the "count not processed" query. - - :return: - """ - return SQL( - f"SELECT COUNT(*) FROM (SELECT id FROM {self.build_table_name()} " - "WHERE NOT processing AND retry < %s AND topic IN %s FOR UPDATE SKIP LOCKED) s" - ) - - def build_select_not_processed(self) -> SQL: - """Build the "select not processed" query. - - :return: A ``SQL`` instance. - """ - return SQL( - "SELECT id, data " - f"FROM {self.build_table_name()} " - "WHERE NOT processing AND retry < %s AND topic IN %s " - "ORDER BY created_at " - "LIMIT %s " - "FOR UPDATE SKIP LOCKED" - ) - - -class PostgreSqlBrokerSubscriberQueueBuilder( - BrokerSubscriberQueueBuilder[PostgreSqlBrokerSubscriberQueue], PostgreSqlBrokerQueueBuilder -): - """PostgreSql Broker Subscriber Queue Builder class.""" - - -PostgreSqlBrokerSubscriberQueue.set_builder(PostgreSqlBrokerSubscriberQueueBuilder) From a4dcfb1511ac6a503a90d94e96853977106528e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 15:18:55 +0200 Subject: [PATCH 145/324] ISSUE #371 * Minor change. --- .../aggregate/events/repositories/database/factories/abc.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py index 63019249d..c5da6bdb5 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py @@ -1,4 +1,5 @@ from abc import ( + ABC, abstractmethod, ) from typing import ( @@ -18,7 +19,7 @@ ) -class EventRepositoryOperationFactory: +class EventRepositoryOperationFactory(ABC): """TODO""" @abstractmethod From d4a6b692e90f063023f343adcf8a708b6ab760c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 15:47:56 +0200 Subject: [PATCH 146/324] ISSUE #371 * Minor improvements. --- .../minos-microservice-networks/minos/networks/__init__.py | 1 + .../minos/networks/brokers/__init__.py | 1 + .../subscribers/queued/queues/database/factories/aiopg.py | 3 ++- .../test_brokers/test_collections/test_queues/test_pg.py | 2 -- .../tests/test_graphql/test_handlers.py | 6 ++---- 5 files changed, 6 insertions(+), 7 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/__init__.py b/packages/core/minos-microservice-networks/minos/networks/__init__.py index 044a35b86..f68feb77b 100644 --- a/packages/core/minos-microservice-networks/minos/networks/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/__init__.py @@ -44,6 +44,7 @@ PostgreSqlBrokerPublisherQueueQueryFactory, PostgreSqlBrokerQueue, PostgreSqlBrokerQueueBuilder, + PostgreSqlBrokerQueueQueryFactory, PostgreSqlBrokerSubscriberDuplicateValidator, PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py index 7b87b020f..5c4fa93a5 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py @@ -6,6 +6,7 @@ InMemoryBrokerQueue, PostgreSqlBrokerQueue, PostgreSqlBrokerQueueBuilder, + PostgreSqlBrokerQueueQueryFactory, ) from .dispatchers import ( BrokerDispatcher, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py index edb2bd4db..f3d54569c 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py @@ -10,7 +10,8 @@ AiopgDatabaseOperation, DatabaseOperation, ) -from minos.networks.brokers.collections import ( + +from ......collections import ( PostgreSqlBrokerQueueQueryFactory, ) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index dd4c065ab..9585a68e4 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -19,8 +19,6 @@ BrokerMessageV1Payload, BrokerQueue, PostgreSqlBrokerQueue, -) -from minos.networks.brokers.collections import ( PostgreSqlBrokerQueueQueryFactory, ) from tests.utils import ( diff --git a/packages/plugins/minos-router-graphql/tests/test_graphql/test_handlers.py b/packages/plugins/minos-router-graphql/tests/test_graphql/test_handlers.py index 9397914d3..d95c2deff 100644 --- a/packages/plugins/minos-router-graphql/tests/test_graphql/test_handlers.py +++ b/packages/plugins/minos-router-graphql/tests/test_graphql/test_handlers.py @@ -16,12 +16,10 @@ ResponseException, ) from minos.plugins.graphql import ( - GraphQlHandler, - GraphQLSchemaBuilder, -) -from minos.plugins.graphql.decorators import ( GraphQlCommandEnrouteDecorator, + GraphQlHandler, GraphQlQueryEnrouteDecorator, + GraphQLSchemaBuilder, ) from tests.test_graphql.test_builders.test_schema import ( callback_fn, From 340e6688cbde78e42dae8cab1e5282d3ca21d619 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 15:48:39 +0200 Subject: [PATCH 147/324] ISSUE #371 * Add `AiopgSnapshotRepositoryOperationFactory`. --- .../minos/aggregate/snapshots/__init__.py | 2 +- .../snapshots/{pg => database}/__init__.py | 0 .../minos/aggregate/snapshots/database/abc.py | 39 +++++ .../snapshots/{pg => database}/api.py | 0 .../snapshots/database/factories/__init__.py | 6 + .../snapshots/database/factories/abc.py | 52 +++++++ .../snapshots/database/factories/aiopg.py | 140 ++++++++++++++++++ .../snapshots/{pg => database}/queries.py | 122 +++++++-------- .../snapshots/{pg => database}/readers.py | 0 .../snapshots/{pg => database}/writers.py | 50 +------ .../minos/aggregate/snapshots/pg/abc.py | 51 ------- .../test_snapshots/test_pg/test_queries.py | 14 +- 12 files changed, 312 insertions(+), 164 deletions(-) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{pg => database}/__init__.py (100%) create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{pg => database}/api.py (100%) create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg.py rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{pg => database}/queries.py (75%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{pg => database}/readers.py (100%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{pg => database}/writers.py (80%) delete mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py index eb026d9fd..b8b8f366a 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py @@ -7,7 +7,7 @@ from .memory import ( InMemorySnapshotRepository, ) -from .pg import ( +from .database import ( PostgreSqlSnapshotQueryBuilder, PostgreSqlSnapshotReader, PostgreSqlSnapshotRepository, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py similarity index 100% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/__init__.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py new file mode 100644 index 000000000..afdc0e099 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py @@ -0,0 +1,39 @@ +from __future__ import ( + annotations, +) + +from typing import ( + Type, + TypeVar, Optional, +) + +from minos.common import ( + Config, + DatabaseMixin, +) +from .factories import ( + SnapshotRepositoryOperationFactory, + AiopgSnapshotRepositoryOperationFactory +) + + +class PostgreSqlSnapshotSetup(DatabaseMixin): + """Minos Snapshot Setup Class""" + + def __init__(self, *args, operation_factory: Optional[SnapshotRepositoryOperationFactory] = None, **kwargs): + super().__init__(*args, **kwargs) + if operation_factory is None: + operation_factory = AiopgSnapshotRepositoryOperationFactory() + + self.operation_factory = operation_factory + + @classmethod + def _from_config(cls: Type[T], config: Config, **kwargs) -> T: + return cls(database_key=None, **kwargs) + + async def _setup(self) -> None: + operation = self.operation_factory.build_create_table() + await self.submit_query(operation) + + +T = TypeVar("T", bound=PostgreSqlSnapshotSetup) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/api.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py similarity index 100% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/api.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py new file mode 100644 index 000000000..c50410738 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py @@ -0,0 +1,6 @@ +from .abc import ( + SnapshotRepositoryOperationFactory, +) +from .aiopg import ( + AiopgSnapshotRepositoryOperationFactory, +) \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py new file mode 100644 index 000000000..16c02fd8c --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py @@ -0,0 +1,52 @@ +from abc import ( + ABC, + abstractmethod, +) +from collections.abc import ( + Iterable, +) +from typing import ( + Any, +) +from uuid import ( + UUID, +) + +from minos.common import ( + DatabaseOperation, + datetime, +) + + +class SnapshotRepositoryOperationFactory(ABC): + """TODO""" + + @abstractmethod + def build_create_table(self) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_store_offset(self, value: int) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_get_offset(self) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_insert( + self, + uuid: UUID, + name: str, + version: int, + schema: bytes, + data: dict[str, Any], + created_at: datetime, + updated_at: datetime, + transaction_uuid: UUID, + ) -> DatabaseOperation: + """TODO""" diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg.py new file mode 100644 index 000000000..e56f3c869 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg.py @@ -0,0 +1,140 @@ +from collections.abc import ( + Iterable, +) +from datetime import ( + datetime, +) +from typing import ( + Any, +) +from uuid import ( + UUID, +) + +from minos.common import ( + AiopgDatabaseOperation, + ComposedDatabaseOperation, + DatabaseOperation, +) + +from .abc import ( + SnapshotRepositoryOperationFactory, +) + + +# noinspection SqlNoDataSourceInspection,SqlResolve +class AiopgSnapshotRepositoryOperationFactory(SnapshotRepositoryOperationFactory): + """TODO""" + + def build_create_table(self) -> DatabaseOperation: + """TODO""" + return ComposedDatabaseOperation( + [ + AiopgDatabaseOperation( + 'CREATE EXTENSION IF NOT EXISTS "uuid-ossp";', + lock="uuid-ossp", + ), + AiopgDatabaseOperation( + """ + CREATE TABLE IF NOT EXISTS snapshot ( + uuid UUID NOT NULL, + name TEXT NOT NULL, + version INT NOT NULL, + schema BYTEA, + data JSONB, + created_at TIMESTAMPTZ NOT NULL, + updated_at TIMESTAMPTZ NOT NULL, + transaction_uuid UUID NOT NULL DEFAULT uuid_nil(), + PRIMARY KEY (uuid, transaction_uuid) + ); + """, + lock="snapshot", + ), + AiopgDatabaseOperation( + """ + CREATE TABLE IF NOT EXISTS snapshot_aux_offset ( + id bool PRIMARY KEY DEFAULT TRUE, + value BIGINT NOT NULL, + CONSTRAINT id_uni CHECK (id) + ); + """, + lock="snapshot_aux_offset", + ), + ] + ) + + def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: + """TODO""" + return AiopgDatabaseOperation( + """ + DELETE FROM snapshot + WHERE transaction_uuid IN %(transaction_uuids)s; + """, + {"transaction_uuids": tuple(transaction_uuids)}, + ) + + def build_store_offset(self, value: int) -> DatabaseOperation: + """TODO""" + return AiopgDatabaseOperation( + """ + INSERT INTO snapshot_aux_offset (id, value) + VALUES (TRUE, %(value)s) + ON CONFLICT (id) + DO UPDATE SET value = GREATEST(%(value)s, (SELECT value FROM snapshot_aux_offset WHERE id = TRUE)); + """.strip(), + {"value": value}, + lock="insert_snapshot_aux_offset" + ) + + def build_get_offset(self) -> DatabaseOperation: + """TODO""" + return AiopgDatabaseOperation( + """ + SELECT value + FROM snapshot_aux_offset + WHERE id = TRUE; + """ + ) + + def build_insert( + self, + uuid: UUID, + name: str, + version: int, + schema: bytes, + data: dict[str, Any], + created_at: datetime, + updated_at: datetime, + transaction_uuid: UUID, + ) -> DatabaseOperation: + """TODO""" + + return AiopgDatabaseOperation( + """ + INSERT INTO snapshot (uuid, name, version, schema, data, created_at, updated_at, transaction_uuid) + VALUES ( + %(uuid)s, + %(name)s, + %(version)s, + %(schema)s, + %(data)s, + %(created_at)s, + %(updated_at)s, + %(transaction_uuid)s + ) + ON CONFLICT (uuid, transaction_uuid) + DO + UPDATE SET version = %(version)s, schema = %(schema)s, data = %(data)s, updated_at = %(updated_at)s + RETURNING created_at, updated_at; + """.strip(), + { + "uuid": uuid, + "name": name, + "version": version, + "schema": schema, + "data": data, + "created_at": created_at, + "updated_at": updated_at, + "transaction_uuid": transaction_uuid, + }, + ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/queries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/queries.py similarity index 75% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/queries.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/queries.py index 5ba0f9a31..5eefc113d 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/queries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/queries.py @@ -52,6 +52,7 @@ ) +# noinspection SqlResolve,SqlNoDataSourceInspection class PostgreSqlSnapshotQueryBuilder: """PostgreSQL Snapshot Query Builder class. @@ -99,7 +100,7 @@ def _build(self) -> Composable: query = SQL(" WHERE ").join([self._build_select_from(), self._build_condition(self.condition)]) if self.exclude_deleted: - query = SQL(" AND ").join([query, _EXCLUDE_DELETED_CONDITION]) + query = SQL(" AND ").join([query, self._EXCLUDE_DELETED_CONDITION]) if self.ordering is not None: query = SQL(" ").join([query, self._build_ordering(self.ordering)]) @@ -116,12 +117,12 @@ def _build_select_from(self) -> Composable: self._parameters[name] = transaction_uuid from_query_parts.append( - _SELECT_TRANSACTION_CHUNK.format(index=Literal(index), transaction_uuid=Placeholder(name)) + self._SELECT_TRANSACTION_CHUNK.format(index=Literal(index), transaction_uuid=Placeholder(name)) ) from_query = SQL(" UNION ALL ").join(from_query_parts) - query = _SELECT_ENTRIES_QUERY.format(from_parts=from_query) + query = self._SELECT_ENTRIES_QUERY.format(from_parts=from_query) return query def _build_condition(self, condition: _Condition) -> Composable: @@ -145,14 +146,14 @@ def _build_condition_not(self, condition: _NotCondition) -> Composable: def _build_condition_composed(self, condition: _ComposedCondition) -> Composable: # noinspection PyTypeChecker - operator = _COMPOSED_MAPPER[type(condition)] + operator = self._COMPOSED_MAPPER[type(condition)] parts = (self._build_condition(c) for c in condition) return SQL("({composed})").format(composed=operator.join(parts)) def _build_condition_simple(self, condition: _SimpleCondition) -> Composable: field = condition.field # noinspection PyTypeChecker - operator = _SIMPLE_MAPPER[type(condition)] + operator = self._SIMPLE_MAPPER[type(condition)] parameter = AvroDataEncoder(condition.parameter).build() if isinstance(parameter, list): @@ -160,11 +161,11 @@ def _build_condition_simple(self, condition: _SimpleCondition) -> Composable: return self._build_condition(_FALSE_CONDITION) parameter = tuple(parameter) - if field in _FIXED_FIELDS_MAPPER: + if field in self._FIXED_FIELDS_MAPPER: name = self.generate_random_str() self._parameters[name] = parameter - field = _FIXED_FIELDS_MAPPER[field] + field = self._FIXED_FIELDS_MAPPER[field] name = Placeholder(name) return SQL("({field} {operator} {name})").format(field=field, operator=operator, name=name) else: @@ -180,11 +181,11 @@ def _build_condition_like(self, condition: _SimpleCondition) -> Composable: parameter = AvroDataEncoder(condition.parameter).build() - if field in _FIXED_FIELDS_MAPPER: + if field in self._FIXED_FIELDS_MAPPER: name = self.generate_random_str() self._parameters[name] = parameter - field = _FIXED_FIELDS_MAPPER[field] + field = self._FIXED_FIELDS_MAPPER[field] name = Placeholder(name) return SQL("({field}::text LIKE {name})").format(field=field, name=name) else: @@ -195,12 +196,11 @@ def _build_condition_like(self, condition: _SimpleCondition) -> Composable: name = Placeholder(name) return SQL("(data#>>{field} LIKE {name})").format(field=field, name=name) - @staticmethod - def _build_ordering(ordering: _Ordering) -> Composable: + def _build_ordering(self, ordering: _Ordering) -> Composable: field = ordering.by - direction = _ORDERING_MAPPER[ordering.reverse] + direction = self._ORDERING_MAPPER[ordering.reverse] - if field in _FIXED_FIELDS_MAPPER: + if field in self._FIXED_FIELDS_MAPPER: field = Identifier(field) order_by = SQL("ORDER BY {field} {direction}").format(field=field, direction=direction) else: @@ -223,51 +223,51 @@ def generate_random_str() -> str: return str(uuid4()) -_COMPOSED_MAPPER = {_AndCondition: SQL(" AND "), _OrCondition: SQL(" OR ")} - -_SIMPLE_MAPPER = { - _LowerCondition: SQL("<"), - _LowerEqualCondition: SQL("<="), - _GreaterCondition: SQL(">"), - _GreaterEqualCondition: SQL(">="), - _EqualCondition: SQL("="), - _NotEqualCondition: SQL("<>"), - _InCondition: SQL("IN"), -} - -_FIXED_FIELDS_MAPPER = { - "uuid": Identifier("uuid"), - "version": Identifier("version"), - "created_at": Identifier("created_at"), - "updated_at": Identifier("updated_at"), -} - -_ORDERING_MAPPER = { - True: SQL("DESC"), - False: SQL("ASC"), -} - -_SELECT_ENTRIES_QUERY = SQL( - "SELECT " - " t2.uuid, " - " t2.name, " - " t2.version, " - " t2.schema, " - " t2.data, " - " t2.created_at, " - " t2.updated_at, " - " t2.transaction_uuid " - "FROM (" - " SELECT DISTINCT ON (uuid) t1.* " - " FROM ( {from_parts} ) AS t1 " - " ORDER BY uuid, transaction_index DESC " - ") AS t2" -) - -_SELECT_TRANSACTION_CHUNK = SQL( - "SELECT {index} AS transaction_index, * " - "FROM snapshot " - "WHERE name = %(name)s AND transaction_uuid = {transaction_uuid} " -) - -_EXCLUDE_DELETED_CONDITION = SQL("(data IS NOT NULL)") + _COMPOSED_MAPPER = {_AndCondition: SQL(" AND "), _OrCondition: SQL(" OR ")} + + _SIMPLE_MAPPER = { + _LowerCondition: SQL("<"), + _LowerEqualCondition: SQL("<="), + _GreaterCondition: SQL(">"), + _GreaterEqualCondition: SQL(">="), + _EqualCondition: SQL("="), + _NotEqualCondition: SQL("<>"), + _InCondition: SQL("IN"), + } + + _FIXED_FIELDS_MAPPER = { + "uuid": Identifier("uuid"), + "version": Identifier("version"), + "created_at": Identifier("created_at"), + "updated_at": Identifier("updated_at"), + } + + _ORDERING_MAPPER = { + True: SQL("DESC"), + False: SQL("ASC"), + } + + _SELECT_ENTRIES_QUERY = SQL( + "SELECT " + " t2.uuid, " + " t2.name, " + " t2.version, " + " t2.schema, " + " t2.data, " + " t2.created_at, " + " t2.updated_at, " + " t2.transaction_uuid " + "FROM (" + " SELECT DISTINCT ON (uuid) t1.* " + " FROM ( {from_parts} ) AS t1 " + " ORDER BY uuid, transaction_index DESC " + ") AS t2" + ) + + _SELECT_TRANSACTION_CHUNK = SQL( + "SELECT {index} AS transaction_index, * " + "FROM snapshot " + "WHERE name = %(name)s AND transaction_uuid = {transaction_uuid} " + ) + + _EXCLUDE_DELETED_CONDITION = SQL("(data IS NOT NULL)") diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py similarity index 100% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/readers.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/writers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py similarity index 80% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/writers.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py index 23fecf450..e0a7d94cf 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/writers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py @@ -105,15 +105,17 @@ async def dispatch(self, **kwargs) -> None: await self._store_offset(offset) async def _load_offset(self, **kwargs) -> int: + operation = self.operation_factory.build_get_offset() # noinspection PyBroadException try: - raw = await self.submit_query_and_fetchone(_SELECT_OFFSET_QUERY, **kwargs) + raw = await self.submit_query_and_fetchone(operation, **kwargs) return raw[0] except Exception: return 0 async def _store_offset(self, offset: int) -> None: - await self.submit_query(_INSERT_OFFSET_QUERY, {"value": offset}, lock="insert_snapshot_aux_offset") + operation = self.operation_factory.build_store_offset(offset) + await self.submit_query(operation) async def _dispatch_one(self, event_entry: EventEntry, **kwargs) -> SnapshotEntry: if event_entry.action.is_delete: @@ -165,8 +167,8 @@ async def _select_one_instance(self, name: str, uuid: UUID, **kwargs) -> RootEnt return snapshot_entry.build(**kwargs) async def _submit_entry(self, snapshot_entry: SnapshotEntry, **kwargs) -> SnapshotEntry: - params = snapshot_entry.as_raw() - response = await self.submit_query_and_fetchone(_INSERT_ONE_SNAPSHOT_ENTRY_QUERY, params, **kwargs) + operation = self.operation_factory.build_insert(**snapshot_entry.as_raw()) + response = await self.submit_query_and_fetchone(operation, **kwargs) snapshot_entry.created_at, snapshot_entry.updated_at = response @@ -178,41 +180,5 @@ async def _clean_transactions(self, offset: int, **kwargs) -> None: ) transaction_uuids = {transaction.uuid async for transaction in iterable} if len(transaction_uuids): - await self.submit_query(_DELETE_SNAPSHOT_ENTRIES_QUERY, {"transaction_uuids": tuple(transaction_uuids)}) - - -_INSERT_ONE_SNAPSHOT_ENTRY_QUERY = """ -INSERT INTO snapshot (uuid, name, version, schema, data, created_at, updated_at, transaction_uuid) -VALUES ( - %(uuid)s, - %(name)s, - %(version)s, - %(schema)s, - %(data)s, - %(created_at)s, - %(updated_at)s, - %(transaction_uuid)s -) -ON CONFLICT (uuid, transaction_uuid) -DO - UPDATE SET version = %(version)s, schema = %(schema)s, data = %(data)s, updated_at = %(updated_at)s -RETURNING created_at, updated_at; -""".strip() - -_DELETE_SNAPSHOT_ENTRIES_QUERY = """ -DELETE FROM snapshot -WHERE transaction_uuid IN %(transaction_uuids)s; -""".strip() - -_SELECT_OFFSET_QUERY = """ -SELECT value -FROM snapshot_aux_offset -WHERE id = TRUE; -""" - -_INSERT_OFFSET_QUERY = """ -INSERT INTO snapshot_aux_offset (id, value) -VALUES (TRUE, %(value)s) -ON CONFLICT (id) -DO UPDATE SET value = GREATEST(%(value)s, (SELECT value FROM snapshot_aux_offset WHERE id = TRUE)); -""".strip() + operation = self.operation_factory.build_delete_by_transactions(transaction_uuids) + await self.submit_query(operation) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py deleted file mode 100644 index 88246d393..000000000 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/pg/abc.py +++ /dev/null @@ -1,51 +0,0 @@ -from __future__ import ( - annotations, -) - -from typing import ( - Type, - TypeVar, -) - -from minos.common import ( - Config, - DatabaseMixin, -) - - -class PostgreSqlSnapshotSetup(DatabaseMixin): - """Minos Snapshot Setup Class""" - - @classmethod - def _from_config(cls: Type[T], config: Config, **kwargs) -> T: - return cls(database_key=None, **kwargs) - - async def _setup(self) -> None: - await self.submit_query('CREATE EXTENSION IF NOT EXISTS "uuid-ossp";', lock="uuid-ossp") - await self.submit_query(_CREATE_TABLE_QUERY, lock="snapshot") - await self.submit_query(_CREATE_OFFSET_TABLE_QUERY, lock="snapshot_aux_offset") - - -T = TypeVar("T", bound=PostgreSqlSnapshotSetup) - -_CREATE_TABLE_QUERY = """ -CREATE TABLE IF NOT EXISTS snapshot ( - uuid UUID NOT NULL, - name TEXT NOT NULL, - version INT NOT NULL, - schema BYTEA, - data JSONB, - created_at TIMESTAMPTZ NOT NULL, - updated_at TIMESTAMPTZ NOT NULL, - transaction_uuid UUID NOT NULL DEFAULT uuid_nil(), - PRIMARY KEY (uuid, transaction_uuid) -); -""".strip() - -_CREATE_OFFSET_TABLE_QUERY = """ -CREATE TABLE IF NOT EXISTS snapshot_aux_offset ( - id bool PRIMARY KEY DEFAULT TRUE, - value BIGINT NOT NULL, - CONSTRAINT id_uni CHECK (id) -); -""".strip() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py index 467cdd3f3..13f222810 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py @@ -22,10 +22,6 @@ Ordering, PostgreSqlSnapshotQueryBuilder, ) -from minos.aggregate.snapshots.pg.queries import ( - _SELECT_ENTRIES_QUERY, - _SELECT_TRANSACTION_CHUNK, -) from minos.common import ( NULL_UUID, AiopgDatabaseClient, @@ -46,8 +42,8 @@ def setUp(self) -> None: "name": self.classname, "transaction_uuid_1": NULL_UUID, } - self.base_select = _SELECT_ENTRIES_QUERY.format( - from_parts=_SELECT_TRANSACTION_CHUNK.format( + self.base_select = PostgreSqlSnapshotQueryBuilder._SELECT_ENTRIES_QUERY.format( + from_parts=PostgreSqlSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( index=Literal(1), transaction_uuid=Placeholder("transaction_uuid_1") ) ) @@ -100,13 +96,13 @@ async def test_build_with_transactions(self): expected_query = SQL(" WHERE ").join( [ - _SELECT_ENTRIES_QUERY.format( + PostgreSqlSnapshotQueryBuilder._SELECT_ENTRIES_QUERY.format( from_parts=SQL(" UNION ALL ").join( [ - _SELECT_TRANSACTION_CHUNK.format( + PostgreSqlSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( index=Literal(1), transaction_uuid=Placeholder("transaction_uuid_1") ), - _SELECT_TRANSACTION_CHUNK.format( + PostgreSqlSnapshotQueryBuilder. _SELECT_TRANSACTION_CHUNK.format( index=Literal(2), transaction_uuid=Placeholder("transaction_uuid_2") ), ] From 0001cf947cf737780a387d24e686074f1138ae5b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 16:03:49 +0200 Subject: [PATCH 148/324] ISSUE #371 * Integrate `AiopgSnapshotRepositoryOperationFactory` and `PostgreSqlSnapshotQueryBuilder`. --- .../events/repositories/database/impl.py | 2 +- .../minos/aggregate/snapshots/__init__.py | 12 +-- .../aggregate/snapshots/database/__init__.py | 4 +- .../minos/aggregate/snapshots/database/abc.py | 6 +- .../snapshots/database/factories/__init__.py | 3 +- .../snapshots/database/factories/abc.py | 34 +++++++-- .../database/factories/aiopg/__init__.py | 6 ++ .../factories/{aiopg.py => aiopg/impl.py} | 73 ++++++++++++------- .../database/{ => factories/aiopg}/queries.py | 5 +- .../aggregate/snapshots/database/readers.py | 10 +-- .../test_root/test_with_postgresql.py | 4 +- .../test_events/test_repositories/test_pg.py | 14 ++-- .../test_snapshots/test_pg/test_queries.py | 2 +- 13 files changed, 112 insertions(+), 63 deletions(-) create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/{aiopg.py => aiopg/impl.py} (85%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/{ => factories/aiopg}/queries.py (99%) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index 83f7f3457..d4281a75d 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -84,7 +84,7 @@ async def _build_submit_operation(self, entry: EventEntry) -> DatabaseOperation: async def _select(self, **kwargs) -> AsyncIterator[EventEntry]: operation = self.operation_factory.build_select_rows(**kwargs) - async for row in self.submit_query_and_iter(operation, kwargs, **kwargs): + async for row in self.submit_query_and_iter(operation, **kwargs): yield EventEntry(*row) @property diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py index b8b8f366a..02754915a 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py @@ -1,12 +1,6 @@ from .abc import ( SnapshotRepository, ) -from .entries import ( - SnapshotEntry, -) -from .memory import ( - InMemorySnapshotRepository, -) from .database import ( PostgreSqlSnapshotQueryBuilder, PostgreSqlSnapshotReader, @@ -14,6 +8,12 @@ PostgreSqlSnapshotSetup, PostgreSqlSnapshotWriter, ) +from .entries import ( + SnapshotEntry, +) +from .memory import ( + InMemorySnapshotRepository, +) from .services import ( SnapshotService, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py index 4b4072b8c..2fb320113 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py @@ -4,8 +4,10 @@ from .api import ( PostgreSqlSnapshotRepository, ) -from .queries import ( +from .factories import ( + AiopgSnapshotRepositoryOperationFactory, PostgreSqlSnapshotQueryBuilder, + SnapshotRepositoryOperationFactory, ) from .readers import ( PostgreSqlSnapshotReader, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py index afdc0e099..c6ed5c5d8 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py @@ -3,17 +3,19 @@ ) from typing import ( + Optional, Type, - TypeVar, Optional, + TypeVar, ) from minos.common import ( Config, DatabaseMixin, ) + from .factories import ( + AiopgSnapshotRepositoryOperationFactory, SnapshotRepositoryOperationFactory, - AiopgSnapshotRepositoryOperationFactory ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py index c50410738..96f75dc18 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py @@ -3,4 +3,5 @@ ) from .aiopg import ( AiopgSnapshotRepositoryOperationFactory, -) \ No newline at end of file + PostgreSqlSnapshotQueryBuilder, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py index 16c02fd8c..f2b482540 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py @@ -7,6 +7,7 @@ ) from typing import ( Any, + Optional, ) from uuid import ( UUID, @@ -17,6 +18,11 @@ datetime, ) +from ....queries import ( + _Condition, + _Ordering, +) + class SnapshotRepositoryOperationFactory(ABC): """TODO""" @@ -29,14 +35,6 @@ def build_create_table(self) -> DatabaseOperation: def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: """TODO""" - @abstractmethod - def build_store_offset(self, value: int) -> DatabaseOperation: - """TODO""" - - @abstractmethod - def build_get_offset(self) -> DatabaseOperation: - """TODO""" - @abstractmethod def build_insert( self, @@ -50,3 +48,23 @@ def build_insert( transaction_uuid: UUID, ) -> DatabaseOperation: """TODO""" + + @abstractmethod + def build_query( + self, + name: str, + condition: _Condition, + ordering: Optional[_Ordering], + limit: Optional[int], + transaction_uuids: tuple[UUID, ...], + exclude_deleted: bool, + ) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_store_offset(self, value: int) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_get_offset(self) -> DatabaseOperation: + """TODO""" diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py new file mode 100644 index 000000000..738cd8ed6 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py @@ -0,0 +1,6 @@ +from .impl import ( + AiopgSnapshotRepositoryOperationFactory, +) +from .queries import ( + PostgreSqlSnapshotQueryBuilder, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py similarity index 85% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py index e56f3c869..f2bdcbe99 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py @@ -6,6 +6,7 @@ ) from typing import ( Any, + Optional, ) from uuid import ( UUID, @@ -17,9 +18,16 @@ DatabaseOperation, ) -from .abc import ( +from .....queries import ( + _Condition, + _Ordering, +) +from ..abc import ( SnapshotRepositoryOperationFactory, ) +from .queries import ( + PostgreSqlSnapshotQueryBuilder, +) # noinspection SqlNoDataSourceInspection,SqlResolve @@ -66,36 +74,13 @@ def build_create_table(self) -> DatabaseOperation: def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: """TODO""" return AiopgDatabaseOperation( - """ + """ DELETE FROM snapshot WHERE transaction_uuid IN %(transaction_uuids)s; """, {"transaction_uuids": tuple(transaction_uuids)}, ) - def build_store_offset(self, value: int) -> DatabaseOperation: - """TODO""" - return AiopgDatabaseOperation( - """ - INSERT INTO snapshot_aux_offset (id, value) - VALUES (TRUE, %(value)s) - ON CONFLICT (id) - DO UPDATE SET value = GREATEST(%(value)s, (SELECT value FROM snapshot_aux_offset WHERE id = TRUE)); - """.strip(), - {"value": value}, - lock="insert_snapshot_aux_offset" - ) - - def build_get_offset(self) -> DatabaseOperation: - """TODO""" - return AiopgDatabaseOperation( - """ - SELECT value - FROM snapshot_aux_offset - WHERE id = TRUE; - """ - ) - def build_insert( self, uuid: UUID, @@ -138,3 +123,41 @@ def build_insert( "transaction_uuid": transaction_uuid, }, ) + + def build_query( + self, + name: str, + condition: _Condition, + ordering: Optional[_Ordering], + limit: Optional[int], + transaction_uuids: tuple[UUID, ...], + exclude_deleted: bool, + ) -> DatabaseOperation: + """TODO""" + builder = PostgreSqlSnapshotQueryBuilder(name, condition, ordering, limit, transaction_uuids, exclude_deleted) + query, parameters = builder.build() + + return AiopgDatabaseOperation(query, parameters) + + def build_store_offset(self, value: int) -> DatabaseOperation: + """TODO""" + return AiopgDatabaseOperation( + """ + INSERT INTO snapshot_aux_offset (id, value) + VALUES (TRUE, %(value)s) + ON CONFLICT (id) + DO UPDATE SET value = GREATEST(%(value)s, (SELECT value FROM snapshot_aux_offset WHERE id = TRUE)); + """.strip(), + {"value": value}, + lock="insert_snapshot_aux_offset", + ) + + def build_get_offset(self) -> DatabaseOperation: + """TODO""" + return AiopgDatabaseOperation( + """ + SELECT value + FROM snapshot_aux_offset + WHERE id = TRUE; + """ + ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/queries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py similarity index 99% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/queries.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py index 5eefc113d..562b793a4 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/queries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py @@ -27,10 +27,10 @@ AvroDataEncoder, ) -from ...contextvars import ( +from .....contextvars import ( IS_REPOSITORY_SERIALIZATION_CONTEXT_VAR, ) -from ...queries import ( +from .....queries import ( _FALSE_CONDITION, _AndCondition, _ComposedCondition, @@ -222,7 +222,6 @@ def generate_random_str() -> str: """ return str(uuid4()) - _COMPOSED_MAPPER = {_AndCondition: SQL(" AND "), _OrCondition: SQL(" OR ")} _SIMPLE_MAPPER = { diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py index 290cfa111..5ea6999cd 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py @@ -33,9 +33,6 @@ from .abc import ( PostgreSqlSnapshotSetup, ) -from .queries import ( - PostgreSqlSnapshotQueryBuilder, -) if TYPE_CHECKING: from ...entities import ( @@ -125,10 +122,11 @@ async def find_entries( else: transaction_uuids = await transaction.uuids - qb = PostgreSqlSnapshotQueryBuilder(name, condition, ordering, limit, transaction_uuids, exclude_deleted) - query, parameters = qb.build() + operation = self.operation_factory.build_query( + name, condition, ordering, limit, transaction_uuids, exclude_deleted + ) - async_iterable = self.submit_query_and_iter(query, parameters) + async_iterable = self.submit_query_and_iter(operation) if streaming_mode: async for row in async_iterable: yield SnapshotEntry(*row) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py index 0ed5f3b97..72956dbac 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py @@ -4,7 +4,7 @@ AlreadyDeletedException, DatabaseTransactionRepository, EntitySet, - PostgreSqlEventRepository, + DatabaseEventRepository, PostgreSqlSnapshotRepository, ValueObjectSet, ) @@ -26,7 +26,7 @@ def setUp(self): self.transaction_repository = DatabaseTransactionRepository.from_config(self.config) - self.event_repository = PostgreSqlEventRepository.from_config( + self.event_repository = DatabaseEventRepository.from_config( self.config, transaction_repository=self.transaction_repository ) self.snapshot_repository = PostgreSqlSnapshotRepository.from_config( diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index a215d5c73..bbc5ded53 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -2,7 +2,7 @@ from minos.aggregate import ( EventRepository, - PostgreSqlEventRepository, + DatabaseEventRepository, ) from minos.common import ( AiopgDatabaseClient, @@ -18,22 +18,22 @@ # noinspection SqlNoDataSourceInspection -class TestPostgreSqlEventRepositorySubmit(EventRepositorySubmitTestCase, PostgresAsyncTestCase): +class TestDatabaseEventRepositorySubmit(EventRepositorySubmitTestCase, PostgresAsyncTestCase): __test__ = True @staticmethod def build_event_repository() -> EventRepository: """Fort testing purposes.""" - return PostgreSqlEventRepository() + return DatabaseEventRepository() def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) - repository = PostgreSqlEventRepository(pool) - self.assertIsInstance(repository, PostgreSqlEventRepository) + repository = DatabaseEventRepository(pool) + self.assertIsInstance(repository, DatabaseEventRepository) self.assertIsInstance(repository.pool, DatabaseClientPool) def test_from_config(self): - repository = PostgreSqlEventRepository.from_config(self.config) + repository = DatabaseEventRepository.from_config(self.config) self.assertIsInstance(repository.pool, DatabaseClientPool) async def test_setup(self): @@ -51,7 +51,7 @@ class TestPostgreSqlRepositorySelect(EventRepositorySelectTestCase, PostgresAsyn @staticmethod def build_event_repository() -> EventRepository: """Fort testing purposes.""" - return PostgreSqlEventRepository() + return DatabaseEventRepository() if __name__ == "__main__": diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py index 13f222810..cef0915f1 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py @@ -102,7 +102,7 @@ async def test_build_with_transactions(self): PostgreSqlSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( index=Literal(1), transaction_uuid=Placeholder("transaction_uuid_1") ), - PostgreSqlSnapshotQueryBuilder. _SELECT_TRANSACTION_CHUNK.format( + PostgreSqlSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( index=Literal(2), transaction_uuid=Placeholder("transaction_uuid_2") ), ] From 90499e34407aadd604c22c62298e164ea2152011 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 16:24:46 +0200 Subject: [PATCH 149/324] ISSUE #371 * Rename classes. --- .../minos/aggregate/__init__.py | 6 +- .../events/repositories/database/impl.py | 1 - .../minos/aggregate/snapshots/__init__.py | 6 +- .../aggregate/snapshots/database/__init__.py | 10 +- .../minos/aggregate/snapshots/database/abc.py | 24 +++- .../minos/aggregate/snapshots/database/api.py | 30 +++-- .../snapshots/database/factories/__init__.py | 6 +- .../snapshots/database/factories/abc.py | 2 +- .../database/factories/aiopg/__init__.py | 4 +- .../database/factories/aiopg/impl.py | 8 +- .../database/factories/aiopg/queries.py | 2 +- .../aggregate/snapshots/database/readers.py | 16 ++- .../aggregate/snapshots/database/writers.py | 20 ++- .../repositories/database/impl.py | 1 - .../test_root/test_with_postgresql.py | 6 +- .../test_events/test_repositories/test_pg.py | 2 +- .../test_snapshots/test_pg/test_abc.py | 6 +- .../test_snapshots/test_pg/test_api.py | 12 +- .../test_snapshots/test_pg/test_queries.py | 116 +++++++++--------- .../test_snapshots/test_pg/test_readers.py | 14 +-- .../test_snapshots/test_pg/test_writers.py | 16 +-- 21 files changed, 180 insertions(+), 128 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index 987e9aad8..be8338b1a 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -60,8 +60,12 @@ Ordering, ) from .snapshots import ( + AiopgSnapshotQueryBuilder, + DatabaseSnapshotReader, + DatabaseSnapshotRepository, + DatabaseSnapshotSetup, + DatabaseSnapshotWriter, InMemorySnapshotRepository, - PostgreSqlSnapshotQueryBuilder, PostgreSqlSnapshotReader, PostgreSqlSnapshotRepository, PostgreSqlSnapshotSetup, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index d4281a75d..e113cf48d 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -101,5 +101,4 @@ def __init__(self, *args, **kwargs): f"{PostgreSqlEventRepository!r} has been deprecated. Use {DatabaseEventRepository} instead.", DeprecationWarning, ) - kwargs["operation_factory"] = AiopgEventRepositoryOperationFactory() super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py index 02754915a..de3dcca47 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py @@ -2,7 +2,11 @@ SnapshotRepository, ) from .database import ( - PostgreSqlSnapshotQueryBuilder, + AiopgSnapshotQueryBuilder, + DatabaseSnapshotReader, + DatabaseSnapshotRepository, + DatabaseSnapshotSetup, + DatabaseSnapshotWriter, PostgreSqlSnapshotReader, PostgreSqlSnapshotRepository, PostgreSqlSnapshotSetup, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py index 2fb320113..937e1da87 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py @@ -1,17 +1,21 @@ from .abc import ( + DatabaseSnapshotSetup, PostgreSqlSnapshotSetup, ) from .api import ( + DatabaseSnapshotRepository, PostgreSqlSnapshotRepository, ) from .factories import ( - AiopgSnapshotRepositoryOperationFactory, - PostgreSqlSnapshotQueryBuilder, - SnapshotRepositoryOperationFactory, + AiopgSnapshotDatabaseOperationFactory, + AiopgSnapshotQueryBuilder, + SnapshotDatabaseOperationFactory, ) from .readers import ( + DatabaseSnapshotReader, PostgreSqlSnapshotReader, ) from .writers import ( + DatabaseSnapshotWriter, PostgreSqlSnapshotWriter, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py index c6ed5c5d8..ec5972fa2 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py @@ -2,6 +2,7 @@ annotations, ) +import warnings from typing import ( Optional, Type, @@ -14,18 +15,18 @@ ) from .factories import ( - AiopgSnapshotRepositoryOperationFactory, - SnapshotRepositoryOperationFactory, + AiopgSnapshotDatabaseOperationFactory, + SnapshotDatabaseOperationFactory, ) -class PostgreSqlSnapshotSetup(DatabaseMixin): +class DatabaseSnapshotSetup(DatabaseMixin): """Minos Snapshot Setup Class""" - def __init__(self, *args, operation_factory: Optional[SnapshotRepositoryOperationFactory] = None, **kwargs): + def __init__(self, *args, operation_factory: Optional[SnapshotDatabaseOperationFactory] = None, **kwargs): super().__init__(*args, **kwargs) if operation_factory is None: - operation_factory = AiopgSnapshotRepositoryOperationFactory() + operation_factory = AiopgSnapshotDatabaseOperationFactory() self.operation_factory = operation_factory @@ -38,4 +39,15 @@ async def _setup(self) -> None: await self.submit_query(operation) -T = TypeVar("T", bound=PostgreSqlSnapshotSetup) +T = TypeVar("T", bound=DatabaseSnapshotSetup) + + +class PostgreSqlSnapshotSetup(DatabaseSnapshotSetup): + """TODO""" + + def __init__(self, *args, **kwargs): + warnings.warn( + f"{PostgreSqlSnapshotSetup!r} has been deprecated. Use {DatabaseSnapshotSetup} instead.", + DeprecationWarning, + ) + super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py index 2ed9c1c73..cdb71eb1e 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py @@ -2,6 +2,7 @@ annotations, ) +import warnings from typing import ( TYPE_CHECKING, AsyncIterator, @@ -16,10 +17,10 @@ SnapshotRepository, ) from .readers import ( - PostgreSqlSnapshotReader, + DatabaseSnapshotReader, ) from .writers import ( - PostgreSqlSnapshotWriter, + DatabaseSnapshotWriter, ) if TYPE_CHECKING: @@ -28,28 +29,28 @@ ) -class PostgreSqlSnapshotRepository(SnapshotRepository): +class DatabaseSnapshotRepository(SnapshotRepository): """PostgreSQL Snapshot class. The snapshot provides a direct accessor to the ``RootEntity`` instances stored as events by the event repository class. """ - reader: PostgreSqlSnapshotReader - writer: PostgreSqlSnapshotWriter + reader: DatabaseSnapshotReader + writer: DatabaseSnapshotWriter - def __init__(self, *args, reader: PostgreSqlSnapshotReader, writer: PostgreSqlSnapshotWriter, **kwargs): + def __init__(self, *args, reader: DatabaseSnapshotReader, writer: DatabaseSnapshotWriter, **kwargs): super().__init__(*args, **kwargs) self.reader = reader self.writer = writer @classmethod - def _from_config(cls, config: Config, **kwargs) -> PostgreSqlSnapshotRepository: + def _from_config(cls, config: Config, **kwargs) -> DatabaseSnapshotRepository: if "reader" not in kwargs: - kwargs["reader"] = PostgreSqlSnapshotReader.from_config(config, **kwargs) + kwargs["reader"] = DatabaseSnapshotReader.from_config(config, **kwargs) if "writer" not in kwargs: - kwargs["writer"] = PostgreSqlSnapshotWriter.from_config(config, **kwargs) + kwargs["writer"] = DatabaseSnapshotWriter.from_config(config, **kwargs) return cls(database_key=None, **kwargs) @@ -71,3 +72,14 @@ def _find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: def _synchronize(self, *args, **kwargs) -> Awaitable[None]: return self.writer.dispatch(**kwargs) + + +class PostgreSqlSnapshotRepository(DatabaseSnapshotRepository): + """TODO""" + + def __init__(self, *args, **kwargs): + warnings.warn( + f"{PostgreSqlSnapshotRepository!r} has been deprecated. Use {DatabaseSnapshotRepository} instead.", + DeprecationWarning, + ) + super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py index 96f75dc18..6cc46463a 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py @@ -1,7 +1,7 @@ from .abc import ( - SnapshotRepositoryOperationFactory, + SnapshotDatabaseOperationFactory, ) from .aiopg import ( - AiopgSnapshotRepositoryOperationFactory, - PostgreSqlSnapshotQueryBuilder, + AiopgSnapshotDatabaseOperationFactory, + AiopgSnapshotQueryBuilder, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py index f2b482540..57bdc21a3 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py @@ -24,7 +24,7 @@ ) -class SnapshotRepositoryOperationFactory(ABC): +class SnapshotDatabaseOperationFactory(ABC): """TODO""" @abstractmethod diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py index 738cd8ed6..766b80901 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py @@ -1,6 +1,6 @@ from .impl import ( - AiopgSnapshotRepositoryOperationFactory, + AiopgSnapshotDatabaseOperationFactory, ) from .queries import ( - PostgreSqlSnapshotQueryBuilder, + AiopgSnapshotQueryBuilder, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py index f2bdcbe99..4c883c581 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py @@ -23,15 +23,15 @@ _Ordering, ) from ..abc import ( - SnapshotRepositoryOperationFactory, + SnapshotDatabaseOperationFactory, ) from .queries import ( - PostgreSqlSnapshotQueryBuilder, + AiopgSnapshotQueryBuilder, ) # noinspection SqlNoDataSourceInspection,SqlResolve -class AiopgSnapshotRepositoryOperationFactory(SnapshotRepositoryOperationFactory): +class AiopgSnapshotDatabaseOperationFactory(SnapshotDatabaseOperationFactory): """TODO""" def build_create_table(self) -> DatabaseOperation: @@ -134,7 +134,7 @@ def build_query( exclude_deleted: bool, ) -> DatabaseOperation: """TODO""" - builder = PostgreSqlSnapshotQueryBuilder(name, condition, ordering, limit, transaction_uuids, exclude_deleted) + builder = AiopgSnapshotQueryBuilder(name, condition, ordering, limit, transaction_uuids, exclude_deleted) query, parameters = builder.build() return AiopgDatabaseOperation(query, parameters) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py index 562b793a4..07bd21ea1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py @@ -53,7 +53,7 @@ # noinspection SqlResolve,SqlNoDataSourceInspection -class PostgreSqlSnapshotQueryBuilder: +class AiopgSnapshotQueryBuilder: """PostgreSQL Snapshot Query Builder class. This class build postgres-compatible database queries over fields based on a condition, ordering, etc. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py index 5ea6999cd..85f49892f 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py @@ -3,6 +3,7 @@ ) import logging +import warnings from typing import ( TYPE_CHECKING, AsyncIterator, @@ -31,7 +32,7 @@ SnapshotEntry, ) from .abc import ( - PostgreSqlSnapshotSetup, + DatabaseSnapshotSetup, ) if TYPE_CHECKING: @@ -42,7 +43,7 @@ logger = logging.getLogger(__name__) -class PostgreSqlSnapshotReader(PostgreSqlSnapshotSetup): +class DatabaseSnapshotReader(DatabaseSnapshotSetup): """PostgreSQL Snapshot class. The snapshot provides a direct accessor to the ``RootEntity`` instances stored as events by the event repository @@ -133,3 +134,14 @@ async def find_entries( else: for row in [row async for row in async_iterable]: yield SnapshotEntry(*row) + + +class PostgreSqlSnapshotReader(DatabaseSnapshotReader): + """TODO""" + + def __init__(self, *args, **kwargs): + warnings.warn( + f"{PostgreSqlSnapshotReader!r} has been deprecated. Use {DatabaseSnapshotReader} instead.", + DeprecationWarning, + ) + super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py index e0a7d94cf..9333cab95 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py @@ -2,6 +2,7 @@ annotations, ) +import warnings from typing import ( TYPE_CHECKING, Type, @@ -34,10 +35,10 @@ SnapshotEntry, ) from .abc import ( - PostgreSqlSnapshotSetup, + DatabaseSnapshotSetup, ) from .readers import ( - PostgreSqlSnapshotReader, + DatabaseSnapshotReader, ) if TYPE_CHECKING: @@ -46,14 +47,14 @@ ) -class PostgreSqlSnapshotWriter(PostgreSqlSnapshotSetup): +class DatabaseSnapshotWriter(DatabaseSnapshotSetup): """Minos Snapshot Dispatcher class.""" @Inject() def __init__( self, *args, - reader: PostgreSqlSnapshotReader, + reader: DatabaseSnapshotReader, event_repository: EventRepository, transaction_repository: TransactionRepository, **kwargs, @@ -182,3 +183,14 @@ async def _clean_transactions(self, offset: int, **kwargs) -> None: if len(transaction_uuids): operation = self.operation_factory.build_delete_by_transactions(transaction_uuids) await self.submit_query(operation) + + +class PostgreSqlSnapshotWriter(DatabaseSnapshotWriter): + """TODO""" + + def __init__(self, *args, **kwargs): + warnings.warn( + f"{PostgreSqlSnapshotWriter!r} has been deprecated. Use {DatabaseSnapshotWriter} instead.", + DeprecationWarning, + ) + super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index 721ada70c..cb390cef0 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -77,5 +77,4 @@ def __init__(self, *args, **kwargs): f"{PostgreSqlTransactionRepository!r} has been deprecated. Use {DatabaseTransactionRepository} instead.", DeprecationWarning, ) - kwargs["operation_factory"] = AiopgTransactionRepositoryOperationFactory() super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py index 72956dbac..75e22474d 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py @@ -2,10 +2,10 @@ from minos.aggregate import ( AlreadyDeletedException, + DatabaseEventRepository, + DatabaseSnapshotRepository, DatabaseTransactionRepository, EntitySet, - DatabaseEventRepository, - PostgreSqlSnapshotRepository, ValueObjectSet, ) from minos.common.testing import ( @@ -29,7 +29,7 @@ def setUp(self): self.event_repository = DatabaseEventRepository.from_config( self.config, transaction_repository=self.transaction_repository ) - self.snapshot_repository = PostgreSqlSnapshotRepository.from_config( + self.snapshot_repository = DatabaseSnapshotRepository.from_config( self.config, event_repository=self.event_repository, transaction_repository=self.transaction_repository ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index bbc5ded53..0b1a24113 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -1,8 +1,8 @@ import unittest from minos.aggregate import ( - EventRepository, DatabaseEventRepository, + EventRepository, ) from minos.common import ( AiopgDatabaseClient, diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py index 207afc7c1..9009a6ce3 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py @@ -1,7 +1,7 @@ import unittest from minos.aggregate import ( - PostgreSqlSnapshotSetup, + DatabaseSnapshotSetup, ) from minos.common import ( AiopgDatabaseClient, @@ -17,7 +17,7 @@ # noinspection SqlNoDataSourceInspection class TestPostgreSqlSnapshotSetup(AggregateTestCase, PostgresAsyncTestCase): async def test_setup_snapshot_table(self): - async with PostgreSqlSnapshotSetup.from_config(self.config): + async with DatabaseSnapshotSetup.from_config(self.config): async with AiopgDatabaseClient(**self.config.get_default_database()) as client: await client.execute( "SELECT EXISTS (SELECT FROM pg_tables WHERE schemaname = 'public' AND tablename = 'snapshot');" @@ -26,7 +26,7 @@ async def test_setup_snapshot_table(self): self.assertEqual(True, observed) async def test_setup_snapshot_aux_offset_table(self): - async with PostgreSqlSnapshotSetup.from_config(self.config): + async with DatabaseSnapshotSetup.from_config(self.config): async with AiopgDatabaseClient(**self.config.get_default_database()) as client: await client.execute( "SELECT EXISTS (SELECT FROM pg_tables WHERE " diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py index 0fb1c6245..7f552c652 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py @@ -10,10 +10,10 @@ from minos.aggregate import ( Condition, + DatabaseSnapshotReader, + DatabaseSnapshotRepository, + DatabaseSnapshotWriter, Ordering, - PostgreSqlSnapshotReader, - PostgreSqlSnapshotRepository, - PostgreSqlSnapshotWriter, TransactionEntry, ) from minos.common.testing import ( @@ -29,7 +29,7 @@ class TestPostgreSqlSnapshotRepository(AggregateTestCase, PostgresAsyncTestCase) def setUp(self) -> None: super().setUp() - self.snapshot_repository = PostgreSqlSnapshotRepository.from_config(self.config) + self.snapshot_repository = DatabaseSnapshotRepository.from_config(self.config) self.dispatch_mock = AsyncMock() self.get_mock = AsyncMock(return_value=1) @@ -49,8 +49,8 @@ async def asyncTearDown(self): await super().asyncTearDown() def test_from_config(self): - self.assertIsInstance(self.snapshot_repository.reader, PostgreSqlSnapshotReader) - self.assertIsInstance(self.snapshot_repository.writer, PostgreSqlSnapshotWriter) + self.assertIsInstance(self.snapshot_repository.reader, DatabaseSnapshotReader) + self.assertIsInstance(self.snapshot_repository.writer, DatabaseSnapshotWriter) async def test_get(self): transaction = TransactionEntry() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py index cef0915f1..0d11ad4d6 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py @@ -18,9 +18,9 @@ from minos.aggregate import ( IS_REPOSITORY_SERIALIZATION_CONTEXT_VAR, + AiopgSnapshotQueryBuilder, Condition, Ordering, - PostgreSqlSnapshotQueryBuilder, ) from minos.common import ( NULL_UUID, @@ -42,14 +42,14 @@ def setUp(self) -> None: "name": self.classname, "transaction_uuid_1": NULL_UUID, } - self.base_select = PostgreSqlSnapshotQueryBuilder._SELECT_ENTRIES_QUERY.format( - from_parts=PostgreSqlSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( + self.base_select = AiopgSnapshotQueryBuilder._SELECT_ENTRIES_QUERY.format( + from_parts=AiopgSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( index=Literal(1), transaction_uuid=Placeholder("transaction_uuid_1") ) ) def test_constructor(self): - qb = PostgreSqlSnapshotQueryBuilder(self.classname, Condition.TRUE) + qb = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE) self.assertEqual(self.classname, qb.name) self.assertEqual(Condition.TRUE, qb.condition) self.assertEqual(None, qb.ordering) @@ -58,7 +58,7 @@ def test_constructor(self): def test_constructor_full(self): transaction_uuids = (NULL_UUID, uuid4()) - qb = PostgreSqlSnapshotQueryBuilder( + qb = AiopgSnapshotQueryBuilder( self.classname, Condition.TRUE, Ordering.ASC("name"), 10, transaction_uuids, True ) self.assertEqual(self.classname, qb.name) @@ -69,7 +69,7 @@ def test_constructor_full(self): self.assertTrue(qb.exclude_deleted) def test_build_submitting_context_var(self): - builder = PostgreSqlSnapshotQueryBuilder(self.classname, Condition.TRUE) + builder = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE) def _fn(): self.assertEqual(True, IS_REPOSITORY_SERIALIZATION_CONTEXT_VAR.get()) @@ -86,23 +86,23 @@ def _fn(): def test_build_raises(self): with self.assertRaises(ValueError): # noinspection PyTypeChecker - PostgreSqlSnapshotQueryBuilder(self.classname, True).build() + AiopgSnapshotQueryBuilder(self.classname, True).build() async def test_build_with_transactions(self): transaction_uuids = (NULL_UUID, uuid4()) - observed = PostgreSqlSnapshotQueryBuilder( + observed = AiopgSnapshotQueryBuilder( self.classname, Condition.TRUE, transaction_uuids=transaction_uuids ).build() expected_query = SQL(" WHERE ").join( [ - PostgreSqlSnapshotQueryBuilder._SELECT_ENTRIES_QUERY.format( + AiopgSnapshotQueryBuilder._SELECT_ENTRIES_QUERY.format( from_parts=SQL(" UNION ALL ").join( [ - PostgreSqlSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( + AiopgSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( index=Literal(1), transaction_uuid=Placeholder("transaction_uuid_1") ), - PostgreSqlSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( + AiopgSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( index=Literal(2), transaction_uuid=Placeholder("transaction_uuid_2") ), ] @@ -118,7 +118,7 @@ async def test_build_with_transactions(self): async def test_build_true(self): condition = Condition.TRUE - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("TRUE")]) expected_parameters = self.base_parameters @@ -128,7 +128,7 @@ async def test_build_true(self): async def test_build_false(self): condition = Condition.FALSE - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("FALSE")]) expected_parameters = self.base_parameters self.assertEqual(await self._flatten_query(expected_query), await self._flatten_query(observed[0])) @@ -137,8 +137,8 @@ async def test_build_false(self): async def test_build_fixed_uuid(self): uuid = uuid4() condition = Condition.EQUAL("uuid", uuid) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('("uuid" = %(hello)s)')]) expected_parameters = {"hello": str(uuid)} | self.base_parameters @@ -148,8 +148,8 @@ async def test_build_fixed_uuid(self): async def test_build_fixed_version(self): condition = Condition.EQUAL("version", 1) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('("version" = %(hello)s)')]) expected_parameters = {"hello": 1} | self.base_parameters @@ -159,8 +159,8 @@ async def test_build_fixed_version(self): async def test_build_fixed_created_at(self): condition = Condition.EQUAL("created_at", 1) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('("created_at" = %(hello)s)')]) expected_parameters = {"hello": 1} | self.base_parameters @@ -170,8 +170,8 @@ async def test_build_fixed_created_at(self): async def test_build_fixed_updated_at(self): condition = Condition.EQUAL("updated_at", 1) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('("updated_at" = %(hello)s)')]) expected_parameters = {"hello": 1} | self.base_parameters @@ -181,8 +181,8 @@ async def test_build_fixed_updated_at(self): async def test_build_fixed_with_like(self): condition = Condition.LIKE("uuid", "a%") - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('("uuid"::text LIKE %(hello)s)')]) expected_parameters = {"hello": "a%"} | self.base_parameters @@ -192,8 +192,8 @@ async def test_build_fixed_with_like(self): async def test_build_lower(self): condition = Condition.LOWER("age", 1) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' < %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -203,8 +203,8 @@ async def test_build_lower(self): async def test_build_lower_equal(self): condition = Condition.LOWER_EQUAL("age", 1) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' <= %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -214,8 +214,8 @@ async def test_build_lower_equal(self): async def test_build_greater(self): condition = Condition.GREATER("age", 1) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' > %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -225,8 +225,8 @@ async def test_build_greater(self): async def test_build_greater_equal(self): condition = Condition.GREATER_EQUAL("age", 1) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' >= %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -236,8 +236,8 @@ async def test_build_greater_equal(self): async def test_build_equal(self): condition = Condition.EQUAL("age", 1) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' = %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -247,8 +247,8 @@ async def test_build_equal(self): async def test_build_not_equal(self): condition = Condition.NOT_EQUAL("age", 1) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' <> %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -258,8 +258,8 @@ async def test_build_not_equal(self): async def test_build_in(self): condition = Condition.IN("age", [1, 2, 3]) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' IN %(hello)s::jsonb)")]) expected_parameters = {"hello": (1, 2, 3)} | self.base_parameters @@ -269,8 +269,8 @@ async def test_build_in(self): async def test_build_in_empty(self): condition = Condition.IN("age", []) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("FALSE")]) expected_parameters = self.base_parameters @@ -280,8 +280,8 @@ async def test_build_in_empty(self): async def test_build_like(self): condition = Condition.LIKE("name", "a%") - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>>'{name}' LIKE %(hello)s)")]) expected_parameters = {"hello": "a%"} | self.base_parameters @@ -291,8 +291,8 @@ async def test_build_like(self): async def test_build_not(self): condition = Condition.NOT(Condition.LOWER("age", 1)) - with patch("minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello"]): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(NOT (data#>'{age}' < %(hello)s::jsonb))")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -302,10 +302,8 @@ async def test_build_not(self): async def test_build_and(self): condition = Condition.AND(Condition.LOWER("age", 1), Condition.LOWER("level", 3)) - with patch( - "minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello", "goodbye"] - ): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello", "goodbye"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join( [self.base_select, SQL("((data#>'{age}' < %(hello)s::jsonb) AND (data#>'{level}' < %(goodbye)s::jsonb))")] @@ -317,10 +315,8 @@ async def test_build_and(self): async def test_build_or(self): condition = Condition.OR(Condition.LOWER("age", 1), Condition.LOWER("level", 3)) - with patch( - "minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["hello", "goodbye"] - ): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello", "goodbye"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join( [self.base_select, SQL("((data#>'{age}' < %(hello)s::jsonb) OR (data#>'{level}' < %(goodbye)s::jsonb))")] @@ -331,7 +327,7 @@ async def test_build_or(self): self.assertEqual(self._flatten_parameters(expected_parameters), self._flatten_parameters(observed[1])) async def test_build_exclude_deleted(self): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, Condition.TRUE, exclude_deleted=True).build() + observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, exclude_deleted=True).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("TRUE AND (data IS NOT NULL)")]) expected_parameters = self.base_parameters @@ -341,7 +337,7 @@ async def test_build_exclude_deleted(self): async def test_build_fixed_ordering_asc(self): ordering = Ordering.ASC("created_at") - observed = PostgreSqlSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() + observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('TRUE ORDER BY "created_at" ASC')]) @@ -352,7 +348,7 @@ async def test_build_fixed_ordering_asc(self): async def test_build_fixed_ordering_desc(self): ordering = Ordering.DESC("created_at") - observed = PostgreSqlSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() + observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('TRUE ORDER BY "created_at" DESC')]) expected_parameters = self.base_parameters @@ -362,7 +358,7 @@ async def test_build_fixed_ordering_desc(self): async def test_build_ordering_asc(self): ordering = Ordering.ASC("name") - observed = PostgreSqlSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() + observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("TRUE ORDER BY data#>'{name}' ASC")]) expected_parameters = self.base_parameters @@ -372,7 +368,7 @@ async def test_build_ordering_asc(self): async def test_build_ordering_desc(self): ordering = Ordering.DESC("name") - observed = PostgreSqlSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() + observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("TRUE ORDER BY data#>'{name}' DESC")]) @@ -382,7 +378,7 @@ async def test_build_ordering_desc(self): self.assertEqual(self._flatten_parameters(expected_parameters), self._flatten_parameters(observed[1])) async def test_build_limit(self): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, Condition.TRUE, limit=10).build() + observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, limit=10).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("TRUE LIMIT 10")]) @@ -399,10 +395,8 @@ async def test_build_complex(self): ordering = Ordering.DESC("updated_at") limit = 100 - with patch( - "minos.aggregate.PostgreSqlSnapshotQueryBuilder.generate_random_str", side_effect=["one", "two", "three"] - ): - observed = PostgreSqlSnapshotQueryBuilder(self.classname, condition, ordering, limit).build() + with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["one", "two", "three"]): + observed = AiopgSnapshotQueryBuilder(self.classname, condition, ordering, limit).build() expected_query = SQL(" WHERE ").join( [ diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py index bba2f9999..91a8ab2d8 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py @@ -9,14 +9,14 @@ from minos.aggregate import ( AlreadyDeletedException, Condition, + DatabaseSnapshotReader, + DatabaseSnapshotSetup, + DatabaseSnapshotWriter, EventEntry, FieldDiff, FieldDiffContainer, NotFoundException, Ordering, - PostgreSqlSnapshotReader, - PostgreSqlSnapshotSetup, - PostgreSqlSnapshotWriter, SnapshotEntry, TransactionEntry, TransactionStatus, @@ -45,7 +45,7 @@ def setUp(self) -> None: self.transaction_2 = uuid4() self.transaction_3 = uuid4() - self.reader = PostgreSqlSnapshotReader.from_config(self.config) + self.reader = DatabaseSnapshotReader.from_config(self.config) async def asyncSetUp(self): await super().asyncSetUp() @@ -89,14 +89,14 @@ async def _populate(self): await self.transaction_repository.submit( TransactionEntry(self.transaction_3, TransactionStatus.REJECTED, await self.event_repository.offset) ) - async with PostgreSqlSnapshotWriter.from_config(self.config, reader=self.reader) as writer: + async with DatabaseSnapshotWriter.from_config(self.config, reader=self.reader) as writer: await writer.dispatch() def test_type(self): - self.assertTrue(issubclass(PostgreSqlSnapshotReader, PostgreSqlSnapshotSetup)) + self.assertTrue(issubclass(DatabaseSnapshotReader, DatabaseSnapshotSetup)) def test_from_config(self): - reader = PostgreSqlSnapshotReader.from_config(self.config) + reader = DatabaseSnapshotReader.from_config(self.config) self.assertIsInstance(reader.pool, DatabaseClientPool) async def test_find_by_uuid(self): diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py index e393903b5..b73d5cb19 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py @@ -14,13 +14,13 @@ Action, AlreadyDeletedException, Condition, + DatabaseSnapshotReader, + DatabaseSnapshotSetup, + DatabaseSnapshotWriter, EventEntry, FieldDiff, FieldDiffContainer, Ordering, - PostgreSqlSnapshotReader, - PostgreSqlSnapshotSetup, - PostgreSqlSnapshotWriter, SnapshotEntry, TransactionEntry, TransactionStatus, @@ -50,8 +50,8 @@ def setUp(self) -> None: self.transaction_2 = uuid4() self.transaction_3 = uuid4() - self.reader = PostgreSqlSnapshotReader.from_config(self.config) - self.writer = PostgreSqlSnapshotWriter.from_config(self.config, reader=self.reader) + self.reader = DatabaseSnapshotReader.from_config(self.config) + self.writer = DatabaseSnapshotWriter.from_config(self.config, reader=self.reader) async def asyncSetUp(self): await super().asyncSetUp() @@ -99,17 +99,17 @@ async def _populate(self): ) def test_type(self): - self.assertTrue(issubclass(PostgreSqlSnapshotWriter, PostgreSqlSnapshotSetup)) + self.assertTrue(issubclass(DatabaseSnapshotWriter, DatabaseSnapshotSetup)) def test_from_config(self): self.assertIsInstance(self.writer.pool, DatabaseClientPool) def test_from_config_raises(self): with self.assertRaises(NotProvidedException): - PostgreSqlSnapshotWriter.from_config(self.config, reader=self.reader, event_repository=None) + DatabaseSnapshotWriter.from_config(self.config, reader=self.reader, event_repository=None) with self.assertRaises(NotProvidedException): - PostgreSqlSnapshotWriter.from_config(self.config, reader=self.reader, transaction_repository=None) + DatabaseSnapshotWriter.from_config(self.config, reader=self.reader, transaction_repository=None) async def test_dispatch(self): await self.writer.dispatch() From 7daa66744b53ed5a97272297c284a8eefed6a9e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 16:27:47 +0200 Subject: [PATCH 150/324] ISSUE #371 * Rename classes (2). --- .../minos/aggregate/__init__.py | 3 +- .../minos/aggregate/snapshots/__init__.py | 3 +- .../aggregate/snapshots/database/__init__.py | 3 +- .../snapshots/database/factories/__init__.py | 3 +- .../database/factories/aiopg/__init__.py | 3 +- .../database/factories/aiopg/impl.py | 6 +- .../database/factories/aiopg/queries.py | 15 ++- .../test_snapshots/test_pg/test_queries.py | 118 ++++++++++-------- 8 files changed, 91 insertions(+), 63 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index be8338b1a..45d36f5bb 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -60,12 +60,13 @@ Ordering, ) from .snapshots import ( - AiopgSnapshotQueryBuilder, + AiopgSnapshotQueryDatabaseOperationBuilder, DatabaseSnapshotReader, DatabaseSnapshotRepository, DatabaseSnapshotSetup, DatabaseSnapshotWriter, InMemorySnapshotRepository, + PostgreSqlSnapshotQueryBuilder, PostgreSqlSnapshotReader, PostgreSqlSnapshotRepository, PostgreSqlSnapshotSetup, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py index de3dcca47..5ace8eace 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py @@ -2,11 +2,12 @@ SnapshotRepository, ) from .database import ( - AiopgSnapshotQueryBuilder, + AiopgSnapshotQueryDatabaseOperationBuilder, DatabaseSnapshotReader, DatabaseSnapshotRepository, DatabaseSnapshotSetup, DatabaseSnapshotWriter, + PostgreSqlSnapshotQueryBuilder, PostgreSqlSnapshotReader, PostgreSqlSnapshotRepository, PostgreSqlSnapshotSetup, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py index 937e1da87..8e2aed6d8 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py @@ -8,7 +8,8 @@ ) from .factories import ( AiopgSnapshotDatabaseOperationFactory, - AiopgSnapshotQueryBuilder, + AiopgSnapshotQueryDatabaseOperationBuilder, + PostgreSqlSnapshotQueryBuilder, SnapshotDatabaseOperationFactory, ) from .readers import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py index 6cc46463a..beca8f414 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py @@ -3,5 +3,6 @@ ) from .aiopg import ( AiopgSnapshotDatabaseOperationFactory, - AiopgSnapshotQueryBuilder, + AiopgSnapshotQueryDatabaseOperationBuilder, + PostgreSqlSnapshotQueryBuilder, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py index 766b80901..48d06f584 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py @@ -2,5 +2,6 @@ AiopgSnapshotDatabaseOperationFactory, ) from .queries import ( - AiopgSnapshotQueryBuilder, + AiopgSnapshotQueryDatabaseOperationBuilder, + PostgreSqlSnapshotQueryBuilder, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py index 4c883c581..40e315999 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py @@ -26,7 +26,7 @@ SnapshotDatabaseOperationFactory, ) from .queries import ( - AiopgSnapshotQueryBuilder, + AiopgSnapshotQueryDatabaseOperationBuilder, ) @@ -134,7 +134,9 @@ def build_query( exclude_deleted: bool, ) -> DatabaseOperation: """TODO""" - builder = AiopgSnapshotQueryBuilder(name, condition, ordering, limit, transaction_uuids, exclude_deleted) + builder = AiopgSnapshotQueryDatabaseOperationBuilder( + name, condition, ordering, limit, transaction_uuids, exclude_deleted + ) query, parameters = builder.build() return AiopgDatabaseOperation(query, parameters) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py index 07bd21ea1..961e2694b 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py @@ -2,6 +2,7 @@ annotations, ) +import warnings from typing import ( Any, Optional, @@ -53,7 +54,7 @@ # noinspection SqlResolve,SqlNoDataSourceInspection -class AiopgSnapshotQueryBuilder: +class AiopgSnapshotQueryDatabaseOperationBuilder: """PostgreSQL Snapshot Query Builder class. This class build postgres-compatible database queries over fields based on a condition, ordering, etc. @@ -270,3 +271,15 @@ def generate_random_str() -> str: ) _EXCLUDE_DELETED_CONDITION = SQL("(data IS NOT NULL)") + + +class PostgreSqlSnapshotQueryBuilder(AiopgSnapshotQueryDatabaseOperationBuilder): + """TODO""" + + def __init__(self, *args, **kwargs): + warnings.warn( + f"{PostgreSqlSnapshotQueryBuilder!r} has been deprecated. " + f"Use {AiopgSnapshotQueryDatabaseOperationBuilder} instead.", + DeprecationWarning, + ) + super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py index 0d11ad4d6..649f324d3 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py @@ -18,7 +18,7 @@ from minos.aggregate import ( IS_REPOSITORY_SERIALIZATION_CONTEXT_VAR, - AiopgSnapshotQueryBuilder, + AiopgSnapshotQueryDatabaseOperationBuilder, Condition, Ordering, ) @@ -42,14 +42,14 @@ def setUp(self) -> None: "name": self.classname, "transaction_uuid_1": NULL_UUID, } - self.base_select = AiopgSnapshotQueryBuilder._SELECT_ENTRIES_QUERY.format( - from_parts=AiopgSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( + self.base_select = AiopgSnapshotQueryDatabaseOperationBuilder._SELECT_ENTRIES_QUERY.format( + from_parts=AiopgSnapshotQueryDatabaseOperationBuilder._SELECT_TRANSACTION_CHUNK.format( index=Literal(1), transaction_uuid=Placeholder("transaction_uuid_1") ) ) def test_constructor(self): - qb = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE) + qb = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, Condition.TRUE) self.assertEqual(self.classname, qb.name) self.assertEqual(Condition.TRUE, qb.condition) self.assertEqual(None, qb.ordering) @@ -58,7 +58,7 @@ def test_constructor(self): def test_constructor_full(self): transaction_uuids = (NULL_UUID, uuid4()) - qb = AiopgSnapshotQueryBuilder( + qb = AiopgSnapshotQueryDatabaseOperationBuilder( self.classname, Condition.TRUE, Ordering.ASC("name"), 10, transaction_uuids, True ) self.assertEqual(self.classname, qb.name) @@ -69,7 +69,7 @@ def test_constructor_full(self): self.assertTrue(qb.exclude_deleted) def test_build_submitting_context_var(self): - builder = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE) + builder = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, Condition.TRUE) def _fn(): self.assertEqual(True, IS_REPOSITORY_SERIALIZATION_CONTEXT_VAR.get()) @@ -86,23 +86,23 @@ def _fn(): def test_build_raises(self): with self.assertRaises(ValueError): # noinspection PyTypeChecker - AiopgSnapshotQueryBuilder(self.classname, True).build() + AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, True).build() async def test_build_with_transactions(self): transaction_uuids = (NULL_UUID, uuid4()) - observed = AiopgSnapshotQueryBuilder( + observed = AiopgSnapshotQueryDatabaseOperationBuilder( self.classname, Condition.TRUE, transaction_uuids=transaction_uuids ).build() expected_query = SQL(" WHERE ").join( [ - AiopgSnapshotQueryBuilder._SELECT_ENTRIES_QUERY.format( + AiopgSnapshotQueryDatabaseOperationBuilder._SELECT_ENTRIES_QUERY.format( from_parts=SQL(" UNION ALL ").join( [ - AiopgSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( + AiopgSnapshotQueryDatabaseOperationBuilder._SELECT_TRANSACTION_CHUNK.format( index=Literal(1), transaction_uuid=Placeholder("transaction_uuid_1") ), - AiopgSnapshotQueryBuilder._SELECT_TRANSACTION_CHUNK.format( + AiopgSnapshotQueryDatabaseOperationBuilder._SELECT_TRANSACTION_CHUNK.format( index=Literal(2), transaction_uuid=Placeholder("transaction_uuid_2") ), ] @@ -118,7 +118,7 @@ async def test_build_with_transactions(self): async def test_build_true(self): condition = Condition.TRUE - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("TRUE")]) expected_parameters = self.base_parameters @@ -128,7 +128,7 @@ async def test_build_true(self): async def test_build_false(self): condition = Condition.FALSE - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("FALSE")]) expected_parameters = self.base_parameters self.assertEqual(await self._flatten_query(expected_query), await self._flatten_query(observed[0])) @@ -137,8 +137,8 @@ async def test_build_false(self): async def test_build_fixed_uuid(self): uuid = uuid4() condition = Condition.EQUAL("uuid", uuid) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('("uuid" = %(hello)s)')]) expected_parameters = {"hello": str(uuid)} | self.base_parameters @@ -148,8 +148,8 @@ async def test_build_fixed_uuid(self): async def test_build_fixed_version(self): condition = Condition.EQUAL("version", 1) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('("version" = %(hello)s)')]) expected_parameters = {"hello": 1} | self.base_parameters @@ -159,8 +159,8 @@ async def test_build_fixed_version(self): async def test_build_fixed_created_at(self): condition = Condition.EQUAL("created_at", 1) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('("created_at" = %(hello)s)')]) expected_parameters = {"hello": 1} | self.base_parameters @@ -170,8 +170,8 @@ async def test_build_fixed_created_at(self): async def test_build_fixed_updated_at(self): condition = Condition.EQUAL("updated_at", 1) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('("updated_at" = %(hello)s)')]) expected_parameters = {"hello": 1} | self.base_parameters @@ -181,8 +181,8 @@ async def test_build_fixed_updated_at(self): async def test_build_fixed_with_like(self): condition = Condition.LIKE("uuid", "a%") - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('("uuid"::text LIKE %(hello)s)')]) expected_parameters = {"hello": "a%"} | self.base_parameters @@ -192,8 +192,8 @@ async def test_build_fixed_with_like(self): async def test_build_lower(self): condition = Condition.LOWER("age", 1) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' < %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -203,8 +203,8 @@ async def test_build_lower(self): async def test_build_lower_equal(self): condition = Condition.LOWER_EQUAL("age", 1) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' <= %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -214,8 +214,8 @@ async def test_build_lower_equal(self): async def test_build_greater(self): condition = Condition.GREATER("age", 1) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' > %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -225,8 +225,8 @@ async def test_build_greater(self): async def test_build_greater_equal(self): condition = Condition.GREATER_EQUAL("age", 1) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' >= %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -236,8 +236,8 @@ async def test_build_greater_equal(self): async def test_build_equal(self): condition = Condition.EQUAL("age", 1) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' = %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -247,8 +247,8 @@ async def test_build_equal(self): async def test_build_not_equal(self): condition = Condition.NOT_EQUAL("age", 1) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' <> %(hello)s::jsonb)")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -258,8 +258,8 @@ async def test_build_not_equal(self): async def test_build_in(self): condition = Condition.IN("age", [1, 2, 3]) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>'{age}' IN %(hello)s::jsonb)")]) expected_parameters = {"hello": (1, 2, 3)} | self.base_parameters @@ -269,8 +269,8 @@ async def test_build_in(self): async def test_build_in_empty(self): condition = Condition.IN("age", []) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("FALSE")]) expected_parameters = self.base_parameters @@ -280,8 +280,8 @@ async def test_build_in_empty(self): async def test_build_like(self): condition = Condition.LIKE("name", "a%") - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(data#>>'{name}' LIKE %(hello)s)")]) expected_parameters = {"hello": "a%"} | self.base_parameters @@ -291,8 +291,8 @@ async def test_build_like(self): async def test_build_not(self): condition = Condition.NOT(Condition.LOWER("age", 1)) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object(AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello"]): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("(NOT (data#>'{age}' < %(hello)s::jsonb))")]) expected_parameters = {"hello": 1} | self.base_parameters @@ -302,8 +302,10 @@ async def test_build_not(self): async def test_build_and(self): condition = Condition.AND(Condition.LOWER("age", 1), Condition.LOWER("level", 3)) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello", "goodbye"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object( + AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello", "goodbye"] + ): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join( [self.base_select, SQL("((data#>'{age}' < %(hello)s::jsonb) AND (data#>'{level}' < %(goodbye)s::jsonb))")] @@ -315,8 +317,10 @@ async def test_build_and(self): async def test_build_or(self): condition = Condition.OR(Condition.LOWER("age", 1), Condition.LOWER("level", 3)) - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["hello", "goodbye"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition).build() + with patch.object( + AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["hello", "goodbye"] + ): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition).build() expected_query = SQL(" WHERE ").join( [self.base_select, SQL("((data#>'{age}' < %(hello)s::jsonb) OR (data#>'{level}' < %(goodbye)s::jsonb))")] @@ -327,7 +331,9 @@ async def test_build_or(self): self.assertEqual(self._flatten_parameters(expected_parameters), self._flatten_parameters(observed[1])) async def test_build_exclude_deleted(self): - observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, exclude_deleted=True).build() + observed = AiopgSnapshotQueryDatabaseOperationBuilder( + self.classname, Condition.TRUE, exclude_deleted=True + ).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("TRUE AND (data IS NOT NULL)")]) expected_parameters = self.base_parameters @@ -337,7 +343,7 @@ async def test_build_exclude_deleted(self): async def test_build_fixed_ordering_asc(self): ordering = Ordering.ASC("created_at") - observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, Condition.TRUE, ordering).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('TRUE ORDER BY "created_at" ASC')]) @@ -348,7 +354,7 @@ async def test_build_fixed_ordering_asc(self): async def test_build_fixed_ordering_desc(self): ordering = Ordering.DESC("created_at") - observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, Condition.TRUE, ordering).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL('TRUE ORDER BY "created_at" DESC')]) expected_parameters = self.base_parameters @@ -358,7 +364,7 @@ async def test_build_fixed_ordering_desc(self): async def test_build_ordering_asc(self): ordering = Ordering.ASC("name") - observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, Condition.TRUE, ordering).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("TRUE ORDER BY data#>'{name}' ASC")]) expected_parameters = self.base_parameters @@ -368,7 +374,7 @@ async def test_build_ordering_asc(self): async def test_build_ordering_desc(self): ordering = Ordering.DESC("name") - observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, ordering).build() + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, Condition.TRUE, ordering).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("TRUE ORDER BY data#>'{name}' DESC")]) @@ -378,7 +384,7 @@ async def test_build_ordering_desc(self): self.assertEqual(self._flatten_parameters(expected_parameters), self._flatten_parameters(observed[1])) async def test_build_limit(self): - observed = AiopgSnapshotQueryBuilder(self.classname, Condition.TRUE, limit=10).build() + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, Condition.TRUE, limit=10).build() expected_query = SQL(" WHERE ").join([self.base_select, SQL("TRUE LIMIT 10")]) @@ -395,8 +401,10 @@ async def test_build_complex(self): ordering = Ordering.DESC("updated_at") limit = 100 - with patch.object(AiopgSnapshotQueryBuilder, "generate_random_str", side_effect=["one", "two", "three"]): - observed = AiopgSnapshotQueryBuilder(self.classname, condition, ordering, limit).build() + with patch.object( + AiopgSnapshotQueryDatabaseOperationBuilder, "generate_random_str", side_effect=["one", "two", "three"] + ): + observed = AiopgSnapshotQueryDatabaseOperationBuilder(self.classname, condition, ordering, limit).build() expected_query = SQL(" WHERE ").join( [ From 6ef3f811be5a0170bde58e184ac32d9d5f4462f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 16:30:04 +0200 Subject: [PATCH 151/324] ISSUE #371 * Rename classes (3). --- .../minos/aggregate/__init__.py | 10 ++++++---- .../minos/aggregate/events/__init__.py | 4 ++-- .../minos/aggregate/events/repositories/__init__.py | 4 ++-- .../aggregate/events/repositories/database/__init__.py | 4 ++-- .../events/repositories/database/factories/__init__.py | 4 ++-- .../events/repositories/database/factories/abc.py | 2 +- .../events/repositories/database/factories/aiopg.py | 4 ++-- .../aggregate/events/repositories/database/impl.py | 8 ++++---- .../minos/aggregate/snapshots/__init__.py | 2 ++ .../minos/aggregate/transactions/__init__.py | 4 ++-- .../aggregate/transactions/repositories/__init__.py | 4 ++-- .../transactions/repositories/database/__init__.py | 4 ++-- .../repositories/database/factories/__init__.py | 4 ++-- .../repositories/database/factories/abc.py | 2 +- .../repositories/database/factories/aiopg.py | 4 ++-- .../transactions/repositories/database/impl.py | 8 ++++---- 16 files changed, 38 insertions(+), 34 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index 45d36f5bb..d1dbd0139 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -29,12 +29,12 @@ RootEntity, ) from .events import ( - AiopgEventRepositoryOperationFactory, + AiopgEventDatabaseOperationFactory, DatabaseEventRepository, Event, + EventDatabaseOperationFactory, EventEntry, EventRepository, - EventRepositoryOperationFactory, FieldDiff, FieldDiffContainer, IncrementalFieldDiff, @@ -60,6 +60,7 @@ Ordering, ) from .snapshots import ( + AiopgSnapshotDatabaseOperationFactory, AiopgSnapshotQueryDatabaseOperationBuilder, DatabaseSnapshotReader, DatabaseSnapshotRepository, @@ -71,19 +72,20 @@ PostgreSqlSnapshotRepository, PostgreSqlSnapshotSetup, PostgreSqlSnapshotWriter, + SnapshotDatabaseOperationFactory, SnapshotEntry, SnapshotRepository, SnapshotService, ) from .transactions import ( TRANSACTION_CONTEXT_VAR, - AiopgTransactionRepositoryOperationFactory, + AiopgTransactionDatatabaseOperationFactory, DatabaseTransactionRepository, InMemoryTransactionRepository, PostgreSqlTransactionRepository, + TransactionDatatabaseOperationFactory, TransactionEntry, TransactionRepository, - TransactionRepositoryOperationFactory, TransactionService, TransactionStatus, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py index 235db363c..9160f0aec 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py @@ -10,10 +10,10 @@ Event, ) from .repositories import ( - AiopgEventRepositoryOperationFactory, + AiopgEventDatabaseOperationFactory, DatabaseEventRepository, + EventDatabaseOperationFactory, EventRepository, - EventRepositoryOperationFactory, InMemoryEventRepository, PostgreSqlEventRepository, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py index 878602383..2fc258715 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py @@ -2,9 +2,9 @@ EventRepository, ) from .database import ( - AiopgEventRepositoryOperationFactory, + AiopgEventDatabaseOperationFactory, DatabaseEventRepository, - EventRepositoryOperationFactory, + EventDatabaseOperationFactory, PostgreSqlEventRepository, ) from .memory import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py index 13004bbcb..67a032ed8 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py @@ -1,6 +1,6 @@ from .factories import ( - AiopgEventRepositoryOperationFactory, - EventRepositoryOperationFactory, + AiopgEventDatabaseOperationFactory, + EventDatabaseOperationFactory, ) from .impl import ( DatabaseEventRepository, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py index 8bc76f7ea..1d69d3be1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py @@ -1,6 +1,6 @@ from .abc import ( - EventRepositoryOperationFactory, + EventDatabaseOperationFactory, ) from .aiopg import ( - AiopgEventRepositoryOperationFactory, + AiopgEventDatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py index c5da6bdb5..5d9f5a20b 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py @@ -19,7 +19,7 @@ ) -class EventRepositoryOperationFactory(ABC): +class EventDatabaseOperationFactory(ABC): """TODO""" @abstractmethod diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py index d95df6d51..458131c05 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py @@ -27,12 +27,12 @@ Action, ) from .abc import ( - EventRepositoryOperationFactory, + EventDatabaseOperationFactory, ) # noinspection SqlNoDataSourceInspection,SqlResolve,PyMethodMayBeStatic -class AiopgEventRepositoryOperationFactory(EventRepositoryOperationFactory): +class AiopgEventDatabaseOperationFactory(EventDatabaseOperationFactory): """TODO""" def build_create_table(self) -> DatabaseOperation: diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index e113cf48d..d20609585 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -26,18 +26,18 @@ EventRepository, ) from .factories import ( - AiopgEventRepositoryOperationFactory, - EventRepositoryOperationFactory, + AiopgEventDatabaseOperationFactory, + EventDatabaseOperationFactory, ) class DatabaseEventRepository(DatabaseMixin, EventRepository): """PostgreSQL-based implementation of the event repository class in ``Minos``.""" - def __init__(self, *args, operation_factory: Optional[EventRepositoryOperationFactory] = None, **kwargs): + def __init__(self, *args, operation_factory: Optional[EventDatabaseOperationFactory] = None, **kwargs): super().__init__(*args, **kwargs) if operation_factory is None: - operation_factory = AiopgEventRepositoryOperationFactory() + operation_factory = AiopgEventDatabaseOperationFactory() self.operation_factory = operation_factory diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py index 5ace8eace..66d3830ab 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py @@ -2,6 +2,7 @@ SnapshotRepository, ) from .database import ( + AiopgSnapshotDatabaseOperationFactory, AiopgSnapshotQueryDatabaseOperationBuilder, DatabaseSnapshotReader, DatabaseSnapshotRepository, @@ -12,6 +13,7 @@ PostgreSqlSnapshotRepository, PostgreSqlSnapshotSetup, PostgreSqlSnapshotWriter, + SnapshotDatabaseOperationFactory, ) from .entries import ( SnapshotEntry, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py index 9e94e6b16..7653e6842 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py @@ -6,12 +6,12 @@ TransactionStatus, ) from .repositories import ( - AiopgTransactionRepositoryOperationFactory, + AiopgTransactionDatatabaseOperationFactory, DatabaseTransactionRepository, InMemoryTransactionRepository, PostgreSqlTransactionRepository, + TransactionDatatabaseOperationFactory, TransactionRepository, - TransactionRepositoryOperationFactory, ) from .services import ( TransactionService, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py index 0f2ccd8cb..dcb539e9f 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py @@ -2,10 +2,10 @@ TransactionRepository, ) from .database import ( - AiopgTransactionRepositoryOperationFactory, + AiopgTransactionDatatabaseOperationFactory, DatabaseTransactionRepository, PostgreSqlTransactionRepository, - TransactionRepositoryOperationFactory, + TransactionDatatabaseOperationFactory, ) from .memory import ( InMemoryTransactionRepository, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py index 4a22ce8ce..e66e5943f 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py @@ -1,6 +1,6 @@ from .factories import ( - AiopgTransactionRepositoryOperationFactory, - TransactionRepositoryOperationFactory, + AiopgTransactionDatatabaseOperationFactory, + TransactionDatatabaseOperationFactory, ) from .impl import ( DatabaseTransactionRepository, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py index ba24761b9..02e029a18 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py @@ -1,6 +1,6 @@ from .abc import ( - TransactionRepositoryOperationFactory, + TransactionDatatabaseOperationFactory, ) from .aiopg import ( - AiopgTransactionRepositoryOperationFactory, + AiopgTransactionDatatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py index f1685115c..46af61ca3 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py @@ -25,7 +25,7 @@ ) -class TransactionRepositoryOperationFactory(ABC): +class TransactionDatatabaseOperationFactory(ABC): """TODO""" @abstractmethod diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py index 5b574656c..cec02cfb9 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py @@ -18,7 +18,7 @@ ) from .abc import ( - TransactionRepositoryOperationFactory, + TransactionDatatabaseOperationFactory, ) if TYPE_CHECKING: @@ -28,7 +28,7 @@ # noinspection SqlNoDataSourceInspection,SqlResolve,PyMethodMayBeStatic -class AiopgTransactionRepositoryOperationFactory(TransactionRepositoryOperationFactory): +class AiopgTransactionDatatabaseOperationFactory(TransactionDatatabaseOperationFactory): """TODO""" def build_create_table(self) -> DatabaseOperation: diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index cb390cef0..1d0309276 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -23,18 +23,18 @@ TransactionRepository, ) from .factories import ( - AiopgTransactionRepositoryOperationFactory, - TransactionRepositoryOperationFactory, + AiopgTransactionDatatabaseOperationFactory, + TransactionDatatabaseOperationFactory, ) class DatabaseTransactionRepository(DatabaseMixin, TransactionRepository): """PostgreSql Transaction Repository class.""" - def __init__(self, *args, operation_factory: Optional[TransactionRepositoryOperationFactory] = None, **kwargs): + def __init__(self, *args, operation_factory: Optional[TransactionDatatabaseOperationFactory] = None, **kwargs): super().__init__(*args, **kwargs) if operation_factory is None: - operation_factory = AiopgTransactionRepositoryOperationFactory() + operation_factory = AiopgTransactionDatatabaseOperationFactory() self.operation_factory = operation_factory From 9a50a56ecca8474d0c17bc728cd426345ab31bce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 16:48:28 +0200 Subject: [PATCH 152/324] ISSUE #371 * Add base classes. * Rename classes (4). --- .../minos/networks/__init__.py | 26 ++++--- .../minos/networks/brokers/__init__.py | 26 ++++--- .../networks/brokers/collections/__init__.py | 7 +- .../brokers/collections/queues/__init__.py | 7 +- .../collections/queues/database/__init__.py | 7 +- .../queues/database/factories/__init__.py | 5 +- .../queues/database/factories/abc.py | 73 +++++++++++++++++++ .../queues/database/factories/aiopg.py | 6 +- .../collections/queues/database/impl.py | 14 ++-- .../networks/brokers/publishers/__init__.py | 5 +- .../brokers/publishers/queued/__init__.py | 5 +- .../publishers/queued/queues/__init__.py | 5 +- .../brokers/publishers/queued/queues/pg.py | 24 ++++-- .../networks/brokers/subscribers/__init__.py | 14 ++-- .../brokers/subscribers/filtered/__init__.py | 7 +- .../filtered/validators/__init__.py | 7 +- .../validators/duplicates/__init__.py | 7 +- .../duplicates/database/__init__.py | 7 +- .../duplicates/database/factories/__init__.py | 5 +- .../duplicates/database/factories/abc.py | 30 ++++++++ .../duplicates/database/factories/aiopg.py | 10 ++- .../validators/duplicates/database/impl.py | 17 +++-- .../brokers/subscribers/queued/__init__.py | 7 +- .../subscribers/queued/queues/__init__.py | 7 +- .../queued/queues/database/__init__.py | 7 +- .../queues/database/factories/__init__.py | 5 +- .../queued/queues/database/factories/abc.py | 51 +++++++++++++ .../queued/queues/database/factories/aiopg.py | 9 ++- .../queued/queues/database/impl.py | 18 ++--- .../test_collections/test_queues/test_pg.py | 24 +++--- .../test_queued/test_queues/test_pg.py | 14 ++-- .../test_duplicates/test_pg.py | 12 +-- .../test_queued/test_queues/test_pg.py | 26 +++---- .../minos/plugins/kafka/publisher.py | 4 +- .../minos/plugins/kafka/subscriber.py | 4 +- .../tests/test_kafka/test_publisher.py | 4 +- .../tests/test_kafka/test_subscriber.py | 4 +- 37 files changed, 363 insertions(+), 147 deletions(-) create mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py diff --git a/packages/core/minos-microservice-networks/minos/networks/__init__.py b/packages/core/minos-microservice-networks/minos/networks/__init__.py index f68feb77b..1058ac612 100644 --- a/packages/core/minos-microservice-networks/minos/networks/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/__init__.py @@ -7,6 +7,10 @@ from .brokers import ( REQUEST_HEADERS_CONTEXT_VAR, REQUEST_REPLY_TOPIC_CONTEXT_VAR, + AiopgBrokerPublisherQueueDatabaseOperationFactory, + AiopgBrokerQueueDatabaseOperationFactory, + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerClient, BrokerClientPool, BrokerDispatcher, @@ -21,16 +25,27 @@ BrokerPublisher, BrokerPublisherBuilder, BrokerPublisherQueue, + BrokerPublisherQueueDatabaseOperationFactory, BrokerQueue, + BrokerQueueDatabaseOperationFactory, BrokerRequest, BrokerResponse, BrokerResponseException, BrokerSubscriber, BrokerSubscriberBuilder, BrokerSubscriberDuplicateValidator, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberQueue, BrokerSubscriberQueueBuilder, + BrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriberValidator, + DatabaseBrokerPublisherQueue, + DatabaseBrokerQueue, + DatabaseBrokerQueueBuilder, + DatabaseBrokerSubscriberDuplicateValidator, + DatabaseBrokerSubscriberDuplicateValidatorBuilder, + DatabaseBrokerSubscriberQueue, + DatabaseBrokerSubscriberQueueBuilder, FilteredBrokerSubscriber, InMemoryBrokerPublisher, InMemoryBrokerPublisherQueue, @@ -40,17 +55,6 @@ InMemoryBrokerSubscriberDuplicateValidator, InMemoryBrokerSubscriberQueue, InMemoryBrokerSubscriberQueueBuilder, - PostgreSqlBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueueQueryFactory, - PostgreSqlBrokerQueue, - PostgreSqlBrokerQueueBuilder, - PostgreSqlBrokerQueueQueryFactory, - PostgreSqlBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, - PostgreSqlBrokerSubscriberQueue, - PostgreSqlBrokerSubscriberQueueBuilder, - PostgreSqlBrokerSubscriberQueueQueryFactory, QueuedBrokerPublisher, QueuedBrokerSubscriber, QueuedBrokerSubscriberBuilder, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py index 5c4fa93a5..bcf814550 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py @@ -2,11 +2,12 @@ BrokerClient, ) from .collections import ( + AiopgBrokerQueueDatabaseOperationFactory, BrokerQueue, + BrokerQueueDatabaseOperationFactory, + DatabaseBrokerQueue, + DatabaseBrokerQueueBuilder, InMemoryBrokerQueue, - PostgreSqlBrokerQueue, - PostgreSqlBrokerQueueBuilder, - PostgreSqlBrokerQueueQueryFactory, ) from .dispatchers import ( BrokerDispatcher, @@ -32,34 +33,37 @@ BrokerClientPool, ) from .publishers import ( + AiopgBrokerPublisherQueueDatabaseOperationFactory, BrokerPublisher, BrokerPublisherBuilder, BrokerPublisherQueue, + BrokerPublisherQueueDatabaseOperationFactory, + DatabaseBrokerPublisherQueue, InMemoryBrokerPublisher, InMemoryBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueueQueryFactory, QueuedBrokerPublisher, ) from .subscribers import ( + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriber, BrokerSubscriberBuilder, BrokerSubscriberDuplicateValidator, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberQueue, BrokerSubscriberQueueBuilder, + BrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriberValidator, + DatabaseBrokerSubscriberDuplicateValidator, + DatabaseBrokerSubscriberDuplicateValidatorBuilder, + DatabaseBrokerSubscriberQueue, + DatabaseBrokerSubscriberQueueBuilder, FilteredBrokerSubscriber, InMemoryBrokerSubscriber, InMemoryBrokerSubscriberBuilder, InMemoryBrokerSubscriberDuplicateValidator, InMemoryBrokerSubscriberQueue, InMemoryBrokerSubscriberQueueBuilder, - PostgreSqlBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, - PostgreSqlBrokerSubscriberQueue, - PostgreSqlBrokerSubscriberQueueBuilder, - PostgreSqlBrokerSubscriberQueueQueryFactory, QueuedBrokerSubscriber, QueuedBrokerSubscriberBuilder, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/__init__.py index 924871e4d..dd2bfc375 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/__init__.py @@ -1,7 +1,8 @@ from .queues import ( + AiopgBrokerQueueDatabaseOperationFactory, BrokerQueue, + BrokerQueueDatabaseOperationFactory, + DatabaseBrokerQueue, + DatabaseBrokerQueueBuilder, InMemoryBrokerQueue, - PostgreSqlBrokerQueue, - PostgreSqlBrokerQueueBuilder, - PostgreSqlBrokerQueueQueryFactory, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py index 6af27b461..ad54e3cde 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py @@ -2,9 +2,10 @@ BrokerQueue, ) from .database import ( - PostgreSqlBrokerQueue, - PostgreSqlBrokerQueueBuilder, - PostgreSqlBrokerQueueQueryFactory, + AiopgBrokerQueueDatabaseOperationFactory, + BrokerQueueDatabaseOperationFactory, + DatabaseBrokerQueue, + DatabaseBrokerQueueBuilder, ) from .memory import ( InMemoryBrokerQueue, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py index 07ce83a2e..2b7024161 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py @@ -1,7 +1,8 @@ from .factories import ( - PostgreSqlBrokerQueueQueryFactory, + AiopgBrokerQueueDatabaseOperationFactory, + BrokerQueueDatabaseOperationFactory, ) from .impl import ( - PostgreSqlBrokerQueue, - PostgreSqlBrokerQueueBuilder, + DatabaseBrokerQueue, + DatabaseBrokerQueueBuilder, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py index bcbfb3743..ee7e48786 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py @@ -1,3 +1,6 @@ +from .abc import ( + BrokerQueueDatabaseOperationFactory, +) from .aiopg import ( - PostgreSqlBrokerQueueQueryFactory, + AiopgBrokerQueueDatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py index e69de29bb..5b1bb9718 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py @@ -0,0 +1,73 @@ +from abc import ( + ABC, + abstractmethod, +) +from collections.abc import ( + Iterable, +) + +from minos.common import ( + DatabaseOperation, +) + + +# noinspection SqlResolve,SqlNoDataSourceInspection,SqlNoDataSourceInspection,SqlResolve +class BrokerQueueDatabaseOperationFactory(ABC): + """PostgreSql Broker Queue Query Factory class.""" + + @abstractmethod + def build_table_name(self) -> str: + """Get the table name. + + :return: A ``str`` value. + """ + raise NotImplementedError + + @abstractmethod + def build_create_table(self) -> DatabaseOperation: + """Build the "create table" query. + + :return: A ``SQL`` instance. + """ + + @abstractmethod + def build_update_not_processed(self, id_: int) -> DatabaseOperation: + """Build the "update not processed" query. + + :return: A ``SQL`` instance. + """ + + @abstractmethod + def build_delete_processed(self, id_: int) -> DatabaseOperation: + """Build the "delete processed" query. + + :return: A ``SQL`` instance. + """ + + @abstractmethod + def build_mark_processing(self, ids: Iterable[int]) -> DatabaseOperation: + """ + + :return: A ``SQL`` instance. + """ + + @abstractmethod + def build_count_not_processed(self, retry: int, *args, **kwargs) -> DatabaseOperation: + """Build the "count not processed" query. + + :return: + """ + + @abstractmethod + def build_insert(self, topic: str, data: bytes) -> DatabaseOperation: + """Build the "insert" query. + + :return: A ``SQL`` instance. + """ + + @abstractmethod + def build_select_not_processed(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: + """Build the "select not processed" query. + + :return: A ``SQL`` instance. + """ diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py index bbe6bd8d1..11b78c25d 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py @@ -15,9 +15,13 @@ DatabaseOperation, ) +from .abc import ( + BrokerQueueDatabaseOperationFactory, +) + # noinspection SqlResolve,SqlNoDataSourceInspection,SqlNoDataSourceInspection,SqlResolve -class PostgreSqlBrokerQueueQueryFactory(ABC): +class AiopgBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): """PostgreSql Broker Queue Query Factory class.""" @abstractmethod diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index 90f74e74c..11fcb0ff8 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -39,13 +39,13 @@ BrokerQueue, ) from .factories import ( - PostgreSqlBrokerQueueQueryFactory, + AiopgBrokerQueueDatabaseOperationFactory, ) logger = logging.getLogger(__name__) -class PostgreSqlBrokerQueue(BrokerQueue, DatabaseMixin): +class DatabaseBrokerQueue(BrokerQueue, DatabaseMixin): """PostgreSql Broker Queue class.""" _queue: PriorityQueue[_Entry] @@ -53,7 +53,7 @@ class PostgreSqlBrokerQueue(BrokerQueue, DatabaseMixin): def __init__( self, *args, - query_factory: PostgreSqlBrokerQueueQueryFactory, + query_factory: AiopgBrokerQueueDatabaseOperationFactory, retry: Optional[int] = None, records: Optional[int] = None, **kwargs, @@ -91,7 +91,7 @@ def records(self) -> int: return self._records @property - def query_factory(self) -> PostgreSqlBrokerQueueQueryFactory: + def query_factory(self) -> AiopgBrokerQueueDatabaseOperationFactory: """Get the query factory. :return: A ``PostgreSqlBrokerQueueQueryFactory`` instance. @@ -99,7 +99,7 @@ def query_factory(self) -> PostgreSqlBrokerQueueQueryFactory: return self._query_factory @classmethod - def _from_config(cls, config: Config, **kwargs) -> PostgreSqlBrokerQueue: + def _from_config(cls, config: Config, **kwargs) -> DatabaseBrokerQueue: broker_interface = config.get_interface_by_name("broker") queue_config = broker_interface.get("common", dict()).get("queue", dict()) database_config = {"database_key": None} @@ -240,7 +240,7 @@ def __lt__(self, other: Any) -> bool: return False -class PostgreSqlBrokerQueueBuilder(Builder): +class DatabaseBrokerQueueBuilder(Builder): """PostgreSql Broker Queue Builder class.""" def with_config(self, config: Config): @@ -254,4 +254,4 @@ def with_config(self, config: Config): return super().with_config(config) -PostgreSqlBrokerQueue.set_builder(PostgreSqlBrokerQueueBuilder) +DatabaseBrokerQueue.set_builder(DatabaseBrokerQueueBuilder) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/__init__.py index 7d3037037..1c5f5166d 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/__init__.py @@ -6,9 +6,10 @@ InMemoryBrokerPublisher, ) from .queued import ( + AiopgBrokerPublisherQueueDatabaseOperationFactory, BrokerPublisherQueue, + BrokerPublisherQueueDatabaseOperationFactory, + DatabaseBrokerPublisherQueue, InMemoryBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueueQueryFactory, QueuedBrokerPublisher, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/__init__.py index eaa101250..9bb141835 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/__init__.py @@ -2,8 +2,9 @@ QueuedBrokerPublisher, ) from .queues import ( + AiopgBrokerPublisherQueueDatabaseOperationFactory, BrokerPublisherQueue, + BrokerPublisherQueueDatabaseOperationFactory, + DatabaseBrokerPublisherQueue, InMemoryBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueueQueryFactory, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py index 81e0bc8cb..7483cabb4 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py @@ -5,6 +5,7 @@ InMemoryBrokerPublisherQueue, ) from .pg import ( - PostgreSqlBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueueQueryFactory, + AiopgBrokerPublisherQueueDatabaseOperationFactory, + BrokerPublisherQueueDatabaseOperationFactory, + DatabaseBrokerPublisherQueue, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py index fef5d0b09..ed53c4861 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py @@ -3,13 +3,19 @@ ) import logging +from abc import ( + ABC, +) from typing import ( Optional, ) from ....collections import ( - PostgreSqlBrokerQueue, - PostgreSqlBrokerQueueQueryFactory, + AiopgBrokerQueueDatabaseOperationFactory, + DatabaseBrokerQueue, +) +from ....collections.queues.database.factories.abc import ( + BrokerQueueDatabaseOperationFactory, ) from .abc import ( BrokerPublisherQueue, @@ -18,16 +24,22 @@ logger = logging.getLogger(__name__) -class PostgreSqlBrokerPublisherQueue(PostgreSqlBrokerQueue, BrokerPublisherQueue): +class DatabaseBrokerPublisherQueue(DatabaseBrokerQueue, BrokerPublisherQueue): """PostgreSql Broker Publisher Queue class.""" - def __init__(self, *args, query_factory: Optional[PostgreSqlBrokerQueueQueryFactory] = None, **kwargs): + def __init__(self, *args, query_factory: Optional[BrokerPublisherQueueDatabaseOperationFactory] = None, **kwargs): if query_factory is None: - query_factory = PostgreSqlBrokerPublisherQueueQueryFactory() + query_factory = AiopgBrokerPublisherQueueDatabaseOperationFactory() super().__init__(*args, query_factory=query_factory, **kwargs) -class PostgreSqlBrokerPublisherQueueQueryFactory(PostgreSqlBrokerQueueQueryFactory): +class BrokerPublisherQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): + """TODO""" + + +class AiopgBrokerPublisherQueueDatabaseOperationFactory( + BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory +): """PostgreSql Broker Publisher Queue Query Factory class.""" def build_table_name(self) -> str: diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/__init__.py index 0a94221e5..2d6b416d9 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/__init__.py @@ -3,26 +3,28 @@ BrokerSubscriberBuilder, ) from .filtered import ( + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberDuplicateValidator, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberValidator, + DatabaseBrokerSubscriberDuplicateValidator, + DatabaseBrokerSubscriberDuplicateValidatorBuilder, FilteredBrokerSubscriber, InMemoryBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, ) from .memory import ( InMemoryBrokerSubscriber, InMemoryBrokerSubscriberBuilder, ) from .queued import ( + AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriberQueue, BrokerSubscriberQueueBuilder, + BrokerSubscriberQueueDatabaseOperationFactory, + DatabaseBrokerSubscriberQueue, + DatabaseBrokerSubscriberQueueBuilder, InMemoryBrokerSubscriberQueue, InMemoryBrokerSubscriberQueueBuilder, - PostgreSqlBrokerSubscriberQueue, - PostgreSqlBrokerSubscriberQueueBuilder, - PostgreSqlBrokerSubscriberQueueQueryFactory, QueuedBrokerSubscriber, QueuedBrokerSubscriberBuilder, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/__init__.py index 12e98c065..4878d8cf0 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/__init__.py @@ -2,10 +2,11 @@ FilteredBrokerSubscriber, ) from .validators import ( + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberDuplicateValidator, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberValidator, + DatabaseBrokerSubscriberDuplicateValidator, + DatabaseBrokerSubscriberDuplicateValidatorBuilder, InMemoryBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/__init__.py index 1ac774fae..9ddb90eaf 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/__init__.py @@ -2,9 +2,10 @@ BrokerSubscriberValidator, ) from .duplicates import ( + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberDuplicateValidator, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + DatabaseBrokerSubscriberDuplicateValidator, + DatabaseBrokerSubscriberDuplicateValidatorBuilder, InMemoryBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py index 61867b5aa..01c3487dd 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py @@ -2,9 +2,10 @@ BrokerSubscriberDuplicateValidator, ) from .database import ( - PostgreSqlBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + DatabaseBrokerSubscriberDuplicateValidator, + DatabaseBrokerSubscriberDuplicateValidatorBuilder, ) from .memory import ( InMemoryBrokerSubscriberDuplicateValidator, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py index 73b7ae821..ae4271871 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py @@ -1,7 +1,8 @@ from .factories import ( - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) from .impl import ( - PostgreSqlBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidatorBuilder, + DatabaseBrokerSubscriberDuplicateValidator, + DatabaseBrokerSubscriberDuplicateValidatorBuilder, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py index 0b61d1d4c..7cdea9721 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py @@ -1,3 +1,6 @@ +from .abc import ( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, +) from .aiopg import ( - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py index e69de29bb..d26989e93 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py @@ -0,0 +1,30 @@ +from abc import ( + ABC, + abstractmethod, +) +from uuid import ( + UUID, +) + +from minos.common import ( + DatabaseOperation, +) + + +# noinspection SqlNoDataSourceInspection,SqlResolve +class BrokerSubscriberDuplicateValidatorDatabaseOperationFactory(ABC): + """TODO""" + + @abstractmethod + def build_create_table(self) -> DatabaseOperation: + """Build the "create table" query. + + :return: A ``SQL`` instance. + """ + + @abstractmethod + def build_insert_row(self, topic: str, uuid: UUID) -> DatabaseOperation: + """Build the "insert row" query. + + :return: A ``SQL`` instance. + """ diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py index 780b3dcf7..4e3dd8e33 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py @@ -12,9 +12,15 @@ DatabaseOperation, ) +from .abc import ( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, +) + # noinspection SqlNoDataSourceInspection,SqlResolve -class PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory: +class AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory +): """PostgreSql Broker Subscriber Duplicate Detector Query Factory class.""" @staticmethod @@ -50,7 +56,7 @@ def build_create_table(self) -> DatabaseOperation: ] ) - def build_insert_row(self, topic: str, uuid: UUID) -> AiopgDatabaseOperation: + def build_insert_row(self, topic: str, uuid: UUID) -> DatabaseOperation: """Build the "insert row" query. :return: A ``SQL`` instance. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py index f05134356..8d8b68fc2 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py @@ -20,18 +20,21 @@ BrokerSubscriberDuplicateValidator, ) from .factories import ( - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) -class PostgreSqlBrokerSubscriberDuplicateValidator(BrokerSubscriberDuplicateValidator, DatabaseMixin): +class DatabaseBrokerSubscriberDuplicateValidator(BrokerSubscriberDuplicateValidator, DatabaseMixin): """PostgreSql Broker Subscriber Duplicate Detector class.""" def __init__( - self, query_factory: Optional[PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory] = None, *args, **kwargs + self, + query_factory: Optional[AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory] = None, + *args, + **kwargs, ): if query_factory is None: - query_factory = PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory() + query_factory = AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory() super().__init__(*args, **kwargs) self._query_factory = query_factory @@ -44,7 +47,7 @@ async def _create_table(self) -> None: await self.submit_query(operation) @property - def query_factory(self) -> PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory: + def query_factory(self) -> AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory: """Get the query factory. :return: A ``PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory`` instance. @@ -60,7 +63,7 @@ async def _is_unique(self, topic: str, uuid: UUID) -> bool: return False -class PostgreSqlBrokerSubscriberDuplicateValidatorBuilder(Builder[PostgreSqlBrokerSubscriberDuplicateValidator]): +class DatabaseBrokerSubscriberDuplicateValidatorBuilder(Builder[DatabaseBrokerSubscriberDuplicateValidator]): """PostgreSql Broker Subscriber Duplicate Detector Builder class.""" def with_config(self, config: Config): @@ -73,4 +76,4 @@ def with_config(self, config: Config): return super().with_config(config) -PostgreSqlBrokerSubscriberDuplicateValidator.set_builder(PostgreSqlBrokerSubscriberDuplicateValidatorBuilder) +DatabaseBrokerSubscriberDuplicateValidator.set_builder(DatabaseBrokerSubscriberDuplicateValidatorBuilder) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/__init__.py index 1d12f5592..d20f7843f 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/__init__.py @@ -3,11 +3,12 @@ QueuedBrokerSubscriberBuilder, ) from .queues import ( + AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriberQueue, BrokerSubscriberQueueBuilder, + BrokerSubscriberQueueDatabaseOperationFactory, + DatabaseBrokerSubscriberQueue, + DatabaseBrokerSubscriberQueueBuilder, InMemoryBrokerSubscriberQueue, InMemoryBrokerSubscriberQueueBuilder, - PostgreSqlBrokerSubscriberQueue, - PostgreSqlBrokerSubscriberQueueBuilder, - PostgreSqlBrokerSubscriberQueueQueryFactory, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py index e94cfbd15..7a6286749 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py @@ -3,9 +3,10 @@ BrokerSubscriberQueueBuilder, ) from .database import ( - PostgreSqlBrokerSubscriberQueue, - PostgreSqlBrokerSubscriberQueueBuilder, - PostgreSqlBrokerSubscriberQueueQueryFactory, + AiopgBrokerSubscriberQueueDatabaseOperationFactory, + BrokerSubscriberQueueDatabaseOperationFactory, + DatabaseBrokerSubscriberQueue, + DatabaseBrokerSubscriberQueueBuilder, ) from .memory import ( InMemoryBrokerSubscriberQueue, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py index 4bbdf989d..9a31cede2 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py @@ -1,7 +1,8 @@ from .factories import ( - PostgreSqlBrokerSubscriberQueueQueryFactory, + AiopgBrokerSubscriberQueueDatabaseOperationFactory, + BrokerSubscriberQueueDatabaseOperationFactory, ) from .impl import ( - PostgreSqlBrokerSubscriberQueue, - PostgreSqlBrokerSubscriberQueueBuilder, + DatabaseBrokerSubscriberQueue, + DatabaseBrokerSubscriberQueueBuilder, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py index 9a2ef153d..8e6078511 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py @@ -1,3 +1,6 @@ +from .abc import ( + BrokerSubscriberQueueDatabaseOperationFactory, +) from .aiopg import ( - PostgreSqlBrokerSubscriberQueueQueryFactory, + AiopgBrokerSubscriberQueueDatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py new file mode 100644 index 000000000..5478058d0 --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py @@ -0,0 +1,51 @@ +from abc import ( + ABC, +) +from collections.abc import ( + Iterable, +) + +from minos.common import ( + DatabaseOperation, +) + +from ......collections import ( + BrokerQueueDatabaseOperationFactory, +) + + +# noinspection SqlNoDataSourceInspection,SqlResolve,PyTypeChecker,PyArgumentList +class BrokerSubscriberQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): + """PostgreSql Broker Subscriber Queue Query Factory class.""" + + def build_table_name(self) -> str: + """Get the table name. + + :return: A ``str`` value. + """ + return "broker_subscriber_queue" + + def build_count_not_processed( + self, + retry: int, + topics: Iterable[str] = tuple(), + *args, + **kwargs, + ) -> DatabaseOperation: + """Build the "count not processed" query. + + :return: + """ + + def build_select_not_processed( + self, + retry: int, + records: int, + topics: Iterable[str] = tuple(), + *args, + **kwargs, + ) -> DatabaseOperation: + """Build the "select not processed" query. + + :return: A ``SQL`` instance. + """ diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py index f3d54569c..454d9c534 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py @@ -12,12 +12,17 @@ ) from ......collections import ( - PostgreSqlBrokerQueueQueryFactory, + AiopgBrokerQueueDatabaseOperationFactory, +) +from .abc import ( + BrokerSubscriberQueueDatabaseOperationFactory, ) # noinspection SqlNoDataSourceInspection,SqlResolve,PyTypeChecker,PyArgumentList -class PostgreSqlBrokerSubscriberQueueQueryFactory(PostgreSqlBrokerQueueQueryFactory): +class AiopgBrokerSubscriberQueueDatabaseOperationFactory( + BrokerSubscriberQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory +): """PostgreSql Broker Subscriber Queue Query Factory class.""" def build_table_name(self) -> str: diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py index 932b0ea6a..c5c8f50bf 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py @@ -13,32 +13,32 @@ ) from .....collections import ( - PostgreSqlBrokerQueue, - PostgreSqlBrokerQueueBuilder, + DatabaseBrokerQueue, + DatabaseBrokerQueueBuilder, ) from ..abc import ( BrokerSubscriberQueue, BrokerSubscriberQueueBuilder, ) from .factories import ( - PostgreSqlBrokerSubscriberQueueQueryFactory, + AiopgBrokerSubscriberQueueDatabaseOperationFactory, ) logger = logging.getLogger(__name__) -class PostgreSqlBrokerSubscriberQueue(PostgreSqlBrokerQueue, BrokerSubscriberQueue): +class DatabaseBrokerSubscriberQueue(DatabaseBrokerQueue, BrokerSubscriberQueue): """PostgreSql Broker Subscriber Queue class.""" def __init__( self, topics: set[str], *args, - query_factory: Optional[PostgreSqlBrokerSubscriberQueueQueryFactory] = None, + query_factory: Optional[AiopgBrokerSubscriberQueueDatabaseOperationFactory] = None, **kwargs, ): if query_factory is None: - query_factory = PostgreSqlBrokerSubscriberQueueQueryFactory() + query_factory = AiopgBrokerSubscriberQueueDatabaseOperationFactory() super().__init__(topics, *args, query_factory=query_factory, **kwargs) async def _get_count(self) -> int: @@ -54,10 +54,10 @@ async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: return [row async for row in client.fetch_all()] -class PostgreSqlBrokerSubscriberQueueBuilder( - BrokerSubscriberQueueBuilder[PostgreSqlBrokerSubscriberQueue], PostgreSqlBrokerQueueBuilder +class DatabaseBrokerSubscriberQueueBuilder( + BrokerSubscriberQueueBuilder[DatabaseBrokerSubscriberQueue], DatabaseBrokerQueueBuilder ): """PostgreSql Broker Subscriber Queue Builder class.""" -PostgreSqlBrokerSubscriberQueue.set_builder(PostgreSqlBrokerSubscriberQueueBuilder) +DatabaseBrokerSubscriberQueue.set_builder(DatabaseBrokerSubscriberQueueBuilder) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index 9585a68e4..d0d27e96c 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -15,11 +15,11 @@ PostgresAsyncTestCase, ) from minos.networks import ( + AiopgBrokerQueueDatabaseOperationFactory, BrokerMessageV1, BrokerMessageV1Payload, BrokerQueue, - PostgreSqlBrokerQueue, - PostgreSqlBrokerQueueQueryFactory, + DatabaseBrokerQueue, ) from tests.utils import ( FakeAsyncIterator, @@ -27,7 +27,7 @@ ) -class _PostgreSqlBrokerQueueQueryFactory(PostgreSqlBrokerQueueQueryFactory): +class _Aiopg_BrokerQueueDatabaseOperationFactory(AiopgBrokerQueueDatabaseOperationFactory): def build_table_name(self) -> str: """For testing purposes.""" return "test_table" @@ -36,27 +36,27 @@ def build_table_name(self) -> str: class TestPostgreSqlBrokerQueue(NetworksTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() - self.query_factory = _PostgreSqlBrokerQueueQueryFactory() + self.query_factory = _Aiopg_BrokerQueueDatabaseOperationFactory() def test_is_subclass(self): - self.assertTrue(issubclass(PostgreSqlBrokerQueue, (BrokerQueue, DatabaseMixin))) + self.assertTrue(issubclass(DatabaseBrokerQueue, (BrokerQueue, DatabaseMixin))) def test_constructor(self): - queue = PostgreSqlBrokerQueue(query_factory=self.query_factory) + queue = DatabaseBrokerQueue(query_factory=self.query_factory) self.assertEqual(self.pool_factory.get_pool("database"), queue.pool) self.assertEqual(self.query_factory, queue.query_factory) self.assertEqual(2, queue.retry) self.assertEqual(1000, queue.records) async def test_query_factory(self): - queue = PostgreSqlBrokerQueue.from_config(self.config, query_factory=self.query_factory) + queue = DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) self.assertEqual(self.query_factory, queue.query_factory) async def test_enqueue(self): message = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) - async with PostgreSqlBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: + async with DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: await queue.enqueue(message) await sleep(0.5) # To give time to consume the message from db. @@ -66,7 +66,7 @@ async def test_aiter(self): BrokerMessageV1("bar", BrokerMessageV1Payload("foo")), ] - queue = PostgreSqlBrokerQueue.from_config(self.config, query_factory=self.query_factory) + queue = DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) await queue.setup() await queue.enqueue(messages[0]) await queue.enqueue(messages[1]) @@ -90,7 +90,7 @@ async def test_dequeue_with_count(self): "fetch_all", return_value=FakeAsyncIterator([[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]]), ): - async with PostgreSqlBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: + async with DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: queue._get_count = AsyncMock(side_effect=[3, 0]) async with queue: @@ -103,7 +103,7 @@ async def test_dequeue_with_notify(self): BrokerMessageV1("foo", BrokerMessageV1Payload("bar")), BrokerMessageV1("bar", BrokerMessageV1Payload("foo")), ] - async with PostgreSqlBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: + async with DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: await queue.enqueue(messages[0]) await queue.enqueue(messages[1]) @@ -119,7 +119,7 @@ async def test_dequeue_ordered(self): BrokerMessageV1("foo", BrokerMessageV1Payload(1)), ] - async with PostgreSqlBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: + async with DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: for message in unsorted: await queue.enqueue(message) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py index 8118d49cf..ec5df2ec0 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py @@ -4,10 +4,10 @@ PostgresAsyncTestCase, ) from minos.networks import ( + AiopgBrokerPublisherQueueDatabaseOperationFactory, BrokerPublisherQueue, - PostgreSqlBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueueQueryFactory, - PostgreSqlBrokerQueue, + DatabaseBrokerPublisherQueue, + DatabaseBrokerQueue, ) from tests.utils import ( NetworksTestCase, @@ -16,17 +16,17 @@ class TestPostgreSqlBrokerPublisherQueue(NetworksTestCase, PostgresAsyncTestCase): def test_is_subclass(self): - self.assertTrue(issubclass(PostgreSqlBrokerPublisherQueue, (PostgreSqlBrokerQueue, BrokerPublisherQueue))) + self.assertTrue(issubclass(DatabaseBrokerPublisherQueue, (DatabaseBrokerQueue, BrokerPublisherQueue))) async def test_query_factory(self): - queue = PostgreSqlBrokerPublisherQueue.from_config(self.config) + queue = DatabaseBrokerPublisherQueue.from_config(self.config) - self.assertIsInstance(queue.query_factory, PostgreSqlBrokerPublisherQueueQueryFactory) + self.assertIsInstance(queue.query_factory, AiopgBrokerPublisherQueueDatabaseOperationFactory) class TestPostgreSqlBrokerPublisherQueueQueryFactory(unittest.TestCase): def setUp(self) -> None: - self.factory = PostgreSqlBrokerPublisherQueueQueryFactory() + self.factory = AiopgBrokerPublisherQueueDatabaseOperationFactory() def test_build_table_name(self): self.assertEqual("broker_publisher_queue", self.factory.build_table_name()) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py index 5c294b2d3..4a0fd21c3 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py @@ -4,11 +4,11 @@ PostgresAsyncTestCase, ) from minos.networks import ( + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerMessageV1, BrokerMessageV1Payload, BrokerSubscriberValidator, - PostgreSqlBrokerSubscriberDuplicateValidator, - PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory, + DatabaseBrokerSubscriberDuplicateValidator, ) from tests.utils import ( NetworksTestCase, @@ -17,19 +17,19 @@ class TestPostgreSqlBrokerSubscriberDuplicateValidator(NetworksTestCase, PostgresAsyncTestCase): def test_is_subclass(self): - self.assertTrue(issubclass(PostgreSqlBrokerSubscriberDuplicateValidator, BrokerSubscriberValidator)) + self.assertTrue(issubclass(DatabaseBrokerSubscriberDuplicateValidator, BrokerSubscriberValidator)) async def test_query_factory(self): - validator = PostgreSqlBrokerSubscriberDuplicateValidator.from_config(self.config) + validator = DatabaseBrokerSubscriberDuplicateValidator.from_config(self.config) - self.assertIsInstance(validator.query_factory, PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory) + self.assertIsInstance(validator.query_factory, AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory) async def test_is_valid(self): one = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) two = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) three = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) - async with PostgreSqlBrokerSubscriberDuplicateValidator.from_config(self.config) as validator: + async with DatabaseBrokerSubscriberDuplicateValidator.from_config(self.config) as validator: self.assertTrue(await validator.is_valid(one)) self.assertTrue(await validator.is_valid(two)) self.assertFalse(await validator.is_valid(one)) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py index d7446dd47..fa22625f7 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py @@ -14,13 +14,13 @@ PostgresAsyncTestCase, ) from minos.networks import ( + AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerMessageV1, BrokerMessageV1Payload, BrokerSubscriberQueue, - PostgreSqlBrokerQueue, - PostgreSqlBrokerSubscriberQueue, - PostgreSqlBrokerSubscriberQueueBuilder, - PostgreSqlBrokerSubscriberQueueQueryFactory, + DatabaseBrokerQueue, + DatabaseBrokerSubscriberQueue, + DatabaseBrokerSubscriberQueueBuilder, ) from tests.utils import ( FakeAsyncIterator, @@ -30,17 +30,17 @@ class TestPostgreSqlBrokerSubscriberQueue(NetworksTestCase, PostgresAsyncTestCase): def test_is_subclass(self): - self.assertTrue(issubclass(PostgreSqlBrokerSubscriberQueue, (PostgreSqlBrokerQueue, BrokerSubscriberQueue))) + self.assertTrue(issubclass(DatabaseBrokerSubscriberQueue, (DatabaseBrokerQueue, BrokerSubscriberQueue))) async def test_query_factory(self): - queue = PostgreSqlBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) + queue = DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) - self.assertIsInstance(queue.query_factory, PostgreSqlBrokerSubscriberQueueQueryFactory) + self.assertIsInstance(queue.query_factory, AiopgBrokerSubscriberQueueDatabaseOperationFactory) async def test_enqueue(self): message = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) - async with PostgreSqlBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: + async with DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: await queue.enqueue(message) await sleep(0.5) # To give time to consume the message from db. @@ -55,7 +55,7 @@ async def test_dequeue_with_count(self): "fetch_all", return_value=FakeAsyncIterator([[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]]), ): - async with PostgreSqlBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: + async with DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: queue._get_count = AsyncMock(side_effect=[3, 0]) async with queue: @@ -68,7 +68,7 @@ async def test_dequeue_with_notify(self): BrokerMessageV1("foo", BrokerMessageV1Payload("bar")), BrokerMessageV1("bar", BrokerMessageV1Payload("foo")), ] - async with PostgreSqlBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: + async with DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: await queue.enqueue(messages[0]) await queue.enqueue(messages[1]) @@ -79,7 +79,7 @@ async def test_dequeue_with_notify(self): class TestPostgreSqlBrokerSubscriberQueueQueryFactory(unittest.TestCase): def setUp(self) -> None: - self.factory = PostgreSqlBrokerSubscriberQueueQueryFactory() + self.factory = AiopgBrokerSubscriberQueueDatabaseOperationFactory() def test_build_table_name(self): self.assertEqual("broker_subscriber_queue", self.factory.build_table_name()) @@ -87,10 +87,10 @@ def test_build_table_name(self): class TestPostgreSqlBrokerSubscriberQueueBuilder(NetworksTestCase, PostgresAsyncTestCase): def test_build(self): - builder = PostgreSqlBrokerSubscriberQueueBuilder().with_config(self.config).with_topics({"one", "two"}) + builder = DatabaseBrokerSubscriberQueueBuilder().with_config(self.config).with_topics({"one", "two"}) subscriber = builder.build() - self.assertIsInstance(subscriber, PostgreSqlBrokerSubscriberQueue) + self.assertIsInstance(subscriber, DatabaseBrokerSubscriberQueue) self.assertEqual({"one", "two"}, subscriber.topics) diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/publisher.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/publisher.py index e2a1cc760..5486499ae 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/publisher.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/publisher.py @@ -29,8 +29,8 @@ BrokerMessage, BrokerPublisher, BrokerPublisherBuilder, + DatabaseBrokerPublisherQueue, InMemoryBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueue, QueuedBrokerPublisher, ) @@ -52,7 +52,7 @@ def __init__(self, *args, **kwargs): @classmethod def _from_config(cls, config: Config, **kwargs) -> PostgreSqlQueuedKafkaBrokerPublisher: impl = KafkaBrokerPublisher.from_config(config, **kwargs) - queue = PostgreSqlBrokerPublisherQueue.from_config(config, **kwargs) + queue = DatabaseBrokerPublisherQueue.from_config(config, **kwargs) return cls(impl, queue, **kwargs) diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py index 6f43045d6..9c998666f 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py @@ -41,8 +41,8 @@ BrokerMessage, BrokerSubscriber, BrokerSubscriberBuilder, + DatabaseBrokerSubscriberQueueBuilder, InMemoryBrokerSubscriberQueueBuilder, - PostgreSqlBrokerSubscriberQueueBuilder, QueuedBrokerSubscriberBuilder, ) @@ -205,7 +205,7 @@ def __init__(self, *args, **kwargs): super().__init__( *args, impl_builder=KafkaBrokerSubscriberBuilder.new(), - queue_builder=PostgreSqlBrokerSubscriberQueueBuilder.new(), + queue_builder=DatabaseBrokerSubscriberQueueBuilder.new(), **kwargs, ) diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py index e0ce016ae..8d7286311 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py @@ -22,8 +22,8 @@ BrokerMessageV1, BrokerMessageV1Payload, BrokerPublisher, + DatabaseBrokerPublisherQueue, InMemoryBrokerPublisherQueue, - PostgreSqlBrokerPublisherQueue, ) from minos.plugins.kafka import ( InMemoryQueuedKafkaBrokerPublisher, @@ -163,7 +163,7 @@ def test_from_config(self): publisher = PostgreSqlQueuedKafkaBrokerPublisher.from_config(CONFIG_FILE_PATH) self.assertIsInstance(publisher, PostgreSqlQueuedKafkaBrokerPublisher) self.assertIsInstance(publisher.impl, KafkaBrokerPublisher) - self.assertIsInstance(publisher.queue, PostgreSqlBrokerPublisherQueue) + self.assertIsInstance(publisher.queue, DatabaseBrokerPublisherQueue) class TestInMemoryQueuedKafkaBrokerPublisher(unittest.IsolatedAsyncioTestCase): diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py index f4d615381..393c951f6 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py @@ -29,8 +29,8 @@ BrokerMessageV1, BrokerMessageV1Payload, BrokerSubscriber, + DatabaseBrokerSubscriberQueue, InMemoryBrokerSubscriberQueue, - PostgreSqlBrokerSubscriberQueue, QueuedBrokerSubscriber, ) from minos.plugins.kafka import ( @@ -267,7 +267,7 @@ def test_build(self): self.assertIsInstance(subscriber, QueuedBrokerSubscriber) self.assertIsInstance(subscriber.impl, KafkaBrokerSubscriber) - self.assertIsInstance(subscriber.queue, PostgreSqlBrokerSubscriberQueue) + self.assertIsInstance(subscriber.queue, DatabaseBrokerSubscriberQueue) class TestInMemoryQueuedKafkaBrokerSubscriberBuilder(unittest.TestCase): From f6a02258a1b3062759c32934d72d1c0d442ac8dc Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Wed, 6 Apr 2022 17:10:24 +0200 Subject: [PATCH 153/324] ISSUE #373 --- .../minos/networks/decorators/definitions/abc.py | 3 +++ .../networks/decorators/definitions/http/abc.py | 3 ++- .../minos/networks/discovery/connectors.py | 3 ++- .../test_networks/test_decorators/test_api.py | 13 +++++++++++++ .../test_decorators/test_collectors.py | 13 ++++++++++++- .../minos-microservice-networks/tests/utils.py | 9 +++++++++ .../minos/plugins/graphql/decorators.py | 3 ++- .../tests/test_graphql/test_decorators.py | 15 +++++++++++++++ .../plugins/minos-router-graphql/tests/utils.py | 12 ++++++++++++ 9 files changed, 70 insertions(+), 4 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/abc.py b/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/abc.py index be8f8d411..7f43c15ec 100644 --- a/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/abc.py @@ -30,6 +30,9 @@ class EnrouteDecorator(ABC): # noinspection PyFinal KIND: Final[EnrouteDecoratorKind] + def __init__(self, **kwargs): + self.kwargs = kwargs + def __call__(self, func: Union[Handler, HandlerWrapper]) -> HandlerWrapper: if isinstance(func, HandlerWrapper): meta = func.meta diff --git a/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/http/abc.py b/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/http/abc.py index c41b164c3..6b13676ce 100644 --- a/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/http/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/http/abc.py @@ -12,7 +12,8 @@ class HttpEnrouteDecorator(EnrouteDecorator): """Http Enroute Decorator class.""" - def __init__(self, path: Optional[str] = None, method: Optional[str] = None, url: Optional[str] = None): + def __init__(self, path: Optional[str] = None, method: Optional[str] = None, url: Optional[str] = None, **kwargs): + super().__init__(**kwargs) if path is None and url is not None: warnings.warn("The 'url' argument has been deprecated. 'path' must be used.", DeprecationWarning) path = url diff --git a/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py b/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py index 960639e09..4da9ec244 100644 --- a/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py +++ b/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py @@ -104,7 +104,8 @@ def _endpoints_from_config(config: Config) -> list[dict[str, Any]]: for name in config.get_services(): decorators = EnrouteCollector(name, config).get_rest_command_query() endpoints += [ - {"url": decorator.url, "method": decorator.method} for decorator in set(chain(*decorators.values())) + {"url": decorator.url, "method": decorator.method} | decorator.kwargs for decorator in + set(chain(*decorators.values())) ] endpoints.sort(key=itemgetter("url", "method")) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py index 075c7c5f3..077701675 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py @@ -16,10 +16,23 @@ def test_rest_command(self): decorator = enroute.rest.command(path="tickets/", method="GET") self.assertEqual(RestCommandEnrouteDecorator("tickets/", "GET"), decorator) + def test_rest_command_kwargs(self): + decorator = enroute.rest.command(path="tickets/", method="GET", authorized=True, + allowed_groups=['super_admin', 'admin', ]) + self.assertEqual( + RestCommandEnrouteDecorator("tickets/", "GET", authorized=True, allowed_groups=['super_admin', 'admin', ]), + decorator) + def test_rest_query(self): decorator = enroute.rest.query(path="tickets/", method="GET") self.assertEqual(RestQueryEnrouteDecorator("tickets/", "GET"), decorator) + def test_rest_query_kwargs(self): + decorator = enroute.rest.query(path="tickets/", method="GET", authorized=True, + allowed_groups=['super_admin', 'admin', ]) + self.assertEqual(RestQueryEnrouteDecorator("tickets/", "GET", authorized=True, + allowed_groups=['super_admin', 'admin', ]), decorator) + def test_rest_event_raises(self): with self.assertRaises(AttributeError): enroute.rest.event("CreateTicket") diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py index c7e520d16..cf6f88f15 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py @@ -14,7 +14,7 @@ ) from tests.utils import ( FakeService, - FakeServiceWithGetEnroute, + FakeServiceWithGetEnroute, FakeServiceWithKwargs, ) @@ -57,6 +57,17 @@ def test_get_rest_command_query(self): self.assertEqual(expected, observed) + def test_get_rest_command_query_kwargs(self): + analyzer = EnrouteCollector(FakeServiceWithKwargs) + + observed = analyzer.get_rest_command_query() + expected = { + "get_tickets": {RestQueryEnrouteDecorator("tickets/", "GET", authorized=True, + allowed_groups=['super_admin', 'admin', ])}, + } + + self.assertEqual(expected, observed) + def test_get_broker_command_query_event(self): analyzer = EnrouteCollector(FakeService) diff --git a/packages/core/minos-microservice-networks/tests/utils.py b/packages/core/minos-microservice-networks/tests/utils.py index bf0e2bea9..42c0fad67 100644 --- a/packages/core/minos-microservice-networks/tests/utils.py +++ b/packages/core/minos-microservice-networks/tests/utils.py @@ -171,6 +171,15 @@ def bar(self, request: Request): return Response("bar") +class FakeServiceWithKwargs: + """For testing purposes.""" + + @enroute.rest.query(path="tickets/", method="GET", authorized=True, allowed_groups=['super_admin', 'admin', ]) + @enroute.broker.query(topic="GetTickets") + async def get_tickets(self, request: Request) -> Response: + """For testing purposes.""" + return Response(": ".join(("Get Tickets", await request.content()))) + class FakeServiceWithGetEnroute: """For testing purposes.""" diff --git a/packages/plugins/minos-router-graphql/minos/plugins/graphql/decorators.py b/packages/plugins/minos-router-graphql/minos/plugins/graphql/decorators.py index 88161605c..a522794fc 100644 --- a/packages/plugins/minos-router-graphql/minos/plugins/graphql/decorators.py +++ b/packages/plugins/minos-router-graphql/minos/plugins/graphql/decorators.py @@ -19,7 +19,8 @@ class GraphQlEnrouteDecorator(EnrouteDecorator, ABC): """GraphQl Enroute Decorator class""" - def __init__(self, name: str, output, argument: Optional = None): + def __init__(self, name: str, output, argument: Optional = None, **kwargs): + super().__init__(**kwargs) self.name = name self.argument = argument self.output = output diff --git a/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py b/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py index d3e59e1c5..99e6974ac 100644 --- a/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py +++ b/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py @@ -16,6 +16,7 @@ ) from tests.utils import ( FakeQueryService, + FakeQueryService2, ) @@ -36,6 +37,20 @@ def test_get_all_queries(self): self.assertEqual(expected, observed) + def test_get_all_queries_with_kwargs(self): + analyzer = EnrouteCollector(FakeQueryService2) + observed = analyzer.get_all() + + expected = { + "get_order": { + GraphQlQueryEnrouteDecorator(name="order", argument=GraphQLField(GraphQLString), output=GraphQLString, + authorized=True, + allowed_groups=['super_admin', 'admin', ]) + }, + } + + self.assertEqual(expected, observed) + if __name__ == "__main__": unittest.main() diff --git a/packages/plugins/minos-router-graphql/tests/utils.py b/packages/plugins/minos-router-graphql/tests/utils.py index 1963f10da..1740d20db 100644 --- a/packages/plugins/minos-router-graphql/tests/utils.py +++ b/packages/plugins/minos-router-graphql/tests/utils.py @@ -79,6 +79,18 @@ def get_order(self, request: Request): return "eu38hj32-889283-j2jjb5kl" +class FakeQueryService2: + """For testng purposes.""" + + # noinspection PyUnusedLocal + @enroute.graphql.query(name="order", argument=GraphQLField(GraphQLString), output=GraphQLString, authorized=True, + allowed_groups=['supèr_admin', 'admin', ]) + def get_order(self, request: Request): + """For testng purposes.""" + + return "eu38hj32-889283-j2jjb5kl" + + user_type = GraphQLObjectType( "UserType", { From cf0117e4d8863566034ef72eefadc9d2464eb839 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Wed, 6 Apr 2022 15:12:01 +0000 Subject: [PATCH 154/324] Restyled by black --- .../minos/networks/discovery/connectors.py | 4 +- .../test_networks/test_decorators/test_api.py | 49 ++++++++++++++++--- .../test_decorators/test_collectors.py | 16 ++++-- .../tests/utils.py | 11 ++++- .../tests/test_graphql/test_decorators.py | 13 +++-- .../minos-router-graphql/tests/utils.py | 12 ++++- 6 files changed, 86 insertions(+), 19 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py b/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py index 4da9ec244..bb4acef18 100644 --- a/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py +++ b/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py @@ -104,8 +104,8 @@ def _endpoints_from_config(config: Config) -> list[dict[str, Any]]: for name in config.get_services(): decorators = EnrouteCollector(name, config).get_rest_command_query() endpoints += [ - {"url": decorator.url, "method": decorator.method} | decorator.kwargs for decorator in - set(chain(*decorators.values())) + {"url": decorator.url, "method": decorator.method} | decorator.kwargs + for decorator in set(chain(*decorators.values())) ] endpoints.sort(key=itemgetter("url", "method")) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py index 077701675..ac9ba4ac4 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py @@ -17,21 +17,54 @@ def test_rest_command(self): self.assertEqual(RestCommandEnrouteDecorator("tickets/", "GET"), decorator) def test_rest_command_kwargs(self): - decorator = enroute.rest.command(path="tickets/", method="GET", authorized=True, - allowed_groups=['super_admin', 'admin', ]) + decorator = enroute.rest.command( + path="tickets/", + method="GET", + authorized=True, + allowed_groups=[ + "super_admin", + "admin", + ], + ) self.assertEqual( - RestCommandEnrouteDecorator("tickets/", "GET", authorized=True, allowed_groups=['super_admin', 'admin', ]), - decorator) + RestCommandEnrouteDecorator( + "tickets/", + "GET", + authorized=True, + allowed_groups=[ + "super_admin", + "admin", + ], + ), + decorator, + ) def test_rest_query(self): decorator = enroute.rest.query(path="tickets/", method="GET") self.assertEqual(RestQueryEnrouteDecorator("tickets/", "GET"), decorator) def test_rest_query_kwargs(self): - decorator = enroute.rest.query(path="tickets/", method="GET", authorized=True, - allowed_groups=['super_admin', 'admin', ]) - self.assertEqual(RestQueryEnrouteDecorator("tickets/", "GET", authorized=True, - allowed_groups=['super_admin', 'admin', ]), decorator) + decorator = enroute.rest.query( + path="tickets/", + method="GET", + authorized=True, + allowed_groups=[ + "super_admin", + "admin", + ], + ) + self.assertEqual( + RestQueryEnrouteDecorator( + "tickets/", + "GET", + authorized=True, + allowed_groups=[ + "super_admin", + "admin", + ], + ), + decorator, + ) def test_rest_event_raises(self): with self.assertRaises(AttributeError): diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py index cf6f88f15..703c19086 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py @@ -14,7 +14,8 @@ ) from tests.utils import ( FakeService, - FakeServiceWithGetEnroute, FakeServiceWithKwargs, + FakeServiceWithGetEnroute, + FakeServiceWithKwargs, ) @@ -62,8 +63,17 @@ def test_get_rest_command_query_kwargs(self): observed = analyzer.get_rest_command_query() expected = { - "get_tickets": {RestQueryEnrouteDecorator("tickets/", "GET", authorized=True, - allowed_groups=['super_admin', 'admin', ])}, + "get_tickets": { + RestQueryEnrouteDecorator( + "tickets/", + "GET", + authorized=True, + allowed_groups=[ + "super_admin", + "admin", + ], + ) + }, } self.assertEqual(expected, observed) diff --git a/packages/core/minos-microservice-networks/tests/utils.py b/packages/core/minos-microservice-networks/tests/utils.py index 42c0fad67..a4521c97b 100644 --- a/packages/core/minos-microservice-networks/tests/utils.py +++ b/packages/core/minos-microservice-networks/tests/utils.py @@ -174,12 +174,21 @@ def bar(self, request: Request): class FakeServiceWithKwargs: """For testing purposes.""" - @enroute.rest.query(path="tickets/", method="GET", authorized=True, allowed_groups=['super_admin', 'admin', ]) + @enroute.rest.query( + path="tickets/", + method="GET", + authorized=True, + allowed_groups=[ + "super_admin", + "admin", + ], + ) @enroute.broker.query(topic="GetTickets") async def get_tickets(self, request: Request) -> Response: """For testing purposes.""" return Response(": ".join(("Get Tickets", await request.content()))) + class FakeServiceWithGetEnroute: """For testing purposes.""" diff --git a/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py b/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py index 99e6974ac..b6dfcddbb 100644 --- a/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py +++ b/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py @@ -43,9 +43,16 @@ def test_get_all_queries_with_kwargs(self): expected = { "get_order": { - GraphQlQueryEnrouteDecorator(name="order", argument=GraphQLField(GraphQLString), output=GraphQLString, - authorized=True, - allowed_groups=['super_admin', 'admin', ]) + GraphQlQueryEnrouteDecorator( + name="order", + argument=GraphQLField(GraphQLString), + output=GraphQLString, + authorized=True, + allowed_groups=[ + "super_admin", + "admin", + ], + ) }, } diff --git a/packages/plugins/minos-router-graphql/tests/utils.py b/packages/plugins/minos-router-graphql/tests/utils.py index 1740d20db..f4f31389d 100644 --- a/packages/plugins/minos-router-graphql/tests/utils.py +++ b/packages/plugins/minos-router-graphql/tests/utils.py @@ -83,8 +83,16 @@ class FakeQueryService2: """For testng purposes.""" # noinspection PyUnusedLocal - @enroute.graphql.query(name="order", argument=GraphQLField(GraphQLString), output=GraphQLString, authorized=True, - allowed_groups=['supèr_admin', 'admin', ]) + @enroute.graphql.query( + name="order", + argument=GraphQLField(GraphQLString), + output=GraphQLString, + authorized=True, + allowed_groups=[ + "supèr_admin", + "admin", + ], + ) def get_order(self, request: Request): """For testng purposes.""" From e5fa8dc4790b3985bcd9ce1cbbc3ab8560c58bd1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 18:03:39 +0200 Subject: [PATCH 155/324] ISSUE #371 * Improve `DatabaseLock`. * Refactor `DatabaseClient.execute` method. --- .../events/repositories/database/impl.py | 7 +- .../aggregate/snapshots/database/readers.py | 10 +-- .../aggregate/snapshots/database/writers.py | 20 +++--- .../repositories/database/impl.py | 4 +- .../test_events/test_repositories/test_pg.py | 4 +- .../test_snapshots/test_pg/test_abc.py | 7 +- .../test_repositories/test_pg.py | 4 +- .../minos/common/database/__init__.py | 2 + .../minos/common/database/abc.py | 45 ++++++++----- .../minos/common/database/clients/abc.py | 21 +++--- .../minos/common/database/clients/aiopg.py | 39 ++++------- .../minos/common/database/locks.py | 42 ------------ .../minos/common/database/locks/__init__.py | 8 +++ .../database/locks/factories/__init__.py | 6 ++ .../common/database/locks/factories/abc.py | 20 ++++++ .../common/database/locks/factories/aiopg.py | 19 ++++++ .../minos/common/database/locks/impl.py | 66 +++++++++++++++++++ .../minos/common/database/operations/aiopg.py | 7 +- .../minos/common/testing.py | 10 ++- .../test_common/test_database/test_abc.py | 56 +++++++++++----- .../test_database/test_clients/test_abc.py | 11 +++- .../test_database/test_clients/test_aiopg.py | 34 ++++++---- .../collections/queues/database/impl.py | 6 +- .../queued/queues/database/impl.py | 4 +- 24 files changed, 286 insertions(+), 166 deletions(-) delete mode 100644 packages/core/minos-microservice-common/minos/common/database/locks.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/locks/__init__.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/locks/impl.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index d20609585..1bc4c3316 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -82,15 +82,16 @@ async def _build_submit_operation(self, entry: EventEntry) -> DatabaseOperation: return self.operation_factory.build_submit_row(transaction_uuids=transaction_uuids, **entry.as_raw(), lock=lock) - async def _select(self, **kwargs) -> AsyncIterator[EventEntry]: + async def _select(self, streaming_mode: Optional[bool] = None, **kwargs) -> AsyncIterator[EventEntry]: operation = self.operation_factory.build_select_rows(**kwargs) - async for row in self.submit_query_and_iter(operation, **kwargs): + async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): yield EventEntry(*row) @property async def _offset(self) -> int: operation = self.operation_factory.build_select_max_id() - return (await self.submit_query_and_fetchone(operation))[0] or 0 + row = await self.submit_query_and_fetchone(operation) + return row[0] or 0 class PostgreSqlEventRepository(DatabaseEventRepository): diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py index 85f49892f..d5c0a0fa8 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py @@ -89,6 +89,7 @@ async def find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: async for snapshot_entry in self.find_entries(*args, **kwargs): yield snapshot_entry.build(**kwargs) + # noinspection PyUnusedLocal async def find_entries( self, name: str, @@ -127,13 +128,8 @@ async def find_entries( name, condition, ordering, limit, transaction_uuids, exclude_deleted ) - async_iterable = self.submit_query_and_iter(operation) - if streaming_mode: - async for row in async_iterable: - yield SnapshotEntry(*row) - else: - for row in [row async for row in async_iterable]: - yield SnapshotEntry(*row) + async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): + yield SnapshotEntry(*row) class PostgreSqlSnapshotReader(DatabaseSnapshotReader): diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py index 9333cab95..ee60cc60b 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py @@ -77,7 +77,7 @@ async def is_synced(self, name: str, **kwargs) -> bool: :param name: Class name of the ``RootEntity`` to be checked. :return: ``True`` if it has the latest version for the identifier or ``False`` otherwise. """ - offset = await self._load_offset(**kwargs) + offset = await self._load_offset() iterable = self._event_repository.select(id_gt=offset, name=name, **kwargs) try: await iterable.__anext__() @@ -90,7 +90,7 @@ async def dispatch(self, **kwargs) -> None: :return: This method does not return anything. """ - initial_offset = await self._load_offset(**kwargs) + initial_offset = await self._load_offset() offset = initial_offset async for event_entry in self._event_repository.select(id_gt=offset, **kwargs): @@ -105,11 +105,11 @@ async def dispatch(self, **kwargs) -> None: await self._store_offset(offset) - async def _load_offset(self, **kwargs) -> int: + async def _load_offset(self) -> int: operation = self.operation_factory.build_get_offset() # noinspection PyBroadException try: - raw = await self.submit_query_and_fetchone(operation, **kwargs) + raw = await self.submit_query_and_fetchone(operation) return raw[0] except Exception: return 0 @@ -120,20 +120,20 @@ async def _store_offset(self, offset: int) -> None: async def _dispatch_one(self, event_entry: EventEntry, **kwargs) -> SnapshotEntry: if event_entry.action.is_delete: - return await self._submit_delete(event_entry, **kwargs) + return await self._submit_delete(event_entry) return await self._submit_update_or_create(event_entry, **kwargs) - async def _submit_delete(self, event_entry: EventEntry, **kwargs) -> SnapshotEntry: + async def _submit_delete(self, event_entry: EventEntry) -> SnapshotEntry: snapshot_entry = SnapshotEntry.from_event_entry(event_entry) - snapshot_entry = await self._submit_entry(snapshot_entry, **kwargs) + snapshot_entry = await self._submit_entry(snapshot_entry) return snapshot_entry async def _submit_update_or_create(self, event_entry: EventEntry, **kwargs) -> SnapshotEntry: instance = await self._build_instance(event_entry, **kwargs) snapshot_entry = SnapshotEntry.from_root_entity(instance, transaction_uuid=event_entry.transaction_uuid) - snapshot_entry = await self._submit_entry(snapshot_entry, **kwargs) + snapshot_entry = await self._submit_entry(snapshot_entry) return snapshot_entry async def _build_instance(self, event_entry: EventEntry, **kwargs) -> RootEntity: @@ -167,9 +167,9 @@ async def _select_one_instance(self, name: str, uuid: UUID, **kwargs) -> RootEnt snapshot_entry = await self._reader.get_entry(name, uuid, **kwargs) return snapshot_entry.build(**kwargs) - async def _submit_entry(self, snapshot_entry: SnapshotEntry, **kwargs) -> SnapshotEntry: + async def _submit_entry(self, snapshot_entry: SnapshotEntry) -> SnapshotEntry: operation = self.operation_factory.build_insert(**snapshot_entry.as_raw()) - response = await self.submit_query_and_fetchone(operation, **kwargs) + response = await self.submit_query_and_fetchone(operation) snapshot_entry.created_at, snapshot_entry.updated_at = response diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index 1d0309276..74a145629 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -63,9 +63,9 @@ async def _submit(self, transaction: TransactionEntry) -> TransactionEntry: transaction.updated_at = updated_at return transaction - async def _select(self, **kwargs) -> AsyncIterator[TransactionEntry]: + async def _select(self, streaming_mode: Optional[bool] = None, **kwargs) -> AsyncIterator[TransactionEntry]: operation = self.operation_factory.build_select_rows(**kwargs) - async for row in self.submit_query_and_iter(operation, **kwargs): + async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): yield TransactionEntry(*row, transaction_repository=self) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index 0b1a24113..ba1556169 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -6,6 +6,7 @@ ) from minos.common import ( AiopgDatabaseClient, + AiopgDatabaseOperation, DatabaseClientPool, ) from minos.common.testing import ( @@ -38,9 +39,10 @@ def test_from_config(self): async def test_setup(self): async with AiopgDatabaseClient(**self.config.get_default_database()) as client: - await client.execute( + operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_event');" ) + await client.execute(operation) response = (await client.fetch_one())[0] self.assertTrue(response) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py index 9009a6ce3..e673be946 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py @@ -5,6 +5,7 @@ ) from minos.common import ( AiopgDatabaseClient, + AiopgDatabaseOperation, ) from minos.common.testing import ( PostgresAsyncTestCase, @@ -19,19 +20,21 @@ class TestPostgreSqlSnapshotSetup(AggregateTestCase, PostgresAsyncTestCase): async def test_setup_snapshot_table(self): async with DatabaseSnapshotSetup.from_config(self.config): async with AiopgDatabaseClient(**self.config.get_default_database()) as client: - await client.execute( + operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM pg_tables WHERE schemaname = 'public' AND tablename = 'snapshot');" ) + await client.execute(operation) observed = (await client.fetch_one())[0] self.assertEqual(True, observed) async def test_setup_snapshot_aux_offset_table(self): async with DatabaseSnapshotSetup.from_config(self.config): async with AiopgDatabaseClient(**self.config.get_default_database()) as client: - await client.execute( + operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM pg_tables WHERE " "schemaname = 'public' AND tablename = 'snapshot_aux_offset');" ) + await client.execute(operation) observed = (await client.fetch_one())[0] self.assertEqual(True, observed) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index f5c38bf83..a9dc0dab5 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -12,6 +12,7 @@ ) from minos.common import ( AiopgDatabaseClient, + AiopgDatabaseOperation, DatabaseClientPool, ) from minos.common.testing import ( @@ -54,9 +55,10 @@ def test_from_config(self): async def test_setup(self): async with AiopgDatabaseClient(**self.config.get_default_database()) as client: - await client.execute( + operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_transaction');" ) + await client.execute(operation) response = (await client.fetch_one())[0] self.assertTrue(response) diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index 3f38227e0..3f21830f6 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -11,7 +11,9 @@ UnableToConnectException, ) from .locks import ( + AiopgLockDatabaseOperationFactory, DatabaseLock, + LockDatabaseOperationFactory, PostgreSqlLock, ) from .operations import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 9c06a070b..760c5ee5c 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -16,6 +16,9 @@ from ..setup import ( SetupMixin, ) +from .operations import ( + DatabaseOperation, +) from .pools import ( DatabaseClientPool, PostgreSqlPool, @@ -48,40 +51,52 @@ def __init__( self._pool = database_pool - async def submit_query_and_fetchone(self, *args, **kwargs) -> tuple: + async def submit_query_and_fetchone(self, operation: DatabaseOperation) -> tuple: """Submit a SQL query and gets the first response. - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. + :param operation: TODO :return: This method does not return anything. """ async with self.pool.acquire() as client: - await client.execute(*args, **kwargs) - return await client.fetch_one(*args, **kwargs) + await client.execute(operation) + return await client.fetch_one() # noinspection PyUnusedLocal - async def submit_query_and_iter(self, *args, **kwargs) -> AsyncIterator[tuple]: + async def submit_query_and_iter( + self, operation: DatabaseOperation, streaming_mode: Optional[bool] = None + ) -> AsyncIterator[tuple]: """Submit a SQL query and return an asynchronous iterator. - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. + :param operation: TODO + :param streaming_mode: If ``True`` return the values in streaming directly from the database (keep an open + database connection), otherwise preloads the full set of values on memory and then retrieves them. :return: This method does not return anything. """ + if streaming_mode is None: + streaming_mode = False + async with self.pool.acquire() as client: - await client.execute(*args, **kwargs) - async for value in client.fetch_all(*args, **kwargs): - yield value + await client.execute(operation) + async_iterable = client.fetch_all() + if streaming_mode: + async for value in async_iterable: + yield value + return + + iterable = [value async for value in async_iterable] + + for value in iterable: + yield value # noinspection PyUnusedLocal - async def submit_query(self, *args, **kwargs) -> None: + async def submit_query(self, operation: DatabaseOperation) -> None: """Submit a SQL query. - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. + :param operation: TODO :return: This method does not return anything. """ async with self.pool.acquire() as client: - return await client.execute(*args, **kwargs) + return await client.execute(operation) @property def pool(self) -> DatabaseClientPool: diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index b2418a4c0..30c93e7ef 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -57,40 +57,35 @@ async def reset(self, **kwargs) -> None: async def _reset(self, **kwargs) -> None: raise NotImplementedError - async def execute(self, operation: DatabaseOperation, *args, **kwargs) -> None: + async def execute(self, operation: DatabaseOperation) -> None: """Execute an operation. :param operation: TODO - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. :return: This method does not return anything. """ if isinstance(operation, ComposedDatabaseOperation): for op in operation.operations: - await self._execute(op, *args, **kwargs) + await self._execute(op) else: - await self._execute(operation, *args, **kwargs) + await self._execute(operation) @abstractmethod - async def _execute(self, *args, **kwargs) -> None: + async def _execute(self, operation: DatabaseOperation) -> None: raise NotImplementedError - async def fetch_one(self, *args, **kwargs) -> Any: + async def fetch_one(self) -> Any: """Fetch one value. - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. :return: This method does not return anything. """ - return await self.fetch_all(*args, **kwargs).__anext__() + return await self.fetch_all().__anext__() - def fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: + def fetch_all(self) -> AsyncIterator[Any]: """Fetch all values with an asynchronous iterator. - :param kwargs: Additional named arguments. :return: This method does not return anything. """ - return self._fetch_all(*args, **kwargs) + return self._fetch_all() @abstractmethod def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index 695fc3cb7..d0078bdbb 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -9,9 +9,7 @@ ) from typing import ( TYPE_CHECKING, - Any, Optional, - Union, ) import aiopg @@ -23,13 +21,9 @@ IntegrityError, OperationalError, ) -from psycopg2.sql import ( - Composable, -) from ..operations import ( AiopgDatabaseOperation, - DatabaseOperation, ) from .abc import ( DatabaseClient, @@ -129,35 +123,24 @@ async def _reset(self, **kwargs) -> None: await self._destroy_cursor(**kwargs) # noinspection PyUnusedLocal - async def _fetch_all( - self, - *args, - **kwargs, - ) -> AsyncIterator[tuple]: + async def _fetch_all(self) -> AsyncIterator[tuple]: await self._create_cursor() async for row in self._cursor: yield row # noinspection PyUnusedLocal - async def _execute( - self, - operation: Union[str, Composable, AiopgDatabaseOperation], - parameters: Any = None, - *, - timeout: Optional[float] = None, - lock: Any = None, - **kwargs, - ) -> None: - if isinstance(operation, DatabaseOperation): - if isinstance(operation, AiopgDatabaseOperation): - operation, parameters, lock = operation.query, operation.parameters, operation.lock - else: - raise ValueError(f"The operation is not supported: {operation!r}") - - await self._create_cursor(lock=lock) + async def _execute(self, operation: AiopgDatabaseOperation) -> None: + if not isinstance(operation, AiopgDatabaseOperation): + raise ValueError(f"The operation is not supported: {operation!r}") + + await self._create_cursor(lock=operation.lock) try: - await self._cursor.execute(operation=operation, parameters=parameters, timeout=timeout) + await self._cursor.execute( + operation=operation.query, + parameters=operation.parameters, + timeout=operation.timeout, + ) except IntegrityError as exc: raise IntegrityException(f"The requested operation raised a integrity error: {exc!r}") diff --git a/packages/core/minos-microservice-common/minos/common/database/locks.py b/packages/core/minos-microservice-common/minos/common/database/locks.py deleted file mode 100644 index 1a0a8ae18..000000000 --- a/packages/core/minos-microservice-common/minos/common/database/locks.py +++ /dev/null @@ -1,42 +0,0 @@ -import warnings -from collections.abc import ( - Hashable, -) - -from ..locks import ( - Lock, -) -from .clients import ( - DatabaseClient, -) - - -class DatabaseLock(Lock): - """Database Lock class.""" - - def __init__(self, client: DatabaseClient, key: Hashable, *args, **kwargs): - super().__init__(key, *args, **kwargs) - - self.client = client - - async def acquire(self) -> None: - """Acquire the lock. - - :return: This method does not return anything. - """ - await self.client.execute("select pg_advisory_lock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) - - async def release(self) -> None: - """Release the lock. - - :return: This method does not return anything. - """ - await self.client.execute("select pg_advisory_unlock(%(hashed_key)s)", {"hashed_key": self.hashed_key}) - - -class PostgreSqlLock(DatabaseLock): - """PostgreSql Lock class.""" - - def __init__(self, *args, **kwargs): - warnings.warn(f"{PostgreSqlLock!r} has been deprecated. Use {DatabaseLock} instead.", DeprecationWarning) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py b/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py new file mode 100644 index 000000000..9083f5c26 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py @@ -0,0 +1,8 @@ +from .factories import ( + AiopgLockDatabaseOperationFactory, + LockDatabaseOperationFactory, +) +from .impl import ( + DatabaseLock, + PostgreSqlLock, +) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py new file mode 100644 index 000000000..e2f0933f4 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py @@ -0,0 +1,6 @@ +from .abc import ( + LockDatabaseOperationFactory, +) +from .aiopg import ( + AiopgLockDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py new file mode 100644 index 000000000..d1591aebd --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py @@ -0,0 +1,20 @@ +from abc import ( + ABC, + abstractmethod, +) + +from ...operations import ( + DatabaseOperation, +) + + +class LockDatabaseOperationFactory(ABC): + """TODO""" + + @abstractmethod + def build_acquire(self, hashed_key: int) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_release(self, hashed_key: int) -> DatabaseOperation: + """TODO""" diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py new file mode 100644 index 000000000..e5515da33 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py @@ -0,0 +1,19 @@ +from ...operations import ( + AiopgDatabaseOperation, + DatabaseOperation, +) +from .abc import ( + LockDatabaseOperationFactory, +) + + +class AiopgLockDatabaseOperationFactory(LockDatabaseOperationFactory): + """TODO""" + + def build_acquire(self, hashed_key: int) -> DatabaseOperation: + """TODO""" + return AiopgDatabaseOperation("select pg_advisory_lock(%(hashed_key)s)", {"hashed_key": hashed_key}) + + def build_release(self, hashed_key: int) -> DatabaseOperation: + """TODO""" + return AiopgDatabaseOperation("select pg_advisory_unlock(%(hashed_key)s)", {"hashed_key": hashed_key}) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/impl.py b/packages/core/minos-microservice-common/minos/common/database/locks/impl.py new file mode 100644 index 000000000..9a5e72078 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/locks/impl.py @@ -0,0 +1,66 @@ +from __future__ import ( + annotations, +) + +import warnings +from collections.abc import ( + Hashable, +) + +from pyparsing import ( + Optional, +) + +from ...locks import ( + Lock, +) +from ..clients import ( + DatabaseClient, +) +from .factories import ( + AiopgLockDatabaseOperationFactory, + LockDatabaseOperationFactory, +) + + +class DatabaseLock(Lock): + """Database Lock class.""" + + def __init__( + self, + client: DatabaseClient, + key: Hashable, + *args, + operation_factory: Optional[LockDatabaseOperationFactory] = None, + **kwargs, + ): + super().__init__(key, *args, **kwargs) + if operation_factory is None: + operation_factory = AiopgLockDatabaseOperationFactory() + + self.client = client + self.operation_factory = operation_factory + + async def acquire(self) -> None: + """Acquire the lock. + + :return: This method does not return anything. + """ + operation = self.operation_factory.build_acquire(self.hashed_key) + await self.client.execute(operation) + + async def release(self) -> None: + """Release the lock. + + :return: This method does not return anything. + """ + operation = self.operation_factory.build_release(self.hashed_key) + await self.client.execute(operation) + + +class PostgreSqlLock(DatabaseLock): + """PostgreSql Lock class.""" + + def __init__(self, *args, **kwargs): + warnings.warn(f"{PostgreSqlLock!r} has been deprecated. Use {DatabaseLock} instead.", DeprecationWarning) + super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py index e724c5337..818367b99 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py @@ -20,10 +20,15 @@ class AiopgDatabaseOperation(DatabaseOperation): """TODO""" def __init__( - self, query: Union[str, Composable], parameters: dict[str, Any] = None, lock: Optional[Hashable] = None + self, + query: Union[str, Composable], + parameters: dict[str, Any] = None, + lock: Optional[Hashable] = None, + timeout: Optional[float] = None, ): if parameters is None: parameters = dict() self.query = query self.parameters = parameters self.lock = lock + self.timeout = timeout diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index 6bbdba801..ef1402df5 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -16,6 +16,10 @@ uuid4, ) +from minos.common import ( + AiopgDatabaseOperation, +) + from .config import ( Config, ) @@ -105,10 +109,12 @@ async def _create_database(self, meta: dict[str, Any], test: dict[str, Any]) -> async with AiopgDatabaseClient(**meta) as client: template = "CREATE DATABASE {database} WITH OWNER = {user};" - await client.execute(template.format(**(meta | test))) + operation = AiopgDatabaseOperation(template.format(**(meta | test))) + await client.execute(operation) @staticmethod async def _drop_database(meta: dict[str, Any], test: dict[str, Any]) -> None: async with AiopgDatabaseClient(**meta) as client: template = "DROP DATABASE IF EXISTS {database}" - await client.execute(template.format(**(meta | test))) + operation = AiopgDatabaseOperation(template.format(**(meta | test))) + await client.execute(operation) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index 5570d154a..cad8123c9 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -3,6 +3,7 @@ from minos.common import ( AiopgDatabaseClient, + AiopgDatabaseOperation, DatabaseClientPool, DatabaseMixin, NotProvidedException, @@ -51,54 +52,75 @@ async def test_pool(self): self.assertIsInstance(database.pool, DatabaseClientPool) async def test_submit_query(self): + op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);") + op2 = AiopgDatabaseOperation("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") + async with DatabaseMixin() as database: - await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") + await database.submit_query(op1) async with AiopgDatabaseClient(**self.config.get_default_database()) as client: - await client.execute("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") + await client.execute(op2) self.assertTrue((await client.fetch_one())[0]) async def test_submit_query_locked(self): + op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);", lock=1234) + op2 = AiopgDatabaseOperation("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") + async with DatabaseMixin() as database: - await database.submit_query("CREATE TABLE foo (id INT NOT NULL);", lock=1234) + await database.submit_query(op1) async with AiopgDatabaseClient(**self.config.get_default_database()) as client: - await client.execute("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") + await client.execute(op2) self.assertTrue((await client.fetch_one())[0]) async def test_submit_query_and_fetchone(self): + op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);") + op2 = AiopgDatabaseOperation("INSERT INTO foo (id) VALUES (3), (4), (5);") + op3 = AiopgDatabaseOperation("SELECT * FROM foo;") + async with DatabaseMixin() as database: - await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") - await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") + await database.submit_query(op1) + await database.submit_query(op2) - observed = await database.submit_query_and_fetchone("SELECT * FROM foo;") + observed = await database.submit_query_and_fetchone(op3) self.assertEqual((3,), observed) async def test_submit_query_and_iter(self): - async with DatabaseMixin() as database: - await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") - await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") + op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);") + op2 = AiopgDatabaseOperation("INSERT INTO foo (id) VALUES (3), (4), (5);") + op3 = AiopgDatabaseOperation("SELECT * FROM foo;") - observed = [v async for v in database.submit_query_and_iter("SELECT * FROM foo;")] + async with DatabaseMixin() as database: + await database.submit_query(op1) + await database.submit_query(op2) + observed = [v async for v in database.submit_query_and_iter(op3)] self.assertEqual([(3,), (4,), (5,)], observed) async def test_submit_query_and_iter_streaming_mode_true(self): + op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);") + op2 = AiopgDatabaseOperation("INSERT INTO foo (id) VALUES (3), (4), (5);") + op3 = AiopgDatabaseOperation("SELECT * FROM foo;") + async with DatabaseMixin() as database: - await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") - await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") + await database.submit_query(op1) + await database.submit_query(op2) - observed = [v async for v in database.submit_query_and_iter("SELECT * FROM foo;", streaming_mode=True)] + observed = [v async for v in database.submit_query_and_iter(op3, streaming_mode=True)] self.assertEqual([(3,), (4,), (5,)], observed) async def test_submit_query_and_iter_locked(self): + op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);", lock=1234) + op2 = AiopgDatabaseOperation("INSERT INTO foo (id) VALUES (3), (4), (5);") + op3 = AiopgDatabaseOperation("SELECT * FROM foo;") + async with DatabaseMixin() as database: - await database.submit_query("CREATE TABLE foo (id INT NOT NULL);") - await database.submit_query("INSERT INTO foo (id) VALUES (3), (4), (5);") + await database.submit_query(op1) + await database.submit_query(op2) - observed = [v async for v in database.submit_query_and_iter("SELECT * FROM foo;", lock=1234)] + observed = [v async for v in database.submit_query_and_iter(op3)] self.assertEqual([(3,), (4,), (5,)], observed) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index 69f948785..7a4457e47 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -17,6 +17,7 @@ BuildableMixin, DatabaseClient, DatabaseClientBuilder, + DatabaseOperation, ) from tests.utils import ( CommonTestCase, @@ -40,6 +41,10 @@ def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: """For testing purposes.""" +class _DatabaseOperation(DatabaseOperation): + """For testing purposes.""" + + class TestDatabaseClient(unittest.IsolatedAsyncioTestCase): def test_abstract(self): self.assertTrue(issubclass(DatabaseClient, (ABC, BuildableMixin))) @@ -73,10 +78,10 @@ async def test_execute(self): mock = AsyncMock() client = _DatabaseClient() client._execute = mock + operation = _DatabaseOperation() + await client.execute(operation) - await client.execute("foo") - - self.assertEqual([call("foo")], mock.call_args_list) + self.assertEqual([call(operation)], mock.call_args_list) async def test_fetch_all(self): mock = MagicMock(return_value=FakeAsyncIterator(["one", "two"])) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py index 1dc7f261e..bab4e15e4 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py @@ -17,6 +17,7 @@ from minos.common import ( AiopgDatabaseClient, + AiopgDatabaseOperation, DatabaseLock, IntegrityException, UnableToConnectException, @@ -33,7 +34,7 @@ class TestAiopgDatabaseClient(CommonTestCase, PostgresAsyncTestCase): def setUp(self): super().setUp() - self.sql = "SELECT * FROM information_schema.tables" + self.operation = AiopgDatabaseOperation("SELECT * FROM information_schema.tables") def test_constructor(self): client = AiopgDatabaseClient("foo") @@ -88,7 +89,7 @@ async def test_cursor(self): self.assertIsNone(client.cursor) async with client: self.assertIsNone(client.cursor) - await client.execute("SELECT * FROM information_schema.tables") + await client.execute(self.operation) self.assertIsInstance(client.cursor, Cursor) self.assertIsNone(client.cursor) @@ -96,24 +97,26 @@ async def test_cursor(self): async def test_cursor_reset(self): client = AiopgDatabaseClient.from_config(self.config) async with client: - await client.execute("SELECT * FROM information_schema.tables") + await client.execute(self.operation) self.assertIsInstance(client.cursor, Cursor) await client.reset() self.assertIsNone(client.cursor) async def test_lock(self): + op1 = AiopgDatabaseOperation("SELECT * FROM information_schema.tables", lock="foo") client = AiopgDatabaseClient.from_config(self.config) self.assertIsNone(client.lock) async with client: self.assertIsNone(client.lock) - await client.execute(self.sql, lock="foo") + await client.execute(op1) self.assertIsInstance(client.lock, DatabaseLock) self.assertIsNone(client.lock) async def test_lock_reset(self): + op1 = AiopgDatabaseOperation("SELECT * FROM information_schema.tables", lock="foo") async with AiopgDatabaseClient.from_config(self.config) as client: - await client.execute(self.sql, lock="foo") + await client.execute(op1) self.assertIsInstance(client.lock, DatabaseLock) await client.reset() self.assertIsNone(client.lock) @@ -121,17 +124,18 @@ async def test_lock_reset(self): async def test_execute(self): async with AiopgDatabaseClient.from_config(self.config) as client: with patch.object(Cursor, "execute") as execute_mock: - await client.execute(self.sql) + await client.execute(self.operation) self.assertEqual( - [call(operation=self.sql, parameters=None, timeout=None)], + [call(operation=self.operation.query, parameters=self.operation.parameters, timeout=None)], execute_mock.call_args_list, ) async def test_execute_with_lock(self): + op1 = AiopgDatabaseOperation("SELECT * FROM information_schema.tables", lock="foo") with patch.object(DatabaseLock, "acquire") as enter_lock_mock: with patch.object(DatabaseLock, "release") as exit_lock_mock: async with AiopgDatabaseClient.from_config(self.config) as client: - await client.execute(self.sql, lock="foo") + await client.execute(op1) self.assertEqual(1, enter_lock_mock.call_count) self.assertEqual(0, exit_lock_mock.call_count) enter_lock_mock.reset_mock() @@ -140,17 +144,19 @@ async def test_execute_with_lock(self): self.assertEqual(1, exit_lock_mock.call_count) async def test_execute_with_lock_multiple(self): + op1 = AiopgDatabaseOperation("SELECT * FROM information_schema.tables", lock="foo") + op2 = AiopgDatabaseOperation("SELECT * FROM information_schema.tables", lock="bar") async with AiopgDatabaseClient.from_config(self.config) as client: self.assertIsNone(client.lock) - await client.execute(self.sql, lock="foo") + await client.execute(op1) foo_lock = client.lock self.assertIsInstance(foo_lock, DatabaseLock) - await client.execute(self.sql, lock="foo") + await client.execute(op1) self.assertEqual(foo_lock, client.lock) - await client.execute(self.sql, lock="bar") + await client.execute(op2) self.assertNotEqual(foo_lock, client.lock) self.assertIsInstance(client.lock, DatabaseLock) @@ -158,17 +164,17 @@ async def test_execute_raises_integrity(self): async with AiopgDatabaseClient.from_config(self.config) as client: with patch.object(Cursor, "execute", side_effect=IntegrityError): with self.assertRaises(IntegrityException): - await client.execute(self.sql) + await client.execute(self.operation) async def test_fetch_one(self): async with AiopgDatabaseClient.from_config(self.config) as client: - await client.execute(self.sql) + await client.execute(self.operation) observed = await client.fetch_one() self.assertIsInstance(observed, tuple) async def test_fetch_all(self): async with AiopgDatabaseClient.from_config(self.config) as client: - await client.execute(self.sql) + await client.execute(self.operation) observed = [value async for value in client.fetch_all()] self.assertGreater(len(observed), 0) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index 11fcb0ff8..a55b6fd83 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -145,7 +145,7 @@ async def _flush_queue(self): async def _enqueue(self, message: BrokerMessage) -> None: operation = self._query_factory.build_insert(message.topic, message.avro_bytes) - await self.submit_query_and_fetchone(operation) + await self.submit_query(operation) await self._notify_enqueued(message) # noinspection PyUnusedLocal @@ -214,8 +214,8 @@ async def _dequeue_batch(self) -> None: await self._queue.put(entry) async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - # noinspection PyTypeChecker - await client.execute(self._query_factory.build_select_not_processed(self._retry, self._records)) + operation = self._query_factory.build_select_not_processed(self._retry, self._records) + await client.execute(operation) return [row async for row in client.fetch_all()] diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py index c5c8f50bf..8b13045f2 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py @@ -49,8 +49,8 @@ async def _get_count(self) -> int: return count async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - # noinspection PyTypeChecker - await client.execute(self._query_factory.build_select_not_processed(self._retry, self._records, self.topics)) + operation = self._query_factory.build_select_not_processed(self._retry, self._records, self.topics) + await client.execute(operation) return [row async for row in client.fetch_all()] From c3499b5d81647c2ef86759f23f5636d31d3bf416 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 18:23:35 +0200 Subject: [PATCH 156/324] ISSUE #371 * Rename `query_factory` as `operation_factory`. --- .../queues/database/factories/aiopg.py | 9 ------- .../collections/queues/database/impl.py | 26 +++++++++---------- .../brokers/publishers/queued/queues/pg.py | 10 ++++--- .../validators/duplicates/database/impl.py | 16 ++++++------ .../queued/queues/database/factories/abc.py | 7 ----- .../queued/queues/database/impl.py | 12 ++++----- .../test_collections/test_queues/test_pg.py | 22 ++++++++-------- .../test_queued/test_queues/test_pg.py | 4 +-- .../test_duplicates/test_pg.py | 6 +++-- .../test_queued/test_queues/test_pg.py | 4 +-- 10 files changed, 52 insertions(+), 64 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py index 11b78c25d..5823b3295 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py @@ -1,6 +1,5 @@ from abc import ( ABC, - abstractmethod, ) from collections.abc import ( Iterable, @@ -24,14 +23,6 @@ class AiopgBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): """PostgreSql Broker Queue Query Factory class.""" - @abstractmethod - def build_table_name(self) -> str: - """Get the table name. - - :return: A ``str`` value. - """ - raise NotImplementedError - def build_create_table(self) -> DatabaseOperation: """Build the "create table" query. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index a55b6fd83..d0e6a75c6 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -39,7 +39,7 @@ BrokerQueue, ) from .factories import ( - AiopgBrokerQueueDatabaseOperationFactory, + BrokerQueueDatabaseOperationFactory, ) logger = logging.getLogger(__name__) @@ -53,7 +53,7 @@ class DatabaseBrokerQueue(BrokerQueue, DatabaseMixin): def __init__( self, *args, - query_factory: AiopgBrokerQueueDatabaseOperationFactory, + operation_factory: BrokerQueueDatabaseOperationFactory, retry: Optional[int] = None, records: Optional[int] = None, **kwargs, @@ -65,7 +65,7 @@ def __init__( if records is None: records = 1000 - self._query_factory = query_factory + self._operation_factory = operation_factory self._retry = retry self._records = records @@ -91,12 +91,12 @@ def records(self) -> int: return self._records @property - def query_factory(self) -> AiopgBrokerQueueDatabaseOperationFactory: + def operation_factory(self) -> BrokerQueueDatabaseOperationFactory: """Get the query factory. :return: A ``PostgreSqlBrokerQueueQueryFactory`` instance. """ - return self._query_factory + return self._operation_factory @classmethod def _from_config(cls, config: Config, **kwargs) -> DatabaseBrokerQueue: @@ -117,7 +117,7 @@ async def _destroy(self) -> None: await super()._destroy() async def _create_table(self) -> None: - operation = self._query_factory.build_create_table() + operation = self._operation_factory.build_create_table() await self.submit_query(operation) async def _start_run(self) -> None: @@ -139,12 +139,12 @@ async def _flush_queue(self): entry = self._queue.get_nowait() except QueueEmpty: break - operation = self._query_factory.build_update_not_processed(entry.id_) + operation = self._operation_factory.build_update_not_processed(entry.id_) await self.submit_query(operation) self._queue.task_done() async def _enqueue(self, message: BrokerMessage) -> None: - operation = self._query_factory.build_insert(message.topic, message.avro_bytes) + operation = self._operation_factory.build_insert(message.topic, message.avro_bytes) await self.submit_query(operation) await self._notify_enqueued(message) @@ -163,11 +163,11 @@ async def _dequeue(self) -> BrokerMessage: logger.warning( f"There was a problem while trying to deserialize the entry with {entry.id_!r} id: {exc}" ) - operation = self._query_factory.build_update_not_processed(entry.id_) + operation = self._operation_factory.build_update_not_processed(entry.id_) await self.submit_query(operation) continue - operation = self._query_factory.build_delete_processed(entry.id_) + operation = self._operation_factory.build_delete_processed(entry.id_) await self.submit_query(operation) return message finally: @@ -192,7 +192,7 @@ async def _wait_enqueued(self) -> None: async def _get_count(self) -> int: # noinspection PyTypeChecker - operation = self._query_factory.build_count_not_processed(self.retry) + operation = self._operation_factory.build_count_not_processed(self.retry) row = await self.submit_query_and_fetchone(operation) count = row[0] return count @@ -207,14 +207,14 @@ async def _dequeue_batch(self) -> None: entries = [_Entry(*row) for row in rows] ids = tuple(entry.id_ for entry in entries) - operation = self._query_factory.build_mark_processing(ids) + operation = self._operation_factory.build_mark_processing(ids) await client.execute(operation) for entry in entries: await self._queue.put(entry) async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - operation = self._query_factory.build_select_not_processed(self._retry, self._records) + operation = self._operation_factory.build_select_not_processed(self._retry, self._records) await client.execute(operation) return [row async for row in client.fetch_all()] diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py index ed53c4861..899526965 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py @@ -27,10 +27,12 @@ class DatabaseBrokerPublisherQueue(DatabaseBrokerQueue, BrokerPublisherQueue): """PostgreSql Broker Publisher Queue class.""" - def __init__(self, *args, query_factory: Optional[BrokerPublisherQueueDatabaseOperationFactory] = None, **kwargs): - if query_factory is None: - query_factory = AiopgBrokerPublisherQueueDatabaseOperationFactory() - super().__init__(*args, query_factory=query_factory, **kwargs) + def __init__( + self, *args, operation_factory: Optional[BrokerPublisherQueueDatabaseOperationFactory] = None, **kwargs + ): + if operation_factory is None: + operation_factory = AiopgBrokerPublisherQueueDatabaseOperationFactory() + super().__init__(*args, operation_factory=operation_factory, **kwargs) class BrokerPublisherQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py index 8d8b68fc2..75e4085da 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py @@ -29,33 +29,33 @@ class DatabaseBrokerSubscriberDuplicateValidator(BrokerSubscriberDuplicateValida def __init__( self, - query_factory: Optional[AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory] = None, + operation_factory: Optional[AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory] = None, *args, **kwargs, ): - if query_factory is None: - query_factory = AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory() + if operation_factory is None: + operation_factory = AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory() super().__init__(*args, **kwargs) - self._query_factory = query_factory + self._operation_factory = operation_factory async def _setup(self) -> None: await super()._setup() await self._create_table() async def _create_table(self) -> None: - operation = self._query_factory.build_create_table() + operation = self._operation_factory.build_create_table() await self.submit_query(operation) @property - def query_factory(self) -> AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory: + def operation_factory(self) -> AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory: """Get the query factory. :return: A ``PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory`` instance. """ - return self._query_factory + return self._operation_factory async def _is_unique(self, topic: str, uuid: UUID) -> bool: - operation = self._query_factory.build_insert_row(topic, uuid) + operation = self._operation_factory.build_insert_row(topic, uuid) try: await self.submit_query(operation) return True diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py index 5478058d0..083cdd19d 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py @@ -18,13 +18,6 @@ class BrokerSubscriberQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): """PostgreSql Broker Subscriber Queue Query Factory class.""" - def build_table_name(self) -> str: - """Get the table name. - - :return: A ``str`` value. - """ - return "broker_subscriber_queue" - def build_count_not_processed( self, retry: int, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py index 8b13045f2..fbe89e448 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py @@ -34,22 +34,22 @@ def __init__( self, topics: set[str], *args, - query_factory: Optional[AiopgBrokerSubscriberQueueDatabaseOperationFactory] = None, + operation_factory: Optional[AiopgBrokerSubscriberQueueDatabaseOperationFactory] = None, **kwargs, ): - if query_factory is None: - query_factory = AiopgBrokerSubscriberQueueDatabaseOperationFactory() - super().__init__(topics, *args, query_factory=query_factory, **kwargs) + if operation_factory is None: + operation_factory = AiopgBrokerSubscriberQueueDatabaseOperationFactory() + super().__init__(topics, *args, operation_factory=operation_factory, **kwargs) async def _get_count(self) -> int: # noinspection PyTypeChecker - operation = self._query_factory.build_count_not_processed(self._retry, self.topics) + operation = self._operation_factory.build_count_not_processed(self._retry, self.topics) row = await self.submit_query_and_fetchone(operation) count = row[0] return count async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - operation = self._query_factory.build_select_not_processed(self._retry, self._records, self.topics) + operation = self._operation_factory.build_select_not_processed(self._retry, self._records, self.topics) await client.execute(operation) return [row async for row in client.fetch_all()] diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index d0d27e96c..97e92b4e3 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -36,27 +36,27 @@ def build_table_name(self) -> str: class TestPostgreSqlBrokerQueue(NetworksTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() - self.query_factory = _Aiopg_BrokerQueueDatabaseOperationFactory() + self.operation_factory = _Aiopg_BrokerQueueDatabaseOperationFactory() def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerQueue, (BrokerQueue, DatabaseMixin))) def test_constructor(self): - queue = DatabaseBrokerQueue(query_factory=self.query_factory) + queue = DatabaseBrokerQueue(operation_factory=self.operation_factory) self.assertEqual(self.pool_factory.get_pool("database"), queue.pool) - self.assertEqual(self.query_factory, queue.query_factory) + self.assertEqual(self.operation_factory, queue.operation_factory) self.assertEqual(2, queue.retry) self.assertEqual(1000, queue.records) - async def test_query_factory(self): - queue = DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) + async def test_operation_factory(self): + queue = DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) - self.assertEqual(self.query_factory, queue.query_factory) + self.assertEqual(self.operation_factory, queue.operation_factory) async def test_enqueue(self): message = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) - async with DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: + async with DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) as queue: await queue.enqueue(message) await sleep(0.5) # To give time to consume the message from db. @@ -66,7 +66,7 @@ async def test_aiter(self): BrokerMessageV1("bar", BrokerMessageV1Payload("foo")), ] - queue = DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) + queue = DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) await queue.setup() await queue.enqueue(messages[0]) await queue.enqueue(messages[1]) @@ -90,7 +90,7 @@ async def test_dequeue_with_count(self): "fetch_all", return_value=FakeAsyncIterator([[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]]), ): - async with DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: + async with DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) as queue: queue._get_count = AsyncMock(side_effect=[3, 0]) async with queue: @@ -103,7 +103,7 @@ async def test_dequeue_with_notify(self): BrokerMessageV1("foo", BrokerMessageV1Payload("bar")), BrokerMessageV1("bar", BrokerMessageV1Payload("foo")), ] - async with DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: + async with DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) as queue: await queue.enqueue(messages[0]) await queue.enqueue(messages[1]) @@ -119,7 +119,7 @@ async def test_dequeue_ordered(self): BrokerMessageV1("foo", BrokerMessageV1Payload(1)), ] - async with DatabaseBrokerQueue.from_config(self.config, query_factory=self.query_factory) as queue: + async with DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) as queue: for message in unsorted: await queue.enqueue(message) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py index ec5df2ec0..37d06f314 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py @@ -18,10 +18,10 @@ class TestPostgreSqlBrokerPublisherQueue(NetworksTestCase, PostgresAsyncTestCase def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerPublisherQueue, (DatabaseBrokerQueue, BrokerPublisherQueue))) - async def test_query_factory(self): + async def test_operation_factory(self): queue = DatabaseBrokerPublisherQueue.from_config(self.config) - self.assertIsInstance(queue.query_factory, AiopgBrokerPublisherQueueDatabaseOperationFactory) + self.assertIsInstance(queue.operation_factory, AiopgBrokerPublisherQueueDatabaseOperationFactory) class TestPostgreSqlBrokerPublisherQueueQueryFactory(unittest.TestCase): diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py index 4a0fd21c3..d118c38e2 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py @@ -19,10 +19,12 @@ class TestPostgreSqlBrokerSubscriberDuplicateValidator(NetworksTestCase, Postgre def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerSubscriberDuplicateValidator, BrokerSubscriberValidator)) - async def test_query_factory(self): + async def test_operation_factory(self): validator = DatabaseBrokerSubscriberDuplicateValidator.from_config(self.config) - self.assertIsInstance(validator.query_factory, AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory) + self.assertIsInstance( + validator.operation_factory, AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory + ) async def test_is_valid(self): one = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py index fa22625f7..d5842be30 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py @@ -32,10 +32,10 @@ class TestPostgreSqlBrokerSubscriberQueue(NetworksTestCase, PostgresAsyncTestCas def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerSubscriberQueue, (DatabaseBrokerQueue, BrokerSubscriberQueue))) - async def test_query_factory(self): + async def test_operation_factory(self): queue = DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) - self.assertIsInstance(queue.query_factory, AiopgBrokerSubscriberQueueDatabaseOperationFactory) + self.assertIsInstance(queue.operation_factory, AiopgBrokerSubscriberQueueDatabaseOperationFactory) async def test_enqueue(self): message = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) From 3fa7f94ed304bf13ccc55ad865f26ada5e2f2684 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 18:27:37 +0200 Subject: [PATCH 157/324] ISSUE #371 * Minor improvements. --- .../brokers/collections/queues/database/factories/abc.py | 8 -------- .../collections/queues/database/factories/aiopg.py | 9 +++++++++ .../test_brokers/test_collections/test_queues/test_pg.py | 6 ++++-- 3 files changed, 13 insertions(+), 10 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py index 5b1bb9718..40a36ddd9 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py @@ -15,14 +15,6 @@ class BrokerQueueDatabaseOperationFactory(ABC): """PostgreSql Broker Queue Query Factory class.""" - @abstractmethod - def build_table_name(self) -> str: - """Get the table name. - - :return: A ``str`` value. - """ - raise NotImplementedError - @abstractmethod def build_create_table(self) -> DatabaseOperation: """Build the "create table" query. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py index 5823b3295..11b78c25d 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py @@ -1,5 +1,6 @@ from abc import ( ABC, + abstractmethod, ) from collections.abc import ( Iterable, @@ -23,6 +24,14 @@ class AiopgBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): """PostgreSql Broker Queue Query Factory class.""" + @abstractmethod + def build_table_name(self) -> str: + """Get the table name. + + :return: A ``str`` value. + """ + raise NotImplementedError + def build_create_table(self) -> DatabaseOperation: """Build the "create table" query. diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index 97e92b4e3..a99511e41 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -27,7 +27,9 @@ ) -class _Aiopg_BrokerQueueDatabaseOperationFactory(AiopgBrokerQueueDatabaseOperationFactory): +class _AiopgBrokerQueueDatabaseOperationFactory(AiopgBrokerQueueDatabaseOperationFactory): + """For testing purposes.""" + def build_table_name(self) -> str: """For testing purposes.""" return "test_table" @@ -36,7 +38,7 @@ def build_table_name(self) -> str: class TestPostgreSqlBrokerQueue(NetworksTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() - self.operation_factory = _Aiopg_BrokerQueueDatabaseOperationFactory() + self.operation_factory = _AiopgBrokerQueueDatabaseOperationFactory() def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerQueue, (BrokerQueue, DatabaseMixin))) From c4fcac3606981e928185e0ea287b7ddb4af43fc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 6 Apr 2022 18:32:28 +0200 Subject: [PATCH 158/324] ISSUE #371 * Minor improvements (2). --- .../minos/aggregate/events/repositories/database/impl.py | 7 ++++++- .../minos/aggregate/snapshots/database/abc.py | 7 ++++++- .../aggregate/transactions/repositories/database/impl.py | 7 ++++++- .../minos/networks/brokers/publishers/queued/queues/pg.py | 5 ++++- .../filtered/validators/duplicates/database/impl.py | 3 ++- .../brokers/subscribers/queued/queues/database/impl.py | 3 ++- 6 files changed, 26 insertions(+), 6 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index 1bc4c3316..ed5323bd1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -34,7 +34,12 @@ class DatabaseEventRepository(DatabaseMixin, EventRepository): """PostgreSQL-based implementation of the event repository class in ``Minos``.""" - def __init__(self, *args, operation_factory: Optional[EventDatabaseOperationFactory] = None, **kwargs): + def __init__( + self, + *args, + operation_factory: Optional[EventDatabaseOperationFactory] = None, + **kwargs, + ): super().__init__(*args, **kwargs) if operation_factory is None: operation_factory = AiopgEventDatabaseOperationFactory() diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py index ec5972fa2..03af580e8 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py @@ -23,7 +23,12 @@ class DatabaseSnapshotSetup(DatabaseMixin): """Minos Snapshot Setup Class""" - def __init__(self, *args, operation_factory: Optional[SnapshotDatabaseOperationFactory] = None, **kwargs): + def __init__( + self, + *args, + operation_factory: Optional[SnapshotDatabaseOperationFactory] = None, + **kwargs, + ): super().__init__(*args, **kwargs) if operation_factory is None: operation_factory = AiopgSnapshotDatabaseOperationFactory() diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index 74a145629..5c981e504 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -31,7 +31,12 @@ class DatabaseTransactionRepository(DatabaseMixin, TransactionRepository): """PostgreSql Transaction Repository class.""" - def __init__(self, *args, operation_factory: Optional[TransactionDatatabaseOperationFactory] = None, **kwargs): + def __init__( + self, + *args, + operation_factory: Optional[TransactionDatatabaseOperationFactory] = None, + **kwargs, + ): super().__init__(*args, **kwargs) if operation_factory is None: operation_factory = AiopgTransactionDatatabaseOperationFactory() diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py index 899526965..d78900197 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py @@ -28,7 +28,10 @@ class DatabaseBrokerPublisherQueue(DatabaseBrokerQueue, BrokerPublisherQueue): """PostgreSql Broker Publisher Queue class.""" def __init__( - self, *args, operation_factory: Optional[BrokerPublisherQueueDatabaseOperationFactory] = None, **kwargs + self, + *args, + operation_factory: Optional[BrokerPublisherQueueDatabaseOperationFactory] = None, + **kwargs, ): if operation_factory is None: operation_factory = AiopgBrokerPublisherQueueDatabaseOperationFactory() diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py index 75e4085da..8151494b6 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py @@ -21,6 +21,7 @@ ) from .factories import ( AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) @@ -29,7 +30,7 @@ class DatabaseBrokerSubscriberDuplicateValidator(BrokerSubscriberDuplicateValida def __init__( self, - operation_factory: Optional[AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory] = None, + operation_factory: Optional[BrokerSubscriberDuplicateValidatorDatabaseOperationFactory] = None, *args, **kwargs, ): diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py index fbe89e448..beab74bca 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py @@ -22,6 +22,7 @@ ) from .factories import ( AiopgBrokerSubscriberQueueDatabaseOperationFactory, + BrokerSubscriberQueueDatabaseOperationFactory, ) logger = logging.getLogger(__name__) @@ -34,7 +35,7 @@ def __init__( self, topics: set[str], *args, - operation_factory: Optional[AiopgBrokerSubscriberQueueDatabaseOperationFactory] = None, + operation_factory: Optional[BrokerSubscriberQueueDatabaseOperationFactory] = None, **kwargs, ): if operation_factory is None: From afb8bba6ad876539b649c56632460a5640109aca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 09:28:43 +0200 Subject: [PATCH 159/324] ISSUE #371 * Add `DatabaseOperationFactory` base class. * Add `register_factory` adn `get_factory` methods to `DatabaseClient`. --- .../minos/aggregate/__init__.py | 4 +-- .../repositories/database/factories/abc.py | 3 +- .../repositories/database/factories/aiopg.py | 4 +++ .../events/repositories/database/impl.py | 3 +- .../minos/aggregate/snapshots/database/abc.py | 3 +- .../snapshots/database/factories/abc.py | 4 +-- .../database/factories/aiopg/impl.py | 4 +++ .../minos/aggregate/transactions/__init__.py | 4 +-- .../transactions/repositories/__init__.py | 4 +-- .../repositories/database/__init__.py | 4 +-- .../database/factories/__init__.py | 4 +-- .../repositories/database/factories/abc.py | 4 +-- .../repositories/database/factories/aiopg.py | 8 +++-- .../repositories/database/impl.py | 7 ++--- .../minos/common/__init__.py | 3 ++ .../minos/common/database/__init__.py | 1 + .../minos/common/database/abc.py | 9 ++++++ .../minos/common/database/clients/abc.py | 29 +++++++++++++++++++ .../common/database/locks/factories/abc.py | 4 +-- .../common/database/locks/factories/aiopg.py | 6 ++++ .../minos/common/database/locks/impl.py | 3 +- .../common/database/operations/__init__.py | 1 + .../minos/common/database/operations/abc.py | 4 +++ .../minos/common/database/pools.py | 8 +++++ .../queues/database/factories/abc.py | 3 +- .../collections/queues/database/impl.py | 6 +++- .../brokers/publishers/queued/queues/pg.py | 25 +++++++--------- .../duplicates/database/factories/abc.py | 3 +- .../duplicates/database/factories/aiopg.py | 7 +++++ .../validators/duplicates/database/impl.py | 11 +++---- .../queued/queues/database/factories/aiopg.py | 7 +++++ .../queued/queues/database/impl.py | 14 ++------- 32 files changed, 141 insertions(+), 63 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index d1dbd0139..47b78e6e4 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -79,11 +79,11 @@ ) from .transactions import ( TRANSACTION_CONTEXT_VAR, - AiopgTransactionDatatabaseOperationFactory, + AiopgTransactionDatabaseOperationFactory, DatabaseTransactionRepository, InMemoryTransactionRepository, PostgreSqlTransactionRepository, - TransactionDatatabaseOperationFactory, + TransactionDatabaseOperationFactory, TransactionEntry, TransactionRepository, TransactionService, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py index 5d9f5a20b..1d08155a7 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py @@ -13,13 +13,14 @@ DatabaseOperation, datetime, ) +from minos.common import DatabaseOperationFactory from .....actions import ( Action, ) -class EventDatabaseOperationFactory(ABC): +class EventDatabaseOperationFactory(DatabaseOperationFactory, ABC): """TODO""" @abstractmethod diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py index 458131c05..a9728a440 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py @@ -17,6 +17,7 @@ ) from minos.common import ( + AiopgDatabaseClient, AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, @@ -242,3 +243,6 @@ def build_select_rows( def build_select_max_id(self) -> DatabaseOperation: """TODO""" return AiopgDatabaseOperation("SELECT MAX(id) FROM aggregate_event;".strip()) + + +AiopgDatabaseClient.register_factory(EventDatabaseOperationFactory, AiopgEventDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index ed5323bd1..3bec19f89 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -26,7 +26,6 @@ EventRepository, ) from .factories import ( - AiopgEventDatabaseOperationFactory, EventDatabaseOperationFactory, ) @@ -42,7 +41,7 @@ def __init__( ): super().__init__(*args, **kwargs) if operation_factory is None: - operation_factory = AiopgEventDatabaseOperationFactory() + operation_factory = self.pool_instance_cls.get_factory(EventDatabaseOperationFactory) self.operation_factory = operation_factory diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py index 03af580e8..f8ed834cf 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py @@ -15,7 +15,6 @@ ) from .factories import ( - AiopgSnapshotDatabaseOperationFactory, SnapshotDatabaseOperationFactory, ) @@ -31,7 +30,7 @@ def __init__( ): super().__init__(*args, **kwargs) if operation_factory is None: - operation_factory = AiopgSnapshotDatabaseOperationFactory() + operation_factory = self.pool_instance_cls.get_factory(SnapshotDatabaseOperationFactory) self.operation_factory = operation_factory diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py index 57bdc21a3..0b5601ce5 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py @@ -15,7 +15,7 @@ from minos.common import ( DatabaseOperation, - datetime, + datetime, DatabaseOperationFactory, ) from ....queries import ( @@ -24,7 +24,7 @@ ) -class SnapshotDatabaseOperationFactory(ABC): +class SnapshotDatabaseOperationFactory(DatabaseOperationFactory, ABC): """TODO""" @abstractmethod diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py index 40e315999..c9e2ebcb1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py @@ -13,6 +13,7 @@ ) from minos.common import ( + AiopgDatabaseClient, AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, @@ -163,3 +164,6 @@ def build_get_offset(self) -> DatabaseOperation: WHERE id = TRUE; """ ) + + +AiopgDatabaseClient.register_factory(SnapshotDatabaseOperationFactory, AiopgSnapshotDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py index 7653e6842..15006d9a6 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py @@ -6,11 +6,11 @@ TransactionStatus, ) from .repositories import ( - AiopgTransactionDatatabaseOperationFactory, + AiopgTransactionDatabaseOperationFactory, DatabaseTransactionRepository, InMemoryTransactionRepository, PostgreSqlTransactionRepository, - TransactionDatatabaseOperationFactory, + TransactionDatabaseOperationFactory, TransactionRepository, ) from .services import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py index dcb539e9f..3d46383fd 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py @@ -2,10 +2,10 @@ TransactionRepository, ) from .database import ( - AiopgTransactionDatatabaseOperationFactory, + AiopgTransactionDatabaseOperationFactory, DatabaseTransactionRepository, PostgreSqlTransactionRepository, - TransactionDatatabaseOperationFactory, + TransactionDatabaseOperationFactory, ) from .memory import ( InMemoryTransactionRepository, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py index e66e5943f..7a5ac1eb6 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py @@ -1,6 +1,6 @@ from .factories import ( - AiopgTransactionDatatabaseOperationFactory, - TransactionDatatabaseOperationFactory, + AiopgTransactionDatabaseOperationFactory, + TransactionDatabaseOperationFactory, ) from .impl import ( DatabaseTransactionRepository, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py index 02e029a18..a7bfcb28c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py @@ -1,6 +1,6 @@ from .abc import ( - TransactionDatatabaseOperationFactory, + TransactionDatabaseOperationFactory, ) from .aiopg import ( - AiopgTransactionDatatabaseOperationFactory, + AiopgTransactionDatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py index 46af61ca3..6fa201fcf 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py @@ -16,7 +16,7 @@ from minos.common import ( DatabaseOperation, - datetime, + datetime, DatabaseOperationFactory, ) if TYPE_CHECKING: @@ -25,7 +25,7 @@ ) -class TransactionDatatabaseOperationFactory(ABC): +class TransactionDatabaseOperationFactory(DatabaseOperationFactory, ABC): """TODO""" @abstractmethod diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py index cec02cfb9..9b4f100e4 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py @@ -11,6 +11,7 @@ ) from minos.common import ( + AiopgDatabaseClient, AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, @@ -18,7 +19,7 @@ ) from .abc import ( - TransactionDatatabaseOperationFactory, + TransactionDatabaseOperationFactory, ) if TYPE_CHECKING: @@ -28,7 +29,7 @@ # noinspection SqlNoDataSourceInspection,SqlResolve,PyMethodMayBeStatic -class AiopgTransactionDatatabaseOperationFactory(TransactionDatatabaseOperationFactory): +class AiopgTransactionDatabaseOperationFactory(TransactionDatabaseOperationFactory): """TODO""" def build_create_table(self) -> DatabaseOperation: @@ -196,3 +197,6 @@ def build_select_rows( "updated_at_ge": updated_at_ge, }, ) + + +AiopgDatabaseClient.register_factory(TransactionDatabaseOperationFactory, AiopgTransactionDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index 5c981e504..061fee499 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -23,8 +23,7 @@ TransactionRepository, ) from .factories import ( - AiopgTransactionDatatabaseOperationFactory, - TransactionDatatabaseOperationFactory, + TransactionDatabaseOperationFactory, ) @@ -34,12 +33,12 @@ class DatabaseTransactionRepository(DatabaseMixin, TransactionRepository): def __init__( self, *args, - operation_factory: Optional[TransactionDatatabaseOperationFactory] = None, + operation_factory: Optional[TransactionDatabaseOperationFactory] = None, **kwargs, ): super().__init__(*args, **kwargs) if operation_factory is None: - operation_factory = AiopgTransactionDatatabaseOperationFactory() + operation_factory = self.pool_instance_cls.get_factory(TransactionDatabaseOperationFactory) self.operation_factory = operation_factory diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 21dcfe346..62d212381 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -31,6 +31,9 @@ PostgreSqlMinosDatabase, PostgreSqlPool, UnableToConnectException, + DatabaseOperationFactory, + LockDatabaseOperationFactory, + AiopgLockDatabaseOperationFactory, ) from .datetime import ( NULL_DATETIME, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index 3f21830f6..e75d13499 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -20,6 +20,7 @@ AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, + DatabaseOperationFactory, ) from .pools import ( DatabaseClientPool, diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/abc.py index 760c5ee5c..9f517ac2b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/abc.py @@ -20,6 +20,7 @@ DatabaseOperation, ) from .pools import ( + DatabaseClient, DatabaseClientPool, PostgreSqlPool, ) @@ -98,6 +99,14 @@ async def submit_query(self, operation: DatabaseOperation) -> None: async with self.pool.acquire() as client: return await client.execute(operation) + @property + def pool_instance_cls(self) -> type[DatabaseClient]: + """TODO + + :return: TODO + """ + return self.pool.instance_cls + @property def pool(self) -> DatabaseClientPool: """Get the connections pool. diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 30c93e7ef..b6e4f4758 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -14,6 +14,8 @@ Optional, ) +from minos.common.database.operations import DatabaseOperationFactory + from ...builders import ( BuildableMixin, Builder, @@ -30,6 +32,8 @@ class DatabaseClient(ABC, BuildableMixin): """Database Client base class.""" + _factories = dict() + @classmethod def _from_config(cls, config: Config, name: Optional[str] = None, **kwargs) -> DatabaseClient: return super()._from_config(config, **config.get_database_by_name(name), **kwargs) @@ -91,6 +95,31 @@ def fetch_all(self) -> AsyncIterator[Any]: def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: raise NotImplementedError + @classmethod + def register_factory(cls, base: type[DatabaseOperationFactory], impl: type[DatabaseOperationFactory]) -> None: + """TODO + + :param base: TODO + :param impl: TODO + :return: + """ + if not issubclass(base, DatabaseOperationFactory): + raise ValueError(f"{base!r} must be a subclass of {DatabaseOperationFactory!r}") + + if not issubclass(impl, base): + raise ValueError(f"{impl!r} must be a subclass of {base!r}") + + cls._factories[base] = impl + + @classmethod + def get_factory(cls, base: type[DatabaseOperationFactory]) -> DatabaseOperationFactory: + """TODO + + :param base: TODO + :return: TODO + """ + return cls._factories[base]() + class DatabaseClientBuilder(Builder[DatabaseClient]): """Database Client Builder class.""" diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py index d1591aebd..4156b754e 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py @@ -4,11 +4,11 @@ ) from ...operations import ( - DatabaseOperation, + DatabaseOperation,DatabaseOperationFactory ) -class LockDatabaseOperationFactory(ABC): +class LockDatabaseOperationFactory(DatabaseOperationFactory, ABC): """TODO""" @abstractmethod diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py index e5515da33..817b4c121 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py @@ -1,3 +1,6 @@ +from ...clients import ( + AiopgDatabaseClient, +) from ...operations import ( AiopgDatabaseOperation, DatabaseOperation, @@ -17,3 +20,6 @@ def build_acquire(self, hashed_key: int) -> DatabaseOperation: def build_release(self, hashed_key: int) -> DatabaseOperation: """TODO""" return AiopgDatabaseOperation("select pg_advisory_unlock(%(hashed_key)s)", {"hashed_key": hashed_key}) + + +AiopgDatabaseClient.register_factory(LockDatabaseOperationFactory, AiopgLockDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/impl.py b/packages/core/minos-microservice-common/minos/common/database/locks/impl.py index 9a5e72078..24a4e3bdd 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/impl.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/impl.py @@ -18,7 +18,6 @@ DatabaseClient, ) from .factories import ( - AiopgLockDatabaseOperationFactory, LockDatabaseOperationFactory, ) @@ -36,7 +35,7 @@ def __init__( ): super().__init__(key, *args, **kwargs) if operation_factory is None: - operation_factory = AiopgLockDatabaseOperationFactory() + operation_factory = client.get_factory(LockDatabaseOperationFactory) self.client = client self.operation_factory = operation_factory diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py index 9ba6002c2..08f7b389c 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py @@ -1,6 +1,7 @@ from .abc import ( ComposedDatabaseOperation, DatabaseOperation, + DatabaseOperationFactory, ) from .aiopg import ( AiopgDatabaseOperation, diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py index 3f4b67781..032cd7e28 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py @@ -20,3 +20,7 @@ class ComposedDatabaseOperation(DatabaseOperation): def __init__(self, operations: Iterable[DatabaseOperation]): super().__init__() self.operations = operations + + +class DatabaseOperationFactory(ABC): + """TODO""" diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 926fca84c..1f726684b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -82,6 +82,14 @@ async def _check_instance(self, instance: Optional[DatabaseClient]) -> bool: async def _release_instance(self, instance: DatabaseClient) -> None: await instance.reset() + @property + def instance_cls(self) -> type[DatabaseClient]: + """TODO + + :return: TODO + """ + return self.client_builder.instance_cls + @property def client_builder(self) -> DatabaseClientBuilder: """Get the client builder class. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py index 40a36ddd9..8fe797c24 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py @@ -8,11 +8,12 @@ from minos.common import ( DatabaseOperation, + DatabaseOperationFactory, ) # noinspection SqlResolve,SqlNoDataSourceInspection,SqlNoDataSourceInspection,SqlResolve -class BrokerQueueDatabaseOperationFactory(ABC): +class BrokerQueueDatabaseOperationFactory(DatabaseOperationFactory, ABC): """PostgreSql Broker Queue Query Factory class.""" @abstractmethod diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index d0e6a75c6..dc65cf2a5 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -53,7 +53,8 @@ class DatabaseBrokerQueue(BrokerQueue, DatabaseMixin): def __init__( self, *args, - operation_factory: BrokerQueueDatabaseOperationFactory, + operation_factory: Optional[BrokerQueueDatabaseOperationFactory] = None, + operation_factory_cls: Optional[type[BrokerQueueDatabaseOperationFactory]] = None, retry: Optional[int] = None, records: Optional[int] = None, **kwargs, @@ -65,6 +66,9 @@ def __init__( if records is None: records = 1000 + if operation_factory is None: + operation_factory = self.pool_instance_cls.get_factory(operation_factory_cls) + self._operation_factory = operation_factory self._retry = retry self._records = records diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py index d78900197..51d7780c0 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py @@ -6,16 +6,15 @@ from abc import ( ABC, ) -from typing import ( - Optional, + +from minos.common import ( + AiopgDatabaseClient, ) from ....collections import ( AiopgBrokerQueueDatabaseOperationFactory, - DatabaseBrokerQueue, -) -from ....collections.queues.database.factories.abc import ( BrokerQueueDatabaseOperationFactory, + DatabaseBrokerQueue, ) from .abc import ( BrokerPublisherQueue, @@ -27,15 +26,8 @@ class DatabaseBrokerPublisherQueue(DatabaseBrokerQueue, BrokerPublisherQueue): """PostgreSql Broker Publisher Queue class.""" - def __init__( - self, - *args, - operation_factory: Optional[BrokerPublisherQueueDatabaseOperationFactory] = None, - **kwargs, - ): - if operation_factory is None: - operation_factory = AiopgBrokerPublisherQueueDatabaseOperationFactory() - super().__init__(*args, operation_factory=operation_factory, **kwargs) + def __init__(self, *args, **kwargs): + super().__init__(*args, operation_factory_cls=BrokerPublisherQueueDatabaseOperationFactory, **kwargs) class BrokerPublisherQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): @@ -53,3 +45,8 @@ def build_table_name(self) -> str: :return: A ``str`` value. """ return "broker_publisher_queue" + + +AiopgDatabaseClient.register_factory( + BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerPublisherQueueDatabaseOperationFactory +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py index d26989e93..87dba8d38 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py @@ -8,11 +8,12 @@ from minos.common import ( DatabaseOperation, + DatabaseOperationFactory, ) # noinspection SqlNoDataSourceInspection,SqlResolve -class BrokerSubscriberDuplicateValidatorDatabaseOperationFactory(ABC): +class BrokerSubscriberDuplicateValidatorDatabaseOperationFactory(DatabaseOperationFactory, ABC): """TODO""" @abstractmethod diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py index 4e3dd8e33..64df7b61f 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py @@ -7,6 +7,7 @@ ) from minos.common import ( + AiopgDatabaseClient, AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, @@ -68,3 +69,9 @@ def build_insert_row(self, topic: str, uuid: UUID) -> DatabaseOperation: "uuid": uuid, }, ) + + +AiopgDatabaseClient.register_factory( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py index 8151494b6..5d83ab2b0 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py @@ -20,7 +20,6 @@ BrokerSubscriberDuplicateValidator, ) from .factories import ( - AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) @@ -34,9 +33,11 @@ def __init__( *args, **kwargs, ): - if operation_factory is None: - operation_factory = AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory() super().__init__(*args, **kwargs) + if operation_factory is None: + operation_factory = self.pool_instance_cls.get_factory( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory + ) self._operation_factory = operation_factory async def _setup(self) -> None: @@ -48,10 +49,10 @@ async def _create_table(self) -> None: await self.submit_query(operation) @property - def operation_factory(self) -> AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory: + def operation_factory(self) -> BrokerSubscriberDuplicateValidatorDatabaseOperationFactory: """Get the query factory. - :return: A ``PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory`` instance. + :return: A ``BrokerSubscriberDuplicateValidatorDatabaseOperationFactory`` instance. """ return self._operation_factory diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py index 454d9c534..452b73b1c 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py @@ -7,6 +7,7 @@ ) from minos.common import ( + AiopgDatabaseClient, AiopgDatabaseOperation, DatabaseOperation, ) @@ -65,3 +66,9 @@ def build_select_not_processed( ), {"retry": retry, "topics": tuple(topics), "records": records}, ) + + +AiopgDatabaseClient.register_factory( + BrokerSubscriberQueueDatabaseOperationFactory, + AiopgBrokerSubscriberQueueDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py index beab74bca..419424ed4 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py @@ -5,7 +5,6 @@ import logging from typing import ( Any, - Optional, ) from minos.common import ( @@ -21,7 +20,6 @@ BrokerSubscriberQueueBuilder, ) from .factories import ( - AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriberQueueDatabaseOperationFactory, ) @@ -31,16 +29,8 @@ class DatabaseBrokerSubscriberQueue(DatabaseBrokerQueue, BrokerSubscriberQueue): """PostgreSql Broker Subscriber Queue class.""" - def __init__( - self, - topics: set[str], - *args, - operation_factory: Optional[BrokerSubscriberQueueDatabaseOperationFactory] = None, - **kwargs, - ): - if operation_factory is None: - operation_factory = AiopgBrokerSubscriberQueueDatabaseOperationFactory() - super().__init__(topics, *args, operation_factory=operation_factory, **kwargs) + def __init__(self, topics: set[str], *args, **kwargs): + super().__init__(topics, *args, operation_factory_cls=BrokerSubscriberQueueDatabaseOperationFactory, **kwargs) async def _get_count(self) -> int: # noinspection PyTypeChecker From 2a9c3832a1f5be7ebe195d2f614d391ac2ec0c5e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 09:41:34 +0200 Subject: [PATCH 160/324] ISSUE #371 * Now `timeout` and `lock` is managed by the `DatabaseClient` instead of by the `AiopgDatabaseClient`. --- .../minos/common/database/clients/abc.py | 35 ++++++++++++++++--- .../minos/common/database/clients/aiopg.py | 35 +++---------------- .../minos/common/database/operations/abc.py | 13 +++++-- .../minos/common/database/operations/aiopg.py | 15 ++------ 4 files changed, 46 insertions(+), 52 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index b6e4f4758..116e8a7d5 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -2,20 +2,20 @@ annotations, ) +import logging from abc import ( ABC, abstractmethod, ) +from asyncio import wait_for from collections.abc import ( - AsyncIterator, + AsyncIterator, Hashable, ) from typing import ( Any, Optional, ) -from minos.common.database.operations import DatabaseOperationFactory - from ...builders import ( BuildableMixin, Builder, @@ -26,8 +26,11 @@ from ..operations import ( ComposedDatabaseOperation, DatabaseOperation, + DatabaseOperationFactory, ) +logger = logging.getLogger(__name__) + class DatabaseClient(ABC, BuildableMixin): """Database Client base class.""" @@ -55,6 +58,7 @@ async def reset(self, **kwargs) -> None: :param kwargs: Additional named parameters. :return: This method does not return anything. """ + await self._destroy_lock() return await self._reset(**kwargs) @abstractmethod @@ -67,16 +71,37 @@ async def execute(self, operation: DatabaseOperation) -> None: :param operation: TODO :return: This method does not return anything. """ + if operation.lock is not None: + await self._create_lock(operation.lock) + if isinstance(operation, ComposedDatabaseOperation): for op in operation.operations: - await self._execute(op) + await wait_for(self._execute(op), operation.timeout) else: - await self._execute(operation) + await wait_for(self._execute(operation), operation.timeout) @abstractmethod async def _execute(self, operation: DatabaseOperation) -> None: raise NotImplementedError + async def _create_lock(self, lock: Hashable, *args, **kwargs): + if self._lock is not None and self._lock.key == lock: + return + await self._destroy_lock() + + from ..locks import ( + DatabaseLock, + ) + + self._lock = DatabaseLock(self, lock, *args, **kwargs) + await self._lock.acquire() + + async def _destroy_lock(self): + if self._lock is not None: + logger.debug(f"Destroying {self._lock!r}...") + await self._lock.release() + self._lock = None + async def fetch_one(self) -> Any: """Fetch one value. diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index d0078bdbb..820a9538c 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -5,7 +5,6 @@ import logging from collections.abc import ( AsyncIterator, - Hashable, ) from typing import ( TYPE_CHECKING, @@ -134,48 +133,22 @@ async def _execute(self, operation: AiopgDatabaseOperation) -> None: if not isinstance(operation, AiopgDatabaseOperation): raise ValueError(f"The operation is not supported: {operation!r}") - await self._create_cursor(lock=operation.lock) + await self._create_cursor() try: - await self._cursor.execute( - operation=operation.query, - parameters=operation.parameters, - timeout=operation.timeout, - ) + await self._cursor.execute(operation=operation.query, parameters=operation.parameters) except IntegrityError as exc: raise IntegrityException(f"The requested operation raised a integrity error: {exc!r}") - async def _create_cursor(self, *args, lock: Optional[Hashable] = None, **kwargs): + async def _create_cursor(self): if self._cursor is None: - self._cursor = await self._connection.cursor(*args, **kwargs) - - if lock is not None: - await self._create_lock(lock) + self._cursor = await self._connection.cursor() async def _destroy_cursor(self, **kwargs): - await self._destroy_lock() if self._cursor is not None: if not self._cursor.closed: self._cursor.close() self._cursor = None - async def _create_lock(self, lock: Hashable, *args, **kwargs): - if self._lock is not None and self._lock.key == lock: - return - await self._destroy_lock() - - from ..locks import ( - DatabaseLock, - ) - - self._lock = DatabaseLock(self, lock, *args, **kwargs) - await self._lock.acquire() - - async def _destroy_lock(self): - if self._lock is not None: - logger.debug(f"Destroying {self.lock!r}...") - await self._lock.release() - self._lock = None - @property def lock(self) -> Optional[DatabaseLock]: """Get the lock. diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py index 032cd7e28..c6ee8d73b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py @@ -6,19 +6,26 @@ ABC, ) from collections.abc import ( - Iterable, + Iterable, Hashable, +) +from typing import ( + Optional, ) class DatabaseOperation(ABC): """TODO""" + def __init__(self, *args, lock: Optional[Hashable] = None, timeout: Optional[float] = None, **kwargs): + self.lock = lock + self.timeout = timeout + class ComposedDatabaseOperation(DatabaseOperation): """TODO""" - def __init__(self, operations: Iterable[DatabaseOperation]): - super().__init__() + def __init__(self, operations: Iterable[DatabaseOperation], *args, **kwargs): + super().__init__(*args, **kwargs) self.operations = operations diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py index 818367b99..efba2ee0a 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py @@ -1,9 +1,5 @@ -from collections.abc import ( - Hashable, -) from typing import ( Any, - Optional, Union, ) @@ -19,16 +15,9 @@ class AiopgDatabaseOperation(DatabaseOperation): """TODO""" - def __init__( - self, - query: Union[str, Composable], - parameters: dict[str, Any] = None, - lock: Optional[Hashable] = None, - timeout: Optional[float] = None, - ): + def __init__(self, query: Union[str, Composable], parameters: dict[str, Any] = None, *args, **kwargs): + super().__init__(*args, **kwargs) if parameters is None: parameters = dict() self.query = query self.parameters = parameters - self.lock = lock - self.timeout = timeout From 7268b2d14fce010a01f073a04a5af362ba526c3d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 09:52:38 +0200 Subject: [PATCH 161/324] ISSUE #371 * Fix minor bugs. --- .../repositories/database/factories/abc.py | 6 ++-- .../repositories/database/factories/aiopg.py | 4 ++- .../snapshots/database/factories/abc.py | 5 +++- .../repositories/database/factories/abc.py | 5 +++- .../repositories/database/factories/aiopg.py | 4 ++- .../minos/common/__init__.py | 6 ++-- .../minos/common/database/clients/abc.py | 29 +++++++++++++++++-- .../minos/common/database/clients/aiopg.py | 17 ----------- .../common/database/locks/factories/abc.py | 3 +- .../minos/common/database/operations/abc.py | 3 +- .../test_database/test_clients/test_aiopg.py | 2 +- 11 files changed, 52 insertions(+), 32 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py index 1d08155a7..d7af71d27 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py @@ -2,6 +2,9 @@ ABC, abstractmethod, ) +from datetime import ( + datetime, +) from typing import ( Optional, ) @@ -11,9 +14,8 @@ from minos.common import ( DatabaseOperation, - datetime, + DatabaseOperationFactory, ) -from minos.common import DatabaseOperationFactory from .....actions import ( Action, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py index a9728a440..702c30f0c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py @@ -1,6 +1,9 @@ from collections.abc import ( Iterable, ) +from datetime import ( + datetime, +) from typing import ( Any, Optional, @@ -21,7 +24,6 @@ AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, - datetime, ) from .....actions import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py index 0b5601ce5..13344e137 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py @@ -5,6 +5,9 @@ from collections.abc import ( Iterable, ) +from datetime import ( + datetime, +) from typing import ( Any, Optional, @@ -15,7 +18,7 @@ from minos.common import ( DatabaseOperation, - datetime, DatabaseOperationFactory, + DatabaseOperationFactory, ) from ....queries import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py index 6fa201fcf..035847c54 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py @@ -6,6 +6,9 @@ ABC, abstractmethod, ) +from datetime import ( + datetime, +) from typing import ( TYPE_CHECKING, Optional, @@ -16,7 +19,7 @@ from minos.common import ( DatabaseOperation, - datetime, DatabaseOperationFactory, + DatabaseOperationFactory, ) if TYPE_CHECKING: diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py index 9b4f100e4..d49106aab 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py @@ -2,6 +2,9 @@ annotations, ) +from datetime import ( + datetime, +) from typing import ( TYPE_CHECKING, Optional, @@ -15,7 +18,6 @@ AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, - datetime, ) from .abc import ( diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 62d212381..2810f069c 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -16,6 +16,7 @@ from .database import ( AiopgDatabaseClient, AiopgDatabaseOperation, + AiopgLockDatabaseOperationFactory, ComposedDatabaseOperation, DatabaseClient, DatabaseClientBuilder, @@ -25,15 +26,14 @@ DatabaseLockPool, DatabaseMixin, DatabaseOperation, + DatabaseOperationFactory, IntegrityException, + LockDatabaseOperationFactory, PostgreSqlLock, PostgreSqlLockPool, PostgreSqlMinosDatabase, PostgreSqlPool, UnableToConnectException, - DatabaseOperationFactory, - LockDatabaseOperationFactory, - AiopgLockDatabaseOperationFactory, ) from .datetime import ( NULL_DATETIME, diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 116e8a7d5..14b327d07 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -7,11 +7,15 @@ ABC, abstractmethod, ) -from asyncio import wait_for +from asyncio import ( + wait_for, +) from collections.abc import ( - AsyncIterator, Hashable, + AsyncIterator, + Hashable, ) from typing import ( + TYPE_CHECKING, Any, Optional, ) @@ -29,13 +33,24 @@ DatabaseOperationFactory, ) +if TYPE_CHECKING: + from ..locks import ( + DatabaseLock, + ) logger = logging.getLogger(__name__) class DatabaseClient(ABC, BuildableMixin): """Database Client base class.""" - _factories = dict() + _factories: dict[type[DatabaseOperationFactory], type[DatabaseOperationFactory]] = dict() + + _lock: Optional[DatabaseLock] + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + + self._lock = None @classmethod def _from_config(cls, config: Config, name: Optional[str] = None, **kwargs) -> DatabaseClient: @@ -102,6 +117,14 @@ async def _destroy_lock(self): await self._lock.release() self._lock = None + @property + def lock(self) -> Optional[DatabaseLock]: + """Get the lock. + + :return: A ``DatabaseLock`` instance. + """ + return self._lock + async def fetch_one(self) -> Any: """Fetch one value. diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index 820a9538c..da4410912 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -7,7 +7,6 @@ AsyncIterator, ) from typing import ( - TYPE_CHECKING, Optional, ) @@ -32,11 +31,6 @@ UnableToConnectException, ) -if TYPE_CHECKING: - from ..locks import ( - DatabaseLock, - ) - logger = logging.getLogger(__name__) @@ -45,7 +39,6 @@ class AiopgDatabaseClient(DatabaseClient): _connection: Optional[Connection] _cursor: Optional[Cursor] - _lock: Optional[DatabaseLock] def __init__( self, @@ -75,8 +68,6 @@ def __init__( self._password = password self._connection = None - - self._lock = None self._cursor = None async def _setup(self) -> None: @@ -149,14 +140,6 @@ async def _destroy_cursor(self, **kwargs): self._cursor.close() self._cursor = None - @property - def lock(self) -> Optional[DatabaseLock]: - """Get the lock. - - :return: A ``DatabaseLock`` instance. - """ - return self._lock - @property def cursor(self) -> Optional[Cursor]: """Get the cursor. diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py index 4156b754e..13049f194 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py @@ -4,7 +4,8 @@ ) from ...operations import ( - DatabaseOperation,DatabaseOperationFactory + DatabaseOperation, + DatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py index c6ee8d73b..3e2180ffd 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py @@ -6,7 +6,8 @@ ABC, ) from collections.abc import ( - Iterable, Hashable, + Hashable, + Iterable, ) from typing import ( Optional, diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py index bab4e15e4..270eb1916 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py @@ -126,7 +126,7 @@ async def test_execute(self): with patch.object(Cursor, "execute") as execute_mock: await client.execute(self.operation) self.assertEqual( - [call(operation=self.operation.query, parameters=self.operation.parameters, timeout=None)], + [call(operation=self.operation.query, parameters=self.operation.parameters)], execute_mock.call_args_list, ) From 4bf4b4cafce60dce08eb721f2a94e83190849bc7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 11:41:09 +0200 Subject: [PATCH 162/324] ISSUE #371 * Add `ManageDatabaseOperationFactory`. --- .../minos/common/__init__.py | 2 + .../minos/common/database/__init__.py | 12 +++-- .../minos/common/database/manage/__init__.py | 4 ++ .../minos/common/database/manage/factories.py | 44 +++++++++++++++++++ .../common/database/{abc.py => mixins.py} | 0 .../minos/common/database/pools.py | 13 ++++-- .../minos/common/testing.py | 34 +++++++------- .../publishers/queued/queues/__init__.py | 8 ++-- .../queued/queues/{pg.py => database.py} | 0 9 files changed, 89 insertions(+), 28 deletions(-) create mode 100644 packages/core/minos-microservice-common/minos/common/database/manage/__init__.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/manage/factories.py rename packages/core/minos-microservice-common/minos/common/database/{abc.py => mixins.py} (100%) rename packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/{pg.py => database.py} (100%) diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 2810f069c..e1dd32b9f 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -17,6 +17,7 @@ AiopgDatabaseClient, AiopgDatabaseOperation, AiopgLockDatabaseOperationFactory, + AiopgManageDatabaseOperationFactory, ComposedDatabaseOperation, DatabaseClient, DatabaseClientBuilder, @@ -29,6 +30,7 @@ DatabaseOperationFactory, IntegrityException, LockDatabaseOperationFactory, + ManageDatabaseOperationFactory, PostgreSqlLock, PostgreSqlLockPool, PostgreSqlMinosDatabase, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index e75d13499..70d762fe3 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -1,7 +1,3 @@ -from .abc import ( - DatabaseMixin, - PostgreSqlMinosDatabase, -) from .clients import ( AiopgDatabaseClient, DatabaseClient, @@ -16,6 +12,14 @@ LockDatabaseOperationFactory, PostgreSqlLock, ) +from .manage import ( + AiopgManageDatabaseOperationFactory, + ManageDatabaseOperationFactory, +) +from .mixins import ( + DatabaseMixin, + PostgreSqlMinosDatabase, +) from .operations import ( AiopgDatabaseOperation, ComposedDatabaseOperation, diff --git a/packages/core/minos-microservice-common/minos/common/database/manage/__init__.py b/packages/core/minos-microservice-common/minos/common/database/manage/__init__.py new file mode 100644 index 000000000..53dca9546 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/manage/__init__.py @@ -0,0 +1,4 @@ +from .factories import ( + AiopgManageDatabaseOperationFactory, + ManageDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-common/minos/common/database/manage/factories.py b/packages/core/minos-microservice-common/minos/common/database/manage/factories.py new file mode 100644 index 000000000..cf486e90f --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/manage/factories.py @@ -0,0 +1,44 @@ +from abc import ( + ABC, + abstractmethod, +) + +from ..clients import ( + AiopgDatabaseClient, +) +from ..operations import ( + AiopgDatabaseOperation, + DatabaseOperation, + DatabaseOperationFactory, +) + + +class ManageDatabaseOperationFactory(DatabaseOperationFactory, ABC): + """TODO""" + + @abstractmethod + def build_create( + self, + database: str, + ) -> DatabaseOperation: + """TODO""" + + @abstractmethod + def build_delete(self, database: str) -> DatabaseOperation: + """TODO""" + + +# noinspection SqlNoDataSourceInspection +class AiopgManageDatabaseOperationFactory(ManageDatabaseOperationFactory): + """TODO""" + + def build_create(self, database: str) -> DatabaseOperation: + """TODO""" + return AiopgDatabaseOperation(f"CREATE DATABASE {database};") + + def build_delete(self, database: str) -> DatabaseOperation: + """TODO""" + return AiopgDatabaseOperation(f"DROP DATABASE IF EXISTS {database};") + + +AiopgDatabaseClient.register_factory(ManageDatabaseOperationFactory, AiopgManageDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-common/minos/common/database/abc.py b/packages/core/minos-microservice-common/minos/common/database/mixins.py similarity index 100% rename from packages/core/minos-microservice-common/minos/common/database/abc.py rename to packages/core/minos-microservice-common/minos/common/database/mixins.py diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 1f726684b..599ff0fbb 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -27,7 +27,6 @@ Pool, ) from .clients import ( - AiopgDatabaseClient, DatabaseClient, DatabaseClientBuilder, UnableToConnectException, @@ -49,9 +48,15 @@ def __init__(self, client_builder: DatabaseClientBuilder, *args, **kwargs): @classmethod def _from_config(cls, config: Config, identifier: Optional[str] = None, **kwargs): - client_cls = config.get_database_by_name(identifier).get("client", AiopgDatabaseClient) - # noinspection PyTypeChecker - base_builder: DatabaseClientBuilder = client_cls.get_builder() + base_builder = config.get_database_by_name(identifier).get("client") + + if base_builder is None: + raise ValueError(f"{base_builder!r} is not a {DatabaseClientBuilder!r} instance.") + elif issubclass(base_builder, DatabaseClient): + base_builder = base_builder.get_builder() + elif issubclass(base_builder, DatabaseClientBuilder): + base_builder = base_builder() + client_builder = base_builder.with_name(identifier).with_config(config) return cls(client_builder=client_builder, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index ef1402df5..d61f2365a 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -1,3 +1,7 @@ +from __future__ import ( + annotations, +) + import unittest from abc import ( ABC, @@ -16,16 +20,14 @@ uuid4, ) -from minos.common import ( - AiopgDatabaseOperation, -) - from .config import ( Config, ) from .database import ( AiopgDatabaseClient, + DatabaseClient, DatabaseClientPool, + ManageDatabaseOperationFactory, ) from .injections import ( DependencyInjector, @@ -82,6 +84,9 @@ def setUp(self): self._test_db = {"database": f"test_db_{self._uuid.hex}"} super().setUp() + def get_client(self) -> DatabaseClient: + return AiopgDatabaseClient.from_config(self.base_config) + def get_config(self) -> Config: config = Config(self.get_config_file_path()) @@ -97,24 +102,21 @@ def get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin], s return [PoolFactory.from_config(self.config, default_classes={"database": DatabaseClientPool})] async def asyncSetUp(self): - await self._create_database(self.base_config.get_default_database(), self._test_db) + await self._create_database(self._test_db) await super().asyncSetUp() async def asyncTearDown(self): await super().asyncTearDown() - await self._drop_database(self.base_config.get_default_database(), self._test_db) + await self._drop_database(self._test_db) - async def _create_database(self, meta: dict[str, Any], test: dict[str, Any]) -> None: - await self._drop_database(meta, test) + async def _create_database(self, test: dict[str, Any]) -> None: + await self._drop_database(test) - async with AiopgDatabaseClient(**meta) as client: - template = "CREATE DATABASE {database} WITH OWNER = {user};" - operation = AiopgDatabaseOperation(template.format(**(meta | test))) + async with self.get_client() as client: + operation = client.get_factory(ManageDatabaseOperationFactory).build_create(test["database"]) await client.execute(operation) - @staticmethod - async def _drop_database(meta: dict[str, Any], test: dict[str, Any]) -> None: - async with AiopgDatabaseClient(**meta) as client: - template = "DROP DATABASE IF EXISTS {database}" - operation = AiopgDatabaseOperation(template.format(**(meta | test))) + async def _drop_database(self, test: dict[str, Any]) -> None: + async with self.get_client() as client: + operation = client.get_factory(ManageDatabaseOperationFactory).build_delete(test["database"]) await client.execute(operation) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py index 7483cabb4..5e544f1a3 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py @@ -1,11 +1,11 @@ from .abc import ( BrokerPublisherQueue, ) -from .memory import ( - InMemoryBrokerPublisherQueue, -) -from .pg import ( +from .database import ( AiopgBrokerPublisherQueueDatabaseOperationFactory, BrokerPublisherQueueDatabaseOperationFactory, DatabaseBrokerPublisherQueue, ) +from .memory import ( + InMemoryBrokerPublisherQueue, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py similarity index 100% rename from packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/pg.py rename to packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py From ed522a5e1ce9f5dc091398ca6479ec2dcd523133 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 11:55:30 +0200 Subject: [PATCH 163/324] ISSUE #371 * Fix bugs. --- .../core/minos-microservice-aggregate/tests/test_config.yml | 3 +++ packages/core/minos-microservice-cqrs/tests/test_config.yml | 3 +++ .../core/minos-microservice-networks/tests/test_config.yml | 3 +++ packages/plugins/minos-broker-kafka/tests/test_config.yml | 3 +++ 4 files changed, 12 insertions(+) diff --git a/packages/core/minos-microservice-aggregate/tests/test_config.yml b/packages/core/minos-microservice-aggregate/tests/test_config.yml index 2416a4a81..17bdcc6f8 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_config.yml +++ b/packages/core/minos-microservice-aggregate/tests/test_config.yml @@ -2,12 +2,14 @@ service: name: Order aggregate: tests.utils.Order repository: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s host: localhost port: 5432 snapshot: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s @@ -20,6 +22,7 @@ broker: host: localhost port: 9092 queue: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-cqrs/tests/test_config.yml b/packages/core/minos-microservice-cqrs/tests/test_config.yml index 195e14244..dd7af43fc 100644 --- a/packages/core/minos-microservice-cqrs/tests/test_config.yml +++ b/packages/core/minos-microservice-cqrs/tests/test_config.yml @@ -8,6 +8,7 @@ broker: host: localhost port: 9092 queue: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s @@ -16,12 +17,14 @@ broker: records: 10 retry: 2 repository: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s host: localhost port: 5432 snapshot: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-networks/tests/test_config.yml b/packages/core/minos-microservice-networks/tests/test_config.yml index e267acc3a..788655ef9 100644 --- a/packages/core/minos-microservice-networks/tests/test_config.yml +++ b/packages/core/minos-microservice-networks/tests/test_config.yml @@ -16,12 +16,14 @@ rest: host: localhost port: 8080 repository: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s host: localhost port: 5432 snapshot: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s @@ -31,6 +33,7 @@ broker: host: localhost port: 9092 queue: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/plugins/minos-broker-kafka/tests/test_config.yml b/packages/plugins/minos-broker-kafka/tests/test_config.yml index 108ab5297..61a8117de 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_config.yml +++ b/packages/plugins/minos-broker-kafka/tests/test_config.yml @@ -10,12 +10,14 @@ rest: host: localhost port: 8080 repository: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s host: localhost port: 5432 snapshot: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s @@ -25,6 +27,7 @@ broker: host: localhost port: 9092 queue: + client: minos.common.AiopgDatabaseClient database: order_db user: minos password: min0s From 5ec3822a327b22bc631fa0795a1d616d8b112314 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 13:11:34 +0200 Subject: [PATCH 164/324] ISSUE #371 * Remove `PostgreSqlEventRepository`. * Remove `PostgreSqlSnapshotReader`. * Remove `PostgreSqlSnapshotRepository`. * Remove `PostgreSqlSnapshotQueryBuilder`. * Remove `PostgreSqlSnapshotWriter`. * Remove `PostgreSqlSnapshotSetup`. * Remove `PostgreSqlTransactionRepository`. --- .../minos/aggregate/__init__.py | 7 ------- .../minos/aggregate/events/__init__.py | 1 - .../minos/aggregate/events/repositories/__init__.py | 1 - .../events/repositories/database/__init__.py | 1 - .../aggregate/events/repositories/database/impl.py | 12 ------------ .../minos/aggregate/snapshots/__init__.py | 5 ----- .../minos/aggregate/snapshots/database/__init__.py | 5 ----- .../minos/aggregate/snapshots/database/abc.py | 12 ------------ .../minos/aggregate/snapshots/database/api.py | 12 ------------ .../snapshots/database/factories/__init__.py | 1 - .../snapshots/database/factories/aiopg/__init__.py | 1 - .../snapshots/database/factories/aiopg/queries.py | 13 ------------- .../minos/aggregate/snapshots/database/readers.py | 12 ------------ .../minos/aggregate/snapshots/database/writers.py | 12 ------------ .../minos/aggregate/transactions/__init__.py | 1 - .../aggregate/transactions/repositories/__init__.py | 1 - .../transactions/repositories/database/__init__.py | 1 - .../transactions/repositories/database/impl.py | 12 ------------ .../test_snapshots/test_pg/test_abc.py | 2 +- .../test_snapshots/test_pg/test_api.py | 2 +- .../test_snapshots/test_pg/test_queries.py | 2 +- .../test_snapshots/test_pg/test_readers.py | 2 +- .../test_snapshots/test_pg/test_writers.py | 2 +- .../test_transactions/test_repositories/test_pg.py | 4 ++-- 24 files changed, 7 insertions(+), 117 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index 47b78e6e4..ea5b00680 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -39,7 +39,6 @@ FieldDiffContainer, IncrementalFieldDiff, InMemoryEventRepository, - PostgreSqlEventRepository, ) from .exceptions import ( AggregateException, @@ -67,11 +66,6 @@ DatabaseSnapshotSetup, DatabaseSnapshotWriter, InMemorySnapshotRepository, - PostgreSqlSnapshotQueryBuilder, - PostgreSqlSnapshotReader, - PostgreSqlSnapshotRepository, - PostgreSqlSnapshotSetup, - PostgreSqlSnapshotWriter, SnapshotDatabaseOperationFactory, SnapshotEntry, SnapshotRepository, @@ -82,7 +76,6 @@ AiopgTransactionDatabaseOperationFactory, DatabaseTransactionRepository, InMemoryTransactionRepository, - PostgreSqlTransactionRepository, TransactionDatabaseOperationFactory, TransactionEntry, TransactionRepository, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py index 9160f0aec..30785fd95 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py @@ -15,5 +15,4 @@ EventDatabaseOperationFactory, EventRepository, InMemoryEventRepository, - PostgreSqlEventRepository, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py index 2fc258715..779f5963e 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py @@ -5,7 +5,6 @@ AiopgEventDatabaseOperationFactory, DatabaseEventRepository, EventDatabaseOperationFactory, - PostgreSqlEventRepository, ) from .memory import ( InMemoryEventRepository, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py index 67a032ed8..a16590570 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py @@ -4,5 +4,4 @@ ) from .impl import ( DatabaseEventRepository, - PostgreSqlEventRepository, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index 3bec19f89..f25c0dc5c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -2,7 +2,6 @@ annotations, ) -import warnings from typing import ( AsyncIterator, Optional, @@ -96,14 +95,3 @@ async def _offset(self) -> int: operation = self.operation_factory.build_select_max_id() row = await self.submit_query_and_fetchone(operation) return row[0] or 0 - - -class PostgreSqlEventRepository(DatabaseEventRepository): - """TODO""" - - def __init__(self, *args, **kwargs): - warnings.warn( - f"{PostgreSqlEventRepository!r} has been deprecated. Use {DatabaseEventRepository} instead.", - DeprecationWarning, - ) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py index 66d3830ab..2e568ba02 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py @@ -8,11 +8,6 @@ DatabaseSnapshotRepository, DatabaseSnapshotSetup, DatabaseSnapshotWriter, - PostgreSqlSnapshotQueryBuilder, - PostgreSqlSnapshotReader, - PostgreSqlSnapshotRepository, - PostgreSqlSnapshotSetup, - PostgreSqlSnapshotWriter, SnapshotDatabaseOperationFactory, ) from .entries import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py index 8e2aed6d8..038c6d32c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py @@ -1,22 +1,17 @@ from .abc import ( DatabaseSnapshotSetup, - PostgreSqlSnapshotSetup, ) from .api import ( DatabaseSnapshotRepository, - PostgreSqlSnapshotRepository, ) from .factories import ( AiopgSnapshotDatabaseOperationFactory, AiopgSnapshotQueryDatabaseOperationBuilder, - PostgreSqlSnapshotQueryBuilder, SnapshotDatabaseOperationFactory, ) from .readers import ( DatabaseSnapshotReader, - PostgreSqlSnapshotReader, ) from .writers import ( DatabaseSnapshotWriter, - PostgreSqlSnapshotWriter, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py index f8ed834cf..2d1e05cdc 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py @@ -2,7 +2,6 @@ annotations, ) -import warnings from typing import ( Optional, Type, @@ -44,14 +43,3 @@ async def _setup(self) -> None: T = TypeVar("T", bound=DatabaseSnapshotSetup) - - -class PostgreSqlSnapshotSetup(DatabaseSnapshotSetup): - """TODO""" - - def __init__(self, *args, **kwargs): - warnings.warn( - f"{PostgreSqlSnapshotSetup!r} has been deprecated. Use {DatabaseSnapshotSetup} instead.", - DeprecationWarning, - ) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py index cdb71eb1e..060de5976 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py @@ -2,7 +2,6 @@ annotations, ) -import warnings from typing import ( TYPE_CHECKING, AsyncIterator, @@ -72,14 +71,3 @@ def _find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: def _synchronize(self, *args, **kwargs) -> Awaitable[None]: return self.writer.dispatch(**kwargs) - - -class PostgreSqlSnapshotRepository(DatabaseSnapshotRepository): - """TODO""" - - def __init__(self, *args, **kwargs): - warnings.warn( - f"{PostgreSqlSnapshotRepository!r} has been deprecated. Use {DatabaseSnapshotRepository} instead.", - DeprecationWarning, - ) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py index beca8f414..dd9c232cc 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py @@ -4,5 +4,4 @@ from .aiopg import ( AiopgSnapshotDatabaseOperationFactory, AiopgSnapshotQueryDatabaseOperationBuilder, - PostgreSqlSnapshotQueryBuilder, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py index 48d06f584..0edcf80f2 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py @@ -3,5 +3,4 @@ ) from .queries import ( AiopgSnapshotQueryDatabaseOperationBuilder, - PostgreSqlSnapshotQueryBuilder, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py index 961e2694b..8d4f53d0c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py @@ -2,7 +2,6 @@ annotations, ) -import warnings from typing import ( Any, Optional, @@ -271,15 +270,3 @@ def generate_random_str() -> str: ) _EXCLUDE_DELETED_CONDITION = SQL("(data IS NOT NULL)") - - -class PostgreSqlSnapshotQueryBuilder(AiopgSnapshotQueryDatabaseOperationBuilder): - """TODO""" - - def __init__(self, *args, **kwargs): - warnings.warn( - f"{PostgreSqlSnapshotQueryBuilder!r} has been deprecated. " - f"Use {AiopgSnapshotQueryDatabaseOperationBuilder} instead.", - DeprecationWarning, - ) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py index d5c0a0fa8..f2b9f4307 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py @@ -3,7 +3,6 @@ ) import logging -import warnings from typing import ( TYPE_CHECKING, AsyncIterator, @@ -130,14 +129,3 @@ async def find_entries( async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): yield SnapshotEntry(*row) - - -class PostgreSqlSnapshotReader(DatabaseSnapshotReader): - """TODO""" - - def __init__(self, *args, **kwargs): - warnings.warn( - f"{PostgreSqlSnapshotReader!r} has been deprecated. Use {DatabaseSnapshotReader} instead.", - DeprecationWarning, - ) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py index ee60cc60b..4a241902e 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py @@ -2,7 +2,6 @@ annotations, ) -import warnings from typing import ( TYPE_CHECKING, Type, @@ -183,14 +182,3 @@ async def _clean_transactions(self, offset: int, **kwargs) -> None: if len(transaction_uuids): operation = self.operation_factory.build_delete_by_transactions(transaction_uuids) await self.submit_query(operation) - - -class PostgreSqlSnapshotWriter(DatabaseSnapshotWriter): - """TODO""" - - def __init__(self, *args, **kwargs): - warnings.warn( - f"{PostgreSqlSnapshotWriter!r} has been deprecated. Use {DatabaseSnapshotWriter} instead.", - DeprecationWarning, - ) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py index 15006d9a6..2a2e506dd 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py @@ -9,7 +9,6 @@ AiopgTransactionDatabaseOperationFactory, DatabaseTransactionRepository, InMemoryTransactionRepository, - PostgreSqlTransactionRepository, TransactionDatabaseOperationFactory, TransactionRepository, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py index 3d46383fd..33907a58d 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py @@ -4,7 +4,6 @@ from .database import ( AiopgTransactionDatabaseOperationFactory, DatabaseTransactionRepository, - PostgreSqlTransactionRepository, TransactionDatabaseOperationFactory, ) from .memory import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py index 7a5ac1eb6..8c6f72e99 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py @@ -4,5 +4,4 @@ ) from .impl import ( DatabaseTransactionRepository, - PostgreSqlTransactionRepository, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index 061fee499..2c14f3db9 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -2,7 +2,6 @@ annotations, ) -import warnings from typing import ( AsyncIterator, Optional, @@ -71,14 +70,3 @@ async def _select(self, streaming_mode: Optional[bool] = None, **kwargs) -> Asyn operation = self.operation_factory.build_select_rows(**kwargs) async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): yield TransactionEntry(*row, transaction_repository=self) - - -class PostgreSqlTransactionRepository(DatabaseTransactionRepository): - """TODO""" - - def __init__(self, *args, **kwargs): - warnings.warn( - f"{PostgreSqlTransactionRepository!r} has been deprecated. Use {DatabaseTransactionRepository} instead.", - DeprecationWarning, - ) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py index e673be946..208fd4893 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py @@ -16,7 +16,7 @@ # noinspection SqlNoDataSourceInspection -class TestPostgreSqlSnapshotSetup(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseSnapshotSetup(AggregateTestCase, PostgresAsyncTestCase): async def test_setup_snapshot_table(self): async with DatabaseSnapshotSetup.from_config(self.config): async with AiopgDatabaseClient(**self.config.get_default_database()) as client: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py index 7f552c652..285bb3d1b 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py @@ -25,7 +25,7 @@ ) -class TestPostgreSqlSnapshotRepository(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseSnapshotRepository(AggregateTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py index 649f324d3..01990d421 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py @@ -34,7 +34,7 @@ ) -class TestPostgreSqlSnapshotQueryBuilder(AggregateTestCase, PostgresAsyncTestCase): +class TestAiopgSnapshotQueryDatabaseOperationBuilder(AggregateTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.classname = "path.to.Product" diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py index 91a8ab2d8..0750def45 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py @@ -33,7 +33,7 @@ ) -class TestPostgreSqlSnapshotReader(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseSnapshotReader(AggregateTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py index b73d5cb19..23e86f9b4 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py @@ -39,7 +39,7 @@ ) -class TestPostgreSqlSnapshotWriter(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseSnapshotWriter(AggregateTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.uuid_1 = uuid4() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index a9dc0dab5..99012ef56 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -24,7 +24,7 @@ # noinspection SqlNoDataSourceInspection -class TestPostgreSqlTransactionRepository(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseTransactionRepository(AggregateTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() @@ -146,7 +146,7 @@ async def test_submit_rejected_raises(self): await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.REJECTED, 34)) -class TestPostgreSqlTransactionRepositorySelect(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseTransactionRepositorySelect(AggregateTestCase, PostgresAsyncTestCase): def setUp(self) -> None: super().setUp() self.uuid_1 = uuid4() From 665a4248b5d9c599387dc4503cff5e5cb50ede31 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 14:27:49 +0200 Subject: [PATCH 165/324] ISSUE #371 * Rename `PostgresAsyncTestCase` as `DatabaseMinosTestCase` --- .../test_models/test_root/test_with_postgresql.py | 4 ++-- .../test_events/test_repositories/test_pg.py | 6 +++--- .../test_aggregate/test_snapshots/test_pg/test_abc.py | 4 ++-- .../test_aggregate/test_snapshots/test_pg/test_api.py | 4 ++-- .../test_snapshots/test_pg/test_queries.py | 4 ++-- .../test_snapshots/test_pg/test_readers.py | 4 ++-- .../test_snapshots/test_pg/test_writers.py | 4 ++-- .../test_aggregate/test_snapshots/test_services.py | 4 ++-- .../test_transactions/test_repositories/test_pg.py | 6 +++--- .../test_aggregate/test_transactions/test_services.py | 4 ++-- .../minos-microservice-common/minos/common/testing.py | 3 +-- .../tests/test_common/test_database/test_abc.py | 6 +++--- .../test_database/test_clients/test_aiopg.py | 4 ++-- .../tests/test_common/test_database/test_locks.py | 6 +++--- .../tests/test_common/test_database/test_pools.py | 10 +++++----- .../tests/test_common/test_launchers.py | 4 ++-- .../tests/test_common/test_testing.py | 4 ++-- .../tests/test_cqrs/test_services.py | 8 ++++---- .../tests/test_networks/test_brokers/test_clients.py | 4 ++-- .../test_collections/test_queues/test_pg.py | 4 ++-- .../test_brokers/test_dispatchers/test_impl.py | 4 ++-- .../test_brokers/test_handlers/test_ports.py | 4 ++-- .../tests/test_networks/test_brokers/test_pools.py | 4 ++-- .../test_publishers/test_queued/test_queues/test_pg.py | 4 ++-- .../test_validators/test_duplicates/test_pg.py | 4 ++-- .../test_queued/test_queues/test_pg.py | 6 +++--- .../tests/test_networks/test_scheduling/test_ports.py | 4 ++-- .../tests/test_kafka/test_publisher.py | 4 ++-- .../tests/test_kafka/test_subscriber.py | 4 ++-- 29 files changed, 67 insertions(+), 68 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py index 75e22474d..bc9306f75 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py @@ -9,7 +9,7 @@ ValueObjectSet, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( AggregateTestCase, @@ -20,7 +20,7 @@ ) -class TestExternalEntityWithPostgreSql(AggregateTestCase, PostgresAsyncTestCase): +class TestExternalEntityWithPostgreSql(AggregateTestCase, DatabaseMinosTestCase): def setUp(self): super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index ba1556169..aed6149c3 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -10,7 +10,7 @@ DatabaseClientPool, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.testcases import ( EventRepositorySelectTestCase, @@ -19,7 +19,7 @@ # noinspection SqlNoDataSourceInspection -class TestDatabaseEventRepositorySubmit(EventRepositorySubmitTestCase, PostgresAsyncTestCase): +class TestDatabaseEventRepositorySubmit(EventRepositorySubmitTestCase, DatabaseMinosTestCase): __test__ = True @staticmethod @@ -47,7 +47,7 @@ async def test_setup(self): self.assertTrue(response) -class TestPostgreSqlRepositorySelect(EventRepositorySelectTestCase, PostgresAsyncTestCase): +class TestPostgreSqlRepositorySelect(EventRepositorySelectTestCase, DatabaseMinosTestCase): __test__ = True @staticmethod diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py index 208fd4893..688d092ef 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py @@ -8,7 +8,7 @@ AiopgDatabaseOperation, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( AggregateTestCase, @@ -16,7 +16,7 @@ # noinspection SqlNoDataSourceInspection -class TestDatabaseSnapshotSetup(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseSnapshotSetup(AggregateTestCase, DatabaseMinosTestCase): async def test_setup_snapshot_table(self): async with DatabaseSnapshotSetup.from_config(self.config): async with AiopgDatabaseClient(**self.config.get_default_database()) as client: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py index 285bb3d1b..45c387dc9 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py @@ -17,7 +17,7 @@ TransactionEntry, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( AggregateTestCase, @@ -25,7 +25,7 @@ ) -class TestDatabaseSnapshotRepository(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseSnapshotRepository(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py index 01990d421..bc3403e5b 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py @@ -27,14 +27,14 @@ AiopgDatabaseClient, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( AggregateTestCase, ) -class TestAiopgSnapshotQueryDatabaseOperationBuilder(AggregateTestCase, PostgresAsyncTestCase): +class TestAiopgSnapshotQueryDatabaseOperationBuilder(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.classname = "path.to.Product" diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py index 0750def45..4f447cc14 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py @@ -25,7 +25,7 @@ DatabaseClientPool, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( AggregateTestCase, @@ -33,7 +33,7 @@ ) -class TestDatabaseSnapshotReader(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseSnapshotReader(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py index 23e86f9b4..c3c406628 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py @@ -31,7 +31,7 @@ current_datetime, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( AggregateTestCase, @@ -39,7 +39,7 @@ ) -class TestDatabaseSnapshotWriter(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseSnapshotWriter(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.uuid_1 = uuid4() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py index 3afa310bd..e552e9104 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_services.py @@ -17,7 +17,7 @@ ModelType, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( BrokerCommandEnrouteDecorator, @@ -33,7 +33,7 @@ Agg = ModelType.build("Agg", {"uuid": UUID}) -class TestSnapshotService(AggregateTestCase, PostgresAsyncTestCase): +class TestSnapshotService(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index 99012ef56..424dbf54b 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -16,7 +16,7 @@ DatabaseClientPool, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( AggregateTestCase, @@ -24,7 +24,7 @@ # noinspection SqlNoDataSourceInspection -class TestDatabaseTransactionRepository(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseTransactionRepository(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() @@ -146,7 +146,7 @@ async def test_submit_rejected_raises(self): await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.REJECTED, 34)) -class TestDatabaseTransactionRepositorySelect(AggregateTestCase, PostgresAsyncTestCase): +class TestDatabaseTransactionRepositorySelect(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.uuid_1 = uuid4() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py index 06315bde2..1fb1c1a6a 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_services.py @@ -22,7 +22,7 @@ current_datetime, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( BrokerCommandEnrouteDecorator, @@ -36,7 +36,7 @@ ) -class TestSnapshotService(AggregateTestCase, PostgresAsyncTestCase): +class TestSnapshotService(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index d61f2365a..a9f3cf4f7 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -76,8 +76,7 @@ def __getattr__(self, item: str) -> Any: raise AttributeError(f"{type(self).__name__!r} does not contain the {item!r} attribute.") -# noinspection SqlNoDataSourceInspection -class PostgresAsyncTestCase(MinosTestCase, ABC): +class DatabaseMinosTestCase(MinosTestCase, ABC): def setUp(self): self.base_config = Config(self.get_config_file_path()) self._uuid = uuid4() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index cad8123c9..bb97ae9b4 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -12,7 +12,7 @@ PostgreSqlPool, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( CommonTestCase, @@ -20,7 +20,7 @@ # noinspection SqlNoDataSourceInspection,SqlResolve -class TestDatabaseMixin(CommonTestCase, PostgresAsyncTestCase): +class TestDatabaseMixin(CommonTestCase, DatabaseMinosTestCase): def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) database = DatabaseMixin(pool) @@ -125,7 +125,7 @@ async def test_submit_query_and_iter_locked(self): self.assertEqual([(3,), (4,), (5,)], observed) -class TestPostgreSqlMinosDatabase(CommonTestCase, PostgresAsyncTestCase): +class TestPostgreSqlMinosDatabase(CommonTestCase, DatabaseMinosTestCase): def test_is_subclass(self): self.assertTrue(issubclass(PostgreSqlMinosDatabase, DatabaseMixin)) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py index 270eb1916..d275b2d1b 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py @@ -23,7 +23,7 @@ UnableToConnectException, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( CommonTestCase, @@ -31,7 +31,7 @@ # noinspection SqlNoDataSourceInspection -class TestAiopgDatabaseClient(CommonTestCase, PostgresAsyncTestCase): +class TestAiopgDatabaseClient(CommonTestCase, DatabaseMinosTestCase): def setUp(self): super().setUp() self.operation = AiopgDatabaseOperation("SELECT * FROM information_schema.tables") diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py index 19ff08541..37e2b425f 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py @@ -8,14 +8,14 @@ PostgreSqlLock, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( CommonTestCase, ) -class TestDatabaseLock(CommonTestCase, PostgresAsyncTestCase): +class TestDatabaseLock(CommonTestCase, DatabaseMinosTestCase): def test_base(self): self.assertTrue(issubclass(DatabaseLock, Lock)) @@ -40,7 +40,7 @@ async def test_hashed_key(self): self.assertEqual(hash("foo"), lock.hashed_key) -class TestPostgreSqlLock(CommonTestCase, PostgresAsyncTestCase): +class TestPostgreSqlLock(CommonTestCase, DatabaseMinosTestCase): def test_is_subclass(self): self.assertTrue(issubclass(PostgreSqlLock, DatabaseLock)) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index fe7ff66ce..07568c79a 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -16,14 +16,14 @@ UnableToConnectException, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( CommonTestCase, ) -class TestDatabaseClientPool(CommonTestCase, PostgresAsyncTestCase): +class TestDatabaseClientPool(CommonTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.pool = DatabaseClientPool.from_config(self.config) @@ -74,7 +74,7 @@ async def test_acquire_with_connection_error(self): self.assertIsInstance(client, AiopgDatabaseClient) -class TestPostgreSqlPool(CommonTestCase, PostgresAsyncTestCase): +class TestPostgreSqlPool(CommonTestCase, DatabaseMinosTestCase): def test_is_subclass(self): self.assertTrue(issubclass(PostgreSqlPool, DatabaseClientPool)) @@ -85,7 +85,7 @@ def test_warnings(self): self.assertIsInstance(pool, DatabaseClientPool) -class TestDatabaseLockPool(CommonTestCase, PostgresAsyncTestCase): +class TestDatabaseLockPool(CommonTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.pool = DatabaseLockPool.from_config(self.config) @@ -104,7 +104,7 @@ async def test_acquire(self): self.assertEqual("foo", lock.key) -class TestPostgreSqlLockPool(CommonTestCase, PostgresAsyncTestCase): +class TestPostgreSqlLockPool(CommonTestCase, DatabaseMinosTestCase): def test_is_subclass(self): self.assertTrue(issubclass(PostgreSqlLockPool, DatabaseLockPool)) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_launchers.py b/packages/core/minos-microservice-common/tests/test_common/test_launchers.py index b876792b1..365647151 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_launchers.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_launchers.py @@ -16,7 +16,7 @@ classname, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( CONFIG_FILE_PATH, @@ -40,7 +40,7 @@ async def _stop(self, err: Exception = None) -> None: """For testing purposes.""" -class TestEntrypointLauncher(CommonTestCase, PostgresAsyncTestCase): +class TestEntrypointLauncher(CommonTestCase, DatabaseMinosTestCase): def setUp(self): super().setUp() self.injections = list() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_testing.py b/packages/core/minos-microservice-common/tests/test_common/test_testing.py index bfb899baf..a80a4fe6d 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_testing.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_testing.py @@ -6,7 +6,7 @@ ) from minos.common.testing import ( MinosTestCase, - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from tests.utils import ( CONFIG_FILE_PATH, @@ -33,7 +33,7 @@ class TestPostgresAsyncTestCase(unittest.IsolatedAsyncioTestCase): pass -class MyPostgresAsyncTestCase(PostgresAsyncTestCase): +class MyDatabaseMinosTestCase(DatabaseMinosTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH diff --git a/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py b/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py index bb3448cfc..4ebbe5639 100644 --- a/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py +++ b/packages/core/minos-microservice-cqrs/tests/test_cqrs/test_services.py @@ -12,7 +12,7 @@ PoolFactory, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.cqrs import ( MinosIllegalHandlingException, @@ -32,7 +32,7 @@ ) -class TestService(PostgresAsyncTestCase): +class TestService(DatabaseMinosTestCase): CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" def setUp(self) -> None: @@ -67,7 +67,7 @@ async def test_pre_event(self): self.assertEqual(1, mock.call_count) -class TestQueryService(PostgresAsyncTestCase): +class TestQueryService(DatabaseMinosTestCase): CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" def setUp(self) -> None: @@ -94,7 +94,7 @@ def test_get_enroute(self): self.assertEqual(expected, observed) -class TestCommandService(PostgresAsyncTestCase): +class TestCommandService(DatabaseMinosTestCase): CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" def setUp(self) -> None: diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_clients.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_clients.py index 52ede53ae..44ba60707 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_clients.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_clients.py @@ -13,7 +13,7 @@ SetupMixin, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( BrokerClient, @@ -29,7 +29,7 @@ ) -class TestBrokerClient(NetworksTestCase, PostgresAsyncTestCase): +class TestBrokerClient(NetworksTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.topic = "fooReply" diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index a99511e41..9815e3e49 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -12,7 +12,7 @@ DatabaseMixin, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( AiopgBrokerQueueDatabaseOperationFactory, @@ -35,7 +35,7 @@ def build_table_name(self) -> str: return "test_table" -class TestPostgreSqlBrokerQueue(NetworksTestCase, PostgresAsyncTestCase): +class TestPostgreSqlBrokerQueue(NetworksTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.operation_factory = _AiopgBrokerQueueDatabaseOperationFactory() diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_dispatchers/test_impl.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_dispatchers/test_impl.py index f7224a039..d29d0e14a 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_dispatchers/test_impl.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_dispatchers/test_impl.py @@ -12,7 +12,7 @@ NotProvidedException, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( REQUEST_HEADERS_CONTEXT_VAR, @@ -58,7 +58,7 @@ async def _fn_raises_exception(request: Request) -> Response: raise ValueError -class TestBrokerDispatcher(NetworksTestCase, PostgresAsyncTestCase): +class TestBrokerDispatcher(NetworksTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_handlers/test_ports.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_handlers/test_ports.py index d4f5221ba..cb177981f 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_handlers/test_ports.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_handlers/test_ports.py @@ -8,7 +8,7 @@ Port, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( BrokerHandler, @@ -22,7 +22,7 @@ ) -class TestBrokerPort(NetworksTestCase, PostgresAsyncTestCase): +class TestBrokerPort(NetworksTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.publisher = InMemoryBrokerPublisher.from_config(self.config) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_pools.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_pools.py index 020812099..c75638572 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_pools.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_pools.py @@ -1,7 +1,7 @@ import unittest from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( REQUEST_REPLY_TOPIC_CONTEXT_VAR, @@ -15,7 +15,7 @@ ) -class TestBrokerClientPool(NetworksTestCase, PostgresAsyncTestCase): +class TestBrokerClientPool(NetworksTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.publisher = InMemoryBrokerPublisher.from_config(self.config) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py index 37d06f314..d9af6ffc4 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py @@ -1,7 +1,7 @@ import unittest from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( AiopgBrokerPublisherQueueDatabaseOperationFactory, @@ -14,7 +14,7 @@ ) -class TestPostgreSqlBrokerPublisherQueue(NetworksTestCase, PostgresAsyncTestCase): +class TestPostgreSqlBrokerPublisherQueue(NetworksTestCase, DatabaseMinosTestCase): def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerPublisherQueue, (DatabaseBrokerQueue, BrokerPublisherQueue))) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py index d118c38e2..c3336b876 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py @@ -1,7 +1,7 @@ import unittest from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, @@ -15,7 +15,7 @@ ) -class TestPostgreSqlBrokerSubscriberDuplicateValidator(NetworksTestCase, PostgresAsyncTestCase): +class TestPostgreSqlBrokerSubscriberDuplicateValidator(NetworksTestCase, DatabaseMinosTestCase): def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerSubscriberDuplicateValidator, BrokerSubscriberValidator)) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py index d5842be30..bdb5d6a11 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py @@ -11,7 +11,7 @@ AiopgDatabaseClient, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( AiopgBrokerSubscriberQueueDatabaseOperationFactory, @@ -28,7 +28,7 @@ ) -class TestPostgreSqlBrokerSubscriberQueue(NetworksTestCase, PostgresAsyncTestCase): +class TestPostgreSqlBrokerSubscriberQueue(NetworksTestCase, DatabaseMinosTestCase): def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerSubscriberQueue, (DatabaseBrokerQueue, BrokerSubscriberQueue))) @@ -85,7 +85,7 @@ def test_build_table_name(self): self.assertEqual("broker_subscriber_queue", self.factory.build_table_name()) -class TestPostgreSqlBrokerSubscriberQueueBuilder(NetworksTestCase, PostgresAsyncTestCase): +class TestPostgreSqlBrokerSubscriberQueueBuilder(NetworksTestCase, DatabaseMinosTestCase): def test_build(self): builder = DatabaseBrokerSubscriberQueueBuilder().with_config(self.config).with_topics({"one", "two"}) subscriber = builder.build() diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_scheduling/test_ports.py b/packages/core/minos-microservice-networks/tests/test_networks/test_scheduling/test_ports.py index 92b1a1234..18ebc5aa2 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_scheduling/test_ports.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_scheduling/test_ports.py @@ -8,7 +8,7 @@ Port, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( PeriodicPort, @@ -20,7 +20,7 @@ ) -class TestPeriodicPort(NetworksTestCase, PostgresAsyncTestCase): +class TestPeriodicPort(NetworksTestCase, DatabaseMinosTestCase): def test_is_instance(self): service = PeriodicPort(config=self.config) self.assertIsInstance(service, Port) diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py index 8d7286311..9761c6e4c 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py @@ -15,7 +15,7 @@ Config, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( BrokerMessage, @@ -154,7 +154,7 @@ def test_build(self): self.assertEqual(common_config["port"], publisher.port) -class TestPostgreSqlQueuedKafkaBrokerPublisher(PostgresAsyncTestCase): +class TestPostgreSqlQueuedKafkaBrokerPublisher(DatabaseMinosTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def test_from_config(self): diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py index 393c951f6..80f1d354a 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py @@ -23,7 +23,7 @@ Config, ) from minos.common.testing import ( - PostgresAsyncTestCase, + DatabaseMinosTestCase, ) from minos.networks import ( BrokerMessageV1, @@ -253,7 +253,7 @@ def test_build(self): self.assertEqual(common_config["port"], subscriber.port) -class TestPostgreSqlQueuedKafkaBrokerSubscriberBuilder(PostgresAsyncTestCase): +class TestPostgreSqlQueuedKafkaBrokerSubscriberBuilder(DatabaseMinosTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH def test_build(self): From e1d3bf90cbc00aec04027d189e5c006541c4daec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 14:59:54 +0200 Subject: [PATCH 166/324] ISSUE #371 * Remove `PostgreSql*` like classes. --- .../events/repositories/database/impl.py | 6 +-- .../minos/aggregate/snapshots/database/api.py | 2 +- .../database/factories/aiopg/queries.py | 2 +- .../aggregate/snapshots/database/readers.py | 2 +- .../repositories/database/impl.py | 2 +- .../test_root/test_with_postgresql.py | 2 +- .../test_events/test_repositories/test_pg.py | 2 +- .../minos/common/__init__.py | 4 -- .../minos/common/database/__init__.py | 4 -- .../minos/common/database/locks/__init__.py | 1 - .../minos/common/database/locks/impl.py | 9 ---- .../minos/common/database/mixins.py | 19 +-------- .../minos/common/database/pools.py | 27 ++---------- .../minos/common/locks.py | 2 +- .../test_common/test_database/test_abc.py | 25 ----------- .../test_common/test_database/test_locks.py | 15 ------- .../test_common/test_database/test_pools.py | 25 ----------- .../tests/test_common/test_testing.py | 4 +- .../queues/database/factories/abc.py | 2 +- .../queues/database/factories/aiopg.py | 2 +- .../collections/queues/database/impl.py | 6 +-- .../publishers/queued/queues/database.py | 6 +-- .../duplicates/database/factories/aiopg.py | 2 +- .../validators/duplicates/database/impl.py | 4 +- .../queued/queues/database/factories/abc.py | 2 +- .../queued/queues/database/factories/aiopg.py | 2 +- .../queued/queues/database/impl.py | 4 +- .../test_collections/test_queues/test_pg.py | 2 +- .../test_queued/test_queues/test_pg.py | 4 +- .../test_duplicates/test_pg.py | 2 +- .../test_queued/test_queues/test_pg.py | 6 +-- .../minos/plugins/kafka/__init__.py | 4 -- .../minos/plugins/kafka/publisher.py | 35 ---------------- .../minos/plugins/kafka/subscriber.py | 27 ------------ .../tests/test_kafka/test_publisher.py | 30 ------------- .../tests/test_kafka/test_subscriber.py | 42 ------------------- 36 files changed, 38 insertions(+), 297 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index f25c0dc5c..75bd099bb 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -30,7 +30,7 @@ class DatabaseEventRepository(DatabaseMixin, EventRepository): - """PostgreSQL-based implementation of the event repository class in ``Minos``.""" + """Database-based implementation of the event repository class.""" def __init__( self, @@ -49,9 +49,7 @@ def _from_config(cls, config: Config, **kwargs) -> Optional[EventRepository]: return super()._from_config(config, database_key=None, **kwargs) async def _setup(self): - """Setup miscellaneous repository thing. - - In the PostgreSQL case, configures the needed table to be used to store the data. + """Setup miscellaneous repository things. :return: This method does not return anything. """ diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py index 060de5976..6872540ce 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py @@ -29,7 +29,7 @@ class DatabaseSnapshotRepository(SnapshotRepository): - """PostgreSQL Snapshot class. + """Database Snapshot Repository class. The snapshot provides a direct accessor to the ``RootEntity`` instances stored as events by the event repository class. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py index 8d4f53d0c..bf65b4174 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py @@ -54,7 +54,7 @@ # noinspection SqlResolve,SqlNoDataSourceInspection class AiopgSnapshotQueryDatabaseOperationBuilder: - """PostgreSQL Snapshot Query Builder class. + """Aiopg Snapshot Query Database Operation Builder class. This class build postgres-compatible database queries over fields based on a condition, ordering, etc. """ diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py index f2b9f4307..1dfca2862 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py @@ -43,7 +43,7 @@ class DatabaseSnapshotReader(DatabaseSnapshotSetup): - """PostgreSQL Snapshot class. + """Database Snapshot Reader class. The snapshot provides a direct accessor to the ``RootEntity`` instances stored as events by the event repository class. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index 2c14f3db9..06ea3070a 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -27,7 +27,7 @@ class DatabaseTransactionRepository(DatabaseMixin, TransactionRepository): - """PostgreSql Transaction Repository class.""" + """Database Transaction Repository class.""" def __init__( self, diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py index bc9306f75..923dafd53 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_models/test_root/test_with_postgresql.py @@ -20,7 +20,7 @@ ) -class TestExternalEntityWithPostgreSql(AggregateTestCase, DatabaseMinosTestCase): +class TestExternalEntityWithDatabase(AggregateTestCase, DatabaseMinosTestCase): def setUp(self): super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index aed6149c3..35b36595e 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -47,7 +47,7 @@ async def test_setup(self): self.assertTrue(response) -class TestPostgreSqlRepositorySelect(EventRepositorySelectTestCase, DatabaseMinosTestCase): +class TestDatabaseEventRepositorySelect(EventRepositorySelectTestCase, DatabaseMinosTestCase): __test__ = True @staticmethod diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index e1dd32b9f..44b04748c 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -31,10 +31,6 @@ IntegrityException, LockDatabaseOperationFactory, ManageDatabaseOperationFactory, - PostgreSqlLock, - PostgreSqlLockPool, - PostgreSqlMinosDatabase, - PostgreSqlPool, UnableToConnectException, ) from .datetime import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index 70d762fe3..7f3e5676c 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -10,7 +10,6 @@ AiopgLockDatabaseOperationFactory, DatabaseLock, LockDatabaseOperationFactory, - PostgreSqlLock, ) from .manage import ( AiopgManageDatabaseOperationFactory, @@ -18,7 +17,6 @@ ) from .mixins import ( DatabaseMixin, - PostgreSqlMinosDatabase, ) from .operations import ( AiopgDatabaseOperation, @@ -29,6 +27,4 @@ from .pools import ( DatabaseClientPool, DatabaseLockPool, - PostgreSqlLockPool, - PostgreSqlPool, ) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py b/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py index 9083f5c26..4f02878f1 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py @@ -4,5 +4,4 @@ ) from .impl import ( DatabaseLock, - PostgreSqlLock, ) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/impl.py b/packages/core/minos-microservice-common/minos/common/database/locks/impl.py index 24a4e3bdd..b0dba9646 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/impl.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/impl.py @@ -2,7 +2,6 @@ annotations, ) -import warnings from collections.abc import ( Hashable, ) @@ -55,11 +54,3 @@ async def release(self) -> None: """ operation = self.operation_factory.build_release(self.hashed_key) await self.client.execute(operation) - - -class PostgreSqlLock(DatabaseLock): - """PostgreSql Lock class.""" - - def __init__(self, *args, **kwargs): - warnings.warn(f"{PostgreSqlLock!r} has been deprecated. Use {DatabaseLock} instead.", DeprecationWarning) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/database/mixins.py b/packages/core/minos-microservice-common/minos/common/database/mixins.py index 9f517ac2b..2b0eae794 100644 --- a/packages/core/minos-microservice-common/minos/common/database/mixins.py +++ b/packages/core/minos-microservice-common/minos/common/database/mixins.py @@ -1,4 +1,3 @@ -import warnings from typing import ( AsyncIterator, Optional, @@ -22,12 +21,11 @@ from .pools import ( DatabaseClient, DatabaseClientPool, - PostgreSqlPool, ) class DatabaseMixin(SetupMixin): - """PostgreSql Minos Database base class.""" + """Database Mixin class.""" @Inject() def __init__( @@ -35,7 +33,6 @@ def __init__( database_pool: Optional[DatabaseClientPool] = None, pool_factory: Optional[PoolFactory] = None, database_key: Optional[str] = None, - postgresql_pool: Optional[PostgreSqlPool] = None, *args, **kwargs, ): @@ -43,10 +40,6 @@ def __init__( if database_pool is None and pool_factory is not None: database_pool = pool_factory.get_pool(type_="database", identifier=database_key) - if database_pool is None and postgresql_pool is not None: - warnings.warn("'postgresql_pool' argument has been deprecated", DeprecationWarning) - database_pool = postgresql_pool - if not isinstance(database_pool, DatabaseClientPool): raise NotProvidedException(f"A {DatabaseClientPool!r} instance is required. Obtained: {database_pool}") @@ -114,13 +107,3 @@ def pool(self) -> DatabaseClientPool: :return: A ``Pool`` object. """ return self._pool - - -class PostgreSqlMinosDatabase(DatabaseMixin): - """PostgreSql Minos Database class.""" - - def __init__(self, *args, **kwargs): - warnings.warn( - f"{PostgreSqlMinosDatabase!r} has been deprecated. Use {DatabaseMixin} instead.", DeprecationWarning - ) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 599ff0fbb..268d9b75a 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -1,5 +1,4 @@ import logging -import warnings from asyncio import ( sleep, ) @@ -38,6 +37,7 @@ logger = logging.getLogger(__name__) +@Injectable("database_pool") class DatabaseClientPool(Pool[DatabaseClient]): """Database Client Pool class.""" @@ -104,25 +104,16 @@ def client_builder(self) -> DatabaseClientBuilder: return self._client_builder -@Injectable("postgresql_pool") -class PostgreSqlPool(DatabaseClientPool): - """PostgreSql Pool class.""" - - def __init__(self, *args, **kwargs): - warnings.warn(f"{PostgreSqlPool!r} has been deprecated. Use {DatabaseClientPool} instead.", DeprecationWarning) - super().__init__(*args, **kwargs) - - -class DatabaseLockPool(DatabaseClientPool, LockPool): +class DatabaseLockPool(LockPool, DatabaseClientPool): """Database Lock Pool class.""" def acquire(self, key: Hashable, *args, **kwargs) -> DatabaseLock: """Acquire a new lock. :param key: The key to be used for locking. - :return: A ``PostgreSqlLock`` instance. + :return: A ``DatabaseLock`` instance. """ - acquired = super().acquire() + acquired = super(DatabaseClientPool, self).acquire() async def _fn_enter(): client = await acquired.__aenter__() @@ -134,13 +125,3 @@ async def _fn_exit(lock: DatabaseLock): # noinspection PyTypeChecker return ContextManager(_fn_enter, _fn_exit) - - -class PostgreSqlLockPool(DatabaseLockPool): - """PostgreSql Lock Pool class""" - - def __init__(self, *args, **kwargs): - warnings.warn( - f"{PostgreSqlLockPool!r} has been deprecated. Use {PostgreSqlLockPool} instead.", DeprecationWarning - ) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/locks.py b/packages/core/minos-microservice-common/minos/common/locks.py index 1366370e2..f26f0019a 100644 --- a/packages/core/minos-microservice-common/minos/common/locks.py +++ b/packages/core/minos-microservice-common/minos/common/locks.py @@ -67,4 +67,4 @@ def hashed_key(self) -> int: @Injectable("lock_pool") class LockPool(Pool[Lock], ABC): - """Postgres Locking Pool class.""" + """Lock Pool class.""" diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index bb97ae9b4..a83e58e46 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -1,5 +1,4 @@ import unittest -import warnings from minos.common import ( AiopgDatabaseClient, @@ -8,8 +7,6 @@ DatabaseMixin, NotProvidedException, PoolFactory, - PostgreSqlMinosDatabase, - PostgreSqlPool, ) from minos.common.testing import ( DatabaseMinosTestCase, @@ -38,15 +35,6 @@ async def test_constructor_raises(self): # noinspection PyArgumentEqualDefault DatabaseMixin(database_pool=None, pool_factory=None) - async def test_constructor_with_postgresql_pool(self): - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - pool = PostgreSqlPool.from_config(self.config) - # noinspection PyTypeChecker,PyArgumentEqualDefault - database = DatabaseMixin(database_pool=None, pool_factory=None, postgresql_pool=pool) - - self.assertEqual(pool, database.pool) - async def test_pool(self): async with DatabaseMixin() as database: self.assertIsInstance(database.pool, DatabaseClientPool) @@ -125,18 +113,5 @@ async def test_submit_query_and_iter_locked(self): self.assertEqual([(3,), (4,), (5,)], observed) -class TestPostgreSqlMinosDatabase(CommonTestCase, DatabaseMinosTestCase): - def test_is_subclass(self): - self.assertTrue(issubclass(PostgreSqlMinosDatabase, DatabaseMixin)) - - def test_warnings(self): - pool = DatabaseClientPool.from_config(self.config) - - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - database = PostgreSqlMinosDatabase(pool) - self.assertIsInstance(database, DatabaseMixin) - - if __name__ == "__main__": unittest.main() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py index 37e2b425f..1352a6ca3 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py @@ -1,11 +1,9 @@ import unittest -import warnings from minos.common import ( AiopgDatabaseClient, DatabaseLock, Lock, - PostgreSqlLock, ) from minos.common.testing import ( DatabaseMinosTestCase, @@ -40,18 +38,5 @@ async def test_hashed_key(self): self.assertEqual(hash("foo"), lock.hashed_key) -class TestPostgreSqlLock(CommonTestCase, DatabaseMinosTestCase): - def test_is_subclass(self): - self.assertTrue(issubclass(PostgreSqlLock, DatabaseLock)) - - async def test_warnings(self): - client = AiopgDatabaseClient(**self.config.get_default_database()) - - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - lock = PostgreSqlLock(client, "foo") - self.assertIsInstance(lock, DatabaseLock) - - if __name__ == "__main__": unittest.main() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index 07568c79a..e13729bd1 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -1,5 +1,4 @@ import unittest -import warnings from unittest.mock import ( patch, ) @@ -11,8 +10,6 @@ DatabaseClientPool, DatabaseLock, DatabaseLockPool, - PostgreSqlLockPool, - PostgreSqlPool, UnableToConnectException, ) from minos.common.testing import ( @@ -74,17 +71,6 @@ async def test_acquire_with_connection_error(self): self.assertIsInstance(client, AiopgDatabaseClient) -class TestPostgreSqlPool(CommonTestCase, DatabaseMinosTestCase): - def test_is_subclass(self): - self.assertTrue(issubclass(PostgreSqlPool, DatabaseClientPool)) - - def test_warnings(self): - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - pool = PostgreSqlPool.from_config(self.config) - self.assertIsInstance(pool, DatabaseClientPool) - - class TestDatabaseLockPool(CommonTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() @@ -104,16 +90,5 @@ async def test_acquire(self): self.assertEqual("foo", lock.key) -class TestPostgreSqlLockPool(CommonTestCase, DatabaseMinosTestCase): - def test_is_subclass(self): - self.assertTrue(issubclass(PostgreSqlLockPool, DatabaseLockPool)) - - def test_warnings(self): - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - pool = PostgreSqlLockPool.from_config(self.config) - self.assertIsInstance(pool, DatabaseLockPool) - - if __name__ == "__main__": unittest.main() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_testing.py b/packages/core/minos-microservice-common/tests/test_common/test_testing.py index a80a4fe6d..a56ca5514 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_testing.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_testing.py @@ -5,8 +5,8 @@ DependencyInjector, ) from minos.common.testing import ( - MinosTestCase, DatabaseMinosTestCase, + MinosTestCase, ) from tests.utils import ( CONFIG_FILE_PATH, @@ -29,7 +29,7 @@ class MyMinosTestCase(MinosTestCase): CONFIG_FILE_PATH = CONFIG_FILE_PATH -class TestPostgresAsyncTestCase(unittest.IsolatedAsyncioTestCase): +class TestMyDatabaseMinosTestCase(unittest.IsolatedAsyncioTestCase): pass diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py index 8fe797c24..2a6847aa4 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py @@ -14,7 +14,7 @@ # noinspection SqlResolve,SqlNoDataSourceInspection,SqlNoDataSourceInspection,SqlResolve class BrokerQueueDatabaseOperationFactory(DatabaseOperationFactory, ABC): - """PostgreSql Broker Queue Query Factory class.""" + """Broker Queue Database Operation Factory class.""" @abstractmethod def build_create_table(self) -> DatabaseOperation: diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py index 11b78c25d..126d370c1 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py @@ -22,7 +22,7 @@ # noinspection SqlResolve,SqlNoDataSourceInspection,SqlNoDataSourceInspection,SqlResolve class AiopgBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): - """PostgreSql Broker Queue Query Factory class.""" + """Aiopg Broker Queue Database Operation Factory class.""" @abstractmethod def build_table_name(self) -> str: diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index dc65cf2a5..d6a2654dc 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -46,7 +46,7 @@ class DatabaseBrokerQueue(BrokerQueue, DatabaseMixin): - """PostgreSql Broker Queue class.""" + """Database Broker Queue class.""" _queue: PriorityQueue[_Entry] @@ -98,7 +98,7 @@ def records(self) -> int: def operation_factory(self) -> BrokerQueueDatabaseOperationFactory: """Get the query factory. - :return: A ``PostgreSqlBrokerQueueQueryFactory`` instance. + :return: A ``BrokerQueueDatabaseOperationFactory`` instance. """ return self._operation_factory @@ -245,7 +245,7 @@ def __lt__(self, other: Any) -> bool: class DatabaseBrokerQueueBuilder(Builder): - """PostgreSql Broker Queue Builder class.""" + """Database Broker Queue Builder class.""" def with_config(self, config: Config): """Set config. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py index 51d7780c0..fae7a1941 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py @@ -24,20 +24,20 @@ class DatabaseBrokerPublisherQueue(DatabaseBrokerQueue, BrokerPublisherQueue): - """PostgreSql Broker Publisher Queue class.""" + """Database Broker Publisher Queue class.""" def __init__(self, *args, **kwargs): super().__init__(*args, operation_factory_cls=BrokerPublisherQueueDatabaseOperationFactory, **kwargs) class BrokerPublisherQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): - """TODO""" + """Broker Publisher Queue Database Operation Factory class.""" class AiopgBrokerPublisherQueueDatabaseOperationFactory( BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory ): - """PostgreSql Broker Publisher Queue Query Factory class.""" + """Aiopg Broker Publisher Queue Query Factory class.""" def build_table_name(self) -> str: """Get the table name. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py index 64df7b61f..48dbeeadb 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py @@ -22,7 +22,7 @@ class AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory( BrokerSubscriberDuplicateValidatorDatabaseOperationFactory ): - """PostgreSql Broker Subscriber Duplicate Detector Query Factory class.""" + """Aiopg Broker Subscriber Duplicate Detector Database Operation class.""" @staticmethod def build_table_name() -> str: diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py index 5d83ab2b0..5d231062a 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py @@ -25,7 +25,7 @@ class DatabaseBrokerSubscriberDuplicateValidator(BrokerSubscriberDuplicateValidator, DatabaseMixin): - """PostgreSql Broker Subscriber Duplicate Detector class.""" + """Database Broker Subscriber Duplicate Detector class.""" def __init__( self, @@ -66,7 +66,7 @@ async def _is_unique(self, topic: str, uuid: UUID) -> bool: class DatabaseBrokerSubscriberDuplicateValidatorBuilder(Builder[DatabaseBrokerSubscriberDuplicateValidator]): - """PostgreSql Broker Subscriber Duplicate Detector Builder class.""" + """Database Broker Subscriber Duplicate Detector Builder class.""" def with_config(self, config: Config): """Set config. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py index 083cdd19d..c6b9db202 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py @@ -16,7 +16,7 @@ # noinspection SqlNoDataSourceInspection,SqlResolve,PyTypeChecker,PyArgumentList class BrokerSubscriberQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): - """PostgreSql Broker Subscriber Queue Query Factory class.""" + """Broker Subscriber Queue Database Operation Factory class.""" def build_count_not_processed( self, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py index 452b73b1c..f4811179f 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py @@ -24,7 +24,7 @@ class AiopgBrokerSubscriberQueueDatabaseOperationFactory( BrokerSubscriberQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory ): - """PostgreSql Broker Subscriber Queue Query Factory class.""" + """Aiopg Broker Subscriber Queue Database Operation Factory class.""" def build_table_name(self) -> str: """Get the table name. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py index 419424ed4..e61bec0c0 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py @@ -27,7 +27,7 @@ class DatabaseBrokerSubscriberQueue(DatabaseBrokerQueue, BrokerSubscriberQueue): - """PostgreSql Broker Subscriber Queue class.""" + """Database Broker Subscriber Queue class.""" def __init__(self, topics: set[str], *args, **kwargs): super().__init__(topics, *args, operation_factory_cls=BrokerSubscriberQueueDatabaseOperationFactory, **kwargs) @@ -48,7 +48,7 @@ async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: class DatabaseBrokerSubscriberQueueBuilder( BrokerSubscriberQueueBuilder[DatabaseBrokerSubscriberQueue], DatabaseBrokerQueueBuilder ): - """PostgreSql Broker Subscriber Queue Builder class.""" + """Database Broker Subscriber Queue Builder class.""" DatabaseBrokerSubscriberQueue.set_builder(DatabaseBrokerSubscriberQueueBuilder) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index 9815e3e49..4bfdfe859 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -35,7 +35,7 @@ def build_table_name(self) -> str: return "test_table" -class TestPostgreSqlBrokerQueue(NetworksTestCase, DatabaseMinosTestCase): +class TestDatabaseBrokerQueue(NetworksTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.operation_factory = _AiopgBrokerQueueDatabaseOperationFactory() diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py index d9af6ffc4..9e28b2bfb 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py @@ -14,7 +14,7 @@ ) -class TestPostgreSqlBrokerPublisherQueue(NetworksTestCase, DatabaseMinosTestCase): +class TestDatabaseBrokerPublisherQueue(NetworksTestCase, DatabaseMinosTestCase): def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerPublisherQueue, (DatabaseBrokerQueue, BrokerPublisherQueue))) @@ -24,7 +24,7 @@ async def test_operation_factory(self): self.assertIsInstance(queue.operation_factory, AiopgBrokerPublisherQueueDatabaseOperationFactory) -class TestPostgreSqlBrokerPublisherQueueQueryFactory(unittest.TestCase): +class TestAiopgBrokerPublisherQueueDatabaseOperationFactory(unittest.TestCase): def setUp(self) -> None: self.factory = AiopgBrokerPublisherQueueDatabaseOperationFactory() diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py index c3336b876..7dcaaf460 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py @@ -15,7 +15,7 @@ ) -class TestPostgreSqlBrokerSubscriberDuplicateValidator(NetworksTestCase, DatabaseMinosTestCase): +class TestDatabaseBrokerSubscriberDuplicateValidator(NetworksTestCase, DatabaseMinosTestCase): def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerSubscriberDuplicateValidator, BrokerSubscriberValidator)) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py index bdb5d6a11..bc289ee9e 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py @@ -28,7 +28,7 @@ ) -class TestPostgreSqlBrokerSubscriberQueue(NetworksTestCase, DatabaseMinosTestCase): +class TestDatabaseBrokerSubscriberQueue(NetworksTestCase, DatabaseMinosTestCase): def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerSubscriberQueue, (DatabaseBrokerQueue, BrokerSubscriberQueue))) @@ -77,7 +77,7 @@ async def test_dequeue_with_notify(self): self.assertEqual(messages, observed) -class TestPostgreSqlBrokerSubscriberQueueQueryFactory(unittest.TestCase): +class TestAiopgBrokerSubscriberQueueDatabaseOperationFactory(unittest.TestCase): def setUp(self) -> None: self.factory = AiopgBrokerSubscriberQueueDatabaseOperationFactory() @@ -85,7 +85,7 @@ def test_build_table_name(self): self.assertEqual("broker_subscriber_queue", self.factory.build_table_name()) -class TestPostgreSqlBrokerSubscriberQueueBuilder(NetworksTestCase, DatabaseMinosTestCase): +class TestDatabaseBrokerSubscriberQueueBuilder(NetworksTestCase, DatabaseMinosTestCase): def test_build(self): builder = DatabaseBrokerSubscriberQueueBuilder().with_config(self.config).with_topics({"one", "two"}) subscriber = builder.build() diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py index 6aeee4acd..941fbb64b 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py @@ -9,14 +9,10 @@ KafkaCircuitBreakerMixin, ) from .publisher import ( - InMemoryQueuedKafkaBrokerPublisher, KafkaBrokerPublisher, KafkaBrokerPublisherBuilder, - PostgreSqlQueuedKafkaBrokerPublisher, ) from .subscriber import ( - InMemoryQueuedKafkaBrokerSubscriberBuilder, KafkaBrokerSubscriber, KafkaBrokerSubscriberBuilder, - PostgreSqlQueuedKafkaBrokerSubscriberBuilder, ) diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/publisher.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/publisher.py index 5486499ae..efd181601 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/publisher.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/publisher.py @@ -3,7 +3,6 @@ ) import logging -import warnings from asyncio import ( TimeoutError, wait_for, @@ -22,16 +21,10 @@ AIOKafkaProducer, ) -from minos.common import ( - Config, -) from minos.networks import ( BrokerMessage, BrokerPublisher, BrokerPublisherBuilder, - DatabaseBrokerPublisherQueue, - InMemoryBrokerPublisherQueue, - QueuedBrokerPublisher, ) from .common import ( @@ -42,34 +35,6 @@ logger = logging.getLogger(__name__) -class PostgreSqlQueuedKafkaBrokerPublisher(QueuedBrokerPublisher): - """PostgreSql Queued Kafka Broker Publisher class.""" - - def __init__(self, *args, **kwargs): - warnings.warn(f"{PostgreSqlQueuedKafkaBrokerPublisher!r} has been deprecated.", DeprecationWarning) - super().__init__(*args, **kwargs) - - @classmethod - def _from_config(cls, config: Config, **kwargs) -> PostgreSqlQueuedKafkaBrokerPublisher: - impl = KafkaBrokerPublisher.from_config(config, **kwargs) - queue = DatabaseBrokerPublisherQueue.from_config(config, **kwargs) - return cls(impl, queue, **kwargs) - - -class InMemoryQueuedKafkaBrokerPublisher(QueuedBrokerPublisher): - """In Memory Queued Kafka Broker Publisher class.""" - - def __init__(self, *args, **kwargs): - warnings.warn(f"{InMemoryQueuedKafkaBrokerPublisher!r} has been deprecated.", DeprecationWarning) - super().__init__(*args, **kwargs) - - @classmethod - def _from_config(cls, config: Config, **kwargs) -> InMemoryQueuedKafkaBrokerPublisher: - impl = KafkaBrokerPublisher.from_config(config, **kwargs) - queue = InMemoryBrokerPublisherQueue.from_config(config, **kwargs) - return cls(impl, queue, **kwargs) - - class KafkaBrokerPublisher(BrokerPublisher, KafkaCircuitBreakerMixin): """Kafka Broker Publisher class.""" diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py index 9c998666f..92c59bdbe 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py @@ -41,9 +41,6 @@ BrokerMessage, BrokerSubscriber, BrokerSubscriberBuilder, - DatabaseBrokerSubscriberQueueBuilder, - InMemoryBrokerSubscriberQueueBuilder, - QueuedBrokerSubscriberBuilder, ) from .common import ( @@ -196,27 +193,3 @@ class KafkaBrokerSubscriberBuilder(BrokerSubscriberBuilder[KafkaBrokerSubscriber KafkaBrokerSubscriber.set_builder(KafkaBrokerSubscriberBuilder) - - -class PostgreSqlQueuedKafkaBrokerSubscriberBuilder(QueuedBrokerSubscriberBuilder): - """PostgreSql Queued Kafka Broker Subscriber Builder class.""" - - def __init__(self, *args, **kwargs): - super().__init__( - *args, - impl_builder=KafkaBrokerSubscriberBuilder.new(), - queue_builder=DatabaseBrokerSubscriberQueueBuilder.new(), - **kwargs, - ) - - -class InMemoryQueuedKafkaBrokerSubscriberBuilder(QueuedBrokerSubscriberBuilder): - """In Memory Queued Kafka Broker Subscriber Builder class.""" - - def __init__(self, *args, **kwargs): - super().__init__( - *args, - impl_builder=KafkaBrokerSubscriberBuilder.new(), - queue_builder=InMemoryBrokerSubscriberQueueBuilder.new(), - **kwargs, - ) diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py index 9761c6e4c..f2fe188d8 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_publisher.py @@ -1,5 +1,4 @@ import unittest -import warnings from unittest.mock import ( AsyncMock, ) @@ -14,22 +13,15 @@ from minos.common import ( Config, ) -from minos.common.testing import ( - DatabaseMinosTestCase, -) from minos.networks import ( BrokerMessage, BrokerMessageV1, BrokerMessageV1Payload, BrokerPublisher, - DatabaseBrokerPublisherQueue, - InMemoryBrokerPublisherQueue, ) from minos.plugins.kafka import ( - InMemoryQueuedKafkaBrokerPublisher, KafkaBrokerPublisher, KafkaBrokerPublisherBuilder, - PostgreSqlQueuedKafkaBrokerPublisher, ) from tests.utils import ( CONFIG_FILE_PATH, @@ -154,27 +146,5 @@ def test_build(self): self.assertEqual(common_config["port"], publisher.port) -class TestPostgreSqlQueuedKafkaBrokerPublisher(DatabaseMinosTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - - def test_from_config(self): - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - publisher = PostgreSqlQueuedKafkaBrokerPublisher.from_config(CONFIG_FILE_PATH) - self.assertIsInstance(publisher, PostgreSqlQueuedKafkaBrokerPublisher) - self.assertIsInstance(publisher.impl, KafkaBrokerPublisher) - self.assertIsInstance(publisher.queue, DatabaseBrokerPublisherQueue) - - -class TestInMemoryQueuedKafkaBrokerPublisher(unittest.IsolatedAsyncioTestCase): - def test_from_config(self): - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - publisher = InMemoryQueuedKafkaBrokerPublisher.from_config(CONFIG_FILE_PATH) - self.assertIsInstance(publisher, InMemoryQueuedKafkaBrokerPublisher) - self.assertIsInstance(publisher.impl, KafkaBrokerPublisher) - self.assertIsInstance(publisher.queue, InMemoryBrokerPublisherQueue) - - if __name__ == "__main__": unittest.main() diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py index 80f1d354a..4614d9b4f 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py @@ -1,5 +1,4 @@ import unittest -import warnings from collections import ( namedtuple, ) @@ -22,22 +21,14 @@ from minos.common import ( Config, ) -from minos.common.testing import ( - DatabaseMinosTestCase, -) from minos.networks import ( BrokerMessageV1, BrokerMessageV1Payload, BrokerSubscriber, - DatabaseBrokerSubscriberQueue, - InMemoryBrokerSubscriberQueue, - QueuedBrokerSubscriber, ) from minos.plugins.kafka import ( - InMemoryQueuedKafkaBrokerSubscriberBuilder, KafkaBrokerSubscriber, KafkaBrokerSubscriberBuilder, - PostgreSqlQueuedKafkaBrokerSubscriberBuilder, ) from tests.utils import ( CONFIG_FILE_PATH, @@ -253,38 +244,5 @@ def test_build(self): self.assertEqual(common_config["port"], subscriber.port) -class TestPostgreSqlQueuedKafkaBrokerSubscriberBuilder(DatabaseMinosTestCase): - CONFIG_FILE_PATH = CONFIG_FILE_PATH - - def test_build(self): - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - builder = ( - PostgreSqlQueuedKafkaBrokerSubscriberBuilder().with_config(self.config).with_topics({"one", "two"}) - ) - - subscriber = builder.build() - - self.assertIsInstance(subscriber, QueuedBrokerSubscriber) - self.assertIsInstance(subscriber.impl, KafkaBrokerSubscriber) - self.assertIsInstance(subscriber.queue, DatabaseBrokerSubscriberQueue) - - -class TestInMemoryQueuedKafkaBrokerSubscriberBuilder(unittest.TestCase): - def setUp(self) -> None: - self.config = Config(CONFIG_FILE_PATH) - - def test_build(self): - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - builder = InMemoryQueuedKafkaBrokerSubscriberBuilder().with_config(self.config).with_topics({"one", "two"}) - - subscriber = builder.build() - - self.assertIsInstance(subscriber, QueuedBrokerSubscriber) - self.assertIsInstance(subscriber.impl, KafkaBrokerSubscriber) - self.assertIsInstance(subscriber.queue, InMemoryBrokerSubscriberQueue) - - if __name__ == "__main__": unittest.main() From 6ae17371daf463857ab108c8d832368f1398bc48 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 7 Apr 2022 16:11:42 +0200 Subject: [PATCH 167/324] ISSUE #373 --- .../minos/networks/discovery/clients/abc.py | 14 +++++++++++++- .../minos/networks/discovery/connectors.py | 5 +---- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py b/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py index a6862ba52..c5e953b1c 100644 --- a/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py @@ -1,3 +1,5 @@ +from __future__ import annotations + import logging from abc import ( ABC, @@ -6,12 +8,14 @@ from minos.common import ( Object, + Config, + SetupMixin, ) logger = logging.getLogger(__name__) -class DiscoveryClient(ABC, Object): +class DiscoveryClient(ABC, SetupMixin): """Discovery Client class.""" def __init__(self, host: str, port: int, **kwargs): @@ -28,6 +32,14 @@ def route(self) -> str: # noinspection HttpUrlsUsage return f"http://{self.host}:{self.port}" + @classmethod + def _from_config(cls, config: Config, **kwargs) -> DiscoveryClient: + discovery_config = config.get_discovery() + + client_host = discovery_config.get("host") + client_port = discovery_config.get("port") + return cls(host=client_host, port=client_port, **kwargs) + @abstractmethod async def subscribe( self, host: str, port: int, name: str, endpoints: list[dict[str, str]], *args, **kwargs diff --git a/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py b/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py index bb4acef18..7fb956fb0 100644 --- a/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py +++ b/packages/core/minos-microservice-networks/minos/networks/discovery/connectors.py @@ -79,10 +79,7 @@ def _client_from_config(cls, config: Config) -> DiscoveryClient: discovery_config = config.get_discovery() client_cls = cls._client_cls_from_config(discovery_config) - client_host = discovery_config.get("host") - client_port = discovery_config.get("port") - - return client_cls(host=client_host, port=client_port) + return client_cls.from_config(config) @staticmethod def _client_cls_from_config(discovery_config: dict[str, Any]) -> type[DiscoveryClient]: From 83bdc06240922d856501f8789b9c306c5205dfc8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 16:20:56 +0200 Subject: [PATCH 168/324] ISSUE #371 * Allow to setup `DatabaseOperationFactory` at `DatabaseMixin` from directly generics. --- .../events/repositories/database/impl.py | 14 +----- .../minos/aggregate/snapshots/database/abc.py | 15 +------ .../repositories/database/impl.py | 14 +----- .../minos/common/database/mixins.py | 43 ++++++++++++++++++- .../minos/common/injections/decorators.py | 5 ++- .../collections/queues/database/impl.py | 42 ++++++++---------- .../publishers/queued/queues/database.py | 13 +++--- .../validators/duplicates/database/impl.py | 33 +++----------- .../queued/queues/database/impl.py | 11 +++-- 9 files changed, 84 insertions(+), 106 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index 75bd099bb..3f45751f1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -29,21 +29,9 @@ ) -class DatabaseEventRepository(DatabaseMixin, EventRepository): +class DatabaseEventRepository(DatabaseMixin[EventDatabaseOperationFactory], EventRepository): """Database-based implementation of the event repository class.""" - def __init__( - self, - *args, - operation_factory: Optional[EventDatabaseOperationFactory] = None, - **kwargs, - ): - super().__init__(*args, **kwargs) - if operation_factory is None: - operation_factory = self.pool_instance_cls.get_factory(EventDatabaseOperationFactory) - - self.operation_factory = operation_factory - @classmethod def _from_config(cls, config: Config, **kwargs) -> Optional[EventRepository]: return super()._from_config(config, database_key=None, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py index 2d1e05cdc..588ea7f6c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py @@ -3,7 +3,6 @@ ) from typing import ( - Optional, Type, TypeVar, ) @@ -18,21 +17,9 @@ ) -class DatabaseSnapshotSetup(DatabaseMixin): +class DatabaseSnapshotSetup(DatabaseMixin[SnapshotDatabaseOperationFactory]): """Minos Snapshot Setup Class""" - def __init__( - self, - *args, - operation_factory: Optional[SnapshotDatabaseOperationFactory] = None, - **kwargs, - ): - super().__init__(*args, **kwargs) - if operation_factory is None: - operation_factory = self.pool_instance_cls.get_factory(SnapshotDatabaseOperationFactory) - - self.operation_factory = operation_factory - @classmethod def _from_config(cls: Type[T], config: Config, **kwargs) -> T: return cls(database_key=None, **kwargs) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index 06ea3070a..202bfd326 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -26,21 +26,9 @@ ) -class DatabaseTransactionRepository(DatabaseMixin, TransactionRepository): +class DatabaseTransactionRepository(DatabaseMixin[TransactionDatabaseOperationFactory], TransactionRepository): """Database Transaction Repository class.""" - def __init__( - self, - *args, - operation_factory: Optional[TransactionDatabaseOperationFactory] = None, - **kwargs, - ): - super().__init__(*args, **kwargs) - if operation_factory is None: - operation_factory = self.pool_instance_cls.get_factory(TransactionDatabaseOperationFactory) - - self.operation_factory = operation_factory - @classmethod def _from_config(cls, config: Config, **kwargs) -> DatabaseTransactionRepository: return super()._from_config(config, database_key=None, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/database/mixins.py b/packages/core/minos-microservice-common/minos/common/database/mixins.py index 2b0eae794..59eceeaac 100644 --- a/packages/core/minos-microservice-common/minos/common/database/mixins.py +++ b/packages/core/minos-microservice-common/minos/common/database/mixins.py @@ -1,6 +1,9 @@ from typing import ( AsyncIterator, + Generic, Optional, + TypeVar, + get_args, get_origin, ) from ..exceptions import ( @@ -17,14 +20,17 @@ ) from .operations import ( DatabaseOperation, + DatabaseOperationFactory, ) from .pools import ( DatabaseClient, DatabaseClientPool, ) +GenericDatabaseOperationFactory = TypeVar("GenericDatabaseOperationFactory", bound=DatabaseOperationFactory) -class DatabaseMixin(SetupMixin): + +class DatabaseMixin(SetupMixin, Generic[GenericDatabaseOperationFactory]): """Database Mixin class.""" @Inject() @@ -33,6 +39,8 @@ def __init__( database_pool: Optional[DatabaseClientPool] = None, pool_factory: Optional[PoolFactory] = None, database_key: Optional[str] = None, + operation_factory: Optional[GenericDatabaseOperationFactory] = None, + operation_factory_cls: Optional[type[GenericDatabaseOperationFactory]] = None, *args, **kwargs, ): @@ -45,6 +53,39 @@ def __init__( self._pool = database_pool + if operation_factory is None: + if operation_factory_cls is None: + operation_factory_cls = self._get_generic_operation_factory() + if operation_factory_cls is not None: + operation_factory = self.pool_instance_cls.get_factory(operation_factory_cls) + + self._operation_factory = operation_factory + + @property + def operation_factory(self) -> Optional[GenericDatabaseOperationFactory]: + """TODO + + :return: TODO + """ + return self._operation_factory + + def _get_generic_operation_factory(self) -> Optional[type[GenericDatabaseOperationFactory]]: + operation_factory_cls = None + # noinspection PyUnresolvedReferences + for base in self.__orig_bases__: + origin = get_origin(base) + if origin is None or not issubclass(origin, DatabaseMixin): + continue + args = get_args(base) + if not len(args): + continue + operation_factory_cls = args[0] + if not isinstance(operation_factory_cls, type) or not issubclass( + operation_factory_cls, DatabaseOperationFactory + ): + raise TypeError(f"{type(self)!r} must contain a {DatabaseOperationFactory!r} as generic value.") + return operation_factory_cls + async def submit_query_and_fetchone(self, operation: DatabaseOperation) -> tuple: """Submit a SQL query and gets the first response. diff --git a/packages/core/minos-microservice-common/minos/common/injections/decorators.py b/packages/core/minos-microservice-common/minos/common/injections/decorators.py index ea299ab77..b052e968f 100644 --- a/packages/core/minos-microservice-common/minos/common/injections/decorators.py +++ b/packages/core/minos-microservice-common/minos/common/injections/decorators.py @@ -151,8 +151,9 @@ def _is_injectable(self, type_: type) -> bool: if any(self._is_injectable(arg) for arg in get_args(type_)): return True elif origin_type is None: - if issubclass(type_, InjectableMixin): - return True + if is_type_subclass(type_): + if issubclass(type_, InjectableMixin): + return True elif is_type_subclass(origin_type): if issubclass(origin_type, InjectableMixin): return True diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index d6a2654dc..1bf8d2729 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -17,8 +17,10 @@ ) from typing import ( Any, + Generic, NoReturn, Optional, + TypeVar, ) from cached_property import ( @@ -44,8 +46,16 @@ logger = logging.getLogger(__name__) +GenericBrokerQueueDatabaseOperationFactory = TypeVar( + "GenericBrokerQueueDatabaseOperationFactory", bound=BrokerQueueDatabaseOperationFactory +) + -class DatabaseBrokerQueue(BrokerQueue, DatabaseMixin): +class DatabaseBrokerQueue( + BrokerQueue, + DatabaseMixin[GenericBrokerQueueDatabaseOperationFactory], + Generic[GenericBrokerQueueDatabaseOperationFactory], +): """Database Broker Queue class.""" _queue: PriorityQueue[_Entry] @@ -53,8 +63,6 @@ class DatabaseBrokerQueue(BrokerQueue, DatabaseMixin): def __init__( self, *args, - operation_factory: Optional[BrokerQueueDatabaseOperationFactory] = None, - operation_factory_cls: Optional[type[BrokerQueueDatabaseOperationFactory]] = None, retry: Optional[int] = None, records: Optional[int] = None, **kwargs, @@ -66,10 +74,6 @@ def __init__( if records is None: records = 1000 - if operation_factory is None: - operation_factory = self.pool_instance_cls.get_factory(operation_factory_cls) - - self._operation_factory = operation_factory self._retry = retry self._records = records @@ -94,14 +98,6 @@ def records(self) -> int: """ return self._records - @property - def operation_factory(self) -> BrokerQueueDatabaseOperationFactory: - """Get the query factory. - - :return: A ``BrokerQueueDatabaseOperationFactory`` instance. - """ - return self._operation_factory - @classmethod def _from_config(cls, config: Config, **kwargs) -> DatabaseBrokerQueue: broker_interface = config.get_interface_by_name("broker") @@ -121,7 +117,7 @@ async def _destroy(self) -> None: await super()._destroy() async def _create_table(self) -> None: - operation = self._operation_factory.build_create_table() + operation = self.operation_factory.build_create_table() await self.submit_query(operation) async def _start_run(self) -> None: @@ -143,12 +139,12 @@ async def _flush_queue(self): entry = self._queue.get_nowait() except QueueEmpty: break - operation = self._operation_factory.build_update_not_processed(entry.id_) + operation = self.operation_factory.build_update_not_processed(entry.id_) await self.submit_query(operation) self._queue.task_done() async def _enqueue(self, message: BrokerMessage) -> None: - operation = self._operation_factory.build_insert(message.topic, message.avro_bytes) + operation = self.operation_factory.build_insert(message.topic, message.avro_bytes) await self.submit_query(operation) await self._notify_enqueued(message) @@ -167,11 +163,11 @@ async def _dequeue(self) -> BrokerMessage: logger.warning( f"There was a problem while trying to deserialize the entry with {entry.id_!r} id: {exc}" ) - operation = self._operation_factory.build_update_not_processed(entry.id_) + operation = self.operation_factory.build_update_not_processed(entry.id_) await self.submit_query(operation) continue - operation = self._operation_factory.build_delete_processed(entry.id_) + operation = self.operation_factory.build_delete_processed(entry.id_) await self.submit_query(operation) return message finally: @@ -196,7 +192,7 @@ async def _wait_enqueued(self) -> None: async def _get_count(self) -> int: # noinspection PyTypeChecker - operation = self._operation_factory.build_count_not_processed(self.retry) + operation = self.operation_factory.build_count_not_processed(self.retry) row = await self.submit_query_and_fetchone(operation) count = row[0] return count @@ -211,14 +207,14 @@ async def _dequeue_batch(self) -> None: entries = [_Entry(*row) for row in rows] ids = tuple(entry.id_ for entry in entries) - operation = self._operation_factory.build_mark_processing(ids) + operation = self.operation_factory.build_mark_processing(ids) await client.execute(operation) for entry in entries: await self._queue.put(entry) async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - operation = self._operation_factory.build_select_not_processed(self._retry, self._records) + operation = self.operation_factory.build_select_not_processed(self._retry, self._records) await client.execute(operation) return [row async for row in client.fetch_all()] diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py index fae7a1941..339360e27 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py @@ -23,13 +23,6 @@ logger = logging.getLogger(__name__) -class DatabaseBrokerPublisherQueue(DatabaseBrokerQueue, BrokerPublisherQueue): - """Database Broker Publisher Queue class.""" - - def __init__(self, *args, **kwargs): - super().__init__(*args, operation_factory_cls=BrokerPublisherQueueDatabaseOperationFactory, **kwargs) - - class BrokerPublisherQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): """Broker Publisher Queue Database Operation Factory class.""" @@ -50,3 +43,9 @@ def build_table_name(self) -> str: AiopgDatabaseClient.register_factory( BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerPublisherQueueDatabaseOperationFactory ) + + +class DatabaseBrokerPublisherQueue( + DatabaseBrokerQueue[BrokerPublisherQueueDatabaseOperationFactory], BrokerPublisherQueue +): + """Database Broker Publisher Queue class.""" diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py index 5d231062a..d767f639f 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py @@ -2,9 +2,6 @@ annotations, ) -from typing import ( - Optional, -) from uuid import ( UUID, ) @@ -24,40 +21,22 @@ ) -class DatabaseBrokerSubscriberDuplicateValidator(BrokerSubscriberDuplicateValidator, DatabaseMixin): +class DatabaseBrokerSubscriberDuplicateValidator( + BrokerSubscriberDuplicateValidator, + DatabaseMixin[BrokerSubscriberDuplicateValidatorDatabaseOperationFactory], +): """Database Broker Subscriber Duplicate Detector class.""" - def __init__( - self, - operation_factory: Optional[BrokerSubscriberDuplicateValidatorDatabaseOperationFactory] = None, - *args, - **kwargs, - ): - super().__init__(*args, **kwargs) - if operation_factory is None: - operation_factory = self.pool_instance_cls.get_factory( - BrokerSubscriberDuplicateValidatorDatabaseOperationFactory - ) - self._operation_factory = operation_factory - async def _setup(self) -> None: await super()._setup() await self._create_table() async def _create_table(self) -> None: - operation = self._operation_factory.build_create_table() + operation = self.operation_factory.build_create_table() await self.submit_query(operation) - @property - def operation_factory(self) -> BrokerSubscriberDuplicateValidatorDatabaseOperationFactory: - """Get the query factory. - - :return: A ``BrokerSubscriberDuplicateValidatorDatabaseOperationFactory`` instance. - """ - return self._operation_factory - async def _is_unique(self, topic: str, uuid: UUID) -> bool: - operation = self._operation_factory.build_insert_row(topic, uuid) + operation = self.operation_factory.build_insert_row(topic, uuid) try: await self.submit_query(operation) return True diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py index e61bec0c0..c39ba4879 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py @@ -26,21 +26,20 @@ logger = logging.getLogger(__name__) -class DatabaseBrokerSubscriberQueue(DatabaseBrokerQueue, BrokerSubscriberQueue): +class DatabaseBrokerSubscriberQueue( + DatabaseBrokerQueue[BrokerSubscriberQueueDatabaseOperationFactory], BrokerSubscriberQueue +): """Database Broker Subscriber Queue class.""" - def __init__(self, topics: set[str], *args, **kwargs): - super().__init__(topics, *args, operation_factory_cls=BrokerSubscriberQueueDatabaseOperationFactory, **kwargs) - async def _get_count(self) -> int: # noinspection PyTypeChecker - operation = self._operation_factory.build_count_not_processed(self._retry, self.topics) + operation = self.operation_factory.build_count_not_processed(self._retry, self.topics) row = await self.submit_query_and_fetchone(operation) count = row[0] return count async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - operation = self._operation_factory.build_select_not_processed(self._retry, self._records, self.topics) + operation = self.operation_factory.build_select_not_processed(self._retry, self._records, self.topics) await client.execute(operation) return [row async for row in client.fetch_all()] From 53ad4c5e984e2549e1f4ee2d186e3fcf2f40d92a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 16:50:05 +0200 Subject: [PATCH 169/324] ISSUE #371 * Add missing docstring. --- .../repositories/database/factories/abc.py | 50 ++++++++++++++--- .../repositories/database/factories/aiopg.py | 48 +++++++++++++++-- .../snapshots/database/factories/abc.py | 53 ++++++++++++++++--- .../database/factories/aiopg/impl.py | 53 ++++++++++++++++--- .../repositories/database/factories/abc.py | 38 +++++++++++-- .../repositories/database/factories/aiopg.py | 40 ++++++++++++-- .../test_events/test_repositories/test_pg.py | 4 +- .../test_snapshots/test_pg/test_readers.py | 2 +- .../test_snapshots/test_pg/test_writers.py | 2 +- .../test_repositories/test_pg.py | 4 +- .../minos/common/database/clients/abc.py | 16 +++--- .../common/database/locks/factories/abc.py | 14 +++-- .../common/database/locks/factories/aiopg.py | 14 +++-- .../minos/common/database/manage/factories.py | 33 ++++++++---- .../minos/common/database/mixins.py | 35 ++++++------ .../minos/common/database/operations/abc.py | 6 +-- .../minos/common/database/operations/aiopg.py | 2 +- .../minos/common/database/pools.py | 6 +-- .../test_common/test_database/test_abc.py | 6 +-- .../collections/queues/database/impl.py | 2 +- .../duplicates/database/factories/abc.py | 2 +- .../test_collections/test_queues/test_pg.py | 2 +- 22 files changed, 339 insertions(+), 93 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py index d7af71d27..10866aa5c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py @@ -23,11 +23,14 @@ class EventDatabaseOperationFactory(DatabaseOperationFactory, ABC): - """TODO""" + """Event Database Operation Factory base class.""" @abstractmethod def build_create_table(self) -> DatabaseOperation: - """TODO""" + """Build the database operation to create the event table. + + :return: A ``DatabaseOperation`` instance.s + """ @abstractmethod def build_submit_row( @@ -40,10 +43,23 @@ def build_submit_row( data: bytes, created_at: datetime, transaction_uuid: UUID, - lock: Optional[str], + lock: Optional[int], **kwargs, ) -> DatabaseOperation: - """TODO""" + """Build the database operation to submit a row into the event table. + + :param transaction_uuids: The sequence of nested transaction in on top of the current event's transaction. + :param uuid: The identifier of the entity. + :param action: The action of the event. + :param name: The name of the entity. + :param version: The version of the entity + :param data: The data of the event. + :param created_at: The creation datetime. + :param transaction_uuid: The identifier of the transaction. + :param lock: The lock identifier. + :param kwargs: Additional named arguments. + :return: A ``DatabaseOperation`` instance. + """ # noinspection PyShadowingBuiltins @abstractmethod @@ -66,8 +82,30 @@ def build_select_rows( transaction_uuid_in: Optional[tuple[UUID, ...]] = None, **kwargs, ) -> DatabaseOperation: - """TODO""" + """Build the database operation to select rows. + + :param uuid: The identifier must be equal to the given value. + :param name: The classname must be equal to the given value. + :param version: The version must be equal to the given value. + :param version_lt: The version must be lower than the given value. + :param version_gt: The version must be greater than the given value. + :param version_le: The version must be lower or equal to the given value. + :param version_ge: The version must be greater or equal to the given value. + :param id: The entry identifier must be equal to the given value. + :param id_lt: The entry identifier must be lower than the given value. + :param id_gt: The entry identifier must be greater than the given value. + :param id_le: The entry identifier must be lower or equal to the given value. + :param id_ge: The entry identifier must be greater or equal to the given value. + :param transaction_uuid: The transaction identifier must be equal to the given value. + :param transaction_uuid_ne: The transaction identifier must be distinct of the given value. + :param transaction_uuid_in: The destination transaction identifier must be equal to one of the given values. + + :return: A ``DatabaseOperation`` instance. + """ @abstractmethod def build_select_max_id(self) -> DatabaseOperation: - """TODO""" + """Build the database operation to get the maximum identifier. + + :return: A ``DatabaseOperation`` instance. + """ diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py index 702c30f0c..aaa7b1c27 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py @@ -36,10 +36,13 @@ # noinspection SqlNoDataSourceInspection,SqlResolve,PyMethodMayBeStatic class AiopgEventDatabaseOperationFactory(EventDatabaseOperationFactory): - """TODO""" + """Aiopg Event Database Operation Factory class.""" def build_create_table(self) -> DatabaseOperation: - """TODO""" + """Build the database operation to create the event table. + + :return: A ``DatabaseOperation`` instance.s + """ return ComposedDatabaseOperation( [ AiopgDatabaseOperation( @@ -97,7 +100,20 @@ def build_submit_row( lock: Optional[str], **kwargs, ) -> DatabaseOperation: - """TODO""" + """Build the database operation to submit a row into the event table. + + :param transaction_uuids: The sequence of nested transaction in on top of the current event's transaction. + :param uuid: The identifier of the entity. + :param action: The action of the event. + :param name: The name of the entity. + :param version: The version of the entity + :param data: The data of the event. + :param created_at: The creation datetime. + :param transaction_uuid: The identifier of the transaction. + :param lock: The lock identifier. + :param kwargs: Additional named arguments. + :return: A ``DatabaseOperation`` instance. + """ insert_values = SQL( """ INSERT INTO aggregate_event (id, action, uuid, name, version, data, created_at, transaction_uuid) @@ -178,7 +194,26 @@ def build_select_rows( transaction_uuid_in: Optional[tuple[UUID, ...]] = None, **kwargs, ) -> DatabaseOperation: - """TODO""" + """Build the database operation to select rows. + + :param uuid: The identifier must be equal to the given value. + :param name: The classname must be equal to the given value. + :param version: The version must be equal to the given value. + :param version_lt: The version must be lower than the given value. + :param version_gt: The version must be greater than the given value. + :param version_le: The version must be lower or equal to the given value. + :param version_ge: The version must be greater or equal to the given value. + :param id: The entry identifier must be equal to the given value. + :param id_lt: The entry identifier must be lower than the given value. + :param id_gt: The entry identifier must be greater than the given value. + :param id_le: The entry identifier must be lower or equal to the given value. + :param id_ge: The entry identifier must be greater or equal to the given value. + :param transaction_uuid: The transaction identifier must be equal to the given value. + :param transaction_uuid_ne: The transaction identifier must be distinct of the given value. + :param transaction_uuid_in: The destination transaction identifier must be equal to one of the given values. + + :return: A ``DatabaseOperation`` instance. + """ _select_all = """ SELECT uuid, name, version, data, id, action, created_at, transaction_uuid @@ -243,7 +278,10 @@ def build_select_rows( ) def build_select_max_id(self) -> DatabaseOperation: - """TODO""" + """Build the database operation to get the maximum identifier. + + :return: A ``DatabaseOperation`` instance. + """ return AiopgDatabaseOperation("SELECT MAX(id) FROM aggregate_event;".strip()) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py index 13344e137..78d895209 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py @@ -28,15 +28,22 @@ class SnapshotDatabaseOperationFactory(DatabaseOperationFactory, ABC): - """TODO""" + """Snapshot Database Operation Factory class.""" @abstractmethod def build_create_table(self) -> DatabaseOperation: - """TODO""" + """Build the database operation to create the snapshot table. + + :return: A ``DatabaseOperation`` instance. + """ @abstractmethod def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: - """TODO""" + """Build the database operation to delete rows by transaction identifiers. + + :param transaction_uuids: The transaction identifiers. + :return: A ``DatabaseOperation`` instance. + """ @abstractmethod def build_insert( @@ -50,7 +57,18 @@ def build_insert( updated_at: datetime, transaction_uuid: UUID, ) -> DatabaseOperation: - """TODO""" + """Build the insert database operation. + + :param uuid: The identifier of the entity. + :param name: The name of the entity. + :param version: The version of the entity. + :param schema: The schema of the entity. + :param data: The data of the entity. + :param created_at: The creation datetime. + :param updated_at: The last update datetime. + :param transaction_uuid: The transaction identifier. + :return: A ``DatabaseOperation`` instance. + """ @abstractmethod def build_query( @@ -62,12 +80,33 @@ def build_query( transaction_uuids: tuple[UUID, ...], exclude_deleted: bool, ) -> DatabaseOperation: - """TODO""" + """Build the query database operation. + + :param name: Class name of the ``RootEntity``. + :param condition: The condition that must be satisfied by the ``RootEntity`` instances. + :param ordering: Optional argument to return the instance with specific ordering strategy. The default behaviour + is to retrieve them without any order pattern. + :param limit: Optional argument to return only a subset of instances. The default behaviour is to return all the + instances that meet the given condition. + :param transaction_uuids: The transaction within the operation is performed. If not any value is provided, then + the transaction is extracted from the context var. If not any transaction is being scoped then the query is + performed to the global snapshot. + :param exclude_deleted: If ``True``, deleted ``RootEntity`` entries are included, otherwise deleted + ``RootEntity`` entries are filtered. + :return: A ``DatabaseOperation`` instance. + """ @abstractmethod def build_store_offset(self, value: int) -> DatabaseOperation: - """TODO""" + """Build the database operation to store the offset. + + :param value: The value to be stored as the new offset. + :return: A ``DatabaseOperation`` instance. + """ @abstractmethod def build_get_offset(self) -> DatabaseOperation: - """TODO""" + """Build the database operation to get the current offset. + + :return: A ``DatabaseOperation`` instance. + """ diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py index c9e2ebcb1..391d487f5 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py @@ -33,10 +33,13 @@ # noinspection SqlNoDataSourceInspection,SqlResolve class AiopgSnapshotDatabaseOperationFactory(SnapshotDatabaseOperationFactory): - """TODO""" + """Aiopg Snapshot Database Operation Factory class.""" def build_create_table(self) -> DatabaseOperation: - """TODO""" + """Build the database operation to create the snapshot table. + + :return: A ``DatabaseOperation`` instance. + """ return ComposedDatabaseOperation( [ AiopgDatabaseOperation( @@ -73,7 +76,11 @@ def build_create_table(self) -> DatabaseOperation: ) def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: - """TODO""" + """Build the database operation to delete rows by transaction identifiers. + + :param transaction_uuids: The transaction identifiers. + :return: A ``DatabaseOperation`` instance. + """ return AiopgDatabaseOperation( """ DELETE FROM snapshot @@ -93,7 +100,18 @@ def build_insert( updated_at: datetime, transaction_uuid: UUID, ) -> DatabaseOperation: - """TODO""" + """Build the insert database operation. + + :param uuid: The identifier of the entity. + :param name: The name of the entity. + :param version: The version of the entity. + :param schema: The schema of the entity. + :param data: The data of the entity. + :param created_at: The creation datetime. + :param updated_at: The last update datetime. + :param transaction_uuid: The transaction identifier. + :return: A ``DatabaseOperation`` instance. + """ return AiopgDatabaseOperation( """ @@ -134,7 +152,21 @@ def build_query( transaction_uuids: tuple[UUID, ...], exclude_deleted: bool, ) -> DatabaseOperation: - """TODO""" + """Build the query database operation. + + :param name: Class name of the ``RootEntity``. + :param condition: The condition that must be satisfied by the ``RootEntity`` instances. + :param ordering: Optional argument to return the instance with specific ordering strategy. The default behaviour + is to retrieve them without any order pattern. + :param limit: Optional argument to return only a subset of instances. The default behaviour is to return all the + instances that meet the given condition. + :param transaction_uuids: The transaction within the operation is performed. If not any value is provided, then + the transaction is extracted from the context var. If not any transaction is being scoped then the query is + performed to the global snapshot. + :param exclude_deleted: If ``True``, deleted ``RootEntity`` entries are included, otherwise deleted + ``RootEntity`` entries are filtered. + :return: A ``DatabaseOperation`` instance. + """ builder = AiopgSnapshotQueryDatabaseOperationBuilder( name, condition, ordering, limit, transaction_uuids, exclude_deleted ) @@ -143,7 +175,11 @@ def build_query( return AiopgDatabaseOperation(query, parameters) def build_store_offset(self, value: int) -> DatabaseOperation: - """TODO""" + """Build the database operation to store the offset. + + :param value: The value to be stored as the new offset. + :return: A ``DatabaseOperation`` instance. + """ return AiopgDatabaseOperation( """ INSERT INTO snapshot_aux_offset (id, value) @@ -156,7 +192,10 @@ def build_store_offset(self, value: int) -> DatabaseOperation: ) def build_get_offset(self) -> DatabaseOperation: - """TODO""" + """Build the database operation to get the current offset. + + :return: A ``DatabaseOperation`` instance. + """ return AiopgDatabaseOperation( """ SELECT value diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py index 035847c54..07c09914d 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py @@ -29,11 +29,14 @@ class TransactionDatabaseOperationFactory(DatabaseOperationFactory, ABC): - """TODO""" + """Transaction Database Operation Factory base class.""" @abstractmethod def build_create_table(self) -> DatabaseOperation: - """TODO""" + """Build the database operation to create the snapshot table. + + :return: A ``DatabaseOperation`` instance. + """ @abstractmethod def build_submit_row( @@ -43,7 +46,14 @@ def build_submit_row( status: TransactionStatus, event_offset: int, ) -> DatabaseOperation: - """TODO""" + """Build the database operation to submit a row. + + :param uuid: The identifier of the transaction. + :param destination_uuid: The identifier of the destination transaction. + :param status: The status of the transaction. + :param event_offset: The event offset of the transaction. + :return: A ``DatabaseOperation`` instance. + """ @abstractmethod def build_select_rows( @@ -66,4 +76,24 @@ def build_select_rows( updated_at_ge: Optional[datetime] = None, **kwargs, ) -> DatabaseOperation: - """TODO""" + """Build the database operation to select rows. + + :param uuid: Transaction identifier equal to the given value. + :param uuid_ne: Transaction identifier not equal to the given value + :param uuid_in: Transaction identifier within the given values. + :param destination_uuid: Destination Transaction identifier equal to the given value. + :param status: Transaction status equal to the given value. + :param status_in: Transaction status within the given values + :param event_offset: Event offset equal to the given value. + :param event_offset_lt: Event Offset lower than the given value + :param event_offset_gt: Event Offset greater than the given value + :param event_offset_le: Event Offset lower or equal to the given value + :param event_offset_ge: Event Offset greater or equal to the given value + :param updated_at: Updated at equal to the given value. + :param updated_at_lt: Updated at lower than the given value. + :param updated_at_gt: Updated at greater than the given value. + :param updated_at_le: Updated at lower or equal to the given value. + :param updated_at_ge: Updated at greater or equal to the given value. + :param kwargs: Additional named arguments. + :return: A ``DatabaseOperation`` instance. + """ diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py index d49106aab..c325fb9e1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py @@ -32,10 +32,13 @@ # noinspection SqlNoDataSourceInspection,SqlResolve,PyMethodMayBeStatic class AiopgTransactionDatabaseOperationFactory(TransactionDatabaseOperationFactory): - """TODO""" + """Aiopg Transaction Database Operation Factory class.""" def build_create_table(self) -> DatabaseOperation: - """TODO""" + """Build the database operation to create the snapshot table. + + :return: A ``DatabaseOperation`` instance. + """ return ComposedDatabaseOperation( [ @@ -86,7 +89,15 @@ def build_submit_row( status: TransactionStatus, event_offset: int, ) -> DatabaseOperation: - """TODO""" + """Build the database operation to submit a row. + + :param uuid: The identifier of the transaction. + :param destination_uuid: The identifier of the destination transaction. + :param status: The status of the transaction. + :param event_offset: The event offset of the transaction. + :return: A ``DatabaseOperation`` instance. + """ + params = { "uuid": uuid, "destination_uuid": destination_uuid, @@ -134,7 +145,28 @@ def build_select_rows( updated_at_ge: Optional[datetime] = None, **kwargs, ) -> DatabaseOperation: - """TODO""" + """Build the database operation to select rows. + + :param uuid: Transaction identifier equal to the given value. + :param uuid_ne: Transaction identifier not equal to the given value + :param uuid_in: Transaction identifier within the given values. + :param destination_uuid: Destination Transaction identifier equal to the given value. + :param status: Transaction status equal to the given value. + :param status_in: Transaction status within the given values + :param event_offset: Event offset equal to the given value. + :param event_offset_lt: Event Offset lower than the given value + :param event_offset_gt: Event Offset greater than the given value + :param event_offset_le: Event Offset lower or equal to the given value + :param event_offset_ge: Event Offset greater or equal to the given value + :param updated_at: Updated at equal to the given value. + :param updated_at_lt: Updated at lower than the given value. + :param updated_at_gt: Updated at greater than the given value. + :param updated_at_le: Updated at lower or equal to the given value. + :param updated_at_ge: Updated at greater or equal to the given value. + :param kwargs: Additional named arguments. + :return: A ``DatabaseOperation`` instance. + """ + conditions = list() if uuid is not None: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index 35b36595e..68618a05b 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -31,11 +31,11 @@ def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) repository = DatabaseEventRepository(pool) self.assertIsInstance(repository, DatabaseEventRepository) - self.assertIsInstance(repository.pool, DatabaseClientPool) + self.assertIsInstance(repository.database_pool, DatabaseClientPool) def test_from_config(self): repository = DatabaseEventRepository.from_config(self.config) - self.assertIsInstance(repository.pool, DatabaseClientPool) + self.assertIsInstance(repository.database_pool, DatabaseClientPool) async def test_setup(self): async with AiopgDatabaseClient(**self.config.get_default_database()) as client: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py index 4f447cc14..092aa086d 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py @@ -97,7 +97,7 @@ def test_type(self): def test_from_config(self): reader = DatabaseSnapshotReader.from_config(self.config) - self.assertIsInstance(reader.pool, DatabaseClientPool) + self.assertIsInstance(reader.database_pool, DatabaseClientPool) async def test_find_by_uuid(self): condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py index c3c406628..dd639b53e 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py @@ -102,7 +102,7 @@ def test_type(self): self.assertTrue(issubclass(DatabaseSnapshotWriter, DatabaseSnapshotSetup)) def test_from_config(self): - self.assertIsInstance(self.writer.pool, DatabaseClientPool) + self.assertIsInstance(self.writer.database_pool, DatabaseClientPool) def test_from_config_raises(self): with self.assertRaises(NotProvidedException): diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index 424dbf54b..c24350f48 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -47,11 +47,11 @@ def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) repository = DatabaseTransactionRepository(pool) self.assertIsInstance(repository, DatabaseTransactionRepository) - self.assertEqual(pool, repository.pool) + self.assertEqual(pool, repository.database_pool) def test_from_config(self): repository = DatabaseTransactionRepository.from_config(self.config) - self.assertIsInstance(repository.pool, DatabaseClientPool) + self.assertIsInstance(repository.database_pool, DatabaseClientPool) async def test_setup(self): async with AiopgDatabaseClient(**self.config.get_default_database()) as client: diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 14b327d07..15f8c7cb4 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -83,7 +83,7 @@ async def _reset(self, **kwargs) -> None: async def execute(self, operation: DatabaseOperation) -> None: """Execute an operation. - :param operation: TODO + :param operation: The operation to be executed. :return: This method does not return anything. """ if operation.lock is not None: @@ -145,11 +145,11 @@ def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: @classmethod def register_factory(cls, base: type[DatabaseOperationFactory], impl: type[DatabaseOperationFactory]) -> None: - """TODO + """Register an operation factory implementation for an operation factory interface. - :param base: TODO - :param impl: TODO - :return: + :param base: The operation factory interface. + :param impl: The operation factory implementation. + :return: This method does not return anything. """ if not issubclass(base, DatabaseOperationFactory): raise ValueError(f"{base!r} must be a subclass of {DatabaseOperationFactory!r}") @@ -161,10 +161,10 @@ def register_factory(cls, base: type[DatabaseOperationFactory], impl: type[Datab @classmethod def get_factory(cls, base: type[DatabaseOperationFactory]) -> DatabaseOperationFactory: - """TODO + """Get an operation factory implementation for an operation factory interface. - :param base: TODO - :return: TODO + :param base: The operation factory interface. + :return: The operation factory implementation. """ return cls._factories[base]() diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py index 13049f194..f16e689dd 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py @@ -10,12 +10,20 @@ class LockDatabaseOperationFactory(DatabaseOperationFactory, ABC): - """TODO""" + """Lock Database Operation Factory class.""" @abstractmethod def build_acquire(self, hashed_key: int) -> DatabaseOperation: - """TODO""" + """Build the database operation to acquire the lock. + + :param hashed_key: The hashed key that identifies the lock. + :return: A ``DatabaseOperation`` instance. + """ @abstractmethod def build_release(self, hashed_key: int) -> DatabaseOperation: - """TODO""" + """Build the database operation to release the lock. + + :param hashed_key: The hashed key that identifies the lock. + :return: A ``DatabaseOperation`` instance. + """ diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py index 817b4c121..b590a58f7 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py @@ -11,14 +11,22 @@ class AiopgLockDatabaseOperationFactory(LockDatabaseOperationFactory): - """TODO""" + """Aiopg Lock Database Operation Factory class.""" def build_acquire(self, hashed_key: int) -> DatabaseOperation: - """TODO""" + """Build the database operation to acquire the lock. + + :param hashed_key: The hashed key that identifies the lock. + :return: A ``DatabaseOperation`` instance. + """ return AiopgDatabaseOperation("select pg_advisory_lock(%(hashed_key)s)", {"hashed_key": hashed_key}) def build_release(self, hashed_key: int) -> DatabaseOperation: - """TODO""" + """Build the database operation to release the lock. + + :param hashed_key: The hashed key that identifies the lock. + :return: A ``DatabaseOperation`` instance. + """ return AiopgDatabaseOperation("select pg_advisory_unlock(%(hashed_key)s)", {"hashed_key": hashed_key}) diff --git a/packages/core/minos-microservice-common/minos/common/database/manage/factories.py b/packages/core/minos-microservice-common/minos/common/database/manage/factories.py index cf486e90f..7ded96715 100644 --- a/packages/core/minos-microservice-common/minos/common/database/manage/factories.py +++ b/packages/core/minos-microservice-common/minos/common/database/manage/factories.py @@ -14,30 +14,43 @@ class ManageDatabaseOperationFactory(DatabaseOperationFactory, ABC): - """TODO""" + """Manage Database Operation Factory base class.""" @abstractmethod - def build_create( - self, - database: str, - ) -> DatabaseOperation: - """TODO""" + def build_create(self, database: str) -> DatabaseOperation: + """Build the database operation to create a database. + + :param database: The new database's name. + :return: A ``DatabaseOperation``. + """ @abstractmethod def build_delete(self, database: str) -> DatabaseOperation: - """TODO""" + """Build the database operation to create a database. + + :param database: The name of the database to be deleted. + :return: A ``DatabaseOperation``. + """ # noinspection SqlNoDataSourceInspection class AiopgManageDatabaseOperationFactory(ManageDatabaseOperationFactory): - """TODO""" + """Aiopg Manage Database Operation Factory class.""" def build_create(self, database: str) -> DatabaseOperation: - """TODO""" + """Build the database operation to create a database. + + :param database: The new database's name. + :return: A ``DatabaseOperation``. + """ return AiopgDatabaseOperation(f"CREATE DATABASE {database};") def build_delete(self, database: str) -> DatabaseOperation: - """TODO""" + """Build the database operation to create a database. + + :param database: The name of the database to be deleted. + :return: A ``DatabaseOperation``. + """ return AiopgDatabaseOperation(f"DROP DATABASE IF EXISTS {database};") diff --git a/packages/core/minos-microservice-common/minos/common/database/mixins.py b/packages/core/minos-microservice-common/minos/common/database/mixins.py index 59eceeaac..e8174ce4a 100644 --- a/packages/core/minos-microservice-common/minos/common/database/mixins.py +++ b/packages/core/minos-microservice-common/minos/common/database/mixins.py @@ -3,7 +3,8 @@ Generic, Optional, TypeVar, - get_args, get_origin, + get_args, + get_origin, ) from ..exceptions import ( @@ -57,15 +58,15 @@ def __init__( if operation_factory_cls is None: operation_factory_cls = self._get_generic_operation_factory() if operation_factory_cls is not None: - operation_factory = self.pool_instance_cls.get_factory(operation_factory_cls) + operation_factory = self.database_client_cls.get_factory(operation_factory_cls) self._operation_factory = operation_factory @property def operation_factory(self) -> Optional[GenericDatabaseOperationFactory]: - """TODO + """Get the operation factory if any. - :return: TODO + :return: A ``OperationFactory`` if it has been set or ``None`` otherwise. """ return self._operation_factory @@ -89,10 +90,10 @@ def _get_generic_operation_factory(self) -> Optional[type[GenericDatabaseOperati async def submit_query_and_fetchone(self, operation: DatabaseOperation) -> tuple: """Submit a SQL query and gets the first response. - :param operation: TODO + :param operation: The operation to be executed. :return: This method does not return anything. """ - async with self.pool.acquire() as client: + async with self.database_pool.acquire() as client: await client.execute(operation) return await client.fetch_one() @@ -102,7 +103,7 @@ async def submit_query_and_iter( ) -> AsyncIterator[tuple]: """Submit a SQL query and return an asynchronous iterator. - :param operation: TODO + :param operation: The operation to be executed. :param streaming_mode: If ``True`` return the values in streaming directly from the database (keep an open database connection), otherwise preloads the full set of values on memory and then retrieves them. :return: This method does not return anything. @@ -110,7 +111,7 @@ async def submit_query_and_iter( if streaming_mode is None: streaming_mode = False - async with self.pool.acquire() as client: + async with self.database_pool.acquire() as client: await client.execute(operation) async_iterable = client.fetch_all() if streaming_mode: @@ -127,24 +128,24 @@ async def submit_query_and_iter( async def submit_query(self, operation: DatabaseOperation) -> None: """Submit a SQL query. - :param operation: TODO + :param operation: The operation to be executed. :return: This method does not return anything. """ - async with self.pool.acquire() as client: + async with self.database_pool.acquire() as client: return await client.execute(operation) @property - def pool_instance_cls(self) -> type[DatabaseClient]: - """TODO + def database_client_cls(self) -> type[DatabaseClient]: + """Get the client's class. - :return: TODO + :return: A ``type`` instance that is subclass of ``DatabaseClient``. """ - return self.pool.instance_cls + return self.database_pool.client_cls @property - def pool(self) -> DatabaseClientPool: - """Get the connections pool. + def database_pool(self) -> DatabaseClientPool: + """Get the database pool. - :return: A ``Pool`` object. + :return: A ``DatabaseClientPool`` object. """ return self._pool diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py index 3e2180ffd..502237c5a 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py @@ -15,7 +15,7 @@ class DatabaseOperation(ABC): - """TODO""" + """Database Operation base class.""" def __init__(self, *args, lock: Optional[Hashable] = None, timeout: Optional[float] = None, **kwargs): self.lock = lock @@ -23,7 +23,7 @@ def __init__(self, *args, lock: Optional[Hashable] = None, timeout: Optional[flo class ComposedDatabaseOperation(DatabaseOperation): - """TODO""" + """Composed Database Operation class.""" def __init__(self, operations: Iterable[DatabaseOperation], *args, **kwargs): super().__init__(*args, **kwargs) @@ -31,4 +31,4 @@ def __init__(self, operations: Iterable[DatabaseOperation], *args, **kwargs): class DatabaseOperationFactory(ABC): - """TODO""" + """Database Operation Factory base class.""" diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py index efba2ee0a..5126ff888 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py @@ -13,7 +13,7 @@ class AiopgDatabaseOperation(DatabaseOperation): - """TODO""" + """Aiopg Database Operation class.""" def __init__(self, query: Union[str, Composable], parameters: dict[str, Any] = None, *args, **kwargs): super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 268d9b75a..16aec0c9b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -88,10 +88,10 @@ async def _release_instance(self, instance: DatabaseClient) -> None: await instance.reset() @property - def instance_cls(self) -> type[DatabaseClient]: - """TODO + def client_cls(self) -> type[DatabaseClient]: + """Get the instance's class. - :return: TODO + :return: A ``type`` instance that is subclass of ``DatabaseClient``. """ return self.client_builder.instance_cls diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py index a83e58e46..1e66f8cb6 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py @@ -21,14 +21,14 @@ class TestDatabaseMixin(CommonTestCase, DatabaseMinosTestCase): def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) database = DatabaseMixin(pool) - self.assertEqual(pool, database.pool) + self.assertEqual(pool, database.database_pool) async def test_constructor_with_pool_factory(self): pool_factory = PoolFactory(self.config, {"database": DatabaseClientPool}) # noinspection PyTypeChecker database = DatabaseMixin(pool_factory=pool_factory) # noinspection PyUnresolvedReferences - self.assertEqual(pool_factory.get_pool("database"), database.pool) + self.assertEqual(pool_factory.get_pool("database"), database.database_pool) async def test_constructor_raises(self): with self.assertRaises(NotProvidedException): @@ -37,7 +37,7 @@ async def test_constructor_raises(self): async def test_pool(self): async with DatabaseMixin() as database: - self.assertIsInstance(database.pool, DatabaseClientPool) + self.assertIsInstance(database.database_pool, DatabaseClientPool) async def test_submit_query(self): op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);") diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index 1bf8d2729..cdfe1e328 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -198,7 +198,7 @@ async def _get_count(self) -> int: return count async def _dequeue_batch(self) -> None: - async with self.pool.acquire() as client: + async with self.database_pool.acquire() as client: rows = await self._dequeue_rows(client) if not len(rows): diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py index 87dba8d38..d00bb82e8 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py @@ -14,7 +14,7 @@ # noinspection SqlNoDataSourceInspection,SqlResolve class BrokerSubscriberDuplicateValidatorDatabaseOperationFactory(DatabaseOperationFactory, ABC): - """TODO""" + """Broker Subscriber Duplicate Validator Database Operation Factory class.""" @abstractmethod def build_create_table(self) -> DatabaseOperation: diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index 4bfdfe859..7d57dbbbd 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -45,7 +45,7 @@ def test_is_subclass(self): def test_constructor(self): queue = DatabaseBrokerQueue(operation_factory=self.operation_factory) - self.assertEqual(self.pool_factory.get_pool("database"), queue.pool) + self.assertEqual(self.pool_factory.get_pool("database"), queue.database_pool) self.assertEqual(self.operation_factory, queue.operation_factory) self.assertEqual(2, queue.retry) self.assertEqual(1000, queue.records) From 285dbc059cb2e0f45684ad7f7aa5166f81436334 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 17:16:32 +0200 Subject: [PATCH 170/324] ISSUE #371 * Increase coverage. --- .../minos/common/database/clients/abc.py | 13 ++++- .../minos/common/database/clients/aiopg.py | 2 +- .../minos/common/database/operations/abc.py | 2 +- .../test_database/test_clients/test_abc.py | 55 +++++++++++++++++++ .../test_database/test_clients/test_aiopg.py | 9 +++ 5 files changed, 77 insertions(+), 4 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 15f8c7cb4..37c707434 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -37,14 +37,14 @@ from ..locks import ( DatabaseLock, ) + logger = logging.getLogger(__name__) class DatabaseClient(ABC, BuildableMixin): """Database Client base class.""" - _factories: dict[type[DatabaseOperationFactory], type[DatabaseOperationFactory]] = dict() - + _factories: dict[type[DatabaseOperationFactory], type[DatabaseOperationFactory]] _lock: Optional[DatabaseLock] def __init__(self, *args, **kwargs): @@ -86,6 +86,9 @@ async def execute(self, operation: DatabaseOperation) -> None: :param operation: The operation to be executed. :return: This method does not return anything. """ + if not isinstance(operation, DatabaseOperation): + raise ValueError(f"The operation must be a {DatabaseOperation!r} instance. Obtained: {operation!r}") + if operation.lock is not None: await self._create_lock(operation.lock) @@ -157,6 +160,9 @@ def register_factory(cls, base: type[DatabaseOperationFactory], impl: type[Datab if not issubclass(impl, base): raise ValueError(f"{impl!r} must be a subclass of {base!r}") + if not hasattr(cls, "_factories"): + cls._factories = dict() + cls._factories[base] = impl @classmethod @@ -166,6 +172,9 @@ def get_factory(cls, base: type[DatabaseOperationFactory]) -> DatabaseOperationF :param base: The operation factory interface. :return: The operation factory implementation. """ + if not hasattr(cls, "_factories") or base not in cls._factories: + raise ValueError(f"{cls!r} does not contain any registered factory implementation for {base!r}") + return cls._factories[base]() diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py index da4410912..e9ffcd49f 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py @@ -122,7 +122,7 @@ async def _fetch_all(self) -> AsyncIterator[tuple]: # noinspection PyUnusedLocal async def _execute(self, operation: AiopgDatabaseOperation) -> None: if not isinstance(operation, AiopgDatabaseOperation): - raise ValueError(f"The operation is not supported: {operation!r}") + raise ValueError(f"The operation must be a {AiopgDatabaseOperation!r} instance. Obtained: {operation!r}") await self._create_cursor() try: diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py index 502237c5a..72b69d69e 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/abc.py @@ -27,7 +27,7 @@ class ComposedDatabaseOperation(DatabaseOperation): def __init__(self, operations: Iterable[DatabaseOperation], *args, **kwargs): super().__init__(*args, **kwargs) - self.operations = operations + self.operations = tuple(operations) class DatabaseOperationFactory(ABC): diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index 7a4457e47..dbbf9afa0 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -15,9 +15,11 @@ from minos.common import ( AiopgDatabaseClient, BuildableMixin, + ComposedDatabaseOperation, DatabaseClient, DatabaseClientBuilder, DatabaseOperation, + DatabaseOperationFactory, ) from tests.utils import ( CommonTestCase, @@ -45,6 +47,14 @@ class _DatabaseOperation(DatabaseOperation): """For testing purposes.""" +class _DatabaseOperationFactory(DatabaseOperationFactory): + """For testing purposes.""" + + +class _DatabaseOperationFactoryImpl(_DatabaseOperationFactory): + """For testing purposes.""" + + class TestDatabaseClient(unittest.IsolatedAsyncioTestCase): def test_abstract(self): self.assertTrue(issubclass(DatabaseClient, (ABC, BuildableMixin))) @@ -83,6 +93,21 @@ async def test_execute(self): self.assertEqual([call(operation)], mock.call_args_list) + async def test_execute_composed(self): + mock = AsyncMock() + client = _DatabaseClient() + client._execute = mock + composed = ComposedDatabaseOperation([_DatabaseOperation(), _DatabaseOperation()]) + await client.execute(composed) + + self.assertEqual([call(composed.operations[0]), call(composed.operations[1])], mock.call_args_list) + + async def test_execute_raises_unsupported(self): + client = _DatabaseClient() + with self.assertRaises(ValueError): + # noinspection PyTypeChecker + await client.execute("wrong!") + async def test_fetch_all(self): mock = MagicMock(return_value=FakeAsyncIterator(["one", "two"])) client = _DatabaseClient() @@ -101,6 +126,36 @@ async def test_fetch_one(self): self.assertEqual([call()], mock.call_args_list) + def test_register_factory(self): + try: + _DatabaseClient.register_factory(_DatabaseOperationFactory, _DatabaseOperationFactoryImpl) + + self.assertEqual({_DatabaseOperationFactory: _DatabaseOperationFactoryImpl}, _DatabaseClient._factories) + finally: + _DatabaseClient._factories.clear() + + def test_register_factory_raises(self): + with self.assertRaises(ValueError): + # noinspection PyTypeChecker + _DatabaseClient.register_factory(object, DatabaseOperationFactory) + + with self.assertRaises(ValueError): + _DatabaseClient.register_factory(_DatabaseOperationFactoryImpl, _DatabaseOperationFactory) + + def test_get_factory(self): + try: + _DatabaseClient._factories = {_DatabaseOperationFactory: _DatabaseOperationFactoryImpl} + self.assertIsInstance( + _DatabaseClient.get_factory(_DatabaseOperationFactory), + _DatabaseOperationFactoryImpl, + ) + finally: + _DatabaseClient._factories.clear() + + def test_get_factory_raises(self): + with self.assertRaises(ValueError): + _DatabaseClient.get_factory(_DatabaseOperationFactory), + class TestDatabaseClientBuilder(CommonTestCase): def test_with_name(self): diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py index d275b2d1b..22683030f 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py @@ -19,6 +19,7 @@ AiopgDatabaseClient, AiopgDatabaseOperation, DatabaseLock, + DatabaseOperation, IntegrityException, UnableToConnectException, ) @@ -160,6 +161,14 @@ async def test_execute_with_lock_multiple(self): self.assertNotEqual(foo_lock, client.lock) self.assertIsInstance(client.lock, DatabaseLock) + async def test_execute_raises_unsupported(self): + class _DatabaseOperation(DatabaseOperation): + """For testing purposes.""" + + async with AiopgDatabaseClient.from_config(self.config) as client: + with self.assertRaises(ValueError): + await client.execute(_DatabaseOperation()) + async def test_execute_raises_integrity(self): async with AiopgDatabaseClient.from_config(self.config) as client: with patch.object(Cursor, "execute", side_effect=IntegrityError): From b83135618f2f38bd9d17b82a0318af2e2bb028a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 7 Apr 2022 17:53:12 +0200 Subject: [PATCH 171/324] ISSUE #371 * Increase coverage (2). --- .../minos/common/config/v2.py | 26 +++++----- .../minos/common/database/mixins.py | 2 - .../{test_abc.py => test_mixins.py} | 29 +++++++++++ .../test_database/test_operations/__init__.py | 0 .../test_database/test_operations/test_abc.py | 48 +++++++++++++++++++ .../test_operations/test_aiopg.py | 22 +++++++++ .../test_common/test_database/test_pools.py | 13 +++++ 7 files changed, 125 insertions(+), 15 deletions(-) rename packages/core/minos-microservice-common/tests/test_common/test_database/{test_abc.py => test_mixins.py} (79%) create mode 100644 packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/__init__.py create mode 100644 packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_abc.py create mode 100644 packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_aiopg.py diff --git a/packages/core/minos-microservice-common/minos/common/config/v2.py b/packages/core/minos-microservice-common/minos/common/config/v2.py index ff6c04a76..345829d74 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v2.py +++ b/packages/core/minos-microservice-common/minos/common/config/v2.py @@ -100,52 +100,52 @@ def _get_injections(self) -> list[Union[InjectableMixin, type[InjectableMixin]]] def _get_databases(self) -> dict[str, dict[str, Any]]: data = deepcopy(self.get_by_key("databases")) for database in data.values(): - if "client" in database: + if database.get("client") is not None: database["client"] = import_module(database["client"]) return data def _get_interfaces(self) -> dict[str, dict[str, Any]]: data = deepcopy(self.get_by_key("interfaces")) - if "http" in data: + if data.get("http") is not None: data["http"] = self._parse_http_interface(data["http"]) - if "broker" in data: + if data.get("broker") is not None: data["broker"] = self._parse_broker_interface(data["broker"]) - if "periodic" in data: + if data.get("periodic") is not None: data["periodic"] = self._parse_periodic_interface(data["periodic"]) return data @staticmethod def _parse_http_interface(data: dict[str, Any]) -> dict[str, Any]: - if "port" in data: + if data.get("port") is not None: data["port"] = import_module(data["port"]) - if "connector" in data: + if data.get("connector") is not None: data["connector"]["client"] = import_module(data["connector"]["client"]) return data @staticmethod def _parse_broker_interface(data: dict[str, Any]) -> dict[str, Any]: - if "port" in data: + if data.get("port") is not None: data["port"] = import_module(data["port"]) - if "publisher" in data: + if data.get("publisher") is not None: data["publisher"]["client"] = import_module(data["publisher"]["client"]) - if "queue" in data["publisher"]: + if data["publisher"].get("queue") is not None: data["publisher"]["queue"] = import_module(data["publisher"]["queue"]) - if "subscriber" in data: + if data.get("subscriber") is not None: data["subscriber"]["client"] = import_module(data["subscriber"]["client"]) - if "queue" in data["subscriber"]: + if data["subscriber"].get("queue") is not None: data["subscriber"]["queue"] = import_module(data["subscriber"]["queue"]) - if "validator" in data["subscriber"]: + if data["subscriber"].get("validator") is not None: data["subscriber"]["validator"] = import_module(data["subscriber"]["validator"]) return data @staticmethod def _parse_periodic_interface(data: dict[str, Any]) -> dict[str, Any]: - if "port" in data: + if data.get("port") is not None: data["port"] = import_module(data["port"]) return data diff --git a/packages/core/minos-microservice-common/minos/common/database/mixins.py b/packages/core/minos-microservice-common/minos/common/database/mixins.py index e8174ce4a..13602518c 100644 --- a/packages/core/minos-microservice-common/minos/common/database/mixins.py +++ b/packages/core/minos-microservice-common/minos/common/database/mixins.py @@ -78,8 +78,6 @@ def _get_generic_operation_factory(self) -> Optional[type[GenericDatabaseOperati if origin is None or not issubclass(origin, DatabaseMixin): continue args = get_args(base) - if not len(args): - continue operation_factory_cls = args[0] if not isinstance(operation_factory_cls, type) or not issubclass( operation_factory_cls, DatabaseOperationFactory diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py similarity index 79% rename from packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py rename to packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py index 1e66f8cb6..d41464845 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py @@ -3,8 +3,10 @@ from minos.common import ( AiopgDatabaseClient, AiopgDatabaseOperation, + AiopgLockDatabaseOperationFactory, DatabaseClientPool, DatabaseMixin, + LockDatabaseOperationFactory, NotProvidedException, PoolFactory, ) @@ -39,6 +41,33 @@ async def test_pool(self): async with DatabaseMixin() as database: self.assertIsInstance(database.database_pool, DatabaseClientPool) + async def test_operation_factory(self): + operation_factory = AiopgLockDatabaseOperationFactory() + mixin = DatabaseMixin(operation_factory=operation_factory) + self.assertEqual(operation_factory, mixin.operation_factory) + + async def test_operation_factory_from_cls_init(self): + mixin = DatabaseMixin(operation_factory_cls=LockDatabaseOperationFactory) + self.assertIsInstance(mixin.operation_factory, AiopgLockDatabaseOperationFactory) + + async def test_operation_factory_from_cls_generic(self): + class _DatabaseMixin(DatabaseMixin[LockDatabaseOperationFactory]): + """For testing purposes.""" + + mixin = _DatabaseMixin() + self.assertIsInstance(mixin.operation_factory, AiopgLockDatabaseOperationFactory) + + async def test_operation_factory_none(self): + mixin = DatabaseMixin() + self.assertEqual(None, mixin.operation_factory) + + async def test_operation_factory_from_cls_generic_raises(self): + class _DatabaseMixin(DatabaseMixin[int]): + """For testing purposes.""" + + with self.assertRaises(TypeError): + _DatabaseMixin() + async def test_submit_query(self): op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);") op2 = AiopgDatabaseOperation("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/__init__.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_abc.py new file mode 100644 index 000000000..78c1aef5f --- /dev/null +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_abc.py @@ -0,0 +1,48 @@ +import unittest +from abc import ( + ABC, +) + +from minos.common import ( + ComposedDatabaseOperation, + DatabaseOperation, + DatabaseOperationFactory, +) + + +class _DatabaseOperation(DatabaseOperation): + """For testing purposes.""" + + +class TestDatabaseOperation(unittest.TestCase): + def test_abstract(self): + self.assertTrue(issubclass(DatabaseOperation, ABC)) + + def test_constructor(self): + operation = _DatabaseOperation() + self.assertEqual(None, operation.timeout) + self.assertEqual(None, operation.lock) + + def test_constructor_extended(self): + operation = _DatabaseOperation(timeout=3, lock="foo") + self.assertEqual(3, operation.timeout) + self.assertEqual("foo", operation.lock) + + +class TestComposedDatabaseOperation(unittest.TestCase): + def test_subclass(self) -> None: + self.assertTrue(issubclass(ComposedDatabaseOperation, DatabaseOperation)) + + def test_constructor(self): + operations = [_DatabaseOperation(), _DatabaseOperation()] + composed = ComposedDatabaseOperation(operations) + self.assertEqual(tuple(operations), composed.operations) + + +class TestDatabaseOperationFactory(unittest.TestCase): + def test_abstract(self): + self.assertTrue(issubclass(DatabaseOperationFactory, ABC)) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_aiopg.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_aiopg.py new file mode 100644 index 000000000..766105ac0 --- /dev/null +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_aiopg.py @@ -0,0 +1,22 @@ +import unittest + +from minos.common import ( + AiopgDatabaseOperation, + DatabaseOperation, +) + + +class TestAiopgDatabaseOperation(unittest.TestCase): + def test_subclass(self) -> None: + self.assertTrue(issubclass(AiopgDatabaseOperation, DatabaseOperation)) + + def test_constructor(self): + operation = AiopgDatabaseOperation("query", {"foo": "bar"}) + self.assertEqual("query", operation.query) + self.assertEqual({"foo": "bar"}, operation.parameters) + self.assertEqual(None, operation.timeout) + self.assertEqual(None, operation.lock) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index e13729bd1..e8dbb12fd 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -5,17 +5,20 @@ from minos.common import ( AiopgDatabaseClient, + Config, DatabaseClient, DatabaseClientBuilder, DatabaseClientPool, DatabaseLock, DatabaseLockPool, UnableToConnectException, + classname, ) from minos.common.testing import ( DatabaseMinosTestCase, ) from tests.utils import ( + CONFIG_FILE_PATH, CommonTestCase, ) @@ -43,6 +46,16 @@ def test_from_config(self): self.assertIsInstance(pool.client_builder, DatabaseClientBuilder) self.assertEqual(AiopgDatabaseClient, pool.client_builder.instance_cls) + def test_from_config_client_builder(self): + config = Config(CONFIG_FILE_PATH, databases_default_client=classname(DatabaseClientBuilder)) + pool = DatabaseClientPool.from_config(config) + self.assertIsInstance(pool.client_builder, DatabaseClientBuilder) + + def test_from_config_client_none(self): + config = Config(CONFIG_FILE_PATH, databases_default_client=None) + with self.assertRaises(ValueError): + DatabaseClientPool.from_config(config) + async def test_acquire_once(self): async with self.pool.acquire() as c1: self.assertIsInstance(c1, DatabaseClient) From 3b2c66c583ccd6d50b5b7683a49470829654a707 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 7 Apr 2022 21:34:21 +0200 Subject: [PATCH 172/324] ISSUE #373 --- .../minos/networks/discovery/clients/abc.py | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py b/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py index c5e953b1c..ad870eae3 100644 --- a/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py @@ -7,7 +7,6 @@ ) from minos.common import ( - Object, Config, SetupMixin, ) From 16832ae704d18e7da5ac9b330e4e9bcc7a94ddc5 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Thu, 7 Apr 2022 19:34:30 +0000 Subject: [PATCH 173/324] Restyled by isort --- .../minos/networks/discovery/clients/abc.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py b/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py index ad870eae3..81d80caf3 100644 --- a/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/discovery/clients/abc.py @@ -1,4 +1,6 @@ -from __future__ import annotations +from __future__ import ( + annotations, +) import logging from abc import ( From ec34b632035a5c79655bf171884f046d55775667 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 7 Apr 2022 21:46:54 +0200 Subject: [PATCH 174/324] ISSUE #387 --- .../minos/plugins/kong/__init__.py | 1 + .../minos/plugins/kong/client.py | 103 +++++----- .../minos/plugins/kong/kong_client.py | 137 ++++++++++++++ .../minos-discovery-kong/tests/__init__.py | 1 + .../tests/test_config.yml | 5 + .../tests/test_kong/test_client.py | 141 ++++++++++++++ .../tests/test_kong/test_kong_client.py | 179 ++++++++++++++++++ .../minos-discovery-kong/tests/utils.py | 6 + 8 files changed, 522 insertions(+), 51 deletions(-) create mode 100644 packages/plugins/minos-discovery-kong/minos/plugins/kong/kong_client.py create mode 100644 packages/plugins/minos-discovery-kong/tests/__init__.py create mode 100644 packages/plugins/minos-discovery-kong/tests/test_config.yml create mode 100644 packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py create mode 100644 packages/plugins/minos-discovery-kong/tests/utils.py diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index 7cd96f503..fb9f9f7b5 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -3,5 +3,6 @@ __version__ = "0.1.0a1" from .client import ( + KongClient, KongDiscoveryClient, ) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index 01c183d06..067281218 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -1,3 +1,7 @@ +from __future__ import ( + annotations, +) + import logging from collections.abc import ( Iterable, @@ -13,11 +17,15 @@ from minos.common import ( CircuitBreakerMixin, + Config, ) from minos.networks import ( DiscoveryClient, ) +from .kong_client import ( + KongClient, +) from .utils import ( Endpoint, ) @@ -42,6 +50,21 @@ def __init__( super().__init__( host, port, circuit_breaker_exceptions=(httpx.HTTPStatusError, *circuit_breaker_exceptions), **kwargs ) + self.kong = KongClient(self.route) + + self.auth_type = None + if "auth_type" in kwargs: + self.auth_type = kwargs["auth_type"] + + @classmethod + def _from_config(cls, config: Config, **kwargs) -> KongDiscoveryClient: + if "auth_type" in kwargs: + auth_type = kwargs['auth_type'] + kwargs.pop('auth_type') + else: + auth_type = config.get_by_key("discovery.auth-type") + + return super()._from_config(config, auth_type=auth_type, **kwargs) async def subscribe( self, host: str, port: int, name: str, endpoints: list[dict[str, str]], *args, **kwargs @@ -57,49 +80,48 @@ async def subscribe( :return: This method does not return anything. """ - fnsr = partial(self._register_service, self.route, name, host, port) + fnsr = partial(self.kong.register_service, self.route, name, host, port) response_service = await self.with_circuit_breaker(fnsr) # register a service if response_service.status_code == 409: # service already exist # if service already exist, delete and add again - fn_delete = partial(self._delete_service, self.route, name) + fn_delete = partial(self.kong.delete_service, self.route, name) await self.with_circuit_breaker(fn_delete) # delete the service - fnsr = partial(self._register_service, self.route, name, host, port) + fnsr = partial(self.kong.register_service, self.route, name, host, port) response_service = await self.with_circuit_breaker(fnsr) # send the servie subscription again content_service = response_service.json() # get the servie information like the id for endpoint in endpoints: endpointClass = Endpoint(endpoint["url"]) - data = { - "protocols": ["http"], - "methods": [endpoint["method"]], - "paths": [endpointClass.path_as_str], - "service": {"id": content_service["id"]}, - "strip_path": False, - } - fn = partial(self._subscribe_routes, self.route, data) + + fn = partial( + self.kong.create_route, + self.route, + ["http"], + [endpoint["method"]], + [endpointClass.path_as_str], + content_service["id"], + False, + ) response = await self.with_circuit_breaker(fn) # send the route request + resp = response.json() + + if "authorized" in endpoint and self.auth_type: + if self.auth_type == "basic-auth": + fn = partial(self.kong.activate_basic_auth_plugin_on_route, route_id=resp["id"]) + await self.with_circuit_breaker(fn) + elif self.auth_type == "jwt": + fn = partial(self.kong.activate_jwt_plugin_on_route, route_id=resp["id"]) + await self.with_circuit_breaker(fn) + + if "allowed_groups" in endpoint: + fn = partial( + self.kong.activate_acl_plugin_on_route, route_id=resp["id"], allow=endpoint["allowed_groups"] + ) + await self.with_circuit_breaker(fn) return response - @staticmethod - async def _register_service( - discovery_route: str, service_name: str, microservice_host: str, microservice_port: str - ) -> httpx.Response: - url = f"{discovery_route}/services" # kong url for service POST or add - data = {"name": service_name, "protocol": "http", "host": microservice_host, "port": microservice_port} - async with httpx.AsyncClient() as client: - response = await client.post(url, json=data) - return response - - @staticmethod - async def _subscribe_routes(endpoint: str, data: dict[str, str]) -> httpx.Response: - logger.debug(f"Subscribing into {endpoint!r}...") - url = f"{endpoint}/routes" - async with httpx.AsyncClient() as client: - response = await client.post(url, json=data) - return response - async def unsubscribe(self, name: str, *args, **kwargs) -> httpx.Response: """Perform the unsubscription query. @@ -108,27 +130,6 @@ async def unsubscribe(self, name: str, *args, **kwargs) -> httpx.Response: :param kwargs: Additional named arguments. :return: This method does not return anything. """ - fn = partial(self._delete_service, self.route, name) + fn = partial(self.kong.delete_service, self.route, name) response = await self.with_circuit_breaker(fn) return response - - @staticmethod - async def _delete_service(discovery_route: str, service_name) -> httpx.Response: - """ - the delete of a service must be checking before if the service already have the routes - if yes the DELETE routes must be called - :param discovery_route: - :param service_name: - :return: - """ - async with httpx.AsyncClient() as client: - url_get_route = f"{discovery_route}/services/{service_name}/routes" # url to get the routes - response_routes = await client.get(url_get_route) - json_routes_response = response_routes.json() - if len(json_routes_response["data"]) > 0: # service already have route, routes must be deleted - for route in json_routes_response["data"]: - url_delete_route = f"{discovery_route}/routes/{route['id']}" # url for routes delete - await client.delete(url_delete_route) - url_delete_service = f"{discovery_route}/services/{service_name}" # url for service delete - response_delete_service = await client.delete(url_delete_service) - return response_delete_service diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/kong_client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/kong_client.py new file mode 100644 index 000000000..0f7f522a3 --- /dev/null +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/kong_client.py @@ -0,0 +1,137 @@ +from uuid import ( + UUID, +) + +import httpx as httpx + + +class KongClient: + """Kong Client class.""" + + def __init__(self, route): + self.route = route + + @staticmethod + async def register_service( + discovery_route: str, service_name: str, microservice_host: str, microservice_port: int + ) -> httpx.Response: + url = f"{discovery_route}/services" # kong url for service POST or add + data = {"name": service_name, "protocol": "http", "host": microservice_host, "port": microservice_port} + async with httpx.AsyncClient() as client: + response = await client.post(url, json=data) + return response + + @staticmethod + async def delete_service(discovery_route: str, service_name) -> httpx.Response: + """ + the delete of a service must be checking before if the service already have the routes + if yes the DELETE routes must be called + :param discovery_route: + :param service_name: + :return: + """ + async with httpx.AsyncClient() as client: + url_get_route = f"{discovery_route}/services/{service_name}/routes" # url to get the routes + response_routes = await client.get(url_get_route) + json_routes_response = response_routes.json() + if len(json_routes_response["data"]) > 0: # service already have route, routes must be deleted + for route in json_routes_response["data"]: + url_delete_route = f"{discovery_route}/routes/{route['id']}" # url for routes delete + await client.delete(url_delete_route) + url_delete_service = f"{discovery_route}/services/{service_name}" # url for service delete + response_delete_service = await client.delete(url_delete_service) + return response_delete_service + + @staticmethod + async def create_route( + endpoint: str, + protocols: list[str], + methods: list[str], + paths: list[str], + service: str, + strip_path: bool = False, + ): + url = f"{endpoint}/routes" + payload = { + "protocols": protocols, + "methods": methods, + "paths": paths, + "service": {"id": service}, + "strip_path": strip_path, + } + + async with httpx.AsyncClient() as client: + resp = await client.post(url, json=payload) + + return resp + + async def create_consumer(self, username: str, user: UUID, tags: list[str]): + payload = {"username": username, "custom_id": str(user), "tags": tags} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/consumers", json=payload) + return resp + + async def add_basic_auth_to_consumer(self, username: str, password: str, consumer: str): + payload = { + "username": username, + "password": password, + } + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/consumers/{consumer}/basic-auth", json=payload) + + return resp + + async def add_jwt_to_consumer(self, consumer: str): + async with httpx.AsyncClient() as client: + resp = await client.post( + f"{self.route}/consumers/{consumer}/jwt", + headers={"content-type": "application/x-www-form-urlencoded"}, + ) + + return resp + + async def add_acl_to_consumer(self, role: str, consumer: str): + payload = { + "group": role, + } + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/consumers/{consumer}/acls", json=payload) + return resp + + async def activate_acl_plugin_on_service(self, service_name: str, allow: list[str]): + payload = {"name": "acl", "config": {"allow": allow}} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/services/{service_name}/plugins", json=payload) + return resp + + async def activate_acl_plugin_on_route(self, route_id: str, allow: list[str]): + payload = {"name": "acl", "config": {"allow": allow}} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) + return resp + + async def activate_basic_auth_plugin_on_service(self, service_name: str): + payload = {"name": "basic-auth", "config": {"hide_credentials": False}} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/services/{service_name}/plugins", json=payload) + return resp + + async def activate_basic_auth_plugin_on_route(self, route_id: str): + payload = {"name": "basic-auth", "config": {"hide_credentials": False}} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) + return resp + + async def activate_jwt_plugin_on_route(self, route_id: str): + payload = {"name": "jwt", "config": {"secret_is_base64": False, "run_on_preflight": True}} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) + return resp diff --git a/packages/plugins/minos-discovery-kong/tests/__init__.py b/packages/plugins/minos-discovery-kong/tests/__init__.py new file mode 100644 index 000000000..84e6145e1 --- /dev/null +++ b/packages/plugins/minos-discovery-kong/tests/__init__.py @@ -0,0 +1 @@ +"""Unit test package for minos_microservice_networks.""" diff --git a/packages/plugins/minos-discovery-kong/tests/test_config.yml b/packages/plugins/minos-discovery-kong/tests/test_config.yml new file mode 100644 index 000000000..5717a6327 --- /dev/null +++ b/packages/plugins/minos-discovery-kong/tests/test_config.yml @@ -0,0 +1,5 @@ +discovery: + client: minos.networks.InMemoryDiscoveryClient + auth-type: jwt + host: localhost + port: 8001 diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index dcdbc2a26..b98ebdcbf 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -6,9 +6,15 @@ import httpx +from minos.common import ( + Config, +) from minos.plugins.kong import ( KongDiscoveryClient, ) +from tests.utils import ( + CONFIG_FILE_PATH, +) PROTOCOL = "http" @@ -72,6 +78,29 @@ async def test_subscribe(self): self.assertEqual("172.160.16.24", response_data["host"]) self.assertEqual(PROTOCOL, response_data["protocol"]) + async def test_subscribe_with_auth(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + "172.160.16.24", + 5660, + name, + [ + {"url": "/", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + {"url": "/foo", "method": "POST", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + {"url": "/bar", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + ], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + async def test_unsubscribe(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( @@ -110,5 +139,117 @@ async def test_route_params(self): self.assertTrue(bool(set(route["paths"]) & set(expected))) +class TestKongDiscoveryClientFromConfig(unittest.IsolatedAsyncioTestCase): + KONG_HOST = os.getenv("KONG_HOST", "localhost") + KONG_PORT = os.getenv("KONG_PORT", 8001) + + def setUp(self) -> None: + config = Config(CONFIG_FILE_PATH) + self.client = KongDiscoveryClient.from_config(config=config, circuit_breaker_time=0.1) + + @staticmethod + def generate_underscore_uuid(): + name = str(uuid4()) + return name.replace("-", "_") + + async def test_subscribe(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + "172.160.16.24", + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + async def test_subscribe_with_auth(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + "172.160.16.24", + 5660, + name, + [ + {"url": "/", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + {"url": "/foo", "method": "POST", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + {"url": "/bar", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + ], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + +class TestKongDiscoveryClientFromConfigOverrideAuth(unittest.IsolatedAsyncioTestCase): + KONG_HOST = os.getenv("KONG_HOST", "localhost") + KONG_PORT = os.getenv("KONG_PORT", 8001) + + def setUp(self) -> None: + config = Config(CONFIG_FILE_PATH) + self.client = KongDiscoveryClient.from_config(config=config, auth_type="basic-auth", circuit_breaker_time=0.1) + + @staticmethod + def generate_underscore_uuid(): + name = str(uuid4()) + return name.replace("-", "_") + + async def test_subscribe(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + "172.160.16.24", + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + async def test_subscribe_with_auth(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + "172.160.16.24", + 5660, + name, + [ + {"url": "/", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + {"url": "/foo", "method": "POST", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + {"url": "/bar", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + ], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + if __name__ == "__main__": unittest.main() diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py new file mode 100644 index 000000000..9a527e6c8 --- /dev/null +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py @@ -0,0 +1,179 @@ +import os +import unittest +from uuid import ( + uuid4, +) + +import httpx + +from minos.plugins.kong import ( + KongClient, + KongDiscoveryClient, +) + +PROTOCOL = "http" + + +class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): + KONG_HOST = os.getenv("KONG_HOST", "localhost") + KONG_PORT = os.getenv("KONG_PORT", 8001) + + def setUp(self) -> None: + self.client = KongDiscoveryClient(self.KONG_HOST, self.KONG_PORT, circuit_breaker_time=0.1) + self.kong = KongClient(self.client.route) + + @staticmethod + def generate_underscore_uuid(): + name = str(uuid4()) + return name.replace("-", "_") + + async def test_register_service(self): + name = self.generate_underscore_uuid() + response = await self.kong.register_service( + discovery_route=self.client.route, + service_name=name, + microservice_host="172.160.16.24", + microservice_port=5660, + ) + + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{self.client.route}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + async def test_create_consumer(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) + + self.assertTrue(201 == response.status_code) + + async def test_add_basic_auth_to_consumer(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) + + self.assertTrue(201 == response.status_code) + resp = response.json() + + response = await self.kong.add_basic_auth_to_consumer(username=user_name, password="test", consumer=resp["id"]) + + self.assertTrue(201 == response.status_code) + + async def test_add_jwt_to_consumer(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) + + self.assertTrue(201 == response.status_code) + resp = response.json() + + response = await self.kong.add_jwt_to_consumer(consumer=resp["id"]) + + self.assertTrue(201 == response.status_code) + + async def test_add_acl_to_consumer(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) + + self.assertTrue(201 == response.status_code) + resp = response.json() + + response = await self.kong.add_acl_to_consumer(role="admin", consumer=resp["id"]) + + self.assertTrue(201 == response.status_code) + + async def test_activate_acl_plugin_on_service(self): + name = self.generate_underscore_uuid() + response = await self.kong.register_service( + discovery_route=self.client.route, + service_name=name, + microservice_host="172.160.16.24", + microservice_port=5660, + ) + + self.assertTrue(201 == response.status_code) + + response = await self.kong.activate_acl_plugin_on_service(service_name=name, allow=["admin"]) + + self.assertTrue(201 == response.status_code) + + async def test_activate_basic_auth_plugin_on_service(self): + name = self.generate_underscore_uuid() + response = await self.kong.register_service( + discovery_route=self.client.route, + service_name=name, + microservice_host="172.160.16.24", + microservice_port=5660, + ) + + self.assertTrue(201 == response.status_code) + + response = await self.kong.activate_basic_auth_plugin_on_service(service_name=name) + + self.assertTrue(201 == response.status_code) + + async def test_activate_basic_auth_plugin_on_route(self): + name = self.generate_underscore_uuid() + response = await self.kong.register_service( + discovery_route=self.client.route, + service_name=name, + microservice_host="172.160.16.24", + microservice_port=5660, + ) + + self.assertTrue(201 == response.status_code) + res = response.json() + response = await self.kong.create_route( + endpoint=self.client.route, + protocols=["http"], + methods=["GET"], + paths=["/foo"], + service=res["id"], + strip_path=False, + ) + + self.assertTrue(201 == response.status_code) + + res = response.json() + response = await self.kong.activate_basic_auth_plugin_on_route(route_id=res["id"]) + + self.assertTrue(201 == response.status_code) + + async def test_activate_jwt_plugin_on_route(self): + name = self.generate_underscore_uuid() + response = await self.kong.register_service( + discovery_route=self.client.route, + service_name=name, + microservice_host="172.160.16.24", + microservice_port=5660, + ) + + self.assertTrue(201 == response.status_code) + res = response.json() + response = await self.kong.create_route( + endpoint=self.client.route, + protocols=["http"], + methods=["GET"], + paths=["/foo"], + service=res["id"], + strip_path=False, + ) + + self.assertTrue(201 == response.status_code) + + res = response.json() + response = await self.kong.activate_jwt_plugin_on_route(route_id=res["id"]) + + self.assertTrue(201 == response.status_code) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/plugins/minos-discovery-kong/tests/utils.py b/packages/plugins/minos-discovery-kong/tests/utils.py new file mode 100644 index 000000000..c816e645f --- /dev/null +++ b/packages/plugins/minos-discovery-kong/tests/utils.py @@ -0,0 +1,6 @@ +from pathlib import ( + Path, +) + +BASE_PATH = Path(__file__).parent +CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" From 769c71e74569743ca4b4371e5f32b63f3236dabc Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Thu, 7 Apr 2022 19:47:07 +0000 Subject: [PATCH 175/324] Restyled by black --- .../plugins/minos-discovery-kong/minos/plugins/kong/client.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index 067281218..978d56e65 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -59,8 +59,8 @@ def __init__( @classmethod def _from_config(cls, config: Config, **kwargs) -> KongDiscoveryClient: if "auth_type" in kwargs: - auth_type = kwargs['auth_type'] - kwargs.pop('auth_type') + auth_type = kwargs["auth_type"] + kwargs.pop("auth_type") else: auth_type = config.get_by_key("discovery.auth-type") From fe89f5b9442af9f76ca8530b70eebc3c9fde11fa Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 7 Apr 2022 22:03:44 +0200 Subject: [PATCH 176/324] ISSUE #378 --- .../tests/test_kong/test_client.py | 33 ++++++++++--------- .../tests/test_kong/test_kong_client.py | 15 +++++---- .../minos-discovery-kong/tests/utils.py | 1 + 3 files changed, 26 insertions(+), 23 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index b98ebdcbf..436bba9a2 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -14,6 +14,7 @@ ) from tests.utils import ( CONFIG_FILE_PATH, + TEST_HOST, ) PROTOCOL = "http" @@ -44,7 +45,7 @@ async def test_already_exist_subscribe(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", + TEST_HOST, 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], @@ -52,7 +53,7 @@ async def test_already_exist_subscribe(self): self.assertTrue(201 == response.status_code) response = await self.client.subscribe( - "172.160.16.24", + TEST_HOST, 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], @@ -62,7 +63,7 @@ async def test_already_exist_subscribe(self): async def test_subscribe(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", + TEST_HOST, 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], @@ -75,13 +76,13 @@ async def test_subscribe(self): response_data = response.json() self.assertTrue(200 == response.status_code) self.assertEqual(5660, response_data["port"]) - self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(TEST_HOST, response_data["host"]) self.assertEqual(PROTOCOL, response_data["protocol"]) async def test_subscribe_with_auth(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", + TEST_HOST, 5660, name, [ @@ -98,13 +99,13 @@ async def test_subscribe_with_auth(self): response_data = response.json() self.assertTrue(200 == response.status_code) self.assertEqual(5660, response_data["port"]) - self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(TEST_HOST, response_data["host"]) self.assertEqual(PROTOCOL, response_data["protocol"]) async def test_unsubscribe(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", 5660, name, [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] + TEST_HOST, 5660, name, [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] ) self.assertTrue(201 == response.status_code) @@ -120,7 +121,7 @@ async def test_unsubscribe(self): async def test_route_params(self): expected = ["/foo/.*", "/bar/.*/.*"] response = await self.client.subscribe( - "172.160.16.24", + TEST_HOST, 5660, "test", [{"url": "/foo/{:user}", "method": "POST"}, {"url": "/bar/{:domain}/{:username}", "method": "GET"}], @@ -155,7 +156,7 @@ def generate_underscore_uuid(): async def test_subscribe(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", + TEST_HOST, 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], @@ -168,13 +169,13 @@ async def test_subscribe(self): response_data = response.json() self.assertTrue(200 == response.status_code) self.assertEqual(5660, response_data["port"]) - self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(TEST_HOST, response_data["host"]) self.assertEqual(PROTOCOL, response_data["protocol"]) async def test_subscribe_with_auth(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", + TEST_HOST, 5660, name, [ @@ -191,7 +192,7 @@ async def test_subscribe_with_auth(self): response_data = response.json() self.assertTrue(200 == response.status_code) self.assertEqual(5660, response_data["port"]) - self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(TEST_HOST, response_data["host"]) self.assertEqual(PROTOCOL, response_data["protocol"]) @@ -211,7 +212,7 @@ def generate_underscore_uuid(): async def test_subscribe(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", + TEST_HOST, 5660, name, [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], @@ -224,13 +225,13 @@ async def test_subscribe(self): response_data = response.json() self.assertTrue(200 == response.status_code) self.assertEqual(5660, response_data["port"]) - self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(TEST_HOST, response_data["host"]) self.assertEqual(PROTOCOL, response_data["protocol"]) async def test_subscribe_with_auth(self): name = self.generate_underscore_uuid() response = await self.client.subscribe( - "172.160.16.24", + TEST_HOST, 5660, name, [ @@ -247,7 +248,7 @@ async def test_subscribe_with_auth(self): response_data = response.json() self.assertTrue(200 == response.status_code) self.assertEqual(5660, response_data["port"]) - self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(TEST_HOST, response_data["host"]) self.assertEqual(PROTOCOL, response_data["protocol"]) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py index 9a527e6c8..61ee15c4b 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py @@ -10,6 +10,7 @@ KongClient, KongDiscoveryClient, ) +from tests.utils import TEST_HOST PROTOCOL = "http" @@ -32,7 +33,7 @@ async def test_register_service(self): response = await self.kong.register_service( discovery_route=self.client.route, service_name=name, - microservice_host="172.160.16.24", + microservice_host=TEST_HOST, microservice_port=5660, ) @@ -44,7 +45,7 @@ async def test_register_service(self): response_data = response.json() self.assertTrue(200 == response.status_code) self.assertEqual(5660, response_data["port"]) - self.assertEqual("172.160.16.24", response_data["host"]) + self.assertEqual(TEST_HOST, response_data["host"]) self.assertEqual(PROTOCOL, response_data["protocol"]) async def test_create_consumer(self): @@ -62,7 +63,7 @@ async def test_add_basic_auth_to_consumer(self): self.assertTrue(201 == response.status_code) resp = response.json() - response = await self.kong.add_basic_auth_to_consumer(username=user_name, password="test", consumer=resp["id"]) + response = await self.kong.add_basic_auth_to_consumer(user_name, "test", resp["id"]) self.assertTrue(201 == response.status_code) @@ -95,7 +96,7 @@ async def test_activate_acl_plugin_on_service(self): response = await self.kong.register_service( discovery_route=self.client.route, service_name=name, - microservice_host="172.160.16.24", + microservice_host=TEST_HOST, microservice_port=5660, ) @@ -110,7 +111,7 @@ async def test_activate_basic_auth_plugin_on_service(self): response = await self.kong.register_service( discovery_route=self.client.route, service_name=name, - microservice_host="172.160.16.24", + microservice_host=TEST_HOST, microservice_port=5660, ) @@ -125,7 +126,7 @@ async def test_activate_basic_auth_plugin_on_route(self): response = await self.kong.register_service( discovery_route=self.client.route, service_name=name, - microservice_host="172.160.16.24", + microservice_host=TEST_HOST, microservice_port=5660, ) @@ -152,7 +153,7 @@ async def test_activate_jwt_plugin_on_route(self): response = await self.kong.register_service( discovery_route=self.client.route, service_name=name, - microservice_host="172.160.16.24", + microservice_host=TEST_HOST, microservice_port=5660, ) diff --git a/packages/plugins/minos-discovery-kong/tests/utils.py b/packages/plugins/minos-discovery-kong/tests/utils.py index c816e645f..de7ecaa7b 100644 --- a/packages/plugins/minos-discovery-kong/tests/utils.py +++ b/packages/plugins/minos-discovery-kong/tests/utils.py @@ -4,3 +4,4 @@ BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" +TEST_HOST = "172.160.16.24" From 91e078d6d9035f59bf624fc3458e59851c617ac0 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 7 Apr 2022 22:17:21 +0200 Subject: [PATCH 177/324] ISSUE #373 --- .../test_networks/test_decorators/test_collectors.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py index 703c19086..728dd391d 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py @@ -20,6 +20,8 @@ class TestEnrouteCollector(unittest.IsolatedAsyncioTestCase): + ticket_route = "tickets/" + def test_decorated_str(self): analyzer = EnrouteCollector(classname(FakeService)) self.assertEqual(FakeService, analyzer.decorated) @@ -29,7 +31,8 @@ def test_get_all(self): observed = analyzer.get_all() expected = { - "get_tickets": {BrokerQueryEnrouteDecorator("GetTickets"), RestQueryEnrouteDecorator("tickets/", "GET")}, + "get_tickets": {BrokerQueryEnrouteDecorator("GetTickets"), + RestQueryEnrouteDecorator(self.ticket_route, "GET")}, "create_ticket": { BrokerCommandEnrouteDecorator("CreateTicket"), BrokerCommandEnrouteDecorator("AddTicket"), @@ -51,7 +54,7 @@ def test_get_rest_command_query(self): observed = analyzer.get_rest_command_query() expected = { - "get_tickets": {RestQueryEnrouteDecorator("tickets/", "GET")}, + "get_tickets": {RestQueryEnrouteDecorator(self.ticket_route, "GET")}, "create_ticket": {RestCommandEnrouteDecorator("orders/", "GET")}, "delete_ticket": {RestCommandEnrouteDecorator("orders/", "DELETE")}, } @@ -65,7 +68,7 @@ def test_get_rest_command_query_kwargs(self): expected = { "get_tickets": { RestQueryEnrouteDecorator( - "tickets/", + self.ticket_route, "GET", authorized=True, allowed_groups=[ From 1b3b96a4c296ca2ca1d927e6ebde045d0132253f Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 7 Apr 2022 22:17:52 +0200 Subject: [PATCH 178/324] ISSUE #378 --- .../minos-discovery-kong/tests/test_kong/test_kong_client.py | 4 +++- packages/plugins/minos-discovery-kong/tests/utils.py | 5 ++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py index 61ee15c4b..43c5715ed 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py @@ -10,7 +10,9 @@ KongClient, KongDiscoveryClient, ) -from tests.utils import TEST_HOST +from tests.utils import ( + TEST_HOST, +) PROTOCOL = "http" diff --git a/packages/plugins/minos-discovery-kong/tests/utils.py b/packages/plugins/minos-discovery-kong/tests/utils.py index de7ecaa7b..ed7df13ad 100644 --- a/packages/plugins/minos-discovery-kong/tests/utils.py +++ b/packages/plugins/minos-discovery-kong/tests/utils.py @@ -1,7 +1,10 @@ +import random +import socket +import struct from pathlib import ( Path, ) BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" -TEST_HOST = "172.160.16.24" +TEST_HOST = socket.inet_ntoa(struct.pack(">I", random.randint(1, 0xFFFFFFFF))) From b4985ddca1aca04461efca17e5b57b81c82fba20 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Thu, 7 Apr 2022 20:18:02 +0000 Subject: [PATCH 179/324] Restyled by black --- .../tests/test_networks/test_decorators/test_collectors.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py index 728dd391d..2f531d0a0 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py @@ -31,8 +31,10 @@ def test_get_all(self): observed = analyzer.get_all() expected = { - "get_tickets": {BrokerQueryEnrouteDecorator("GetTickets"), - RestQueryEnrouteDecorator(self.ticket_route, "GET")}, + "get_tickets": { + BrokerQueryEnrouteDecorator("GetTickets"), + RestQueryEnrouteDecorator(self.ticket_route, "GET"), + }, "create_ticket": { BrokerCommandEnrouteDecorator("CreateTicket"), BrokerCommandEnrouteDecorator("AddTicket"), From 786790edf9a98946c8900d3aedd620f29c8b9339 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 7 Apr 2022 22:25:52 +0200 Subject: [PATCH 180/324] ISSUE #378 --- packages/plugins/minos-discovery-kong/tests/utils.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/tests/utils.py b/packages/plugins/minos-discovery-kong/tests/utils.py index ed7df13ad..b351fe005 100644 --- a/packages/plugins/minos-discovery-kong/tests/utils.py +++ b/packages/plugins/minos-discovery-kong/tests/utils.py @@ -1,10 +1,8 @@ import random -import socket -import struct from pathlib import ( Path, ) BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" -TEST_HOST = socket.inet_ntoa(struct.pack(">I", random.randint(1, 0xFFFFFFFF))) +TEST_HOST = f"{random.randint(1,255)}.{random.randint(1,255)}.{random.randint(1,255)}.{random.randint(1,255)}" From 47120b44311aa32257565b6f6236d8a845e69d36 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 7 Apr 2022 22:28:29 +0200 Subject: [PATCH 181/324] ISSUE #378 --- packages/plugins/minos-discovery-kong/tests/utils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/tests/utils.py b/packages/plugins/minos-discovery-kong/tests/utils.py index b351fe005..c629ed540 100644 --- a/packages/plugins/minos-discovery-kong/tests/utils.py +++ b/packages/plugins/minos-discovery-kong/tests/utils.py @@ -5,4 +5,5 @@ BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" -TEST_HOST = f"{random.randint(1,255)}.{random.randint(1,255)}.{random.randint(1,255)}.{random.randint(1,255)}" +rand = random.randint(1, 255) +TEST_HOST = f"{rand}.{rand}.{rand}.{rand}" From 9376bd8259d8ae407afd37b62448b1be2e09d62b Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 7 Apr 2022 22:31:14 +0200 Subject: [PATCH 182/324] ISSUE #378 --- packages/plugins/minos-discovery-kong/tests/utils.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/tests/utils.py b/packages/plugins/minos-discovery-kong/tests/utils.py index c629ed540..b7f58120f 100644 --- a/packages/plugins/minos-discovery-kong/tests/utils.py +++ b/packages/plugins/minos-discovery-kong/tests/utils.py @@ -1,9 +1,8 @@ -import random from pathlib import ( Path, ) BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" -rand = random.randint(1, 255) +rand = 27 TEST_HOST = f"{rand}.{rand}.{rand}.{rand}" From 7271ab9941296dafd555901427b8279495535ab9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 8 Apr 2022 08:55:39 +0200 Subject: [PATCH 183/324] ISSUE #144 * Fix naming bug --- .pre-commit-config.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index efacc4d24..500b9a919 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -51,11 +51,11 @@ repos: files: ^packages/plugins/minos-discovery-minos/ language: system - - id: kong-discovery-kong-check + - id: minos-discovery-kong-check pass_filenames: false - entry: make --directory=packages/plugins/kong-discovery-kong check - name: Check kong-discovery-kong - files: ^packages/plugins/kong-discovery-kong/ + entry: make --directory=packages/plugins/minos-discovery-kong check + name: Check minos-discovery-kong + files: ^packages/plugins/minos-discovery-kong/ language: system - id: minos-http-aiohttp-check From e37be67a1f6ac9160660e80b6b376546ff2fcc39 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 8 Apr 2022 09:22:26 +0200 Subject: [PATCH 184/324] ISSUE #98 * Add package skeleton. --- .../minos-database-aiopg-publish.yml | 33 + .../workflows/minos-database-aiopg-tests.yml | 67 ++ .../plugins/minos-database-aiopg/AUTHORS.md | 15 + .../plugins/minos-database-aiopg/HISTORY.md | 2 + packages/plugins/minos-database-aiopg/LICENSE | 21 + .../plugins/minos-database-aiopg/Makefile | 37 + .../plugins/minos-database-aiopg/README.md | 47 + .../minos-database-aiopg/RUNTHETESTS.md | 20 + .../minos/plugins/aiopg/__init__.py | 0 .../plugins/minos-database-aiopg/poetry.lock | 886 ++++++++++++++++++ .../plugins/minos-database-aiopg/poetry.toml | 2 + .../minos-database-aiopg/pyproject.toml | 53 ++ .../plugins/minos-database-aiopg/setup.cfg | 28 + .../minos-database-aiopg/tests/__init__.py | 0 .../tests/test_aiopg/__init__.py | 0 .../tests/test_config.yml | 43 + .../minos-database-aiopg/tests/utils.py | 15 + 17 files changed, 1269 insertions(+) create mode 100644 .github/workflows/minos-database-aiopg-publish.yml create mode 100644 .github/workflows/minos-database-aiopg-tests.yml create mode 100644 packages/plugins/minos-database-aiopg/AUTHORS.md create mode 100644 packages/plugins/minos-database-aiopg/HISTORY.md create mode 100644 packages/plugins/minos-database-aiopg/LICENSE create mode 100644 packages/plugins/minos-database-aiopg/Makefile create mode 100644 packages/plugins/minos-database-aiopg/README.md create mode 100644 packages/plugins/minos-database-aiopg/RUNTHETESTS.md create mode 100644 packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/poetry.lock create mode 100644 packages/plugins/minos-database-aiopg/poetry.toml create mode 100644 packages/plugins/minos-database-aiopg/pyproject.toml create mode 100644 packages/plugins/minos-database-aiopg/setup.cfg create mode 100644 packages/plugins/minos-database-aiopg/tests/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_config.yml create mode 100644 packages/plugins/minos-database-aiopg/tests/utils.py diff --git a/.github/workflows/minos-database-aiopg-publish.yml b/.github/workflows/minos-database-aiopg-publish.yml new file mode 100644 index 000000000..95d9c4760 --- /dev/null +++ b/.github/workflows/minos-database-aiopg-publish.yml @@ -0,0 +1,33 @@ +name: "Publish: minos-database-aiopg" + +on: + push: + branches: + - '*.*.x' + paths: + - 'packages/plugins/minos-database-aiopg/**' + +jobs: + deploy: + runs-on: ubuntu-latest + container: python:3.9-buster + defaults: + run: + working-directory: packages/plugins/minos-database-aiopg + + steps: + + - name: Check out repository code + uses: actions/checkout@v2 + + - name: Install Poetry + uses: snok/install-poetry@v1 + + - name: Install dependencies + run: make install + + - name: Publish package + run: make release + env: + POETRY_HTTP_BASIC_PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }} + POETRY_HTTP_BASIC_PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }} diff --git a/.github/workflows/minos-database-aiopg-tests.yml b/.github/workflows/minos-database-aiopg-tests.yml new file mode 100644 index 000000000..6a887234e --- /dev/null +++ b/.github/workflows/minos-database-aiopg-tests.yml @@ -0,0 +1,67 @@ +name: "Test: minos-database-aiopg" + +on: + push: + branches: + - main + - '*.*.x' + pull_request: + paths: + - 'packages/plugins/minos-database-aiopg/**' + - 'packages/core/minos-microservice-aggregate/**' + - 'packages/core/minos-microservice-networks/**' + - 'packages/core/minos-microservice-common/**' + +jobs: + build: + runs-on: ubuntu-latest + container: python:3.9-buster + defaults: + run: + working-directory: packages/plugins/minos-database-aiopg + + services: + postgres: + image: postgres + env: + POSTGRES_USER: minos + POSTGRES_PASSWORD: min0s + POSTGRES_DB: order_db + ports: + - 5432:5432 + options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 + + env: + MINOS_BROKER_QUEUE_HOST: postgres + MINOS_BROKER_HOST: kafka + MINOS_REPOSITORY_HOST: postgres + MINOS_SNAPSHOT_HOST: postgres + + steps: + - name: Check out repository code + uses: actions/checkout@v2 + + - name: Install Poetry + uses: snok/install-poetry@v1 + + - name: Install dependencies + run: make install + + - name: Lint package + run: make lint + + - name: Test package with coverage + run: make coverage + + - name: Publish coverage + uses: codecov/codecov-action@v2 + with: + token: ${{ secrets.CODECOV_TOKEN }} + files: ./packages/plugins/minos-database-aiopg/coverage.xml + fail_ci_if_error: true + + - name: Generate documentation + run: make docs + + - name: Generate build + run: make dist diff --git a/packages/plugins/minos-database-aiopg/AUTHORS.md b/packages/plugins/minos-database-aiopg/AUTHORS.md new file mode 100644 index 000000000..30ff94991 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/AUTHORS.md @@ -0,0 +1,15 @@ +# Credits + +## Development Lead + +* Andrea Mucci + +## Core Devs + +* Sergio Garcia Prado +* Vladyslav Fenchak +* Alberto Amigo Alonso + +## Contributors + +None yet. Why not be the first? diff --git a/packages/plugins/minos-database-aiopg/HISTORY.md b/packages/plugins/minos-database-aiopg/HISTORY.md new file mode 100644 index 000000000..e0e57d3b3 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/HISTORY.md @@ -0,0 +1,2 @@ +# History + diff --git a/packages/plugins/minos-database-aiopg/LICENSE b/packages/plugins/minos-database-aiopg/LICENSE new file mode 100644 index 000000000..4daf85bf2 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2021 Clariteia + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/packages/plugins/minos-database-aiopg/Makefile b/packages/plugins/minos-database-aiopg/Makefile new file mode 100644 index 000000000..2016f9e38 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/Makefile @@ -0,0 +1,37 @@ +.PHONY: docs + +lint: + poetry run flake8 + +test: + poetry run pytest + +coverage: + poetry run coverage run -m pytest + poetry run coverage report -m + poetry run coverage xml + +reformat: + poetry run black --line-length 120 minos tests + poetry run isort minos tests + +release: + $(MAKE) dist + poetry publish + +dist: + poetry build + ls -l dist + +install: + poetry install + +update: + poetry update + +check: + $(MAKE) install + $(MAKE) reformat + $(MAKE) lint + $(MAKE) test + $(MAKE) dist diff --git a/packages/plugins/minos-database-aiopg/README.md b/packages/plugins/minos-database-aiopg/README.md new file mode 100644 index 000000000..e69c5b280 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/README.md @@ -0,0 +1,47 @@ +

+ Minos logo +

+ +## minos-database-aiopg + +[![PyPI Latest Release](https://img.shields.io/pypi/v/minos-database-aiopg.svg)](https://pypi.org/project/minos-database-aiopg/) +[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://minos-framework.github.io/minos-python) +[![License](https://img.shields.io/github/license/minos-framework/minos-python.svg)](https://github.com/minos-framework/minos-python/blob/main/LICENSE) +[![Coverage](https://codecov.io/github/minos-framework/minos-python/coverage.svg?branch=main)](https://codecov.io/gh/minos-framework/minos-python) +[![Stack Overflow](https://img.shields.io/badge/Stack%20Overflow-Ask%20a%20question-green)](https://stackoverflow.com/questions/tagged/minos) + +## Summary + +Minos is a framework which helps you create [reactive](https://www.reactivemanifesto.org/) microservices in Python. Internally, it leverages Event Sourcing, CQRS and a message driven architecture to fulfil the commitments of an asynchronous environment. + +## Installation + +Install the dependency: + +```shell +pip install minos-database-aiopg +``` + +Modify `config.yml` file: + +[TODO] + +## Documentation + +The official API Reference is publicly available at the [GitHub Pages](https://minos-framework.github.io/minos-python). + +## Source Code + +The source code of this project is hosted at the [GitHub Repository](https://github.com/minos-framework/minos-python). + +## Getting Help + +For usage questions, the best place to go to is [StackOverflow](https://stackoverflow.com/questions/tagged/minos). + +## Discussion and Development + +Most development discussions take place over the [GitHub Issues](https://github.com/minos-framework/minos-python/issues). In addition, a [Gitter channel](https://gitter.im/minos-framework/community) is available for development-related questions. + +## License + +This project is distributed under the [MIT](https://raw.githubusercontent.com/minos-framework/minos-python/main/LICENSE) license. diff --git a/packages/plugins/minos-database-aiopg/RUNTHETESTS.md b/packages/plugins/minos-database-aiopg/RUNTHETESTS.md new file mode 100644 index 000000000..386e2b0e7 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/RUNTHETESTS.md @@ -0,0 +1,20 @@ +# Run the tests + +In order to run the tests, please make sure you have the `Docker Engine `_ +and `Docker Compose `_ installed. + +Move into tests/ directory + +`cd tests/` + +Run service dependencies: + +`docker-compose up -d` + +Install library dependencies: + +`make install` + +Run tests: + +`make test` diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/poetry.lock b/packages/plugins/minos-database-aiopg/poetry.lock new file mode 100644 index 000000000..9bc36cb30 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/poetry.lock @@ -0,0 +1,886 @@ +[[package]] +name = "aiomisc" +version = "15.8.0" +description = "aiomisc - miscellaneous utils for asyncio" +category = "main" +optional = false +python-versions = "*" + +[package.dependencies] +colorlog = "*" + +[package.extras] +aiohttp = ["aiohttp"] +asgi = ["aiohttp-asgi"] +carbon = ["aiocarbon (>=0.15,<1.0)"] +contextvars = ["contextvars (>=2.4,<3.0)"] +cron = ["croniter (>=0.3.34,<0.4.0)"] +develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-timeout", "coveralls", "croniter (>=0.3.34,<0.4.0)", "fastapi", "freezegun (<1.1)", "mypy (>=0.782,<1.0)", "pylava", "pytest", "pytest-cov (>=3.0,<4.0)", "pytest-freezegun (>=0.4.2,<0.5.0)", "pytest-rst", "pytest-subtests", "rich", "setproctitle", "sphinx-autobuild", "sphinx-intl", "sphinx (>=3.5.1)", "timeout-decorator", "tox (>=2.4)", "types-croniter"] +raven = ["raven-aiohttp"] +uvloop = ["uvloop (>=0.14,<1)"] + +[[package]] +name = "aiopg" +version = "1.3.3" +description = "Postgres integration with asyncio." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +async-timeout = ">=3.0,<5.0" +psycopg2-binary = ">=2.8.4" + +[package.extras] +sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] + +[[package]] +name = "async-timeout" +version = "4.0.2" +description = "Timeout context manager for asyncio programs" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "atomicwrites" +version = "1.4.0" +description = "Atomic file writes." +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" + +[[package]] +name = "attrs" +version = "21.4.0" +description = "Classes Without Boilerplate" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[package.extras] +dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] +docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] +tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] +tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] + +[[package]] +name = "black" +version = "22.3.0" +description = "The uncompromising code formatter." +category = "dev" +optional = false +python-versions = ">=3.6.2" + +[package.dependencies] +click = ">=8.0.0" +mypy-extensions = ">=0.4.3" +pathspec = ">=0.9.0" +platformdirs = ">=2" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} +typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} + +[package.extras] +colorama = ["colorama (>=0.4.3)"] +d = ["aiohttp (>=3.7.4)"] +jupyter = ["ipython (>=7.8.0)", "tokenize-rt (>=3.2.0)"] +uvloop = ["uvloop (>=0.15.2)"] + +[[package]] +name = "cached-property" +version = "1.5.2" +description = "A decorator for caching properties in classes." +category = "main" +optional = false +python-versions = "*" + +[[package]] +name = "click" +version = "8.1.2" +description = "Composable command line interface toolkit" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} + +[[package]] +name = "colorama" +version = "0.4.4" +description = "Cross-platform colored terminal text." +category = "main" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "colorlog" +version = "6.6.0" +description = "Add colours to the output of Python's logging module." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +colorama = {version = "*", markers = "sys_platform == \"win32\""} + +[package.extras] +development = ["black", "flake8", "mypy", "pytest", "types-colorama"] + +[[package]] +name = "coverage" +version = "6.3.2" +description = "Code coverage measurement for Python" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.extras] +toml = ["tomli"] + +[[package]] +name = "crontab" +version = "0.23.0" +description = "Parse and use crontab schedules in Python" +category = "main" +optional = false +python-versions = "*" + +[[package]] +name = "dependency-injector" +version = "4.39.1" +description = "Dependency injection framework for Python" +category = "main" +optional = false +python-versions = "*" + +[package.dependencies] +six = ">=1.7.0,<=1.16.0" + +[package.extras] +aiohttp = ["aiohttp"] +flask = ["flask"] +pydantic = ["pydantic"] +yaml = ["pyyaml"] + +[[package]] +name = "fastavro" +version = "1.4.10" +description = "Fast read/write of AVRO files" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.extras] +codecs = ["python-snappy", "zstandard", "lz4"] +lz4 = ["lz4"] +snappy = ["python-snappy"] +zstandard = ["zstandard"] + +[[package]] +name = "flake8" +version = "4.0.1" +description = "the modular source code checker: pep8 pyflakes and co" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +mccabe = ">=0.6.0,<0.7.0" +pycodestyle = ">=2.8.0,<2.9.0" +pyflakes = ">=2.4.0,<2.5.0" + +[[package]] +name = "iniconfig" +version = "1.1.1" +description = "iniconfig: brain-dead simple config-ini parsing" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "isort" +version = "5.10.1" +description = "A Python utility / library to sort Python imports." +category = "dev" +optional = false +python-versions = ">=3.6.1,<4.0" + +[package.extras] +pipfile_deprecated_finder = ["pipreqs", "requirementslib"] +requirements_deprecated_finder = ["pipreqs", "pip-api"] +colors = ["colorama (>=0.4.3,<0.5.0)"] +plugins = ["setuptools"] + +[[package]] +name = "lmdb" +version = "1.3.0" +description = "Universal Python binding for the LMDB 'Lightning' Database" +category = "main" +optional = false +python-versions = "*" + +[[package]] +name = "mccabe" +version = "0.6.1" +description = "McCabe checker, plugin for flake8" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "minos-microservice-aggregate" +version = "0.6.0" +description = "The Aggregate pattern of the Minos Framework" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +cached-property = "^1.5.2" +minos-microservice-common = "^0.6.0" +minos-microservice-networks = "^0.6.0" +psycopg2-binary = "^2.9.3" + +[package.source] +type = "directory" +url = "../../core/minos-microservice-aggregate" + +[[package]] +name = "minos-microservice-common" +version = "0.6.1" +description = "The common core of the Minos Framework" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +aiomisc = ">=14.0.3,<16.0.0" +aiopg = "^1.2.1" +cached-property = "^1.5.2" +dependency-injector = "^4.32.2" +fastavro = "^1.4.0" +lmdb = "^1.2.1" +orjson = "^3.5.2" +PyYAML = ">=5.4.1,<7.0.0" +uvloop = "^0.16.0" + +[package.source] +type = "directory" +url = "../../core/minos-microservice-common" + +[[package]] +name = "minos-microservice-networks" +version = "0.6.0" +description = "The networks core of the Minos Framework" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +aiopg = "^1.2.1" +crontab = "^0.23.0" +minos-microservice-common = "^0.6.0" +psycopg2-binary = "^2.9.3" + +[package.source] +type = "directory" +url = "../../core/minos-microservice-networks" + +[[package]] +name = "mypy-extensions" +version = "0.4.3" +description = "Experimental type system extensions for programs checked with the mypy typechecker." +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "orjson" +version = "3.6.7" +description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" +category = "main" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "packaging" +version = "21.3" +description = "Core utilities for Python packages" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" + +[[package]] +name = "pathspec" +version = "0.9.0" +description = "Utility library for gitignore style pattern matching of file paths." +category = "dev" +optional = false +python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" + +[[package]] +name = "platformdirs" +version = "2.5.1" +description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.extras] +docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] +test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] + +[[package]] +name = "pluggy" +version = "1.0.0" +description = "plugin and hook calling mechanisms for python" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.extras] +dev = ["pre-commit", "tox"] +testing = ["pytest", "pytest-benchmark"] + +[[package]] +name = "psycopg2-binary" +version = "2.9.3" +description = "psycopg2 - Python-PostgreSQL Database Adapter" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "py" +version = "1.11.0" +description = "library with cross-python path, ini-parsing, io, code, log facilities" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "pycodestyle" +version = "2.8.0" +description = "Python style guide checker" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "pyflakes" +version = "2.4.0" +description = "passive checker of Python programs" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" + +[[package]] +name = "pyparsing" +version = "3.0.7" +description = "Python parsing module" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.extras] +diagrams = ["jinja2", "railroad-diagrams"] + +[[package]] +name = "pytest" +version = "6.2.5" +description = "pytest: simple powerful testing with Python" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +atomicwrites = {version = ">=1.0", markers = "sys_platform == \"win32\""} +attrs = ">=19.2.0" +colorama = {version = "*", markers = "sys_platform == \"win32\""} +iniconfig = "*" +packaging = "*" +pluggy = ">=0.12,<2.0" +py = ">=1.8.2" +toml = "*" + +[package.extras] +testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] + +[[package]] +name = "pyyaml" +version = "6.0" +description = "YAML parser and emitter for Python" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "six" +version = "1.16.0" +description = "Python 2 and 3 compatibility utilities" +category = "main" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" + +[[package]] +name = "toml" +version = "0.10.2" +description = "Python Library for Tom's Obvious, Minimal Language" +category = "dev" +optional = false +python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" + +[[package]] +name = "tomli" +version = "2.0.1" +description = "A lil' TOML parser" +category = "dev" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "typing-extensions" +version = "4.1.1" +description = "Backported and Experimental Type Hints for Python 3.6+" +category = "dev" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "uvloop" +version = "0.16.0" +description = "Fast implementation of asyncio event loop on top of libuv" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.extras] +dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)", "aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] +docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] +test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] + +[metadata] +lock-version = "1.1" +python-versions = "^3.9" +content-hash = "db5ca350dc51163597dccfec3324385d9ae7ff94b5a20235688061dfe6a1173c" + +[metadata.files] +aiomisc = [ + {file = "aiomisc-15.8.0-py3-none-any.whl", hash = "sha256:4cb14333099853534b33223e8447075d00cf5a0aad36694e27b41661f5347d4a"}, + {file = "aiomisc-15.8.0.tar.gz", hash = "sha256:c8fe3699557fd362faca824ec759f1bf0c91c2d419491396e1af29203112a825"}, +] +aiopg = [ + {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, + {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, +] +async-timeout = [ + {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, + {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, +] +atomicwrites = [ + {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, + {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, +] +attrs = [ + {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, + {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, +] +black = [ + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, +] +cached-property = [ + {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, + {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, +] +click = [ + {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, + {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, +] +colorama = [ + {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, + {file = "colorama-0.4.4.tar.gz", hash = "sha256:5941b2b48a20143d2267e95b1c2a7603ce057ee39fd88e7329b0c292aa16869b"}, +] +colorlog = [ + {file = "colorlog-6.6.0-py2.py3-none-any.whl", hash = "sha256:351c51e866c86c3217f08e4b067a7974a678be78f07f85fc2d55b8babde6d94e"}, + {file = "colorlog-6.6.0.tar.gz", hash = "sha256:344f73204009e4c83c5b6beb00b3c45dc70fcdae3c80db919e0a4171d006fde8"}, +] +coverage = [ + {file = "coverage-6.3.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:9b27d894748475fa858f9597c0ee1d4829f44683f3813633aaf94b19cb5453cf"}, + {file = "coverage-6.3.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:37d1141ad6b2466a7b53a22e08fe76994c2d35a5b6b469590424a9953155afac"}, + {file = "coverage-6.3.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f9987b0354b06d4df0f4d3e0ec1ae76d7ce7cbca9a2f98c25041eb79eec766f1"}, + {file = "coverage-6.3.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:26e2deacd414fc2f97dd9f7676ee3eaecd299ca751412d89f40bc01557a6b1b4"}, + {file = "coverage-6.3.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4dd8bafa458b5c7d061540f1ee9f18025a68e2d8471b3e858a9dad47c8d41903"}, + {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:46191097ebc381fbf89bdce207a6c107ac4ec0890d8d20f3360345ff5976155c"}, + {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:6f89d05e028d274ce4fa1a86887b071ae1755082ef94a6740238cd7a8178804f"}, + {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:58303469e9a272b4abdb9e302a780072c0633cdcc0165db7eec0f9e32f901e05"}, + {file = "coverage-6.3.2-cp310-cp310-win32.whl", hash = "sha256:2fea046bfb455510e05be95e879f0e768d45c10c11509e20e06d8fcaa31d9e39"}, + {file = "coverage-6.3.2-cp310-cp310-win_amd64.whl", hash = "sha256:a2a8b8bcc399edb4347a5ca8b9b87e7524c0967b335fbb08a83c8421489ddee1"}, + {file = "coverage-6.3.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:f1555ea6d6da108e1999b2463ea1003fe03f29213e459145e70edbaf3e004aaa"}, + {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e5f4e1edcf57ce94e5475fe09e5afa3e3145081318e5fd1a43a6b4539a97e518"}, + {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7a15dc0a14008f1da3d1ebd44bdda3e357dbabdf5a0b5034d38fcde0b5c234b7"}, + {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:21b7745788866028adeb1e0eca3bf1101109e2dc58456cb49d2d9b99a8c516e6"}, + {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:8ce257cac556cb03be4a248d92ed36904a59a4a5ff55a994e92214cde15c5bad"}, + {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:b0be84e5a6209858a1d3e8d1806c46214e867ce1b0fd32e4ea03f4bd8b2e3359"}, + {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:acf53bc2cf7282ab9b8ba346746afe703474004d9e566ad164c91a7a59f188a4"}, + {file = "coverage-6.3.2-cp37-cp37m-win32.whl", hash = "sha256:8bdde1177f2311ee552f47ae6e5aa7750c0e3291ca6b75f71f7ffe1f1dab3dca"}, + {file = "coverage-6.3.2-cp37-cp37m-win_amd64.whl", hash = "sha256:b31651d018b23ec463e95cf10070d0b2c548aa950a03d0b559eaa11c7e5a6fa3"}, + {file = "coverage-6.3.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:07e6db90cd9686c767dcc593dff16c8c09f9814f5e9c51034066cad3373b914d"}, + {file = "coverage-6.3.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:2c6dbb42f3ad25760010c45191e9757e7dce981cbfb90e42feef301d71540059"}, + {file = "coverage-6.3.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c76aeef1b95aff3905fb2ae2d96e319caca5b76fa41d3470b19d4e4a3a313512"}, + {file = "coverage-6.3.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:8cf5cfcb1521dc3255d845d9dca3ff204b3229401994ef8d1984b32746bb45ca"}, + {file = "coverage-6.3.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8fbbdc8d55990eac1b0919ca69eb5a988a802b854488c34b8f37f3e2025fa90d"}, + {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ec6bc7fe73a938933d4178c9b23c4e0568e43e220aef9472c4f6044bfc6dd0f0"}, + {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:9baff2a45ae1f17c8078452e9e5962e518eab705e50a0aa8083733ea7d45f3a6"}, + {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:fd9e830e9d8d89b20ab1e5af09b32d33e1a08ef4c4e14411e559556fd788e6b2"}, + {file = "coverage-6.3.2-cp38-cp38-win32.whl", hash = "sha256:f7331dbf301b7289013175087636bbaf5b2405e57259dd2c42fdcc9fcc47325e"}, + {file = "coverage-6.3.2-cp38-cp38-win_amd64.whl", hash = "sha256:68353fe7cdf91f109fc7d474461b46e7f1f14e533e911a2a2cbb8b0fc8613cf1"}, + {file = "coverage-6.3.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b78e5afb39941572209f71866aa0b206c12f0109835aa0d601e41552f9b3e620"}, + {file = "coverage-6.3.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:4e21876082ed887baed0146fe222f861b5815455ada3b33b890f4105d806128d"}, + {file = "coverage-6.3.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:34626a7eee2a3da12af0507780bb51eb52dca0e1751fd1471d0810539cefb536"}, + {file = "coverage-6.3.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1ebf730d2381158ecf3dfd4453fbca0613e16eaa547b4170e2450c9707665ce7"}, + {file = "coverage-6.3.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dd6fe30bd519694b356cbfcaca9bd5c1737cddd20778c6a581ae20dc8c04def2"}, + {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:96f8a1cb43ca1422f36492bebe63312d396491a9165ed3b9231e778d43a7fca4"}, + {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:dd035edafefee4d573140a76fdc785dc38829fe5a455c4bb12bac8c20cfc3d69"}, + {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:5ca5aeb4344b30d0bec47481536b8ba1181d50dbe783b0e4ad03c95dc1296684"}, + {file = "coverage-6.3.2-cp39-cp39-win32.whl", hash = "sha256:f5fa5803f47e095d7ad8443d28b01d48c0359484fec1b9d8606d0e3282084bc4"}, + {file = "coverage-6.3.2-cp39-cp39-win_amd64.whl", hash = "sha256:9548f10d8be799551eb3a9c74bbf2b4934ddb330e08a73320123c07f95cc2d92"}, + {file = "coverage-6.3.2-pp36.pp37.pp38-none-any.whl", hash = "sha256:18d520c6860515a771708937d2f78f63cc47ab3b80cb78e86573b0a760161faf"}, + {file = "coverage-6.3.2.tar.gz", hash = "sha256:03e2a7826086b91ef345ff18742ee9fc47a6839ccd517061ef8fa1976e652ce9"}, +] +crontab = [ + {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, +] +dependency-injector = [ + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, +] +fastavro = [ + {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, + {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, + {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, + {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, + {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, + {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, + {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, + {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, + {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, + {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, + {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, + {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, + {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, + {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, + {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, + {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, +] +flake8 = [ + {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, + {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, +] +iniconfig = [ + {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, + {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, +] +isort = [ + {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, + {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, +] +lmdb = [ + {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, + {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, + {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, + {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, + {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, + {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, + {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, + {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, + {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, + {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, + {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, + {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, + {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, + {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, + {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, + {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, + {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, + {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, + {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, + {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, + {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, + {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, + {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, + {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, + {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, + {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, + {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, +] +mccabe = [ + {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, + {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, +] +minos-microservice-aggregate = [] +minos-microservice-common = [] +minos-microservice-networks = [] +mypy-extensions = [ + {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, + {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, +] +orjson = [ + {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, + {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, + {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, + {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, + {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, + {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, + {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, + {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, + {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, + {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, + {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, + {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, + {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, + {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, + {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, + {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, + {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, + {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, + {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, + {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, + {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, + {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, + {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, + {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, + {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, + {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, + {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, + {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, + {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, + {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, + {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, + {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, +] +packaging = [ + {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, + {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, +] +pathspec = [ + {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, + {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, +] +platformdirs = [ + {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, + {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, +] +pluggy = [ + {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, + {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, +] +psycopg2-binary = [ + {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, +] +py = [ + {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, + {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, +] +pycodestyle = [ + {file = "pycodestyle-2.8.0-py2.py3-none-any.whl", hash = "sha256:720f8b39dde8b293825e7ff02c475f3077124006db4f440dcbc9a20b76548a20"}, + {file = "pycodestyle-2.8.0.tar.gz", hash = "sha256:eddd5847ef438ea1c7870ca7eb78a9d47ce0cdb4851a5523949f2601d0cbbe7f"}, +] +pyflakes = [ + {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, + {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, +] +pyparsing = [ + {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, + {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, +] +pytest = [ + {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, + {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, +] +pyyaml = [ + {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, + {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, + {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, + {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4"}, + {file = "PyYAML-6.0-cp36-cp36m-win32.whl", hash = "sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293"}, + {file = "PyYAML-6.0-cp36-cp36m-win_amd64.whl", hash = "sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57"}, + {file = "PyYAML-6.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9"}, + {file = "PyYAML-6.0-cp37-cp37m-win32.whl", hash = "sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737"}, + {file = "PyYAML-6.0-cp37-cp37m-win_amd64.whl", hash = "sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d"}, + {file = "PyYAML-6.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287"}, + {file = "PyYAML-6.0-cp38-cp38-win32.whl", hash = "sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78"}, + {file = "PyYAML-6.0-cp38-cp38-win_amd64.whl", hash = "sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0"}, + {file = "PyYAML-6.0-cp39-cp39-win32.whl", hash = "sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb"}, + {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, + {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, +] +six = [ + {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, + {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, +] +toml = [ + {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, + {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, +] +tomli = [ + {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, + {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, +] +typing-extensions = [ + {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, + {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, +] +uvloop = [ + {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, + {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, + {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:bd53f7f5db562f37cd64a3af5012df8cac2c464c97e732ed556800129505bd64"}, + {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:772206116b9b57cd625c8a88f2413df2fcfd0b496eb188b82a43bed7af2c2ec9"}, + {file = "uvloop-0.16.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:b572256409f194521a9895aef274cea88731d14732343da3ecdb175228881638"}, + {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:04ff57aa137230d8cc968f03481176041ae789308b4d5079118331ab01112450"}, + {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3a19828c4f15687675ea912cc28bbcb48e9bb907c801873bd1519b96b04fb805"}, + {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e814ac2c6f9daf4c36eb8e85266859f42174a4ff0d71b99405ed559257750382"}, + {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:bd8f42ea1ea8f4e84d265769089964ddda95eb2bb38b5cbe26712b0616c3edee"}, + {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:647e481940379eebd314c00440314c81ea547aa636056f554d491e40503c8464"}, + {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e0d26fa5875d43ddbb0d9d79a447d2ace4180d9e3239788208527c4784f7cab"}, + {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:6ccd57ae8db17d677e9e06192e9c9ec4bd2066b77790f9aa7dede2cc4008ee8f"}, + {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:089b4834fd299d82d83a25e3335372f12117a7d38525217c2258e9b9f4578897"}, + {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98d117332cc9e5ea8dfdc2b28b0a23f60370d02e1395f88f40d1effd2cb86c4f"}, + {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, + {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, +] diff --git a/packages/plugins/minos-database-aiopg/poetry.toml b/packages/plugins/minos-database-aiopg/poetry.toml new file mode 100644 index 000000000..ab1033bd3 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/poetry.toml @@ -0,0 +1,2 @@ +[virtualenvs] +in-project = true diff --git a/packages/plugins/minos-database-aiopg/pyproject.toml b/packages/plugins/minos-database-aiopg/pyproject.toml new file mode 100644 index 000000000..23d108002 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/pyproject.toml @@ -0,0 +1,53 @@ +[tool.poetry] +name = "minos-database-aiopg" +version = "0.0.0" +description = "The aiopg plugin of the Minos Framework" +readme = "README.md" +repository = "https://github.com/minos-framework/minos-python" +homepage = "https://www.minos.run/" +authors = ["Minos Framework Devs "] +license = "MIT" +classifiers = [ + "Development Status :: 4 - Beta", + "Intended Audience :: Developers", + "Natural Language :: English", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3.9", +] +keywords = [ + "clariteia", + "minos", + "microservice", + "saga", +] +packages = [ + { include = "minos" } +] +include = [ + "AUTHORS.md", + "HISTORY.md", + "LICENSE", +] + +[tool.poetry.dependencies] +python = "^3.9" +minos-microservice-common = "^0.6.0" +minos-microservice-networks = "^0.6.0" +minos-microservice-aggregate = "^0.6.0" +aiopg = "^1.2.1" +psycopg2-binary = "^2.9.3" + +[tool.poetry.dev-dependencies] +minos-microservice-common = { path = "../../core/minos-microservice-common", develop = true } +minos-microservice-networks = { path = "../../core/minos-microservice-networks", develop = true } +minos-microservice-aggregate = { path = "../../core/minos-microservice-aggregate", develop = true } + +black = "^22.1" +isort = "^5.8.0" +pytest = "^6.2.4" +coverage = "^6.3" +flake8 = "^4.0.1" + +[build-system] +requires = ["poetry-core>=1.0.0"] +build-backend = "poetry.core.masonry.api" diff --git a/packages/plugins/minos-database-aiopg/setup.cfg b/packages/plugins/minos-database-aiopg/setup.cfg new file mode 100644 index 000000000..dbb9ac849 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/setup.cfg @@ -0,0 +1,28 @@ +[coverage:run] +source = + minos + +[coverage:report] +exclude_lines = + pragma: no cover + raise NotImplementedError + if TYPE_CHECKING: + pass +precision = 2 + +[flake8] +filename = + ./minos/**/*.py, + ./tests/**/*.py, + ./examples/**/*.py +max-line-length = 120 +per-file-ignores = + ./**/__init__.py:F401,W391 + +[isort] +known_first_party=minos +multi_line_output = 3 +include_trailing_comma = True +force_grid_wrap = 1 +use_parentheses = True +line_length = 120 diff --git a/packages/plugins/minos-database-aiopg/tests/__init__.py b/packages/plugins/minos-database-aiopg/tests/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/tests/test_config.yml b/packages/plugins/minos-database-aiopg/tests/test_config.yml new file mode 100644 index 000000000..5a44809fd --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_config.yml @@ -0,0 +1,43 @@ +service: + name: Order + aggregate: tests.utils.Order + services: + - minos.networks.HttpPort +routers: + - minos.networks.RestHttpRouter +services: + - tests.utils.FakeCommandService + - tests.utils.FakeQueryService +rest: + host: 0.0.0.0 + port: 7689 +repository: + database: order_db + user: minos + password: min0s + host: localhost + port: 5432 +snapshot: + database: order_db + user: minos + password: min0s + host: localhost + port: 5432 +broker: + host: localhost + port: 9092 + queue: + database: order_db + user: minos + password: min0s + host: localhost + port: 5432 + records: 10 + retry: 2 +saga: + storage: + path: "./order.lmdb" +discovery: + client: minos.networks.InMemoryDiscoveryClient + host: discovery-service + port: 8080 diff --git a/packages/plugins/minos-database-aiopg/tests/utils.py b/packages/plugins/minos-database-aiopg/tests/utils.py new file mode 100644 index 000000000..4400a258b --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/utils.py @@ -0,0 +1,15 @@ +from pathlib import ( + Path, +) + +from minos.common.testing import ( + MinosTestCase, +) + +BASE_PATH = Path(__file__).parent +CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" + + +class CommonTestCase(MinosTestCase): + def get_config_file_path(self) -> Path: + return CONFIG_FILE_PATH From 4402a56d0569313a7cf7f43efd857a55a4caa795 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 8 Apr 2022 09:38:46 +0200 Subject: [PATCH 185/324] ISSUE #98 * Migrate code from `minos-microservice-common`. --- .../minos/common/__init__.py | 4 -- .../minos/common/database/__init__.py | 4 -- .../minos/common/database/clients/__init__.py | 3 -- .../minos/common/database/locks/__init__.py | 1 - .../database/locks/factories/__init__.py | 5 +-- .../minos/common/database/manage/__init__.py | 1 - .../minos/common/database/manage/factories.py | 28 ------------ .../common/database/operations/__init__.py | 5 +-- .../minos/common/testing.py | 5 ++- .../minos/plugins/aiopg/__init__.py | 10 +++++ .../minos/plugins/aiopg/clients.py} | 11 +++-- .../minos/plugins/aiopg/factories/__init__.py | 4 ++ .../aiopg/factories/aggregate/__init__.py | 0 .../aiopg/factories/common/__init__.py | 6 +++ .../plugins/aiopg/factories/common/locks.py} | 9 ++-- .../plugins/aiopg/factories/common/manage.py | 35 +++++++++++++++ .../aiopg/factories/networks/__init__.py | 0 .../minos/plugins/aiopg/operations.py} | 2 +- .../tests/test_aiopg/test_clients.py} | 10 +++-- .../tests/test_aiopg/test_operations.py} | 4 +- .../tests/test_config.yml | 44 +++---------------- .../minos-database-aiopg/tests/utils.py | 2 +- 22 files changed, 86 insertions(+), 107 deletions(-) rename packages/{core/minos-microservice-common/minos/common/database/clients/aiopg.py => plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py} (98%) create mode 100644 packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/__init__.py rename packages/{core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py => plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/locks.py} (97%) create mode 100644 packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/manage.py create mode 100644 packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/__init__.py rename packages/{core/minos-microservice-common/minos/common/database/operations/aiopg.py => plugins/minos-database-aiopg/minos/plugins/aiopg/operations.py} (94%) rename packages/{core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py => plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py} (98%) rename packages/{core/minos-microservice-common/tests/test_common/test_database/test_operations/test_aiopg.py => plugins/minos-database-aiopg/tests/test_aiopg/test_operations.py} (94%) diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 44b04748c..08c200a00 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -14,10 +14,6 @@ MinosConfig, ) from .database import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, - AiopgLockDatabaseOperationFactory, - AiopgManageDatabaseOperationFactory, ComposedDatabaseOperation, DatabaseClient, DatabaseClientBuilder, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index 7f3e5676c..1ed02893f 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -1,5 +1,4 @@ from .clients import ( - AiopgDatabaseClient, DatabaseClient, DatabaseClientBuilder, DatabaseClientException, @@ -7,19 +6,16 @@ UnableToConnectException, ) from .locks import ( - AiopgLockDatabaseOperationFactory, DatabaseLock, LockDatabaseOperationFactory, ) from .manage import ( - AiopgManageDatabaseOperationFactory, ManageDatabaseOperationFactory, ) from .mixins import ( DatabaseMixin, ) from .operations import ( - AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, DatabaseOperationFactory, diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py index a2884b3c4..87f91189d 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py @@ -2,9 +2,6 @@ DatabaseClient, DatabaseClientBuilder, ) -from .aiopg import ( - AiopgDatabaseClient, -) from .exceptions import ( DatabaseClientException, IntegrityException, diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py b/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py index 4f02878f1..ddf3ddc07 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/__init__.py @@ -1,5 +1,4 @@ from .factories import ( - AiopgLockDatabaseOperationFactory, LockDatabaseOperationFactory, ) from .impl import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py index e2f0933f4..285e6f714 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py @@ -1,6 +1,3 @@ from .abc import ( LockDatabaseOperationFactory, -) -from .aiopg import ( - AiopgLockDatabaseOperationFactory, -) +) \ No newline at end of file diff --git a/packages/core/minos-microservice-common/minos/common/database/manage/__init__.py b/packages/core/minos-microservice-common/minos/common/database/manage/__init__.py index 53dca9546..442bfff30 100644 --- a/packages/core/minos-microservice-common/minos/common/database/manage/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/manage/__init__.py @@ -1,4 +1,3 @@ from .factories import ( - AiopgManageDatabaseOperationFactory, ManageDatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-common/minos/common/database/manage/factories.py b/packages/core/minos-microservice-common/minos/common/database/manage/factories.py index 7ded96715..f140af805 100644 --- a/packages/core/minos-microservice-common/minos/common/database/manage/factories.py +++ b/packages/core/minos-microservice-common/minos/common/database/manage/factories.py @@ -3,11 +3,7 @@ abstractmethod, ) -from ..clients import ( - AiopgDatabaseClient, -) from ..operations import ( - AiopgDatabaseOperation, DatabaseOperation, DatabaseOperationFactory, ) @@ -31,27 +27,3 @@ def build_delete(self, database: str) -> DatabaseOperation: :param database: The name of the database to be deleted. :return: A ``DatabaseOperation``. """ - - -# noinspection SqlNoDataSourceInspection -class AiopgManageDatabaseOperationFactory(ManageDatabaseOperationFactory): - """Aiopg Manage Database Operation Factory class.""" - - def build_create(self, database: str) -> DatabaseOperation: - """Build the database operation to create a database. - - :param database: The new database's name. - :return: A ``DatabaseOperation``. - """ - return AiopgDatabaseOperation(f"CREATE DATABASE {database};") - - def build_delete(self, database: str) -> DatabaseOperation: - """Build the database operation to create a database. - - :param database: The name of the database to be deleted. - :return: A ``DatabaseOperation``. - """ - return AiopgDatabaseOperation(f"DROP DATABASE IF EXISTS {database};") - - -AiopgDatabaseClient.register_factory(ManageDatabaseOperationFactory, AiopgManageDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py index 08f7b389c..e5521819f 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py @@ -2,7 +2,4 @@ ComposedDatabaseOperation, DatabaseOperation, DatabaseOperationFactory, -) -from .aiopg import ( - AiopgDatabaseOperation, -) +) \ No newline at end of file diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index a9f3cf4f7..baa99e521 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -24,7 +24,6 @@ Config, ) from .database import ( - AiopgDatabaseClient, DatabaseClient, DatabaseClientPool, ManageDatabaseOperationFactory, @@ -84,7 +83,9 @@ def setUp(self): super().setUp() def get_client(self) -> DatabaseClient: - return AiopgDatabaseClient.from_config(self.base_config) + default_config = self.base_config.get_default_database() + client = default_config.get("client") + return client.from_config(self.base_config) def get_config(self) -> Config: config = Config(self.get_config_file_path()) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py index e69de29bb..9208db042 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py @@ -0,0 +1,10 @@ +from .clients import ( + AiopgDatabaseClient, +) +from .factories import ( + AiopgLockDatabaseOperationFactory, + AiopgManageDatabaseOperationFactory, +) +from .operations import ( + AiopgDatabaseOperation, +) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py similarity index 98% rename from packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py index e9ffcd49f..75b233e3f 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/aiopg.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py @@ -20,17 +20,16 @@ OperationalError, ) -from ..operations import ( - AiopgDatabaseOperation, -) -from .abc import ( +from minos.common import ( DatabaseClient, -) -from .exceptions import ( IntegrityException, UnableToConnectException, ) +from .operations import ( + AiopgDatabaseOperation, +) + logger = logging.getLogger(__name__) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py new file mode 100644 index 000000000..194fc3b65 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py @@ -0,0 +1,4 @@ +from .common import ( + AiopgLockDatabaseOperationFactory, + AiopgManageDatabaseOperationFactory, +) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/__init__.py new file mode 100644 index 000000000..ec2c30084 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/__init__.py @@ -0,0 +1,6 @@ +from .locks import ( + AiopgLockDatabaseOperationFactory, +) +from .manage import ( + AiopgManageDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/locks.py similarity index 97% rename from packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/locks.py index b590a58f7..3fee1913b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/factories/aiopg.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/locks.py @@ -1,12 +1,13 @@ +from minos.common import ( + DatabaseOperation, + LockDatabaseOperationFactory, +) + from ...clients import ( AiopgDatabaseClient, ) from ...operations import ( AiopgDatabaseOperation, - DatabaseOperation, -) -from .abc import ( - LockDatabaseOperationFactory, ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/manage.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/manage.py new file mode 100644 index 000000000..995034455 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/manage.py @@ -0,0 +1,35 @@ +from minos.common import ( + DatabaseOperation, + ManageDatabaseOperationFactory, +) + +from ...clients import ( + AiopgDatabaseClient, +) +from ...operations import ( + AiopgDatabaseOperation, +) + + +# noinspection SqlNoDataSourceInspection +class AiopgManageDatabaseOperationFactory(ManageDatabaseOperationFactory): + """Aiopg Manage Database Operation Factory class.""" + + def build_create(self, database: str) -> DatabaseOperation: + """Build the database operation to create a database. + + :param database: The new database's name. + :return: A ``DatabaseOperation``. + """ + return AiopgDatabaseOperation(f"CREATE DATABASE {database};") + + def build_delete(self, database: str) -> DatabaseOperation: + """Build the database operation to create a database. + + :param database: The name of the database to be deleted. + :return: A ``DatabaseOperation``. + """ + return AiopgDatabaseOperation(f"DROP DATABASE IF EXISTS {database};") + + +AiopgDatabaseClient.register_factory(ManageDatabaseOperationFactory, AiopgManageDatabaseOperationFactory) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/operations.py similarity index 94% rename from packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/operations.py index 5126ff888..f404578f7 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/aiopg.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/operations.py @@ -7,7 +7,7 @@ Composable, ) -from .abc import ( +from minos.common import ( DatabaseOperation, ) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py similarity index 98% rename from packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py rename to packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py index 22683030f..d7080d205 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_aiopg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py @@ -16,8 +16,6 @@ ) from minos.common import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, DatabaseLock, DatabaseOperation, IntegrityException, @@ -26,13 +24,17 @@ from minos.common.testing import ( DatabaseMinosTestCase, ) +from minos.plugins.aiopg import ( + AiopgDatabaseClient, + AiopgDatabaseOperation, +) from tests.utils import ( - CommonTestCase, + AiopgTestCase, ) # noinspection SqlNoDataSourceInspection -class TestAiopgDatabaseClient(CommonTestCase, DatabaseMinosTestCase): +class TestAiopgDatabaseClient(AiopgTestCase, DatabaseMinosTestCase): def setUp(self): super().setUp() self.operation = AiopgDatabaseOperation("SELECT * FROM information_schema.tables") diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_aiopg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_operations.py similarity index 94% rename from packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_aiopg.py rename to packages/plugins/minos-database-aiopg/tests/test_aiopg/test_operations.py index 766105ac0..531fc4d52 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_aiopg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_operations.py @@ -1,9 +1,11 @@ import unittest from minos.common import ( - AiopgDatabaseOperation, DatabaseOperation, ) +from minos.plugins.aiopg import ( + AiopgDatabaseOperation, +) class TestAiopgDatabaseOperation(unittest.TestCase): diff --git a/packages/plugins/minos-database-aiopg/tests/test_config.yml b/packages/plugins/minos-database-aiopg/tests/test_config.yml index 5a44809fd..3f2398a08 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_config.yml +++ b/packages/plugins/minos-database-aiopg/tests/test_config.yml @@ -1,43 +1,9 @@ -service: - name: Order - aggregate: tests.utils.Order - services: - - minos.networks.HttpPort -routers: - - minos.networks.RestHttpRouter -services: - - tests.utils.FakeCommandService - - tests.utils.FakeQueryService -rest: - host: 0.0.0.0 - port: 7689 -repository: +version: 2 +databases: + default: + client: minos.plugins.aiopg.AiopgDatabaseClient database: order_db user: minos password: min0s host: localhost - port: 5432 -snapshot: - database: order_db - user: minos - password: min0s - host: localhost - port: 5432 -broker: - host: localhost - port: 9092 - queue: - database: order_db - user: minos - password: min0s - host: localhost - port: 5432 - records: 10 - retry: 2 -saga: - storage: - path: "./order.lmdb" -discovery: - client: minos.networks.InMemoryDiscoveryClient - host: discovery-service - port: 8080 + port: 5432 \ No newline at end of file diff --git a/packages/plugins/minos-database-aiopg/tests/utils.py b/packages/plugins/minos-database-aiopg/tests/utils.py index 4400a258b..b35cdb12d 100644 --- a/packages/plugins/minos-database-aiopg/tests/utils.py +++ b/packages/plugins/minos-database-aiopg/tests/utils.py @@ -10,6 +10,6 @@ CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" -class CommonTestCase(MinosTestCase): +class AiopgTestCase(MinosTestCase): def get_config_file_path(self) -> Path: return CONFIG_FILE_PATH From 45348cca4d5dcb294214ed719b1d62008f982f97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 8 Apr 2022 10:59:27 +0200 Subject: [PATCH 186/324] ISSUE #98 * Fix broken tests. --- .../database/locks/factories/__init__.py | 2 +- .../common/database/operations/__init__.py | 2 +- .../tests/config/v1.yml | 2 +- .../tests/config/v2.yml | 2 +- .../test_database/test_clients/test_abc.py | 12 +-- .../test_common/test_database/test_locks.py | 16 ++-- .../test_common/test_database/test_mixins.py | 49 +++++------ .../test_common/test_database/test_pools.py | 14 ++-- .../minos-microservice-common/tests/utils.py | 81 +++++++++++++++++++ 9 files changed, 128 insertions(+), 52 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py index 285e6f714..47511313b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py @@ -1,3 +1,3 @@ from .abc import ( LockDatabaseOperationFactory, -) \ No newline at end of file +) diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py index e5521819f..96a05c57c 100644 --- a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py @@ -2,4 +2,4 @@ ComposedDatabaseOperation, DatabaseOperation, DatabaseOperationFactory, -) \ No newline at end of file +) diff --git a/packages/core/minos-microservice-common/tests/config/v1.yml b/packages/core/minos-microservice-common/tests/config/v1.yml index 0b124e10c..1240496a0 100644 --- a/packages/core/minos-microservice-common/tests/config/v1.yml +++ b/packages/core/minos-microservice-common/tests/config/v1.yml @@ -19,7 +19,7 @@ service: - tests.utils.FakeSagaManager - tests.utils.FakeCustomInjection repository: - client: minos.common.AiopgDatabaseClient + client: tests.utils.FakeDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-common/tests/config/v2.yml b/packages/core/minos-microservice-common/tests/config/v2.yml index af4e8dfc9..a331350b4 100644 --- a/packages/core/minos-microservice-common/tests/config/v2.yml +++ b/packages/core/minos-microservice-common/tests/config/v2.yml @@ -6,7 +6,7 @@ serializer: client: tests.utils.FakeSerializer databases: default: - client: minos.common.AiopgDatabaseClient + client: tests.utils.FakeDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index dbbf9afa0..239025c28 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -13,7 +13,6 @@ ) from minos.common import ( - AiopgDatabaseClient, BuildableMixin, ComposedDatabaseOperation, DatabaseClient, @@ -24,6 +23,7 @@ from tests.utils import ( CommonTestCase, FakeAsyncIterator, + FakeDatabaseClient, ) @@ -159,19 +159,19 @@ def test_get_factory_raises(self): class TestDatabaseClientBuilder(CommonTestCase): def test_with_name(self): - builder = DatabaseClientBuilder(AiopgDatabaseClient).with_name("query") + builder = DatabaseClientBuilder(FakeDatabaseClient).with_name("query") self.assertEqual({"name": "query"}, builder.kwargs) def test_with_config(self): - builder = DatabaseClientBuilder(AiopgDatabaseClient).with_name("query").with_config(self.config) + builder = DatabaseClientBuilder(FakeDatabaseClient).with_name("query").with_config(self.config) self.assertEqual({"name": "query"} | self.config.get_database_by_name("query"), builder.kwargs) def test_build(self): - builder = DatabaseClientBuilder(AiopgDatabaseClient).with_name("query").with_config(self.config) + builder = DatabaseClientBuilder(FakeDatabaseClient).with_name("query").with_config(self.config) client = builder.build() - self.assertIsInstance(client, AiopgDatabaseClient) - self.assertEqual(self.config.get_database_by_name("query")["database"], client.database) + self.assertIsInstance(client, FakeDatabaseClient) + self.assertEqual(self.config.get_database_by_name("query")["database"], client.kwargs["database"]) if __name__ == "__main__": diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py index 1352a6ca3..bcdd40a6d 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py @@ -1,39 +1,35 @@ import unittest from minos.common import ( - AiopgDatabaseClient, DatabaseLock, Lock, ) -from minos.common.testing import ( - DatabaseMinosTestCase, -) from tests.utils import ( - CommonTestCase, + FakeDatabaseClient, ) -class TestDatabaseLock(CommonTestCase, DatabaseMinosTestCase): +class TestDatabaseLock(unittest.IsolatedAsyncioTestCase): def test_base(self): self.assertTrue(issubclass(DatabaseLock, Lock)) async def test_client(self): - client = AiopgDatabaseClient(**self.config.get_default_database()) + client = FakeDatabaseClient() lock = DatabaseLock(client, "foo") self.assertEqual(client, lock.client) async def test_key(self): - client = AiopgDatabaseClient(**self.config.get_default_database()) + client = FakeDatabaseClient() lock = DatabaseLock(client, "foo") self.assertEqual("foo", lock.key) async def test_key_raises(self): - client = AiopgDatabaseClient(**self.config.get_default_database()) + client = FakeDatabaseClient() with self.assertRaises(ValueError): DatabaseLock(client, []) async def test_hashed_key(self): - client = AiopgDatabaseClient(**self.config.get_default_database()) + client = FakeDatabaseClient() lock = DatabaseLock(client, "foo") self.assertEqual(hash("foo"), lock.hashed_key) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py index d41464845..dd5939ec2 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py @@ -1,9 +1,6 @@ import unittest from minos.common import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, - AiopgLockDatabaseOperationFactory, DatabaseClientPool, DatabaseMixin, LockDatabaseOperationFactory, @@ -15,6 +12,9 @@ ) from tests.utils import ( CommonTestCase, + FakeDatabaseClient, + FakeDatabaseOperation, + FakeLockDatabaseOperationFactory, ) @@ -22,6 +22,7 @@ class TestDatabaseMixin(CommonTestCase, DatabaseMinosTestCase): def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) + # noinspection PyTypeChecker database = DatabaseMixin(pool) self.assertEqual(pool, database.database_pool) @@ -42,20 +43,20 @@ async def test_pool(self): self.assertIsInstance(database.database_pool, DatabaseClientPool) async def test_operation_factory(self): - operation_factory = AiopgLockDatabaseOperationFactory() + operation_factory = FakeLockDatabaseOperationFactory() mixin = DatabaseMixin(operation_factory=operation_factory) self.assertEqual(operation_factory, mixin.operation_factory) async def test_operation_factory_from_cls_init(self): mixin = DatabaseMixin(operation_factory_cls=LockDatabaseOperationFactory) - self.assertIsInstance(mixin.operation_factory, AiopgLockDatabaseOperationFactory) + self.assertIsInstance(mixin.operation_factory, FakeLockDatabaseOperationFactory) async def test_operation_factory_from_cls_generic(self): class _DatabaseMixin(DatabaseMixin[LockDatabaseOperationFactory]): """For testing purposes.""" mixin = _DatabaseMixin() - self.assertIsInstance(mixin.operation_factory, AiopgLockDatabaseOperationFactory) + self.assertIsInstance(mixin.operation_factory, FakeLockDatabaseOperationFactory) async def test_operation_factory_none(self): mixin = DatabaseMixin() @@ -69,31 +70,31 @@ class _DatabaseMixin(DatabaseMixin[int]): _DatabaseMixin() async def test_submit_query(self): - op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);") - op2 = AiopgDatabaseOperation("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") + op1 = FakeDatabaseOperation("create_table") + op2 = FakeDatabaseOperation("check_exist", [(True,)]) async with DatabaseMixin() as database: await database.submit_query(op1) - async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + async with FakeDatabaseClient(**self.config.get_default_database()) as client: await client.execute(op2) self.assertTrue((await client.fetch_one())[0]) async def test_submit_query_locked(self): - op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);", lock=1234) - op2 = AiopgDatabaseOperation("SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'foo');") + op1 = FakeDatabaseOperation("create_table", lock=1234) + op2 = FakeDatabaseOperation("check_exist", [(True,)]) async with DatabaseMixin() as database: await database.submit_query(op1) - async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + async with FakeDatabaseClient(**self.config.get_default_database()) as client: await client.execute(op2) self.assertTrue((await client.fetch_one())[0]) async def test_submit_query_and_fetchone(self): - op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);") - op2 = AiopgDatabaseOperation("INSERT INTO foo (id) VALUES (3), (4), (5);") - op3 = AiopgDatabaseOperation("SELECT * FROM foo;") + op1 = FakeDatabaseOperation("create_table") + op2 = FakeDatabaseOperation("insert") + op3 = FakeDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: await database.submit_query(op1) @@ -104,9 +105,9 @@ async def test_submit_query_and_fetchone(self): self.assertEqual((3,), observed) async def test_submit_query_and_iter(self): - op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);") - op2 = AiopgDatabaseOperation("INSERT INTO foo (id) VALUES (3), (4), (5);") - op3 = AiopgDatabaseOperation("SELECT * FROM foo;") + op1 = FakeDatabaseOperation("create_table") + op2 = FakeDatabaseOperation("insert") + op3 = FakeDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: await database.submit_query(op1) @@ -116,9 +117,9 @@ async def test_submit_query_and_iter(self): self.assertEqual([(3,), (4,), (5,)], observed) async def test_submit_query_and_iter_streaming_mode_true(self): - op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);") - op2 = AiopgDatabaseOperation("INSERT INTO foo (id) VALUES (3), (4), (5);") - op3 = AiopgDatabaseOperation("SELECT * FROM foo;") + op1 = FakeDatabaseOperation("create_table") + op2 = FakeDatabaseOperation("insert") + op3 = FakeDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: await database.submit_query(op1) @@ -129,9 +130,9 @@ async def test_submit_query_and_iter_streaming_mode_true(self): self.assertEqual([(3,), (4,), (5,)], observed) async def test_submit_query_and_iter_locked(self): - op1 = AiopgDatabaseOperation("CREATE TABLE foo (id INT NOT NULL);", lock=1234) - op2 = AiopgDatabaseOperation("INSERT INTO foo (id) VALUES (3), (4), (5);") - op3 = AiopgDatabaseOperation("SELECT * FROM foo;") + op1 = FakeDatabaseOperation("create_table", lock=1234) + op2 = FakeDatabaseOperation("insert") + op3 = FakeDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: await database.submit_query(op1) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index e8dbb12fd..f30a9c055 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -4,14 +4,12 @@ ) from minos.common import ( - AiopgDatabaseClient, Config, DatabaseClient, DatabaseClientBuilder, DatabaseClientPool, DatabaseLock, DatabaseLockPool, - UnableToConnectException, classname, ) from minos.common.testing import ( @@ -20,6 +18,7 @@ from tests.utils import ( CONFIG_FILE_PATH, CommonTestCase, + FakeDatabaseClient, ) @@ -44,7 +43,7 @@ async def asyncTearDown(self): def test_from_config(self): pool = DatabaseClientPool.from_config(self.config, key="event") self.assertIsInstance(pool.client_builder, DatabaseClientBuilder) - self.assertEqual(AiopgDatabaseClient, pool.client_builder.instance_cls) + self.assertEqual(FakeDatabaseClient, pool.client_builder.instance_cls) def test_from_config_client_builder(self): config = Config(CONFIG_FILE_PATH, databases_default_client=classname(DatabaseClientBuilder)) @@ -72,16 +71,15 @@ async def test_acquire_multiple_same_time(self): self.assertNotEqual(c1, c2) async def test_acquire_with_reset(self): - with patch.object(AiopgDatabaseClient, "reset") as reset_mock: + with patch.object(FakeDatabaseClient, "reset") as reset_mock: async with self.pool.acquire(): self.assertEqual(0, reset_mock.call_count) self.assertEqual(1, reset_mock.call_count) async def test_acquire_with_connection_error(self): - with patch.object(AiopgDatabaseClient, "_create_connection", side_effect=(UnableToConnectException(""), None)): - with patch.object(AiopgDatabaseClient, "is_valid", return_value=True): - async with self.pool.acquire() as client: - self.assertIsInstance(client, AiopgDatabaseClient) + with patch.object(FakeDatabaseClient, "is_valid", return_value=True): + async with self.pool.acquire() as client: + self.assertIsInstance(client, FakeDatabaseClient) class TestDatabaseLockPool(CommonTestCase, DatabaseMinosTestCase): diff --git a/packages/core/minos-microservice-common/tests/utils.py b/packages/core/minos-microservice-common/tests/utils.py index d54835fe6..d62eee54f 100644 --- a/packages/core/minos-microservice-common/tests/utils.py +++ b/packages/core/minos-microservice-common/tests/utils.py @@ -1,13 +1,29 @@ +from __future__ import ( + annotations, +) + +from collections.abc import ( + AsyncIterator, + Iterable, +) from pathlib import ( Path, ) +from typing import ( + Any, + Optional, +) from minos.common import ( BuildableMixin, Builder, + DatabaseClient, + DatabaseOperation, Injectable, Lock, + LockDatabaseOperationFactory, LockPool, + ManageDatabaseOperationFactory, Port, ) from minos.common.testing import ( @@ -65,6 +81,71 @@ async def __anext__(self): raise StopAsyncIteration +class FakeDatabaseClient(DatabaseClient): + """For testing purposes""" + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self.kwargs = kwargs + self._response = tuple() + + async def _is_valid(self, **kwargs) -> bool: + """For testing purposes""" + return True + + async def _reset(self, **kwargs) -> None: + """For testing purposes""" + self._response = tuple() + + async def _execute(self, operation: FakeDatabaseOperation) -> None: + """For testing purposes""" + self._response = operation.response + + async def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: + """For testing purposes""" + for value in self._response: + yield value + + +class FakeLockDatabaseOperationFactory(LockDatabaseOperationFactory): + """For testing purposes""" + + def build_acquire(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("acquire") + + def build_release(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("release") + + +FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) + + +class FakeManageDatabaseOperationFactory(ManageDatabaseOperationFactory): + """For testing purposes""" + + def build_create(self, database: str) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("create") + + def build_delete(self, database: str) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("delete") + + +FakeDatabaseClient.register_factory(ManageDatabaseOperationFactory, FakeManageDatabaseOperationFactory) + + +class FakeDatabaseOperation(DatabaseOperation): + """For testing purposes""" + + def __init__(self, content: str, response: Optional[Iterable[Any]] = tuple(), *args, **kwargs): + super().__init__(*args, **kwargs) + self.content = content + self.response = tuple(response) + + class FakeLock(Lock): """For testing purposes.""" From 81583272c28d54b76bc1f17ddde4637cb1d39c44 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 8 Apr 2022 12:22:45 +0200 Subject: [PATCH 187/324] ISSUE #381 --- .../minos-http-aiohttp/minos/plugins/aiohttp/requests.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py index 12902ea38..8b5130320 100644 --- a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py +++ b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py @@ -90,14 +90,14 @@ def user(self) -> Optional[UUID]: return None return UUID(self.headers["user"]) - @property + @cached_property def headers(self) -> dict[str, str]: """Get the headers of the request. :return: A dictionary in which keys are ``str`` instances and values are ``str`` instances. """ # noinspection PyTypeChecker - return self.raw.headers + return self.raw.headers.copy() @property def has_content(self) -> bool: From f084a505e9033953b9884cf49f95ad934b5a6bf3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Fri, 8 Apr 2022 13:11:29 +0200 Subject: [PATCH 188/324] ISSUE #98 * Fix broken tests on `minos-microservice-networks`. --- .../minos/networks/__init__.py | 4 - .../minos/networks/brokers/__init__.py | 4 - .../networks/brokers/collections/__init__.py | 1 - .../brokers/collections/queues/__init__.py | 1 - .../collections/queues/database/__init__.py | 1 - .../queues/database/factories/__init__.py | 3 - .../networks/brokers/publishers/__init__.py | 1 - .../brokers/publishers/queued/__init__.py | 1 - .../publishers/queued/queues/__init__.py | 1 - .../publishers/queued/queues/database.py | 23 --- .../networks/brokers/subscribers/__init__.py | 2 - .../brokers/subscribers/filtered/__init__.py | 1 - .../filtered/validators/__init__.py | 1 - .../validators/duplicates/__init__.py | 1 - .../duplicates/database/__init__.py | 1 - .../duplicates/database/factories/__init__.py | 3 - .../brokers/subscribers/queued/__init__.py | 1 - .../subscribers/queued/queues/__init__.py | 1 - .../queued/queues/database/__init__.py | 1 - .../queues/database/factories/__init__.py | 3 - .../queued/queues/database/factories/abc.py | 3 + .../tests/test_config.yml | 24 +-- .../test_collections/test_queues/test_pg.py | 112 ++++++++---- .../test_queued/test_queues/test_pg.py | 12 +- .../test_duplicates/test_pg.py | 24 ++- .../test_queued/test_queues/test_pg.py | 66 ++++--- .../tests/utils.py | 170 ++++++++++++++++++ .../minos/plugins/aiopg/__init__.py | 4 + .../minos/plugins/aiopg/factories/__init__.py | 6 + .../aiopg/factories/networks/__init__.py | 10 ++ .../networks/collections/__init__.py | 3 + .../factories/networks/collections/queue.py} | 8 +- .../factories/networks/publishers/__init__.py | 3 + .../factories/networks/publishers/queue.py | 28 +++ .../networks/subscribers/__init__.py | 6 + .../factories/networks/subscribers/queue.py} | 16 +- .../networks/subscribers/validator.py} | 12 +- .../test_aiopg/test_factories/__init__.py | 0 .../test_factories/test_networks/__init__.py | 0 .../test_networks/test_publishers/__init__.py | 0 .../test_publishers/test_queues.py | 27 +++ .../test_subscribers/__init__.py | 0 .../test_subscribers/test_queues.py | 17 ++ .../minos/plugins/aiohttp/requests.py | 4 +- 44 files changed, 440 insertions(+), 170 deletions(-) create mode 100644 packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/__init__.py rename packages/{core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py => plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queue.py} (98%) create mode 100644 packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queue.py create mode 100644 packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/__init__.py rename packages/{core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py => plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queue.py} (94%) rename packages/{core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py => plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validator.py} (96%) create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py diff --git a/packages/core/minos-microservice-networks/minos/networks/__init__.py b/packages/core/minos-microservice-networks/minos/networks/__init__.py index 1058ac612..a6db44637 100644 --- a/packages/core/minos-microservice-networks/minos/networks/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/__init__.py @@ -7,10 +7,6 @@ from .brokers import ( REQUEST_HEADERS_CONTEXT_VAR, REQUEST_REPLY_TOPIC_CONTEXT_VAR, - AiopgBrokerPublisherQueueDatabaseOperationFactory, - AiopgBrokerQueueDatabaseOperationFactory, - AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, - AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerClient, BrokerClientPool, BrokerDispatcher, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py index bcf814550..0ec5e35de 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/__init__.py @@ -2,7 +2,6 @@ BrokerClient, ) from .collections import ( - AiopgBrokerQueueDatabaseOperationFactory, BrokerQueue, BrokerQueueDatabaseOperationFactory, DatabaseBrokerQueue, @@ -33,7 +32,6 @@ BrokerClientPool, ) from .publishers import ( - AiopgBrokerPublisherQueueDatabaseOperationFactory, BrokerPublisher, BrokerPublisherBuilder, BrokerPublisherQueue, @@ -44,8 +42,6 @@ QueuedBrokerPublisher, ) from .subscribers import ( - AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, - AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriber, BrokerSubscriberBuilder, BrokerSubscriberDuplicateValidator, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/__init__.py index dd2bfc375..38a6846a9 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/__init__.py @@ -1,5 +1,4 @@ from .queues import ( - AiopgBrokerQueueDatabaseOperationFactory, BrokerQueue, BrokerQueueDatabaseOperationFactory, DatabaseBrokerQueue, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py index ad54e3cde..d31afd683 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/__init__.py @@ -2,7 +2,6 @@ BrokerQueue, ) from .database import ( - AiopgBrokerQueueDatabaseOperationFactory, BrokerQueueDatabaseOperationFactory, DatabaseBrokerQueue, DatabaseBrokerQueueBuilder, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py index 2b7024161..05a61761f 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/__init__.py @@ -1,5 +1,4 @@ from .factories import ( - AiopgBrokerQueueDatabaseOperationFactory, BrokerQueueDatabaseOperationFactory, ) from .impl import ( diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py index ee7e48786..f00f6af3a 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py @@ -1,6 +1,3 @@ from .abc import ( BrokerQueueDatabaseOperationFactory, ) -from .aiopg import ( - AiopgBrokerQueueDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/__init__.py index 1c5f5166d..d3195a41f 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/__init__.py @@ -6,7 +6,6 @@ InMemoryBrokerPublisher, ) from .queued import ( - AiopgBrokerPublisherQueueDatabaseOperationFactory, BrokerPublisherQueue, BrokerPublisherQueueDatabaseOperationFactory, DatabaseBrokerPublisherQueue, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/__init__.py index 9bb141835..9f1dfd8b8 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/__init__.py @@ -2,7 +2,6 @@ QueuedBrokerPublisher, ) from .queues import ( - AiopgBrokerPublisherQueueDatabaseOperationFactory, BrokerPublisherQueue, BrokerPublisherQueueDatabaseOperationFactory, DatabaseBrokerPublisherQueue, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py index 5e544f1a3..85b9822bc 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/__init__.py @@ -2,7 +2,6 @@ BrokerPublisherQueue, ) from .database import ( - AiopgBrokerPublisherQueueDatabaseOperationFactory, BrokerPublisherQueueDatabaseOperationFactory, DatabaseBrokerPublisherQueue, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py index 339360e27..059a5e0d8 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/publishers/queued/queues/database.py @@ -7,12 +7,7 @@ ABC, ) -from minos.common import ( - AiopgDatabaseClient, -) - from ....collections import ( - AiopgBrokerQueueDatabaseOperationFactory, BrokerQueueDatabaseOperationFactory, DatabaseBrokerQueue, ) @@ -27,24 +22,6 @@ class BrokerPublisherQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationF """Broker Publisher Queue Database Operation Factory class.""" -class AiopgBrokerPublisherQueueDatabaseOperationFactory( - BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory -): - """Aiopg Broker Publisher Queue Query Factory class.""" - - def build_table_name(self) -> str: - """Get the table name. - - :return: A ``str`` value. - """ - return "broker_publisher_queue" - - -AiopgDatabaseClient.register_factory( - BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerPublisherQueueDatabaseOperationFactory -) - - class DatabaseBrokerPublisherQueue( DatabaseBrokerQueue[BrokerPublisherQueueDatabaseOperationFactory], BrokerPublisherQueue ): diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/__init__.py index 2d6b416d9..c5932b0ec 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/__init__.py @@ -3,7 +3,6 @@ BrokerSubscriberBuilder, ) from .filtered import ( - AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberDuplicateValidator, BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberValidator, @@ -17,7 +16,6 @@ InMemoryBrokerSubscriberBuilder, ) from .queued import ( - AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriberQueue, BrokerSubscriberQueueBuilder, BrokerSubscriberQueueDatabaseOperationFactory, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/__init__.py index 4878d8cf0..f9239bd89 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/__init__.py @@ -2,7 +2,6 @@ FilteredBrokerSubscriber, ) from .validators import ( - AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberDuplicateValidator, BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberValidator, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/__init__.py index 9ddb90eaf..083fb0000 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/__init__.py @@ -2,7 +2,6 @@ BrokerSubscriberValidator, ) from .duplicates import ( - AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberDuplicateValidator, BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, DatabaseBrokerSubscriberDuplicateValidator, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py index 01c3487dd..48612b056 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/__init__.py @@ -2,7 +2,6 @@ BrokerSubscriberDuplicateValidator, ) from .database import ( - AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, DatabaseBrokerSubscriberDuplicateValidator, DatabaseBrokerSubscriberDuplicateValidatorBuilder, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py index ae4271871..8cb5ceb47 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/__init__.py @@ -1,5 +1,4 @@ from .factories import ( - AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) from .impl import ( diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py index 7cdea9721..a96d4d6bc 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py @@ -1,6 +1,3 @@ from .abc import ( BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) -from .aiopg import ( - AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/__init__.py index d20f7843f..896e77c03 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/__init__.py @@ -3,7 +3,6 @@ QueuedBrokerSubscriberBuilder, ) from .queues import ( - AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriberQueue, BrokerSubscriberQueueBuilder, BrokerSubscriberQueueDatabaseOperationFactory, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py index 7a6286749..6a871e7f3 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/__init__.py @@ -3,7 +3,6 @@ BrokerSubscriberQueueBuilder, ) from .database import ( - AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriberQueueDatabaseOperationFactory, DatabaseBrokerSubscriberQueue, DatabaseBrokerSubscriberQueueBuilder, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py index 9a31cede2..d06e7c8dc 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/__init__.py @@ -1,5 +1,4 @@ from .factories import ( - AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerSubscriberQueueDatabaseOperationFactory, ) from .impl import ( diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py index 8e6078511..ec7ac9533 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py @@ -1,6 +1,3 @@ from .abc import ( BrokerSubscriberQueueDatabaseOperationFactory, ) -from .aiopg import ( - AiopgBrokerSubscriberQueueDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py index c6b9db202..7bd4c1e4f 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py @@ -1,5 +1,6 @@ from abc import ( ABC, + abstractmethod, ) from collections.abc import ( Iterable, @@ -18,6 +19,7 @@ class BrokerSubscriberQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): """Broker Subscriber Queue Database Operation Factory class.""" + @abstractmethod def build_count_not_processed( self, retry: int, @@ -30,6 +32,7 @@ def build_count_not_processed( :return: """ + @abstractmethod def build_select_not_processed( self, retry: int, diff --git a/packages/core/minos-microservice-networks/tests/test_config.yml b/packages/core/minos-microservice-networks/tests/test_config.yml index 788655ef9..ca4b4ee59 100644 --- a/packages/core/minos-microservice-networks/tests/test_config.yml +++ b/packages/core/minos-microservice-networks/tests/test_config.yml @@ -16,34 +16,12 @@ rest: host: localhost port: 8080 repository: - client: minos.common.AiopgDatabaseClient + client: tests.utils.FakeDatabaseClient database: order_db user: minos password: min0s host: localhost port: 5432 -snapshot: - client: minos.common.AiopgDatabaseClient - database: order_db - user: minos - password: min0s - host: localhost - port: 5432 -broker: - host: localhost - port: 9092 - queue: - client: minos.common.AiopgDatabaseClient - database: order_db - user: minos - password: min0s - host: localhost - port: 5432 - records: 10 - retry: 2 -saga: - storage: - path: "./order.lmdb" discovery: client: minos.networks.InMemoryDiscoveryClient host: discovery-service diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py index 7d57dbbbd..df23c2b9c 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py @@ -2,20 +2,22 @@ from asyncio import ( sleep, ) +from itertools import ( + chain, + cycle, +) from unittest.mock import ( AsyncMock, patch, ) from minos.common import ( - AiopgDatabaseClient, DatabaseMixin, ) from minos.common.testing import ( DatabaseMinosTestCase, ) from minos.networks import ( - AiopgBrokerQueueDatabaseOperationFactory, BrokerMessageV1, BrokerMessageV1Payload, BrokerQueue, @@ -23,22 +25,16 @@ ) from tests.utils import ( FakeAsyncIterator, + FakeBrokerQueueDatabaseOperationFactory, + FakeDatabaseClient, NetworksTestCase, ) -class _AiopgBrokerQueueDatabaseOperationFactory(AiopgBrokerQueueDatabaseOperationFactory): - """For testing purposes.""" - - def build_table_name(self) -> str: - """For testing purposes.""" - return "test_table" - - class TestDatabaseBrokerQueue(NetworksTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() - self.operation_factory = _AiopgBrokerQueueDatabaseOperationFactory() + self.operation_factory = FakeBrokerQueueDatabaseOperationFactory() def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerQueue, (BrokerQueue, DatabaseMixin))) @@ -58,9 +54,17 @@ async def test_operation_factory(self): async def test_enqueue(self): message = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) - async with DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) as queue: - await queue.enqueue(message) - await sleep(0.5) # To give time to consume the message from db. + with patch.object( + FakeDatabaseClient, + "fetch_all", + side_effect=chain( + [FakeAsyncIterator([(0,)]), FakeAsyncIterator([(1, message.avro_bytes)])], + cycle([FakeAsyncIterator([(0,)])]), + ), + ): + async with DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) as queue: + await queue.enqueue(message) + await sleep(0.5) # To give time to consume the message from db. async def test_aiter(self): messages = [ @@ -73,11 +77,23 @@ async def test_aiter(self): await queue.enqueue(messages[0]) await queue.enqueue(messages[1]) - observed = list() - async for message in queue: - observed.append(message) - if len(messages) == len(observed): - await queue.destroy() + with patch.object( + FakeDatabaseClient, + "fetch_all", + side_effect=chain( + [ + FakeAsyncIterator([(2,)]), + FakeAsyncIterator([(1, messages[0].avro_bytes), (2, messages[1].avro_bytes)]), + ], + cycle([FakeAsyncIterator([(0,)])]), + ), + ): + + observed = list() + async for message in queue: + observed.append(message) + if len(messages) == len(observed): + await queue.destroy() self.assertEqual(messages, observed) @@ -88,7 +104,7 @@ async def test_dequeue_with_count(self): ] with patch.object( - AiopgDatabaseClient, + FakeDatabaseClient, "fetch_all", return_value=FakeAsyncIterator([[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]]), ): @@ -105,11 +121,28 @@ async def test_dequeue_with_notify(self): BrokerMessageV1("foo", BrokerMessageV1Payload("bar")), BrokerMessageV1("bar", BrokerMessageV1Payload("foo")), ] - async with DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) as queue: - await queue.enqueue(messages[0]) - await queue.enqueue(messages[1]) - observed = [await queue.dequeue(), await queue.dequeue()] + with patch.object( + FakeDatabaseClient, + "fetch_all", + side_effect=chain( + [ + FakeAsyncIterator([(0,)]), + FakeAsyncIterator( + [ + (1, messages[0].avro_bytes), + (2, messages[1].avro_bytes), + ] + ), + ], + cycle([FakeAsyncIterator([(0,)])]), + ), + ): + async with DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) as queue: + await queue.enqueue(messages[0]) + await queue.enqueue(messages[1]) + + observed = [await queue.dequeue(), await queue.dequeue()] self.assertEqual(messages, observed) @@ -121,15 +154,28 @@ async def test_dequeue_ordered(self): BrokerMessageV1("foo", BrokerMessageV1Payload(1)), ] - async with DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) as queue: - - for message in unsorted: - await queue.enqueue(message) - - await sleep(0.5) - observed = list() - for _ in range(len(unsorted)): - observed.append(await queue.dequeue()) + with patch.object( + FakeDatabaseClient, + "fetch_all", + side_effect=chain( + [ + FakeAsyncIterator([(2,)]), + FakeAsyncIterator( + [ + (1, unsorted[0].avro_bytes), + (2, unsorted[1].avro_bytes), + (3, unsorted[2].avro_bytes), + (4, unsorted[3].avro_bytes), + ] + ), + ], + cycle([FakeAsyncIterator([(0,)])]), + ), + ): + async with DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) as queue: + observed = list() + for _ in range(len(unsorted)): + observed.append(await queue.dequeue()) expected = [unsorted[3], unsorted[1], unsorted[2], unsorted[0]] diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py index 9e28b2bfb..ea49824c0 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py @@ -4,8 +4,8 @@ DatabaseMinosTestCase, ) from minos.networks import ( - AiopgBrokerPublisherQueueDatabaseOperationFactory, BrokerPublisherQueue, + BrokerPublisherQueueDatabaseOperationFactory, DatabaseBrokerPublisherQueue, DatabaseBrokerQueue, ) @@ -21,15 +21,7 @@ def test_is_subclass(self): async def test_operation_factory(self): queue = DatabaseBrokerPublisherQueue.from_config(self.config) - self.assertIsInstance(queue.operation_factory, AiopgBrokerPublisherQueueDatabaseOperationFactory) - - -class TestAiopgBrokerPublisherQueueDatabaseOperationFactory(unittest.TestCase): - def setUp(self) -> None: - self.factory = AiopgBrokerPublisherQueueDatabaseOperationFactory() - - def test_build_table_name(self): - self.assertEqual("broker_publisher_queue", self.factory.build_table_name()) + self.assertIsInstance(queue.operation_factory, BrokerPublisherQueueDatabaseOperationFactory) if __name__ == "__main__": diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py index 7dcaaf460..bfbe9709c 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py @@ -1,16 +1,23 @@ import unittest +from unittest.mock import ( + patch, +) +from minos.common import ( + IntegrityException, +) from minos.common.testing import ( DatabaseMinosTestCase, ) from minos.networks import ( - AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerMessageV1, BrokerMessageV1Payload, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberValidator, DatabaseBrokerSubscriberDuplicateValidator, ) from tests.utils import ( + FakeDatabaseClient, NetworksTestCase, ) @@ -22,20 +29,19 @@ def test_is_subclass(self): async def test_operation_factory(self): validator = DatabaseBrokerSubscriberDuplicateValidator.from_config(self.config) - self.assertIsInstance( - validator.operation_factory, AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory - ) + self.assertIsInstance(validator.operation_factory, BrokerSubscriberDuplicateValidatorDatabaseOperationFactory) async def test_is_valid(self): one = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) two = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) three = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) - async with DatabaseBrokerSubscriberDuplicateValidator.from_config(self.config) as validator: - self.assertTrue(await validator.is_valid(one)) - self.assertTrue(await validator.is_valid(two)) - self.assertFalse(await validator.is_valid(one)) - self.assertTrue(await validator.is_valid(three)) + with patch.object(FakeDatabaseClient, "execute", side_effect=[None, None, None, IntegrityException(""), None]): + async with DatabaseBrokerSubscriberDuplicateValidator.from_config(self.config) as validator: + self.assertTrue(await validator.is_valid(one)) + self.assertTrue(await validator.is_valid(two)) + self.assertFalse(await validator.is_valid(one)) + self.assertTrue(await validator.is_valid(three)) if __name__ == "__main__": diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py index bc289ee9e..955158e94 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py @@ -2,28 +2,29 @@ from asyncio import ( sleep, ) +from itertools import ( + chain, + cycle, +) from unittest.mock import ( - AsyncMock, patch, ) -from minos.common import ( - AiopgDatabaseClient, -) from minos.common.testing import ( DatabaseMinosTestCase, ) from minos.networks import ( - AiopgBrokerSubscriberQueueDatabaseOperationFactory, BrokerMessageV1, BrokerMessageV1Payload, BrokerSubscriberQueue, + BrokerSubscriberQueueDatabaseOperationFactory, DatabaseBrokerQueue, DatabaseBrokerSubscriberQueue, DatabaseBrokerSubscriberQueueBuilder, ) from tests.utils import ( FakeAsyncIterator, + FakeDatabaseClient, NetworksTestCase, ) @@ -35,14 +36,22 @@ def test_is_subclass(self): async def test_operation_factory(self): queue = DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) - self.assertIsInstance(queue.operation_factory, AiopgBrokerSubscriberQueueDatabaseOperationFactory) + self.assertIsInstance(queue.operation_factory, BrokerSubscriberQueueDatabaseOperationFactory) async def test_enqueue(self): message = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) - async with DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: - await queue.enqueue(message) - await sleep(0.5) # To give time to consume the message from db. + with patch.object( + FakeDatabaseClient, + "fetch_all", + side_effect=chain( + [FakeAsyncIterator([(0,)]), FakeAsyncIterator([(1, message.avro_bytes)])], + cycle([FakeAsyncIterator([(0,)])]), + ), + ): + async with DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: + await queue.enqueue(message) + await sleep(0.5) # To give time to consume the message from db. async def test_dequeue_with_count(self): messages = [ @@ -51,13 +60,19 @@ async def test_dequeue_with_count(self): ] with patch.object( - AiopgDatabaseClient, + FakeDatabaseClient, "fetch_all", - return_value=FakeAsyncIterator([[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]]), + side_effect=[ + FakeAsyncIterator( + [ + [2], + ] + ), + FakeAsyncIterator([[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]]), + FakeAsyncIterator([(0,)]), + ], ): async with DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: - queue._get_count = AsyncMock(side_effect=[3, 0]) - async with queue: observed = [await queue.dequeue(), await queue.dequeue()] @@ -68,23 +83,24 @@ async def test_dequeue_with_notify(self): BrokerMessageV1("foo", BrokerMessageV1Payload("bar")), BrokerMessageV1("bar", BrokerMessageV1Payload("foo")), ] - async with DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: - await queue.enqueue(messages[0]) - await queue.enqueue(messages[1]) + with patch.object( + FakeDatabaseClient, + "fetch_all", + side_effect=[ + FakeAsyncIterator([(0,)]), + FakeAsyncIterator([(1, messages[0].avro_bytes), (3, messages[1].avro_bytes)]), + FakeAsyncIterator([(0,)]), + ], + ): + async with DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) as queue: + await queue.enqueue(messages[0]) + await queue.enqueue(messages[1]) - observed = [await queue.dequeue(), await queue.dequeue()] + observed = [await queue.dequeue(), await queue.dequeue()] self.assertEqual(messages, observed) -class TestAiopgBrokerSubscriberQueueDatabaseOperationFactory(unittest.TestCase): - def setUp(self) -> None: - self.factory = AiopgBrokerSubscriberQueueDatabaseOperationFactory() - - def test_build_table_name(self): - self.assertEqual("broker_subscriber_queue", self.factory.build_table_name()) - - class TestDatabaseBrokerSubscriberQueueBuilder(NetworksTestCase, DatabaseMinosTestCase): def test_build(self): builder = DatabaseBrokerSubscriberQueueBuilder().with_config(self.config).with_topics({"one", "two"}) diff --git a/packages/core/minos-microservice-networks/tests/utils.py b/packages/core/minos-microservice-networks/tests/utils.py index c1636a784..a2040962b 100644 --- a/packages/core/minos-microservice-networks/tests/utils.py +++ b/packages/core/minos-microservice-networks/tests/utils.py @@ -1,6 +1,14 @@ +from __future__ import ( + annotations, +) + from abc import ( ABC, ) +from collections.abc import ( + AsyncIterator, + Iterable, +) from datetime import ( timedelta, ) @@ -15,14 +23,25 @@ Callable, Optional, ) +from uuid import ( + UUID, +) from minos.common import ( + DatabaseClient, + DatabaseOperation, DeclarativeModel, + LockDatabaseOperationFactory, + ManageDatabaseOperationFactory, ) from minos.common.testing import ( MinosTestCase, ) from minos.networks import ( + BrokerPublisherQueueDatabaseOperationFactory, + BrokerQueueDatabaseOperationFactory, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + BrokerSubscriberQueueDatabaseOperationFactory, EnrouteDecorator, HttpConnector, Request, @@ -40,6 +59,157 @@ def get_config_file_path(self): return CONFIG_FILE_PATH +class FakeDatabaseClient(DatabaseClient): + """For testing purposes""" + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self.kwargs = kwargs + self._response = tuple() + + async def _is_valid(self, **kwargs) -> bool: + """For testing purposes""" + return True + + async def _reset(self, **kwargs) -> None: + """For testing purposes""" + self._response = tuple() + + async def _execute(self, operation: FakeDatabaseOperation) -> None: + """For testing purposes""" + self._response = operation.response + + async def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: + """For testing purposes""" + for value in self._response: + yield value + + +class FakeDatabaseOperation(DatabaseOperation): + """For testing purposes""" + + def __init__(self, content: str, response: Optional[Iterable[Any]] = tuple(), *args, **kwargs): + super().__init__(*args, **kwargs) + self.content = content + self.response = tuple(response) + + +class FakeLockDatabaseOperationFactory(LockDatabaseOperationFactory): + """For testing purposes""" + + def build_acquire(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("acquire") + + def build_release(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("release") + + +FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) + + +class FakeManageDatabaseOperationFactory(ManageDatabaseOperationFactory): + """For testing purposes""" + + def build_create(self, database: str) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("create") + + def build_delete(self, database: str) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("delete") + + +FakeDatabaseClient.register_factory(ManageDatabaseOperationFactory, FakeManageDatabaseOperationFactory) + + +class FakeBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory): + """For testing purposes.""" + + def build_create_table(self) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("create_queue_table") + + def build_update_not_processed(self, id_: int) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("update_not_processed") + + def build_delete_processed(self, id_: int) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("delete_processed") + + def build_mark_processing(self, ids: Iterable[int]) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("mark_processing") + + def build_count_not_processed(self, retry: int, *args, **kwargs) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("count_not_processed") + + def build_insert(self, topic: str, data: bytes) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("insert") + + def build_select_not_processed(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("select_not_processed") + + +class FakeBrokerPublisherQueueDatabaseOperationFactory( + BrokerPublisherQueueDatabaseOperationFactory, FakeBrokerQueueDatabaseOperationFactory +): + """For testing purposes""" + + +FakeDatabaseClient.register_factory( + BrokerPublisherQueueDatabaseOperationFactory, FakeBrokerPublisherQueueDatabaseOperationFactory +) + + +class FakeBrokerSubscriberQueueDatabaseOperationFactory( + BrokerSubscriberQueueDatabaseOperationFactory, FakeBrokerQueueDatabaseOperationFactory +): + """For testing purposes""" + + def build_count_not_processed( + self, retry: int, topics: Iterable[str] = tuple(), *args, **kwargs + ) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("count_not_processed") + + def build_select_not_processed( + self, retry: int, records: int, topics: Iterable[str] = tuple(), *args, **kwargs + ) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("select_not_processed") + + +FakeDatabaseClient.register_factory( + BrokerSubscriberQueueDatabaseOperationFactory, FakeBrokerSubscriberQueueDatabaseOperationFactory +) + + +class FakeBrokerSubscriberDuplicateValidatorDatabaseOperationFactory( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory +): + """For testing purposes""" + + def build_create_table(self) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("create_table") + + def build_insert_row(self, topic: str, uuid: UUID) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("insert_row") + + +FakeDatabaseClient.register_factory( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + FakeBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, +) + + @total_ordering class FakeModel(DeclarativeModel): """For testing purposes""" diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py index 9208db042..cd63547a9 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py @@ -2,6 +2,10 @@ AiopgDatabaseClient, ) from .factories import ( + AiopgBrokerPublisherQueueDatabaseOperationFactory, + AiopgBrokerQueueDatabaseOperationFactory, + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + AiopgBrokerSubscriberQueueDatabaseOperationFactory, AiopgLockDatabaseOperationFactory, AiopgManageDatabaseOperationFactory, ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py index 194fc3b65..12a5f7c87 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py @@ -2,3 +2,9 @@ AiopgLockDatabaseOperationFactory, AiopgManageDatabaseOperationFactory, ) +from .networks import ( + AiopgBrokerPublisherQueueDatabaseOperationFactory, + AiopgBrokerQueueDatabaseOperationFactory, + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + AiopgBrokerSubscriberQueueDatabaseOperationFactory, +) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/__init__.py index e69de29bb..04568ca64 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/__init__.py @@ -0,0 +1,10 @@ +from .collections import ( + AiopgBrokerQueueDatabaseOperationFactory, +) +from .publishers import ( + AiopgBrokerPublisherQueueDatabaseOperationFactory, +) +from .subscribers import ( + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + AiopgBrokerSubscriberQueueDatabaseOperationFactory, +) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/__init__.py new file mode 100644 index 000000000..b66f563c8 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/__init__.py @@ -0,0 +1,3 @@ +from .queue import ( + AiopgBrokerQueueDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queue.py similarity index 98% rename from packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queue.py index 126d370c1..135620b36 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/aiopg.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queue.py @@ -11,14 +11,16 @@ ) from minos.common import ( - AiopgDatabaseOperation, DatabaseOperation, ) - -from .abc import ( +from minos.networks import ( BrokerQueueDatabaseOperationFactory, ) +from ....clients import ( + AiopgDatabaseOperation, +) + # noinspection SqlResolve,SqlNoDataSourceInspection,SqlNoDataSourceInspection,SqlResolve class AiopgBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory, ABC): diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/__init__.py new file mode 100644 index 000000000..60a42fafa --- /dev/null +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/__init__.py @@ -0,0 +1,3 @@ +from .queue import ( + AiopgBrokerPublisherQueueDatabaseOperationFactory, +) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queue.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queue.py new file mode 100644 index 000000000..77a6dfa92 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queue.py @@ -0,0 +1,28 @@ +from minos.networks import ( + BrokerPublisherQueueDatabaseOperationFactory, +) + +from ....clients import ( + AiopgDatabaseClient, +) +from ..collections import ( + AiopgBrokerQueueDatabaseOperationFactory, +) + + +class AiopgBrokerPublisherQueueDatabaseOperationFactory( + BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory +): + """Aiopg Broker Publisher Queue Query Factory class.""" + + def build_table_name(self) -> str: + """Get the table name. + + :return: A ``str`` value. + """ + return "broker_publisher_queue" + + +AiopgDatabaseClient.register_factory( + BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerPublisherQueueDatabaseOperationFactory +) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/__init__.py new file mode 100644 index 000000000..44e93f099 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/__init__.py @@ -0,0 +1,6 @@ +from .queue import ( + AiopgBrokerSubscriberQueueDatabaseOperationFactory, +) +from .validator import ( + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queue.py similarity index 94% rename from packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queue.py index f4811179f..de335d995 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/aiopg.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queue.py @@ -7,16 +7,20 @@ ) from minos.common import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, DatabaseOperation, ) +from minos.networks import ( + BrokerSubscriberQueueDatabaseOperationFactory, +) -from ......collections import ( - AiopgBrokerQueueDatabaseOperationFactory, +from ....clients import ( + AiopgDatabaseClient, ) -from .abc import ( - BrokerSubscriberQueueDatabaseOperationFactory, +from ....operations import ( + AiopgDatabaseOperation, +) +from ..collections import ( + AiopgBrokerQueueDatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validator.py similarity index 96% rename from packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validator.py index 48dbeeadb..6890c7ff4 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/aiopg.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validator.py @@ -7,16 +7,20 @@ ) from minos.common import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, ) - -from .abc import ( +from minos.networks import ( BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) +from ....clients import ( + AiopgDatabaseClient, +) +from ....operations import ( + AiopgDatabaseOperation, +) + # noinspection SqlNoDataSourceInspection,SqlResolve class AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory( diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py new file mode 100644 index 000000000..abebe32dd --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py @@ -0,0 +1,27 @@ +import unittest + +from minos.networks import ( + BrokerPublisherQueueDatabaseOperationFactory, +) +from minos.plugins.aiopg import ( + AiopgBrokerPublisherQueueDatabaseOperationFactory, + AiopgBrokerQueueDatabaseOperationFactory, +) + + +class TestAiopgBrokerPublisherQueueDatabaseOperationFactory(unittest.TestCase): + def setUp(self) -> None: + self.factory = AiopgBrokerPublisherQueueDatabaseOperationFactory() + + def test_subclass(self): + self.assertTrue( + AiopgBrokerPublisherQueueDatabaseOperationFactory, + (BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory), + ) + + def test_build_table_name(self): + self.assertEqual("broker_publisher_queue", self.factory.build_table_name()) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py new file mode 100644 index 000000000..4ba38c918 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py @@ -0,0 +1,17 @@ +import unittest + +from minos.plugins.aiopg import ( + AiopgBrokerSubscriberQueueDatabaseOperationFactory, +) + + +class TestAiopgBrokerSubscriberQueueDatabaseOperationFactory(unittest.TestCase): + def setUp(self) -> None: + self.factory = AiopgBrokerSubscriberQueueDatabaseOperationFactory() + + def test_build_table_name(self): + self.assertEqual("broker_subscriber_queue", self.factory.build_table_name()) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py index 12902ea38..8b5130320 100644 --- a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py +++ b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py @@ -90,14 +90,14 @@ def user(self) -> Optional[UUID]: return None return UUID(self.headers["user"]) - @property + @cached_property def headers(self) -> dict[str, str]: """Get the headers of the request. :return: A dictionary in which keys are ``str`` instances and values are ``str`` instances. """ # noinspection PyTypeChecker - return self.raw.headers + return self.raw.headers.copy() @property def has_content(self) -> bool: From 5687f5d8f1b8cc8c41c3d19af06467b0b748080d Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 8 Apr 2022 14:12:40 +0200 Subject: [PATCH 189/324] ISSUE #381 --- .../minos-http-aiohttp/minos/plugins/aiohttp/requests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py index 8b5130320..4a4bf3355 100644 --- a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py +++ b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/requests.py @@ -81,7 +81,7 @@ def __eq__(self, other: AioHttpRequest) -> bool: def __repr__(self) -> str: return f"{type(self).__name__}({self.raw!r})" - @cached_property + @property def user(self) -> Optional[UUID]: """ Returns the UUID of the user making the Request. From 0177ddd58e0a4e173f1b27dcd50e414b8cee5934 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 8 Apr 2022 14:46:15 +0200 Subject: [PATCH 190/324] ISSUE #378 --- .../plugins/minos-discovery-kong/README.md | 158 +++++++++++++++++- .../minos/plugins/kong/__init__.py | 3 + .../minos/plugins/kong/client.py | 11 +- .../minos/plugins/kong/middleware.py | 35 ++++ .../tests/test_kong/test_client.py | 18 +- .../tests/test_kong/test_middleware.py | 43 +++++ .../minos-discovery-kong/tests/utils.py | 51 ++++++ 7 files changed, 305 insertions(+), 14 deletions(-) create mode 100644 packages/plugins/minos-discovery-kong/minos/plugins/kong/middleware.py create mode 100644 packages/plugins/minos-discovery-kong/tests/test_kong/test_middleware.py diff --git a/packages/plugins/minos-discovery-kong/README.md b/packages/plugins/minos-discovery-kong/README.md index f411085ea..70ffa0450 100644 --- a/packages/plugins/minos-discovery-kong/README.md +++ b/packages/plugins/minos-discovery-kong/README.md @@ -27,7 +27,6 @@ Modify `config.yml` file: ```yaml ... discovery: - connector: minos.networks.DiscoveryConnector client: minos.plugins.kong.KongDiscoveryClient host: localhost port: 8001 @@ -64,6 +63,163 @@ services: - NODE_ENV=production ``` +## Authentication + +Modify `config.yml` file. Add new middleware and modify discovery section: +```yaml +... +middleware: + ... + - minos.plugins.kong.middleware + +discovery: + client: minos.plugins.kong.KongDiscoveryClient + host: localhost + auth-type: basic-auth + port: 8001 +... +``` + +Currently, there are 2 possible types of authentication: +- `basic-auth` +- `jwt` + +For the route to be authenticated with the method specified above, a parameter called `authenticated` must be passed: +```python +class CategoryCommandService(CommandService): + @enroute.rest.command("/categories", "POST", authenticated=True, authorized_groups=["super_admin", "admin"]) + @enroute.broker.command("CreateCategory") + async def create_category(self, request: Request) -> Response: + try: + content = await request.content() + category = await Category.create(**content) + return Response(category) + except Exception: + raise ResponseException("An error occurred during category creation.") +``` + +If `authorized_groups` is also specified, this means that ACL will be enabled for that path and only users in the specified group will be allowed access. + +Example of how to create a user and add them to a group: + +```python +from minos.common import ( + NotProvidedException, + Config, + Inject, +) +from minos.cqrs import ( + CommandService, +) +from minos.networks import ( + Request, + Response, + enroute, +) +from ..aggregates import ( + Role, + User, +) +from minos.plugins.kong import KongClient + + +class UserCommandService(CommandService): + """UserCommandService class.""" + + + @enroute.rest.command("/users", "POST") + @enroute.broker.command("CreateUser") + async def create_user(self, request: Request) -> Response: + """Create a new ``User`` instance. + + :param request: The ``Request`` instance. + :return: A ``Response`` instance. + """ + content = await request.content() + + active = True + if "active" in content: + active = content["active"] + + user = User( + name=content["name"], + surname=content["surname"], + email=content["email"], + telephone=content["telephone"], + role=content["role"], + active=active, + ) + await user.save() + + kong = KongClient(self._get_kong_url()) + + consumer_raw = await kong.create_consumer(username=f"{user.name} {user.surname}", user=user.uuid, tags=[]) + consumer = consumer_raw.json() + + basic_auth = await kong.add_basic_auth_to_consumer(username=f"{user.name.lower()}_{user.surname.lower()}", + password=content["password"], consumer=consumer["id"]) + + acl = await kong.add_acl_to_consumer(role=user.role.name.lower(), consumer=consumer["id"]) + + return Response(user) + + @staticmethod + @Inject() + def _get_kong_url(config: Config) -> str: + """Get the service name.""" + if config is None: + raise NotProvidedException("The config object must be provided.") + return f"http://{config.get_by_key('discovery.host')}:{config.get_by_key('discovery.port')}" +``` + +Generate JWT example: +```python +from minos.common import ( + UUID_REGEX, + NotProvidedException, + Config, + Inject, +) +from minos.cqrs import ( + CommandService, +) +from minos.networks import ( + Request, + Response, + enroute, +) +from ..aggregates import ( + Role, + User, +) +from minos.plugins.kong import KongClient + +class UserCommandService(CommandService): + """UserCommandService class.""" + + @enroute.rest.command(f"/users/{{uuid:{UUID_REGEX.pattern}}}/jwt", "POST", authenticated=True, authorized_groups=["admin"]) + @enroute.broker.command("GetUserJWT") + async def create_user_jwt(self, request: Request) -> Response: + params = await request.params() + uuid = params["uuid"] + user = await User.get(uuid) + + if user.uuid == request.user: + kong = KongClient(self._get_kong_url()) + jwt = await kong.add_jwt_to_consumer(request.headers.get("X-Consumer-ID")) + return Response(jwt.json()) + else: + return Response(status=404) + + @staticmethod + @Inject() + def _get_kong_url(config: Config) -> str: + """Get the service name.""" + if config is None: + raise NotProvidedException("The config object must be provided.") + return f"http://{config.get_by_key('discovery.host')}:{config.get_by_key('discovery.port')}" +``` + You can get read the official docs [here](https://pantsel.github.io/konga/). ## Documentation diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index fb9f9f7b5..468460170 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -6,3 +6,6 @@ KongClient, KongDiscoveryClient, ) +from .middleware import ( + middleware, +) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index 978d56e65..39df1ebbb 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -62,7 +62,10 @@ def _from_config(cls, config: Config, **kwargs) -> KongDiscoveryClient: auth_type = kwargs["auth_type"] kwargs.pop("auth_type") else: - auth_type = config.get_by_key("discovery.auth-type") + try: + auth_type = config.get_by_key("discovery.auth-type") + except Exception: + auth_type = None return super()._from_config(config, auth_type=auth_type, **kwargs) @@ -106,7 +109,7 @@ async def subscribe( response = await self.with_circuit_breaker(fn) # send the route request resp = response.json() - if "authorized" in endpoint and self.auth_type: + if "authenticated" in endpoint and self.auth_type: if self.auth_type == "basic-auth": fn = partial(self.kong.activate_basic_auth_plugin_on_route, route_id=resp["id"]) await self.with_circuit_breaker(fn) @@ -114,9 +117,9 @@ async def subscribe( fn = partial(self.kong.activate_jwt_plugin_on_route, route_id=resp["id"]) await self.with_circuit_breaker(fn) - if "allowed_groups" in endpoint: + if "authorized_groups" in endpoint: fn = partial( - self.kong.activate_acl_plugin_on_route, route_id=resp["id"], allow=endpoint["allowed_groups"] + self.kong.activate_acl_plugin_on_route, route_id=resp["id"], allow=endpoint["authorized_groups"] ) await self.with_circuit_breaker(fn) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/middleware.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/middleware.py new file mode 100644 index 000000000..8d39005b0 --- /dev/null +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/middleware.py @@ -0,0 +1,35 @@ +from collections.abc import ( + Awaitable, + Callable, +) +from typing import ( + Optional, +) + +from minos.networks import ( + REQUEST_USER_CONTEXT_VAR, + HttpRequest, + Request, + Response, +) + + +async def middleware(request: Request, inner: Callable[[Request], Awaitable[Optional[Response]]]) -> Optional[Response]: + """Parse headers for http request and set Minos user from Kong headers. + + :param request: The request containing the data. + :param inner: The inner handling function to be executed. + :return: The response generated by the inner handling function. + """ + token = None + try: + if isinstance(request, HttpRequest): + if (user_uuid := request.headers.get("X-Consumer-Custom-ID")) is not None: + request.headers["user"] = user_uuid + token = REQUEST_USER_CONTEXT_VAR.set(user_uuid) + response = await inner(request) + finally: + if token: + REQUEST_USER_CONTEXT_VAR.reset(token) + + return response diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 436bba9a2..3ad072911 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -86,9 +86,9 @@ async def test_subscribe_with_auth(self): 5660, name, [ - {"url": "/", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, - {"url": "/foo", "method": "POST", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, - {"url": "/bar", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, ], ) self.assertTrue(201 == response.status_code) @@ -179,9 +179,9 @@ async def test_subscribe_with_auth(self): 5660, name, [ - {"url": "/", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, - {"url": "/foo", "method": "POST", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, - {"url": "/bar", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, ], ) self.assertTrue(201 == response.status_code) @@ -235,9 +235,9 @@ async def test_subscribe_with_auth(self): 5660, name, [ - {"url": "/", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, - {"url": "/foo", "method": "POST", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, - {"url": "/bar", "method": "GET", "authorized": True, "allowed_groups": ["super_admin", "admin"]}, + {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, ], ) self.assertTrue(201 == response.status_code) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_middleware.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_middleware.py new file mode 100644 index 000000000..763735276 --- /dev/null +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_middleware.py @@ -0,0 +1,43 @@ +import unittest +from collections import ( + namedtuple, +) +from uuid import ( + uuid4, +) + +from minos.networks import ( + Request, + Response, +) +from minos.plugins.kong.middleware import ( + middleware, +) +from tests.utils import ( + InMemoryHttpRequest, +) + +PROTOCOL = "http" + + +async def _fn(request: Request) -> Response: + return Response(f"{await request.content()}bar") + + +Raw = namedtuple("Raw", ["headers", "content"]) + + +class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): + async def test_middleware_no_user_headers(self): + user_uuid = uuid4() + request_headers = {"X-Consumer-Custom-ID": str(user_uuid)} + request = InMemoryHttpRequest(content="foo", headers=request_headers) + response = await middleware(request, _fn) + + self.assertEqual("foobar", await response.content()) + + self.assertEqual({"X-Consumer-Custom-ID": str(user_uuid), "user": str(user_uuid)}, request_headers) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/plugins/minos-discovery-kong/tests/utils.py b/packages/plugins/minos-discovery-kong/tests/utils.py index b7f58120f..c197d0cf0 100644 --- a/packages/plugins/minos-discovery-kong/tests/utils.py +++ b/packages/plugins/minos-discovery-kong/tests/utils.py @@ -1,8 +1,59 @@ from pathlib import ( Path, ) +from typing import ( + Any, + Optional, + Union, +) + +from minos.networks import ( + HttpRequest, + InMemoryRequest, +) BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" rand = 27 TEST_HOST = f"{rand}.{rand}.{rand}.{rand}" + + +class InMemoryHttpRequest(InMemoryRequest, HttpRequest): + """For testing purposes.""" + + def __init__( + self, + *args, + headers: Optional[dict[str, str]] = None, + **kwargs, + ): + super().__init__(*args, **kwargs) + if headers is None: + headers = dict() + self._headers = headers + + @property + def headers(self) -> dict[str, str]: + """For testing purposes.""" + return self._headers + + @property + def content_type(self) -> str: + """For testing purposes.""" + return "" + + async def url_params(self, type_: Optional[Union[type, str]] = None, **kwargs) -> Any: + """For testing purposes.""" + + @property + def has_url_params(self) -> bool: + """For testing purposes.""" + return False + + async def query_params(self, type_: Optional[Union[type, str]] = None, **kwargs) -> Any: + """For testing purposes.""" + + @property + def has_query_params(self) -> bool: + """For testing purposes.""" + return False From 6023105cf42698f215fc3ce31236a98e41c5d7b0 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Fri, 8 Apr 2022 14:57:11 +0200 Subject: [PATCH 191/324] ISSUE #378 --- .../minos-discovery-kong/pyproject.toml | 2 +- .../tests/test_config_no_auth.yml | 4 +++ .../tests/test_kong/test_client.py | 34 +++++++++++++++++++ .../minos-discovery-kong/tests/utils.py | 1 + 4 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 packages/plugins/minos-discovery-kong/tests/test_config_no_auth.yml diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index f94170c90..006bc4b05 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-kong" -version = "0.1.0a1" +version = "0.6.0" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-discovery-kong/tests/test_config_no_auth.yml b/packages/plugins/minos-discovery-kong/tests/test_config_no_auth.yml new file mode 100644 index 000000000..4ce1b78eb --- /dev/null +++ b/packages/plugins/minos-discovery-kong/tests/test_config_no_auth.yml @@ -0,0 +1,4 @@ +discovery: + client: minos.networks.InMemoryDiscoveryClient + host: localhost + port: 8001 diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 3ad072911..000e093ab 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -13,6 +13,7 @@ KongDiscoveryClient, ) from tests.utils import ( + CONFIG_FILE_NO_AUTH_PATH, CONFIG_FILE_PATH, TEST_HOST, ) @@ -252,5 +253,38 @@ async def test_subscribe_with_auth(self): self.assertEqual(PROTOCOL, response_data["protocol"]) +class TestKongDiscoveryClientFromConfigNoAuth(unittest.IsolatedAsyncioTestCase): + KONG_HOST = os.getenv("KONG_HOST", "localhost") + KONG_PORT = os.getenv("KONG_PORT", 8001) + + def setUp(self) -> None: + config = Config(CONFIG_FILE_NO_AUTH_PATH) + self.client = KongDiscoveryClient.from_config(config=config, circuit_breaker_time=0.1) + + @staticmethod + def generate_underscore_uuid(): + name = str(uuid4()) + return name.replace("-", "_") + + async def test_subscribe(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + TEST_HOST, + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual(TEST_HOST, response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + if __name__ == "__main__": unittest.main() diff --git a/packages/plugins/minos-discovery-kong/tests/utils.py b/packages/plugins/minos-discovery-kong/tests/utils.py index c197d0cf0..628218ad5 100644 --- a/packages/plugins/minos-discovery-kong/tests/utils.py +++ b/packages/plugins/minos-discovery-kong/tests/utils.py @@ -14,6 +14,7 @@ BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" +CONFIG_FILE_NO_AUTH_PATH = BASE_PATH / "test_config_no_auth.yml" rand = 27 TEST_HOST = f"{rand}.{rand}.{rand}.{rand}" From 2be00b66f619457da470f5027ee541ae62706165 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 09:27:52 +0200 Subject: [PATCH 192/324] ISSUE #98 * Migrate code from `minos-microservice-aggregate` --- .../minos/aggregate/__init__.py | 4 - .../minos/aggregate/events/__init__.py | 1 - .../aggregate/events/repositories/__init__.py | 1 - .../events/repositories/database/__init__.py | 1 - .../database/factories/__init__.py | 3 - .../minos/aggregate/snapshots/__init__.py | 2 - .../aggregate/snapshots/database/__init__.py | 2 - .../snapshots/database/factories/__init__.py | 4 - .../minos/aggregate/transactions/__init__.py | 1 - .../transactions/repositories/__init__.py | 1 - .../repositories/database/__init__.py | 1 - .../database/factories/__init__.py | 3 - .../test_events/test_repositories/test_pg.py | 10 +- .../test_snapshots/test_pg/test_abc.py | 17 +- .../test_snapshots/test_pg/test_readers.py | 1 + .../test_snapshots/test_pg/test_writers.py | 1 + .../test_repositories/test_pg.py | 10 +- .../tests/test_config.yml | 6 +- .../tests/utils.py | 228 ++++++++++++++++++ .../minos/plugins/aiopg/__init__.py | 4 + .../minos/plugins/aiopg/factories/__init__.py | 6 + .../aiopg/factories/aggregate/__init__.py | 10 + .../aiopg/factories/aggregate/events.py} | 14 +- .../aggregate/snapshots}/__init__.py | 0 .../factories/aggregate/snapshots}/impl.py | 18 +- .../factories/aggregate/snapshots}/queries.py | 13 +- .../factories/aggregate/transactions.py} | 19 +- .../test_factories/test_aggregate/__init__.py | 0 .../test_aggregate}/test_queries.py | 6 +- 29 files changed, 316 insertions(+), 71 deletions(-) rename packages/{core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py => plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py} (99%) rename packages/{core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg => plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots}/__init__.py (100%) rename packages/{core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg => plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots}/impl.py (98%) rename packages/{core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg => plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots}/queries.py (99%) rename packages/{core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py => plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py} (98%) create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/__init__.py rename packages/{core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg => plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate}/test_queries.py (99%) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index ea5b00680..e0af6e649 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -29,7 +29,6 @@ RootEntity, ) from .events import ( - AiopgEventDatabaseOperationFactory, DatabaseEventRepository, Event, EventDatabaseOperationFactory, @@ -59,8 +58,6 @@ Ordering, ) from .snapshots import ( - AiopgSnapshotDatabaseOperationFactory, - AiopgSnapshotQueryDatabaseOperationBuilder, DatabaseSnapshotReader, DatabaseSnapshotRepository, DatabaseSnapshotSetup, @@ -73,7 +70,6 @@ ) from .transactions import ( TRANSACTION_CONTEXT_VAR, - AiopgTransactionDatabaseOperationFactory, DatabaseTransactionRepository, InMemoryTransactionRepository, TransactionDatabaseOperationFactory, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py index 30785fd95..08f4df4da 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/__init__.py @@ -10,7 +10,6 @@ Event, ) from .repositories import ( - AiopgEventDatabaseOperationFactory, DatabaseEventRepository, EventDatabaseOperationFactory, EventRepository, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py index 779f5963e..d4c3e79b1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/__init__.py @@ -2,7 +2,6 @@ EventRepository, ) from .database import ( - AiopgEventDatabaseOperationFactory, DatabaseEventRepository, EventDatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py index a16590570..c37452705 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/__init__.py @@ -1,5 +1,4 @@ from .factories import ( - AiopgEventDatabaseOperationFactory, EventDatabaseOperationFactory, ) from .impl import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py index 1d69d3be1..c78f0abb4 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py @@ -1,6 +1,3 @@ from .abc import ( EventDatabaseOperationFactory, ) -from .aiopg import ( - AiopgEventDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py index 2e568ba02..065cf08dc 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py @@ -2,8 +2,6 @@ SnapshotRepository, ) from .database import ( - AiopgSnapshotDatabaseOperationFactory, - AiopgSnapshotQueryDatabaseOperationBuilder, DatabaseSnapshotReader, DatabaseSnapshotRepository, DatabaseSnapshotSetup, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py index 038c6d32c..c14f7e6ef 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py @@ -5,8 +5,6 @@ DatabaseSnapshotRepository, ) from .factories import ( - AiopgSnapshotDatabaseOperationFactory, - AiopgSnapshotQueryDatabaseOperationBuilder, SnapshotDatabaseOperationFactory, ) from .readers import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py index dd9c232cc..0ac79d093 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py @@ -1,7 +1,3 @@ from .abc import ( SnapshotDatabaseOperationFactory, ) -from .aiopg import ( - AiopgSnapshotDatabaseOperationFactory, - AiopgSnapshotQueryDatabaseOperationBuilder, -) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py index 2a2e506dd..387f13660 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/__init__.py @@ -6,7 +6,6 @@ TransactionStatus, ) from .repositories import ( - AiopgTransactionDatabaseOperationFactory, DatabaseTransactionRepository, InMemoryTransactionRepository, TransactionDatabaseOperationFactory, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py index 33907a58d..efc6c6599 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/__init__.py @@ -2,7 +2,6 @@ TransactionRepository, ) from .database import ( - AiopgTransactionDatabaseOperationFactory, DatabaseTransactionRepository, TransactionDatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py index 8c6f72e99..a418d1f39 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/__init__.py @@ -1,5 +1,4 @@ from .factories import ( - AiopgTransactionDatabaseOperationFactory, TransactionDatabaseOperationFactory, ) from .impl import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py index a7bfcb28c..c9fea61b2 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py @@ -1,6 +1,3 @@ from .abc import ( TransactionDatabaseOperationFactory, ) -from .aiopg import ( - AiopgTransactionDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py index 68618a05b..a3d61e24e 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py @@ -5,8 +5,6 @@ EventRepository, ) from minos.common import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, DatabaseClientPool, ) from minos.common.testing import ( @@ -19,6 +17,7 @@ # noinspection SqlNoDataSourceInspection +@unittest.skip class TestDatabaseEventRepositorySubmit(EventRepositorySubmitTestCase, DatabaseMinosTestCase): __test__ = True @@ -38,7 +37,11 @@ def test_from_config(self): self.assertIsInstance(repository.database_pool, DatabaseClientPool) async def test_setup(self): - async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + async with self.get_client() as client: + from minos.plugins.aiopg import ( + AiopgDatabaseOperation, + ) + operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_event');" ) @@ -47,6 +50,7 @@ async def test_setup(self): self.assertTrue(response) +@unittest.skip class TestDatabaseEventRepositorySelect(EventRepositorySelectTestCase, DatabaseMinosTestCase): __test__ = True diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py index 688d092ef..4967654e6 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py @@ -3,10 +3,6 @@ from minos.aggregate import ( DatabaseSnapshotSetup, ) -from minos.common import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, -) from minos.common.testing import ( DatabaseMinosTestCase, ) @@ -16,10 +12,15 @@ # noinspection SqlNoDataSourceInspection +@unittest.skip class TestDatabaseSnapshotSetup(AggregateTestCase, DatabaseMinosTestCase): async def test_setup_snapshot_table(self): async with DatabaseSnapshotSetup.from_config(self.config): - async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + async with self.get_client() as client: + from minos.plugins.aiopg import ( + AiopgDatabaseOperation, + ) + operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM pg_tables WHERE schemaname = 'public' AND tablename = 'snapshot');" ) @@ -29,7 +30,11 @@ async def test_setup_snapshot_table(self): async def test_setup_snapshot_aux_offset_table(self): async with DatabaseSnapshotSetup.from_config(self.config): - async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + async with self.get_client() as client: + from minos.plugins.aiopg import ( + AiopgDatabaseOperation, + ) + operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM pg_tables WHERE " "schemaname = 'public' AND tablename = 'snapshot_aux_offset');" diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py index 092aa086d..81fa4ee9c 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py @@ -33,6 +33,7 @@ ) +@unittest.skip class TestDatabaseSnapshotReader(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py index dd639b53e..2c8ed7566 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py @@ -39,6 +39,7 @@ ) +@unittest.skip class TestDatabaseSnapshotWriter(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py index c24350f48..f693d069e 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py @@ -11,8 +11,6 @@ TransactionStatus, ) from minos.common import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, DatabaseClientPool, ) from minos.common.testing import ( @@ -24,6 +22,7 @@ # noinspection SqlNoDataSourceInspection +@unittest.skip class TestDatabaseTransactionRepository(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() @@ -54,7 +53,11 @@ def test_from_config(self): self.assertIsInstance(repository.database_pool, DatabaseClientPool) async def test_setup(self): - async with AiopgDatabaseClient(**self.config.get_default_database()) as client: + async with self.get_client() as client: + from minos.plugins.aiopg import ( + AiopgDatabaseOperation, + ) + operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_transaction');" ) @@ -146,6 +149,7 @@ async def test_submit_rejected_raises(self): await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.REJECTED, 34)) +@unittest.skip class TestDatabaseTransactionRepositorySelect(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() diff --git a/packages/core/minos-microservice-aggregate/tests/test_config.yml b/packages/core/minos-microservice-aggregate/tests/test_config.yml index 17bdcc6f8..38b0f3152 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_config.yml +++ b/packages/core/minos-microservice-aggregate/tests/test_config.yml @@ -2,14 +2,14 @@ service: name: Order aggregate: tests.utils.Order repository: - client: minos.common.AiopgDatabaseClient + client: tests.utils.FakeDatabaseClient database: order_db user: minos password: min0s host: localhost port: 5432 snapshot: - client: minos.common.AiopgDatabaseClient + client: tests.utils.FakeDatabaseClient database: order_db user: minos password: min0s @@ -22,7 +22,7 @@ broker: host: localhost port: 9092 queue: - client: minos.common.AiopgDatabaseClient + client: tests.utils.FakeDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 908121875..8385ba50a 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -5,10 +5,18 @@ from abc import ( ABC, ) +from collections.abc import ( + AsyncIterator, + Iterable, +) +from datetime import ( + datetime, +) from pathlib import ( Path, ) from typing import ( + Any, Optional, ) from uuid import ( @@ -16,22 +24,35 @@ ) from minos.aggregate import ( + Action, Aggregate, Entity, EntitySet, + EventDatabaseOperationFactory, ExternalEntity, InMemoryEventRepository, InMemorySnapshotRepository, InMemoryTransactionRepository, Ref, RootEntity, + SnapshotDatabaseOperationFactory, + TransactionDatabaseOperationFactory, + TransactionStatus, ValueObject, ValueObjectSet, ) +from minos.aggregate.queries import ( + _Condition, + _Ordering, +) from minos.common import ( + DatabaseClient, DatabaseClientPool, + DatabaseOperation, Lock, + LockDatabaseOperationFactory, LockPool, + ManageDatabaseOperationFactory, PoolFactory, ) from minos.common.testing import ( @@ -77,6 +98,213 @@ def get_injections(self): ] +class FakeDatabaseClient(DatabaseClient): + """For testing purposes""" + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self.kwargs = kwargs + self._response = tuple() + + async def _is_valid(self, **kwargs) -> bool: + """For testing purposes""" + return True + + async def _reset(self, **kwargs) -> None: + """For testing purposes""" + self._response = tuple() + + async def _execute(self, operation: FakeDatabaseOperation) -> None: + """For testing purposes""" + self._response = operation.response + + async def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: + """For testing purposes""" + for value in self._response: + yield value + + +class FakeDatabaseOperation(DatabaseOperation): + """For testing purposes""" + + def __init__(self, content: str, response: Optional[Iterable[Any]] = tuple(), *args, **kwargs): + super().__init__(*args, **kwargs) + self.content = content + self.response = tuple(response) + + +class FakeLockDatabaseOperationFactory(LockDatabaseOperationFactory): + """For testing purposes""" + + def build_acquire(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("acquire") + + def build_release(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("release") + + +FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) + + +class FakeManageDatabaseOperationFactory(ManageDatabaseOperationFactory): + """For testing purposes""" + + def build_create(self, database: str) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("create") + + def build_delete(self, database: str) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("delete") + + +FakeDatabaseClient.register_factory(ManageDatabaseOperationFactory, FakeManageDatabaseOperationFactory) + + +class FakeTransactionDatabaseOperationFactory(TransactionDatabaseOperationFactory): + """For testing purposes.""" + + def build_create_table(self) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("create") + + def build_submit_row( + self, uuid: UUID, destination_uuid: UUID, status: TransactionStatus, event_offset: int + ) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("submit") + + def build_select_rows( + self, + uuid: Optional[UUID] = None, + uuid_ne: Optional[UUID] = None, + uuid_in: Optional[tuple[UUID]] = None, + destination_uuid: Optional[UUID] = None, + status: Optional[str] = None, + status_in: Optional[tuple[str]] = None, + event_offset: Optional[int] = None, + event_offset_lt: Optional[int] = None, + event_offset_gt: Optional[int] = None, + event_offset_le: Optional[int] = None, + event_offset_ge: Optional[int] = None, + updated_at: Optional[datetime] = None, + updated_at_lt: Optional[datetime] = None, + updated_at_gt: Optional[datetime] = None, + updated_at_le: Optional[datetime] = None, + updated_at_ge: Optional[datetime] = None, + **kwargs, + ) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("select") + + +FakeDatabaseClient.register_factory(TransactionDatabaseOperationFactory, FakeTransactionDatabaseOperationFactory) + + +class FakeEventDatabaseOperationFactory(EventDatabaseOperationFactory): + """For testing purposes.""" + + def build_create_table(self) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("create") + + def build_submit_row( + self, + transaction_uuids: tuple[UUID], + uuid: UUID, + action: Action, + name: str, + version: int, + data: bytes, + created_at: datetime, + transaction_uuid: UUID, + lock: Optional[int], + **kwargs, + ) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("submit") + + def build_select_rows( + self, + uuid: Optional[UUID] = None, + name: Optional[str] = None, + version: Optional[int] = None, + version_lt: Optional[int] = None, + version_gt: Optional[int] = None, + version_le: Optional[int] = None, + version_ge: Optional[int] = None, + id: Optional[int] = None, + id_lt: Optional[int] = None, + id_gt: Optional[int] = None, + id_le: Optional[int] = None, + id_ge: Optional[int] = None, + transaction_uuid: Optional[UUID] = None, + transaction_uuid_ne: Optional[UUID] = None, + transaction_uuid_in: Optional[tuple[UUID, ...]] = None, + **kwargs, + ) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("select_rows") + + def build_select_max_id(self) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("select_max_id") + + +FakeDatabaseClient.register_factory(EventDatabaseOperationFactory, FakeEventDatabaseOperationFactory) + + +class FakeSnapshotDatabaseOperationFactory(SnapshotDatabaseOperationFactory): + """For testing purposes.""" + + def build_create_table(self) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("create") + + def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("delete") + + def build_insert( + self, + uuid: UUID, + name: str, + version: int, + schema: bytes, + data: dict[str, Any], + created_at: datetime, + updated_at: datetime, + transaction_uuid: UUID, + ) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("insert") + + def build_query( + self, + name: str, + condition: _Condition, + ordering: Optional[_Ordering], + limit: Optional[int], + transaction_uuids: tuple[UUID, ...], + exclude_deleted: bool, + ) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("query") + + def build_store_offset(self, value: int) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("store_offset") + + def build_get_offset(self) -> DatabaseOperation: + """For testing purposes.""" + return FakeDatabaseOperation("get_offset") + + +FakeDatabaseClient.register_factory(SnapshotDatabaseOperationFactory, FakeSnapshotDatabaseOperationFactory) + + class FakeAsyncIterator: """For testing purposes.""" diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py index cd63547a9..2dbe97e49 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py @@ -8,6 +8,10 @@ AiopgBrokerSubscriberQueueDatabaseOperationFactory, AiopgLockDatabaseOperationFactory, AiopgManageDatabaseOperationFactory, + AiopgTransactionDatabaseOperationFactory, + AiopgSnapshotQueryDatabaseOperationBuilder, + AiopgSnapshotDatabaseOperationFactory, + AiopgEventDatabaseOperationFactory, ) from .operations import ( AiopgDatabaseOperation, diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py index 12a5f7c87..21132368f 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py @@ -1,3 +1,9 @@ +from .aggregate import ( + AiopgEventDatabaseOperationFactory, + AiopgSnapshotDatabaseOperationFactory, + AiopgSnapshotQueryDatabaseOperationBuilder, + AiopgTransactionDatabaseOperationFactory, +) from .common import ( AiopgLockDatabaseOperationFactory, AiopgManageDatabaseOperationFactory, diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/__init__.py index e69de29bb..7ab92c103 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/__init__.py @@ -0,0 +1,10 @@ +from .events import ( + AiopgEventDatabaseOperationFactory, +) +from .snapshots import ( + AiopgSnapshotDatabaseOperationFactory, + AiopgSnapshotQueryDatabaseOperationBuilder, +) +from .transactions import ( + AiopgTransactionDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py similarity index 99% rename from packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py index aaa7b1c27..15d2774ff 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/aiopg.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py @@ -19,18 +19,20 @@ Placeholder, ) +from minos.aggregate import ( + Action, + EventDatabaseOperationFactory, +) from minos.common import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, ) -from .....actions import ( - Action, +from ...clients import ( + AiopgDatabaseClient, ) -from .abc import ( - EventDatabaseOperationFactory, +from ...operations import ( + AiopgDatabaseOperation, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/__init__.py similarity index 100% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/__init__.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/__init__.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py similarity index 98% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py index 391d487f5..e3abf38d4 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/impl.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py @@ -12,19 +12,23 @@ UUID, ) +from minos.aggregate import ( + SnapshotDatabaseOperationFactory, +) +from minos.aggregate.queries import ( + _Condition, + _Ordering, +) from minos.common import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, ) -from .....queries import ( - _Condition, - _Ordering, +from ....clients import ( + AiopgDatabaseClient, ) -from ..abc import ( - SnapshotDatabaseOperationFactory, +from ....operations import ( + AiopgDatabaseOperation, ) from .queries import ( AiopgSnapshotQueryDatabaseOperationBuilder, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/queries.py similarity index 99% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/queries.py index bf65b4174..07f3fae58 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/aiopg/queries.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/queries.py @@ -22,15 +22,10 @@ Placeholder, ) -from minos.common import ( - NULL_UUID, - AvroDataEncoder, -) - -from .....contextvars import ( +from minos.aggregate import ( IS_REPOSITORY_SERIALIZATION_CONTEXT_VAR, ) -from .....queries import ( +from minos.aggregate.queries import ( _FALSE_CONDITION, _AndCondition, _ComposedCondition, @@ -50,6 +45,10 @@ _SimpleCondition, _TrueCondition, ) +from minos.common import ( + NULL_UUID, + AvroDataEncoder, +) # noinspection SqlResolve,SqlNoDataSourceInspection diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py similarity index 98% rename from packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py index c325fb9e1..3a7ac8d58 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/aiopg.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py @@ -6,28 +6,27 @@ datetime, ) from typing import ( - TYPE_CHECKING, Optional, ) from uuid import ( UUID, ) +from minos.aggregate import ( + TransactionDatabaseOperationFactory, + TransactionStatus, +) from minos.common import ( - AiopgDatabaseClient, - AiopgDatabaseOperation, ComposedDatabaseOperation, DatabaseOperation, ) -from .abc import ( - TransactionDatabaseOperationFactory, +from ...clients import ( + AiopgDatabaseClient, +) +from ...operations import ( + AiopgDatabaseOperation, ) - -if TYPE_CHECKING: - from ....entries import ( - TransactionStatus, - ) # noinspection SqlNoDataSourceInspection,SqlResolve,PyMethodMayBeStatic diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py similarity index 99% rename from packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py rename to packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py index bc3403e5b..a83ca6cc5 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_queries.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py @@ -18,13 +18,15 @@ from minos.aggregate import ( IS_REPOSITORY_SERIALIZATION_CONTEXT_VAR, - AiopgSnapshotQueryDatabaseOperationBuilder, Condition, Ordering, ) +from minos.plugins.aiopg import ( + AiopgSnapshotQueryDatabaseOperationBuilder, + AiopgDatabaseClient, +) from minos.common import ( NULL_UUID, - AiopgDatabaseClient, ) from minos.common.testing import ( DatabaseMinosTestCase, From 36dad71647aae841575b2d74960d62c93006c14e Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Mon, 11 Apr 2022 10:15:52 +0200 Subject: [PATCH 193/324] ISSUE #373 --- .../tests/test_graphql/test_decorators.py | 4 ++-- packages/plugins/minos-router-graphql/tests/utils.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py b/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py index b6dfcddbb..74cc3e8e6 100644 --- a/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py +++ b/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py @@ -49,8 +49,8 @@ def test_get_all_queries_with_kwargs(self): output=GraphQLString, authorized=True, allowed_groups=[ - "super_admin", - "admin", + "foo", + "bar", ], ) }, diff --git a/packages/plugins/minos-router-graphql/tests/utils.py b/packages/plugins/minos-router-graphql/tests/utils.py index f4f31389d..878333663 100644 --- a/packages/plugins/minos-router-graphql/tests/utils.py +++ b/packages/plugins/minos-router-graphql/tests/utils.py @@ -89,8 +89,8 @@ class FakeQueryService2: output=GraphQLString, authorized=True, allowed_groups=[ - "supèr_admin", - "admin", + "foo", + "bar", ], ) def get_order(self, request: Request): From e4a25d3d076ee0635ac5956d0c8e037a96f8b251 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 10:41:36 +0200 Subject: [PATCH 194/324] ISSUE #98 * Fix broken tests. --- .../aggregate/testing}/__init__.py | 0 .../aggregate/testing}/event_repository.py | 6 +- .../test_repositories/test_memory.py | 9 ++- .../minos/common/pools.py | 10 ++- .../minos-microservice-common/poetry.lock | 2 +- .../minos-microservice-common/pyproject.toml | 2 +- .../tests/test_config.yml | 6 +- .../minos-microservice-cqrs/tests/utils.py | 79 +++++++++++++++++++ .../plugins/minos-database-aiopg/poetry.lock | 46 ++++------- .../minos-database-aiopg/pyproject.toml | 5 +- .../tests/test_aiopg/test_clients.py | 5 +- .../test_aggregate/test_events/__init__.py | 0 .../test_aggregate/test_events}/test_pg.py | 19 ++--- .../test_aggregate/test_queries.py | 7 +- .../minos-database-aiopg/tests/utils.py | 77 +++++++++++++++++- 15 files changed, 204 insertions(+), 69 deletions(-) rename packages/core/minos-microservice-aggregate/{tests/testcases => minos/aggregate/testing}/__init__.py (100%) rename packages/core/minos-microservice-aggregate/{tests/testcases => minos/aggregate/testing}/event_repository.py (99%) create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/__init__.py rename packages/{core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories => plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events}/test_pg.py (76%) diff --git a/packages/core/minos-microservice-aggregate/tests/testcases/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py similarity index 100% rename from packages/core/minos-microservice-aggregate/tests/testcases/__init__.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py diff --git a/packages/core/minos-microservice-aggregate/tests/testcases/event_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py similarity index 99% rename from packages/core/minos-microservice-aggregate/tests/testcases/event_repository.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py index 3ff98508a..924e3d897 100644 --- a/packages/core/minos-microservice-aggregate/tests/testcases/event_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py @@ -28,12 +28,12 @@ NULL_UUID, current_datetime, ) -from tests.utils import ( - AggregateTestCase, +from minos.common.testing import ( + MinosTestCase, ) -class EventRepositoryTestCase(AggregateTestCase): +class EventRepositoryTestCase(MinosTestCase): def setUp(self) -> None: super().setUp() self.uuid = uuid4() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_memory.py index 02d1a69e3..56a54b251 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_memory.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_memory.py @@ -4,13 +4,16 @@ EventRepository, InMemoryEventRepository, ) -from tests.testcases import ( +from minos.aggregate.testing import ( EventRepositorySelectTestCase, EventRepositorySubmitTestCase, ) +from tests.utils import ( + AggregateTestCase, +) -class TestInMemoryEventRepositorySubmit(EventRepositorySubmitTestCase): +class TestInMemoryEventRepositorySubmit(AggregateTestCase, EventRepositorySubmitTestCase): __test__ = True def build_event_repository(self) -> EventRepository: @@ -18,7 +21,7 @@ def build_event_repository(self) -> EventRepository: return InMemoryEventRepository() -class TestInMemoryEventRepositorySelect(EventRepositorySelectTestCase): +class TestInMemoryEventRepositorySelect(AggregateTestCase, EventRepositorySelectTestCase): __test__ = True def build_event_repository(self) -> EventRepository: diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index c78ee6eed..9ffcce19b 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -104,12 +104,16 @@ def _get_pool_cls(self, type_: str) -> type[Pool]: return pool_cls -class Pool(SetupMixin, PoolBase, Generic[P], ABC): +class _PoolBase(PoolBase, ABC): + def __init__(self, *args, maxsize: int = 10, recycle: Optional[int] = 300, **kwargs): + super().__init__(maxsize=maxsize, recycle=recycle) + + +class Pool(SetupMixin, _PoolBase, Generic[P], ABC): """Base class for Pool implementations in minos""" def __init__(self, *args, maxsize: int = 10, recycle: Optional[int] = 300, already_setup: bool = True, **kwargs): - SetupMixin.__init__(self, *args, already_setup=already_setup, **kwargs) - PoolBase.__init__(self, maxsize=maxsize, recycle=recycle) + super().__init__(*args, maxsize=maxsize, recycle=recycle, already_setup=already_setup, **kwargs) # noinspection PyUnresolvedReferences async def __acquire(self) -> Any: # pragma: no cover diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index bf9ab3520..1701c4afb 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -391,7 +391,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "e47f8fa7cd4cd7dd0b552b168c8e7e17014c445a7941c0a0521f072daffd3a34" +content-hash = "0ffaa4f60d01f3464d7a3797d3ba04e6b1ebbaf2ae67f105cf5ba49e79521d50" [metadata.files] aiomisc = [ diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index 2d7f53c87..5f822e47f 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -31,7 +31,7 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" fastavro = "^1.4.0" orjson = "^3.5.2" lmdb = "^1.2.1" diff --git a/packages/core/minos-microservice-cqrs/tests/test_config.yml b/packages/core/minos-microservice-cqrs/tests/test_config.yml index dd7af43fc..c56d1d5c1 100644 --- a/packages/core/minos-microservice-cqrs/tests/test_config.yml +++ b/packages/core/minos-microservice-cqrs/tests/test_config.yml @@ -8,7 +8,7 @@ broker: host: localhost port: 9092 queue: - client: minos.common.AiopgDatabaseClient + client: tests.utils.FakeDatabaseClient database: order_db user: minos password: min0s @@ -17,14 +17,14 @@ broker: records: 10 retry: 2 repository: - client: minos.common.AiopgDatabaseClient + client: tests.utils.FakeDatabaseClient database: order_db user: minos password: min0s host: localhost port: 5432 snapshot: - client: minos.common.AiopgDatabaseClient + client: tests.utils.FakeDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-cqrs/tests/utils.py b/packages/core/minos-microservice-cqrs/tests/utils.py index a70c6b4cf..5ab66b6ac 100644 --- a/packages/core/minos-microservice-cqrs/tests/utils.py +++ b/packages/core/minos-microservice-cqrs/tests/utils.py @@ -2,15 +2,29 @@ annotations, ) +from collections.abc import ( + AsyncIterator, + Iterable, +) from pathlib import ( Path, ) +from typing import ( + Any, + Optional, +) from minos.aggregate import ( ExternalEntity, Ref, RootEntity, ) +from minos.common import ( + DatabaseClient, + DatabaseOperation, + LockDatabaseOperationFactory, + ManageDatabaseOperationFactory, +) from minos.cqrs import ( CommandService, QueryService, @@ -55,3 +69,68 @@ class Bar(ExternalEntity): """For testing purposes""" name: str + + +class FakeDatabaseClient(DatabaseClient): + """For testing purposes""" + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self.kwargs = kwargs + self._response = tuple() + + async def _is_valid(self, **kwargs) -> bool: + """For testing purposes""" + return True + + async def _reset(self, **kwargs) -> None: + """For testing purposes""" + self._response = tuple() + + async def _execute(self, operation: FakeDatabaseOperation) -> None: + """For testing purposes""" + self._response = operation.response + + async def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: + """For testing purposes""" + for value in self._response: + yield value + + +class FakeDatabaseOperation(DatabaseOperation): + """For testing purposes""" + + def __init__(self, content: str, response: Optional[Iterable[Any]] = tuple(), *args, **kwargs): + super().__init__(*args, **kwargs) + self.content = content + self.response = tuple(response) + + +class FakeLockDatabaseOperationFactory(LockDatabaseOperationFactory): + """For testing purposes""" + + def build_acquire(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("acquire") + + def build_release(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("release") + + +FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) + + +class FakeManageDatabaseOperationFactory(ManageDatabaseOperationFactory): + """For testing purposes""" + + def build_create(self, database: str) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("create") + + def build_delete(self, database: str) -> DatabaseOperation: + """For testing purposes""" + return FakeDatabaseOperation("delete") + + +FakeDatabaseClient.register_factory(ManageDatabaseOperationFactory, FakeManageDatabaseOperationFactory) diff --git a/packages/plugins/minos-database-aiopg/poetry.lock b/packages/plugins/minos-database-aiopg/poetry.lock index 9bc36cb30..305d0cd6c 100644 --- a/packages/plugins/minos-database-aiopg/poetry.lock +++ b/packages/plugins/minos-database-aiopg/poetry.lock @@ -1,6 +1,6 @@ [[package]] name = "aiomisc" -version = "15.8.0" +version = "15.7.3" description = "aiomisc - miscellaneous utils for asyncio" category = "main" optional = false @@ -257,7 +257,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -383,22 +383,22 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" -version = "6.2.5" +version = "7.1.1" description = "pytest: simple powerful testing with Python" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] atomicwrites = {version = ">=1.0", markers = "sys_platform == \"win32\""} @@ -408,10 +408,10 @@ iniconfig = "*" packaging = "*" pluggy = ">=0.12,<2.0" py = ">=1.8.2" -toml = "*" +tomli = ">=1.0.0" [package.extras] -testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] +testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2.7.2)", "requests", "xmlschema"] [[package]] name = "pyyaml" @@ -429,14 +429,6 @@ category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "toml" -version = "0.10.2" -description = "Python Library for Tom's Obvious, Minimal Language" -category = "dev" -optional = false -python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" - [[package]] name = "tomli" version = "2.0.1" @@ -469,12 +461,12 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "db5ca350dc51163597dccfec3324385d9ae7ff94b5a20235688061dfe6a1173c" +content-hash = "1810729aaeb2889a1550499890e0b5377ddf4f57896bdfbce6023ee2673399cb" [metadata.files] aiomisc = [ - {file = "aiomisc-15.8.0-py3-none-any.whl", hash = "sha256:4cb14333099853534b33223e8447075d00cf5a0aad36694e27b41661f5347d4a"}, - {file = "aiomisc-15.8.0.tar.gz", hash = "sha256:c8fe3699557fd362faca824ec759f1bf0c91c2d419491396e1af29203112a825"}, + {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, + {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] aiopg = [ {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, @@ -808,12 +800,12 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ - {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, - {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, + {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, + {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, ] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, @@ -854,10 +846,6 @@ six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -toml = [ - {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, - {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, -] tomli = [ {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, diff --git a/packages/plugins/minos-database-aiopg/pyproject.toml b/packages/plugins/minos-database-aiopg/pyproject.toml index 23d108002..f98dd1d25 100644 --- a/packages/plugins/minos-database-aiopg/pyproject.toml +++ b/packages/plugins/minos-database-aiopg/pyproject.toml @@ -41,10 +41,9 @@ psycopg2-binary = "^2.9.3" minos-microservice-common = { path = "../../core/minos-microservice-common", develop = true } minos-microservice-networks = { path = "../../core/minos-microservice-networks", develop = true } minos-microservice-aggregate = { path = "../../core/minos-microservice-aggregate", develop = true } - -black = "^22.1" +black = "^22.3" isort = "^5.8.0" -pytest = "^6.2.4" +pytest = "^7.0.1" coverage = "^6.3" flake8 = "^4.0.1" diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py index d7080d205..55c1568f5 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py @@ -21,9 +21,6 @@ IntegrityException, UnableToConnectException, ) -from minos.common.testing import ( - DatabaseMinosTestCase, -) from minos.plugins.aiopg import ( AiopgDatabaseClient, AiopgDatabaseOperation, @@ -34,7 +31,7 @@ # noinspection SqlNoDataSourceInspection -class TestAiopgDatabaseClient(AiopgTestCase, DatabaseMinosTestCase): +class TestAiopgDatabaseClient(AiopgTestCase): def setUp(self): super().setUp() self.operation = AiopgDatabaseOperation("SELECT * FROM information_schema.tables") diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py similarity index 76% rename from packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py rename to packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py index a3d61e24e..fa51fe481 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py @@ -7,22 +7,19 @@ from minos.common import ( DatabaseClientPool, ) -from minos.common.testing import ( - DatabaseMinosTestCase, -) -from tests.testcases import ( +from minos.aggregate.testing import ( EventRepositorySelectTestCase, EventRepositorySubmitTestCase, ) +from tests.utils import AiopgTestCase + # noinspection SqlNoDataSourceInspection -@unittest.skip -class TestDatabaseEventRepositorySubmit(EventRepositorySubmitTestCase, DatabaseMinosTestCase): +class TestDatabaseEventRepositorySubmit(AiopgTestCase, EventRepositorySubmitTestCase): __test__ = True - @staticmethod - def build_event_repository() -> EventRepository: + def build_event_repository(self) -> EventRepository: """Fort testing purposes.""" return DatabaseEventRepository() @@ -50,12 +47,10 @@ async def test_setup(self): self.assertTrue(response) -@unittest.skip -class TestDatabaseEventRepositorySelect(EventRepositorySelectTestCase, DatabaseMinosTestCase): +class TestDatabaseEventRepositorySelect(AiopgTestCase, EventRepositorySelectTestCase): __test__ = True - @staticmethod - def build_event_repository() -> EventRepository: + def build_event_repository(self) -> EventRepository: """Fort testing purposes.""" return DatabaseEventRepository() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py index a83ca6cc5..b6c49dbcb 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py @@ -28,15 +28,12 @@ from minos.common import ( NULL_UUID, ) -from minos.common.testing import ( - DatabaseMinosTestCase, -) from tests.utils import ( - AggregateTestCase, + AiopgTestCase, ) -class TestAiopgSnapshotQueryDatabaseOperationBuilder(AggregateTestCase, DatabaseMinosTestCase): +class TestAiopgSnapshotQueryDatabaseOperationBuilder(AiopgTestCase): def setUp(self) -> None: super().setUp() self.classname = "path.to.Product" diff --git a/packages/plugins/minos-database-aiopg/tests/utils.py b/packages/plugins/minos-database-aiopg/tests/utils.py index b35cdb12d..bea9c4953 100644 --- a/packages/plugins/minos-database-aiopg/tests/utils.py +++ b/packages/plugins/minos-database-aiopg/tests/utils.py @@ -2,14 +2,87 @@ Path, ) +from minos.aggregate import ( + InMemoryEventRepository, + InMemorySnapshotRepository, + InMemoryTransactionRepository, +) +from minos.common import ( + DatabaseClientPool, + Lock, + LockPool, + PoolFactory, +) from minos.common.testing import ( - MinosTestCase, + DatabaseMinosTestCase, +) +from minos.networks import ( + BrokerClientPool, + InMemoryBrokerPublisher, + InMemoryBrokerSubscriberBuilder, ) BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" -class AiopgTestCase(MinosTestCase): +class AiopgTestCase(DatabaseMinosTestCase): def get_config_file_path(self) -> Path: return CONFIG_FILE_PATH + + def get_injections(self): + pool_factory = PoolFactory.from_config( + self.config, + default_classes={ + "broker": BrokerClientPool, + "lock": FakeLockPool, + "database": DatabaseClientPool, + }, + ) + broker_publisher = InMemoryBrokerPublisher() + broker_subscriber_builder = InMemoryBrokerSubscriberBuilder() + transaction_repository = InMemoryTransactionRepository( + lock_pool=pool_factory.get_pool("lock"), + ) + event_repository = InMemoryEventRepository( + broker_publisher=broker_publisher, + transaction_repository=transaction_repository, + lock_pool=pool_factory.get_pool("lock"), + ) + snapshot_repository = InMemorySnapshotRepository( + event_repository=event_repository, + transaction_repository=transaction_repository, + ) + return [ + pool_factory, + broker_publisher, + broker_subscriber_builder, + transaction_repository, + event_repository, + snapshot_repository, + ] + + +class FakeLock(Lock): + """For testing purposes.""" + + def __init__(self, key=None, *args, **kwargs): + if key is None: + key = "fake" + super().__init__(key, *args, **kwargs) + + async def acquire(self) -> None: + """For testing purposes.""" + + async def release(self): + """For testing purposes.""" + + +class FakeLockPool(LockPool): + """For testing purposes.""" + + async def _create_instance(self): + return FakeLock() + + async def _destroy_instance(self, instance) -> None: + """For testing purposes.""" \ No newline at end of file From 7d43787c9fd7119e2892def458f6a65fecccac2c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 10:47:49 +0200 Subject: [PATCH 195/324] ISSUE #98 * Reformat code. --- .../minos/plugins/aiopg/__init__.py | 6 +++--- .../test_aggregate/test_events/test_pg.py | 11 ++++++----- .../test_factories/test_aggregate/test_queries.py | 8 ++++---- packages/plugins/minos-database-aiopg/tests/utils.py | 2 +- 4 files changed, 14 insertions(+), 13 deletions(-) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py index 2dbe97e49..03e492269 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py @@ -6,12 +6,12 @@ AiopgBrokerQueueDatabaseOperationFactory, AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, AiopgBrokerSubscriberQueueDatabaseOperationFactory, + AiopgEventDatabaseOperationFactory, AiopgLockDatabaseOperationFactory, AiopgManageDatabaseOperationFactory, - AiopgTransactionDatabaseOperationFactory, - AiopgSnapshotQueryDatabaseOperationBuilder, AiopgSnapshotDatabaseOperationFactory, - AiopgEventDatabaseOperationFactory, + AiopgSnapshotQueryDatabaseOperationBuilder, + AiopgTransactionDatabaseOperationFactory, ) from .operations import ( AiopgDatabaseOperation, diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py index fa51fe481..81d6b989e 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py @@ -4,15 +4,16 @@ DatabaseEventRepository, EventRepository, ) -from minos.common import ( - DatabaseClientPool, -) from minos.aggregate.testing import ( EventRepositorySelectTestCase, EventRepositorySubmitTestCase, ) - -from tests.utils import AiopgTestCase +from minos.common import ( + DatabaseClientPool, +) +from tests.utils import ( + AiopgTestCase, +) # noinspection SqlNoDataSourceInspection diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py index b6c49dbcb..5fa02ca31 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py @@ -21,13 +21,13 @@ Condition, Ordering, ) -from minos.plugins.aiopg import ( - AiopgSnapshotQueryDatabaseOperationBuilder, - AiopgDatabaseClient, -) from minos.common import ( NULL_UUID, ) +from minos.plugins.aiopg import ( + AiopgDatabaseClient, + AiopgSnapshotQueryDatabaseOperationBuilder, +) from tests.utils import ( AiopgTestCase, ) diff --git a/packages/plugins/minos-database-aiopg/tests/utils.py b/packages/plugins/minos-database-aiopg/tests/utils.py index bea9c4953..f3670c839 100644 --- a/packages/plugins/minos-database-aiopg/tests/utils.py +++ b/packages/plugins/minos-database-aiopg/tests/utils.py @@ -85,4 +85,4 @@ async def _create_instance(self): return FakeLock() async def _destroy_instance(self, instance) -> None: - """For testing purposes.""" \ No newline at end of file + """For testing purposes.""" From 368e9146b1e80690fb2a43d58f2be32af37b60a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 11:13:56 +0200 Subject: [PATCH 196/324] ISSUE #98 * Update GitHub Workflows. * Remove `aiopg` dependencies from core packages. --- .../workflows/minos-broker-kafka-tests.yml | 13 --- .../workflows/minos-broker-rabbitmq-tests.yml | 19 ---- .../workflows/minos-database-aiopg-tests.yml | 5 +- .../workflows/minos-http-aiohttp-tests.yml | 17 ---- .../minos-microservice-aggregate-tests.yml | 16 --- .../minos-microservice-common-tests.yml | 15 --- .../minos-microservice-cqrs-tests.yml | 16 --- .../minos-microservice-networks-tests.yml | 17 ---- .../workflows/minos-router-graphql-tests.yml | 17 ---- .../minos-microservice-aggregate/poetry.lock | 2 +- .../pyproject.toml | 1 - .../minos-microservice-common/poetry.lock | 99 +------------------ .../minos-microservice-common/pyproject.toml | 1 - .../minos-microservice-networks/poetry.lock | 2 +- .../pyproject.toml | 2 - 15 files changed, 4 insertions(+), 238 deletions(-) diff --git a/.github/workflows/minos-broker-kafka-tests.yml b/.github/workflows/minos-broker-kafka-tests.yml index 9fca0d856..0828e490c 100644 --- a/.github/workflows/minos-broker-kafka-tests.yml +++ b/.github/workflows/minos-broker-kafka-tests.yml @@ -20,16 +20,6 @@ jobs: working-directory: packages/plugins/minos-broker-kafka services: - postgres: - image: postgres - env: - POSTGRES_USER: minos - POSTGRES_PASSWORD: min0s - POSTGRES_DB: order_db - ports: - - 5432:5432 - options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 - zookeeper: image: wurstmeister/zookeeper:latest ports: @@ -44,10 +34,7 @@ jobs: KAFKA_ADVERTISED_HOST_NAME: kafka KAFKA_DELETE_TOPIC_ENABLE: "true" env: - MINOS_BROKER_QUEUE_HOST: postgres MINOS_BROKER_HOST: kafka - MINOS_REPOSITORY_HOST: postgres - MINOS_SNAPSHOT_HOST: postgres steps: - name: Check out repository code diff --git a/.github/workflows/minos-broker-rabbitmq-tests.yml b/.github/workflows/minos-broker-rabbitmq-tests.yml index 65db8140c..e20576500 100644 --- a/.github/workflows/minos-broker-rabbitmq-tests.yml +++ b/.github/workflows/minos-broker-rabbitmq-tests.yml @@ -19,27 +19,8 @@ jobs: run: working-directory: packages/plugins/minos-broker-rabbitmq - services: - postgres: - image: postgres - env: - POSTGRES_USER: minos - POSTGRES_PASSWORD: min0s - POSTGRES_DB: order_db - ports: - - 5432:5432 - options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 - - rabbitmq: - image: rabbitmq:3 - ports: - - "5672:5672" - env: - MINOS_BROKER_QUEUE_HOST: postgres MINOS_BROKER_HOST: rabbitmq - MINOS_REPOSITORY_HOST: postgres - MINOS_SNAPSHOT_HOST: postgres steps: - name: Check out repository code diff --git a/.github/workflows/minos-database-aiopg-tests.yml b/.github/workflows/minos-database-aiopg-tests.yml index 6a887234e..9dbc735cc 100644 --- a/.github/workflows/minos-database-aiopg-tests.yml +++ b/.github/workflows/minos-database-aiopg-tests.yml @@ -32,10 +32,7 @@ jobs: options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 env: - MINOS_BROKER_QUEUE_HOST: postgres - MINOS_BROKER_HOST: kafka - MINOS_REPOSITORY_HOST: postgres - MINOS_SNAPSHOT_HOST: postgres + MINOS_DATABASES_DEFAULT_HOST: postgres steps: - name: Check out repository code diff --git a/.github/workflows/minos-http-aiohttp-tests.yml b/.github/workflows/minos-http-aiohttp-tests.yml index 3d83928ae..d9a164f91 100644 --- a/.github/workflows/minos-http-aiohttp-tests.yml +++ b/.github/workflows/minos-http-aiohttp-tests.yml @@ -19,23 +19,6 @@ jobs: run: working-directory: packages/plugins/minos-http-aiohttp - services: - postgres: - image: postgres - env: - POSTGRES_USER: minos - POSTGRES_PASSWORD: min0s - POSTGRES_DB: order_db - ports: - - 5432:5432 - options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 - - env: - MINOS_BROKER_QUEUE_HOST: postgres - MINOS_BROKER_HOST: kafka - MINOS_REPOSITORY_HOST: postgres - MINOS_SNAPSHOT_HOST: postgres - steps: - name: Check out repository code uses: actions/checkout@v2 diff --git a/.github/workflows/minos-microservice-aggregate-tests.yml b/.github/workflows/minos-microservice-aggregate-tests.yml index 1c731a5dc..4b8604ea6 100644 --- a/.github/workflows/minos-microservice-aggregate-tests.yml +++ b/.github/workflows/minos-microservice-aggregate-tests.yml @@ -19,22 +19,6 @@ jobs: run: working-directory: packages/core/minos-microservice-aggregate - services: - postgres: - image: postgres - env: - POSTGRES_USER: minos - POSTGRES_PASSWORD: min0s - POSTGRES_DB: order_db - ports: - - 5432:5432 - options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 - - env: - MINOS_BROKER_QUEUE_HOST: postgres - MINOS_REPOSITORY_HOST: postgres - MINOS_SNAPSHOT_HOST: postgres - steps: - name: Check out repository code uses: actions/checkout@v2 diff --git a/.github/workflows/minos-microservice-common-tests.yml b/.github/workflows/minos-microservice-common-tests.yml index 92e2af7f5..cc89ccefb 100644 --- a/.github/workflows/minos-microservice-common-tests.yml +++ b/.github/workflows/minos-microservice-common-tests.yml @@ -17,21 +17,6 @@ jobs: run: working-directory: packages/core/minos-microservice-common - services: - postgres: - image: postgres - env: - POSTGRES_USER: minos - POSTGRES_PASSWORD: min0s - POSTGRES_DB: order_db - ports: - - 5432:5432 - options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 - - env: - MINOS_DATABASES_DEFAULT_HOST: postgres - MINOS_DATABASES_QUERY_HOST: postgres - steps: - name: Check out repository code uses: actions/checkout@v2 diff --git a/.github/workflows/minos-microservice-cqrs-tests.yml b/.github/workflows/minos-microservice-cqrs-tests.yml index dc2644ba4..1ab963a4a 100644 --- a/.github/workflows/minos-microservice-cqrs-tests.yml +++ b/.github/workflows/minos-microservice-cqrs-tests.yml @@ -20,22 +20,6 @@ jobs: run: working-directory: packages/core/minos-microservice-cqrs - services: - postgres: - image: postgres - env: - POSTGRES_USER: minos - POSTGRES_PASSWORD: min0s - POSTGRES_DB: order_db - ports: - - 5432:5432 - options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 - - env: - MINOS_BROKER_QUEUE_HOST: postgres - MINOS_REPOSITORY_HOST: postgres - MINOS_SNAPSHOT_HOST: postgres - steps: - name: Check out repository code uses: actions/checkout@v2 diff --git a/.github/workflows/minos-microservice-networks-tests.yml b/.github/workflows/minos-microservice-networks-tests.yml index 49a642b3e..5cf23e011 100644 --- a/.github/workflows/minos-microservice-networks-tests.yml +++ b/.github/workflows/minos-microservice-networks-tests.yml @@ -18,23 +18,6 @@ jobs: run: working-directory: packages/core/minos-microservice-networks - services: - postgres: - image: postgres - env: - POSTGRES_USER: minos - POSTGRES_PASSWORD: min0s - POSTGRES_DB: order_db - ports: - - 5432:5432 - options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 - - env: - MINOS_BROKER_QUEUE_HOST: postgres - MINOS_BROKER_HOST: kafka - MINOS_REPOSITORY_HOST: postgres - MINOS_SNAPSHOT_HOST: postgres - steps: - name: Check out repository code uses: actions/checkout@v2 diff --git a/.github/workflows/minos-router-graphql-tests.yml b/.github/workflows/minos-router-graphql-tests.yml index e830f4370..f36c3617b 100644 --- a/.github/workflows/minos-router-graphql-tests.yml +++ b/.github/workflows/minos-router-graphql-tests.yml @@ -19,23 +19,6 @@ jobs: run: working-directory: packages/plugins/minos-router-graphql - services: - postgres: - image: postgres - env: - POSTGRES_USER: minos - POSTGRES_PASSWORD: min0s - POSTGRES_DB: order_db - ports: - - 5432:5432 - options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 - - env: - MINOS_BROKER_QUEUE_HOST: postgres - MINOS_BROKER_HOST: kafka - MINOS_REPOSITORY_HOST: postgres - MINOS_SNAPSHOT_HOST: postgres - steps: - name: Check out repository code uses: actions/checkout@v2 diff --git a/packages/core/minos-microservice-aggregate/poetry.lock b/packages/core/minos-microservice-aggregate/poetry.lock index e234be8d7..c7c9f4ab8 100644 --- a/packages/core/minos-microservice-aggregate/poetry.lock +++ b/packages/core/minos-microservice-aggregate/poetry.lock @@ -442,7 +442,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "68b13cc914d2cf6d62d9195948eee0a89b6722bc73dfdd27f60c84c1aa0150d3" +content-hash = "e834c028de4f16ef5579578f8382fafdec7a4cb3324b70cd502049424c4af4e7" [metadata.files] aiomisc = [ diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index a50271c19..4d0991bbd 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -34,7 +34,6 @@ python = "^3.9" minos-microservice-common = "^0.6.0" minos-microservice-networks = "^0.6.0" cached-property = "^1.5.2" -psycopg2-binary = "^2.9.3" [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../minos-microservice-common", develop = true } diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index 1701c4afb..5fce0c9d2 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -19,29 +19,6 @@ develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-ti raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - -[[package]] -name = "async-timeout" -version = "4.0.2" -description = "Timeout context manager for asyncio programs" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "atomicwrites" version = "1.4.0" @@ -279,14 +256,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "py" version = "1.11.0" @@ -391,21 +360,13 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "0ffaa4f60d01f3464d7a3797d3ba04e6b1ebbaf2ae67f105cf5ba49e79521d50" +content-hash = "fa95fd5d2d8811d958396a78489d81ebc4f8945e7b4139e9e94b1d2797bb1377" [metadata.files] aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] -async-timeout = [ - {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, - {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, -] atomicwrites = [ {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, @@ -653,64 +614,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index 5f822e47f..8ad046a65 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -36,7 +36,6 @@ fastavro = "^1.4.0" orjson = "^3.5.2" lmdb = "^1.2.1" PyYAML = ">=5.4.1,<7.0.0" -aiopg = "^1.2.1" dependency-injector = "^4.32.2" cached-property = "^1.5.2" uvloop = "^0.16.0" diff --git a/packages/core/minos-microservice-networks/poetry.lock b/packages/core/minos-microservice-networks/poetry.lock index 8ff00456b..2384eef00 100644 --- a/packages/core/minos-microservice-networks/poetry.lock +++ b/packages/core/minos-microservice-networks/poetry.lock @@ -423,7 +423,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "bf50cd47a454d6e16e009014abd24654c13ee736ea523a58241b9aef4b65d8ab" +content-hash = "913262bc1dc5a9e7afdb0a527c697bc0c4495623c913108f967a21b002df4cb6" [metadata.files] aiomisc = [ diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index afabfddb7..c9a362dec 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -32,9 +32,7 @@ include = [ [tool.poetry.dependencies] python = "^3.9" minos-microservice-common = "^0.6.0" -aiopg = "^1.2.1" crontab = "^0.23.0" -psycopg2-binary = "^2.9.3" [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../minos-microservice-common", develop = true } From 71b98b9d3713cea4fdb5e649bda74b37d0e42812 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Mon, 11 Apr 2022 11:20:47 +0200 Subject: [PATCH 197/324] ISSUE #373 --- .../minos/networks/decorators/definitions/broker.py | 3 ++- .../minos/networks/decorators/definitions/periodic.py | 3 ++- .../test_decorators/test_definitions/test_abc.py | 4 ++++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/broker.py b/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/broker.py index e51f16ce8..9e158e08e 100644 --- a/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/broker.py +++ b/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/broker.py @@ -17,7 +17,8 @@ class BrokerEnrouteDecorator(EnrouteDecorator, ABC): """Broker Enroute class""" - def __init__(self, topic: str): + def __init__(self, topic: str, **kwargs): + super().__init__(**kwargs) self.topic = topic def __iter__(self) -> Iterable: diff --git a/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/periodic.py b/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/periodic.py index eca561757..fc150dd9c 100644 --- a/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/periodic.py +++ b/packages/core/minos-microservice-networks/minos/networks/decorators/definitions/periodic.py @@ -32,7 +32,8 @@ class PeriodicEnrouteDecorator(EnrouteDecorator, ABC): """Periodic Enroute class""" - def __init__(self, crontab: Union[str, CronTab, CronTabImpl]): + def __init__(self, crontab: Union[str, CronTab, CronTabImpl], **kwargs): + super().__init__(**kwargs) from ...scheduling import ( CronTab, ) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_definitions/test_abc.py b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_definitions/test_abc.py index dc228d058..f1130d95e 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_definitions/test_abc.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_definitions/test_abc.py @@ -70,6 +70,10 @@ def test_function_call(self): wrapper = self.decorator(_fn) self.assertEqual(Response("Fn"), wrapper(self.request)) + def test_kwargs(self): + self.decorator = _FakeEnrouteDecorator(foo="foo", bar="bar") + self.assertEqual({"foo": "foo", "bar": "bar"}, self.decorator.kwargs) + async def test_async_function_call(self): wrapper = self.decorator(_async_fn) self.assertEqual(Response("Async Fn: test"), await wrapper(self.request)) From 1be8a0d592ca79bb8186f79e9b50cc8c9aa8ba25 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Mon, 11 Apr 2022 11:21:17 +0200 Subject: [PATCH 198/324] ISSUE #378 --- .../plugins/minos-discovery-kong/README.md | 1 + .../minos/plugins/kong/__init__.py | 2 +- .../minos/plugins/kong/client.py | 255 +++++++++--------- .../minos/plugins/kong/discovery.py | 138 ++++++++++ .../minos/plugins/kong/kong_client.py | 137 ---------- .../tests/test_config.yml | 1 + .../tests/test_config_no_auth.yml | 1 + 7 files changed, 269 insertions(+), 266 deletions(-) create mode 100644 packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py delete mode 100644 packages/plugins/minos-discovery-kong/minos/plugins/kong/kong_client.py diff --git a/packages/plugins/minos-discovery-kong/README.md b/packages/plugins/minos-discovery-kong/README.md index 70ffa0450..82c52a039 100644 --- a/packages/plugins/minos-discovery-kong/README.md +++ b/packages/plugins/minos-discovery-kong/README.md @@ -73,6 +73,7 @@ middleware: - minos.plugins.kong.middleware discovery: + connector: minos.networks.DiscoveryConnector client: minos.plugins.kong.KongDiscoveryClient host: localhost auth-type: basic-auth diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index 468460170..b85decac2 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -2,7 +2,7 @@ __email__ = "hey@minos.run" __version__ = "0.1.0a1" -from .client import ( +from .discovery import ( KongClient, KongDiscoveryClient, ) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index 39df1ebbb..0f7f522a3 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -1,138 +1,137 @@ -from __future__ import ( - annotations, -) - -import logging -from collections.abc import ( - Iterable, -) -from functools import ( - partial, -) -from typing import ( - Optional, +from uuid import ( + UUID, ) import httpx as httpx -from minos.common import ( - CircuitBreakerMixin, - Config, -) -from minos.networks import ( - DiscoveryClient, -) - -from .kong_client import ( - KongClient, -) -from .utils import ( - Endpoint, -) -logger = logging.getLogger(__name__) +class KongClient: + """Kong Client class.""" + def __init__(self, route): + self.route = route -class KongDiscoveryClient(DiscoveryClient, CircuitBreakerMixin): - """Kong Discovery Client class.""" - - def __init__( - self, - host: Optional[str] = None, - port: Optional[int] = None, - circuit_breaker_exceptions: Iterable[type] = tuple(), - **kwargs, - ): - if host is None: - host = "localhost" - if port is None: - port = 5567 - super().__init__( - host, port, circuit_breaker_exceptions=(httpx.HTTPStatusError, *circuit_breaker_exceptions), **kwargs - ) - self.kong = KongClient(self.route) - - self.auth_type = None - if "auth_type" in kwargs: - self.auth_type = kwargs["auth_type"] - - @classmethod - def _from_config(cls, config: Config, **kwargs) -> KongDiscoveryClient: - if "auth_type" in kwargs: - auth_type = kwargs["auth_type"] - kwargs.pop("auth_type") - else: - try: - auth_type = config.get_by_key("discovery.auth-type") - except Exception: - auth_type = None - - return super()._from_config(config, auth_type=auth_type, **kwargs) - - async def subscribe( - self, host: str, port: int, name: str, endpoints: list[dict[str, str]], *args, **kwargs + @staticmethod + async def register_service( + discovery_route: str, service_name: str, microservice_host: str, microservice_port: int ) -> httpx.Response: - """Perform the subscription query. - - :param host: The ip of the microservice to be subscribed. - :param port: The port of the microservice to be subscribed. - :param name: The name of the microservice to be subscribed. - :param endpoints: List of endpoints exposed by the microservice. - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. - :return: This method does not return anything. + url = f"{discovery_route}/services" # kong url for service POST or add + data = {"name": service_name, "protocol": "http", "host": microservice_host, "port": microservice_port} + async with httpx.AsyncClient() as client: + response = await client.post(url, json=data) + return response + + @staticmethod + async def delete_service(discovery_route: str, service_name) -> httpx.Response: """ - - fnsr = partial(self.kong.register_service, self.route, name, host, port) - response_service = await self.with_circuit_breaker(fnsr) # register a service - if response_service.status_code == 409: # service already exist - # if service already exist, delete and add again - fn_delete = partial(self.kong.delete_service, self.route, name) - await self.with_circuit_breaker(fn_delete) # delete the service - fnsr = partial(self.kong.register_service, self.route, name, host, port) - response_service = await self.with_circuit_breaker(fnsr) # send the servie subscription again - - content_service = response_service.json() # get the servie information like the id - - for endpoint in endpoints: - endpointClass = Endpoint(endpoint["url"]) - - fn = partial( - self.kong.create_route, - self.route, - ["http"], - [endpoint["method"]], - [endpointClass.path_as_str], - content_service["id"], - False, - ) - response = await self.with_circuit_breaker(fn) # send the route request - resp = response.json() - - if "authenticated" in endpoint and self.auth_type: - if self.auth_type == "basic-auth": - fn = partial(self.kong.activate_basic_auth_plugin_on_route, route_id=resp["id"]) - await self.with_circuit_breaker(fn) - elif self.auth_type == "jwt": - fn = partial(self.kong.activate_jwt_plugin_on_route, route_id=resp["id"]) - await self.with_circuit_breaker(fn) - - if "authorized_groups" in endpoint: - fn = partial( - self.kong.activate_acl_plugin_on_route, route_id=resp["id"], allow=endpoint["authorized_groups"] - ) - await self.with_circuit_breaker(fn) - - return response - - async def unsubscribe(self, name: str, *args, **kwargs) -> httpx.Response: - """Perform the unsubscription query. - - :param name: The name of the microservice to be unsubscribed. - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. - :return: This method does not return anything. + the delete of a service must be checking before if the service already have the routes + if yes the DELETE routes must be called + :param discovery_route: + :param service_name: + :return: """ - fn = partial(self.kong.delete_service, self.route, name) - response = await self.with_circuit_breaker(fn) - return response + async with httpx.AsyncClient() as client: + url_get_route = f"{discovery_route}/services/{service_name}/routes" # url to get the routes + response_routes = await client.get(url_get_route) + json_routes_response = response_routes.json() + if len(json_routes_response["data"]) > 0: # service already have route, routes must be deleted + for route in json_routes_response["data"]: + url_delete_route = f"{discovery_route}/routes/{route['id']}" # url for routes delete + await client.delete(url_delete_route) + url_delete_service = f"{discovery_route}/services/{service_name}" # url for service delete + response_delete_service = await client.delete(url_delete_service) + return response_delete_service + + @staticmethod + async def create_route( + endpoint: str, + protocols: list[str], + methods: list[str], + paths: list[str], + service: str, + strip_path: bool = False, + ): + url = f"{endpoint}/routes" + payload = { + "protocols": protocols, + "methods": methods, + "paths": paths, + "service": {"id": service}, + "strip_path": strip_path, + } + + async with httpx.AsyncClient() as client: + resp = await client.post(url, json=payload) + + return resp + + async def create_consumer(self, username: str, user: UUID, tags: list[str]): + payload = {"username": username, "custom_id": str(user), "tags": tags} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/consumers", json=payload) + return resp + + async def add_basic_auth_to_consumer(self, username: str, password: str, consumer: str): + payload = { + "username": username, + "password": password, + } + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/consumers/{consumer}/basic-auth", json=payload) + + return resp + + async def add_jwt_to_consumer(self, consumer: str): + async with httpx.AsyncClient() as client: + resp = await client.post( + f"{self.route}/consumers/{consumer}/jwt", + headers={"content-type": "application/x-www-form-urlencoded"}, + ) + + return resp + + async def add_acl_to_consumer(self, role: str, consumer: str): + payload = { + "group": role, + } + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/consumers/{consumer}/acls", json=payload) + return resp + + async def activate_acl_plugin_on_service(self, service_name: str, allow: list[str]): + payload = {"name": "acl", "config": {"allow": allow}} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/services/{service_name}/plugins", json=payload) + return resp + + async def activate_acl_plugin_on_route(self, route_id: str, allow: list[str]): + payload = {"name": "acl", "config": {"allow": allow}} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) + return resp + + async def activate_basic_auth_plugin_on_service(self, service_name: str): + payload = {"name": "basic-auth", "config": {"hide_credentials": False}} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/services/{service_name}/plugins", json=payload) + return resp + + async def activate_basic_auth_plugin_on_route(self, route_id: str): + payload = {"name": "basic-auth", "config": {"hide_credentials": False}} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) + return resp + + async def activate_jwt_plugin_on_route(self, route_id: str): + payload = {"name": "jwt", "config": {"secret_is_base64": False, "run_on_preflight": True}} + + async with httpx.AsyncClient() as client: + resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) + return resp diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py new file mode 100644 index 000000000..330b2c5b0 --- /dev/null +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py @@ -0,0 +1,138 @@ +from __future__ import ( + annotations, +) + +import logging +from collections.abc import ( + Iterable, +) +from functools import ( + partial, +) +from typing import ( + Optional, +) + +import httpx as httpx + +from minos.common import ( + CircuitBreakerMixin, + Config, +) +from minos.networks import ( + DiscoveryClient, +) + +from .client import ( + KongClient, +) +from .utils import ( + Endpoint, +) + +logger = logging.getLogger(__name__) + + +class KongDiscoveryClient(DiscoveryClient, CircuitBreakerMixin): + """Kong Discovery Client class.""" + + def __init__( + self, + host: Optional[str] = None, + port: Optional[int] = None, + circuit_breaker_exceptions: Iterable[type] = tuple(), + **kwargs, + ): + if host is None: + host = "localhost" + if port is None: + port = 5567 + super().__init__( + host, port, circuit_breaker_exceptions=(httpx.HTTPStatusError, *circuit_breaker_exceptions), **kwargs + ) + self.kong = KongClient(self.route) + + self.auth_type = None + if "auth_type" in kwargs: + self.auth_type = kwargs["auth_type"] + + @classmethod + def _from_config(cls, config: Config, **kwargs) -> KongDiscoveryClient: + if "auth_type" in kwargs: + auth_type = kwargs["auth_type"] + kwargs.pop("auth_type") + else: + try: + auth_type = config.get_by_key("discovery.auth-type") + except Exception: + auth_type = None + + return super()._from_config(config, auth_type=auth_type, **kwargs) + + async def subscribe( + self, host: str, port: int, name: str, endpoints: list[dict[str, str]], *args, **kwargs + ) -> httpx.Response: + """Perform the subscription query. + + :param host: The ip of the microservice to be subscribed. + :param port: The port of the microservice to be subscribed. + :param name: The name of the microservice to be subscribed. + :param endpoints: List of endpoints exposed by the microservice. + :param args: Additional positional arguments. + :param kwargs: Additional named arguments. + :return: This method does not return anything. + """ + + fnsr = partial(self.kong.register_service, self.route, name, host, port) + response_service = await self.with_circuit_breaker(fnsr) # register a service + if response_service.status_code == 409: # service already exist + # if service already exist, delete and add again + fn_delete = partial(self.kong.delete_service, self.route, name) + await self.with_circuit_breaker(fn_delete) # delete the service + fnsr = partial(self.kong.register_service, self.route, name, host, port) + response_service = await self.with_circuit_breaker(fnsr) # send the servie subscription again + + content_service = response_service.json() # get the servie information like the id + + for endpoint in endpoints: + endpointClass = Endpoint(endpoint["url"]) + + fn = partial( + self.kong.create_route, + self.route, + ["http"], + [endpoint["method"]], + [endpointClass.path_as_str], + content_service["id"], + False, + ) + response = await self.with_circuit_breaker(fn) # send the route request + resp = response.json() + + if "authenticated" in endpoint and self.auth_type: + if self.auth_type == "basic-auth": + fn = partial(self.kong.activate_basic_auth_plugin_on_route, route_id=resp["id"]) + await self.with_circuit_breaker(fn) + elif self.auth_type == "jwt": + fn = partial(self.kong.activate_jwt_plugin_on_route, route_id=resp["id"]) + await self.with_circuit_breaker(fn) + + if "authorized_groups" in endpoint: + fn = partial( + self.kong.activate_acl_plugin_on_route, route_id=resp["id"], allow=endpoint["authorized_groups"] + ) + await self.with_circuit_breaker(fn) + + return response + + async def unsubscribe(self, name: str, *args, **kwargs) -> httpx.Response: + """Perform the unsubscription query. + + :param name: The name of the microservice to be unsubscribed. + :param args: Additional positional arguments. + :param kwargs: Additional named arguments. + :return: This method does not return anything. + """ + fn = partial(self.kong.delete_service, self.route, name) + response = await self.with_circuit_breaker(fn) + return response diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/kong_client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/kong_client.py deleted file mode 100644 index 0f7f522a3..000000000 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/kong_client.py +++ /dev/null @@ -1,137 +0,0 @@ -from uuid import ( - UUID, -) - -import httpx as httpx - - -class KongClient: - """Kong Client class.""" - - def __init__(self, route): - self.route = route - - @staticmethod - async def register_service( - discovery_route: str, service_name: str, microservice_host: str, microservice_port: int - ) -> httpx.Response: - url = f"{discovery_route}/services" # kong url for service POST or add - data = {"name": service_name, "protocol": "http", "host": microservice_host, "port": microservice_port} - async with httpx.AsyncClient() as client: - response = await client.post(url, json=data) - return response - - @staticmethod - async def delete_service(discovery_route: str, service_name) -> httpx.Response: - """ - the delete of a service must be checking before if the service already have the routes - if yes the DELETE routes must be called - :param discovery_route: - :param service_name: - :return: - """ - async with httpx.AsyncClient() as client: - url_get_route = f"{discovery_route}/services/{service_name}/routes" # url to get the routes - response_routes = await client.get(url_get_route) - json_routes_response = response_routes.json() - if len(json_routes_response["data"]) > 0: # service already have route, routes must be deleted - for route in json_routes_response["data"]: - url_delete_route = f"{discovery_route}/routes/{route['id']}" # url for routes delete - await client.delete(url_delete_route) - url_delete_service = f"{discovery_route}/services/{service_name}" # url for service delete - response_delete_service = await client.delete(url_delete_service) - return response_delete_service - - @staticmethod - async def create_route( - endpoint: str, - protocols: list[str], - methods: list[str], - paths: list[str], - service: str, - strip_path: bool = False, - ): - url = f"{endpoint}/routes" - payload = { - "protocols": protocols, - "methods": methods, - "paths": paths, - "service": {"id": service}, - "strip_path": strip_path, - } - - async with httpx.AsyncClient() as client: - resp = await client.post(url, json=payload) - - return resp - - async def create_consumer(self, username: str, user: UUID, tags: list[str]): - payload = {"username": username, "custom_id": str(user), "tags": tags} - - async with httpx.AsyncClient() as client: - resp = await client.post(f"{self.route}/consumers", json=payload) - return resp - - async def add_basic_auth_to_consumer(self, username: str, password: str, consumer: str): - payload = { - "username": username, - "password": password, - } - - async with httpx.AsyncClient() as client: - resp = await client.post(f"{self.route}/consumers/{consumer}/basic-auth", json=payload) - - return resp - - async def add_jwt_to_consumer(self, consumer: str): - async with httpx.AsyncClient() as client: - resp = await client.post( - f"{self.route}/consumers/{consumer}/jwt", - headers={"content-type": "application/x-www-form-urlencoded"}, - ) - - return resp - - async def add_acl_to_consumer(self, role: str, consumer: str): - payload = { - "group": role, - } - - async with httpx.AsyncClient() as client: - resp = await client.post(f"{self.route}/consumers/{consumer}/acls", json=payload) - return resp - - async def activate_acl_plugin_on_service(self, service_name: str, allow: list[str]): - payload = {"name": "acl", "config": {"allow": allow}} - - async with httpx.AsyncClient() as client: - resp = await client.post(f"{self.route}/services/{service_name}/plugins", json=payload) - return resp - - async def activate_acl_plugin_on_route(self, route_id: str, allow: list[str]): - payload = {"name": "acl", "config": {"allow": allow}} - - async with httpx.AsyncClient() as client: - resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) - return resp - - async def activate_basic_auth_plugin_on_service(self, service_name: str): - payload = {"name": "basic-auth", "config": {"hide_credentials": False}} - - async with httpx.AsyncClient() as client: - resp = await client.post(f"{self.route}/services/{service_name}/plugins", json=payload) - return resp - - async def activate_basic_auth_plugin_on_route(self, route_id: str): - payload = {"name": "basic-auth", "config": {"hide_credentials": False}} - - async with httpx.AsyncClient() as client: - resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) - return resp - - async def activate_jwt_plugin_on_route(self, route_id: str): - payload = {"name": "jwt", "config": {"secret_is_base64": False, "run_on_preflight": True}} - - async with httpx.AsyncClient() as client: - resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) - return resp diff --git a/packages/plugins/minos-discovery-kong/tests/test_config.yml b/packages/plugins/minos-discovery-kong/tests/test_config.yml index 5717a6327..2a18cf385 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_config.yml +++ b/packages/plugins/minos-discovery-kong/tests/test_config.yml @@ -1,4 +1,5 @@ discovery: + connector: minos.networks.DiscoveryConnector client: minos.networks.InMemoryDiscoveryClient auth-type: jwt host: localhost diff --git a/packages/plugins/minos-discovery-kong/tests/test_config_no_auth.yml b/packages/plugins/minos-discovery-kong/tests/test_config_no_auth.yml index 4ce1b78eb..4958f9f90 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_config_no_auth.yml +++ b/packages/plugins/minos-discovery-kong/tests/test_config_no_auth.yml @@ -1,4 +1,5 @@ discovery: + connector: minos.networks.DiscoveryConnector client: minos.networks.InMemoryDiscoveryClient host: localhost port: 8001 From 049ade00d4675b902bfeb6399162ab500261e245 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 11:38:42 +0200 Subject: [PATCH 199/324] ISSUE #98 * Add transaction test cases. --- .../minos/aggregate/testing/__init__.py | 5 + .../testing/transaction_repository.py} | 94 +++---- .../test_repositories/test_memory.py | 251 +----------------- .../test_transactions/__init__.py | 0 .../test_transactions/test_pg.py | 56 ++++ 5 files changed, 108 insertions(+), 298 deletions(-) rename packages/core/minos-microservice-aggregate/{tests/test_aggregate/test_transactions/test_repositories/test_pg.py => minos/aggregate/testing/transaction_repository.py} (87%) create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py index ed0100614..6170eef89 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py @@ -3,3 +3,8 @@ EventRepositorySubmitTestCase, EventRepositoryTestCase, ) +from .transaction_repository import ( + TransactionRepositorySelectTestCase, + TransactionRepositorySubmitTestCase, + TransactionRepositoryTestCase, +) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py similarity index 87% rename from packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py index f693d069e..65a1bcfb8 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_pg.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py @@ -1,69 +1,55 @@ -import unittest +from abc import ( + ABC, + abstractmethod, +) from uuid import ( uuid4, ) from minos.aggregate import ( - DatabaseTransactionRepository, + InMemoryTransactionRepository, TransactionEntry, TransactionRepository, TransactionRepositoryConflictException, TransactionStatus, ) -from minos.common import ( - DatabaseClientPool, -) from minos.common.testing import ( - DatabaseMinosTestCase, -) -from tests.utils import ( - AggregateTestCase, + MinosTestCase, ) -# noinspection SqlNoDataSourceInspection -@unittest.skip -class TestDatabaseTransactionRepository(AggregateTestCase, DatabaseMinosTestCase): +class TransactionRepositoryTestCase(MinosTestCase): def setUp(self) -> None: super().setUp() - - self.transaction_repository = DatabaseTransactionRepository() - self.uuid = uuid4() - async def asyncSetUp(self) -> None: + self.transaction_repository = self.build_transaction_repository() + + async def asyncSetUp(self): await super().asyncSetUp() await self.transaction_repository.setup() - async def asyncTearDown(self) -> None: + async def asyncTearDown(self): await self.transaction_repository.destroy() await super().asyncTearDown() - async def test_subclass(self) -> None: - self.assertTrue(issubclass(DatabaseTransactionRepository, TransactionRepository)) - - def test_constructor(self): - pool = DatabaseClientPool.from_config(self.config) - repository = DatabaseTransactionRepository(pool) - self.assertIsInstance(repository, DatabaseTransactionRepository) - self.assertEqual(pool, repository.database_pool) - - def test_from_config(self): - repository = DatabaseTransactionRepository.from_config(self.config) - self.assertIsInstance(repository.database_pool, DatabaseClientPool) - - async def test_setup(self): - async with self.get_client() as client: - from minos.plugins.aiopg import ( - AiopgDatabaseOperation, - ) + def tearDown(self): + super().tearDown() - operation = AiopgDatabaseOperation( - "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_transaction');" - ) - await client.execute(operation) - response = (await client.fetch_one())[0] - self.assertTrue(response) + @abstractmethod + def build_transaction_repository(self) -> TransactionRepository: + """For testing purposes.""" + + +class TransactionRepositorySubmitTestCase(TransactionRepositoryTestCase, ABC): + __test__ = False + + def setUp(self) -> None: + super().setUp() + self.uuid = uuid4() + + async def test_subclass(self) -> None: + self.assertTrue(isinstance(self.transaction_repository, TransactionRepository)) async def test_submit(self): await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.PENDING, 34)) @@ -71,11 +57,6 @@ async def test_submit(self): observed = [v async for v in self.transaction_repository.select()] self.assertEqual(expected, observed) - async def test_select_empty(self): - expected = [] - observed = [v async for v in self.transaction_repository.select()] - self.assertEqual(expected, observed) - async def test_submit_pending_raises(self): await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.PENDING, 34)) with self.assertRaises(TransactionRepositoryConflictException): @@ -148,9 +129,15 @@ async def test_submit_rejected_raises(self): with self.assertRaises(TransactionRepositoryConflictException): await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.REJECTED, 34)) + async def test_select_empty(self): + expected = [] + observed = [v async for v in self.transaction_repository.select()] + self.assertEqual(expected, observed) + + +class TransactionRepositorySelectTestCase(TransactionRepositoryTestCase, ABC): + __test__ = False -@unittest.skip -class TestDatabaseTransactionRepositorySelect(AggregateTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() self.uuid_1 = uuid4() @@ -159,8 +146,6 @@ def setUp(self) -> None: self.uuid_4 = uuid4() self.uuid_5 = uuid4() - self.transaction_repository = DatabaseTransactionRepository() - self.entries = [ TransactionEntry(self.uuid_1, TransactionStatus.PENDING, 12), TransactionEntry(self.uuid_2, TransactionStatus.PENDING, 15), @@ -171,7 +156,6 @@ def setUp(self) -> None: async def asyncSetUp(self): await super().asyncSetUp() - await self.transaction_repository.setup() await self._populate() async def _populate(self): @@ -183,10 +167,6 @@ async def _populate(self): TransactionEntry(self.uuid_5, TransactionStatus.PENDING, 20, self.uuid_1) ) - async def asyncTearDown(self): - await self.transaction_repository.destroy() - await super().asyncTearDown() - async def test_select(self): expected = self.entries observed = [v async for v in self.transaction_repository.select()] @@ -286,7 +266,3 @@ async def test_select_updated_at_ge(self): expected = [self.entries[2], self.entries[3], self.entries[4]] observed = [v async for v in self.transaction_repository.select(updated_at_ge=updated_at)] self.assertEqual(expected, observed) - - -if __name__ == "__main__": - unittest.main() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py index 394666700..0f02d4a67 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py @@ -1,257 +1,30 @@ import unittest -from uuid import ( - uuid4, -) from minos.aggregate import ( InMemoryTransactionRepository, - TransactionEntry, TransactionRepository, - TransactionRepositoryConflictException, - TransactionStatus, +) +from minos.aggregate.testing import ( + TransactionRepositorySelectTestCase, + TransactionRepositorySubmitTestCase, ) from tests.utils import ( AggregateTestCase, ) -class TestInMemoryTransactionRepository(AggregateTestCase): - def setUp(self) -> None: - super().setUp() - self.uuid = uuid4() - - async def asyncSetUp(self) -> None: - await super().asyncSetUp() - self.transaction_repository = InMemoryTransactionRepository() - await self.transaction_repository.setup() - - async def asyncTearDown(self) -> None: - await self.transaction_repository.destroy() - await super().asyncTearDown() - - async def test_subclass(self) -> None: - self.assertTrue(issubclass(InMemoryTransactionRepository, TransactionRepository)) - - async def test_submit(self): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.PENDING, 34)) - expected = [TransactionEntry(self.uuid, TransactionStatus.PENDING, 34)] - observed = [v async for v in self.transaction_repository.select()] - self.assertEqual(expected, observed) - - async def test_submit_pending_raises(self): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.PENDING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVED, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTED, 34)) - - async def test_submit_reserving_raises(self): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.PENDING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTED, 34)) - - async def test_submit_reserved_raises(self): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVED, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.PENDING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVED, 34)) - - async def test_submit_committing_raises(self): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTED, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.PENDING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVED, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.REJECTED, 34)) - - async def test_submit_committed_raises(self): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTED, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.PENDING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVED, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTED, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.REJECTED, 34)) - - async def test_submit_rejected_raises(self): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.REJECTED, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.PENDING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.RESERVED, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTING, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.COMMITTED, 34)) - with self.assertRaises(TransactionRepositoryConflictException): - await self.transaction_repository.submit(TransactionEntry(self.uuid, TransactionStatus.REJECTED, 34)) - - async def test_select_empty(self): - expected = [] - observed = [v async for v in self.transaction_repository.select()] - self.assertEqual(expected, observed) - - -class TestInMemoryTransactionRepositorySelect(AggregateTestCase): - def setUp(self) -> None: - super().setUp() - self.uuid_1 = uuid4() - self.uuid_2 = uuid4() - self.uuid_3 = uuid4() - self.uuid_4 = uuid4() - self.uuid_5 = uuid4() - - self.transaction_repository = InMemoryTransactionRepository() - - self.entries = [ - TransactionEntry(self.uuid_1, TransactionStatus.PENDING, 12), - TransactionEntry(self.uuid_2, TransactionStatus.PENDING, 15), - TransactionEntry(self.uuid_3, TransactionStatus.REJECTED, 16), - TransactionEntry(self.uuid_4, TransactionStatus.COMMITTED, 20), - TransactionEntry(self.uuid_5, TransactionStatus.PENDING, 20, self.uuid_1), - ] - - async def asyncSetUp(self): - await super().asyncSetUp() - await self._populate() - - async def _populate(self): - await self.transaction_repository.setup() - await self.transaction_repository.submit(TransactionEntry(self.uuid_1, TransactionStatus.PENDING, 12)) - await self.transaction_repository.submit(TransactionEntry(self.uuid_2, TransactionStatus.PENDING, 15)) - await self.transaction_repository.submit(TransactionEntry(self.uuid_3, TransactionStatus.REJECTED, 16)) - await self.transaction_repository.submit(TransactionEntry(self.uuid_4, TransactionStatus.COMMITTED, 20)) - await self.transaction_repository.submit( - TransactionEntry(self.uuid_5, TransactionStatus.PENDING, 20, self.uuid_1) - ) - - async def asyncTearDown(self): - await self.transaction_repository.destroy() - await super().asyncTearDown() - - async def test_select(self): - expected = self.entries - observed = [v async for v in self.transaction_repository.select()] - self.assertEqual(expected, observed) - - async def test_select_uuid(self): - expected = [self.entries[1]] - observed = [v async for v in self.transaction_repository.select(uuid=self.uuid_2)] - self.assertEqual(expected, observed) - - async def test_select_uuid_ne(self): - expected = [self.entries[0], self.entries[2], self.entries[3], self.entries[4]] - observed = [v async for v in self.transaction_repository.select(uuid_ne=self.uuid_2)] - self.assertEqual(expected, observed) - - async def test_select_uuid_in(self): - expected = [self.entries[1], self.entries[2]] - observed = [v async for v in self.transaction_repository.select(uuid_in=(self.uuid_2, self.uuid_3))] - self.assertEqual(expected, observed) - - async def test_select_destination_uuid(self): - expected = [self.entries[4]] - observed = [v async for v in self.transaction_repository.select(destination_uuid=self.uuid_1)] - self.assertEqual(expected, observed) - - async def test_select_status(self): - expected = [self.entries[0], self.entries[1], self.entries[4]] - observed = [v async for v in self.transaction_repository.select(status=TransactionStatus.PENDING)] - self.assertEqual(expected, observed) - - async def test_select_status_in(self): - expected = [self.entries[2], self.entries[3]] - observed = [ - v - async for v in self.transaction_repository.select( - status_in=(TransactionStatus.COMMITTED, TransactionStatus.REJECTED) - ) - ] - self.assertEqual(expected, observed) - - async def test_select_event_offset(self): - expected = [self.entries[1]] - observed = [v async for v in self.transaction_repository.select(event_offset=15)] - self.assertEqual(expected, observed) - - async def test_select_event_offset_lt(self): - expected = [self.entries[0]] - observed = [v async for v in self.transaction_repository.select(event_offset_lt=15)] - self.assertEqual(expected, observed) - - async def test_select_event_offset_gt(self): - expected = [self.entries[2], self.entries[3], self.entries[4]] - observed = [v async for v in self.transaction_repository.select(event_offset_gt=15)] - self.assertEqual(expected, observed) - - async def test_select_event_offset_le(self): - expected = [self.entries[0], self.entries[1]] - observed = [v async for v in self.transaction_repository.select(event_offset_le=15)] - self.assertEqual(expected, observed) - - async def test_select_event_offset_ge(self): - expected = [self.entries[1], self.entries[2], self.entries[3], self.entries[4]] - observed = [v async for v in self.transaction_repository.select(event_offset_ge=15)] - self.assertEqual(expected, observed) - - async def test_select_updated_at(self): - updated_at = (await self.transaction_repository.get(self.uuid_3)).updated_at - - expected = [self.entries[2]] - observed = [v async for v in self.transaction_repository.select(updated_at=updated_at)] - self.assertEqual(expected, observed) - - async def test_select_updated_at_lt(self): - updated_at = (await self.transaction_repository.get(self.uuid_3)).updated_at - - expected = [self.entries[0], self.entries[1]] - observed = [v async for v in self.transaction_repository.select(updated_at_lt=updated_at)] - self.assertEqual(expected, observed) - - async def test_select_updated_at_gt(self): - updated_at = (await self.transaction_repository.get(self.uuid_3)).updated_at - - expected = [self.entries[3], self.entries[4]] - observed = [v async for v in self.transaction_repository.select(updated_at_gt=updated_at)] - self.assertEqual(expected, observed) +class TestInMemoryTransactionRepository(AggregateTestCase, TransactionRepositorySubmitTestCase): + __test__ = True - async def test_select_updated_at_le(self): - updated_at = (await self.transaction_repository.get(self.uuid_3)).updated_at + def build_transaction_repository(self) -> TransactionRepository: + return InMemoryTransactionRepository() - expected = [self.entries[0], self.entries[1], self.entries[2]] - observed = [v async for v in self.transaction_repository.select(updated_at_le=updated_at)] - self.assertEqual(expected, observed) - async def test_select_updated_at_ge(self): - updated_at = (await self.transaction_repository.get(self.uuid_3)).updated_at +class TestInMemoryTransactionRepositorySelect(AggregateTestCase, TransactionRepositorySelectTestCase): + __test__ = True - expected = [self.entries[2], self.entries[3], self.entries[4]] - observed = [v async for v in self.transaction_repository.select(updated_at_ge=updated_at)] - self.assertEqual(expected, observed) + def build_transaction_repository(self) -> TransactionRepository: + return InMemoryTransactionRepository() if __name__ == "__main__": diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py new file mode 100644 index 000000000..7402d277e --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py @@ -0,0 +1,56 @@ +import unittest +from minos.aggregate import ( + DatabaseTransactionRepository, + TransactionRepository, +) +from minos.aggregate.testing import ( + TransactionRepositorySelectTestCase, + TransactionRepositorySubmitTestCase, +) +from minos.common import ( + DatabaseClientPool, +) +from minos.plugins.aiopg import ( + AiopgDatabaseOperation, +) +from tests.utils import ( + AiopgTestCase, +) + + +# noinspection SqlNoDataSourceInspection +class TestDatabaseTransactionRepository(AiopgTestCase, TransactionRepositorySubmitTestCase): + __test__ = True + + def build_transaction_repository(self) -> TransactionRepository: + return DatabaseTransactionRepository() + + def test_constructor(self): + pool = DatabaseClientPool.from_config(self.config) + repository = DatabaseTransactionRepository(pool) + self.assertIsInstance(repository, DatabaseTransactionRepository) + self.assertEqual(pool, repository.database_pool) + + def test_from_config(self): + repository = DatabaseTransactionRepository.from_config(self.config) + self.assertIsInstance(repository.database_pool, DatabaseClientPool) + + async def test_setup(self): + async with self.get_client() as client: + operation = AiopgDatabaseOperation( + "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_transaction');" + ) + await client.execute(operation) + response = (await client.fetch_one())[0] + self.assertTrue(response) + + +class TestDatabaseTransactionRepositorySelect(AiopgTestCase, TransactionRepositorySelectTestCase): + __test__ = True + + def build_transaction_repository(self) -> TransactionRepository: + return DatabaseTransactionRepository() + + +if __name__ == "__main__": + unittest.main() From c3987eaa89ee20eb85b2dd4a87b70a4fab4131cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 11:41:59 +0200 Subject: [PATCH 200/324] ISSUE #98 * Minor fix. --- .../minos/aggregate/testing/transaction_repository.py | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py index 65a1bcfb8..0738a3908 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py @@ -7,7 +7,6 @@ ) from minos.aggregate import ( - InMemoryTransactionRepository, TransactionEntry, TransactionRepository, TransactionRepositoryConflictException, From f865414dbef925e72cb55b25dd68856a41e8243d Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Mon, 11 Apr 2022 11:47:29 +0200 Subject: [PATCH 201/324] ISSUE #378 --- .../tests/test_kong/test_client.py | 302 ++++++------------ .../tests/test_kong/test_discovery.py | 290 +++++++++++++++++ .../tests/test_kong/test_kong_client.py | 182 ----------- .../tests/test_kong/test_middleware.py | 11 +- 4 files changed, 397 insertions(+), 388 deletions(-) create mode 100644 packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py delete mode 100644 packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 000e093ab..43c5715ed 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -6,15 +6,11 @@ import httpx -from minos.common import ( - Config, -) from minos.plugins.kong import ( + KongClient, KongDiscoveryClient, ) from tests.utils import ( - CONFIG_FILE_NO_AUTH_PATH, - CONFIG_FILE_PATH, TEST_HOST, ) @@ -27,52 +23,26 @@ class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): def setUp(self) -> None: self.client = KongDiscoveryClient(self.KONG_HOST, self.KONG_PORT, circuit_breaker_time=0.1) + self.kong = KongClient(self.client.route) @staticmethod def generate_underscore_uuid(): name = str(uuid4()) return name.replace("-", "_") - def test_constructor(self): - client = KongDiscoveryClient() - self.assertEqual("localhost", client.host) - self.assertEqual(5567, client.port) - - def test_route(self): - # noinspection HttpUrlsUsage - self.assertEqual(f"{PROTOCOL}://{self.client.host}:{self.client.port}", self.client.route) - - async def test_already_exist_subscribe(self): + async def test_register_service(self): name = self.generate_underscore_uuid() - - response = await self.client.subscribe( - TEST_HOST, - 5660, - name, - [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + response = await self.kong.register_service( + discovery_route=self.client.route, + service_name=name, + microservice_host=TEST_HOST, + microservice_port=5660, ) - self.assertTrue(201 == response.status_code) - response = await self.client.subscribe( - TEST_HOST, - 5660, - name, - [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], - ) - self.assertTrue(201 == response.status_code) - - async def test_subscribe(self): - name = self.generate_underscore_uuid() - response = await self.client.subscribe( - TEST_HOST, - 5660, - name, - [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], - ) self.assertTrue(201 == response.status_code) async with httpx.AsyncClient() as client: - url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + url = f"{self.client.route}/services/{name}" response = await client.get(url) response_data = response.json() self.assertTrue(200 == response.status_code) @@ -80,210 +50,132 @@ async def test_subscribe(self): self.assertEqual(TEST_HOST, response_data["host"]) self.assertEqual(PROTOCOL, response_data["protocol"]) - async def test_subscribe_with_auth(self): - name = self.generate_underscore_uuid() - response = await self.client.subscribe( - TEST_HOST, - 5660, - name, - [ - {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - ], - ) - self.assertTrue(201 == response.status_code) + async def test_create_consumer(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) - async with httpx.AsyncClient() as client: - url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" - response = await client.get(url) - response_data = response.json() - self.assertTrue(200 == response.status_code) - self.assertEqual(5660, response_data["port"]) - self.assertEqual(TEST_HOST, response_data["host"]) - self.assertEqual(PROTOCOL, response_data["protocol"]) + self.assertTrue(201 == response.status_code) - async def test_unsubscribe(self): - name = self.generate_underscore_uuid() - response = await self.client.subscribe( - TEST_HOST, 5660, name, [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] - ) + async def test_add_basic_auth_to_consumer(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) self.assertTrue(201 == response.status_code) + resp = response.json() - response_delete = await self.client.unsubscribe(name) - self.assertTrue(204 == response_delete.status_code) - - async with httpx.AsyncClient() as client: - url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" - response = await client.get(url) - self.assertTrue(404 == response.status_code) - - async def test_route_params(self): - expected = ["/foo/.*", "/bar/.*/.*"] - response = await self.client.subscribe( - TEST_HOST, - 5660, - "test", - [{"url": "/foo/{:user}", "method": "POST"}, {"url": "/bar/{:domain}/{:username}", "method": "GET"}], - ) + response = await self.kong.add_basic_auth_to_consumer(user_name, "test", resp["id"]) self.assertTrue(201 == response.status_code) - async with httpx.AsyncClient() as client: - url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/test/routes" - response = await client.get(url) - response_data = response.json() - self.assertTrue(200 == response.status_code) - self.assertGreater(len(response_data["data"]), 0) + async def test_add_jwt_to_consumer(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) - for route in response_data["data"]: - self.assertTrue(bool(set(route["paths"]) & set(expected))) + self.assertTrue(201 == response.status_code) + resp = response.json() + response = await self.kong.add_jwt_to_consumer(consumer=resp["id"]) -class TestKongDiscoveryClientFromConfig(unittest.IsolatedAsyncioTestCase): - KONG_HOST = os.getenv("KONG_HOST", "localhost") - KONG_PORT = os.getenv("KONG_PORT", 8001) - - def setUp(self) -> None: - config = Config(CONFIG_FILE_PATH) - self.client = KongDiscoveryClient.from_config(config=config, circuit_breaker_time=0.1) + self.assertTrue(201 == response.status_code) - @staticmethod - def generate_underscore_uuid(): - name = str(uuid4()) - return name.replace("-", "_") + async def test_add_acl_to_consumer(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) - async def test_subscribe(self): - name = self.generate_underscore_uuid() - response = await self.client.subscribe( - TEST_HOST, - 5660, - name, - [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], - ) self.assertTrue(201 == response.status_code) + resp = response.json() - async with httpx.AsyncClient() as client: - url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" - response = await client.get(url) - response_data = response.json() - self.assertTrue(200 == response.status_code) - self.assertEqual(5660, response_data["port"]) - self.assertEqual(TEST_HOST, response_data["host"]) - self.assertEqual(PROTOCOL, response_data["protocol"]) + response = await self.kong.add_acl_to_consumer(role="admin", consumer=resp["id"]) - async def test_subscribe_with_auth(self): - name = self.generate_underscore_uuid() - response = await self.client.subscribe( - TEST_HOST, - 5660, - name, - [ - {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - ], - ) self.assertTrue(201 == response.status_code) - async with httpx.AsyncClient() as client: - url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" - response = await client.get(url) - response_data = response.json() - self.assertTrue(200 == response.status_code) - self.assertEqual(5660, response_data["port"]) - self.assertEqual(TEST_HOST, response_data["host"]) - self.assertEqual(PROTOCOL, response_data["protocol"]) - + async def test_activate_acl_plugin_on_service(self): + name = self.generate_underscore_uuid() + response = await self.kong.register_service( + discovery_route=self.client.route, + service_name=name, + microservice_host=TEST_HOST, + microservice_port=5660, + ) -class TestKongDiscoveryClientFromConfigOverrideAuth(unittest.IsolatedAsyncioTestCase): - KONG_HOST = os.getenv("KONG_HOST", "localhost") - KONG_PORT = os.getenv("KONG_PORT", 8001) + self.assertTrue(201 == response.status_code) - def setUp(self) -> None: - config = Config(CONFIG_FILE_PATH) - self.client = KongDiscoveryClient.from_config(config=config, auth_type="basic-auth", circuit_breaker_time=0.1) + response = await self.kong.activate_acl_plugin_on_service(service_name=name, allow=["admin"]) - @staticmethod - def generate_underscore_uuid(): - name = str(uuid4()) - return name.replace("-", "_") + self.assertTrue(201 == response.status_code) - async def test_subscribe(self): + async def test_activate_basic_auth_plugin_on_service(self): name = self.generate_underscore_uuid() - response = await self.client.subscribe( - TEST_HOST, - 5660, - name, - [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + response = await self.kong.register_service( + discovery_route=self.client.route, + service_name=name, + microservice_host=TEST_HOST, + microservice_port=5660, ) + self.assertTrue(201 == response.status_code) - async with httpx.AsyncClient() as client: - url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" - response = await client.get(url) - response_data = response.json() - self.assertTrue(200 == response.status_code) - self.assertEqual(5660, response_data["port"]) - self.assertEqual(TEST_HOST, response_data["host"]) - self.assertEqual(PROTOCOL, response_data["protocol"]) + response = await self.kong.activate_basic_auth_plugin_on_service(service_name=name) - async def test_subscribe_with_auth(self): - name = self.generate_underscore_uuid() - response = await self.client.subscribe( - TEST_HOST, - 5660, - name, - [ - {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - ], - ) self.assertTrue(201 == response.status_code) - async with httpx.AsyncClient() as client: - url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" - response = await client.get(url) - response_data = response.json() - self.assertTrue(200 == response.status_code) - self.assertEqual(5660, response_data["port"]) - self.assertEqual(TEST_HOST, response_data["host"]) - self.assertEqual(PROTOCOL, response_data["protocol"]) + async def test_activate_basic_auth_plugin_on_route(self): + name = self.generate_underscore_uuid() + response = await self.kong.register_service( + discovery_route=self.client.route, + service_name=name, + microservice_host=TEST_HOST, + microservice_port=5660, + ) + self.assertTrue(201 == response.status_code) + res = response.json() + response = await self.kong.create_route( + endpoint=self.client.route, + protocols=["http"], + methods=["GET"], + paths=["/foo"], + service=res["id"], + strip_path=False, + ) -class TestKongDiscoveryClientFromConfigNoAuth(unittest.IsolatedAsyncioTestCase): - KONG_HOST = os.getenv("KONG_HOST", "localhost") - KONG_PORT = os.getenv("KONG_PORT", 8001) + self.assertTrue(201 == response.status_code) - def setUp(self) -> None: - config = Config(CONFIG_FILE_NO_AUTH_PATH) - self.client = KongDiscoveryClient.from_config(config=config, circuit_breaker_time=0.1) + res = response.json() + response = await self.kong.activate_basic_auth_plugin_on_route(route_id=res["id"]) - @staticmethod - def generate_underscore_uuid(): - name = str(uuid4()) - return name.replace("-", "_") + self.assertTrue(201 == response.status_code) - async def test_subscribe(self): + async def test_activate_jwt_plugin_on_route(self): name = self.generate_underscore_uuid() - response = await self.client.subscribe( - TEST_HOST, - 5660, - name, - [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + response = await self.kong.register_service( + discovery_route=self.client.route, + service_name=name, + microservice_host=TEST_HOST, + microservice_port=5660, ) + self.assertTrue(201 == response.status_code) + res = response.json() + response = await self.kong.create_route( + endpoint=self.client.route, + protocols=["http"], + methods=["GET"], + paths=["/foo"], + service=res["id"], + strip_path=False, + ) - async with httpx.AsyncClient() as client: - url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" - response = await client.get(url) - response_data = response.json() - self.assertTrue(200 == response.status_code) - self.assertEqual(5660, response_data["port"]) - self.assertEqual(TEST_HOST, response_data["host"]) - self.assertEqual(PROTOCOL, response_data["protocol"]) + self.assertTrue(201 == response.status_code) + + res = response.json() + response = await self.kong.activate_jwt_plugin_on_route(route_id=res["id"]) + + self.assertTrue(201 == response.status_code) if __name__ == "__main__": diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py new file mode 100644 index 000000000..000e093ab --- /dev/null +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py @@ -0,0 +1,290 @@ +import os +import unittest +from uuid import ( + uuid4, +) + +import httpx + +from minos.common import ( + Config, +) +from minos.plugins.kong import ( + KongDiscoveryClient, +) +from tests.utils import ( + CONFIG_FILE_NO_AUTH_PATH, + CONFIG_FILE_PATH, + TEST_HOST, +) + +PROTOCOL = "http" + + +class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): + KONG_HOST = os.getenv("KONG_HOST", "localhost") + KONG_PORT = os.getenv("KONG_PORT", 8001) + + def setUp(self) -> None: + self.client = KongDiscoveryClient(self.KONG_HOST, self.KONG_PORT, circuit_breaker_time=0.1) + + @staticmethod + def generate_underscore_uuid(): + name = str(uuid4()) + return name.replace("-", "_") + + def test_constructor(self): + client = KongDiscoveryClient() + self.assertEqual("localhost", client.host) + self.assertEqual(5567, client.port) + + def test_route(self): + # noinspection HttpUrlsUsage + self.assertEqual(f"{PROTOCOL}://{self.client.host}:{self.client.port}", self.client.route) + + async def test_already_exist_subscribe(self): + name = self.generate_underscore_uuid() + + response = await self.client.subscribe( + TEST_HOST, + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + ) + self.assertTrue(201 == response.status_code) + + response = await self.client.subscribe( + TEST_HOST, + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + ) + self.assertTrue(201 == response.status_code) + + async def test_subscribe(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + TEST_HOST, + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual(TEST_HOST, response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + async def test_subscribe_with_auth(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + TEST_HOST, + 5660, + name, + [ + {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + ], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual(TEST_HOST, response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + async def test_unsubscribe(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + TEST_HOST, 5660, name, [{"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}] + ) + + self.assertTrue(201 == response.status_code) + + response_delete = await self.client.unsubscribe(name) + self.assertTrue(204 == response_delete.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + self.assertTrue(404 == response.status_code) + + async def test_route_params(self): + expected = ["/foo/.*", "/bar/.*/.*"] + response = await self.client.subscribe( + TEST_HOST, + 5660, + "test", + [{"url": "/foo/{:user}", "method": "POST"}, {"url": "/bar/{:domain}/{:username}", "method": "GET"}], + ) + + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/test/routes" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertGreater(len(response_data["data"]), 0) + + for route in response_data["data"]: + self.assertTrue(bool(set(route["paths"]) & set(expected))) + + +class TestKongDiscoveryClientFromConfig(unittest.IsolatedAsyncioTestCase): + KONG_HOST = os.getenv("KONG_HOST", "localhost") + KONG_PORT = os.getenv("KONG_PORT", 8001) + + def setUp(self) -> None: + config = Config(CONFIG_FILE_PATH) + self.client = KongDiscoveryClient.from_config(config=config, circuit_breaker_time=0.1) + + @staticmethod + def generate_underscore_uuid(): + name = str(uuid4()) + return name.replace("-", "_") + + async def test_subscribe(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + TEST_HOST, + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual(TEST_HOST, response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + async def test_subscribe_with_auth(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + TEST_HOST, + 5660, + name, + [ + {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + ], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual(TEST_HOST, response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + +class TestKongDiscoveryClientFromConfigOverrideAuth(unittest.IsolatedAsyncioTestCase): + KONG_HOST = os.getenv("KONG_HOST", "localhost") + KONG_PORT = os.getenv("KONG_PORT", 8001) + + def setUp(self) -> None: + config = Config(CONFIG_FILE_PATH) + self.client = KongDiscoveryClient.from_config(config=config, auth_type="basic-auth", circuit_breaker_time=0.1) + + @staticmethod + def generate_underscore_uuid(): + name = str(uuid4()) + return name.replace("-", "_") + + async def test_subscribe(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + TEST_HOST, + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual(TEST_HOST, response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + async def test_subscribe_with_auth(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + TEST_HOST, + 5660, + name, + [ + {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + ], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual(TEST_HOST, response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + +class TestKongDiscoveryClientFromConfigNoAuth(unittest.IsolatedAsyncioTestCase): + KONG_HOST = os.getenv("KONG_HOST", "localhost") + KONG_PORT = os.getenv("KONG_PORT", 8001) + + def setUp(self) -> None: + config = Config(CONFIG_FILE_NO_AUTH_PATH) + self.client = KongDiscoveryClient.from_config(config=config, circuit_breaker_time=0.1) + + @staticmethod + def generate_underscore_uuid(): + name = str(uuid4()) + return name.replace("-", "_") + + async def test_subscribe(self): + name = self.generate_underscore_uuid() + response = await self.client.subscribe( + TEST_HOST, + 5660, + name, + [{"url": "/", "method": "GET"}, {"url": "/foo", "method": "POST"}, {"url": "/bar", "method": "GET"}], + ) + self.assertTrue(201 == response.status_code) + + async with httpx.AsyncClient() as client: + url = f"{PROTOCOL}://{self.client.host}:{self.client.port}/services/{name}" + response = await client.get(url) + response_data = response.json() + self.assertTrue(200 == response.status_code) + self.assertEqual(5660, response_data["port"]) + self.assertEqual(TEST_HOST, response_data["host"]) + self.assertEqual(PROTOCOL, response_data["protocol"]) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py deleted file mode 100644 index 43c5715ed..000000000 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_kong_client.py +++ /dev/null @@ -1,182 +0,0 @@ -import os -import unittest -from uuid import ( - uuid4, -) - -import httpx - -from minos.plugins.kong import ( - KongClient, - KongDiscoveryClient, -) -from tests.utils import ( - TEST_HOST, -) - -PROTOCOL = "http" - - -class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): - KONG_HOST = os.getenv("KONG_HOST", "localhost") - KONG_PORT = os.getenv("KONG_PORT", 8001) - - def setUp(self) -> None: - self.client = KongDiscoveryClient(self.KONG_HOST, self.KONG_PORT, circuit_breaker_time=0.1) - self.kong = KongClient(self.client.route) - - @staticmethod - def generate_underscore_uuid(): - name = str(uuid4()) - return name.replace("-", "_") - - async def test_register_service(self): - name = self.generate_underscore_uuid() - response = await self.kong.register_service( - discovery_route=self.client.route, - service_name=name, - microservice_host=TEST_HOST, - microservice_port=5660, - ) - - self.assertTrue(201 == response.status_code) - - async with httpx.AsyncClient() as client: - url = f"{self.client.route}/services/{name}" - response = await client.get(url) - response_data = response.json() - self.assertTrue(200 == response.status_code) - self.assertEqual(5660, response_data["port"]) - self.assertEqual(TEST_HOST, response_data["host"]) - self.assertEqual(PROTOCOL, response_data["protocol"]) - - async def test_create_consumer(self): - user_uuid = uuid4() - user_name = self.generate_underscore_uuid() - response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) - - self.assertTrue(201 == response.status_code) - - async def test_add_basic_auth_to_consumer(self): - user_uuid = uuid4() - user_name = self.generate_underscore_uuid() - response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) - - self.assertTrue(201 == response.status_code) - resp = response.json() - - response = await self.kong.add_basic_auth_to_consumer(user_name, "test", resp["id"]) - - self.assertTrue(201 == response.status_code) - - async def test_add_jwt_to_consumer(self): - user_uuid = uuid4() - user_name = self.generate_underscore_uuid() - response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) - - self.assertTrue(201 == response.status_code) - resp = response.json() - - response = await self.kong.add_jwt_to_consumer(consumer=resp["id"]) - - self.assertTrue(201 == response.status_code) - - async def test_add_acl_to_consumer(self): - user_uuid = uuid4() - user_name = self.generate_underscore_uuid() - response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) - - self.assertTrue(201 == response.status_code) - resp = response.json() - - response = await self.kong.add_acl_to_consumer(role="admin", consumer=resp["id"]) - - self.assertTrue(201 == response.status_code) - - async def test_activate_acl_plugin_on_service(self): - name = self.generate_underscore_uuid() - response = await self.kong.register_service( - discovery_route=self.client.route, - service_name=name, - microservice_host=TEST_HOST, - microservice_port=5660, - ) - - self.assertTrue(201 == response.status_code) - - response = await self.kong.activate_acl_plugin_on_service(service_name=name, allow=["admin"]) - - self.assertTrue(201 == response.status_code) - - async def test_activate_basic_auth_plugin_on_service(self): - name = self.generate_underscore_uuid() - response = await self.kong.register_service( - discovery_route=self.client.route, - service_name=name, - microservice_host=TEST_HOST, - microservice_port=5660, - ) - - self.assertTrue(201 == response.status_code) - - response = await self.kong.activate_basic_auth_plugin_on_service(service_name=name) - - self.assertTrue(201 == response.status_code) - - async def test_activate_basic_auth_plugin_on_route(self): - name = self.generate_underscore_uuid() - response = await self.kong.register_service( - discovery_route=self.client.route, - service_name=name, - microservice_host=TEST_HOST, - microservice_port=5660, - ) - - self.assertTrue(201 == response.status_code) - res = response.json() - response = await self.kong.create_route( - endpoint=self.client.route, - protocols=["http"], - methods=["GET"], - paths=["/foo"], - service=res["id"], - strip_path=False, - ) - - self.assertTrue(201 == response.status_code) - - res = response.json() - response = await self.kong.activate_basic_auth_plugin_on_route(route_id=res["id"]) - - self.assertTrue(201 == response.status_code) - - async def test_activate_jwt_plugin_on_route(self): - name = self.generate_underscore_uuid() - response = await self.kong.register_service( - discovery_route=self.client.route, - service_name=name, - microservice_host=TEST_HOST, - microservice_port=5660, - ) - - self.assertTrue(201 == response.status_code) - res = response.json() - response = await self.kong.create_route( - endpoint=self.client.route, - protocols=["http"], - methods=["GET"], - paths=["/foo"], - service=res["id"], - strip_path=False, - ) - - self.assertTrue(201 == response.status_code) - - res = response.json() - response = await self.kong.activate_jwt_plugin_on_route(route_id=res["id"]) - - self.assertTrue(201 == response.status_code) - - -if __name__ == "__main__": - unittest.main() diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_middleware.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_middleware.py index 763735276..131bcecd0 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_middleware.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_middleware.py @@ -28,7 +28,7 @@ async def _fn(request: Request) -> Response: class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): - async def test_middleware_no_user_headers(self): + async def test_middleware_user_headers(self): user_uuid = uuid4() request_headers = {"X-Consumer-Custom-ID": str(user_uuid)} request = InMemoryHttpRequest(content="foo", headers=request_headers) @@ -38,6 +38,15 @@ async def test_middleware_no_user_headers(self): self.assertEqual({"X-Consumer-Custom-ID": str(user_uuid), "user": str(user_uuid)}, request_headers) + async def test_middleware_no_user_headers(self): + request_headers = {} + request = InMemoryHttpRequest(content="foo", headers=request_headers) + response = await middleware(request, _fn) + + self.assertEqual("foobar", await response.content()) + + self.assertEqual({}, request_headers) + if __name__ == "__main__": unittest.main() From 917c0cec0f0157d91b3d8955ca840342025a1197 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Mon, 11 Apr 2022 11:53:57 +0200 Subject: [PATCH 202/324] Update test_requests.py --- .../minos-http-aiohttp/tests/test_aiohttp/test_requests.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/packages/plugins/minos-http-aiohttp/tests/test_aiohttp/test_requests.py b/packages/plugins/minos-http-aiohttp/tests/test_aiohttp/test_requests.py index dd0a73feb..725ab541d 100644 --- a/packages/plugins/minos-http-aiohttp/tests/test_aiohttp/test_requests.py +++ b/packages/plugins/minos-http-aiohttp/tests/test_aiohttp/test_requests.py @@ -73,6 +73,13 @@ def test_headers(self): request = AioHttpRequest(raw) self.assertEqual({"something": "123"}, request.headers) + def test_headers_modifiable(self): + raw = mocked_request(headers={"something": "123"}) + request = AioHttpRequest(raw) + self.assertEqual({"something": "123"}, request.headers) + request.headers['something'] = "321" + self.assertEqual({"something": "321"}, request.headers) + def test_user(self): uuid = uuid4() raw = mocked_request(user=uuid) From d92fbcc3c83a8e3826c7bc6722b37b100c2493e9 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Mon, 11 Apr 2022 09:54:08 +0000 Subject: [PATCH 203/324] Restyled by black --- .../minos-http-aiohttp/tests/test_aiohttp/test_requests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/plugins/minos-http-aiohttp/tests/test_aiohttp/test_requests.py b/packages/plugins/minos-http-aiohttp/tests/test_aiohttp/test_requests.py index 725ab541d..0375e5b21 100644 --- a/packages/plugins/minos-http-aiohttp/tests/test_aiohttp/test_requests.py +++ b/packages/plugins/minos-http-aiohttp/tests/test_aiohttp/test_requests.py @@ -77,7 +77,7 @@ def test_headers_modifiable(self): raw = mocked_request(headers={"something": "123"}) request = AioHttpRequest(raw) self.assertEqual({"something": "123"}, request.headers) - request.headers['something'] = "321" + request.headers["something"] = "321" self.assertEqual({"something": "321"}, request.headers) def test_user(self): From b7364438db1fd75b23bdb061aab82c374474bb43 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Mon, 11 Apr 2022 12:37:27 +0200 Subject: [PATCH 204/324] ISSUE #373 --- .../tests/services/commands.py | 2 +- .../tests/services/queries.py | 2 +- .../test_discovery/test_clients/test_abc.py | 12 ++++++++++++ .../test_discovery/test_connectors.py | 19 +++++++++++++++---- 4 files changed, 29 insertions(+), 6 deletions(-) diff --git a/packages/core/minos-microservice-networks/tests/services/commands.py b/packages/core/minos-microservice-networks/tests/services/commands.py index fbbc75cd9..408ed58d0 100644 --- a/packages/core/minos-microservice-networks/tests/services/commands.py +++ b/packages/core/minos-microservice-networks/tests/services/commands.py @@ -7,7 +7,7 @@ class CommandService: - @enroute.rest.command(path="/order", method="GET") + @enroute.rest.command(path="/order", method="GET", foo="bar") def get_order_rest(self, request: Request) -> Response: return Response("get_order") diff --git a/packages/core/minos-microservice-networks/tests/services/queries.py b/packages/core/minos-microservice-networks/tests/services/queries.py index 835300277..c48d8cafb 100644 --- a/packages/core/minos-microservice-networks/tests/services/queries.py +++ b/packages/core/minos-microservice-networks/tests/services/queries.py @@ -6,7 +6,7 @@ class QueryService: - @enroute.rest.query(path="/ticket", method="POST") + @enroute.rest.query(path="/ticket", method="POST", foo="bar") def add_ticket(self, request: Request) -> Response: return Response("ticket_added") diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_clients/test_abc.py b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_clients/test_abc.py index c79f93685..03a461343 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_clients/test_abc.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_clients/test_abc.py @@ -5,10 +5,14 @@ from minos.common import ( Object, + Config, ) from minos.networks import ( DiscoveryClient, ) +from tests.utils import ( + CONFIG_FILE_PATH, +) class _DiscoveryClient(DiscoveryClient): @@ -30,6 +34,8 @@ async def unsubscribe(self, name: str, *args, **kwargs) -> None: class TestDiscoveryClient(unittest.IsolatedAsyncioTestCase): + CONFIG_FILE_PATH = CONFIG_FILE_PATH + def test_abstract(self): self.assertTrue(issubclass(DiscoveryClient, (ABC, Object))) # noinspection PyUnresolvedReferences @@ -39,6 +45,12 @@ def test_route(self): client = _DiscoveryClient("localhost", 9999) self.assertEqual("http://localhost:9999", client.route) + def test_from_config(self): + self.config = Config(self.CONFIG_FILE_PATH) + client = _DiscoveryClient.from_config(config=self.config) + self.assertEqual("discovery-service", client.host) + self.assertEqual(8080, client.port) + if __name__ == "__main__": unittest.main() diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py index a709f25f5..d4086d397 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py @@ -12,7 +12,7 @@ DiscoveryConnector, InMemoryDiscoveryClient, MinosInvalidDiscoveryClient, - get_host_ip, + get_host_ip, DiscoveryClient, ) from tests.utils import ( CONFIG_FILE_PATH, @@ -36,6 +36,17 @@ def test_constructor(self): self.assertEqual("192.168.1.32", connector.host) self.assertEqual(8080, connector.port) + def test_from_config(self): + connector = DiscoveryConnector.from_config(self.config) + expected = [ + {'url': '/order', 'method': 'DELETE'}, + {'url': '/order', 'method': 'GET', 'foo': 'bar'}, + {'url': '/ticket', 'method': 'POST', 'foo': 'bar'} + ] + + self.assertEqual(expected, connector.endpoints) + self.assertIsInstance(connector.client, DiscoveryClient) + def test_config_minos_client_does_not_exist(self): config = Config(self.CONFIG_FILE_PATH, minos_discovery_client="wrong-client") with self.assertRaises(MinosImportException): @@ -59,9 +70,9 @@ async def test_subscription(self): 8080, "Order", [ - {"url": "/order", "method": "DELETE"}, - {"url": "/order", "method": "GET"}, - {"url": "/ticket", "method": "POST"}, + {'url': '/order', 'method': 'DELETE'}, + {'url': '/order', 'method': 'GET', 'foo': 'bar'}, + {'url': '/ticket', 'method': 'POST', 'foo': 'bar'} ], ) self.assertEqual(expected, mock.call_args) From 7e558ebc5b381922a22ab54bb316cd822221ea4f Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Mon, 11 Apr 2022 10:37:47 +0000 Subject: [PATCH 205/324] Restyled by black --- .../test_discovery/test_connectors.py | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py index d4086d397..27a6bac06 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py @@ -12,7 +12,8 @@ DiscoveryConnector, InMemoryDiscoveryClient, MinosInvalidDiscoveryClient, - get_host_ip, DiscoveryClient, + get_host_ip, + DiscoveryClient, ) from tests.utils import ( CONFIG_FILE_PATH, @@ -39,9 +40,9 @@ def test_constructor(self): def test_from_config(self): connector = DiscoveryConnector.from_config(self.config) expected = [ - {'url': '/order', 'method': 'DELETE'}, - {'url': '/order', 'method': 'GET', 'foo': 'bar'}, - {'url': '/ticket', 'method': 'POST', 'foo': 'bar'} + {"url": "/order", "method": "DELETE"}, + {"url": "/order", "method": "GET", "foo": "bar"}, + {"url": "/ticket", "method": "POST", "foo": "bar"}, ] self.assertEqual(expected, connector.endpoints) @@ -70,9 +71,9 @@ async def test_subscription(self): 8080, "Order", [ - {'url': '/order', 'method': 'DELETE'}, - {'url': '/order', 'method': 'GET', 'foo': 'bar'}, - {'url': '/ticket', 'method': 'POST', 'foo': 'bar'} + {"url": "/order", "method": "DELETE"}, + {"url": "/order", "method": "GET", "foo": "bar"}, + {"url": "/ticket", "method": "POST", "foo": "bar"}, ], ) self.assertEqual(expected, mock.call_args) From c1ea40ba773ba945a799b9a6b9e6b8c527c33bbb Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Mon, 11 Apr 2022 10:37:48 +0000 Subject: [PATCH 206/324] Restyled by isort --- .../tests/test_networks/test_discovery/test_clients/test_abc.py | 2 +- .../tests/test_networks/test_discovery/test_connectors.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_clients/test_abc.py b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_clients/test_abc.py index 03a461343..887fab994 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_clients/test_abc.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_clients/test_abc.py @@ -4,8 +4,8 @@ ) from minos.common import ( - Object, Config, + Object, ) from minos.networks import ( DiscoveryClient, diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py index 27a6bac06..fecc9d61e 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_discovery/test_connectors.py @@ -9,11 +9,11 @@ MinosImportException, ) from minos.networks import ( + DiscoveryClient, DiscoveryConnector, InMemoryDiscoveryClient, MinosInvalidDiscoveryClient, get_host_ip, - DiscoveryClient, ) from tests.utils import ( CONFIG_FILE_PATH, From c0f75ef2e4b67146cb4518fd96f67b930abd81a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 13:12:41 +0200 Subject: [PATCH 207/324] ISSUE #98 * Migrate snapshot tests. --- .../minos/aggregate/snapshots/__init__.py | 14 +- .../snapshots/repositories/__init__.py | 13 + .../snapshots/{ => repositories}/abc.py | 24 +- .../{ => repositories}/database/__init__.py | 0 .../{ => repositories}/database/abc.py | 0 .../{ => repositories}/database/api.py | 10 +- .../database/factories/__init__.py | 0 .../database/factories/abc.py | 2 +- .../{ => repositories}/database/readers.py | 10 +- .../{ => repositories}/database/writers.py | 10 +- .../snapshots/{ => repositories}/memory.py | 10 +- .../minos/aggregate/snapshots/services.py | 2 +- .../minos/aggregate/testing/__init__.py | 4 + .../aggregate/testing/snapshot_repository.py | 672 ++++++++++++++++++ .../test_snapshots/test_memory.py | 359 ---------- .../test_snapshots/test_pg/test_abc.py | 48 -- .../test_snapshots/test_pg/test_readers.py | 369 ---------- .../test_snapshots/test_pg/test_writers.py | 339 --------- .../test_repositories/__init__.py | 0 .../{ => test_repositories}/test_abc.py | 0 .../test_repositories/test_memory.py | 35 + .../test_pg/__init__.py | 0 .../test_pg/test_api.py | 0 .../test_aggregate/test_snapshots/__init__.py | 0 .../test_aggregate/test_snapshots/test_pg.py | 59 ++ 25 files changed, 833 insertions(+), 1147 deletions(-) create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/__init__.py rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{ => repositories}/abc.py (92%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{ => repositories}/database/__init__.py (100%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{ => repositories}/database/abc.py (100%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{ => repositories}/database/api.py (90%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{ => repositories}/database/factories/__init__.py (100%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{ => repositories}/database/factories/abc.py (99%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{ => repositories}/database/readers.py (97%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{ => repositories}/database/writers.py (97%) rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/{ => repositories}/memory.py (97%) create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py delete mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py delete mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py delete mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py delete mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py create mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/__init__.py rename packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/{ => test_repositories}/test_abc.py (100%) create mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py rename packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/{ => test_repositories}/test_pg/__init__.py (100%) rename packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/{ => test_repositories}/test_pg/test_api.py (100%) create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py index 065cf08dc..c98072570 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py @@ -1,18 +1,14 @@ -from .abc import ( - SnapshotRepository, +from .entries import ( + SnapshotEntry, ) -from .database import ( +from .repositories import ( DatabaseSnapshotReader, DatabaseSnapshotRepository, DatabaseSnapshotSetup, DatabaseSnapshotWriter, - SnapshotDatabaseOperationFactory, -) -from .entries import ( - SnapshotEntry, -) -from .memory import ( InMemorySnapshotRepository, + SnapshotDatabaseOperationFactory, + SnapshotRepository, ) from .services import ( SnapshotService, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/__init__.py new file mode 100644 index 000000000..50896c892 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/__init__.py @@ -0,0 +1,13 @@ +from .abc import ( + SnapshotRepository, +) +from .database import ( + DatabaseSnapshotReader, + DatabaseSnapshotRepository, + DatabaseSnapshotSetup, + DatabaseSnapshotWriter, + SnapshotDatabaseOperationFactory, +) +from .memory import ( + InMemorySnapshotRepository, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py similarity index 92% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/abc.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py index f1b0f26a9..af0e74f3b 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py @@ -11,6 +11,7 @@ AsyncIterator, Awaitable, Optional, + Union, ) from uuid import ( UUID, @@ -19,20 +20,21 @@ from minos.common import ( Injectable, SetupMixin, + classname, ) -from ..queries import ( +from ...queries import ( _TRUE_CONDITION, _Condition, _Ordering, ) -from ..transactions import ( +from ...transactions import ( TRANSACTION_CONTEXT_VAR, TransactionEntry, ) if TYPE_CHECKING: - from ..entities import ( + from ...entities import ( RootEntity, ) @@ -45,7 +47,13 @@ class SnapshotRepository(ABC, SetupMixin): class. """ - async def get(self, name: str, uuid: UUID, transaction: Optional[TransactionEntry] = None, **kwargs) -> RootEntity: + async def get( + self, + name: Union[str, type[RootEntity]], + uuid: UUID, + transaction: Optional[TransactionEntry] = None, + **kwargs, + ) -> RootEntity: """Get a ``RootEntity`` instance from its identifier. :param name: Class name of the ``RootEntity``. @@ -56,6 +64,9 @@ async def get(self, name: str, uuid: UUID, transaction: Optional[TransactionEntr :param kwargs: Additional named arguments. :return: The ``RootEntity`` instance. """ + if isinstance(name, type): + name = classname(name) + if transaction is None: transaction = TRANSACTION_CONTEXT_VAR.get() @@ -103,7 +114,7 @@ def get_all( async def find( self, - name: str, + name: Union[str, type[RootEntity]], condition: _Condition, ordering: Optional[_Ordering] = None, limit: Optional[int] = None, @@ -127,6 +138,9 @@ async def find( :param kwargs: Additional named arguments. :return: An asynchronous iterator that containing the ``RootEntity`` instances. """ + if isinstance(name, type): + name = classname(name) + if transaction is None: transaction = TRANSACTION_CONTEXT_VAR.get() diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/__init__.py similarity index 100% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/__init__.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/__init__.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/abc.py similarity index 100% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/abc.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/abc.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/api.py similarity index 90% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/api.py index 6872540ce..fa12040ed 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/api.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/api.py @@ -23,7 +23,7 @@ ) if TYPE_CHECKING: - from ...entities import ( + from ....entities import ( RootEntity, ) @@ -71,3 +71,11 @@ def _find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: def _synchronize(self, *args, **kwargs) -> Awaitable[None]: return self.writer.dispatch(**kwargs) + + @property + def find_entries(self): + return self.reader.find_entries + + @property + def is_synced(self): + return self.writer.is_synced diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/__init__.py similarity index 100% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/__init__.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/__init__.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/abc.py similarity index 99% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/abc.py index 78d895209..13d173cb2 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/abc.py @@ -21,7 +21,7 @@ DatabaseOperationFactory, ) -from ....queries import ( +from .....queries import ( _Condition, _Ordering, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/readers.py similarity index 97% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/readers.py index 1dfca2862..972d1c6a1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/readers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/readers.py @@ -16,18 +16,18 @@ NULL_UUID, ) -from ...exceptions import ( +from ....exceptions import ( NotFoundException, ) -from ...queries import ( +from ....queries import ( _Condition, _EqualCondition, _Ordering, ) -from ...transactions import ( +from ....transactions import ( TransactionEntry, ) -from ..entries import ( +from ...entries import ( SnapshotEntry, ) from .abc import ( @@ -35,7 +35,7 @@ ) if TYPE_CHECKING: - from ...entities import ( + from ....entities import ( RootEntity, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/writers.py similarity index 97% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/writers.py index 4a241902e..f844008aa 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/database/writers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/writers.py @@ -16,21 +16,21 @@ import_module, ) -from ...events import ( +from ....events import ( Event, EventEntry, EventRepository, ) -from ...exceptions import ( +from ....exceptions import ( NotFoundException, SnapshotRepositoryConflictException, TransactionNotFoundException, ) -from ...transactions import ( +from ....transactions import ( TransactionRepository, TransactionStatus, ) -from ..entries import ( +from ...entries import ( SnapshotEntry, ) from .abc import ( @@ -41,7 +41,7 @@ ) if TYPE_CHECKING: - from ...entities import ( + from ....entities import ( RootEntity, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/memory.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py similarity index 97% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/memory.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py index c74df9a10..05d654023 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/memory.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py @@ -20,19 +20,19 @@ NotProvidedException, ) -from ..events import ( +from ...events import ( EventEntry, EventRepository, ) -from ..exceptions import ( +from ...exceptions import ( AlreadyDeletedException, NotFoundException, ) -from ..queries import ( +from ...queries import ( _Condition, _Ordering, ) -from ..transactions import ( +from ...transactions import ( TransactionEntry, TransactionRepository, TransactionStatus, @@ -42,7 +42,7 @@ ) if TYPE_CHECKING: - from ..entities import ( + from ...entities import ( RootEntity, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/services.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/services.py index cd27c022e..b77ab3f4c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/services.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/services.py @@ -30,7 +30,7 @@ enroute, ) -from .abc import ( +from .repositories import ( SnapshotRepository, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py index 6170eef89..a4757c607 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py @@ -3,6 +3,10 @@ EventRepositorySubmitTestCase, EventRepositoryTestCase, ) +from .snapshot_repository import ( + SnapshotRepositoryReaderTestCase, + SnapshotRepositoryWriterTestCase, +) from .transaction_repository import ( TransactionRepositorySelectTestCase, TransactionRepositorySubmitTestCase, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py new file mode 100644 index 000000000..0d7e017a8 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py @@ -0,0 +1,672 @@ +from abc import ( + ABC, + abstractmethod, +) +from datetime import ( + datetime, +) +from typing import ( + Optional, +) +from unittest.mock import ( + MagicMock, + call, +) +from uuid import ( + uuid4, +) + +from minos.aggregate import ( + Action, + AlreadyDeletedException, + Condition, + EventEntry, + FieldDiff, + FieldDiffContainer, + NotFoundException, + Ordering, + Ref, + RootEntity, + SnapshotEntry, + SnapshotRepository, + TransactionEntry, + TransactionStatus, +) +from minos.common import ( + current_datetime, +) +from minos.common.testing import ( + MinosTestCase, +) + + +class Owner(RootEntity): + """For testing purposes""" + + name: str + surname: str + age: Optional[int] + + +class Car(RootEntity): + """For testing purposes""" + + doors: int + color: str + owner: Optional[Ref[Owner]] + + +class SnapshotRepositoryTestCase(MinosTestCase, ABC): + snapshot_repository: SnapshotRepository + + def setUp(self) -> None: + super().setUp() + self.snapshot_repository = self.build_snapshot_repository() + + @abstractmethod + def build_snapshot_repository(self) -> SnapshotRepository: + pass + + async def asyncSetUp(self): + await super().asyncSetUp() + await self.snapshot_repository.setup() + + async def asyncTearDown(self): + await self.snapshot_repository.destroy() + await super().asyncTearDown() + + def assert_equal_snapshot_entries(self, expected: list[SnapshotEntry], observed: list[SnapshotEntry]): + self.assertEqual(len(expected), len(observed)) + for exp, obs in zip(expected, observed): + if exp.data is None: + with self.assertRaises(AlreadyDeletedException): + # noinspection PyStatementEffect + obs.build() + else: + self.assertEqual(exp.build(), obs.build()) + self.assertIsInstance(obs.created_at, datetime) + self.assertIsInstance(obs.updated_at, datetime) + + +class SnapshotRepositoryWriterTestCase(SnapshotRepositoryTestCase, ABC): + __test__ = False + + def setUp(self) -> None: + super().setUp() + self.uuid_1 = uuid4() + self.uuid_2 = uuid4() + self.uuid_3 = uuid4() + + self.transaction_1 = uuid4() + self.transaction_2 = uuid4() + self.transaction_3 = uuid4() + + async def asyncSetUp(self): + await super().asyncSetUp() + await self._populate() + + async def _populate(self): + diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) + # noinspection PyTypeChecker + name: str = Car.classname + + await self.event_repository.create(EventEntry(self.uuid_1, name, 1, diff.avro_bytes)) + await self.event_repository.update(EventEntry(self.uuid_1, name, 2, diff.avro_bytes)) + await self.event_repository.create(EventEntry(self.uuid_2, name, 1, diff.avro_bytes)) + await self.event_repository.update(EventEntry(self.uuid_1, name, 3, diff.avro_bytes)) + await self.event_repository.delete(EventEntry(self.uuid_1, name, 4)) + await self.event_repository.update(EventEntry(self.uuid_2, name, 2, diff.avro_bytes)) + await self.event_repository.update( + EventEntry(self.uuid_2, name, 3, diff.avro_bytes, transaction_uuid=self.transaction_1) + ) + await self.event_repository.delete( + EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_2) + ) + await self.event_repository.update( + EventEntry(self.uuid_2, name, 4, diff.avro_bytes, transaction_uuid=self.transaction_1) + ) + await self.event_repository.create(EventEntry(self.uuid_3, name, 1, diff.avro_bytes)) + await self.event_repository.delete( + EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_3) + ) + await self.transaction_repository.submit( + TransactionEntry(self.transaction_1, TransactionStatus.PENDING, await self.event_repository.offset) + ) + await self.transaction_repository.submit( + TransactionEntry(self.transaction_2, TransactionStatus.PENDING, await self.event_repository.offset) + ) + await self.transaction_repository.submit( + TransactionEntry(self.transaction_3, TransactionStatus.REJECTED, await self.event_repository.offset) + ) + + def test_type(self): + self.assertTrue(isinstance(self.snapshot_repository, SnapshotRepository)) + + async def test_dispatch(self): + await self.snapshot_repository.synchronize() + + # noinspection PyTypeChecker + iterable = self.snapshot_repository.find_entries( + Car.classname, Condition.TRUE, Ordering.ASC("updated_at"), exclude_deleted=False + ) + observed = [v async for v in iterable] + + # noinspection PyTypeChecker + expected = [ + SnapshotEntry(self.uuid_1, Car.classname, 4), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_2, + version=2, + created_at=observed[1].created_at, + updated_at=observed[1].updated_at, + ) + ), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[2].created_at, + updated_at=observed[2].updated_at, + ) + ), + ] + self.assert_equal_snapshot_entries(expected, observed) + + async def test_dispatch_first_transaction(self): + await self.snapshot_repository.synchronize() + + # noinspection PyTypeChecker + iterable = self.snapshot_repository.find_entries( + Car.classname, + Condition.TRUE, + Ordering.ASC("updated_at"), + exclude_deleted=False, + transaction=TransactionEntry(self.transaction_1), + ) + observed = [v async for v in iterable] + + # noinspection PyTypeChecker + expected = [ + SnapshotEntry(self.uuid_1, Car.classname, 4), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_2, + version=4, + created_at=observed[1].created_at, + updated_at=observed[1].updated_at, + ) + ), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[2].created_at, + updated_at=observed[2].updated_at, + ) + ), + ] + self.assert_equal_snapshot_entries(expected, observed) + + async def test_dispatch_second_transaction(self): + await self.snapshot_repository.synchronize() + + # noinspection PyTypeChecker + iterable = self.snapshot_repository.find_entries( + Car.classname, + Condition.TRUE, + Ordering.ASC("updated_at"), + exclude_deleted=False, + transaction=TransactionEntry(self.transaction_2), + ) + observed = [v async for v in iterable] + + # noinspection PyTypeChecker + expected = [ + SnapshotEntry(self.uuid_1, Car.classname, 4), + SnapshotEntry(self.uuid_2, Car.classname, 4), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[2].created_at, + updated_at=observed[2].updated_at, + ) + ), + ] + self.assert_equal_snapshot_entries(expected, observed) + + async def test_dispatch_third_transaction(self): + await self.snapshot_repository.synchronize() + + # noinspection PyTypeChecker + iterable = self.snapshot_repository.find_entries( + Car.classname, + Condition.TRUE, + Ordering.ASC("updated_at"), + exclude_deleted=False, + transaction_uuid=self.transaction_3, + ) + observed = [v async for v in iterable] + + # noinspection PyTypeChecker + expected = [ + SnapshotEntry(self.uuid_1, Car.classname, 4), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_2, + version=2, + created_at=observed[1].created_at, + updated_at=observed[1].updated_at, + ) + ), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[2].created_at, + updated_at=observed[2].updated_at, + ) + ), + ] + self.assert_equal_snapshot_entries(expected, observed) + + async def test_dispatch_ignore_previous_version(self): + diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) + # noinspection PyTypeChecker + name: str = Car.classname + condition = Condition.EQUAL("uuid", self.uuid_1) + + async def _fn(*args, **kwargs): + yield EventEntry(self.uuid_1, name, 1, diff.avro_bytes, 1, Action.CREATE, current_datetime()) + yield EventEntry(self.uuid_1, name, 3, diff.avro_bytes, 2, Action.CREATE, current_datetime()) + yield EventEntry(self.uuid_1, name, 2, diff.avro_bytes, 3, Action.CREATE, current_datetime()) + + self.event_repository.select = MagicMock(side_effect=_fn) + await self.snapshot_repository.synchronize() + + observed = [v async for v in self.snapshot_repository.find_entries(name, condition)] + + # noinspection PyTypeChecker + expected = [ + SnapshotEntry( + uuid=self.uuid_1, + name=name, + version=3, + schema=Car.avro_schema, + data=Car(3, "blue", uuid=self.uuid_1, version=1).avro_data, + created_at=observed[0].created_at, + updated_at=observed[0].updated_at, + ) + ] + self.assert_equal_snapshot_entries(expected, observed) + + async def test_dispatch_with_offset(self): + mock = MagicMock(side_effect=self.event_repository.select) + self.event_repository.select = mock + + await self.snapshot_repository.synchronize() + self.assertEqual(1, mock.call_count) + self.assertEqual(call(id_gt=0), mock.call_args) + mock.reset_mock() + + # noinspection PyTypeChecker + entry = EventEntry( + uuid=self.uuid_3, + name=Car.classname, + data=FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]).avro_bytes, + ) + await self.event_repository.create(entry) + + await self.snapshot_repository.synchronize() + self.assertEqual(1, mock.call_count) + self.assertEqual(call(id_gt=11), mock.call_args) + mock.reset_mock() + + await self.snapshot_repository.synchronize() + self.assertEqual(1, mock.call_count) + self.assertEqual(call(id_gt=12), mock.call_args) + mock.reset_mock() + + await self.snapshot_repository.synchronize() + self.assertEqual(1, mock.call_count) + self.assertEqual(call(id_gt=12), mock.call_args) + mock.reset_mock() + + +class SnapshotRepositoryReaderTestCase(SnapshotRepositoryTestCase, ABC): + __test__ = False + + def setUp(self) -> None: + super().setUp() + + self.uuid_1 = uuid4() + self.uuid_2 = uuid4() + self.uuid_3 = uuid4() + + self.transaction_1 = uuid4() + self.transaction_2 = uuid4() + self.transaction_3 = uuid4() + self.transaction_4 = uuid4() + + async def asyncSetUp(self): + await super().asyncSetUp() + await self._populate() + + async def _populate(self): + diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) + # noinspection PyTypeChecker + name: str = Car.classname + + await self.event_repository.create(EventEntry(self.uuid_1, name, 1, diff.avro_bytes)) + await self.event_repository.update(EventEntry(self.uuid_1, name, 2, diff.avro_bytes)) + await self.event_repository.create(EventEntry(self.uuid_2, name, 1, diff.avro_bytes)) + await self.event_repository.update(EventEntry(self.uuid_1, name, 3, diff.avro_bytes)) + await self.event_repository.delete(EventEntry(self.uuid_1, name, 4)) + await self.event_repository.update(EventEntry(self.uuid_2, name, 2, diff.avro_bytes)) + await self.event_repository.update( + EventEntry(self.uuid_2, name, 3, diff.avro_bytes, transaction_uuid=self.transaction_1) + ) + await self.event_repository.delete( + EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_2) + ) + await self.event_repository.update( + EventEntry(self.uuid_2, name, 4, diff.avro_bytes, transaction_uuid=self.transaction_1) + ) + await self.event_repository.create(EventEntry(self.uuid_3, name, 1, diff.avro_bytes)) + await self.event_repository.delete( + EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_3) + ) + await self.transaction_repository.submit( + TransactionEntry(self.transaction_1, TransactionStatus.PENDING, await self.event_repository.offset) + ) + await self.transaction_repository.submit( + TransactionEntry(self.transaction_2, TransactionStatus.PENDING, await self.event_repository.offset) + ) + await self.transaction_repository.submit( + TransactionEntry(self.transaction_3, TransactionStatus.REJECTED, await self.event_repository.offset) + ) + await self.transaction_repository.submit( + TransactionEntry( + self.transaction_4, TransactionStatus.REJECTED, await self.event_repository.offset, self.transaction_3 + ) + ) + await self.snapshot_repository.synchronize() + + async def test_find_by_uuid(self): + condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) + + iterable = self.snapshot_repository.find(Car, condition, ordering=Ordering.ASC("updated_at")) + observed = [v async for v in iterable] + + expected = [ + Car( + 3, + "blue", + uuid=self.uuid_2, + version=2, + created_at=observed[0].created_at, + updated_at=observed[0].updated_at, + ), + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[1].created_at, + updated_at=observed[1].updated_at, + ), + ] + self.assertEqual(expected, observed) + + async def test_find_with_transaction(self): + condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) + + iterable = self.snapshot_repository.find( + Car, + condition, + ordering=Ordering.ASC("updated_at"), + transaction=TransactionEntry(self.transaction_1), + ) + observed = [v async for v in iterable] + + expected = [ + Car( + 3, + "blue", + uuid=self.uuid_2, + version=4, + created_at=observed[0].created_at, + updated_at=observed[0].updated_at, + ), + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[1].created_at, + updated_at=observed[1].updated_at, + ), + ] + self.assertEqual(expected, observed) + + async def test_find_with_transaction_delete(self): + condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) + + iterable = self.snapshot_repository.find( + Car, + condition, + ordering=Ordering.ASC("updated_at"), + transaction=TransactionEntry(self.transaction_2), + ) + observed = [v async for v in iterable] + + expected = [ + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[0].created_at, + updated_at=observed[0].updated_at, + ), + ] + self.assertEqual(expected, observed) + + async def test_find_with_transaction_reverted(self): + condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) + + iterable = self.snapshot_repository.find( + Car, condition, ordering=Ordering.ASC("updated_at"), transaction_uuid=self.transaction_3 + ) + observed = [v async for v in iterable] + + expected = [ + Car( + 3, + "blue", + uuid=self.uuid_2, + version=2, + created_at=observed[0].created_at, + updated_at=observed[0].updated_at, + ), + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[1].created_at, + updated_at=observed[1].updated_at, + ), + ] + self.assertEqual(expected, observed) + + async def test_find_streaming_true(self): + condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) + + iterable = self.snapshot_repository.find( + Car, condition, streaming_mode=True, ordering=Ordering.ASC("updated_at") + ) + observed = [v async for v in iterable] + + expected = [ + Car( + 3, + "blue", + uuid=self.uuid_2, + version=2, + created_at=observed[0].created_at, + updated_at=observed[0].updated_at, + ), + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[1].created_at, + updated_at=observed[1].updated_at, + ), + ] + self.assertEqual(expected, observed) + + async def test_find_with_duplicates(self): + uuids = [self.uuid_2, self.uuid_2, self.uuid_3] + condition = Condition.IN("uuid", uuids) + + iterable = self.snapshot_repository.find(Car, condition, ordering=Ordering.ASC("updated_at")) + observed = [v async for v in iterable] + + expected = [ + Car( + 3, + "blue", + uuid=self.uuid_2, + version=2, + created_at=observed[0].created_at, + updated_at=observed[0].updated_at, + ), + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[1].created_at, + updated_at=observed[1].updated_at, + ), + ] + self.assertEqual(expected, observed) + + async def test_find_empty(self): + + observed = {v async for v in self.snapshot_repository.find(Car, Condition.FALSE)} + + expected = set() + self.assertEqual(expected, observed) + + async def test_get(self): + + observed = await self.snapshot_repository.get(Car, self.uuid_2) + + expected = Car( + 3, "blue", uuid=self.uuid_2, version=2, created_at=observed.created_at, updated_at=observed.updated_at + ) + self.assertEqual(expected, observed) + + async def test_get_with_transaction(self): + + observed = await self.snapshot_repository.get( + Car, self.uuid_2, transaction=TransactionEntry(self.transaction_1) + ) + + expected = Car( + 3, "blue", uuid=self.uuid_2, version=4, created_at=observed.created_at, updated_at=observed.updated_at + ) + self.assertEqual(expected, observed) + + async def test_get_raises(self): + + with self.assertRaises(AlreadyDeletedException): + await self.snapshot_repository.get(Car, self.uuid_1) + with self.assertRaises(NotFoundException): + await self.snapshot_repository.get(Car, uuid4()) + + async def test_get_with_transaction_raises(self): + + with self.assertRaises(AlreadyDeletedException): + await self.snapshot_repository.get(Car, self.uuid_2, transaction=TransactionEntry(self.transaction_2)) + + async def test_find(self): + condition = Condition.EQUAL("color", "blue") + iterable = self.snapshot_repository.find(Car, condition, ordering=Ordering.ASC("updated_at")) + observed = [v async for v in iterable] + + expected = [ + Car( + 3, + "blue", + uuid=self.uuid_2, + version=2, + created_at=observed[0].created_at, + updated_at=observed[0].updated_at, + ), + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[1].created_at, + updated_at=observed[1].updated_at, + ), + ] + self.assertEqual(expected, observed) + + async def test_find_all(self): + + iterable = self.snapshot_repository.find(Car, Condition.TRUE, Ordering.ASC("updated_at")) + observed = [v async for v in iterable] + + expected = [ + Car( + 3, + "blue", + uuid=self.uuid_2, + version=2, + created_at=observed[0].created_at, + updated_at=observed[0].updated_at, + ), + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=observed[1].created_at, + updated_at=observed[1].updated_at, + ), + ] + self.assertEqual(expected, observed) + + def _assert_equal_snapshot_entries(self, expected: list[SnapshotEntry], observed: list[SnapshotEntry]): + self.assertEqual(len(expected), len(observed)) + for exp, obs in zip(expected, observed): + if exp.data is None: + with self.assertRaises(AlreadyDeletedException): + # noinspection PyStatementEffect + obs.build() + else: + self.assertEqual(exp.build(), obs.build()) + self.assertIsInstance(obs.created_at, datetime) + self.assertIsInstance(obs.updated_at, datetime) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py deleted file mode 100644 index d0a5887a0..000000000 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_memory.py +++ /dev/null @@ -1,359 +0,0 @@ -import unittest -from datetime import ( - datetime, -) -from uuid import ( - uuid4, -) - -from minos.aggregate import ( - AlreadyDeletedException, - Condition, - EventEntry, - FieldDiff, - FieldDiffContainer, - InMemorySnapshotRepository, - NotFoundException, - Ordering, - SnapshotEntry, - SnapshotRepository, - TransactionEntry, - TransactionStatus, -) -from minos.common import ( - NotProvidedException, -) -from tests.utils import ( - AggregateTestCase, - Car, -) - - -class TestInMemorySnapshotRepository(AggregateTestCase): - def setUp(self) -> None: - super().setUp() - - self.uuid_1 = uuid4() - self.uuid_2 = uuid4() - self.uuid_3 = uuid4() - - self.transaction_1 = uuid4() - self.transaction_2 = uuid4() - self.transaction_3 = uuid4() - self.transaction_4 = uuid4() - - async def asyncSetUp(self): - await super().asyncSetUp() - await self._populate() - - async def _populate(self): - diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) - # noinspection PyTypeChecker - name: str = Car.classname - await self.event_repository.create(EventEntry(self.uuid_1, name, 1, diff.avro_bytes)) - await self.event_repository.update(EventEntry(self.uuid_1, name, 2, diff.avro_bytes)) - await self.event_repository.create(EventEntry(self.uuid_2, name, 1, diff.avro_bytes)) - await self.event_repository.update(EventEntry(self.uuid_1, name, 3, diff.avro_bytes)) - await self.event_repository.delete(EventEntry(self.uuid_1, name, 4)) - await self.event_repository.update(EventEntry(self.uuid_2, name, 2, diff.avro_bytes)) - await self.event_repository.update( - EventEntry(self.uuid_2, name, 3, diff.avro_bytes, transaction_uuid=self.transaction_1) - ) - await self.event_repository.delete( - EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_2) - ) - await self.event_repository.update( - EventEntry(self.uuid_2, name, 4, diff.avro_bytes, transaction_uuid=self.transaction_1) - ) - await self.event_repository.create(EventEntry(self.uuid_3, name, 1, diff.avro_bytes)) - await self.event_repository.delete( - EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_3) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_1, TransactionStatus.PENDING, await self.event_repository.offset) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_2, TransactionStatus.PENDING, await self.event_repository.offset) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_3, TransactionStatus.REJECTED, await self.event_repository.offset) - ) - await self.transaction_repository.submit( - TransactionEntry( - self.transaction_4, TransactionStatus.REJECTED, await self.event_repository.offset, self.transaction_3 - ) - ) - - def test_type(self): - self.assertTrue(issubclass(InMemorySnapshotRepository, SnapshotRepository)) - - def test_constructor_raises(self): - with self.assertRaises(NotProvidedException): - # noinspection PyTypeChecker - InMemorySnapshotRepository(event_repository=None) - - with self.assertRaises(NotProvidedException): - # noinspection PyTypeChecker - InMemorySnapshotRepository(transaction_repository=None) - - async def test_find_by_uuid(self): - condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - iterable = self.snapshot_repository.find("tests.utils.Car", condition, ordering=Ordering.ASC("updated_at")) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_with_transaction(self): - condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - iterable = self.snapshot_repository.find( - "tests.utils.Car", - condition, - ordering=Ordering.ASC("updated_at"), - transaction=TransactionEntry(self.transaction_1), - ) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=4, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_with_transaction_delete(self): - condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - iterable = self.snapshot_repository.find( - "tests.utils.Car", - condition, - ordering=Ordering.ASC("updated_at"), - transaction=TransactionEntry(self.transaction_2), - ) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_with_transaction_reverted(self): - condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - iterable = self.snapshot_repository.find( - "tests.utils.Car", - condition, - ordering=Ordering.ASC("updated_at"), - transaction=TransactionEntry(self.transaction_4), - ) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_streaming_true(self): - condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - - iterable = self.snapshot_repository.find( - "tests.utils.Car", condition, streaming_mode=True, ordering=Ordering.ASC("updated_at") - ) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_with_duplicates(self): - uuids = [self.uuid_2, self.uuid_2, self.uuid_3] - condition = Condition.IN("uuid", uuids) - iterable = self.snapshot_repository.find("tests.utils.Car", condition, ordering=Ordering.ASC("updated_at")) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_empty(self): - observed = {v async for v in self.snapshot_repository.find("tests.utils.Car", Condition.FALSE)} - - expected = set() - self.assertEqual(expected, observed) - - async def test_get(self): - observed = await self.snapshot_repository.get("tests.utils.Car", self.uuid_2) - - expected = Car( - 3, "blue", uuid=self.uuid_2, version=2, created_at=observed.created_at, updated_at=observed.updated_at - ) - self.assertEqual(expected, observed) - - async def test_get_with_transaction(self): - observed = await self.snapshot_repository.get( - "tests.utils.Car", self.uuid_2, transaction=TransactionEntry(self.transaction_1) - ) - - expected = Car( - 3, "blue", uuid=self.uuid_2, version=4, created_at=observed.created_at, updated_at=observed.updated_at - ) - self.assertEqual(expected, observed) - - async def test_get_raises(self): - with self.assertRaises(AlreadyDeletedException): - await self.snapshot_repository.get("tests.utils.Car", self.uuid_1) - with self.assertRaises(NotFoundException): - await self.snapshot_repository.get("tests.utils.Car", uuid4()) - - async def test_get_with_transaction_raises(self): - with self.assertRaises(AlreadyDeletedException): - await self.snapshot_repository.get( - "tests.utils.Car", self.uuid_2, transaction=TransactionEntry(self.transaction_2) - ) - - async def test_find(self): - condition = Condition.EQUAL("color", "blue") - iterable = self.snapshot_repository.find("tests.utils.Car", condition, ordering=Ordering.ASC("updated_at")) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_all(self): - iterable = self.snapshot_repository.find("tests.utils.Car", Condition.TRUE, Ordering.ASC("updated_at")) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - def _assert_equal_snapshot_entries(self, expected: list[SnapshotEntry], observed: list[SnapshotEntry]): - self.assertEqual(len(expected), len(observed)) - for exp, obs in zip(expected, observed): - if exp.data is None: - with self.assertRaises(AlreadyDeletedException): - # noinspection PyStatementEffect - obs.build() - else: - self.assertEqual(exp.build(), obs.build()) - self.assertIsInstance(obs.created_at, datetime) - self.assertIsInstance(obs.updated_at, datetime) - - -if __name__ == "__main__": - unittest.main() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py deleted file mode 100644 index 4967654e6..000000000 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_abc.py +++ /dev/null @@ -1,48 +0,0 @@ -import unittest - -from minos.aggregate import ( - DatabaseSnapshotSetup, -) -from minos.common.testing import ( - DatabaseMinosTestCase, -) -from tests.utils import ( - AggregateTestCase, -) - - -# noinspection SqlNoDataSourceInspection -@unittest.skip -class TestDatabaseSnapshotSetup(AggregateTestCase, DatabaseMinosTestCase): - async def test_setup_snapshot_table(self): - async with DatabaseSnapshotSetup.from_config(self.config): - async with self.get_client() as client: - from minos.plugins.aiopg import ( - AiopgDatabaseOperation, - ) - - operation = AiopgDatabaseOperation( - "SELECT EXISTS (SELECT FROM pg_tables WHERE schemaname = 'public' AND tablename = 'snapshot');" - ) - await client.execute(operation) - observed = (await client.fetch_one())[0] - self.assertEqual(True, observed) - - async def test_setup_snapshot_aux_offset_table(self): - async with DatabaseSnapshotSetup.from_config(self.config): - async with self.get_client() as client: - from minos.plugins.aiopg import ( - AiopgDatabaseOperation, - ) - - operation = AiopgDatabaseOperation( - "SELECT EXISTS (SELECT FROM pg_tables WHERE " - "schemaname = 'public' AND tablename = 'snapshot_aux_offset');" - ) - await client.execute(operation) - observed = (await client.fetch_one())[0] - self.assertEqual(True, observed) - - -if __name__ == "__main__": - unittest.main() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py deleted file mode 100644 index 81fa4ee9c..000000000 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_readers.py +++ /dev/null @@ -1,369 +0,0 @@ -import unittest -from datetime import ( - datetime, -) -from uuid import ( - uuid4, -) - -from minos.aggregate import ( - AlreadyDeletedException, - Condition, - DatabaseSnapshotReader, - DatabaseSnapshotSetup, - DatabaseSnapshotWriter, - EventEntry, - FieldDiff, - FieldDiffContainer, - NotFoundException, - Ordering, - SnapshotEntry, - TransactionEntry, - TransactionStatus, -) -from minos.common import ( - DatabaseClientPool, -) -from minos.common.testing import ( - DatabaseMinosTestCase, -) -from tests.utils import ( - AggregateTestCase, - Car, -) - - -@unittest.skip -class TestDatabaseSnapshotReader(AggregateTestCase, DatabaseMinosTestCase): - def setUp(self) -> None: - super().setUp() - - self.uuid_1 = uuid4() - self.uuid_2 = uuid4() - self.uuid_3 = uuid4() - - self.transaction_1 = uuid4() - self.transaction_2 = uuid4() - self.transaction_3 = uuid4() - - self.reader = DatabaseSnapshotReader.from_config(self.config) - - async def asyncSetUp(self): - await super().asyncSetUp() - await self.reader.setup() - await self._populate() - - async def asyncTearDown(self): - await self.reader.destroy() - await super().asyncTearDown() - - async def _populate(self): - diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) - # noinspection PyTypeChecker - name: str = Car.classname - - await self.event_repository.create(EventEntry(self.uuid_1, name, 1, diff.avro_bytes)) - await self.event_repository.update(EventEntry(self.uuid_1, name, 2, diff.avro_bytes)) - await self.event_repository.create(EventEntry(self.uuid_2, name, 1, diff.avro_bytes)) - await self.event_repository.update(EventEntry(self.uuid_1, name, 3, diff.avro_bytes)) - await self.event_repository.delete(EventEntry(self.uuid_1, name, 4)) - await self.event_repository.update(EventEntry(self.uuid_2, name, 2, diff.avro_bytes)) - await self.event_repository.update( - EventEntry(self.uuid_2, name, 3, diff.avro_bytes, transaction_uuid=self.transaction_1) - ) - await self.event_repository.delete( - EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_2) - ) - await self.event_repository.update( - EventEntry(self.uuid_2, name, 4, diff.avro_bytes, transaction_uuid=self.transaction_1) - ) - await self.event_repository.create(EventEntry(self.uuid_3, name, 1, diff.avro_bytes)) - await self.event_repository.delete( - EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_3) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_1, TransactionStatus.PENDING, await self.event_repository.offset) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_2, TransactionStatus.PENDING, await self.event_repository.offset) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_3, TransactionStatus.REJECTED, await self.event_repository.offset) - ) - async with DatabaseSnapshotWriter.from_config(self.config, reader=self.reader) as writer: - await writer.dispatch() - - def test_type(self): - self.assertTrue(issubclass(DatabaseSnapshotReader, DatabaseSnapshotSetup)) - - def test_from_config(self): - reader = DatabaseSnapshotReader.from_config(self.config) - self.assertIsInstance(reader.database_pool, DatabaseClientPool) - - async def test_find_by_uuid(self): - condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - - iterable = self.reader.find("tests.utils.Car", condition, ordering=Ordering.ASC("updated_at")) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_with_transaction(self): - condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - - iterable = self.reader.find( - "tests.utils.Car", - condition, - ordering=Ordering.ASC("updated_at"), - transaction=TransactionEntry(self.transaction_1), - ) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=4, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_with_transaction_delete(self): - condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - - iterable = self.reader.find( - "tests.utils.Car", - condition, - ordering=Ordering.ASC("updated_at"), - transaction=TransactionEntry(self.transaction_2), - ) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_with_transaction_reverted(self): - condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - - iterable = self.reader.find( - "tests.utils.Car", condition, ordering=Ordering.ASC("updated_at"), transaction_uuid=self.transaction_3 - ) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_streaming_true(self): - condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - - iterable = self.reader.find( - "tests.utils.Car", condition, streaming_mode=True, ordering=Ordering.ASC("updated_at") - ) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_with_duplicates(self): - uuids = [self.uuid_2, self.uuid_2, self.uuid_3] - condition = Condition.IN("uuid", uuids) - - iterable = self.reader.find("tests.utils.Car", condition, ordering=Ordering.ASC("updated_at")) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_empty(self): - - observed = {v async for v in self.reader.find("tests.utils.Car", Condition.FALSE)} - - expected = set() - self.assertEqual(expected, observed) - - async def test_get(self): - - observed = await self.reader.get("tests.utils.Car", self.uuid_2) - - expected = Car( - 3, "blue", uuid=self.uuid_2, version=2, created_at=observed.created_at, updated_at=observed.updated_at - ) - self.assertEqual(expected, observed) - - async def test_get_with_transaction(self): - - observed = await self.reader.get( - "tests.utils.Car", self.uuid_2, transaction=TransactionEntry(self.transaction_1) - ) - - expected = Car( - 3, "blue", uuid=self.uuid_2, version=4, created_at=observed.created_at, updated_at=observed.updated_at - ) - self.assertEqual(expected, observed) - - async def test_get_raises(self): - - with self.assertRaises(AlreadyDeletedException): - await self.reader.get("tests.utils.Car", self.uuid_1) - with self.assertRaises(NotFoundException): - await self.reader.get("tests.utils.Car", uuid4()) - - async def test_get_with_transaction_raises(self): - - with self.assertRaises(AlreadyDeletedException): - await self.reader.get("tests.utils.Car", self.uuid_2, transaction=TransactionEntry(self.transaction_2)) - - async def test_find(self): - condition = Condition.EQUAL("color", "blue") - iterable = self.reader.find("tests.utils.Car", condition, ordering=Ordering.ASC("updated_at")) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - async def test_find_all(self): - - iterable = self.reader.find("tests.utils.Car", Condition.TRUE, Ordering.ASC("updated_at")) - observed = [v async for v in iterable] - - expected = [ - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ), - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ), - ] - self.assertEqual(expected, observed) - - def _assert_equal_snapshot_entries(self, expected: list[SnapshotEntry], observed: list[SnapshotEntry]): - self.assertEqual(len(expected), len(observed)) - for exp, obs in zip(expected, observed): - if exp.data is None: - with self.assertRaises(AlreadyDeletedException): - # noinspection PyStatementEffect - obs.build() - else: - self.assertEqual(exp.build(), obs.build()) - self.assertIsInstance(obs.created_at, datetime) - self.assertIsInstance(obs.updated_at, datetime) - - -if __name__ == "__main__": - unittest.main() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py deleted file mode 100644 index 2c8ed7566..000000000 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_writers.py +++ /dev/null @@ -1,339 +0,0 @@ -import unittest -from datetime import ( - datetime, -) -from unittest.mock import ( - MagicMock, - call, -) -from uuid import ( - uuid4, -) - -from minos.aggregate import ( - Action, - AlreadyDeletedException, - Condition, - DatabaseSnapshotReader, - DatabaseSnapshotSetup, - DatabaseSnapshotWriter, - EventEntry, - FieldDiff, - FieldDiffContainer, - Ordering, - SnapshotEntry, - TransactionEntry, - TransactionStatus, -) -from minos.common import ( - DatabaseClientPool, - NotProvidedException, - current_datetime, -) -from minos.common.testing import ( - DatabaseMinosTestCase, -) -from tests.utils import ( - AggregateTestCase, - Car, -) - - -@unittest.skip -class TestDatabaseSnapshotWriter(AggregateTestCase, DatabaseMinosTestCase): - def setUp(self) -> None: - super().setUp() - self.uuid_1 = uuid4() - self.uuid_2 = uuid4() - self.uuid_3 = uuid4() - - self.transaction_1 = uuid4() - self.transaction_2 = uuid4() - self.transaction_3 = uuid4() - - self.reader = DatabaseSnapshotReader.from_config(self.config) - self.writer = DatabaseSnapshotWriter.from_config(self.config, reader=self.reader) - - async def asyncSetUp(self): - await super().asyncSetUp() - await self.writer.setup() - await self.reader.setup() - await self._populate() - - async def asyncTearDown(self): - await self.reader.destroy() - await self.writer.destroy() - await super().asyncTearDown() - - async def _populate(self): - diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) - # noinspection PyTypeChecker - name: str = Car.classname - - await self.event_repository.create(EventEntry(self.uuid_1, name, 1, diff.avro_bytes)) - await self.event_repository.update(EventEntry(self.uuid_1, name, 2, diff.avro_bytes)) - await self.event_repository.create(EventEntry(self.uuid_2, name, 1, diff.avro_bytes)) - await self.event_repository.update(EventEntry(self.uuid_1, name, 3, diff.avro_bytes)) - await self.event_repository.delete(EventEntry(self.uuid_1, name, 4)) - await self.event_repository.update(EventEntry(self.uuid_2, name, 2, diff.avro_bytes)) - await self.event_repository.update( - EventEntry(self.uuid_2, name, 3, diff.avro_bytes, transaction_uuid=self.transaction_1) - ) - await self.event_repository.delete( - EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_2) - ) - await self.event_repository.update( - EventEntry(self.uuid_2, name, 4, diff.avro_bytes, transaction_uuid=self.transaction_1) - ) - await self.event_repository.create(EventEntry(self.uuid_3, name, 1, diff.avro_bytes)) - await self.event_repository.delete( - EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_3) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_1, TransactionStatus.PENDING, await self.event_repository.offset) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_2, TransactionStatus.PENDING, await self.event_repository.offset) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_3, TransactionStatus.REJECTED, await self.event_repository.offset) - ) - - def test_type(self): - self.assertTrue(issubclass(DatabaseSnapshotWriter, DatabaseSnapshotSetup)) - - def test_from_config(self): - self.assertIsInstance(self.writer.database_pool, DatabaseClientPool) - - def test_from_config_raises(self): - with self.assertRaises(NotProvidedException): - DatabaseSnapshotWriter.from_config(self.config, reader=self.reader, event_repository=None) - - with self.assertRaises(NotProvidedException): - DatabaseSnapshotWriter.from_config(self.config, reader=self.reader, transaction_repository=None) - - async def test_dispatch(self): - await self.writer.dispatch() - - # noinspection PyTypeChecker - iterable = self.reader.find_entries( - Car.classname, Condition.TRUE, Ordering.ASC("updated_at"), exclude_deleted=False - ) - observed = [v async for v in iterable] - - # noinspection PyTypeChecker - expected = [ - SnapshotEntry(self.uuid_1, Car.classname, 4), - SnapshotEntry.from_root_entity( - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ) - ), - SnapshotEntry.from_root_entity( - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[2].created_at, - updated_at=observed[2].updated_at, - ) - ), - ] - self._assert_equal_snapshot_entries(expected, observed) - - async def test_dispatch_first_transaction(self): - await self.writer.dispatch() - - # noinspection PyTypeChecker - iterable = self.reader.find_entries( - Car.classname, - Condition.TRUE, - Ordering.ASC("updated_at"), - exclude_deleted=False, - transaction=TransactionEntry(self.transaction_1), - ) - observed = [v async for v in iterable] - - # noinspection PyTypeChecker - expected = [ - SnapshotEntry(self.uuid_1, Car.classname, 4), - SnapshotEntry.from_root_entity( - Car( - 3, - "blue", - uuid=self.uuid_2, - version=4, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ) - ), - SnapshotEntry.from_root_entity( - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[2].created_at, - updated_at=observed[2].updated_at, - ) - ), - ] - self._assert_equal_snapshot_entries(expected, observed) - - async def test_dispatch_second_transaction(self): - await self.writer.dispatch() - - # noinspection PyTypeChecker - iterable = self.reader.find_entries( - Car.classname, - Condition.TRUE, - Ordering.ASC("updated_at"), - exclude_deleted=False, - transaction=TransactionEntry(self.transaction_2), - ) - observed = [v async for v in iterable] - - # noinspection PyTypeChecker - expected = [ - SnapshotEntry(self.uuid_1, Car.classname, 4), - SnapshotEntry(self.uuid_2, Car.classname, 4), - SnapshotEntry.from_root_entity( - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[2].created_at, - updated_at=observed[2].updated_at, - ) - ), - ] - self._assert_equal_snapshot_entries(expected, observed) - - async def test_dispatch_third_transaction(self): - await self.writer.dispatch() - - # noinspection PyTypeChecker - iterable = self.reader.find_entries( - Car.classname, - Condition.TRUE, - Ordering.ASC("updated_at"), - exclude_deleted=False, - transaction_uuid=self.transaction_3, - ) - observed = [v async for v in iterable] - - # noinspection PyTypeChecker - expected = [ - SnapshotEntry(self.uuid_1, Car.classname, 4), - SnapshotEntry.from_root_entity( - Car( - 3, - "blue", - uuid=self.uuid_2, - version=2, - created_at=observed[1].created_at, - updated_at=observed[1].updated_at, - ) - ), - SnapshotEntry.from_root_entity( - Car( - 3, - "blue", - uuid=self.uuid_3, - version=1, - created_at=observed[2].created_at, - updated_at=observed[2].updated_at, - ) - ), - ] - self._assert_equal_snapshot_entries(expected, observed) - - async def test_is_synced(self): - self.assertFalse(await self.writer.is_synced("tests.utils.Car")) - await self.writer.dispatch() - self.assertTrue(await self.writer.is_synced("tests.utils.Car")) - - async def test_dispatch_ignore_previous_version(self): - diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) - # noinspection PyTypeChecker - name: str = Car.classname - condition = Condition.EQUAL("uuid", self.uuid_1) - - async def _fn(*args, **kwargs): - yield EventEntry(self.uuid_1, name, 1, diff.avro_bytes, 1, Action.CREATE, current_datetime()) - yield EventEntry(self.uuid_1, name, 3, diff.avro_bytes, 2, Action.CREATE, current_datetime()) - yield EventEntry(self.uuid_1, name, 2, diff.avro_bytes, 3, Action.CREATE, current_datetime()) - - self.event_repository.select = MagicMock(side_effect=_fn) - await self.writer.dispatch() - - observed = [v async for v in self.reader.find_entries(name, condition)] - - # noinspection PyTypeChecker - expected = [ - SnapshotEntry( - uuid=self.uuid_1, - name=name, - version=3, - schema=Car.avro_schema, - data=Car(3, "blue", uuid=self.uuid_1, version=1).avro_data, - created_at=observed[0].created_at, - updated_at=observed[0].updated_at, - ) - ] - self._assert_equal_snapshot_entries(expected, observed) - - def _assert_equal_snapshot_entries(self, expected: list[SnapshotEntry], observed: list[SnapshotEntry]): - self.assertEqual(len(expected), len(observed)) - for exp, obs in zip(expected, observed): - if exp.data is None: - with self.assertRaises(AlreadyDeletedException): - # noinspection PyStatementEffect - obs.build() - else: - self.assertEqual(exp.build(), obs.build()) - self.assertIsInstance(obs.created_at, datetime) - self.assertIsInstance(obs.updated_at, datetime) - - async def test_dispatch_with_offset(self): - mock = MagicMock(side_effect=self.writer._event_repository.select) - self.writer._event_repository.select = mock - - await self.writer.dispatch() - self.assertEqual(1, mock.call_count) - self.assertEqual(call(id_gt=0), mock.call_args) - mock.reset_mock() - - # noinspection PyTypeChecker - entry = EventEntry( - uuid=self.uuid_3, - name=Car.classname, - data=FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]).avro_bytes, - ) - await self.event_repository.create(entry) - - await self.writer.dispatch() - self.assertEqual(1, mock.call_count) - self.assertEqual(call(id_gt=11), mock.call_args) - mock.reset_mock() - - await self.writer.dispatch() - self.assertEqual(1, mock.call_count) - self.assertEqual(call(id_gt=12), mock.call_args) - mock.reset_mock() - - await self.writer.dispatch() - self.assertEqual(1, mock.call_count) - self.assertEqual(call(id_gt=12), mock.call_args) - mock.reset_mock() - - -if __name__ == "__main__": - unittest.main() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/__init__.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_abc.py similarity index 100% rename from packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_abc.py rename to packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_abc.py diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py new file mode 100644 index 000000000..57727a28d --- /dev/null +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py @@ -0,0 +1,35 @@ +import unittest + +from minos.aggregate import ( + InMemorySnapshotRepository, + SnapshotRepository, +) +from minos.aggregate.testing import ( + SnapshotRepositoryReaderTestCase, +) +from minos.common import ( + NotProvidedException, +) +from tests.utils import ( + AggregateTestCase, +) + + +class TestInMemorySnapshotRepositoryReader(AggregateTestCase, SnapshotRepositoryReaderTestCase): + __test__ = True + + def build_snapshot_repository(self) -> SnapshotRepository: + return InMemorySnapshotRepository() + + def test_constructor_raises(self): + with self.assertRaises(NotProvidedException): + # noinspection PyTypeChecker + InMemorySnapshotRepository(event_repository=None) + + with self.assertRaises(NotProvidedException): + # noinspection PyTypeChecker + InMemorySnapshotRepository(transaction_repository=None) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/__init__.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/__init__.py similarity index 100% rename from packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/__init__.py rename to packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/__init__.py diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/test_api.py similarity index 100% rename from packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_pg/test_api.py rename to packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/test_api.py diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py new file mode 100644 index 000000000..adcb1359c --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py @@ -0,0 +1,59 @@ +import unittest + +from minos.aggregate import ( + DatabaseSnapshotRepository, +) +from minos.aggregate.testing import ( + SnapshotRepositoryReaderTestCase, + SnapshotRepositoryWriterTestCase, +) +from minos.aggregate.testing.snapshot_repository import Car +from minos.plugins.aiopg import ( + AiopgDatabaseOperation, +) +from tests.utils import ( + AiopgTestCase, +) + + +# noinspection SqlNoDataSourceInspection +class TestDatabaseSnapshotRepositoryWriter(AiopgTestCase, SnapshotRepositoryWriterTestCase): + __test__ = True + + def build_snapshot_repository(self): + return DatabaseSnapshotRepository.from_config(self.config) + + async def test_setup_snapshot_table(self): + async with self.get_client() as client: + operation = AiopgDatabaseOperation( + "SELECT EXISTS (SELECT FROM pg_tables WHERE schemaname = 'public' AND tablename = 'snapshot');" + ) + await client.execute(operation) + observed = (await client.fetch_one())[0] + self.assertEqual(True, observed) + + async def test_setup_snapshot_aux_offset_table(self): + async with self.get_client() as client: + operation = AiopgDatabaseOperation( + "SELECT EXISTS (SELECT FROM pg_tables WHERE " + "schemaname = 'public' AND tablename = 'snapshot_aux_offset');" + ) + await client.execute(operation) + observed = (await client.fetch_one())[0] + self.assertEqual(True, observed) + + async def test_is_synced(self): + self.assertFalse(await self.snapshot_repository.is_synced(Car)) + await self.snapshot_repository.synchronize() + self.assertTrue(await self.snapshot_repository.is_synced(Car)) + + +class TestDatabaseSnapshotReader(AiopgTestCase, SnapshotRepositoryReaderTestCase): + __test__ = True + + def build_snapshot_repository(self): + return DatabaseSnapshotRepository.from_config(self.config) + + +if __name__ == "__main__": + unittest.main() From ca779870e8a17679026991b7d26577eb3d2efe97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 13:16:25 +0200 Subject: [PATCH 208/324] ISSUE #98 * Reformat code. --- .../test_factories/test_aggregate/test_snapshots/test_pg.py | 4 +++- .../test_aggregate/test_transactions/test_pg.py | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py index adcb1359c..e368497bf 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py @@ -7,7 +7,9 @@ SnapshotRepositoryReaderTestCase, SnapshotRepositoryWriterTestCase, ) -from minos.aggregate.testing.snapshot_repository import Car +from minos.aggregate.testing.snapshot_repository import ( + Car, +) from minos.plugins.aiopg import ( AiopgDatabaseOperation, ) diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py index 7402d277e..2d2ab55ac 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py @@ -1,4 +1,5 @@ import unittest + from minos.aggregate import ( DatabaseTransactionRepository, TransactionRepository, From 270d92d630ffc8a813183ded1058912d6cda6ca6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 13:17:50 +0200 Subject: [PATCH 209/324] ISSUE #98 * Add `minos-database-aiopg` to `pre-commit` config. --- .pre-commit-config.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 500b9a919..84470da60 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -44,6 +44,13 @@ repos: files: ^packages/plugins/minos-broker-kafka/ language: system + - id: minos-database-aiopg-check + pass_filenames: false + entry: make --directory=packages/plugins/minos-database-aiopg check + name: Check minos-database-aiopg + files: ^packages/plugins/minos-database-aiopg/ + language: system + - id: minos-discovery-minos-check pass_filenames: false entry: make --directory=packages/plugins/minos-discovery-minos check From 8c51a04c3279810b2dfbc11cc5131d125834fdf6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 13:41:52 +0200 Subject: [PATCH 210/324] Update packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py --- .../minos-discovery-kong/minos/plugins/kong/__init__.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index b85decac2..11acb787a 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -2,8 +2,10 @@ __email__ = "hey@minos.run" __version__ = "0.1.0a1" -from .discovery import ( +from .client import ( KongClient, +) +from .discovery import ( KongDiscoveryClient, ) from .middleware import ( From 66a932bccaf7dec397dc2584bae594de86d91e76 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 13:44:31 +0200 Subject: [PATCH 211/324] Apply suggestions from code review --- .../tests/test_graphql/test_decorators.py | 6 +----- packages/plugins/minos-router-graphql/tests/utils.py | 6 +----- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py b/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py index 74cc3e8e6..d08c1d7ad 100644 --- a/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py +++ b/packages/plugins/minos-router-graphql/tests/test_graphql/test_decorators.py @@ -47,11 +47,7 @@ def test_get_all_queries_with_kwargs(self): name="order", argument=GraphQLField(GraphQLString), output=GraphQLString, - authorized=True, - allowed_groups=[ - "foo", - "bar", - ], + foo="bar", ) }, } diff --git a/packages/plugins/minos-router-graphql/tests/utils.py b/packages/plugins/minos-router-graphql/tests/utils.py index 878333663..3d994165e 100644 --- a/packages/plugins/minos-router-graphql/tests/utils.py +++ b/packages/plugins/minos-router-graphql/tests/utils.py @@ -87,11 +87,7 @@ class FakeQueryService2: name="order", argument=GraphQLField(GraphQLString), output=GraphQLString, - authorized=True, - allowed_groups=[ - "foo", - "bar", - ], + foo="bar", ) def get_order(self, request: Request): """For testng purposes.""" From 4ab59d803a4a0c49446a6b1c6b414c9aad21391b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 13:56:02 +0200 Subject: [PATCH 212/324] ISSUE #373 * Minor improvement. --- .../test_networks/test_decorators/test_api.py | 38 ++----------------- .../test_decorators/test_collectors.py | 12 +----- 2 files changed, 5 insertions(+), 45 deletions(-) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py index ac9ba4ac4..739baf92b 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_api.py @@ -20,24 +20,9 @@ def test_rest_command_kwargs(self): decorator = enroute.rest.command( path="tickets/", method="GET", - authorized=True, - allowed_groups=[ - "super_admin", - "admin", - ], - ) - self.assertEqual( - RestCommandEnrouteDecorator( - "tickets/", - "GET", - authorized=True, - allowed_groups=[ - "super_admin", - "admin", - ], - ), - decorator, + foo="bar", ) + self.assertEqual({"foo": "bar"}, decorator.kwargs) def test_rest_query(self): decorator = enroute.rest.query(path="tickets/", method="GET") @@ -47,24 +32,9 @@ def test_rest_query_kwargs(self): decorator = enroute.rest.query( path="tickets/", method="GET", - authorized=True, - allowed_groups=[ - "super_admin", - "admin", - ], - ) - self.assertEqual( - RestQueryEnrouteDecorator( - "tickets/", - "GET", - authorized=True, - allowed_groups=[ - "super_admin", - "admin", - ], - ), - decorator, + foo="bar", ) + self.assertEqual({"foo": "bar"}, decorator.kwargs) def test_rest_event_raises(self): with self.assertRaises(AttributeError): diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py index 2f531d0a0..298d1f71d 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_decorators/test_collectors.py @@ -68,17 +68,7 @@ def test_get_rest_command_query_kwargs(self): observed = analyzer.get_rest_command_query() expected = { - "get_tickets": { - RestQueryEnrouteDecorator( - self.ticket_route, - "GET", - authorized=True, - allowed_groups=[ - "super_admin", - "admin", - ], - ) - }, + "get_tickets": {RestQueryEnrouteDecorator(self.ticket_route, "GET", foo="bar")}, } self.assertEqual(expected, observed) From 7bc3fb37150193d2b4b180123120bf15931b8eea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 15:31:26 +0200 Subject: [PATCH 213/324] ISSUE #98 * Move lock tests from `minos-database-aiopg` to `minos-microservice-common`. --- .../minos/common/database/clients/abc.py | 4 + .../test_database/test_clients/test_abc.py | 106 ++++++++++++++---- .../minos/plugins/aiopg/clients.py | 3 +- .../tests/test_aiopg/test_clients.py | 48 -------- 4 files changed, 90 insertions(+), 71 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 37c707434..90e95cd33 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -67,6 +67,10 @@ async def is_valid(self, **kwargs) -> bool: async def _is_valid(self, **kwargs) -> bool: raise NotImplementedError + async def _destroy(self) -> None: + await self.reset() + await super()._destroy() + async def reset(self, **kwargs) -> None: """Reset the current instance status. diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index 239025c28..9398a5c36 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -10,6 +10,7 @@ AsyncMock, MagicMock, call, + patch, ) from minos.common import ( @@ -17,13 +18,14 @@ ComposedDatabaseOperation, DatabaseClient, DatabaseClientBuilder, + DatabaseLock, DatabaseOperation, DatabaseOperationFactory, + LockDatabaseOperationFactory, ) from tests.utils import ( CommonTestCase, FakeAsyncIterator, - FakeDatabaseClient, ) @@ -55,7 +57,22 @@ class _DatabaseOperationFactoryImpl(_DatabaseOperationFactory): """For testing purposes.""" -class TestDatabaseClient(unittest.IsolatedAsyncioTestCase): +class _LockDatabaseOperationFactory(LockDatabaseOperationFactory): + """For testing purposes.""" + + def build_acquire(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes.""" + return _DatabaseOperation() + + def build_release(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes.""" + return _DatabaseOperation() + + +_DatabaseClient.register_factory(LockDatabaseOperationFactory, _LockDatabaseOperationFactory) + + +class TestDatabaseClient(CommonTestCase): def test_abstract(self): self.assertTrue(issubclass(DatabaseClient, (ABC, BuildableMixin))) expected = {"_is_valid", "_execute", "_fetch_all", "_reset"} @@ -65,6 +82,10 @@ def test_abstract(self): def test_get_builder(self): self.assertIsInstance(DatabaseClient.get_builder(), DatabaseClientBuilder) + def test_from_config(self): + client = _DatabaseClient.from_config(self.config) + self.assertIsInstance(client, DatabaseClient) + async def test_is_valid(self): mock = AsyncMock(side_effect=[True, False]) client = _DatabaseClient() @@ -75,6 +96,26 @@ async def test_is_valid(self): self.assertEqual([call(), call()], mock.call_args_list) + async def test_lock(self): + _DatabaseClient.register_factory(LockDatabaseOperationFactory, _LockDatabaseOperationFactory) + op1 = _DatabaseOperation(lock="foo") + client = _DatabaseClient() + self.assertIsNone(client.lock) + async with client: + self.assertIsNone(client.lock) + await client.execute(op1) + self.assertIsInstance(client.lock, DatabaseLock) + + self.assertIsNone(client.lock) + + async def test_lock_reset(self): + op1 = _DatabaseOperation(lock="foo") + async with _DatabaseClient() as client: + await client.execute(op1) + self.assertIsInstance(client.lock, DatabaseLock) + await client.reset() + self.assertIsNone(client.lock) + async def test_reset(self): mock = AsyncMock() client = _DatabaseClient() @@ -102,6 +143,36 @@ async def test_execute_composed(self): self.assertEqual([call(composed.operations[0]), call(composed.operations[1])], mock.call_args_list) + async def test_execute_with_lock(self): + op1 = _DatabaseOperation(lock="foo") + with patch.object(DatabaseLock, "acquire") as enter_lock_mock: + with patch.object(DatabaseLock, "release") as exit_lock_mock: + async with _DatabaseClient() as client: + await client.execute(op1) + self.assertEqual(1, enter_lock_mock.call_count) + self.assertEqual(0, exit_lock_mock.call_count) + enter_lock_mock.reset_mock() + exit_lock_mock.reset_mock() + self.assertEqual(0, enter_lock_mock.call_count) + self.assertEqual(1, exit_lock_mock.call_count) + + async def test_execute_with_lock_multiple(self): + op1 = _DatabaseOperation(lock="foo") + op2 = _DatabaseOperation(lock="bar") + async with _DatabaseClient() as client: + self.assertIsNone(client.lock) + + await client.execute(op1) + foo_lock = client.lock + self.assertIsInstance(foo_lock, DatabaseLock) + + await client.execute(op1) + self.assertEqual(foo_lock, client.lock) + + await client.execute(op2) + self.assertNotEqual(foo_lock, client.lock) + self.assertIsInstance(client.lock, DatabaseLock) + async def test_execute_raises_unsupported(self): client = _DatabaseClient() with self.assertRaises(ValueError): @@ -127,12 +198,16 @@ async def test_fetch_one(self): self.assertEqual([call()], mock.call_args_list) def test_register_factory(self): + expected = { + LockDatabaseOperationFactory: _LockDatabaseOperationFactory, + _DatabaseOperationFactory: _DatabaseOperationFactoryImpl, + } try: _DatabaseClient.register_factory(_DatabaseOperationFactory, _DatabaseOperationFactoryImpl) - self.assertEqual({_DatabaseOperationFactory: _DatabaseOperationFactoryImpl}, _DatabaseClient._factories) + self.assertEqual(expected, _DatabaseClient._factories) finally: - _DatabaseClient._factories.clear() + _DatabaseClient._factories.pop(_DatabaseOperationFactory) def test_register_factory_raises(self): with self.assertRaises(ValueError): @@ -143,14 +218,10 @@ def test_register_factory_raises(self): _DatabaseClient.register_factory(_DatabaseOperationFactoryImpl, _DatabaseOperationFactory) def test_get_factory(self): - try: - _DatabaseClient._factories = {_DatabaseOperationFactory: _DatabaseOperationFactoryImpl} - self.assertIsInstance( - _DatabaseClient.get_factory(_DatabaseOperationFactory), - _DatabaseOperationFactoryImpl, - ) - finally: - _DatabaseClient._factories.clear() + self.assertIsInstance( + _DatabaseClient.get_factory(LockDatabaseOperationFactory), + _LockDatabaseOperationFactory, + ) def test_get_factory_raises(self): with self.assertRaises(ValueError): @@ -159,20 +230,13 @@ def test_get_factory_raises(self): class TestDatabaseClientBuilder(CommonTestCase): def test_with_name(self): - builder = DatabaseClientBuilder(FakeDatabaseClient).with_name("query") + builder = DatabaseClientBuilder(_DatabaseClient).with_name("query") self.assertEqual({"name": "query"}, builder.kwargs) def test_with_config(self): - builder = DatabaseClientBuilder(FakeDatabaseClient).with_name("query").with_config(self.config) + builder = DatabaseClientBuilder(_DatabaseClient).with_name("query").with_config(self.config) self.assertEqual({"name": "query"} | self.config.get_database_by_name("query"), builder.kwargs) - def test_build(self): - builder = DatabaseClientBuilder(FakeDatabaseClient).with_name("query").with_config(self.config) - client = builder.build() - - self.assertIsInstance(client, FakeDatabaseClient) - self.assertEqual(self.config.get_database_by_name("query")["database"], client.kwargs["database"]) - if __name__ == "__main__": unittest.main() diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py index 75b233e3f..001e30d2e 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py @@ -74,9 +74,8 @@ async def _setup(self) -> None: await self._create_connection() async def _destroy(self) -> None: - await self.reset() - await self._close_connection() await super()._destroy() + await self._close_connection() async def _create_connection(self): try: diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py index 55c1568f5..319400fe3 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py @@ -16,7 +16,6 @@ ) from minos.common import ( - DatabaseLock, DatabaseOperation, IntegrityException, UnableToConnectException, @@ -102,24 +101,7 @@ async def test_cursor_reset(self): await client.reset() self.assertIsNone(client.cursor) - async def test_lock(self): - op1 = AiopgDatabaseOperation("SELECT * FROM information_schema.tables", lock="foo") - client = AiopgDatabaseClient.from_config(self.config) - self.assertIsNone(client.lock) - async with client: - self.assertIsNone(client.lock) - await client.execute(op1) - self.assertIsInstance(client.lock, DatabaseLock) - - self.assertIsNone(client.lock) - async def test_lock_reset(self): - op1 = AiopgDatabaseOperation("SELECT * FROM information_schema.tables", lock="foo") - async with AiopgDatabaseClient.from_config(self.config) as client: - await client.execute(op1) - self.assertIsInstance(client.lock, DatabaseLock) - await client.reset() - self.assertIsNone(client.lock) async def test_execute(self): async with AiopgDatabaseClient.from_config(self.config) as client: @@ -130,36 +112,6 @@ async def test_execute(self): execute_mock.call_args_list, ) - async def test_execute_with_lock(self): - op1 = AiopgDatabaseOperation("SELECT * FROM information_schema.tables", lock="foo") - with patch.object(DatabaseLock, "acquire") as enter_lock_mock: - with patch.object(DatabaseLock, "release") as exit_lock_mock: - async with AiopgDatabaseClient.from_config(self.config) as client: - await client.execute(op1) - self.assertEqual(1, enter_lock_mock.call_count) - self.assertEqual(0, exit_lock_mock.call_count) - enter_lock_mock.reset_mock() - exit_lock_mock.reset_mock() - self.assertEqual(0, enter_lock_mock.call_count) - self.assertEqual(1, exit_lock_mock.call_count) - - async def test_execute_with_lock_multiple(self): - op1 = AiopgDatabaseOperation("SELECT * FROM information_schema.tables", lock="foo") - op2 = AiopgDatabaseOperation("SELECT * FROM information_schema.tables", lock="bar") - async with AiopgDatabaseClient.from_config(self.config) as client: - self.assertIsNone(client.lock) - - await client.execute(op1) - foo_lock = client.lock - self.assertIsInstance(foo_lock, DatabaseLock) - - await client.execute(op1) - self.assertEqual(foo_lock, client.lock) - - await client.execute(op2) - self.assertNotEqual(foo_lock, client.lock) - self.assertIsInstance(client.lock, DatabaseLock) - async def test_execute_raises_unsupported(self): class _DatabaseOperation(DatabaseOperation): """For testing purposes.""" From 50e593e285a03f85b3fcc6e26f4a5161ffe8a54c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 15:35:15 +0200 Subject: [PATCH 214/324] ISSUE #98 * Add test for failure. --- .../tests/test_common/test_database/test_pools.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index f30a9c055..93cebff72 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -10,6 +10,7 @@ DatabaseClientPool, DatabaseLock, DatabaseLockPool, + UnableToConnectException, classname, ) from minos.common.testing import ( @@ -76,8 +77,8 @@ async def test_acquire_with_reset(self): self.assertEqual(0, reset_mock.call_count) self.assertEqual(1, reset_mock.call_count) - async def test_acquire_with_connection_error(self): - with patch.object(FakeDatabaseClient, "is_valid", return_value=True): + async def test_acquire_with_raises(self): + with patch.object(FakeDatabaseClient, "setup", side_effect=[UnableToConnectException(""), None]): async with self.pool.acquire() as client: self.assertIsInstance(client, FakeDatabaseClient) From db3a24239a3ce42e15c24a9e2c6c922307a1f53d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 15:51:20 +0200 Subject: [PATCH 215/324] ISSUE #98 * Fix bug. --- .../minos/aggregate/events/repositories/abc.py | 11 ++++++++++- .../tests/test_aiopg/test_clients.py | 2 -- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py index f3fd7f593..de03ccfd5 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/abc.py @@ -13,6 +13,7 @@ suppress, ) from typing import ( + TYPE_CHECKING, AsyncIterator, Awaitable, Optional, @@ -31,6 +32,7 @@ NotProvidedException, PoolFactory, SetupMixin, + classname, ) from minos.networks import ( BrokerMessageV1, @@ -65,6 +67,11 @@ Event, ) +if TYPE_CHECKING: + from ...entities import ( + RootEntity, + ) + @Injectable("event_repository") class EventRepository(ABC, SetupMixin): @@ -233,7 +240,7 @@ async def _send_events(self, event: Event): async def select( self, uuid: Optional[UUID] = None, - name: Optional[str] = None, + name: Optional[Union[str, type[RootEntity]]] = None, version: Optional[int] = None, version_lt: Optional[int] = None, version_gt: Optional[int] = None, @@ -268,6 +275,8 @@ async def select( :param transaction_uuid_in: The destination transaction identifier must be equal to one of the given values. :return: A list of entries. """ + if isinstance(name, type): + name = classname(name) generator = self._select( uuid=uuid, name=name, diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py index 319400fe3..403a094af 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py @@ -101,8 +101,6 @@ async def test_cursor_reset(self): await client.reset() self.assertIsNone(client.cursor) - - async def test_execute(self): async with AiopgDatabaseClient.from_config(self.config) as client: with patch.object(Cursor, "execute") as execute_mock: From 3b264aa7cecbac3008e6278b7ded09877ab11c67 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 15:54:06 +0200 Subject: [PATCH 216/324] ISSUE #98 * Remove postgres. --- .../tests/docker-compose.yml | 8 ----- .../tests/test_config.yml | 35 +------------------ 2 files changed, 1 insertion(+), 42 deletions(-) diff --git a/packages/plugins/minos-broker-rabbitmq/tests/docker-compose.yml b/packages/plugins/minos-broker-rabbitmq/tests/docker-compose.yml index 2e0f9e21f..bc4158ab3 100644 --- a/packages/plugins/minos-broker-rabbitmq/tests/docker-compose.yml +++ b/packages/plugins/minos-broker-rabbitmq/tests/docker-compose.yml @@ -1,13 +1,5 @@ version: '2' services: - postgres: - image: postgres:alpine - network_mode: host - environment: - POSTGRES_USER: minos - POSTGRES_PASSWORD: min0s - POSTGRES_DB: order_db - rabbitmq: image: rabbitmq:3-management ports: diff --git a/packages/plugins/minos-broker-rabbitmq/tests/test_config.yml b/packages/plugins/minos-broker-rabbitmq/tests/test_config.yml index 2e1a8a779..3e4c40985 100644 --- a/packages/plugins/minos-broker-rabbitmq/tests/test_config.yml +++ b/packages/plugins/minos-broker-rabbitmq/tests/test_config.yml @@ -3,41 +3,8 @@ service: aggregate: tests.utils.Order services: - minos.networks.BrokerPort -services: - - tests.services.commands.CommandService - - tests.services.queries.QueryService -rest: - host: localhost - port: 8080 -repository: - database: order_db - user: minos - password: min0s - host: localhost - port: 5432 -snapshot: - database: order_db - user: minos - password: min0s - host: localhost - port: 5432 broker: host: localhost port: 5672 user: guest - password: guest - queue: - database: order_db - user: minos - password: min0s - host: localhost - port: 5432 - records: 10 - retry: 2 -saga: - storage: - path: "./order.lmdb" -discovery: - client: minos.networks.MinosDiscoveryClient - host: discovery-service - port: 8080 + password: guest \ No newline at end of file From 5c6815fd9011901d344527401ceb5a55b09a47fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 16:19:09 +0200 Subject: [PATCH 217/324] ISSUE #98 * Increase coverage. --- .../test_repositories/test_database.py | 106 ++++++++++++++++++ 1 file changed, 106 insertions(+) create mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py new file mode 100644 index 000000000..eec961597 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py @@ -0,0 +1,106 @@ +import unittest +from datetime import ( + datetime, + timezone, +) +from unittest.mock import ( + patch, +) +from uuid import ( + uuid4, +) + +from minos.aggregate import ( + Action, + DatabaseEventRepository, + EventRepository, +) +from minos.aggregate.testing import ( + EventRepositorySelectTestCase, + EventRepositorySubmitTestCase, +) +from minos.common import ( + DatabaseClient, + IntegrityException, + current_datetime, +) +from tests.utils import ( + AggregateTestCase, + FakeAsyncIterator, +) + + +class TestDatabaseEventRepositorySubmit(AggregateTestCase, EventRepositorySubmitTestCase): + __test__ = True + + def build_event_repository(self) -> EventRepository: + """For testing purposes.""" + return DatabaseEventRepository.from_config(self.config) + + async def test_generate_uuid(self): + fetch_one = [ + (1, self.uuid, 1, current_datetime()), + ] + fetch_all = [(self.uuid, "example.Car", 1, bytes(), 1, Action.CREATE, current_datetime())] + with patch.object(DatabaseClient, "fetch_one", side_effect=fetch_one): + with patch.object(DatabaseClient, "fetch_all", return_value=FakeAsyncIterator(fetch_all)): + await super().test_generate_uuid() + + async def test_submit(self): + fetch_one = [ + (1, self.uuid, 1, current_datetime()), + ] + fetch_all = [(self.uuid, "example.Car", 1, bytes(), 1, Action.CREATE, current_datetime())] + with patch.object(DatabaseClient, "fetch_one", side_effect=fetch_one): + with patch.object(DatabaseClient, "fetch_all", return_value=FakeAsyncIterator(fetch_all)): + await super().test_submit() + + async def test_submit_with_version(self): + fetch_one = [ + (1, self.uuid, 3, current_datetime()), + ] + fetch_all = [(self.uuid, "example.Car", 3, bytes(), 1, Action.CREATE, current_datetime())] + with patch.object(DatabaseClient, "fetch_one", side_effect=fetch_one): + with patch.object(DatabaseClient, "fetch_all", return_value=FakeAsyncIterator(fetch_all)): + await super().test_submit_with_version() + + async def test_submit_with_created_at(self): + created_at = datetime(2021, 10, 25, 8, 30, tzinfo=timezone.utc) + fetch_one = [ + (1, self.uuid, 1, created_at), + ] + fetch_all = [(self.uuid, "example.Car", 1, bytes(), 1, Action.CREATE, created_at)] + with patch.object(DatabaseClient, "fetch_one", side_effect=fetch_one): + with patch.object(DatabaseClient, "fetch_all", return_value=FakeAsyncIterator(fetch_all)): + await super().test_submit_with_created_at() + + async def test_submit_raises_duplicate(self): + fetch_one = [ + (1, uuid4(), 1, current_datetime()), + IntegrityException(""), + (1,), + ] + with patch.object(DatabaseClient, "fetch_one", side_effect=fetch_one): + await super().test_submit_raises_duplicate() + + async def test_offset(self): + fetch_one = [ + (0,), + (1, uuid4(), 1, current_datetime()), + (1,), + ] + with patch.object(DatabaseClient, "fetch_one", side_effect=fetch_one): + await super().test_offset() + + +@unittest.skip +class TestDatabaseEventRepositorySelect(AggregateTestCase, EventRepositorySelectTestCase): + __test__ = True + + def build_event_repository(self) -> EventRepository: + """For testing purposes.""" + return DatabaseEventRepository.from_config(self.config) + + +if __name__ == "__main__": + unittest.main() From ac63685e2ec673472a626193599fc1bfd77d3d59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 16:36:32 +0200 Subject: [PATCH 218/324] ISSUE #98 * Partial revert. --- .github/workflows/minos-broker-rabbitmq-tests.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/minos-broker-rabbitmq-tests.yml b/.github/workflows/minos-broker-rabbitmq-tests.yml index e20576500..cf21e6258 100644 --- a/.github/workflows/minos-broker-rabbitmq-tests.yml +++ b/.github/workflows/minos-broker-rabbitmq-tests.yml @@ -18,7 +18,11 @@ jobs: defaults: run: working-directory: packages/plugins/minos-broker-rabbitmq - + services: + rabbitmq: + image: rabbitmq:3 + ports: + - 5672:5672 env: MINOS_BROKER_HOST: rabbitmq From 082810b64fcdf1d6e9d22070ff0bb3c29700843a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 16:41:37 +0200 Subject: [PATCH 219/324] ISSUE #98 * Minor improvements. --- .../test_factories/test_aggregate/test_events/test_pg.py | 4 ++-- .../test_aggregate/test_transactions/test_pg.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py index 81d6b989e..1c75ef235 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py @@ -22,7 +22,7 @@ class TestDatabaseEventRepositorySubmit(AiopgTestCase, EventRepositorySubmitTest def build_event_repository(self) -> EventRepository: """Fort testing purposes.""" - return DatabaseEventRepository() + return DatabaseEventRepository.from_config(self.config) def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) @@ -53,7 +53,7 @@ class TestDatabaseEventRepositorySelect(AiopgTestCase, EventRepositorySelectTest def build_event_repository(self) -> EventRepository: """Fort testing purposes.""" - return DatabaseEventRepository() + return DatabaseEventRepository.from_config(self.config) if __name__ == "__main__": diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py index 2d2ab55ac..1d186f273 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py @@ -24,7 +24,7 @@ class TestDatabaseTransactionRepository(AiopgTestCase, TransactionRepositorySubm __test__ = True def build_transaction_repository(self) -> TransactionRepository: - return DatabaseTransactionRepository() + return DatabaseTransactionRepository.from_config(self.config) def test_constructor(self): pool = DatabaseClientPool.from_config(self.config) @@ -50,7 +50,7 @@ class TestDatabaseTransactionRepositorySelect(AiopgTestCase, TransactionReposito __test__ = True def build_transaction_repository(self) -> TransactionRepository: - return DatabaseTransactionRepository() + return DatabaseTransactionRepository.from_config(self.config) if __name__ == "__main__": From 2f5042087ff7687ad57d76ac73bbe0c83d8664c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 16:48:41 +0200 Subject: [PATCH 220/324] ISSUE #98 * Fix broken test. --- .../test_aggregate/test_events/test_pg.py | 10 +++++----- .../test_aggregate/test_snapshots/test_pg.py | 5 +++-- .../test_aggregate/test_transactions/test_pg.py | 3 ++- 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py index 1c75ef235..4bd5c5f72 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py @@ -11,6 +11,10 @@ from minos.common import ( DatabaseClientPool, ) +from minos.plugins.aiopg import ( + AiopgDatabaseClient, + AiopgDatabaseOperation, +) from tests.utils import ( AiopgTestCase, ) @@ -35,11 +39,7 @@ def test_from_config(self): self.assertIsInstance(repository.database_pool, DatabaseClientPool) async def test_setup(self): - async with self.get_client() as client: - from minos.plugins.aiopg import ( - AiopgDatabaseOperation, - ) - + async with AiopgDatabaseClient.from_config(self.config) as client: operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_event');" ) diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py index e368497bf..bc93b11c8 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py @@ -11,6 +11,7 @@ Car, ) from minos.plugins.aiopg import ( + AiopgDatabaseClient, AiopgDatabaseOperation, ) from tests.utils import ( @@ -26,7 +27,7 @@ def build_snapshot_repository(self): return DatabaseSnapshotRepository.from_config(self.config) async def test_setup_snapshot_table(self): - async with self.get_client() as client: + async with AiopgDatabaseClient.from_config(self.config) as client: operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM pg_tables WHERE schemaname = 'public' AND tablename = 'snapshot');" ) @@ -35,7 +36,7 @@ async def test_setup_snapshot_table(self): self.assertEqual(True, observed) async def test_setup_snapshot_aux_offset_table(self): - async with self.get_client() as client: + async with AiopgDatabaseClient.from_config(self.config) as client: operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM pg_tables WHERE " "schemaname = 'public' AND tablename = 'snapshot_aux_offset');" diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py index 1d186f273..51ae8c01b 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py @@ -12,6 +12,7 @@ DatabaseClientPool, ) from minos.plugins.aiopg import ( + AiopgDatabaseClient, AiopgDatabaseOperation, ) from tests.utils import ( @@ -37,7 +38,7 @@ def test_from_config(self): self.assertIsInstance(repository.database_pool, DatabaseClientPool) async def test_setup(self): - async with self.get_client() as client: + async with AiopgDatabaseClient.from_config(self.config) as client: operation = AiopgDatabaseOperation( "SELECT EXISTS (SELECT FROM information_schema.tables WHERE table_name = 'aggregate_transaction');" ) From 409c41b5b029883670f964ebafb23a9e08311ca9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 17:17:38 +0200 Subject: [PATCH 221/324] ISSUE #98 * Working on tests. --- .../test_repositories/test_database.py | 55 ++++++++++++++++++- 1 file changed, 54 insertions(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py index eec961597..a7203a945 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py @@ -93,7 +93,6 @@ async def test_offset(self): await super().test_offset() -@unittest.skip class TestDatabaseEventRepositorySelect(AggregateTestCase, EventRepositorySelectTestCase): __test__ = True @@ -101,6 +100,60 @@ def build_event_repository(self) -> EventRepository: """For testing purposes.""" return DatabaseEventRepository.from_config(self.config) + async def test_select(self): + await super().test_select() + + async def test_select_id(self): + await super().test_select_id() + + async def test_select_id_lt(self): + await super().test_select_id_lt() + + async def test_select_id_gt(self): + await super().test_select_id_gt() + + async def test_select_id_le(self): + await super().test_select_id_le() + + async def test_select_id_ge(self): + await super().test_select_id_ge() + + async def test_select_uuid(self): + await super().test_select_uuid() + + async def test_select_name(self): + await super().test_select_name() + + async def test_select_version(self): + await super().test_select_version() + + async def test_select_version_lt(self): + await super().test_select_version_lt() + + async def test_select_version_gt(self): + await super().test_select_version_gt() + + async def test_select_version_le(self): + await super().test_select_version_le() + + async def test_select_version_ge(self): + await super().test_select_version_ge() + + async def test_select_transaction_uuid_null(self): + await super().test_select_transaction_uuid_null() + + async def test_select_transaction_uuid(self): + await super().test_select_transaction_uuid() + + async def test_select_transaction_uuid_ne(self): + await super().test_select_transaction_uuid_ne() + + async def test_select_transaction_uuid_in(self): + await super().test_select_transaction_uuid_in() + + async def test_select_combined(self): + await super().test_select_combined() + if __name__ == "__main__": unittest.main() From b2cbc7825e7f050d12de757ce3a797c878165e36 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 17:22:05 +0200 Subject: [PATCH 222/324] v0.7.0.dev1 --- .../minos-microservice-aggregate/minos/aggregate/__init__.py | 2 +- packages/core/minos-microservice-aggregate/pyproject.toml | 2 +- .../core/minos-microservice-common/minos/common/__init__.py | 2 +- packages/core/minos-microservice-common/pyproject.toml | 2 +- packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py | 2 +- packages/core/minos-microservice-cqrs/pyproject.toml | 2 +- .../core/minos-microservice-networks/minos/networks/__init__.py | 2 +- packages/core/minos-microservice-networks/pyproject.toml | 2 +- packages/core/minos-microservice-saga/minos/saga/__init__.py | 2 +- packages/core/minos-microservice-saga/pyproject.toml | 2 +- .../plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py | 2 +- packages/plugins/minos-broker-kafka/pyproject.toml | 2 +- .../minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py | 2 +- packages/plugins/minos-broker-rabbitmq/pyproject.toml | 2 +- .../plugins/minos-discovery-kong/minos/plugins/kong/__init__.py | 2 +- packages/plugins/minos-discovery-kong/pyproject.toml | 2 +- .../minos/plugins/minos_discovery/__init__.py | 2 +- packages/plugins/minos-discovery-minos/pyproject.toml | 2 +- .../minos-http-aiohttp/minos/plugins/aiohttp/__init__.py | 2 +- packages/plugins/minos-http-aiohttp/pyproject.toml | 2 +- .../minos-router-graphql/minos/plugins/graphql/__init__.py | 2 +- packages/plugins/minos-router-graphql/pyproject.toml | 2 +- pyproject.toml | 2 +- 23 files changed, 23 insertions(+), 23 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index 95ec86a09..695cf20f4 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.0" +__version__ = "0.7.0.dev1" from .actions import ( Action, diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index a50271c19..fdf2edd1d 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-aggregate" -version = "0.6.0" +version = "0.7.0.dev1" description = "The Aggregate pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 508626614..cf40ed59a 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -1,7 +1,7 @@ """The common core of the Minos Framework.""" __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.1" +__version__ = "0.7.0.dev1" from .builders import ( BuildableMixin, diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index 2d7f53c87..2f6a4869d 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-common" -version = "0.6.1" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py b/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py index 68dd15f80..2f34314d9 100644 --- a/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py +++ b/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.0" +__version__ = "0.7.0.dev1" from .exceptions import ( MinosCqrsException, diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index d71b3adbb..a87bae705 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-cqrs" -version = "0.6.0" +version = "0.7.0.dev1" description = "The CQRS pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-networks/minos/networks/__init__.py b/packages/core/minos-microservice-networks/minos/networks/__init__.py index 044a35b86..9c952e092 100644 --- a/packages/core/minos-microservice-networks/minos/networks/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.0" +__version__ = "0.7.0.dev1" from .brokers import ( REQUEST_HEADERS_CONTEXT_VAR, diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index afabfddb7..67eccda03 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-saga/minos/saga/__init__.py b/packages/core/minos-microservice-saga/minos/saga/__init__.py index 788625039..c424053b1 100644 --- a/packages/core/minos-microservice-saga/minos/saga/__init__.py +++ b/packages/core/minos-microservice-saga/minos/saga/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.0" +__version__ = "0.7.0.dev1" from .context import ( SagaContext, diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index 1b88ac581..227f41fbb 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-saga" -version = "0.6.0" +version = "0.7.0.dev1" description = "The SAGA pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py index 6aeee4acd..a40e635b8 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.1" +__version__ = "0.7.0.dev1" from .common import ( KafkaBrokerBuilderMixin, diff --git a/packages/plugins/minos-broker-kafka/pyproject.toml b/packages/plugins/minos-broker-kafka/pyproject.toml index 0d073e5c3..b630bb21f 100644 --- a/packages/plugins/minos-broker-kafka/pyproject.toml +++ b/packages/plugins/minos-broker-kafka/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-broker-kafka" -version = "0.6.1" +version = "0.7.0.dev1" description = "The kafka plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py b/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py index 2a7519cf9..562bf559f 100644 --- a/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py +++ b/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.0" +__version__ = "0.7.0.dev1" from .common import ( RabbitMQBrokerBuilderMixin, diff --git a/packages/plugins/minos-broker-rabbitmq/pyproject.toml b/packages/plugins/minos-broker-rabbitmq/pyproject.toml index cac8904d2..e0784a6ab 100644 --- a/packages/plugins/minos-broker-rabbitmq/pyproject.toml +++ b/packages/plugins/minos-broker-rabbitmq/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-broker-rabbitmq" -version = "0.6.0" +version = "0.7.0.dev1" description = "The rabbitmq plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index 11acb787a..0d4a9459f 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -1,6 +1,6 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.1.0a1" +__version__ = "0.7.0.dev1" from .client import ( KongClient, diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index 006bc4b05..e1df8c291 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-kong" -version = "0.6.0" +version = "0.7.0.dev1" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py b/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py index fa3fdf505..9f4dbd476 100644 --- a/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py +++ b/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.0" +__version__ = "0.7.0.dev1" from .client import ( MinosDiscoveryClient, diff --git a/packages/plugins/minos-discovery-minos/pyproject.toml b/packages/plugins/minos-discovery-minos/pyproject.toml index bba53b0fa..83a9cbd53 100644 --- a/packages/plugins/minos-discovery-minos/pyproject.toml +++ b/packages/plugins/minos-discovery-minos/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-minos" -version = "0.6.0" +version = "0.7.0.dev1" description = "The minos-discovery plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py index 306d4d301..5b548d3a8 100644 --- a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py +++ b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.0" +__version__ = "0.7.0.dev1" from .connectors import ( AioHttpConnector, diff --git a/packages/plugins/minos-http-aiohttp/pyproject.toml b/packages/plugins/minos-http-aiohttp/pyproject.toml index c883b3276..a6c203fa0 100644 --- a/packages/plugins/minos-http-aiohttp/pyproject.toml +++ b/packages/plugins/minos-http-aiohttp/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-http-aiohttp" -version = "0.6.0" +version = "0.7.0.dev1" description = "The aiohttp plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py b/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py index 4bf9b2a7c..7edb5204a 100644 --- a/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py +++ b/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.6.0" +__version__ = "0.7.0.dev1" from .builders import ( GraphQLSchemaBuilder, diff --git a/packages/plugins/minos-router-graphql/pyproject.toml b/packages/plugins/minos-router-graphql/pyproject.toml index 1b4fa7667..55d7f15f4 100644 --- a/packages/plugins/minos-router-graphql/pyproject.toml +++ b/packages/plugins/minos-router-graphql/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-router-graphql" -version = "0.6.0" +version = "0.7.0.dev1" description = "The graphql plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/pyproject.toml b/pyproject.toml index dc08ae16e..c7fc20b6c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-python" -version = "0.1.0" +version = "0.7.0.dev1" description = "" authors = ["Minos Framework Devs "] license = "MIT" From 152e4fef93825d471421e40c57c81e25a37f7b38 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 17:26:07 +0200 Subject: [PATCH 223/324] v0.7.0.dev1 (2) --- packages/core/minos-microservice-aggregate/pyproject.toml | 4 ++-- packages/core/minos-microservice-cqrs/pyproject.toml | 6 +++--- packages/core/minos-microservice-networks/pyproject.toml | 2 +- packages/core/minos-microservice-saga/pyproject.toml | 6 +++--- packages/plugins/minos-broker-kafka/pyproject.toml | 4 ++-- packages/plugins/minos-broker-rabbitmq/pyproject.toml | 4 ++-- packages/plugins/minos-discovery-kong/pyproject.toml | 4 ++-- packages/plugins/minos-discovery-minos/pyproject.toml | 4 ++-- packages/plugins/minos-http-aiohttp/pyproject.toml | 4 ++-- packages/plugins/minos-router-graphql/pyproject.toml | 4 ++-- 10 files changed, 21 insertions(+), 21 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index fdf2edd1d..500836d03 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" cached-property = "^1.5.2" psycopg2-binary = "^2.9.3" diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index a87bae705..2596c5b51 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-aggregate = "^0.6.0" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-aggregate = "^0.7.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../minos-microservice-common", develop = true } diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index 67eccda03..ac9596484 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -31,7 +31,7 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.6.0" +minos-microservice-common = "^0.7.0" aiopg = "^1.2.1" crontab = "^0.23.0" psycopg2-binary = "^2.9.3" diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index 227f41fbb..e50d3d3ab 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-aggregate = "^0.6.0" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-aggregate = "^0.7.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" cached-property = "^1.5.2" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-broker-kafka/pyproject.toml b/packages/plugins/minos-broker-kafka/pyproject.toml index b630bb21f..998c3ffa3 100644 --- a/packages/plugins/minos-broker-kafka/pyproject.toml +++ b/packages/plugins/minos-broker-kafka/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" aiokafka = "^0.7.0" cached-property = "^1.5.2" kafka-python = "^2.0.2" diff --git a/packages/plugins/minos-broker-rabbitmq/pyproject.toml b/packages/plugins/minos-broker-rabbitmq/pyproject.toml index e0784a6ab..4466a6b26 100644 --- a/packages/plugins/minos-broker-rabbitmq/pyproject.toml +++ b/packages/plugins/minos-broker-rabbitmq/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" aio-pika = "^7.1.0" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index e1df8c291..216778bf9 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -32,8 +32,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" httpx = "^0.22.0" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-discovery-minos/pyproject.toml b/packages/plugins/minos-discovery-minos/pyproject.toml index 83a9cbd53..9c93fe746 100644 --- a/packages/plugins/minos-discovery-minos/pyproject.toml +++ b/packages/plugins/minos-discovery-minos/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" aiohttp = "^3.8.1" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-http-aiohttp/pyproject.toml b/packages/plugins/minos-http-aiohttp/pyproject.toml index a6c203fa0..1ae70877f 100644 --- a/packages/plugins/minos-http-aiohttp/pyproject.toml +++ b/packages/plugins/minos-http-aiohttp/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" aiohttp = "^3.8.1" orjson = "^3.6.7" cached-property = "^1.5.2" diff --git a/packages/plugins/minos-router-graphql/pyproject.toml b/packages/plugins/minos-router-graphql/pyproject.toml index 55d7f15f4..f51e01966 100644 --- a/packages/plugins/minos-router-graphql/pyproject.toml +++ b/packages/plugins/minos-router-graphql/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" graphql-core = "^3.2.0" [tool.poetry.dev-dependencies] From 061bacab81819ab3cf2984fe2d47e2f2e7d59266 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 17:38:33 +0200 Subject: [PATCH 224/324] v0.7.0.dev1 (3) --- .../minos-microservice-aggregate/poetry.lock | 22 ++++++------ .../pyproject.toml | 4 +-- .../minos-microservice-common/poetry.lock | 14 ++++---- .../minos-microservice-common/pyproject.toml | 2 +- .../core/minos-microservice-cqrs/poetry.lock | 28 +++++++-------- .../minos-microservice-cqrs/pyproject.toml | 6 ++-- .../minos-microservice-networks/poetry.lock | 18 +++++----- .../pyproject.toml | 2 +- .../core/minos-microservice-saga/poetry.lock | 28 +++++++-------- .../minos-microservice-saga/pyproject.toml | 6 ++-- .../plugins/minos-broker-kafka/poetry.lock | 28 +++++++-------- .../plugins/minos-broker-kafka/pyproject.toml | 4 +-- .../plugins/minos-broker-rabbitmq/poetry.lock | 28 +++++++-------- .../minos-broker-rabbitmq/pyproject.toml | 4 +-- .../plugins/minos-discovery-kong/poetry.lock | 22 ++++++------ .../minos-discovery-kong/pyproject.toml | 4 +-- .../plugins/minos-discovery-minos/poetry.lock | 28 +++++++-------- .../minos-discovery-minos/pyproject.toml | 4 +-- .../plugins/minos-http-aiohttp/poetry.lock | 28 +++++++-------- .../plugins/minos-http-aiohttp/pyproject.toml | 4 +-- .../plugins/minos-router-graphql/poetry.lock | 34 +++++++++---------- .../minos-router-graphql/pyproject.toml | 4 +-- 22 files changed, 161 insertions(+), 161 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/poetry.lock b/packages/core/minos-microservice-aggregate/poetry.lock index e234be8d7..852cdb5f5 100644 --- a/packages/core/minos-microservice-aggregate/poetry.lock +++ b/packages/core/minos-microservice-aggregate/poetry.lock @@ -230,7 +230,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.1" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -238,7 +238,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -254,7 +254,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -264,7 +264,7 @@ develop = true [package.dependencies] aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" +minos-microservice-common = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -364,14 +364,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -442,7 +442,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "68b13cc914d2cf6d62d9195948eee0a89b6722bc73dfdd27f60c84c1aa0150d3" +content-hash = "6396dea0a2b7eaacdc945a96189dc6569ed60a0646c252be31e273aad6629985" [metadata.files] aiomisc = [ @@ -780,8 +780,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index 500836d03..68dd85bf2 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.7.0" -minos-microservice-networks = "^0.7.0" +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } cached-property = "^1.5.2" psycopg2-binary = "^2.9.3" diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index bf9ab3520..e42299fc2 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -313,14 +313,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -391,7 +391,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "e47f8fa7cd4cd7dd0b552b168c8e7e17014c445a7941c0a0521f072daffd3a34" +content-hash = "0ffaa4f60d01f3464d7a3797d3ba04e6b1ebbaf2ae67f105cf5ba49e79521d50" [metadata.files] aiomisc = [ @@ -724,8 +724,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index 2f6a4869d..7bc7662ab 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -31,7 +31,7 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" fastavro = "^1.4.0" orjson = "^3.5.2" lmdb = "^1.2.1" diff --git a/packages/core/minos-microservice-cqrs/poetry.lock b/packages/core/minos-microservice-cqrs/poetry.lock index 50b1b0638..bc0c15e2b 100644 --- a/packages/core/minos-microservice-cqrs/poetry.lock +++ b/packages/core/minos-microservice-cqrs/poetry.lock @@ -230,7 +230,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.6.0" +version = "0.7.0.dev1" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -239,8 +239,8 @@ develop = true [package.dependencies] cached-property = "^1.5.2" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -249,7 +249,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.1" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -257,7 +257,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -273,7 +273,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -283,7 +283,7 @@ develop = true [package.dependencies] aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" +minos-microservice-common = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -383,14 +383,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -461,7 +461,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "e9e7d8d79b5a31f43d672277ba2da98cdf0fb0e58bde9c158824c4b69f7696cc" +content-hash = "4aebc32cd00338ca4f9a425c9f75b2c796abb3b46bd8a7b895ec0b9e753866b5" [metadata.files] aiomisc = [ @@ -800,8 +800,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index 2596c5b51..25286b446 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-aggregate = "^0.7.0" -minos-microservice-common = "^0.7.0" -minos-microservice-networks = "^0.7.0" +minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../minos-microservice-common", develop = true } diff --git a/packages/core/minos-microservice-networks/poetry.lock b/packages/core/minos-microservice-networks/poetry.lock index 8ff00456b..93681dd9c 100644 --- a/packages/core/minos-microservice-networks/poetry.lock +++ b/packages/core/minos-microservice-networks/poetry.lock @@ -230,7 +230,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.1" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -238,7 +238,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -345,14 +345,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -423,7 +423,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "bf50cd47a454d6e16e009014abd24654c13ee736ea523a58241b9aef4b65d8ab" +content-hash = "c9bb8530112d131ba7e2db97e307010931ebaa7cd724a268aa9182b79608ef92" [metadata.files] aiomisc = [ @@ -760,8 +760,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index ac9596484..63c0f30fd 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -31,7 +31,7 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.7.0" +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } aiopg = "^1.2.1" crontab = "^0.23.0" psycopg2-binary = "^2.9.3" diff --git a/packages/core/minos-microservice-saga/poetry.lock b/packages/core/minos-microservice-saga/poetry.lock index f69c54fe6..9b8d56bdf 100644 --- a/packages/core/minos-microservice-saga/poetry.lock +++ b/packages/core/minos-microservice-saga/poetry.lock @@ -230,7 +230,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.6.0" +version = "0.7.0.dev1" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -239,8 +239,8 @@ develop = true [package.dependencies] cached-property = "^1.5.2" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -249,7 +249,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.1" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -257,7 +257,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -273,7 +273,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -283,7 +283,7 @@ develop = true [package.dependencies] aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" +minos-microservice-common = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -383,14 +383,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -461,7 +461,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "97d564c578f53fa2980ec36b48dcda0ba291afed526be417d2a08c8432b7e61e" +content-hash = "78161968a697862a222239c4016779c6140d2f39f8fb4ed614bb596f76413aee" [metadata.files] aiomisc = [ @@ -800,8 +800,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index e50d3d3ab..2aeb27abb 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-aggregate = "^0.7.0" -minos-microservice-common = "^0.7.0" -minos-microservice-networks = "^0.7.0" +minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } cached-property = "^1.5.2" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-broker-kafka/poetry.lock b/packages/plugins/minos-broker-kafka/poetry.lock index f623057fb..917f8a71e 100644 --- a/packages/plugins/minos-broker-kafka/poetry.lock +++ b/packages/plugins/minos-broker-kafka/poetry.lock @@ -110,7 +110,7 @@ python-versions = "*" [[package]] name = "click" -version = "8.1.1" +version = "8.1.2" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -255,7 +255,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -263,7 +263,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -279,7 +279,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -289,7 +289,7 @@ develop = true [package.dependencies] aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" +minos-microservice-common = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -389,14 +389,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -475,7 +475,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "ecd34b3f2eeddc1b83c628b472b82a382205f731469e4203d210b01f3c68118d" +content-hash = "83dc6e09d794b3da6df0d99473af5ec70635027ee12d410e98eb29f830339979" [metadata.files] aiokafka = [ @@ -551,8 +551,8 @@ cached-property = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] click = [ - {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, - {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, + {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, + {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -840,8 +840,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-broker-kafka/pyproject.toml b/packages/plugins/minos-broker-kafka/pyproject.toml index 998c3ffa3..21325bcdf 100644 --- a/packages/plugins/minos-broker-kafka/pyproject.toml +++ b/packages/plugins/minos-broker-kafka/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.7.0" -minos-microservice-networks = "^0.7.0" +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } aiokafka = "^0.7.0" cached-property = "^1.5.2" kafka-python = "^2.0.2" diff --git a/packages/plugins/minos-broker-rabbitmq/poetry.lock b/packages/plugins/minos-broker-rabbitmq/poetry.lock index 64ffc02d1..c9108fa32 100644 --- a/packages/plugins/minos-broker-rabbitmq/poetry.lock +++ b/packages/plugins/minos-broker-rabbitmq/poetry.lock @@ -126,7 +126,7 @@ python-versions = "*" [[package]] name = "click" -version = "8.1.1" +version = "8.1.2" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -268,7 +268,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -276,7 +276,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -292,7 +292,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -302,7 +302,7 @@ develop = true [package.dependencies] aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" +minos-microservice-common = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -422,14 +422,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -520,7 +520,7 @@ multidict = ">=4.0" [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "98b33c6e7100a12158c1037e16d702490623ec6b90c1c3b569cb86779dc8b525" +content-hash = "2b66ade14c61be67e8928576bec9684c7798cc021994c6815a8a0e25b47f5d5b" [metadata.files] aio-pika = [ @@ -581,8 +581,8 @@ cached-property = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] click = [ - {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, - {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, + {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, + {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -934,8 +934,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-broker-rabbitmq/pyproject.toml b/packages/plugins/minos-broker-rabbitmq/pyproject.toml index 4466a6b26..9b3d256be 100644 --- a/packages/plugins/minos-broker-rabbitmq/pyproject.toml +++ b/packages/plugins/minos-broker-rabbitmq/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.7.0" -minos-microservice-networks = "^0.7.0" +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } aio-pika = "^7.1.0" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-discovery-kong/poetry.lock b/packages/plugins/minos-discovery-kong/poetry.lock index 891e4770d..86d2b2810 100644 --- a/packages/plugins/minos-discovery-kong/poetry.lock +++ b/packages/plugins/minos-discovery-kong/poetry.lock @@ -321,7 +321,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.1" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -329,7 +329,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -345,7 +345,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -355,7 +355,7 @@ develop = true [package.dependencies] aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" +minos-microservice-common = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -455,14 +455,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -563,7 +563,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "980f2d6f75effa21b4da747805178aec427e22a3dc017bb7f9360b736aa8f4a8" +content-hash = "7cc1a8e54ecde83eecf19cfa5c6e636ebf1f1e2e9bfb4c3a4d69a0d188d53715" [metadata.files] aiomisc = [ @@ -929,8 +929,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index 216778bf9..7299ee51f 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -32,8 +32,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.7.0" -minos-microservice-networks = "^0.7.0" +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } httpx = "^0.22.0" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-discovery-minos/poetry.lock b/packages/plugins/minos-discovery-minos/poetry.lock index e49e2b433..4b8937fd7 100644 --- a/packages/plugins/minos-discovery-minos/poetry.lock +++ b/packages/plugins/minos-discovery-minos/poetry.lock @@ -138,7 +138,7 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.1.1" +version = "8.1.2" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -288,7 +288,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -296,7 +296,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -312,7 +312,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -322,7 +322,7 @@ develop = true [package.dependencies] aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" +minos-microservice-common = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -430,14 +430,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -528,7 +528,7 @@ multidict = ">=4.0" [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "a92374adf66c4b234f53b1d8758750e049f11a9b8d0e5a952d34602579eacf09" +content-hash = "8de1ddcc7e0efd18606f140ff12b1863992d8867b595de724e91b86baddc47c1" [metadata.files] aiohttp = [ @@ -663,8 +663,8 @@ charset-normalizer = [ {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, - {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, + {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, + {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1074,8 +1074,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-discovery-minos/pyproject.toml b/packages/plugins/minos-discovery-minos/pyproject.toml index 9c93fe746..9ee7b064a 100644 --- a/packages/plugins/minos-discovery-minos/pyproject.toml +++ b/packages/plugins/minos-discovery-minos/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.7.0" -minos-microservice-networks = "^0.7.0" +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } aiohttp = "^3.8.1" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-http-aiohttp/poetry.lock b/packages/plugins/minos-http-aiohttp/poetry.lock index cb3e0e7d3..5f54411d9 100644 --- a/packages/plugins/minos-http-aiohttp/poetry.lock +++ b/packages/plugins/minos-http-aiohttp/poetry.lock @@ -138,7 +138,7 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.1.1" +version = "8.1.2" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -288,7 +288,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -296,7 +296,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -312,7 +312,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -322,7 +322,7 @@ develop = true [package.dependencies] aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" +minos-microservice-common = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -430,14 +430,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -528,7 +528,7 @@ multidict = ">=4.0" [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "cf3f1cbfb0802979f6e4c686ffcd7d15a5e62208d38db5738a923a428d91e9d0" +content-hash = "9ed872e521aee3a92c874dfb20d4f7c6eed8c1f252ef22657578b97ea0ad0d03" [metadata.files] aiohttp = [ @@ -663,8 +663,8 @@ charset-normalizer = [ {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, - {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, + {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, + {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -1074,8 +1074,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-http-aiohttp/pyproject.toml b/packages/plugins/minos-http-aiohttp/pyproject.toml index 1ae70877f..c8e689ede 100644 --- a/packages/plugins/minos-http-aiohttp/pyproject.toml +++ b/packages/plugins/minos-http-aiohttp/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.7.0" -minos-microservice-networks = "^0.7.0" +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } aiohttp = "^3.8.1" orjson = "^3.6.7" cached-property = "^1.5.2" diff --git a/packages/plugins/minos-router-graphql/poetry.lock b/packages/plugins/minos-router-graphql/poetry.lock index ee849c445..30e4b6736 100644 --- a/packages/plugins/minos-router-graphql/poetry.lock +++ b/packages/plugins/minos-router-graphql/poetry.lock @@ -96,7 +96,7 @@ python-versions = "*" [[package]] name = "click" -version = "8.1.1" +version = "8.1.2" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -192,7 +192,7 @@ pyflakes = ">=2.4.0,<2.5.0" [[package]] name = "graphql-core" -version = "3.2.0" +version = "3.2.1" description = "GraphQL implementation for Python, a port of GraphQL.js, the JavaScript reference implementation for GraphQL." category = "main" optional = false @@ -238,7 +238,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -246,7 +246,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" +aiomisc = ">=14.0.3,<15.8.0" aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" @@ -262,7 +262,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -272,7 +272,7 @@ develop = true [package.dependencies] aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" +minos-microservice-common = "^0.7.0*" psycopg2-binary = "^2.9.3" [package.source] @@ -372,14 +372,14 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -458,7 +458,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "a8050f5103cea0140af18113d3faa9a494436b9f2fb5f4618dc909a3d51bd97f" +content-hash = "4e128a7d215b0b372007e4d0eb730675ac7998a38c17ead9ce794683f29a3941" [metadata.files] aiomisc = [ @@ -511,8 +511,8 @@ cached-property = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] click = [ - {file = "click-8.1.1-py3-none-any.whl", hash = "sha256:5e0d195c2067da3136efb897449ec1e9e6c98282fbf30d7f9e164af9be901a6b"}, - {file = "click-8.1.1.tar.gz", hash = "sha256:7ab900e38149c9872376e8f9b5986ddcaf68c0f413cf73678a0bca5547e6f976"}, + {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, + {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -629,8 +629,8 @@ flake8 = [ {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, ] graphql-core = [ - {file = "graphql-core-3.2.0.tar.gz", hash = "sha256:86e2a0be008bfde19ef78388de8a725a1d942a9190ca431c24a60837973803ce"}, - {file = "graphql_core-3.2.0-py3-none-any.whl", hash = "sha256:0dda7e63676f119bb3d814621190fedad72fda07a8e9ab780bedd9f1957c6dc6"}, + {file = "graphql-core-3.2.1.tar.gz", hash = "sha256:9d1bf141427b7d54be944587c8349df791ce60ade2e3cccaf9c56368c133c201"}, + {file = "graphql_core-3.2.1-py3-none-any.whl", hash = "sha256:f83c658e4968998eed1923a2e3e3eddd347e005ac0315fbb7ca4d70ea9156323"}, ] iniconfig = [ {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, @@ -800,8 +800,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-router-graphql/pyproject.toml b/packages/plugins/minos-router-graphql/pyproject.toml index f51e01966..0e3ba9242 100644 --- a/packages/plugins/minos-router-graphql/pyproject.toml +++ b/packages/plugins/minos-router-graphql/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.7.0" -minos-microservice-networks = "^0.7.0" +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } graphql-core = "^3.2.0" [tool.poetry.dev-dependencies] From f78eb44eb7ac3f444295396f662e0779502973c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 11 Apr 2022 18:34:39 +0200 Subject: [PATCH 225/324] ISSUE #98 * Add tests for even repository. --- .../aggregate/testing/event_repository.py | 73 ++++- .../test_repositories/test_database.py | 278 ++++++++++++++++-- 2 files changed, 326 insertions(+), 25 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py index 924e3d897..1a772528a 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py @@ -139,13 +139,69 @@ def setUp(self) -> None: self.second_transaction = uuid4() self.entries = [ - EventEntry(self.uuid_1, "example.Car", 1, bytes("foo", "utf-8"), 1, Action.CREATE), - EventEntry(self.uuid_1, "example.Car", 2, bytes("bar", "utf-8"), 2, Action.UPDATE), - EventEntry(self.uuid_2, "example.Car", 1, bytes("hello", "utf-8"), 3, Action.CREATE), - EventEntry(self.uuid_1, "example.Car", 3, bytes("foobar", "utf-8"), 4, Action.UPDATE), - EventEntry(self.uuid_1, "example.Car", 4, bytes(), 5, Action.DELETE), - EventEntry(self.uuid_2, "example.Car", 2, bytes("bye", "utf-8"), 6, Action.UPDATE), - EventEntry(self.uuid_4, "example.MotorCycle", 1, bytes("one", "utf-8"), 7, Action.CREATE), + EventEntry( + self.uuid_1, + "example.Car", + 1, + bytes("foo", "utf-8"), + 1, + Action.CREATE, + current_datetime(), + ), + EventEntry( + self.uuid_1, + "example.Car", + 2, + bytes("bar", "utf-8"), + 2, + Action.UPDATE, + current_datetime(), + ), + EventEntry( + self.uuid_2, + "example.Car", + 1, + bytes("hello", "utf-8"), + 3, + Action.CREATE, + current_datetime(), + ), + EventEntry( + self.uuid_1, + "example.Car", + 3, + bytes("foobar", "utf-8"), + 4, + Action.UPDATE, + current_datetime(), + ), + EventEntry( + self.uuid_1, + "example.Car", + 4, + bytes(), + 5, + Action.DELETE, + current_datetime(), + ), + EventEntry( + self.uuid_2, + "example.Car", + 2, + bytes("bye", "utf-8"), + 6, + Action.UPDATE, + current_datetime(), + ), + EventEntry( + self.uuid_4, + "example.MotorCycle", + 1, + bytes("one", "utf-8"), + 7, + Action.CREATE, + current_datetime(), + ), EventEntry( self.uuid_2, "example.Car", @@ -153,6 +209,7 @@ def setUp(self) -> None: bytes("hola", "utf-8"), 8, Action.UPDATE, + current_datetime(), transaction_uuid=self.first_transaction, ), EventEntry( @@ -162,6 +219,7 @@ def setUp(self) -> None: bytes("salut", "utf-8"), 9, Action.UPDATE, + current_datetime(), transaction_uuid=self.second_transaction, ), EventEntry( @@ -171,6 +229,7 @@ def setUp(self) -> None: bytes("adios", "utf-8"), 10, Action.UPDATE, + current_datetime(), transaction_uuid=self.first_transaction, ), ] diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py index a7203a945..c346ef8fa 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py @@ -96,63 +96,305 @@ async def test_offset(self): class TestDatabaseEventRepositorySelect(AggregateTestCase, EventRepositorySelectTestCase): __test__ = True + async def _populate(self): + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + (1, uuid4(), 1, current_datetime()), + (2, uuid4(), 2, current_datetime()), + (3, uuid4(), 1, current_datetime()), + (4, uuid4(), 3, current_datetime()), + (5, uuid4(), 4, current_datetime()), + (6, uuid4(), 2, current_datetime()), + (7, uuid4(), 1, current_datetime()), + (8, uuid4(), 3, current_datetime()), + (9, uuid4(), 3, current_datetime()), + (10, uuid4(), 4, current_datetime()), + ], + ): + await super()._populate() + def build_event_repository(self) -> EventRepository: """For testing purposes.""" return DatabaseEventRepository.from_config(self.config) async def test_select(self): - await super().test_select() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[0].as_raw().values()), + tuple(self.entries[1].as_raw().values()), + tuple(self.entries[2].as_raw().values()), + tuple(self.entries[3].as_raw().values()), + tuple(self.entries[4].as_raw().values()), + tuple(self.entries[5].as_raw().values()), + tuple(self.entries[6].as_raw().values()), + tuple(self.entries[7].as_raw().values()), + tuple(self.entries[8].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select() async def test_select_id(self): - await super().test_select_id() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[1].as_raw().values()), + ] + ), + ): + await super().test_select_id() async def test_select_id_lt(self): - await super().test_select_id_lt() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[0].as_raw().values()), + tuple(self.entries[1].as_raw().values()), + tuple(self.entries[2].as_raw().values()), + tuple(self.entries[3].as_raw().values()), + ] + ), + ): + await super().test_select_id_lt() async def test_select_id_gt(self): - await super().test_select_id_gt() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[4].as_raw().values()), + tuple(self.entries[5].as_raw().values()), + tuple(self.entries[6].as_raw().values()), + tuple(self.entries[7].as_raw().values()), + tuple(self.entries[8].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select_id_gt() async def test_select_id_le(self): - await super().test_select_id_le() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[0].as_raw().values()), + tuple(self.entries[1].as_raw().values()), + tuple(self.entries[2].as_raw().values()), + tuple(self.entries[3].as_raw().values()), + ] + ), + ): + await super().test_select_id_le() async def test_select_id_ge(self): - await super().test_select_id_ge() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[4].as_raw().values()), + tuple(self.entries[5].as_raw().values()), + tuple(self.entries[6].as_raw().values()), + tuple(self.entries[7].as_raw().values()), + tuple(self.entries[8].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select_id_ge() async def test_select_uuid(self): - await super().test_select_uuid() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[2].as_raw().values()), + tuple(self.entries[5].as_raw().values()), + tuple(self.entries[7].as_raw().values()), + tuple(self.entries[8].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select_uuid() async def test_select_name(self): - await super().test_select_name() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[6].as_raw().values()), + ] + ), + ): + await super().test_select_name() async def test_select_version(self): - await super().test_select_version() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[4].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select_version() async def test_select_version_lt(self): - await super().test_select_version_lt() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[0].as_raw().values()), + tuple(self.entries[2].as_raw().values()), + tuple(self.entries[6].as_raw().values()), + ] + ), + ): + await super().test_select_version_lt() async def test_select_version_gt(self): - await super().test_select_version_gt() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[1].as_raw().values()), + tuple(self.entries[3].as_raw().values()), + tuple(self.entries[4].as_raw().values()), + tuple(self.entries[5].as_raw().values()), + tuple(self.entries[7].as_raw().values()), + tuple(self.entries[8].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select_version_gt() async def test_select_version_le(self): - await super().test_select_version_le() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[0].as_raw().values()), + tuple(self.entries[2].as_raw().values()), + tuple(self.entries[6].as_raw().values()), + ] + ), + ): + await super().test_select_version_le() async def test_select_version_ge(self): - await super().test_select_version_ge() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[1].as_raw().values()), + tuple(self.entries[3].as_raw().values()), + tuple(self.entries[4].as_raw().values()), + tuple(self.entries[5].as_raw().values()), + tuple(self.entries[7].as_raw().values()), + tuple(self.entries[8].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select_version_ge() async def test_select_transaction_uuid_null(self): - await super().test_select_transaction_uuid_null() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[0].as_raw().values()), + tuple(self.entries[1].as_raw().values()), + tuple(self.entries[2].as_raw().values()), + tuple(self.entries[3].as_raw().values()), + tuple(self.entries[4].as_raw().values()), + tuple(self.entries[5].as_raw().values()), + tuple(self.entries[6].as_raw().values()), + ] + ), + ): + await super().test_select_transaction_uuid_null() async def test_select_transaction_uuid(self): - await super().test_select_transaction_uuid() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[7].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select_transaction_uuid() async def test_select_transaction_uuid_ne(self): - await super().test_select_transaction_uuid_ne() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[7].as_raw().values()), + tuple(self.entries[8].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select_transaction_uuid_ne() async def test_select_transaction_uuid_in(self): - await super().test_select_transaction_uuid_in() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[7].as_raw().values()), + tuple(self.entries[8].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select_transaction_uuid_in() async def test_select_combined(self): - await super().test_select_combined() + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(self.entries[2].as_raw().values()), + tuple(self.entries[5].as_raw().values()), + tuple(self.entries[7].as_raw().values()), + tuple(self.entries[8].as_raw().values()), + tuple(self.entries[9].as_raw().values()), + ] + ), + ): + await super().test_select_combined() if __name__ == "__main__": From 62a060f327e15cda6da241343df6ecad47cf3b76 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 08:50:26 +0200 Subject: [PATCH 226/324] ISSUE #98 * Increase coverage. --- .../tests/test_aggregate/test_exceptions.py | 26 ++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_exceptions.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_exceptions.py index d41042910..4ed0bf613 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_exceptions.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_exceptions.py @@ -3,25 +3,49 @@ from minos.aggregate import ( AggregateException, AlreadyDeletedException, + Event, + EventRepositoryConflictException, EventRepositoryException, NotFoundException, + SnapshotRepositoryConflictException, SnapshotRepositoryException, ) from minos.common import ( MinosException, ) +from tests.utils import ( + Car, +) class TestExceptions(unittest.TestCase): def test_base(self): self.assertTrue(issubclass(AggregateException, MinosException)) - def test_repository(self): + def test_event(self): self.assertTrue(issubclass(EventRepositoryException, AggregateException)) + def test_event_conflict(self): + message = "There was a conflict" + offset = 56 + exception = EventRepositoryConflictException(message, offset) + + self.assertIsInstance(exception, EventRepositoryException) + self.assertEqual(message, str(exception)) + self.assertEqual(offset, exception.offset) + def test_snapshot(self): self.assertTrue(issubclass(SnapshotRepositoryException, AggregateException)) + def test_snapshot_conflict(self): + entity = Car(3, "red") + event = Event.from_root_entity(entity) + exception = SnapshotRepositoryConflictException(entity, event) + + self.assertIsInstance(exception, SnapshotRepositoryException) + self.assertEqual(entity, exception.previous) + self.assertEqual(event, exception.event) + def test_snapshot_not_found(self): self.assertTrue(issubclass(NotFoundException, SnapshotRepositoryException)) From 9995152d54245db8ad46dabd038caba93a294b27 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 09:30:05 +0200 Subject: [PATCH 227/324] ISSUE #98 * Add tests for `DatabaseTransactionRepository`. --- .../minos/aggregate/exceptions.py | 2 +- .../minos/aggregate/transactions/entries.py | 14 + .../repositories/database/factories/abc.py | 7 +- .../repositories/database/impl.py | 5 +- .../tests/test_aggregate/test_exceptions.py | 15 +- .../test_transactions/test_entries.py | 21 ++ .../test_repositories/test_database.py | 331 ++++++++++++++++++ .../tests/utils.py | 2 +- .../aiopg/factories/aggregate/transactions.py | 2 + 9 files changed, 387 insertions(+), 12 deletions(-) create mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/exceptions.py b/packages/core/minos-microservice-aggregate/minos/aggregate/exceptions.py index b0d8790ba..6958a2a48 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/exceptions.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/exceptions.py @@ -40,7 +40,7 @@ class TransactionRepositoryException(AggregateException): class TransactionRepositoryConflictException(TransactionRepositoryException): - """Exception to be raised when a transactions has invalid status.""" + """Exception to be raised when a transaction has invalid status.""" class TransactionNotFoundException(TransactionRepositoryException): diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/entries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/entries.py index 2d7dd7f1f..d883c2410 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/entries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/entries.py @@ -17,6 +17,7 @@ ) from typing import ( TYPE_CHECKING, + Any, Iterable, Optional, Union, @@ -316,6 +317,19 @@ def __repr__(self): f"destination_uuid={self.destination_uuid!r}, updated_at={self.updated_at!r})" ) + def as_raw(self) -> dict[str, Any]: + """Get a raw representation of the instance. + + :return: A dictionary in which the keys are attribute names and values the attribute contents. + """ + return { + "uuid": self.uuid, + "status": self.status, + "event_offset": self.event_offset, + "destination_uuid": self.destination_uuid, + "updated_at": self.updated_at, + } + class TransactionStatus(str, Enum): """Transaction Status Enum.""" diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py index 07c09914d..18b2443a0 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py @@ -40,11 +40,7 @@ def build_create_table(self) -> DatabaseOperation: @abstractmethod def build_submit_row( - self, - uuid: UUID, - destination_uuid: UUID, - status: TransactionStatus, - event_offset: int, + self, uuid: UUID, destination_uuid: UUID, status: TransactionStatus, event_offset: int, **kwargs ) -> DatabaseOperation: """Build the database operation to submit a row. @@ -52,6 +48,7 @@ def build_submit_row( :param destination_uuid: The identifier of the destination transaction. :param status: The status of the transaction. :param event_offset: The event offset of the transaction. + :param kwargs: Additional named arguments. :return: A ``DatabaseOperation`` instance. """ diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index 202bfd326..d41b511b1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -39,10 +39,7 @@ async def _setup(self): async def _submit(self, transaction: TransactionEntry) -> TransactionEntry: operation = self.operation_factory.build_submit_row( - uuid=transaction.uuid, - destination_uuid=transaction.destination_uuid, - status=transaction.status, - event_offset=transaction.event_offset, + **transaction.as_raw(), ) try: diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_exceptions.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_exceptions.py index 4ed0bf613..6f1ca4a4a 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_exceptions.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_exceptions.py @@ -9,16 +9,19 @@ NotFoundException, SnapshotRepositoryConflictException, SnapshotRepositoryException, + TransactionRepositoryConflictException, + TransactionRepositoryException, ) from minos.common import ( MinosException, ) from tests.utils import ( + AggregateTestCase, Car, ) -class TestExceptions(unittest.TestCase): +class TestExceptions(AggregateTestCase): def test_base(self): self.assertTrue(issubclass(AggregateException, MinosException)) @@ -52,6 +55,16 @@ def test_snapshot_not_found(self): def test_snapshot_already_deleted(self): self.assertTrue(issubclass(AlreadyDeletedException, SnapshotRepositoryException)) + def test_transaction(self): + self.assertTrue(issubclass(TransactionRepositoryException, AggregateException)) + + def test_transaction_conflict(self): + message = "There was a conflict" + exception = TransactionRepositoryConflictException(message) + + self.assertIsInstance(exception, TransactionRepositoryException) + self.assertEqual(message, str(exception)) + if __name__ == "__main__": unittest.main() diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py index 32eb6d7fd..ef8f2d75b 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_entries.py @@ -1,4 +1,7 @@ import unittest +from datetime import ( + datetime, +) from unittest.mock import ( AsyncMock, MagicMock, @@ -523,6 +526,24 @@ def test_repr(self): ) self.assertEqual(expected, repr(transaction)) + def test_as_raw(self): + uuid = uuid4() + status = TransactionStatus.PENDING + event_offset = 56 + updated_at = datetime(2020, 10, 13, 8, 45, 32) + destination_uuid = uuid4() + + entry = TransactionEntry(uuid, status, event_offset, destination_uuid, updated_at) + expected = { + "uuid": uuid, + "status": status, + "event_offset": event_offset, + "destination_uuid": destination_uuid, + "updated_at": updated_at, + } + + self.assertEqual(expected, entry.as_raw()) + class TestTransactionStatus(unittest.TestCase): def test_value_of_created(self): diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py new file mode 100644 index 000000000..1aceacc66 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py @@ -0,0 +1,331 @@ +import unittest +from unittest.mock import ( + patch, +) + +from minos.aggregate import ( + DatabaseTransactionRepository, + TransactionRepository, + TransactionRepositoryConflictException, + TransactionStatus, +) +from minos.aggregate.testing import ( + TransactionRepositorySelectTestCase, + TransactionRepositorySubmitTestCase, +) +from minos.common import ( + DatabaseClient, + current_datetime, +) +from tests.utils import ( + AggregateTestCase, + FakeAsyncIterator, +) + + +# noinspection SqlNoDataSourceInspection +class TestDatabaseTransactionRepository(AggregateTestCase, TransactionRepositorySubmitTestCase): + __test__ = True + + def build_transaction_repository(self) -> TransactionRepository: + return DatabaseTransactionRepository.from_config(self.config) + + async def test_submit(self): + with patch.object( + DatabaseClient, + "fetch_one", + return_value=[current_datetime()], + ): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([(self.uuid, TransactionStatus.PENDING, 34)]), + ): + await super().test_submit() + + async def test_submit_pending_raises(self): + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + (current_datetime(),), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + ], + ): + await super().test_submit_pending_raises() + + async def test_submit_reserving_raises(self): + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + (current_datetime(),), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + ], + ): + await super().test_submit_reserving_raises() + + async def test_submit_reserved_raises(self): + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + (current_datetime(),), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + ], + ): + await super().test_submit_reserved_raises() + + async def test_submit_committing_raises(self): + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + (current_datetime(),), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + ], + ): + await super().test_submit_committing_raises() + + async def test_submit_committed_raises(self): + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + (current_datetime(),), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + ], + ): + await super().test_submit_committed_raises() + + async def test_submit_rejected_raises(self): + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + (current_datetime(),), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + TransactionRepositoryConflictException(""), + ], + ): + await super().test_submit_rejected_raises() + + +class TestDatabaseTransactionRepositorySelect(AggregateTestCase, TransactionRepositorySelectTestCase): + __test__ = True + + def build_transaction_repository(self) -> TransactionRepository: + return DatabaseTransactionRepository.from_config(self.config) + + async def _populate(self): + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + (current_datetime(),), + (current_datetime(),), + (current_datetime(),), + (current_datetime(),), + (current_datetime(),), + (current_datetime(),), + ], + ): + await super()._populate() + + async def test_select(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in self.entries]), + ): + await super().test_select() + + async def test_select_uuid(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in [self.entries[1]]]), + ): + await super().test_select_uuid() + + async def test_select_uuid_ne(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(entry.as_raw().values()) + for entry in [self.entries[0], self.entries[2], self.entries[3], self.entries[4]] + ] + ), + ): + await super().test_select_uuid_ne() + + async def test_select_uuid_in(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(entry.as_raw().values()) for entry in [self.entries[1], self.entries[2]]] + ), + ): + await super().test_select_uuid_in() + + async def test_select_destination_uuid(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in [self.entries[4]]]), + ): + await super().test_select_destination_uuid() + + async def test_select_status(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(entry.as_raw().values()) for entry in [self.entries[0], self.entries[1], self.entries[4]]] + ), + ): + await super().test_select_status() + + async def test_select_status_in(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(entry.as_raw().values()) for entry in [self.entries[2], self.entries[3]]] + ), + ): + await super().test_select_status_in() + + async def test_select_event_offset(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in [self.entries[1]]]), + ): + await super().test_select_event_offset() + + async def test_select_event_offset_lt(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in [self.entries[0]]]), + ): + await super().test_select_event_offset_lt() + + async def test_select_event_offset_gt(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(entry.as_raw().values()) for entry in [self.entries[2], self.entries[3], self.entries[4]]] + ), + ): + await super().test_select_event_offset_gt() + + async def test_select_event_offset_le(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(entry.as_raw().values()) for entry in [self.entries[0], self.entries[1]]] + ), + ): + await super().test_select_event_offset_le() + + async def test_select_event_offset_ge(self): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [ + tuple(entry.as_raw().values()) + for entry in [self.entries[1], self.entries[2], self.entries[3], self.entries[4]] + ] + ), + ): + await super().test_select_event_offset_ge() + + async def test_select_updated_at(self): + with patch.object( + DatabaseClient, + "fetch_all", + side_effect=[ + FakeAsyncIterator([tuple(self.entries[2].as_raw().values())]), + FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in [self.entries[2]]]), + ], + ): + await super().test_select_updated_at() + + async def test_select_updated_at_lt(self): + with patch.object( + DatabaseClient, + "fetch_all", + side_effect=[ + FakeAsyncIterator([tuple(self.entries[2].as_raw().values())]), + FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in [self.entries[0], self.entries[1]]]), + ], + ): + await super().test_select_updated_at_lt() + + async def test_select_updated_at_gt(self): + with patch.object( + DatabaseClient, + "fetch_all", + side_effect=[ + FakeAsyncIterator([tuple(self.entries[2].as_raw().values())]), + FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in [self.entries[3], self.entries[4]]]), + ], + ): + await super().test_select_updated_at_gt() + + async def test_select_updated_at_le(self): + with patch.object( + DatabaseClient, + "fetch_all", + side_effect=[ + FakeAsyncIterator([tuple(self.entries[2].as_raw().values())]), + FakeAsyncIterator( + [tuple(entry.as_raw().values()) for entry in [self.entries[0], self.entries[1], self.entries[2]]] + ), + ], + ): + await super().test_select_updated_at_le() + + async def test_select_updated_at_ge(self): + with patch.object( + DatabaseClient, + "fetch_all", + side_effect=[ + FakeAsyncIterator([tuple(self.entries[2].as_raw().values())]), + FakeAsyncIterator( + [tuple(entry.as_raw().values()) for entry in [self.entries[2], self.entries[3], self.entries[4]]] + ), + ], + ): + await super().test_select_updated_at_ge() + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 8385ba50a..a5daee718 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -171,7 +171,7 @@ def build_create_table(self) -> DatabaseOperation: return FakeDatabaseOperation("create") def build_submit_row( - self, uuid: UUID, destination_uuid: UUID, status: TransactionStatus, event_offset: int + self, uuid: UUID, destination_uuid: UUID, status: TransactionStatus, event_offset: int, **kwargs ) -> DatabaseOperation: """For testing purposes.""" return FakeDatabaseOperation("submit") diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py index 3a7ac8d58..78a70baf0 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py @@ -87,6 +87,7 @@ def build_submit_row( destination_uuid: UUID, status: TransactionStatus, event_offset: int, + **kwargs, ) -> DatabaseOperation: """Build the database operation to submit a row. @@ -94,6 +95,7 @@ def build_submit_row( :param destination_uuid: The identifier of the destination transaction. :param status: The status of the transaction. :param event_offset: The event offset of the transaction. + :param kwargs: Additional named arguments. :return: A ``DatabaseOperation`` instance. """ From c6146dcc8c95729b1368ea675dd0d058abf70bdd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 09:33:59 +0200 Subject: [PATCH 228/324] ISSUE #98 * Increase coverage. --- .../tests/test_aggregate/test_events/test_entries.py | 5 +++++ .../test_events/test_repositories/test_abc.py | 7 ++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_entries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_entries.py index a2941bdfc..6e0e532e4 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_entries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_entries.py @@ -39,6 +39,11 @@ def test_constructor(self): self.assertEqual(None, entry.created_at) self.assertEqual(NULL_UUID, entry.transaction_uuid) + # noinspection SpellCheckingInspection + def test_constructor_with_memoryview(self): + entry = EventEntry(self.uuid, "example.Car", 0, memoryview(bytes("car", "utf-8"))) + self.assertEqual(bytes("car", "utf-8"), entry.data) + def test_constructor_extended(self): entry = EventEntry( uuid=self.uuid, diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py index 19e0d76af..90a09c8ee 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_abc.py @@ -35,6 +35,7 @@ NULL_UUID, NotProvidedException, SetupMixin, + classname, current_datetime, ) from minos.networks import ( @@ -42,6 +43,7 @@ ) from tests.utils import ( AggregateTestCase, + Car, FakeAsyncIterator, FakeLock, ) @@ -465,17 +467,16 @@ async def test_select(self): self.event_repository._select = mock uuid = uuid4() - name = "path.to.Product" transaction_uuid = uuid4() - iterable = self.event_repository.select(uuid=uuid, name=name, id_gt=56, transaction_uuid=transaction_uuid) + iterable = self.event_repository.select(uuid=uuid, name=Car, id_gt=56, transaction_uuid=transaction_uuid) observed = [a async for a in iterable] self.assertEqual(list(range(5)), observed) self.assertEqual(1, mock.call_count) args = call( uuid=uuid, - name=name, + name=classname(Car), version=None, version_lt=None, version_gt=None, From 7610ff7c97310d5276413ab658b88c792b40185c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 09:51:15 +0200 Subject: [PATCH 229/324] ISSUE #98 * Increase coverage (2). --- .../minos/aggregate/snapshots/entries.py | 2 +- .../test_events/test_entries.py | 2 +- .../test_snapshots/test_entries.py | 85 +++++++++++++++++++ 3 files changed, 87 insertions(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py index 73b8afab1..326e52a88 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py @@ -59,7 +59,7 @@ def __init__( uuid: UUID, name: str, version: int, - schema: Optional[Union[list[dict[str, Any]], dict[str, Any]]] = None, + schema: Optional[Union[list[dict[str, Any]], dict[str, Any]], bytes, memoryview] = None, data: Optional[dict[str, Any]] = None, created_at: Optional[datetime] = None, updated_at: Optional[datetime] = None, diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_entries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_entries.py index 6e0e532e4..cf57c6055 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_entries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_entries.py @@ -40,7 +40,7 @@ def test_constructor(self): self.assertEqual(NULL_UUID, entry.transaction_uuid) # noinspection SpellCheckingInspection - def test_constructor_with_memoryview(self): + def test_constructor_with_memoryview_data(self): entry = EventEntry(self.uuid, "example.Car", 0, memoryview(bytes("car", "utf-8"))) self.assertEqual(bytes("car", "utf-8"), entry.data) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py index a3408b759..6d597c56d 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_entries.py @@ -1,3 +1,4 @@ +import json import unittest from datetime import ( datetime, @@ -10,8 +11,14 @@ ) from minos.aggregate import ( + AlreadyDeletedException, + Event, + EventEntry, SnapshotEntry, ) +from minos.common import ( + MinosJsonBinaryProtocol, +) from tests.utils import ( AggregateTestCase, Car, @@ -41,6 +48,17 @@ def test_constructor(self): self.assertEqual(None, entry.created_at) self.assertEqual(None, entry.updated_at) + def test_constructor_with_bytes_schema(self): + raw = MinosJsonBinaryProtocol.encode(self.schema) + entry = SnapshotEntry(self.uuid, "example.Car", 0, raw, self.data) + self.assertEqual(self.schema, entry.schema) + + # noinspection SpellCheckingInspection + def test_constructor_with_memoryview_schema(self): + raw = memoryview(MinosJsonBinaryProtocol.encode(self.schema)) + entry = SnapshotEntry(self.uuid, "example.Car", 0, raw, self.data) + self.assertEqual(self.schema, entry.schema) + def test_constructor_extended(self): entry = SnapshotEntry( self.uuid, @@ -71,6 +89,18 @@ def test_from_root_entity(self): self.assertEqual(car.created_at, entry.created_at) self.assertEqual(car.updated_at, entry.updated_at) + def test_from_event_entry(self): + car = Car(3, "blue", uuid=self.uuid, version=1) + event_entry = EventEntry.from_event(Event.from_root_entity(car), version=1) + with patch("minos.common.AvroSchemaEncoder.generate_random_str", return_value="hello"): + snapshot_entry = SnapshotEntry.from_event_entry(event_entry) + self.assertEqual(event_entry.uuid, snapshot_entry.uuid) + self.assertEqual(event_entry.name, snapshot_entry.name) + self.assertEqual(event_entry.version, snapshot_entry.version) + self.assertEqual(event_entry.created_at, snapshot_entry.created_at) + self.assertEqual(event_entry.created_at, snapshot_entry.updated_at) + self.assertEqual(event_entry.transaction_uuid, snapshot_entry.transaction_uuid) + def test_equals(self): a = SnapshotEntry(self.uuid, "example.Car", 0, self.schema, self.data) b = SnapshotEntry(self.uuid, "example.Car", 0, self.schema, self.data) @@ -86,6 +116,12 @@ def test_build(self): entry = SnapshotEntry.from_root_entity(car) self.assertEqual(car, entry.build()) + def test_build_raises(self): + entry = SnapshotEntry(uuid=self.uuid, name="example.Car", version=0, schema=self.schema) + + with self.assertRaises(AlreadyDeletedException): + entry.build() + def test_repr(self): name = "example.Car" version = 0 @@ -112,6 +148,55 @@ def test_repr(self): self.assertEqual(expected, repr(entry)) + def test_as_raw(self): + name = "example.Car" + version = 0 + created_at = datetime(2020, 1, 10, 4, 23) + updated_at = datetime(2020, 1, 10, 4, 25) + transaction_uuid = uuid4() + + entry = SnapshotEntry( + uuid=self.uuid, + name=name, + version=version, + schema=self.schema, + data=self.data, + created_at=created_at, + updated_at=updated_at, + transaction_uuid=transaction_uuid, + ) + + expected = { + "created_at": created_at, + "data": json.dumps(self.data), + "name": name, + "schema": MinosJsonBinaryProtocol.encode(self.schema), + "transaction_uuid": transaction_uuid, + "updated_at": updated_at, + "uuid": self.uuid, + "version": version, + } + + self.assertEqual(expected, entry.as_raw()) + + def test_encoded_schema(self): + entry = SnapshotEntry(uuid=self.uuid, name="example.Car", version=0, schema=self.schema) + expected = MinosJsonBinaryProtocol.encode(self.schema) + self.assertEqual(expected, entry.encoded_schema) + + def test_encoded_schema_none(self): + entry = SnapshotEntry(uuid=self.uuid, name="example.Car", version=0) + self.assertEqual(None, entry.encoded_schema) + + def test_encoded_data(self): + entry = SnapshotEntry(uuid=self.uuid, name="example.Car", version=0, schema=self.schema, data=self.data) + expected = json.dumps(self.data) + self.assertEqual(expected, entry.encoded_data) + + def test_encoded_none(self): + entry = SnapshotEntry(uuid=self.uuid, name="example.Car", version=0, schema=self.schema) + self.assertEqual(None, entry.encoded_data) + if __name__ == "__main__": unittest.main() From cd86d13a7eccf4e8e50e9f978bc930fd4301f1f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 09:55:13 +0200 Subject: [PATCH 230/324] ISSUE #98 * Remove unused method. --- .../minos/aggregate/testing/snapshot_repository.py | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py index 0d7e017a8..3ad429695 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py @@ -657,16 +657,4 @@ async def test_find_all(self): updated_at=observed[1].updated_at, ), ] - self.assertEqual(expected, observed) - - def _assert_equal_snapshot_entries(self, expected: list[SnapshotEntry], observed: list[SnapshotEntry]): - self.assertEqual(len(expected), len(observed)) - for exp, obs in zip(expected, observed): - if exp.data is None: - with self.assertRaises(AlreadyDeletedException): - # noinspection PyStatementEffect - obs.build() - else: - self.assertEqual(exp.build(), obs.build()) - self.assertIsInstance(obs.created_at, datetime) - self.assertIsInstance(obs.updated_at, datetime) + self.assertEqual(expected, observed) \ No newline at end of file From 4003cceb278ad6a450f56c9ef0479686fb7378b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 10:49:18 +0200 Subject: [PATCH 231/324] ISSUE #98 * Simplify `minos.aggregate.snapshots.repositories.database` module removing `DatabaseSnapshotReader`, `DatabaseSnapshotWriter` and `DatabaseSnapshotSetup`. --- .../minos/aggregate/__init__.py | 3 - .../minos/aggregate/snapshots/__init__.py | 3 - .../snapshots/repositories/__init__.py | 3 - .../repositories/database/__init__.py | 13 +- .../snapshots/repositories/database/abc.py | 32 ----- .../snapshots/repositories/database/api.py | 81 ----------- .../database/{writers.py => impl.py} | 119 +++++++++++++--- .../repositories/database/readers.py | 131 ------------------ .../aggregate/testing/snapshot_repository.py | 11 +- .../test_repositories/test_pg/__init__.py | 1 - .../test_repositories/test_pg/test_api.py | 98 ------------- .../test_aggregate/test_snapshots/test_pg.py | 2 +- 12 files changed, 116 insertions(+), 381 deletions(-) delete mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/abc.py delete mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/api.py rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/{writers.py => impl.py} (57%) delete mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/readers.py delete mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/__init__.py delete mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/test_api.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index e0af6e649..f7a19f75d 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -58,10 +58,7 @@ Ordering, ) from .snapshots import ( - DatabaseSnapshotReader, DatabaseSnapshotRepository, - DatabaseSnapshotSetup, - DatabaseSnapshotWriter, InMemorySnapshotRepository, SnapshotDatabaseOperationFactory, SnapshotEntry, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py index c98072570..fa4e34c31 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/__init__.py @@ -2,10 +2,7 @@ SnapshotEntry, ) from .repositories import ( - DatabaseSnapshotReader, DatabaseSnapshotRepository, - DatabaseSnapshotSetup, - DatabaseSnapshotWriter, InMemorySnapshotRepository, SnapshotDatabaseOperationFactory, SnapshotRepository, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/__init__.py index 50896c892..172c54117 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/__init__.py @@ -2,10 +2,7 @@ SnapshotRepository, ) from .database import ( - DatabaseSnapshotReader, DatabaseSnapshotRepository, - DatabaseSnapshotSetup, - DatabaseSnapshotWriter, SnapshotDatabaseOperationFactory, ) from .memory import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/__init__.py index c14f7e6ef..d45559535 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/__init__.py @@ -1,15 +1,6 @@ -from .abc import ( - DatabaseSnapshotSetup, -) -from .api import ( - DatabaseSnapshotRepository, -) from .factories import ( SnapshotDatabaseOperationFactory, ) -from .readers import ( - DatabaseSnapshotReader, -) -from .writers import ( - DatabaseSnapshotWriter, +from .impl import ( + DatabaseSnapshotRepository, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/abc.py deleted file mode 100644 index 588ea7f6c..000000000 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/abc.py +++ /dev/null @@ -1,32 +0,0 @@ -from __future__ import ( - annotations, -) - -from typing import ( - Type, - TypeVar, -) - -from minos.common import ( - Config, - DatabaseMixin, -) - -from .factories import ( - SnapshotDatabaseOperationFactory, -) - - -class DatabaseSnapshotSetup(DatabaseMixin[SnapshotDatabaseOperationFactory]): - """Minos Snapshot Setup Class""" - - @classmethod - def _from_config(cls: Type[T], config: Config, **kwargs) -> T: - return cls(database_key=None, **kwargs) - - async def _setup(self) -> None: - operation = self.operation_factory.build_create_table() - await self.submit_query(operation) - - -T = TypeVar("T", bound=DatabaseSnapshotSetup) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/api.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/api.py deleted file mode 100644 index fa12040ed..000000000 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/api.py +++ /dev/null @@ -1,81 +0,0 @@ -from __future__ import ( - annotations, -) - -from typing import ( - TYPE_CHECKING, - AsyncIterator, - Awaitable, -) - -from minos.common import ( - Config, -) - -from ..abc import ( - SnapshotRepository, -) -from .readers import ( - DatabaseSnapshotReader, -) -from .writers import ( - DatabaseSnapshotWriter, -) - -if TYPE_CHECKING: - from ....entities import ( - RootEntity, - ) - - -class DatabaseSnapshotRepository(SnapshotRepository): - """Database Snapshot Repository class. - - The snapshot provides a direct accessor to the ``RootEntity`` instances stored as events by the event repository - class. - """ - - reader: DatabaseSnapshotReader - writer: DatabaseSnapshotWriter - - def __init__(self, *args, reader: DatabaseSnapshotReader, writer: DatabaseSnapshotWriter, **kwargs): - super().__init__(*args, **kwargs) - self.reader = reader - self.writer = writer - - @classmethod - def _from_config(cls, config: Config, **kwargs) -> DatabaseSnapshotRepository: - if "reader" not in kwargs: - kwargs["reader"] = DatabaseSnapshotReader.from_config(config, **kwargs) - - if "writer" not in kwargs: - kwargs["writer"] = DatabaseSnapshotWriter.from_config(config, **kwargs) - - return cls(database_key=None, **kwargs) - - async def _setup(self) -> None: - await self.writer.setup() - await self.reader.setup() - await super()._setup() - - async def _destroy(self) -> None: - await super()._destroy() - await self.reader.destroy() - await self.writer.destroy() - - def _get(self, *args, **kwargs) -> Awaitable[RootEntity]: - return self.reader.get(*args, **kwargs) - - def _find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: - return self.reader.find(*args, **kwargs) - - def _synchronize(self, *args, **kwargs) -> Awaitable[None]: - return self.writer.dispatch(**kwargs) - - @property - def find_entries(self): - return self.reader.find_entries - - @property - def is_synced(self): - return self.writer.is_synced diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/writers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py similarity index 57% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/writers.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py index f844008aa..fef497e55 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/writers.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py @@ -2,15 +2,20 @@ annotations, ) +from collections.abc import ( + AsyncIterator, +) from typing import ( TYPE_CHECKING, - Type, + Optional, ) from uuid import ( UUID, ) from minos.common import ( + NULL_UUID, + Config, Inject, NotProvidedException, import_module, @@ -26,18 +31,21 @@ SnapshotRepositoryConflictException, TransactionNotFoundException, ) +from ....queries import ( + _Condition, + _EqualCondition, + _Ordering, +) from ....transactions import ( + TransactionEntry, TransactionRepository, TransactionStatus, ) from ...entries import ( SnapshotEntry, ) -from .abc import ( - DatabaseSnapshotSetup, -) -from .readers import ( - DatabaseSnapshotReader, +from ..abc import ( + SnapshotRepository, ) if TYPE_CHECKING: @@ -46,14 +54,17 @@ ) -class DatabaseSnapshotWriter(DatabaseSnapshotSetup): - """Minos Snapshot Dispatcher class.""" +class DatabaseSnapshotRepository(SnapshotRepository): + """Database Snapshot Repository class. + + The snapshot provides a direct accessor to the ``RootEntity`` instances stored as events by the event repository + class. + """ @Inject() def __init__( self, *args, - reader: DatabaseSnapshotReader, event_repository: EventRepository, transaction_repository: TransactionRepository, **kwargs, @@ -66,10 +77,90 @@ def __init__( if transaction_repository is None: raise NotProvidedException("A transaction repository instance is required.") - self._reader = reader self._event_repository = event_repository self._transaction_repository = transaction_repository + @classmethod + def _from_config(cls, config: Config, **kwargs) -> DatabaseSnapshotRepository: + return cls(database_key=None, **kwargs) + + async def _setup(self) -> None: + operation = self.operation_factory.build_create_table() + await self.submit_query(operation) + + async def _destroy(self) -> None: + await super()._destroy() + + async def _get(self, name: str, uuid: UUID, **kwargs) -> RootEntity: + snapshot_entry = await self.get_entry(name, uuid, **kwargs) + instance = snapshot_entry.build(**kwargs) + return instance + + # noinspection PyUnusedLocal + + async def get_entry(self, name: str, uuid: UUID, **kwargs) -> SnapshotEntry: + """Get a ``SnapshotEntry`` from its identifier. + + :param name: Class name of the ``RootEntity``. + :param uuid: Identifier of the ``RootEntity``. + :param kwargs: Additional named arguments. + :return: The ``SnapshotEntry`` instance. + """ + + try: + return await self.find_entries( + name, _EqualCondition("uuid", uuid), **kwargs | {"exclude_deleted": False} + ).__anext__() + except StopAsyncIteration: + raise NotFoundException(f"The instance could not be found: {uuid!s}") + + async def _find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: + async for snapshot_entry in self.find_entries(*args, **kwargs): + yield snapshot_entry.build(**kwargs) + + # noinspection PyUnusedLocal + + async def find_entries( + self, + name: str, + condition: _Condition, + ordering: Optional[_Ordering] = None, + limit: Optional[int] = None, + streaming_mode: bool = False, + transaction: Optional[TransactionEntry] = None, + exclude_deleted: bool = True, + **kwargs, + ) -> AsyncIterator[SnapshotEntry]: + """Find a collection of ``SnapshotEntry`` instances based on a ``Condition``. + + :param name: Class name of the ``RootEntity``. + :param condition: The condition that must be satisfied by the ``RootEntity`` instances. + :param ordering: Optional argument to return the instance with specific ordering strategy. The default behaviour + is to retrieve them without any order pattern. + :param limit: Optional argument to return only a subset of instances. The default behaviour is to return all the + instances that meet the given condition. + :param streaming_mode: If ``True`` return the values in streaming directly from the database (keep an open + database connection), otherwise preloads the full set of values on memory and then retrieves them. + :param transaction: The transaction within the operation is performed. If not any value is provided, then the + transaction is extracted from the context var. If not any transaction is being scoped then the query is + performed to the global snapshot. + :param exclude_deleted: If ``True``, deleted ``RootEntity`` entries are included, otherwise deleted + ``RootEntity`` entries are filtered. + :param kwargs: Additional named arguments. + :return: An asynchronous iterator that containing the ``RootEntity`` instances. + """ + if transaction is None: + transaction_uuids = (NULL_UUID,) + else: + transaction_uuids = await transaction.uuids + + operation = self.operation_factory.build_query( + name, condition, ordering, limit, transaction_uuids, exclude_deleted + ) + + async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): + yield SnapshotEntry(*row) + async def is_synced(self, name: str, **kwargs) -> bool: """Check if the snapshot has the latest version of a ``RootEntity`` instance. @@ -84,11 +175,7 @@ async def is_synced(self, name: str, **kwargs) -> bool: except StopAsyncIteration: return True - async def dispatch(self, **kwargs) -> None: - """Perform a dispatching step, based on the sequence of non already processed ``EventEntry`` objects. - - :return: This method does not return anything. - """ + async def _synchronize(self, **kwargs) -> None: initial_offset = await self._load_offset() offset = initial_offset @@ -153,7 +240,7 @@ async def _update_instance_if_exists(self, event: Event, **kwargs) -> RootEntity previous = await self._select_one_instance(event.name, event.uuid, **kwargs) except NotFoundException: # noinspection PyTypeChecker - cls: Type[RootEntity] = import_module(event.name) + cls = import_module(event.name) return cls.from_diff(event, **kwargs) if previous.version >= event.version: diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/readers.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/readers.py deleted file mode 100644 index 972d1c6a1..000000000 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/readers.py +++ /dev/null @@ -1,131 +0,0 @@ -from __future__ import ( - annotations, -) - -import logging -from typing import ( - TYPE_CHECKING, - AsyncIterator, - Optional, -) -from uuid import ( - UUID, -) - -from minos.common import ( - NULL_UUID, -) - -from ....exceptions import ( - NotFoundException, -) -from ....queries import ( - _Condition, - _EqualCondition, - _Ordering, -) -from ....transactions import ( - TransactionEntry, -) -from ...entries import ( - SnapshotEntry, -) -from .abc import ( - DatabaseSnapshotSetup, -) - -if TYPE_CHECKING: - from ....entities import ( - RootEntity, - ) - -logger = logging.getLogger(__name__) - - -class DatabaseSnapshotReader(DatabaseSnapshotSetup): - """Database Snapshot Reader class. - - The snapshot provides a direct accessor to the ``RootEntity`` instances stored as events by the event repository - class. - """ - - async def get(self, name: str, uuid: UUID, **kwargs) -> RootEntity: - """Get a ``RootEntity`` instance from its identifier. - - :param name: Class name of the ``RootEntity``. - :param uuid: Identifier of the ``RootEntity``. - :param kwargs: Additional named arguments. - :return: The ``RootEntity`` instance. - """ - snapshot_entry = await self.get_entry(name, uuid, **kwargs) - instance = snapshot_entry.build(**kwargs) - return instance - - # noinspection PyUnusedLocal - async def get_entry(self, name: str, uuid: UUID, **kwargs) -> SnapshotEntry: - """Get a ``SnapshotEntry`` from its identifier. - - :param name: Class name of the ``RootEntity``. - :param uuid: Identifier of the ``RootEntity``. - :param kwargs: Additional named arguments. - :return: The ``SnapshotEntry`` instance. - """ - - try: - return await self.find_entries( - name, _EqualCondition("uuid", uuid), **kwargs | {"exclude_deleted": False} - ).__anext__() - except StopAsyncIteration: - raise NotFoundException(f"The instance could not be found: {uuid!s}") - - async def find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: - """Find a collection of ``RootEntity`` instances based on a ``Condition``. - - :param args: Additional positional arguments. - :param kwargs: Additional named arguments. - :return: An asynchronous iterator that containing the ``RootEntity`` instances. - """ - async for snapshot_entry in self.find_entries(*args, **kwargs): - yield snapshot_entry.build(**kwargs) - - # noinspection PyUnusedLocal - async def find_entries( - self, - name: str, - condition: _Condition, - ordering: Optional[_Ordering] = None, - limit: Optional[int] = None, - streaming_mode: bool = False, - transaction: Optional[TransactionEntry] = None, - exclude_deleted: bool = True, - **kwargs, - ) -> AsyncIterator[SnapshotEntry]: - """Find a collection of ``SnapshotEntry`` instances based on a ``Condition``. - - :param name: Class name of the ``RootEntity``. - :param condition: The condition that must be satisfied by the ``RootEntity`` instances. - :param ordering: Optional argument to return the instance with specific ordering strategy. The default behaviour - is to retrieve them without any order pattern. - :param limit: Optional argument to return only a subset of instances. The default behaviour is to return all the - instances that meet the given condition. - :param streaming_mode: If ``True`` return the values in streaming directly from the database (keep an open - database connection), otherwise preloads the full set of values on memory and then retrieves them. - :param transaction: The transaction within the operation is performed. If not any value is provided, then the - transaction is extracted from the context var. If not any transaction is being scoped then the query is - performed to the global snapshot. - :param exclude_deleted: If ``True``, deleted ``RootEntity`` entries are included, otherwise deleted - ``RootEntity`` entries are filtered. - :param kwargs: Additional named arguments. - :return: An asynchronous iterator that containing the ``RootEntity`` instances. - """ - if transaction is None: - transaction_uuids = (NULL_UUID,) - else: - transaction_uuids = await transaction.uuids - - operation = self.operation_factory.build_query( - name, condition, ordering, limit, transaction_uuids, exclude_deleted - ) - - async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): - yield SnapshotEntry(*row) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py index 3ad429695..b9394aa88 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py @@ -100,6 +100,7 @@ def setUp(self) -> None: self.transaction_1 = uuid4() self.transaction_2 = uuid4() self.transaction_3 = uuid4() + self.transaction_4 = uuid4() async def asyncSetUp(self): await super().asyncSetUp() @@ -138,6 +139,11 @@ async def _populate(self): await self.transaction_repository.submit( TransactionEntry(self.transaction_3, TransactionStatus.REJECTED, await self.event_repository.offset) ) + await self.transaction_repository.submit( + TransactionEntry( + self.transaction_4, TransactionStatus.REJECTED, await self.event_repository.offset, self.transaction_3 + ) + ) def test_type(self): self.assertTrue(isinstance(self.snapshot_repository, SnapshotRepository)) @@ -491,7 +497,10 @@ async def test_find_with_transaction_reverted(self): condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) iterable = self.snapshot_repository.find( - Car, condition, ordering=Ordering.ASC("updated_at"), transaction_uuid=self.transaction_3 + Car, + condition, + ordering=Ordering.ASC("updated_at"), + transaction=TransactionEntry(self.transaction_4), ) observed = [v async for v in iterable] diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/__init__.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/__init__.py deleted file mode 100644 index 8b1378917..000000000 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/__init__.py +++ /dev/null @@ -1 +0,0 @@ - diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/test_api.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/test_api.py deleted file mode 100644 index 45c387dc9..000000000 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_pg/test_api.py +++ /dev/null @@ -1,98 +0,0 @@ -import unittest -from unittest.mock import ( - AsyncMock, - MagicMock, - call, -) -from uuid import ( - uuid4, -) - -from minos.aggregate import ( - Condition, - DatabaseSnapshotReader, - DatabaseSnapshotRepository, - DatabaseSnapshotWriter, - Ordering, - TransactionEntry, -) -from minos.common.testing import ( - DatabaseMinosTestCase, -) -from tests.utils import ( - AggregateTestCase, - FakeAsyncIterator, -) - - -class TestDatabaseSnapshotRepository(AggregateTestCase, DatabaseMinosTestCase): - def setUp(self) -> None: - super().setUp() - - self.snapshot_repository = DatabaseSnapshotRepository.from_config(self.config) - - self.dispatch_mock = AsyncMock() - self.get_mock = AsyncMock(return_value=1) - self.find_mock = MagicMock(return_value=FakeAsyncIterator(range(5))) - self.snapshot_repository.reader.get = self.get_mock - self.snapshot_repository.reader.find = self.find_mock - self.snapshot_repository.writer.dispatch = self.dispatch_mock - - self.classname = "path.to.Product" - - async def asyncSetUp(self): - await super().asyncSetUp() - await self.snapshot_repository.setup() - - async def asyncTearDown(self): - await self.snapshot_repository.destroy() - await super().asyncTearDown() - - def test_from_config(self): - self.assertIsInstance(self.snapshot_repository.reader, DatabaseSnapshotReader) - self.assertIsInstance(self.snapshot_repository.writer, DatabaseSnapshotWriter) - - async def test_get(self): - transaction = TransactionEntry() - uuid = uuid4() - observed = await self.snapshot_repository.get(self.classname, uuid, transaction) - self.assertEqual(1, observed) - - self.assertEqual(1, self.dispatch_mock.call_count) - self.assertEqual(call(), self.dispatch_mock.call_args) - - self.assertEqual(1, self.get_mock.call_count) - args = call(name=self.classname, uuid=uuid, transaction=transaction) - self.assertEqual(args, self.get_mock.call_args) - - async def test_find(self): - transaction = TransactionEntry() - iterable = self.snapshot_repository.find( - self.classname, Condition.TRUE, Ordering.ASC("name"), 10, True, transaction - ) - observed = [a async for a in iterable] - self.assertEqual(list(range(5)), observed) - - self.assertEqual(1, self.dispatch_mock.call_count) - self.assertEqual(call(), self.dispatch_mock.call_args) - - self.assertEqual(1, self.find_mock.call_count) - args = call( - name=self.classname, - condition=Condition.TRUE, - ordering=Ordering.ASC("name"), - limit=10, - streaming_mode=True, - transaction=transaction, - ) - self.assertEqual(args, self.find_mock.call_args) - - async def test_synchronize(self): - await self.snapshot_repository.synchronize() - - self.assertEqual(1, self.dispatch_mock.call_count) - self.assertEqual(call(), self.dispatch_mock.call_args) - - -if __name__ == "__main__": - unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py index bc93b11c8..48a2d627c 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py @@ -51,7 +51,7 @@ async def test_is_synced(self): self.assertTrue(await self.snapshot_repository.is_synced(Car)) -class TestDatabaseSnapshotReader(AiopgTestCase, SnapshotRepositoryReaderTestCase): +class TestDatabaseSnapshotRepositoryReader(AiopgTestCase, SnapshotRepositoryReaderTestCase): __test__ = True def build_snapshot_repository(self): From 36f76ff273ddfd0e694620bdec4372d00faa5b72 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 10:52:47 +0200 Subject: [PATCH 232/324] ISSUE #98 * Minor renaming. --- .../minos/aggregate/testing/event_repository.py | 4 ++-- .../minos/aggregate/testing/snapshot_repository.py | 8 ++++---- .../minos/aggregate/testing/transaction_repository.py | 4 ++-- .../test_events/test_repositories/test_database.py | 4 ++-- .../test_transactions/test_repositories/test_database.py | 4 ++-- 5 files changed, 12 insertions(+), 12 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py index 1a772528a..3940828ee 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py @@ -236,9 +236,9 @@ def setUp(self) -> None: async def asyncSetUp(self): await super().asyncSetUp() - await self._populate() + await self.populate() - async def _populate(self): + async def populate(self) -> None: await self.transaction_repository.submit(TransactionEntry(self.first_transaction)) await self.transaction_repository.submit(TransactionEntry(self.second_transaction)) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py index b9394aa88..1e9b77ab7 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py @@ -104,9 +104,9 @@ def setUp(self) -> None: async def asyncSetUp(self): await super().asyncSetUp() - await self._populate() + await self.populate() - async def _populate(self): + async def populate(self) -> None: diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) # noinspection PyTypeChecker name: str = Car.classname @@ -371,9 +371,9 @@ def setUp(self) -> None: async def asyncSetUp(self): await super().asyncSetUp() - await self._populate() + await self.populate() - async def _populate(self): + async def populate(self) -> None: diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) # noinspection PyTypeChecker name: str = Car.classname diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py index 0738a3908..8cec2c535 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py @@ -155,9 +155,9 @@ def setUp(self) -> None: async def asyncSetUp(self): await super().asyncSetUp() - await self._populate() + await self.populate() - async def _populate(self): + async def populate(self) -> None: await self.transaction_repository.submit(TransactionEntry(self.uuid_1, TransactionStatus.PENDING, 12)) await self.transaction_repository.submit(TransactionEntry(self.uuid_2, TransactionStatus.PENDING, 15)) await self.transaction_repository.submit(TransactionEntry(self.uuid_3, TransactionStatus.REJECTED, 16)) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py index c346ef8fa..57b788783 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py @@ -96,7 +96,7 @@ async def test_offset(self): class TestDatabaseEventRepositorySelect(AggregateTestCase, EventRepositorySelectTestCase): __test__ = True - async def _populate(self): + async def populate(self) -> None: with patch.object( DatabaseClient, "fetch_one", @@ -113,7 +113,7 @@ async def _populate(self): (10, uuid4(), 4, current_datetime()), ], ): - await super()._populate() + await super().populate() def build_event_repository(self) -> EventRepository: """For testing purposes.""" diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py index 1aceacc66..fa9fb59d4 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py @@ -136,7 +136,7 @@ class TestDatabaseTransactionRepositorySelect(AggregateTestCase, TransactionRepo def build_transaction_repository(self) -> TransactionRepository: return DatabaseTransactionRepository.from_config(self.config) - async def _populate(self): + async def populate(self) -> None: with patch.object( DatabaseClient, "fetch_one", @@ -149,7 +149,7 @@ async def _populate(self): (current_datetime(),), ], ): - await super()._populate() + await super().populate() async def test_select(self): with patch.object( From 68e078bbff57491334b9c5a975fb656212c06324 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 11:03:52 +0200 Subject: [PATCH 233/324] ISSUE #98 * Refactor `EventRepositoryTestCase`. --- .../minos/aggregate/testing/__init__.py | 2 - .../aggregate/testing/event_repository.py | 186 +++++++++--------- .../test_repositories/test_database.py | 8 +- .../test_repositories/test_memory.py | 13 +- .../test_aggregate/test_events/test_pg.py | 13 +- 5 files changed, 101 insertions(+), 121 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py index a4757c607..6ba595c38 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py @@ -1,6 +1,4 @@ from .event_repository import ( - EventRepositorySelectTestCase, - EventRepositorySubmitTestCase, EventRepositoryTestCase, ) from .snapshot_repository import ( diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py index 3940828ee..e7d8ee72e 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py @@ -33,104 +33,18 @@ ) -class EventRepositoryTestCase(MinosTestCase): +class EventRepositoryTestCase(MinosTestCase, ABC): + __test__ = False + def setUp(self) -> None: super().setUp() - self.uuid = uuid4() - self.event_repository = self.build_event_repository() self.field_diff_container_patcher = patch( "minos.aggregate.FieldDiffContainer.from_avro_bytes", return_value=FieldDiffContainer.empty() ) self.field_diff_container_patcher.start() - async def asyncSetUp(self): - await super().asyncSetUp() - await self.event_repository.setup() - - async def asyncTearDown(self): - await self.event_repository.destroy() - await super().asyncTearDown() - - def tearDown(self): - self.field_diff_container_patcher.stop() - super().tearDown() - - @abstractmethod - def build_event_repository(self) -> EventRepository: - """For testing purposes.""" - - def assert_equal_repository_entries(self, expected: list[EventEntry], observed: list[EventEntry]) -> None: - """For testing purposes.""" - - self.assertEqual(len(expected), len(observed)) - - for e, o in zip(expected, observed): - self.assertEqual(type(e), type(o)) - self.assertEqual(e.uuid, o.uuid) - self.assertEqual(e.name, o.name) - self.assertEqual(e.version, o.version) - self.assertEqual(e.data, o.data) - self.assertEqual(e.id, o.id) - self.assertEqual(e.action, o.action) - self.assertAlmostEqual(e.created_at or current_datetime(), o.created_at, delta=timedelta(seconds=5)) - - -class EventRepositorySubmitTestCase(EventRepositoryTestCase, ABC): - __test__ = False - - async def test_generate_uuid(self): - await self.event_repository.create(EventEntry(NULL_UUID, "example.Car", 1, bytes("foo", "utf-8"))) - observed = [v async for v in self.event_repository.select()] - self.assertEqual(1, len(observed)) - self.assertIsInstance(observed[0].uuid, UUID) - self.assertNotEqual(NULL_UUID, observed[0].uuid) - - async def test_submit(self): - await self.event_repository.submit(EventEntry(self.uuid, "example.Car", action=Action.CREATE)) - expected = [EventEntry(self.uuid, "example.Car", 1, bytes(), 1, Action.CREATE)] - observed = [v async for v in self.event_repository.select()] - self.assert_equal_repository_entries(expected, observed) - - async def test_submit_with_version(self): - await self.event_repository.submit(EventEntry(self.uuid, "example.Car", version=3, action=Action.CREATE)) - expected = [EventEntry(self.uuid, "example.Car", 3, bytes(), 1, Action.CREATE)] - observed = [v async for v in self.event_repository.select()] - self.assert_equal_repository_entries(expected, observed) - - async def test_submit_with_created_at(self): - created_at = datetime(2021, 10, 25, 8, 30, tzinfo=timezone.utc) - await self.event_repository.submit( - EventEntry(self.uuid, "example.Car", created_at=created_at, action=Action.CREATE) - ) - expected = [EventEntry(self.uuid, "example.Car", 1, bytes(), 1, Action.CREATE, created_at=created_at)] - observed = [v async for v in self.event_repository.select()] - self.assert_equal_repository_entries(expected, observed) - - async def test_submit_raises_duplicate(self): - await self.event_repository.submit(EventEntry(self.uuid, "example.Car", 1, action=Action.CREATE)) - with self.assertRaises(EventRepositoryConflictException): - await self.event_repository.submit(EventEntry(self.uuid, "example.Car", 1, action=Action.CREATE)) - - async def test_submit_raises_no_action(self): - with self.assertRaises(EventRepositoryException): - await self.event_repository.submit(EventEntry(self.uuid, "example.Car", 1, "foo".encode())) - - async def test_select_empty(self): - self.assertEqual([], [v async for v in self.event_repository.select()]) - - async def test_offset(self): - self.assertEqual(0, await self.event_repository.offset) - await self.event_repository.submit(EventEntry(self.uuid, "example.Car", version=3, action=Action.CREATE)) - self.assertEqual(1, await self.event_repository.offset) - - -class EventRepositorySelectTestCase(EventRepositoryTestCase, ABC): - __test__ = False - - def setUp(self) -> None: - super().setUp() - + self.uuid = uuid4() self.uuid_1 = uuid4() self.uuid_2 = uuid4() self.uuid_4 = uuid4() @@ -236,7 +150,15 @@ def setUp(self) -> None: async def asyncSetUp(self): await super().asyncSetUp() - await self.populate() + await self.event_repository.setup() + + async def asyncTearDown(self): + await self.event_repository.destroy() + await super().asyncTearDown() + + def tearDown(self): + self.field_diff_container_patcher.stop() + super().tearDown() async def populate(self) -> None: await self.transaction_repository.submit(TransactionEntry(self.first_transaction)) @@ -259,57 +181,132 @@ async def populate(self) -> None: EventEntry(self.uuid_2, "example.Car", 4, bytes("adios", "utf-8"), transaction_uuid=self.first_transaction) ) + @abstractmethod + def build_event_repository(self) -> EventRepository: + """For testing purposes.""" + + def assert_equal_repository_entries(self, expected: list[EventEntry], observed: list[EventEntry]) -> None: + """For testing purposes.""" + + self.assertEqual(len(expected), len(observed)) + + for e, o in zip(expected, observed): + self.assertEqual(type(e), type(o)) + self.assertEqual(e.uuid, o.uuid) + self.assertEqual(e.name, o.name) + self.assertEqual(e.version, o.version) + self.assertEqual(e.data, o.data) + self.assertEqual(e.id, o.id) + self.assertEqual(e.action, o.action) + self.assertAlmostEqual(e.created_at or current_datetime(), o.created_at, delta=timedelta(seconds=5)) + + async def test_generate_uuid(self): + await self.event_repository.create(EventEntry(NULL_UUID, "example.Car", 1, bytes("foo", "utf-8"))) + observed = [v async for v in self.event_repository.select()] + self.assertEqual(1, len(observed)) + self.assertIsInstance(observed[0].uuid, UUID) + self.assertNotEqual(NULL_UUID, observed[0].uuid) + + async def test_submit(self): + await self.event_repository.submit(EventEntry(self.uuid, "example.Car", action=Action.CREATE)) + expected = [EventEntry(self.uuid, "example.Car", 1, bytes(), 1, Action.CREATE)] + observed = [v async for v in self.event_repository.select()] + self.assert_equal_repository_entries(expected, observed) + + async def test_submit_with_version(self): + await self.event_repository.submit(EventEntry(self.uuid, "example.Car", version=3, action=Action.CREATE)) + expected = [EventEntry(self.uuid, "example.Car", 3, bytes(), 1, Action.CREATE)] + observed = [v async for v in self.event_repository.select()] + self.assert_equal_repository_entries(expected, observed) + + async def test_submit_with_created_at(self): + created_at = datetime(2021, 10, 25, 8, 30, tzinfo=timezone.utc) + await self.event_repository.submit( + EventEntry(self.uuid, "example.Car", created_at=created_at, action=Action.CREATE) + ) + expected = [EventEntry(self.uuid, "example.Car", 1, bytes(), 1, Action.CREATE, created_at=created_at)] + observed = [v async for v in self.event_repository.select()] + self.assert_equal_repository_entries(expected, observed) + + async def test_submit_raises_duplicate(self): + await self.event_repository.submit(EventEntry(self.uuid, "example.Car", 1, action=Action.CREATE)) + with self.assertRaises(EventRepositoryConflictException): + await self.event_repository.submit(EventEntry(self.uuid, "example.Car", 1, action=Action.CREATE)) + + async def test_submit_raises_no_action(self): + with self.assertRaises(EventRepositoryException): + await self.event_repository.submit(EventEntry(self.uuid, "example.Car", 1, "foo".encode())) + + async def test_select_empty(self): + self.assertEqual([], [v async for v in self.event_repository.select()]) + + async def test_offset(self): + self.assertEqual(0, await self.event_repository.offset) + await self.event_repository.submit(EventEntry(self.uuid, "example.Car", version=3, action=Action.CREATE)) + self.assertEqual(1, await self.event_repository.offset) + async def test_select(self): + await self.populate() expected = self.entries observed = [v async for v in self.event_repository.select()] self.assert_equal_repository_entries(expected, observed) async def test_select_id(self): + await self.populate() expected = [self.entries[1]] observed = [v async for v in self.event_repository.select(id=2)] self.assert_equal_repository_entries(expected, observed) async def test_select_id_lt(self): + await self.populate() expected = self.entries[:4] observed = [v async for v in self.event_repository.select(id_lt=5)] self.assert_equal_repository_entries(expected, observed) async def test_select_id_gt(self): + await self.populate() expected = self.entries[4:] observed = [v async for v in self.event_repository.select(id_gt=4)] self.assert_equal_repository_entries(expected, observed) async def test_select_id_le(self): + await self.populate() expected = self.entries[:4] observed = [v async for v in self.event_repository.select(id_le=4)] self.assert_equal_repository_entries(expected, observed) async def test_select_id_ge(self): + await self.populate() expected = self.entries[4:] observed = [v async for v in self.event_repository.select(id_ge=5)] self.assert_equal_repository_entries(expected, observed) async def test_select_uuid(self): + await self.populate() expected = [self.entries[2], self.entries[5], self.entries[7], self.entries[8], self.entries[9]] observed = [v async for v in self.event_repository.select(uuid=self.uuid_2)] self.assert_equal_repository_entries(expected, observed) async def test_select_name(self): + await self.populate() expected = [self.entries[6]] observed = [v async for v in self.event_repository.select(name="example.MotorCycle")] self.assert_equal_repository_entries(expected, observed) async def test_select_version(self): + await self.populate() expected = [self.entries[4], self.entries[9]] observed = [v async for v in self.event_repository.select(version=4)] self.assert_equal_repository_entries(expected, observed) async def test_select_version_lt(self): + await self.populate() expected = [self.entries[0], self.entries[2], self.entries[6]] observed = [v async for v in self.event_repository.select(version_lt=2)] self.assert_equal_repository_entries(expected, observed) async def test_select_version_gt(self): + await self.populate() expected = [ self.entries[1], self.entries[3], @@ -323,11 +320,13 @@ async def test_select_version_gt(self): self.assert_equal_repository_entries(expected, observed) async def test_select_version_le(self): + await self.populate() expected = [self.entries[0], self.entries[2], self.entries[6]] observed = [v async for v in self.event_repository.select(version_le=1)] self.assert_equal_repository_entries(expected, observed) async def test_select_version_ge(self): + await self.populate() expected = [ self.entries[1], self.entries[3], @@ -341,21 +340,25 @@ async def test_select_version_ge(self): self.assert_equal_repository_entries(expected, observed) async def test_select_transaction_uuid_null(self): + await self.populate() expected = self.entries[:7] observed = [v async for v in self.event_repository.select(transaction_uuid=NULL_UUID)] self.assert_equal_repository_entries(expected, observed) async def test_select_transaction_uuid(self): + await self.populate() expected = [self.entries[7], self.entries[9]] observed = [v async for v in self.event_repository.select(transaction_uuid=self.first_transaction)] self.assert_equal_repository_entries(expected, observed) async def test_select_transaction_uuid_ne(self): + await self.populate() expected = [self.entries[7], self.entries[8], self.entries[9]] observed = [v async for v in self.event_repository.select(transaction_uuid_ne=NULL_UUID)] self.assert_equal_repository_entries(expected, observed) async def test_select_transaction_uuid_in(self): + await self.populate() expected = [self.entries[7], self.entries[8], self.entries[9]] observed = [ v @@ -366,6 +369,7 @@ async def test_select_transaction_uuid_in(self): self.assert_equal_repository_entries(expected, observed) async def test_select_combined(self): + await self.populate() expected = [self.entries[2], self.entries[5], self.entries[7], self.entries[8], self.entries[9]] observed = [v async for v in self.event_repository.select(name="example.Car", uuid=self.uuid_2)] self.assert_equal_repository_entries(expected, observed) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py index 57b788783..155dee21c 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py @@ -16,8 +16,7 @@ EventRepository, ) from minos.aggregate.testing import ( - EventRepositorySelectTestCase, - EventRepositorySubmitTestCase, + EventRepositoryTestCase, ) from minos.common import ( DatabaseClient, @@ -30,7 +29,7 @@ ) -class TestDatabaseEventRepositorySubmit(AggregateTestCase, EventRepositorySubmitTestCase): +class TestDatabaseEventRepositorySubmit(AggregateTestCase, EventRepositoryTestCase): __test__ = True def build_event_repository(self) -> EventRepository: @@ -93,9 +92,6 @@ async def test_offset(self): await super().test_offset() -class TestDatabaseEventRepositorySelect(AggregateTestCase, EventRepositorySelectTestCase): - __test__ = True - async def populate(self) -> None: with patch.object( DatabaseClient, diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_memory.py index 56a54b251..c1efcdce1 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_memory.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_memory.py @@ -5,23 +5,14 @@ InMemoryEventRepository, ) from minos.aggregate.testing import ( - EventRepositorySelectTestCase, - EventRepositorySubmitTestCase, + EventRepositoryTestCase, ) from tests.utils import ( AggregateTestCase, ) -class TestInMemoryEventRepositorySubmit(AggregateTestCase, EventRepositorySubmitTestCase): - __test__ = True - - def build_event_repository(self) -> EventRepository: - """For testing purposes.""" - return InMemoryEventRepository() - - -class TestInMemoryEventRepositorySelect(AggregateTestCase, EventRepositorySelectTestCase): +class TestInMemoryEventRepositorySubmit(AggregateTestCase, EventRepositoryTestCase): __test__ = True def build_event_repository(self) -> EventRepository: diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py index 4bd5c5f72..bf57368d0 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py @@ -5,8 +5,7 @@ EventRepository, ) from minos.aggregate.testing import ( - EventRepositorySelectTestCase, - EventRepositorySubmitTestCase, + EventRepositoryTestCase, ) from minos.common import ( DatabaseClientPool, @@ -21,7 +20,7 @@ # noinspection SqlNoDataSourceInspection -class TestDatabaseEventRepositorySubmit(AiopgTestCase, EventRepositorySubmitTestCase): +class TestDatabaseEventRepositorySubmit(AiopgTestCase, EventRepositoryTestCase): __test__ = True def build_event_repository(self) -> EventRepository: @@ -48,13 +47,5 @@ async def test_setup(self): self.assertTrue(response) -class TestDatabaseEventRepositorySelect(AiopgTestCase, EventRepositorySelectTestCase): - __test__ = True - - def build_event_repository(self) -> EventRepository: - """Fort testing purposes.""" - return DatabaseEventRepository.from_config(self.config) - - if __name__ == "__main__": unittest.main() From ab4f044388fb1621d8c01a60899ed4642547a641 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 11:15:34 +0200 Subject: [PATCH 234/324] ISSUE #98 * Refactor `TransactionRepositoryTestCase`. * Fix bug. --- .../snapshots/repositories/database/impl.py | 9 +- .../minos/aggregate/testing/__init__.py | 2 - .../aggregate/testing/snapshot_repository.py | 2 +- .../testing/transaction_repository.py | 87 ++++++++++--------- .../test_repositories/test_database.py | 5 -- .../test_repositories/test_database.py | 12 +-- .../test_repositories/test_memory.py | 12 +-- .../test_transactions/test_pg.py | 12 +-- 8 files changed, 58 insertions(+), 83 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py index fef497e55..c344221f3 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py @@ -16,6 +16,7 @@ from minos.common import ( NULL_UUID, Config, + DatabaseMixin, Inject, NotProvidedException, import_module, @@ -47,6 +48,9 @@ from ..abc import ( SnapshotRepository, ) +from .factories import ( + SnapshotDatabaseOperationFactory, +) if TYPE_CHECKING: from ....entities import ( @@ -54,7 +58,7 @@ ) -class DatabaseSnapshotRepository(SnapshotRepository): +class DatabaseSnapshotRepository(SnapshotRepository, DatabaseMixin[SnapshotDatabaseOperationFactory]): """Database Snapshot Repository class. The snapshot provides a direct accessor to the ``RootEntity`` instances stored as events by the event repository @@ -120,6 +124,7 @@ async def _find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: # noinspection PyUnusedLocal + # noinspection PyUnusedLocal async def find_entries( self, name: str, @@ -250,7 +255,7 @@ async def _update_instance_if_exists(self, event: Event, **kwargs) -> RootEntity return previous async def _select_one_instance(self, name: str, uuid: UUID, **kwargs) -> RootEntity: - snapshot_entry = await self._reader.get_entry(name, uuid, **kwargs) + snapshot_entry = await self.get_entry(name, uuid, **kwargs) return snapshot_entry.build(**kwargs) async def _submit_entry(self, snapshot_entry: SnapshotEntry) -> SnapshotEntry: diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py index 6ba595c38..86b8671c5 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py @@ -6,7 +6,5 @@ SnapshotRepositoryWriterTestCase, ) from .transaction_repository import ( - TransactionRepositorySelectTestCase, - TransactionRepositorySubmitTestCase, TransactionRepositoryTestCase, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py index 1e9b77ab7..e74935f74 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py @@ -666,4 +666,4 @@ async def test_find_all(self): updated_at=observed[1].updated_at, ), ] - self.assertEqual(expected, observed) \ No newline at end of file + self.assertEqual(expected, observed) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py index 8cec2c535..8276bbf85 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py @@ -17,13 +17,38 @@ ) -class TransactionRepositoryTestCase(MinosTestCase): +class TransactionRepositoryTestCase(MinosTestCase, ABC): + __test__ = False + def setUp(self) -> None: super().setUp() - self.uuid = uuid4() self.transaction_repository = self.build_transaction_repository() + self.uuid = uuid4() + self.uuid_1 = uuid4() + self.uuid_2 = uuid4() + self.uuid_3 = uuid4() + self.uuid_4 = uuid4() + self.uuid_5 = uuid4() + + self.entries = [ + TransactionEntry(self.uuid_1, TransactionStatus.PENDING, 12), + TransactionEntry(self.uuid_2, TransactionStatus.PENDING, 15), + TransactionEntry(self.uuid_3, TransactionStatus.REJECTED, 16), + TransactionEntry(self.uuid_4, TransactionStatus.COMMITTED, 20), + TransactionEntry(self.uuid_5, TransactionStatus.PENDING, 20, self.uuid_1), + ] + + async def populate(self) -> None: + await self.transaction_repository.submit(TransactionEntry(self.uuid_1, TransactionStatus.PENDING, 12)) + await self.transaction_repository.submit(TransactionEntry(self.uuid_2, TransactionStatus.PENDING, 15)) + await self.transaction_repository.submit(TransactionEntry(self.uuid_3, TransactionStatus.REJECTED, 16)) + await self.transaction_repository.submit(TransactionEntry(self.uuid_4, TransactionStatus.COMMITTED, 20)) + await self.transaction_repository.submit( + TransactionEntry(self.uuid_5, TransactionStatus.PENDING, 20, self.uuid_1) + ) + async def asyncSetUp(self): await super().asyncSetUp() await self.transaction_repository.setup() @@ -39,14 +64,6 @@ def tearDown(self): def build_transaction_repository(self) -> TransactionRepository: """For testing purposes.""" - -class TransactionRepositorySubmitTestCase(TransactionRepositoryTestCase, ABC): - __test__ = False - - def setUp(self) -> None: - super().setUp() - self.uuid = uuid4() - async def test_subclass(self) -> None: self.assertTrue(isinstance(self.transaction_repository, TransactionRepository)) @@ -133,70 +150,44 @@ async def test_select_empty(self): observed = [v async for v in self.transaction_repository.select()] self.assertEqual(expected, observed) - -class TransactionRepositorySelectTestCase(TransactionRepositoryTestCase, ABC): - __test__ = False - - def setUp(self) -> None: - super().setUp() - self.uuid_1 = uuid4() - self.uuid_2 = uuid4() - self.uuid_3 = uuid4() - self.uuid_4 = uuid4() - self.uuid_5 = uuid4() - - self.entries = [ - TransactionEntry(self.uuid_1, TransactionStatus.PENDING, 12), - TransactionEntry(self.uuid_2, TransactionStatus.PENDING, 15), - TransactionEntry(self.uuid_3, TransactionStatus.REJECTED, 16), - TransactionEntry(self.uuid_4, TransactionStatus.COMMITTED, 20), - TransactionEntry(self.uuid_5, TransactionStatus.PENDING, 20, self.uuid_1), - ] - - async def asyncSetUp(self): - await super().asyncSetUp() - await self.populate() - - async def populate(self) -> None: - await self.transaction_repository.submit(TransactionEntry(self.uuid_1, TransactionStatus.PENDING, 12)) - await self.transaction_repository.submit(TransactionEntry(self.uuid_2, TransactionStatus.PENDING, 15)) - await self.transaction_repository.submit(TransactionEntry(self.uuid_3, TransactionStatus.REJECTED, 16)) - await self.transaction_repository.submit(TransactionEntry(self.uuid_4, TransactionStatus.COMMITTED, 20)) - await self.transaction_repository.submit( - TransactionEntry(self.uuid_5, TransactionStatus.PENDING, 20, self.uuid_1) - ) - async def test_select(self): + await self.populate() expected = self.entries observed = [v async for v in self.transaction_repository.select()] self.assertEqual(expected, observed) async def test_select_uuid(self): + await self.populate() expected = [self.entries[1]] observed = [v async for v in self.transaction_repository.select(uuid=self.uuid_2)] self.assertEqual(expected, observed) async def test_select_uuid_ne(self): + await self.populate() expected = [self.entries[0], self.entries[2], self.entries[3], self.entries[4]] observed = [v async for v in self.transaction_repository.select(uuid_ne=self.uuid_2)] self.assertEqual(expected, observed) async def test_select_uuid_in(self): + await self.populate() expected = [self.entries[1], self.entries[2]] observed = [v async for v in self.transaction_repository.select(uuid_in=(self.uuid_2, self.uuid_3))] self.assertEqual(expected, observed) async def test_select_destination_uuid(self): + await self.populate() expected = [self.entries[4]] observed = [v async for v in self.transaction_repository.select(destination_uuid=self.uuid_1)] self.assertEqual(expected, observed) async def test_select_status(self): + await self.populate() expected = [self.entries[0], self.entries[1], self.entries[4]] observed = [v async for v in self.transaction_repository.select(status=TransactionStatus.PENDING)] self.assertEqual(expected, observed) async def test_select_status_in(self): + await self.populate() expected = [self.entries[2], self.entries[3]] observed = [ v @@ -207,31 +198,37 @@ async def test_select_status_in(self): self.assertEqual(expected, observed) async def test_select_event_offset(self): + await self.populate() expected = [self.entries[1]] observed = [v async for v in self.transaction_repository.select(event_offset=15)] self.assertEqual(expected, observed) async def test_select_event_offset_lt(self): + await self.populate() expected = [self.entries[0]] observed = [v async for v in self.transaction_repository.select(event_offset_lt=15)] self.assertEqual(expected, observed) async def test_select_event_offset_gt(self): + await self.populate() expected = [self.entries[2], self.entries[3], self.entries[4]] observed = [v async for v in self.transaction_repository.select(event_offset_gt=15)] self.assertEqual(expected, observed) async def test_select_event_offset_le(self): + await self.populate() expected = [self.entries[0], self.entries[1]] observed = [v async for v in self.transaction_repository.select(event_offset_le=15)] self.assertEqual(expected, observed) async def test_select_event_offset_ge(self): + await self.populate() expected = [self.entries[1], self.entries[2], self.entries[3], self.entries[4]] observed = [v async for v in self.transaction_repository.select(event_offset_ge=15)] self.assertEqual(expected, observed) async def test_select_updated_at(self): + await self.populate() updated_at = (await self.transaction_repository.get(self.uuid_3)).updated_at expected = [self.entries[2]] @@ -239,6 +236,7 @@ async def test_select_updated_at(self): self.assertEqual(expected, observed) async def test_select_updated_at_lt(self): + await self.populate() updated_at = (await self.transaction_repository.get(self.uuid_3)).updated_at expected = [self.entries[0], self.entries[1]] @@ -246,6 +244,7 @@ async def test_select_updated_at_lt(self): self.assertEqual(expected, observed) async def test_select_updated_at_gt(self): + await self.populate() updated_at = (await self.transaction_repository.get(self.uuid_3)).updated_at expected = [self.entries[3], self.entries[4]] @@ -253,6 +252,7 @@ async def test_select_updated_at_gt(self): self.assertEqual(expected, observed) async def test_select_updated_at_le(self): + await self.populate() updated_at = (await self.transaction_repository.get(self.uuid_3)).updated_at expected = [self.entries[0], self.entries[1], self.entries[2]] @@ -260,6 +260,7 @@ async def test_select_updated_at_le(self): self.assertEqual(expected, observed) async def test_select_updated_at_ge(self): + await self.populate() updated_at = (await self.transaction_repository.get(self.uuid_3)).updated_at expected = [self.entries[2], self.entries[3], self.entries[4]] diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py index 155dee21c..fef33992f 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_events/test_repositories/test_database.py @@ -91,7 +91,6 @@ async def test_offset(self): with patch.object(DatabaseClient, "fetch_one", side_effect=fetch_one): await super().test_offset() - async def populate(self) -> None: with patch.object( DatabaseClient, @@ -111,10 +110,6 @@ async def populate(self) -> None: ): await super().populate() - def build_event_repository(self) -> EventRepository: - """For testing purposes.""" - return DatabaseEventRepository.from_config(self.config) - async def test_select(self): with patch.object( DatabaseClient, diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py index fa9fb59d4..addcdfc4c 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py @@ -10,8 +10,7 @@ TransactionStatus, ) from minos.aggregate.testing import ( - TransactionRepositorySelectTestCase, - TransactionRepositorySubmitTestCase, + TransactionRepositoryTestCase, ) from minos.common import ( DatabaseClient, @@ -24,7 +23,7 @@ # noinspection SqlNoDataSourceInspection -class TestDatabaseTransactionRepository(AggregateTestCase, TransactionRepositorySubmitTestCase): +class TestDatabaseTransactionRepository(AggregateTestCase, TransactionRepositoryTestCase): __test__ = True def build_transaction_repository(self) -> TransactionRepository: @@ -129,13 +128,6 @@ async def test_submit_rejected_raises(self): ): await super().test_submit_rejected_raises() - -class TestDatabaseTransactionRepositorySelect(AggregateTestCase, TransactionRepositorySelectTestCase): - __test__ = True - - def build_transaction_repository(self) -> TransactionRepository: - return DatabaseTransactionRepository.from_config(self.config) - async def populate(self) -> None: with patch.object( DatabaseClient, diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py index 0f02d4a67..95ba70979 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_memory.py @@ -5,22 +5,14 @@ TransactionRepository, ) from minos.aggregate.testing import ( - TransactionRepositorySelectTestCase, - TransactionRepositorySubmitTestCase, + TransactionRepositoryTestCase, ) from tests.utils import ( AggregateTestCase, ) -class TestInMemoryTransactionRepository(AggregateTestCase, TransactionRepositorySubmitTestCase): - __test__ = True - - def build_transaction_repository(self) -> TransactionRepository: - return InMemoryTransactionRepository() - - -class TestInMemoryTransactionRepositorySelect(AggregateTestCase, TransactionRepositorySelectTestCase): +class TestInMemoryTransactionRepository(AggregateTestCase, TransactionRepositoryTestCase): __test__ = True def build_transaction_repository(self) -> TransactionRepository: diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py index 51ae8c01b..c86eab02a 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py @@ -5,8 +5,7 @@ TransactionRepository, ) from minos.aggregate.testing import ( - TransactionRepositorySelectTestCase, - TransactionRepositorySubmitTestCase, + TransactionRepositoryTestCase, ) from minos.common import ( DatabaseClientPool, @@ -21,7 +20,7 @@ # noinspection SqlNoDataSourceInspection -class TestDatabaseTransactionRepository(AiopgTestCase, TransactionRepositorySubmitTestCase): +class TestDatabaseTransactionRepository(AiopgTestCase, TransactionRepositoryTestCase): __test__ = True def build_transaction_repository(self) -> TransactionRepository: @@ -47,12 +46,5 @@ async def test_setup(self): self.assertTrue(response) -class TestDatabaseTransactionRepositorySelect(AiopgTestCase, TransactionRepositorySelectTestCase): - __test__ = True - - def build_transaction_repository(self) -> TransactionRepository: - return DatabaseTransactionRepository.from_config(self.config) - - if __name__ == "__main__": unittest.main() From 18ca477182e10bf19dd2818ba408136075d737d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 11:45:50 +0200 Subject: [PATCH 235/324] ISSUE #98 * Refactor `SnapshotRepositoryTestCase`. --- .../minos/aggregate/testing/__init__.py | 3 +- .../aggregate/testing/snapshot_repository.py | 151 ++++++------------ .../test_repositories/test_memory.py | 4 +- .../test_aggregate/test_snapshots/test_pg.py | 13 +- 4 files changed, 55 insertions(+), 116 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py index 86b8671c5..1ccc48fce 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py @@ -2,8 +2,7 @@ EventRepositoryTestCase, ) from .snapshot_repository import ( - SnapshotRepositoryReaderTestCase, - SnapshotRepositoryWriterTestCase, + SnapshotRepositoryTestCase, ) from .transaction_repository import ( TransactionRepositoryTestCase, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py index e74935f74..d7f40eed1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py @@ -57,42 +57,14 @@ class Car(RootEntity): class SnapshotRepositoryTestCase(MinosTestCase, ABC): + __test__ = False + snapshot_repository: SnapshotRepository def setUp(self) -> None: super().setUp() self.snapshot_repository = self.build_snapshot_repository() - @abstractmethod - def build_snapshot_repository(self) -> SnapshotRepository: - pass - - async def asyncSetUp(self): - await super().asyncSetUp() - await self.snapshot_repository.setup() - - async def asyncTearDown(self): - await self.snapshot_repository.destroy() - await super().asyncTearDown() - - def assert_equal_snapshot_entries(self, expected: list[SnapshotEntry], observed: list[SnapshotEntry]): - self.assertEqual(len(expected), len(observed)) - for exp, obs in zip(expected, observed): - if exp.data is None: - with self.assertRaises(AlreadyDeletedException): - # noinspection PyStatementEffect - obs.build() - else: - self.assertEqual(exp.build(), obs.build()) - self.assertIsInstance(obs.created_at, datetime) - self.assertIsInstance(obs.updated_at, datetime) - - -class SnapshotRepositoryWriterTestCase(SnapshotRepositoryTestCase, ABC): - __test__ = False - - def setUp(self) -> None: - super().setUp() self.uuid_1 = uuid4() self.uuid_2 = uuid4() self.uuid_3 = uuid4() @@ -102,9 +74,9 @@ def setUp(self) -> None: self.transaction_3 = uuid4() self.transaction_4 = uuid4() - async def asyncSetUp(self): - await super().asyncSetUp() - await self.populate() + @abstractmethod + def build_snapshot_repository(self) -> SnapshotRepository: + pass async def populate(self) -> None: diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) @@ -145,11 +117,35 @@ async def populate(self) -> None: ) ) + async def populate_and_synchronize(self): + await self.populate() + await self.snapshot_repository.synchronize() + + async def asyncSetUp(self): + await super().asyncSetUp() + await self.snapshot_repository.setup() + + async def asyncTearDown(self): + await self.snapshot_repository.destroy() + await super().asyncTearDown() + + def assert_equal_snapshot_entries(self, expected: list[SnapshotEntry], observed: list[SnapshotEntry]): + self.assertEqual(len(expected), len(observed)) + for exp, obs in zip(expected, observed): + if exp.data is None: + with self.assertRaises(AlreadyDeletedException): + # noinspection PyStatementEffect + obs.build() + else: + self.assertEqual(exp.build(), obs.build()) + self.assertIsInstance(obs.created_at, datetime) + self.assertIsInstance(obs.updated_at, datetime) + def test_type(self): self.assertTrue(isinstance(self.snapshot_repository, SnapshotRepository)) async def test_dispatch(self): - await self.snapshot_repository.synchronize() + await self.populate_and_synchronize() # noinspection PyTypeChecker iterable = self.snapshot_repository.find_entries( @@ -184,7 +180,7 @@ async def test_dispatch(self): self.assert_equal_snapshot_entries(expected, observed) async def test_dispatch_first_transaction(self): - await self.snapshot_repository.synchronize() + await self.populate_and_synchronize() # noinspection PyTypeChecker iterable = self.snapshot_repository.find_entries( @@ -223,7 +219,7 @@ async def test_dispatch_first_transaction(self): self.assert_equal_snapshot_entries(expected, observed) async def test_dispatch_second_transaction(self): - await self.snapshot_repository.synchronize() + await self.populate_and_synchronize() # noinspection PyTypeChecker iterable = self.snapshot_repository.find_entries( @@ -253,7 +249,7 @@ async def test_dispatch_second_transaction(self): self.assert_equal_snapshot_entries(expected, observed) async def test_dispatch_third_transaction(self): - await self.snapshot_repository.synchronize() + await self.populate_and_synchronize() # noinspection PyTypeChecker iterable = self.snapshot_repository.find_entries( @@ -292,6 +288,7 @@ async def test_dispatch_third_transaction(self): self.assert_equal_snapshot_entries(expected, observed) async def test_dispatch_ignore_previous_version(self): + await self.populate() diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) # noinspection PyTypeChecker name: str = Car.classname @@ -322,6 +319,8 @@ async def _fn(*args, **kwargs): self.assert_equal_snapshot_entries(expected, observed) async def test_dispatch_with_offset(self): + await self.populate() + mock = MagicMock(side_effect=self.event_repository.select) self.event_repository.select = mock @@ -353,67 +352,8 @@ async def test_dispatch_with_offset(self): self.assertEqual(call(id_gt=12), mock.call_args) mock.reset_mock() - -class SnapshotRepositoryReaderTestCase(SnapshotRepositoryTestCase, ABC): - __test__ = False - - def setUp(self) -> None: - super().setUp() - - self.uuid_1 = uuid4() - self.uuid_2 = uuid4() - self.uuid_3 = uuid4() - - self.transaction_1 = uuid4() - self.transaction_2 = uuid4() - self.transaction_3 = uuid4() - self.transaction_4 = uuid4() - - async def asyncSetUp(self): - await super().asyncSetUp() - await self.populate() - - async def populate(self) -> None: - diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) - # noinspection PyTypeChecker - name: str = Car.classname - - await self.event_repository.create(EventEntry(self.uuid_1, name, 1, diff.avro_bytes)) - await self.event_repository.update(EventEntry(self.uuid_1, name, 2, diff.avro_bytes)) - await self.event_repository.create(EventEntry(self.uuid_2, name, 1, diff.avro_bytes)) - await self.event_repository.update(EventEntry(self.uuid_1, name, 3, diff.avro_bytes)) - await self.event_repository.delete(EventEntry(self.uuid_1, name, 4)) - await self.event_repository.update(EventEntry(self.uuid_2, name, 2, diff.avro_bytes)) - await self.event_repository.update( - EventEntry(self.uuid_2, name, 3, diff.avro_bytes, transaction_uuid=self.transaction_1) - ) - await self.event_repository.delete( - EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_2) - ) - await self.event_repository.update( - EventEntry(self.uuid_2, name, 4, diff.avro_bytes, transaction_uuid=self.transaction_1) - ) - await self.event_repository.create(EventEntry(self.uuid_3, name, 1, diff.avro_bytes)) - await self.event_repository.delete( - EventEntry(self.uuid_2, name, 3, bytes(), transaction_uuid=self.transaction_3) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_1, TransactionStatus.PENDING, await self.event_repository.offset) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_2, TransactionStatus.PENDING, await self.event_repository.offset) - ) - await self.transaction_repository.submit( - TransactionEntry(self.transaction_3, TransactionStatus.REJECTED, await self.event_repository.offset) - ) - await self.transaction_repository.submit( - TransactionEntry( - self.transaction_4, TransactionStatus.REJECTED, await self.event_repository.offset, self.transaction_3 - ) - ) - await self.snapshot_repository.synchronize() - async def test_find_by_uuid(self): + await self.populate_and_synchronize() condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) iterable = self.snapshot_repository.find(Car, condition, ordering=Ordering.ASC("updated_at")) @@ -440,6 +380,7 @@ async def test_find_by_uuid(self): self.assertEqual(expected, observed) async def test_find_with_transaction(self): + await self.populate_and_synchronize() condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) iterable = self.snapshot_repository.find( @@ -471,6 +412,7 @@ async def test_find_with_transaction(self): self.assertEqual(expected, observed) async def test_find_with_transaction_delete(self): + await self.populate_and_synchronize() condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) iterable = self.snapshot_repository.find( @@ -494,6 +436,7 @@ async def test_find_with_transaction_delete(self): self.assertEqual(expected, observed) async def test_find_with_transaction_reverted(self): + await self.populate_and_synchronize() condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) iterable = self.snapshot_repository.find( @@ -525,6 +468,7 @@ async def test_find_with_transaction_reverted(self): self.assertEqual(expected, observed) async def test_find_streaming_true(self): + await self.populate_and_synchronize() condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) iterable = self.snapshot_repository.find( @@ -553,6 +497,7 @@ async def test_find_streaming_true(self): self.assertEqual(expected, observed) async def test_find_with_duplicates(self): + await self.populate_and_synchronize() uuids = [self.uuid_2, self.uuid_2, self.uuid_3] condition = Condition.IN("uuid", uuids) @@ -580,14 +525,14 @@ async def test_find_with_duplicates(self): self.assertEqual(expected, observed) async def test_find_empty(self): - + await self.populate_and_synchronize() observed = {v async for v in self.snapshot_repository.find(Car, Condition.FALSE)} expected = set() self.assertEqual(expected, observed) async def test_get(self): - + await self.populate_and_synchronize() observed = await self.snapshot_repository.get(Car, self.uuid_2) expected = Car( @@ -596,6 +541,7 @@ async def test_get(self): self.assertEqual(expected, observed) async def test_get_with_transaction(self): + await self.populate_and_synchronize() observed = await self.snapshot_repository.get( Car, self.uuid_2, transaction=TransactionEntry(self.transaction_1) @@ -607,18 +553,19 @@ async def test_get_with_transaction(self): self.assertEqual(expected, observed) async def test_get_raises(self): - + await self.populate_and_synchronize() with self.assertRaises(AlreadyDeletedException): await self.snapshot_repository.get(Car, self.uuid_1) with self.assertRaises(NotFoundException): await self.snapshot_repository.get(Car, uuid4()) async def test_get_with_transaction_raises(self): - + await self.populate_and_synchronize() with self.assertRaises(AlreadyDeletedException): await self.snapshot_repository.get(Car, self.uuid_2, transaction=TransactionEntry(self.transaction_2)) async def test_find(self): + await self.populate_and_synchronize() condition = Condition.EQUAL("color", "blue") iterable = self.snapshot_repository.find(Car, condition, ordering=Ordering.ASC("updated_at")) observed = [v async for v in iterable] @@ -644,7 +591,7 @@ async def test_find(self): self.assertEqual(expected, observed) async def test_find_all(self): - + await self.populate_and_synchronize() iterable = self.snapshot_repository.find(Car, Condition.TRUE, Ordering.ASC("updated_at")) observed = [v async for v in iterable] diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py index 57727a28d..18bdf851f 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py @@ -5,7 +5,7 @@ SnapshotRepository, ) from minos.aggregate.testing import ( - SnapshotRepositoryReaderTestCase, + SnapshotRepositoryTestCase, ) from minos.common import ( NotProvidedException, @@ -15,7 +15,7 @@ ) -class TestInMemorySnapshotRepositoryReader(AggregateTestCase, SnapshotRepositoryReaderTestCase): +class TestInMemorySnapshotRepositoryReader(AggregateTestCase, SnapshotRepositoryTestCase): __test__ = True def build_snapshot_repository(self) -> SnapshotRepository: diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py index 48a2d627c..69ac0c9a6 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py @@ -4,8 +4,7 @@ DatabaseSnapshotRepository, ) from minos.aggregate.testing import ( - SnapshotRepositoryReaderTestCase, - SnapshotRepositoryWriterTestCase, + SnapshotRepositoryTestCase, ) from minos.aggregate.testing.snapshot_repository import ( Car, @@ -20,7 +19,7 @@ # noinspection SqlNoDataSourceInspection -class TestDatabaseSnapshotRepositoryWriter(AiopgTestCase, SnapshotRepositoryWriterTestCase): +class TestDatabaseSnapshotRepositoryWriter(AiopgTestCase, SnapshotRepositoryTestCase): __test__ = True def build_snapshot_repository(self): @@ -46,17 +45,11 @@ async def test_setup_snapshot_aux_offset_table(self): self.assertEqual(True, observed) async def test_is_synced(self): + await self.populate() self.assertFalse(await self.snapshot_repository.is_synced(Car)) await self.snapshot_repository.synchronize() self.assertTrue(await self.snapshot_repository.is_synced(Car)) -class TestDatabaseSnapshotRepositoryReader(AiopgTestCase, SnapshotRepositoryReaderTestCase): - __test__ = True - - def build_snapshot_repository(self): - return DatabaseSnapshotRepository.from_config(self.config) - - if __name__ == "__main__": unittest.main() From 5300dfcf581cfe8172da5d2fdffbb00cda9381db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 14:05:36 +0200 Subject: [PATCH 236/324] ISSUE #98 * Refactoring `SnapshotRepository`. --- .../aggregate/snapshots/repositories/abc.py | 100 +++++++++++++++--- .../snapshots/repositories/database/impl.py | 60 ++--------- .../snapshots/repositories/memory.py | 82 +++++++++----- .../aggregate/testing/snapshot_repository.py | 8 +- .../test_repositories/test_abc.py | 60 ++++++----- .../test_repositories/test_memory.py | 5 +- 6 files changed, 188 insertions(+), 127 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py index af0e74f3b..d753e1069 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py @@ -23,15 +23,22 @@ classname, ) +from ...exceptions import ( + NotFoundException, +) from ...queries import ( _TRUE_CONDITION, _Condition, + _EqualCondition, _Ordering, ) from ...transactions import ( TRANSACTION_CONTEXT_VAR, TransactionEntry, ) +from ..entries import ( + SnapshotEntry, +) if TYPE_CHECKING: from ...entities import ( @@ -64,19 +71,25 @@ async def get( :param kwargs: Additional named arguments. :return: The ``RootEntity`` instance. """ - if isinstance(name, type): - name = classname(name) - - if transaction is None: - transaction = TRANSACTION_CONTEXT_VAR.get() + snapshot_entry = await self.get_entry(name, uuid, transaction=transaction, **kwargs) + instance = snapshot_entry.build(**kwargs) + return instance - await self.synchronize(**kwargs) + async def get_entry(self, name: str, uuid: UUID, **kwargs) -> SnapshotEntry: + """Get a ``SnapshotEntry`` from its identifier. - return await self._get(name=name, uuid=uuid, transaction=transaction, **kwargs) + :param name: Class name of the ``RootEntity``. + :param uuid: Identifier of the ``RootEntity``. + :param kwargs: Additional named arguments. + :return: The ``SnapshotEntry`` instance. + """ - @abstractmethod - async def _get(self, *args, **kwargs) -> RootEntity: - raise NotImplementedError + try: + return await self.find_entries( + name, _EqualCondition("uuid", uuid), **kwargs | {"exclude_deleted": False} + ).__anext__() + except StopAsyncIteration: + raise NotFoundException(f"The instance could not be found: {uuid!s}") def get_all( self, @@ -138,29 +151,82 @@ async def find( :param kwargs: Additional named arguments. :return: An asynchronous iterator that containing the ``RootEntity`` instances. """ + iterable = self.find_entries( + name=name, + condition=condition, + ordering=ordering, + limit=limit, + streaming_mode=streaming_mode, + transaction=transaction, + **kwargs, + ) + async for snapshot_entry in iterable: + yield snapshot_entry.build(**kwargs) + + async def find_entries( + self, + name: str, + condition: _Condition, + ordering: Optional[_Ordering] = None, + limit: Optional[int] = None, + streaming_mode: bool = False, + transaction: Optional[TransactionEntry] = None, + exclude_deleted: bool = True, + synchronize: bool = True, + **kwargs, + ) -> AsyncIterator[SnapshotEntry]: + """Find a collection of ``SnapshotEntry`` instances based on a ``Condition``. + + :param name: Class name of the ``RootEntity``. + :param condition: The condition that must be satisfied by the ``RootEntity`` instances. + :param ordering: Optional argument to return the instance with specific ordering strategy. The default behaviour + is to retrieve them without any order pattern. + :param limit: Optional argument to return only a subset of instances. The default behaviour is to return all the + instances that meet the given condition. + :param streaming_mode: If ``True`` return the values in streaming directly from the database (keep an open + database connection), otherwise preloads the full set of values on memory and then retrieves them. + :param transaction: The transaction within the operation is performed. If not any value is provided, then the + transaction is extracted from the context var. If not any transaction is being scoped then the query is + performed to the global snapshot. + :param exclude_deleted: If ``True``, deleted ``RootEntity`` entries are included, otherwise deleted + ``RootEntity`` entries are filtered. + :param kwargs: Additional named arguments. + :return: An asynchronous iterator that containing the ``RootEntity`` instances. + """ if isinstance(name, type): name = classname(name) if transaction is None: transaction = TRANSACTION_CONTEXT_VAR.get() - await self.synchronize(**kwargs) + if synchronize: + await self.synchronize(**kwargs) - iterable = self._find( + iterable = self._find_entries( name=name, condition=condition, ordering=ordering, limit=limit, streaming_mode=streaming_mode, transaction=transaction, + exclude_deleted=exclude_deleted, **kwargs, ) - - async for instance in iterable: - yield instance + async for entry in iterable: + yield entry @abstractmethod - def _find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: + def _find_entries( + self, + name: str, + condition: _Condition, + ordering: Optional[_Ordering], + limit: Optional[int], + streaming_mode: bool, + transaction: Optional[TransactionEntry], + exclude_deleted: bool, + **kwargs, + ) -> AsyncIterator[SnapshotEntry]: raise NotImplementedError def synchronize(self, **kwargs) -> Awaitable[None]: @@ -169,7 +235,7 @@ def synchronize(self, **kwargs) -> Awaitable[None]: :param kwargs: Additional named arguments. :return: This method does not return anything. """ - return self._synchronize(**kwargs) + return self._synchronize(**kwargs, synchronize=False) @abstractmethod async def _synchronize(self, **kwargs) -> None: diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py index c344221f3..084fc8cac 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py @@ -34,7 +34,6 @@ ) from ....queries import ( _Condition, - _EqualCondition, _Ordering, ) from ....transactions import ( @@ -95,65 +94,18 @@ async def _setup(self) -> None: async def _destroy(self) -> None: await super()._destroy() - async def _get(self, name: str, uuid: UUID, **kwargs) -> RootEntity: - snapshot_entry = await self.get_entry(name, uuid, **kwargs) - instance = snapshot_entry.build(**kwargs) - return instance - - # noinspection PyUnusedLocal - - async def get_entry(self, name: str, uuid: UUID, **kwargs) -> SnapshotEntry: - """Get a ``SnapshotEntry`` from its identifier. - - :param name: Class name of the ``RootEntity``. - :param uuid: Identifier of the ``RootEntity``. - :param kwargs: Additional named arguments. - :return: The ``SnapshotEntry`` instance. - """ - - try: - return await self.find_entries( - name, _EqualCondition("uuid", uuid), **kwargs | {"exclude_deleted": False} - ).__anext__() - except StopAsyncIteration: - raise NotFoundException(f"The instance could not be found: {uuid!s}") - - async def _find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: - async for snapshot_entry in self.find_entries(*args, **kwargs): - yield snapshot_entry.build(**kwargs) - - # noinspection PyUnusedLocal - # noinspection PyUnusedLocal - async def find_entries( + async def _find_entries( self, name: str, condition: _Condition, - ordering: Optional[_Ordering] = None, - limit: Optional[int] = None, - streaming_mode: bool = False, - transaction: Optional[TransactionEntry] = None, - exclude_deleted: bool = True, + ordering: Optional[_Ordering], + limit: Optional[int], + streaming_mode: bool, + transaction: Optional[TransactionEntry], + exclude_deleted: bool, **kwargs, ) -> AsyncIterator[SnapshotEntry]: - """Find a collection of ``SnapshotEntry`` instances based on a ``Condition``. - - :param name: Class name of the ``RootEntity``. - :param condition: The condition that must be satisfied by the ``RootEntity`` instances. - :param ordering: Optional argument to return the instance with specific ordering strategy. The default behaviour - is to retrieve them without any order pattern. - :param limit: Optional argument to return only a subset of instances. The default behaviour is to return all the - instances that meet the given condition. - :param streaming_mode: If ``True`` return the values in streaming directly from the database (keep an open - database connection), otherwise preloads the full set of values on memory and then retrieves them. - :param transaction: The transaction within the operation is performed. If not any value is provided, then the - transaction is extracted from the context var. If not any transaction is being scoped then the query is - performed to the global snapshot. - :param exclude_deleted: If ``True``, deleted ``RootEntity`` entries are included, otherwise deleted - ``RootEntity`` entries are filtered. - :param kwargs: Additional named arguments. - :return: An asynchronous iterator that containing the ``RootEntity`` instances. - """ if transaction is None: transaction_uuids = (NULL_UUID,) else: diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py index 05d654023..c2048363a 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py @@ -2,11 +2,16 @@ annotations, ) +from contextlib import ( + suppress, +) +from functools import ( + cmp_to_key, +) from operator import ( attrgetter, ) from typing import ( - TYPE_CHECKING, AsyncIterator, Optional, ) @@ -37,15 +42,13 @@ TransactionRepository, TransactionStatus, ) +from ..entries import ( + SnapshotEntry, +) from .abc import ( SnapshotRepository, ) -if TYPE_CHECKING: - from ...entities import ( - RootEntity, - ) - class InMemorySnapshotRepository(SnapshotRepository): """InMemory Snapshot class. @@ -73,46 +76,70 @@ def __init__( self._event_repository = event_repository self._transaction_repository = transaction_repository - async def _find( + async def _find_entries( self, name: str, condition: _Condition, - ordering: Optional[_Ordering] = None, - limit: Optional[int] = None, + ordering: Optional[_Ordering], + limit: Optional[int], + exclude_deleted: bool, **kwargs, - ) -> AsyncIterator[RootEntity]: + ) -> AsyncIterator[SnapshotEntry]: uuids = {v.uuid async for v in self._event_repository.select(name=name)} - instances = list() + entries = list() for uuid in uuids: + entry = await self._get(name, uuid, **kwargs) + try: - instance = await self.get(name, uuid, **kwargs) + instance = entry.build() + if condition.evaluate(instance): + entries.append(entry) except AlreadyDeletedException: - continue - - if condition.evaluate(instance): - instances.append(instance) + # noinspection PyTypeChecker + if not exclude_deleted and condition.evaluate(entry): + entries.append(entry) if ordering is not None: - instances.sort(key=attrgetter(ordering.by), reverse=ordering.reverse) + + def _cmp(a: SnapshotEntry, b: SnapshotEntry) -> int: + with suppress(AlreadyDeletedException): + with suppress(AlreadyDeletedException): + try: + aa = attrgetter(ordering.by)(a.build()) + except AlreadyDeletedException: + aa = attrgetter(ordering.by)(a) + with suppress(AlreadyDeletedException): + try: + bb = attrgetter(ordering.by)(b.build()) + except AlreadyDeletedException: + bb = attrgetter(ordering.by)(b) + + if aa > bb: + return 1 + elif aa < bb: + return -1 + + return 0 + + entries.sort(key=cmp_to_key(_cmp), reverse=ordering.reverse) if limit is not None: - instances = instances[:limit] + entries = entries[:limit] - for instance in instances: - yield instance + for entry in entries: + yield entry # noinspection PyMethodOverriding - async def _get(self, name: str, uuid: UUID, transaction: Optional[TransactionEntry] = None, **kwargs) -> RootEntity: + async def _get( + self, name: str, uuid: UUID, transaction: Optional[TransactionEntry] = None, **kwargs + ) -> SnapshotEntry: transaction_uuids = await self._get_transaction_uuids(transaction) entries = await self._get_event_entries(name, uuid, transaction_uuids) if not len(entries): raise NotFoundException(f"Not found any entries for the {uuid!r} id.") - if entries[-1].action.is_delete: - raise AlreadyDeletedException(f"The {uuid!r} identifier belongs to an already deleted instance.") - return self._build_instance(entries, **kwargs) async def _get_transaction_uuids(self, transaction: Optional[TransactionEntry]) -> tuple[UUID, ...]: @@ -147,12 +174,15 @@ async def _get_event_entries(self, name: str, uuid: UUID, transaction_uuids: tup return entries @staticmethod - def _build_instance(entries: list[EventEntry], **kwargs) -> RootEntity: + def _build_instance(entries: list[EventEntry], **kwargs) -> SnapshotEntry: + if entries[-1].action.is_delete: + return SnapshotEntry.from_event_entry(entries[-1]) + cls = entries[0].type_ instance = cls.from_diff(entries[0].event, **kwargs) for entry in entries[1:]: instance.apply_diff(entry.event) - return instance + return SnapshotEntry.from_root_entity(instance) async def _synchronize(self, **kwargs) -> None: pass diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py index d7f40eed1..f1608a42f 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py @@ -326,7 +326,7 @@ async def test_dispatch_with_offset(self): await self.snapshot_repository.synchronize() self.assertEqual(1, mock.call_count) - self.assertEqual(call(id_gt=0), mock.call_args) + self.assertEqual(call(id_gt=0, synchronize=False), mock.call_args) mock.reset_mock() # noinspection PyTypeChecker @@ -339,17 +339,17 @@ async def test_dispatch_with_offset(self): await self.snapshot_repository.synchronize() self.assertEqual(1, mock.call_count) - self.assertEqual(call(id_gt=11), mock.call_args) + self.assertEqual(call(id_gt=11, synchronize=False), mock.call_args) mock.reset_mock() await self.snapshot_repository.synchronize() self.assertEqual(1, mock.call_count) - self.assertEqual(call(id_gt=12), mock.call_args) + self.assertEqual(call(id_gt=12, synchronize=False), mock.call_args) mock.reset_mock() await self.snapshot_repository.synchronize() self.assertEqual(1, mock.call_count) - self.assertEqual(call(id_gt=12), mock.call_args) + self.assertEqual(call(id_gt=12, synchronize=False), mock.call_args) mock.reset_mock() async def test_find_by_uuid(self): diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_abc.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_abc.py index 1f0c979bb..4413415b2 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_abc.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_abc.py @@ -18,14 +18,19 @@ TRANSACTION_CONTEXT_VAR, Condition, Ordering, - RootEntity, + SnapshotEntry, SnapshotRepository, TransactionEntry, ) +from minos.aggregate.queries import ( + _EqualCondition, +) from minos.common import ( SetupMixin, ) from tests.utils import ( + AggregateTestCase, + Car, FakeAsyncIterator, ) @@ -33,28 +38,23 @@ class _SnapshotRepository(SnapshotRepository): """For testing purposes.""" - async def _get(self, *args, **kwargs) -> RootEntity: - """For testing purposes.""" - - def _find(self, *args, **kwargs) -> AsyncIterator[RootEntity]: + def _find_entries(self, *args, **kwargs) -> AsyncIterator[SnapshotEntry]: """For testing purposes.""" async def _synchronize(self, **kwargs) -> None: """For testing purposes.""" -class TestSnapshotRepository(unittest.IsolatedAsyncioTestCase): +class TestSnapshotRepository(AggregateTestCase): def setUp(self) -> None: super().setUp() self.snapshot_repository = _SnapshotRepository() - + self.entries = [SnapshotEntry.from_root_entity(Car(3, "red"))] * 5 self.synchronize_mock = AsyncMock() - self.get_mock = AsyncMock(return_value=1) - self.find_mock = MagicMock(return_value=FakeAsyncIterator(range(5))) + self.find_mock = MagicMock(return_value=FakeAsyncIterator(self.entries)) - self.snapshot_repository._get = self.get_mock - self.snapshot_repository._find = self.find_mock + self.snapshot_repository._find_entries = self.find_mock self.snapshot_repository._synchronize = self.synchronize_mock self.classname = "path.to.Product" @@ -64,41 +64,49 @@ def test_subclass(self): def test_abstract(self): # noinspection PyUnresolvedReferences - self.assertEqual({"_get", "_find", "_synchronize"}, SnapshotRepository.__abstractmethods__) + self.assertEqual({"_find_entries", "_synchronize"}, SnapshotRepository.__abstractmethods__) async def test_get(self): transaction = TransactionEntry() uuid = uuid4() observed = await self.snapshot_repository.get(self.classname, uuid, transaction) - self.assertEqual(1, observed) + self.assertEqual(self.entries[0].build(), observed) self.assertEqual(1, self.synchronize_mock.call_count) - self.assertEqual(call(), self.synchronize_mock.call_args) + self.assertEqual(call(synchronize=False), self.synchronize_mock.call_args) - self.assertEqual(1, self.get_mock.call_count) - args = call(name=self.classname, uuid=uuid, transaction=transaction) - self.assertEqual(args, self.get_mock.call_args) + self.assertEqual(1, self.find_mock.call_count) + args = call( + name=self.classname, + condition=_EqualCondition("uuid", uuid), + ordering=None, + limit=None, + streaming_mode=False, + transaction=transaction, + exclude_deleted=False, + ) + self.assertEqual(args, self.find_mock.call_args) async def test_get_transaction_null(self): await self.snapshot_repository.get(self.classname, uuid4()) - self.assertEqual(1, self.get_mock.call_count) - self.assertEqual(None, self.get_mock.call_args.kwargs["transaction"]) + self.assertEqual(1, self.find_mock.call_count) + self.assertEqual(None, self.find_mock.call_args.kwargs["transaction"]) async def test_get_transaction_context(self): transaction = TransactionEntry() TRANSACTION_CONTEXT_VAR.set(transaction) await self.snapshot_repository.get(self.classname, uuid4()) - self.assertEqual(1, self.get_mock.call_count) - self.assertEqual(transaction, self.get_mock.call_args.kwargs["transaction"]) + self.assertEqual(1, self.find_mock.call_count) + self.assertEqual(transaction, self.find_mock.call_args.kwargs["transaction"]) async def test_get_all(self): transaction = TransactionEntry() iterable = self.snapshot_repository.get_all(self.classname, Ordering.ASC("name"), 10, True, transaction) observed = [a async for a in iterable] - self.assertEqual(list(range(5)), observed) + self.assertEqual([e.build() for e in self.entries], observed) self.assertEqual( [ @@ -109,6 +117,7 @@ async def test_get_all(self): limit=10, streaming_mode=True, transaction=transaction, + exclude_deleted=True, ) ], self.find_mock.call_args_list, @@ -120,10 +129,10 @@ async def test_find(self): self.classname, Condition.TRUE, Ordering.ASC("name"), 10, True, transaction ) observed = [a async for a in iterable] - self.assertEqual(list(range(5)), observed) + self.assertEqual([e.build() for e in self.entries], observed) self.assertEqual(1, self.synchronize_mock.call_count) - self.assertEqual(call(), self.synchronize_mock.call_args) + self.assertEqual(call(synchronize=False), self.synchronize_mock.call_args) self.assertEqual(1, self.find_mock.call_count) args = call( @@ -133,6 +142,7 @@ async def test_find(self): limit=10, streaming_mode=True, transaction=transaction, + exclude_deleted=True, ) self.assertEqual(args, self.find_mock.call_args) @@ -154,7 +164,7 @@ async def test_synchronize(self): await self.snapshot_repository.synchronize() self.assertEqual(1, self.synchronize_mock.call_count) - self.assertEqual(call(), self.synchronize_mock.call_args) + self.assertEqual(call(synchronize=False), self.synchronize_mock.call_args) if __name__ == "__main__": diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py index 18bdf851f..0fbc1b325 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_memory.py @@ -15,7 +15,7 @@ ) -class TestInMemorySnapshotRepositoryReader(AggregateTestCase, SnapshotRepositoryTestCase): +class TestInMemorySnapshotRepository(AggregateTestCase, SnapshotRepositoryTestCase): __test__ = True def build_snapshot_repository(self) -> SnapshotRepository: @@ -30,6 +30,9 @@ def test_constructor_raises(self): # noinspection PyTypeChecker InMemorySnapshotRepository(transaction_repository=None) + async def test_dispatch_with_offset(self): + pass + if __name__ == "__main__": unittest.main() From df3fd9341eab70f5aa6cc6b7ee6118519e6ff426 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 14:46:19 +0200 Subject: [PATCH 237/324] ISSUE #98 * Patch `SnapshotRepository.build` method. --- .../minos/aggregate/snapshots/entries.py | 11 ----------- .../aggregate/snapshots/repositories/memory.py | 15 +++++++++------ 2 files changed, 9 insertions(+), 17 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py index 326e52a88..d2e3c4179 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py @@ -42,17 +42,6 @@ class SnapshotEntry: Is the python object representation of a row in the ``snapshot`` storage system. """ - __slots__ = ( - "uuid", - "name", - "version", - "schema", - "data", - "created_at", - "updated_at", - "transaction_uuid", - ) - # noinspection PyShadowingBuiltins def __init__( self, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py index c2048363a..176e6cb14 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py @@ -31,7 +31,6 @@ ) from ...exceptions import ( AlreadyDeletedException, - NotFoundException, ) from ...queries import ( _Condition, @@ -136,10 +135,6 @@ async def _get( ) -> SnapshotEntry: transaction_uuids = await self._get_transaction_uuids(transaction) entries = await self._get_event_entries(name, uuid, transaction_uuids) - - if not len(entries): - raise NotFoundException(f"Not found any entries for the {uuid!r} id.") - return self._build_instance(entries, **kwargs) async def _get_transaction_uuids(self, transaction: Optional[TransactionEntry]) -> tuple[UUID, ...]: @@ -182,7 +177,15 @@ def _build_instance(entries: list[EventEntry], **kwargs) -> SnapshotEntry: instance = cls.from_diff(entries[0].event, **kwargs) for entry in entries[1:]: instance.apply_diff(entry.event) - return SnapshotEntry.from_root_entity(instance) + + snapshot = SnapshotEntry.from_root_entity(instance) + + def _fn(*ag, **kw): + return instance + + snapshot.build = _fn # FIXME + + return snapshot async def _synchronize(self, **kwargs) -> None: pass From 8aeef85f896de18205882ec946fff5d891bae13e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 16:56:25 +0200 Subject: [PATCH 238/324] ISSUE #98 * Improve `decode_data`. --- .../minos/aggregate/entities/collections.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/entities/collections.py b/packages/core/minos-microservice-aggregate/minos/aggregate/entities/collections.py index 3925a7784..62da179b2 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/entities/collections.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/entities/collections.py @@ -140,6 +140,8 @@ def decode_data(cls, decoder: DataDecoder, target: Any, type_: ModelType, **kwar :param type_: The data type. :return: A decoded instance. """ + data_cls = get_args(type_.type_hints["data"])[1] + target = {decoder.build(v, data_cls, **kwargs) for v in target} target = {str(v["uuid"]): v for v in target} decoded = decoder.build(target, type_.type_hints["data"], **kwargs) return cls(decoded, additional_type_hints=type_.type_hints) From db61ce396bd8a6e709c558b259aa188f0f4503ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 17:42:00 +0200 Subject: [PATCH 239/324] ISSUE #98 * Remove patch. --- .../minos/aggregate/snapshots/repositories/memory.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py index 176e6cb14..cc8ecfb69 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/memory.py @@ -180,11 +180,6 @@ def _build_instance(entries: list[EventEntry], **kwargs) -> SnapshotEntry: snapshot = SnapshotEntry.from_root_entity(instance) - def _fn(*ag, **kw): - return instance - - snapshot.build = _fn # FIXME - return snapshot async def _synchronize(self, **kwargs) -> None: From da6502937d27020a203a73e6909922d58bd72f99 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 12 Apr 2022 18:33:35 +0200 Subject: [PATCH 240/324] ISSUE #98 * Fix bug related with type comparisons. --- .../aggregate/entities/refs/extractors.py | 6 +++- .../minos/common/__init__.py | 1 + .../minos/common/model/__init__.py | 1 + .../minos/common/model/fields.py | 3 +- .../minos/common/model/types/__init__.py | 1 + .../minos/common/model/types/builders.py | 31 ++++++++++++++++++ .../minos/common/model/types/model_types.py | 9 +++++- .../test_model/test_declarative/test_avro.py | 14 ++++---- .../test_model/test_types/test_builders.py | 32 +++++++++++++++++++ 9 files changed, 87 insertions(+), 11 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/extractors.py b/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/extractors.py index 298727725..96d22da41 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/extractors.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/entities/refs/extractors.py @@ -61,7 +61,11 @@ def _build(self, value: Any, type_: type, ans: dict[str, set[Ref]]) -> None: self._build_iterable(value.values(), get_args(type_)[1], ans) elif isinstance(value, Ref): - cls = value.data_cls or get_args(type_)[0] + cls = value.data_cls + if cls is None and len(args := get_args(type_)): + cls = args[0] + if cls is None and len(args := get_args(type_.type_hints["data"])): + cls = args[0] name = cls.__name__ ans[name].add(value) diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 08c200a00..4e7e0824a 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -103,6 +103,7 @@ SchemaEncoder, TypeHintBuilder, TypeHintComparator, + TypeHintParser, is_model_type, ) from .object import ( diff --git a/packages/core/minos-microservice-common/minos/common/model/__init__.py b/packages/core/minos-microservice-common/minos/common/model/__init__.py index 6cba174aa..04b4019e5 100644 --- a/packages/core/minos-microservice-common/minos/common/model/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/model/__init__.py @@ -31,5 +31,6 @@ NoneType, TypeHintBuilder, TypeHintComparator, + TypeHintParser, is_model_type, ) diff --git a/packages/core/minos-microservice-common/minos/common/model/fields.py b/packages/core/minos-microservice-common/minos/common/model/fields.py index 512cc8041..942e7cce4 100644 --- a/packages/core/minos-microservice-common/minos/common/model/fields.py +++ b/packages/core/minos-microservice-common/minos/common/model/fields.py @@ -31,6 +31,7 @@ MissingSentinel, TypeHintBuilder, TypeHintComparator, + TypeHintParser, ) logger = logging.getLogger(__name__) @@ -64,7 +65,7 @@ def name(self) -> str: @property def type(self) -> type: """Type getter.""" - return self._type + return TypeHintParser(self._type).build() @property def real_type(self) -> type: diff --git a/packages/core/minos-microservice-common/minos/common/model/types/__init__.py b/packages/core/minos-microservice-common/minos/common/model/types/__init__.py index 26649a7ca..2a6a407e7 100644 --- a/packages/core/minos-microservice-common/minos/common/model/types/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/model/types/__init__.py @@ -1,5 +1,6 @@ from .builders import ( TypeHintBuilder, + TypeHintParser, build_union, ) from .comparators import ( diff --git a/packages/core/minos-microservice-common/minos/common/model/types/builders.py b/packages/core/minos-microservice-common/minos/common/model/types/builders.py index 9a25d8290..dc84b4a74 100644 --- a/packages/core/minos-microservice-common/minos/common/model/types/builders.py +++ b/packages/core/minos-microservice-common/minos/common/model/types/builders.py @@ -6,6 +6,9 @@ from collections.abc import ( Iterable, ) +from functools import ( + lru_cache, +) from typing import ( Any, Optional, @@ -16,6 +19,7 @@ from .comparators import ( TypeHintComparator, + is_model_subclass, is_model_type, ) from .model_types import ( @@ -87,3 +91,30 @@ def _build_from_iterable(self, values: Iterable, type_: Optional[type]) -> type: @staticmethod def _build_from_dynamic(dynamic: type, static: Optional[type]) -> type: return dynamic if not len(get_args(static)) and TypeHintComparator(dynamic, static).match() else static + + +class TypeHintParser: + """Type Hint Parser class.""" + + def __init__(self, type_: Optional[type] = None): + self.type_ = type_ + + def build(self) -> type: + """Parse type hint. + + :return: A type. + """ + return self._build(self.type_) + + @classmethod + @lru_cache() + def _build(cls, type_: Optional[type]) -> type: + if is_model_subclass(type_): + # noinspection PyTypeChecker + return ModelType.from_model(type_) + + origin = get_origin(type_) + if origin is None: + return type_ + args = get_args(type_) + return cls._build(origin)[tuple(cls._build(arg) for arg in args)] diff --git a/packages/core/minos-microservice-common/minos/common/model/types/model_types.py b/packages/core/minos-microservice-common/minos/common/model/types/model_types.py index 027c89d34..e13812a83 100644 --- a/packages/core/minos-microservice-common/minos/common/model/types/model_types.py +++ b/packages/core/minos-microservice-common/minos/common/model/types/model_types.py @@ -87,8 +87,15 @@ def from_model(model: Union[Model, type[Model]]) -> ModelType: :param model: The model class. :return: A new ``ModelType`` instance. """ + from .builders import ( + TypeHintParser, + ) + + type_hints = GenericTypeProjector.from_model(model).build() + type_hints = {k: TypeHintParser(v).build() for k, v in type_hints.items()} + # noinspection PyTypeChecker - return ModelType.build(name_=model.classname, type_hints_=GenericTypeProjector.from_model(model).build()) + return ModelType.build(name_=model.classname, type_hints_=type_hints) def __call__(cls, *args, **kwargs) -> Model: return cls.model_cls.from_model_type(cls, *args, **kwargs) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_model/test_declarative/test_avro.py b/packages/core/minos-microservice-common/tests/test_common/test_model/test_declarative/test_avro.py index bc2927c80..2e851c368 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_model/test_declarative/test_avro.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_model/test_declarative/test_avro.py @@ -73,14 +73,12 @@ def test_avro_schema_generics_nested(self): "fields": [ { "name": "user", - "type": [ - { - "fields": [{"name": "username", "type": "string"}], - "name": "GenericUser", - "namespace": "tests.model_classes.goodbye", - "type": "record", - } - ], + "type": { + "fields": [{"name": "username", "type": "string"}], + "name": "GenericUser", + "namespace": "tests.model_classes.goodbye", + "type": "record", + }, } ], "name": "Auth", diff --git a/packages/core/minos-microservice-common/tests/test_common/test_model/test_types/test_builders.py b/packages/core/minos-microservice-common/tests/test_common/test_model/test_types/test_builders.py index 103cc4c66..24a849f60 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_model/test_types/test_builders.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_model/test_types/test_builders.py @@ -1,12 +1,14 @@ import unittest from typing import ( Any, + Optional, Union, ) from minos.common import ( ModelType, TypeHintBuilder, + TypeHintParser, ) from tests.model_classes import ( Foo, @@ -46,5 +48,35 @@ def test_union_any(self): self.assertEqual(expected, observed) +class TestTypeHintParser(unittest.TestCase): + def test_immutable(self): + self.assertEqual(int, TypeHintParser(int).build()) + + def test_optional(self): + self.assertEqual(Optional[int], TypeHintParser(Optional[int]).build()) + + def test_model(self): + # noinspection PyPep8Naming + FooMt = ModelType.build("tests.model_classes.Foo", {"text": str}) + self.assertEqual(FooMt, TypeHintParser(Foo).build()) + + def test_nested_model(self): + # noinspection PyPep8Naming + FooMt = ModelType.build("tests.model_classes.Foo", {"text": str}) + self.assertEqual(Optional[FooMt], TypeHintParser(Optional[Foo]).build()) + + def test_model_type(self): + # noinspection PyPep8Naming + FooMt = ModelType.build("tests.model_classes.Foo", {"text": str}) + self.assertEqual(FooMt, TypeHintParser(FooMt).build()) + + # noinspection PyPep8Naming + def test_model_type_nested(self): + Base = ModelType.build("Base", {"another": Foo}) + FooMt = ModelType.build("tests.model_classes.Foo", {"text": str}) + Expected = ModelType.build("Base", {"another": FooMt}) + self.assertEqual(Expected, TypeHintParser(Base).build()) + + if __name__ == "__main__": unittest.main() From 8d8cd39783cddb94de1df686fe9c97f1cfd59f90 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 09:42:47 +0200 Subject: [PATCH 241/324] ISSUE #98 * Increase coverage. --- .../minos/aggregate/snapshots/entries.py | 5 +- .../aggregate/snapshots/repositories/abc.py | 1 + .../aggregate/testing/snapshot_repository.py | 17 +- .../test_repositories/test_database.py | 415 ++++++++++++++++++ 4 files changed, 431 insertions(+), 7 deletions(-) create mode 100644 packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py index d2e3c4179..6a92f5078 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/entries.py @@ -49,7 +49,7 @@ def __init__( name: str, version: int, schema: Optional[Union[list[dict[str, Any]], dict[str, Any]], bytes, memoryview] = None, - data: Optional[dict[str, Any]] = None, + data: Optional[Union[dict[str, Any], str]] = None, created_at: Optional[datetime] = None, updated_at: Optional[datetime] = None, transaction_uuid: UUID = NULL_UUID, @@ -59,6 +59,9 @@ def __init__( if isinstance(schema, bytes): schema = MinosJsonBinaryProtocol.decode(schema) + if isinstance(data, str): + data = json.loads(data) + self.uuid = uuid self.name = name self.version = version diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py index d753e1069..a047d5f16 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py @@ -190,6 +190,7 @@ async def find_entries( performed to the global snapshot. :param exclude_deleted: If ``True``, deleted ``RootEntity`` entries are included, otherwise deleted ``RootEntity`` entries are filtered. + :param synchronize: TODO :param kwargs: Additional named arguments. :return: An asynchronous iterator that containing the ``RootEntity`` instances. """ diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py index f1608a42f..2a95000df 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py @@ -3,7 +3,7 @@ abstractmethod, ) from datetime import ( - datetime, + timedelta, ) from typing import ( Optional, @@ -33,6 +33,7 @@ TransactionStatus, ) from minos.common import ( + classname, current_datetime, ) from minos.common.testing import ( @@ -80,8 +81,7 @@ def build_snapshot_repository(self) -> SnapshotRepository: async def populate(self) -> None: diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) - # noinspection PyTypeChecker - name: str = Car.classname + name: str = classname(Car) await self.event_repository.create(EventEntry(self.uuid_1, name, 1, diff.avro_bytes)) await self.event_repository.update(EventEntry(self.uuid_1, name, 2, diff.avro_bytes)) @@ -119,6 +119,9 @@ async def populate(self) -> None: async def populate_and_synchronize(self): await self.populate() + await self.synchronize() + + async def synchronize(self): await self.snapshot_repository.synchronize() async def asyncSetUp(self): @@ -138,8 +141,8 @@ def assert_equal_snapshot_entries(self, expected: list[SnapshotEntry], observed: obs.build() else: self.assertEqual(exp.build(), obs.build()) - self.assertIsInstance(obs.created_at, datetime) - self.assertIsInstance(obs.updated_at, datetime) + self.assertAlmostEqual(exp.created_at or current_datetime(), obs.created_at, delta=timedelta(seconds=5)) + self.assertAlmostEqual(exp.updated_at or current_datetime(), obs.updated_at, delta=timedelta(seconds=5)) def test_type(self): self.assertTrue(isinstance(self.snapshot_repository, SnapshotRepository)) @@ -294,7 +297,9 @@ async def test_dispatch_ignore_previous_version(self): name: str = Car.classname condition = Condition.EQUAL("uuid", self.uuid_1) - async def _fn(*args, **kwargs): + async def _fn(*args, id_gt: Optional[int] = None, **kwargs): + if id_gt is not None and id_gt > 0: + return yield EventEntry(self.uuid_1, name, 1, diff.avro_bytes, 1, Action.CREATE, current_datetime()) yield EventEntry(self.uuid_1, name, 3, diff.avro_bytes, 2, Action.CREATE, current_datetime()) yield EventEntry(self.uuid_1, name, 2, diff.avro_bytes, 3, Action.CREATE, current_datetime()) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py new file mode 100644 index 000000000..8aea1879f --- /dev/null +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py @@ -0,0 +1,415 @@ +import unittest +from unittest.mock import ( + patch, +) + +from minos.aggregate import ( + DatabaseSnapshotRepository, + SnapshotEntry, + SnapshotRepository, +) +from minos.aggregate.testing import ( + SnapshotRepositoryTestCase, +) +from minos.aggregate.testing.snapshot_repository import ( + Car, +) +from minos.common import ( + DatabaseClient, + classname, + current_datetime, +) +from tests.utils import ( + AggregateTestCase, + FakeAsyncIterator, +) + + +class TestDatabaseSnapshotRepository(AggregateTestCase, SnapshotRepositoryTestCase): + __test__ = True + + def build_snapshot_repository(self) -> SnapshotRepository: + return DatabaseSnapshotRepository.from_config(self.config) + + async def synchronize(self): + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + StopAsyncIteration, + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + ], + ): + with patch.object(DatabaseClient, "fetch_all", return_value=FakeAsyncIterator([])): + await super().synchronize() + + async def test_dispatch(self): + entries = [ + SnapshotEntry(self.uuid_1, classname(Car), 4, created_at=current_datetime(), updated_at=current_datetime()), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_2, + version=2, + created_at=current_datetime(), + updated_at=current_datetime(), + ) + ), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=current_datetime(), + updated_at=current_datetime(), + ) + ), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in entries]), + ): + await super().test_dispatch() + + async def test_dispatch_first_transaction(self): + entries = [ + SnapshotEntry(self.uuid_1, classname(Car), 4, created_at=current_datetime(), updated_at=current_datetime()), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_2, + version=4, + created_at=current_datetime(), + updated_at=current_datetime(), + ) + ), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=current_datetime(), + updated_at=current_datetime(), + ) + ), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in entries]), + ): + await super().test_dispatch_first_transaction() + + async def test_dispatch_second_transaction(self): + entries = [ + SnapshotEntry(self.uuid_1, classname(Car), 4, created_at=current_datetime(), updated_at=current_datetime()), + SnapshotEntry(self.uuid_2, classname(Car), 4, created_at=current_datetime(), updated_at=current_datetime()), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=current_datetime(), + updated_at=current_datetime(), + ) + ), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in entries]), + ): + await super().test_dispatch_second_transaction() + + async def test_dispatch_third_transaction(self): + entries = [ + SnapshotEntry(self.uuid_1, classname(Car), 4, created_at=current_datetime(), updated_at=current_datetime()), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_2, + version=2, + created_at=current_datetime(), + updated_at=current_datetime(), + ) + ), + SnapshotEntry.from_root_entity( + Car( + 3, + "blue", + uuid=self.uuid_3, + version=1, + created_at=current_datetime(), + updated_at=current_datetime(), + ) + ), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in entries]), + ): + await super().test_dispatch_third_transaction() + + async def test_dispatch_ignore_previous_version(self): + entries = [ + SnapshotEntry( + uuid=self.uuid_1, + name=classname(Car), + version=3, + schema=Car.avro_schema, + data=Car(3, "blue", uuid=self.uuid_1, version=1).avro_data, + created_at=current_datetime(), + updated_at=current_datetime(), + ) + ] + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + StopAsyncIteration, + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (9999,), + ], + ): + with patch.object( + DatabaseClient, + "fetch_all", + side_effect=[ + FakeAsyncIterator([]), + FakeAsyncIterator([]), + FakeAsyncIterator([]), + FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in entries]), + ], + ): + await super().test_dispatch_ignore_previous_version() + + async def test_dispatch_with_offset(self): + with patch.object( + DatabaseClient, + "fetch_one", + side_effect=[ + (0,), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (current_datetime(), current_datetime()), + (11,), + (current_datetime(), current_datetime()), + (12,), + (12,), + ], + ): + await super().test_dispatch_with_offset() + + async def test_find_by_uuid(self): + entities = [ + Car(3, "blue", uuid=self.uuid_2, version=2), + Car(3, "blue", uuid=self.uuid_3, version=1), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_find_by_uuid() + + async def test_find_with_transaction(self): + entities = [ + Car(3, "blue", uuid=self.uuid_2, version=4), + Car(3, "blue", uuid=self.uuid_3, version=1), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_find_with_transaction() + + async def test_find_with_transaction_delete(self): + entities = [Car(3, "blue", uuid=self.uuid_3, version=1)] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_find_with_transaction_delete() + + async def test_find_with_transaction_reverted(self): + entities = [ + Car(3, "blue", uuid=self.uuid_2, version=2), + Car(3, "blue", uuid=self.uuid_3, version=1), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_find_with_transaction_reverted() + + async def test_find_streaming_true(self): + entities = [ + Car(3, "blue", uuid=self.uuid_2, version=2), + Car(3, "blue", uuid=self.uuid_3, version=1), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_find_streaming_true() + + async def test_find_with_duplicates(self): + entities = [ + Car(3, "blue", uuid=self.uuid_2, version=2), + Car(3, "blue", uuid=self.uuid_3, version=1), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_find_with_duplicates() + + async def test_find_empty(self): + entities = [] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_find_empty() + + async def test_get(self): + entities = [ + Car(3, "blue", uuid=self.uuid_2, version=2), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_get() + + async def test_get_with_transaction(self): + entities = [Car(3, "blue", uuid=self.uuid_2, version=4)] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_get_with_transaction() + + async def test_get_raises(self): + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + side_effect=[ + FakeAsyncIterator([tuple(SnapshotEntry(self.uuid_1, classname(Car), 1).as_raw().values())]), + FakeAsyncIterator([]), + ], + ): + await super().test_get_raises() + + async def test_get_with_transaction_raises(self): + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry(self.uuid_1, classname(Car), 1).as_raw().values())] + ), + ): + await super().test_get_with_transaction_raises() + + async def test_find(self): + entities = [ + Car(3, "blue", uuid=self.uuid_2, version=2), + Car(3, "blue", uuid=self.uuid_3, version=1), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_find() + + async def test_find_all(self): + entities = [ + Car(3, "blue", uuid=self.uuid_2, version=2), + Car(3, "blue", uuid=self.uuid_3, version=1), + ] + with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): + with patch.object( + DatabaseClient, + "fetch_all", + return_value=FakeAsyncIterator( + [tuple(SnapshotEntry.from_root_entity(entity).as_raw().values()) for entity in entities] + ), + ): + await super().test_find_all() + + +if __name__ == "__main__": + unittest.main() From 38d7031e788fae49bfa21b6826a91ff4079b8671 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 09:48:27 +0200 Subject: [PATCH 242/324] ISSUE #98 * Increase coverage (2). --- .../test_repositories/test_database.py | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py index 8aea1879f..94b8317c7 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py @@ -1,5 +1,6 @@ import unittest from unittest.mock import ( + MagicMock, patch, ) @@ -16,6 +17,7 @@ ) from minos.common import ( DatabaseClient, + NotProvidedException, classname, current_datetime, ) @@ -28,6 +30,26 @@ class TestDatabaseSnapshotRepository(AggregateTestCase, SnapshotRepositoryTestCase): __test__ = True + def test_constructor_raises(self): + with self.assertRaises(NotProvidedException): + # noinspection PyTypeChecker + DatabaseSnapshotRepository(event_repository=None) + + with self.assertRaises(NotProvidedException): + # noinspection PyTypeChecker + DatabaseSnapshotRepository(transaction_repository=None) + + async def test_is_synced(self): + self.event_repository.select = MagicMock(side_effect=[FakeAsyncIterator([1]), FakeAsyncIterator([])]) + + with patch.object( + DatabaseClient, + "fetch_one", + return_value=(0,) + ): + self.assertFalse(await self.snapshot_repository.is_synced(Car)) + self.assertTrue(await self.snapshot_repository.is_synced(Car)) + def build_snapshot_repository(self) -> SnapshotRepository: return DatabaseSnapshotRepository.from_config(self.config) From a483bed5008362615f3f4125f5152528f250ac39 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 09:56:58 +0200 Subject: [PATCH 243/324] ISSUE #98 * Increase coverage (3). --- .../test_repositories/test_database.py | 45 +++++++++++++++---- 1 file changed, 37 insertions(+), 8 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py index 94b8317c7..5a3209948 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py @@ -1,4 +1,8 @@ import unittest +from itertools import ( + chain, + cycle, +) from unittest.mock import ( MagicMock, patch, @@ -42,11 +46,7 @@ def test_constructor_raises(self): async def test_is_synced(self): self.event_repository.select = MagicMock(side_effect=[FakeAsyncIterator([1]), FakeAsyncIterator([])]) - with patch.object( - DatabaseClient, - "fetch_one", - return_value=(0,) - ): + with patch.object(DatabaseClient, "fetch_one", return_value=(0,)): self.assertFalse(await self.snapshot_repository.is_synced(Car)) self.assertTrue(await self.snapshot_repository.is_synced(Car)) @@ -72,7 +72,29 @@ async def synchronize(self): (current_datetime(), current_datetime()), ], ): - with patch.object(DatabaseClient, "fetch_all", return_value=FakeAsyncIterator([])): + with patch.object( + DatabaseClient, + "fetch_all", + side_effect=chain( + [ + FakeAsyncIterator([]), + FakeAsyncIterator( + [ + tuple( + SnapshotEntry.from_root_entity(Car(3, "blue", uuid=self.uuid_1, version=1)) + .as_raw() + .values() + ) + ] + ), + ], + cycle( + [ + FakeAsyncIterator([]), + ] + ), + ), + ): await super().synchronize() async def test_dispatch(self): @@ -213,7 +235,6 @@ async def test_dispatch_ignore_previous_version(self): StopAsyncIteration, (current_datetime(), current_datetime()), (current_datetime(), current_datetime()), - (current_datetime(), current_datetime()), (9999,), ], ): @@ -222,7 +243,15 @@ async def test_dispatch_ignore_previous_version(self): "fetch_all", side_effect=[ FakeAsyncIterator([]), - FakeAsyncIterator([]), + FakeAsyncIterator( + [ + tuple( + SnapshotEntry.from_root_entity(Car(3, "blue", uuid=self.uuid_1, version=5)) + .as_raw() + .values() + ) + ] + ), FakeAsyncIterator([]), FakeAsyncIterator([tuple(entry.as_raw().values()) for entry in entries]), ], From 8192b702b6c240938e8eefb62e1a6a7baa1ec243 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 10:54:43 +0200 Subject: [PATCH 244/324] ISSUE #98 * Rename files. --- .../test_queues/{test_pg.py => test_database.py} | 0 .../test_queued/test_queues/{test_pg.py => test_database.py} | 0 .../test_duplicates/{test_pg.py => test_database.py} | 0 .../test_queued/test_queues/{test_pg.py => test_database.py} | 0 .../plugins/aiopg/factories/networks/collections/__init__.py | 2 +- .../factories/networks/collections/{queue.py => queues.py} | 0 .../plugins/aiopg/factories/networks/publishers/__init__.py | 2 +- .../factories/networks/publishers/{queue.py => queues.py} | 0 .../plugins/aiopg/factories/networks/subscribers/__init__.py | 4 ++-- .../factories/networks/subscribers/{queue.py => queues.py} | 0 .../networks/subscribers/{validator.py => validators.py} | 0 .../test_events/{test_pg.py => test_repositories.py} | 0 .../test_snapshots/{test_pg.py => test_repository.py} | 0 .../test_transactions/{test_pg.py => test_repository.py} | 0 14 files changed, 4 insertions(+), 4 deletions(-) rename packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/{test_pg.py => test_database.py} (100%) rename packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/{test_pg.py => test_database.py} (100%) rename packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/{test_pg.py => test_database.py} (100%) rename packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/{test_pg.py => test_database.py} (100%) rename packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/{queue.py => queues.py} (100%) rename packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/{queue.py => queues.py} (100%) rename packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/{queue.py => queues.py} (100%) rename packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/{validator.py => validators.py} (100%) rename packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/{test_pg.py => test_repositories.py} (100%) rename packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/{test_pg.py => test_repository.py} (100%) rename packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/{test_pg.py => test_repository.py} (100%) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_database.py similarity index 100% rename from packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_pg.py rename to packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_database.py diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_database.py similarity index 100% rename from packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_pg.py rename to packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_database.py diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_database.py similarity index 100% rename from packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_pg.py rename to packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_database.py diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_database.py similarity index 100% rename from packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_pg.py rename to packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_database.py diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/__init__.py index b66f563c8..7f6fc30e8 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/__init__.py @@ -1,3 +1,3 @@ -from .queue import ( +from .queues import ( AiopgBrokerQueueDatabaseOperationFactory, ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queue.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queues.py similarity index 100% rename from packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queue.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queues.py diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/__init__.py index 60a42fafa..fd07a5ba7 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/__init__.py @@ -1,3 +1,3 @@ -from .queue import ( +from .queues import ( AiopgBrokerPublisherQueueDatabaseOperationFactory, ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queue.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queues.py similarity index 100% rename from packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queue.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queues.py diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/__init__.py index 44e93f099..e4eedf459 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/__init__.py @@ -1,6 +1,6 @@ -from .queue import ( +from .queues import ( AiopgBrokerSubscriberQueueDatabaseOperationFactory, ) -from .validator import ( +from .validators import ( AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queue.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queues.py similarity index 100% rename from packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queue.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queues.py diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validator.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validators.py similarity index 100% rename from packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validator.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validators.py diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_repositories.py similarity index 100% rename from packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_pg.py rename to packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_repositories.py diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_repository.py similarity index 100% rename from packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_pg.py rename to packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_repository.py diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_repository.py similarity index 100% rename from packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_pg.py rename to packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_repository.py From 743bdd58f449186d9a03e33ef94984b53e62cf0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 11:00:39 +0200 Subject: [PATCH 245/324] ISSUE #98 * Rename files. --- packages/core/minos-microservice-aggregate/tests/utils.py | 6 +++--- .../core/minos-microservice-common/minos/common/__init__.py | 2 +- .../minos/common/database/__init__.py | 4 ++-- .../minos/common/database/manage/__init__.py | 3 --- .../minos/common/database/managements/__init__.py | 3 +++ .../common/database/{manage => managements}/factories.py | 4 ++-- .../core/minos-microservice-common/minos/common/testing.py | 6 +++--- packages/core/minos-microservice-common/tests/utils.py | 6 +++--- packages/core/minos-microservice-cqrs/tests/utils.py | 6 +++--- packages/core/minos-microservice-networks/tests/utils.py | 6 +++--- .../minos-database-aiopg/minos/plugins/aiopg/__init__.py | 2 +- .../minos/plugins/aiopg/factories/__init__.py | 2 +- .../minos/plugins/aiopg/factories/common/__init__.py | 4 ++-- .../aiopg/factories/common/{manage.py => managemens.py} | 6 +++--- 14 files changed, 30 insertions(+), 30 deletions(-) delete mode 100644 packages/core/minos-microservice-common/minos/common/database/manage/__init__.py create mode 100644 packages/core/minos-microservice-common/minos/common/database/managements/__init__.py rename packages/core/minos-microservice-common/minos/common/database/{manage => managements}/factories.py (83%) rename packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/{manage.py => managemens.py} (79%) diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index a5daee718..69001e084 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -52,7 +52,7 @@ Lock, LockDatabaseOperationFactory, LockPool, - ManageDatabaseOperationFactory, + ManagementDatabaseOperationFactory, PoolFactory, ) from minos.common.testing import ( @@ -148,7 +148,7 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) -class FakeManageDatabaseOperationFactory(ManageDatabaseOperationFactory): +class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): """For testing purposes""" def build_create(self, database: str) -> DatabaseOperation: @@ -160,7 +160,7 @@ def build_delete(self, database: str) -> DatabaseOperation: return FakeDatabaseOperation("delete") -FakeDatabaseClient.register_factory(ManageDatabaseOperationFactory, FakeManageDatabaseOperationFactory) +FakeDatabaseClient.register_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) class FakeTransactionDatabaseOperationFactory(TransactionDatabaseOperationFactory): diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 4e7e0824a..072927064 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -26,7 +26,7 @@ DatabaseOperationFactory, IntegrityException, LockDatabaseOperationFactory, - ManageDatabaseOperationFactory, + ManagementDatabaseOperationFactory, UnableToConnectException, ) from .datetime import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index 1ed02893f..811be8e95 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -9,8 +9,8 @@ DatabaseLock, LockDatabaseOperationFactory, ) -from .manage import ( - ManageDatabaseOperationFactory, +from .managements import ( + ManagementDatabaseOperationFactory, ) from .mixins import ( DatabaseMixin, diff --git a/packages/core/minos-microservice-common/minos/common/database/manage/__init__.py b/packages/core/minos-microservice-common/minos/common/database/manage/__init__.py deleted file mode 100644 index 442bfff30..000000000 --- a/packages/core/minos-microservice-common/minos/common/database/manage/__init__.py +++ /dev/null @@ -1,3 +0,0 @@ -from .factories import ( - ManageDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-common/minos/common/database/managements/__init__.py b/packages/core/minos-microservice-common/minos/common/database/managements/__init__.py new file mode 100644 index 000000000..a00b0ae0d --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/database/managements/__init__.py @@ -0,0 +1,3 @@ +from .factories import ( + ManagementDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-common/minos/common/database/manage/factories.py b/packages/core/minos-microservice-common/minos/common/database/managements/factories.py similarity index 83% rename from packages/core/minos-microservice-common/minos/common/database/manage/factories.py rename to packages/core/minos-microservice-common/minos/common/database/managements/factories.py index f140af805..d84c5ebbe 100644 --- a/packages/core/minos-microservice-common/minos/common/database/manage/factories.py +++ b/packages/core/minos-microservice-common/minos/common/database/managements/factories.py @@ -9,8 +9,8 @@ ) -class ManageDatabaseOperationFactory(DatabaseOperationFactory, ABC): - """Manage Database Operation Factory base class.""" +class ManagementDatabaseOperationFactory(DatabaseOperationFactory, ABC): + """Management Database Operation Factory base class.""" @abstractmethod def build_create(self, database: str) -> DatabaseOperation: diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing.py index baa99e521..e868b54e8 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing.py @@ -26,7 +26,7 @@ from .database import ( DatabaseClient, DatabaseClientPool, - ManageDatabaseOperationFactory, + ManagementDatabaseOperationFactory, ) from .injections import ( DependencyInjector, @@ -113,10 +113,10 @@ async def _create_database(self, test: dict[str, Any]) -> None: await self._drop_database(test) async with self.get_client() as client: - operation = client.get_factory(ManageDatabaseOperationFactory).build_create(test["database"]) + operation = client.get_factory(ManagementDatabaseOperationFactory).build_create(test["database"]) await client.execute(operation) async def _drop_database(self, test: dict[str, Any]) -> None: async with self.get_client() as client: - operation = client.get_factory(ManageDatabaseOperationFactory).build_delete(test["database"]) + operation = client.get_factory(ManagementDatabaseOperationFactory).build_delete(test["database"]) await client.execute(operation) diff --git a/packages/core/minos-microservice-common/tests/utils.py b/packages/core/minos-microservice-common/tests/utils.py index d62eee54f..43701b670 100644 --- a/packages/core/minos-microservice-common/tests/utils.py +++ b/packages/core/minos-microservice-common/tests/utils.py @@ -23,7 +23,7 @@ Lock, LockDatabaseOperationFactory, LockPool, - ManageDatabaseOperationFactory, + ManagementDatabaseOperationFactory, Port, ) from minos.common.testing import ( @@ -122,7 +122,7 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) -class FakeManageDatabaseOperationFactory(ManageDatabaseOperationFactory): +class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): """For testing purposes""" def build_create(self, database: str) -> DatabaseOperation: @@ -134,7 +134,7 @@ def build_delete(self, database: str) -> DatabaseOperation: return FakeDatabaseOperation("delete") -FakeDatabaseClient.register_factory(ManageDatabaseOperationFactory, FakeManageDatabaseOperationFactory) +FakeDatabaseClient.register_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) class FakeDatabaseOperation(DatabaseOperation): diff --git a/packages/core/minos-microservice-cqrs/tests/utils.py b/packages/core/minos-microservice-cqrs/tests/utils.py index 5ab66b6ac..8cbef68fa 100644 --- a/packages/core/minos-microservice-cqrs/tests/utils.py +++ b/packages/core/minos-microservice-cqrs/tests/utils.py @@ -23,7 +23,7 @@ DatabaseClient, DatabaseOperation, LockDatabaseOperationFactory, - ManageDatabaseOperationFactory, + ManagementDatabaseOperationFactory, ) from minos.cqrs import ( CommandService, @@ -121,7 +121,7 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) -class FakeManageDatabaseOperationFactory(ManageDatabaseOperationFactory): +class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): """For testing purposes""" def build_create(self, database: str) -> DatabaseOperation: @@ -133,4 +133,4 @@ def build_delete(self, database: str) -> DatabaseOperation: return FakeDatabaseOperation("delete") -FakeDatabaseClient.register_factory(ManageDatabaseOperationFactory, FakeManageDatabaseOperationFactory) +FakeDatabaseClient.register_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-networks/tests/utils.py b/packages/core/minos-microservice-networks/tests/utils.py index a2040962b..018df1a55 100644 --- a/packages/core/minos-microservice-networks/tests/utils.py +++ b/packages/core/minos-microservice-networks/tests/utils.py @@ -32,7 +32,7 @@ DatabaseOperation, DeclarativeModel, LockDatabaseOperationFactory, - ManageDatabaseOperationFactory, + ManagementDatabaseOperationFactory, ) from minos.common.testing import ( MinosTestCase, @@ -109,7 +109,7 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) -class FakeManageDatabaseOperationFactory(ManageDatabaseOperationFactory): +class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): """For testing purposes""" def build_create(self, database: str) -> DatabaseOperation: @@ -121,7 +121,7 @@ def build_delete(self, database: str) -> DatabaseOperation: return FakeDatabaseOperation("delete") -FakeDatabaseClient.register_factory(ManageDatabaseOperationFactory, FakeManageDatabaseOperationFactory) +FakeDatabaseClient.register_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) class FakeBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory): diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py index 03e492269..15ff2a727 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py @@ -8,7 +8,7 @@ AiopgBrokerSubscriberQueueDatabaseOperationFactory, AiopgEventDatabaseOperationFactory, AiopgLockDatabaseOperationFactory, - AiopgManageDatabaseOperationFactory, + AiopgManagementDatabaseOperationFactory, AiopgSnapshotDatabaseOperationFactory, AiopgSnapshotQueryDatabaseOperationBuilder, AiopgTransactionDatabaseOperationFactory, diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py index 21132368f..0a9416f42 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/__init__.py @@ -6,7 +6,7 @@ ) from .common import ( AiopgLockDatabaseOperationFactory, - AiopgManageDatabaseOperationFactory, + AiopgManagementDatabaseOperationFactory, ) from .networks import ( AiopgBrokerPublisherQueueDatabaseOperationFactory, diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/__init__.py index ec2c30084..bd213d8b7 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/__init__.py @@ -1,6 +1,6 @@ from .locks import ( AiopgLockDatabaseOperationFactory, ) -from .manage import ( - AiopgManageDatabaseOperationFactory, +from .managemens import ( + AiopgManagementDatabaseOperationFactory, ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/manage.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/managemens.py similarity index 79% rename from packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/manage.py rename to packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/managemens.py index 995034455..119d2bad6 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/manage.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/managemens.py @@ -1,6 +1,6 @@ from minos.common import ( DatabaseOperation, - ManageDatabaseOperationFactory, + ManagementDatabaseOperationFactory, ) from ...clients import ( @@ -12,7 +12,7 @@ # noinspection SqlNoDataSourceInspection -class AiopgManageDatabaseOperationFactory(ManageDatabaseOperationFactory): +class AiopgManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): """Aiopg Manage Database Operation Factory class.""" def build_create(self, database: str) -> DatabaseOperation: @@ -32,4 +32,4 @@ def build_delete(self, database: str) -> DatabaseOperation: return AiopgDatabaseOperation(f"DROP DATABASE IF EXISTS {database};") -AiopgDatabaseClient.register_factory(ManageDatabaseOperationFactory, AiopgManageDatabaseOperationFactory) +AiopgDatabaseClient.register_factory(ManagementDatabaseOperationFactory, AiopgManagementDatabaseOperationFactory) From ba8d7963fa36b0e20924cd546f79f9bc3e1876ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 11:20:38 +0200 Subject: [PATCH 246/324] ISSUE #98 * Increase coverage. --- .../{ => test_snapshots}/test_queries.py | 0 .../test_factories/test_common/__init__.py | 0 .../test_factories/test_common/test_locks.py | 29 ++++++++++++ .../test_common/test_managements.py | 29 ++++++++++++ .../test_collections/__init__.py | 0 .../test_collections/test_queues.py | 31 +++++++++++++ .../test_publishers/test_queues.py | 31 ++++++++++++- .../test_subscribers/test_queues.py | 21 +++++++++ .../test_subscribers/test_validators.py | 46 +++++++++++++++++++ 9 files changed, 186 insertions(+), 1 deletion(-) rename packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/{ => test_snapshots}/test_queries.py (100%) create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/test_locks.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/test_managements.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/__init__.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/test_queues.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_validators.py diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_queries.py similarity index 100% rename from packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_queries.py rename to packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_queries.py diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/test_locks.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/test_locks.py new file mode 100644 index 000000000..6f518a290 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/test_locks.py @@ -0,0 +1,29 @@ +import unittest + +from minos.common import ( + LockDatabaseOperationFactory, +) +from minos.plugins.aiopg import ( + AiopgDatabaseOperation, + AiopgLockDatabaseOperationFactory, +) + + +class TestAiopgLockDatabaseOperationFactory(unittest.TestCase): + def setUp(self) -> None: + self.factory = AiopgLockDatabaseOperationFactory() + + def test_is_subclass(self): + self.assertTrue(issubclass(AiopgLockDatabaseOperationFactory, LockDatabaseOperationFactory)) + + def test_build_acquire(self): + operation = self.factory.build_acquire(56) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_release(self): + operation = self.factory.build_release(56) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/test_managements.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/test_managements.py new file mode 100644 index 000000000..fe0996797 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_common/test_managements.py @@ -0,0 +1,29 @@ +import unittest + +from minos.common import ( + ManagementDatabaseOperationFactory, +) +from minos.plugins.aiopg import ( + AiopgDatabaseOperation, + AiopgManagementDatabaseOperationFactory, +) + + +class TestAiopgManagementDatabaseOperationFactory(unittest.TestCase): + def setUp(self) -> None: + self.factory = AiopgManagementDatabaseOperationFactory() + + def test_is_subclass(self): + self.assertTrue(issubclass(AiopgManagementDatabaseOperationFactory, ManagementDatabaseOperationFactory)) + + def test_build_create(self): + operation = self.factory.build_create("foo") + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_delete(self): + operation = self.factory.build_delete("foo") + self.assertIsInstance(operation, AiopgDatabaseOperation) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/__init__.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/test_queues.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/test_queues.py new file mode 100644 index 000000000..03fed3d90 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/test_queues.py @@ -0,0 +1,31 @@ +import unittest + +from minos.networks import ( + BrokerQueueDatabaseOperationFactory, +) +from minos.plugins.aiopg import ( + AiopgBrokerQueueDatabaseOperationFactory, +) + + +class _BrokerQueueDatabaseOperationFactory(AiopgBrokerQueueDatabaseOperationFactory): + """For testing purposes.""" + + def build_table_name(self) -> str: + """For testing purposes.""" + return "foo" + + +class TestAiopgBrokerQueueDatabaseOperationFactory(unittest.TestCase): + def setUp(self) -> None: + self.factory = _BrokerQueueDatabaseOperationFactory() + + def test_is_subclass(self): + self.assertTrue(AiopgBrokerQueueDatabaseOperationFactory, BrokerQueueDatabaseOperationFactory) + + def test_build_table_name(self): + self.assertEqual("foo", self.factory.build_table_name()) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py index abebe32dd..f9192ad36 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py @@ -6,6 +6,7 @@ from minos.plugins.aiopg import ( AiopgBrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory, + AiopgDatabaseOperation, ) @@ -13,7 +14,7 @@ class TestAiopgBrokerPublisherQueueDatabaseOperationFactory(unittest.TestCase): def setUp(self) -> None: self.factory = AiopgBrokerPublisherQueueDatabaseOperationFactory() - def test_subclass(self): + def test_is_subclass(self): self.assertTrue( AiopgBrokerPublisherQueueDatabaseOperationFactory, (BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory), @@ -22,6 +23,34 @@ def test_subclass(self): def test_build_table_name(self): self.assertEqual("broker_publisher_queue", self.factory.build_table_name()) + def test_build_create_table(self): + operation = self.factory.build_create_table() + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_update_not_processed(self): + operation = self.factory.build_update_not_processed(id_=56) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_delete_processed(self): + operation = self.factory.build_delete_processed(id_=56) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_mark_processing(self): + operation = self.factory.build_mark_processing(ids={56, 78}) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_count_not_processed(self): + operation = self.factory.build_count_not_processed(retry=3) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_insert(self): + operation = self.factory.build_insert(topic="foo", data=bytes()) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_select_not_processed(self): + operation = self.factory.build_select_not_processed(retry=3, records=1000) + self.assertIsInstance(operation, AiopgDatabaseOperation) + if __name__ == "__main__": unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py index 4ba38c918..ec4e2687f 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py @@ -1,7 +1,12 @@ import unittest +from minos.networks import ( + BrokerSubscriberQueueDatabaseOperationFactory, +) from minos.plugins.aiopg import ( + AiopgBrokerQueueDatabaseOperationFactory, AiopgBrokerSubscriberQueueDatabaseOperationFactory, + AiopgDatabaseOperation, ) @@ -9,9 +14,25 @@ class TestAiopgBrokerSubscriberQueueDatabaseOperationFactory(unittest.TestCase): def setUp(self) -> None: self.factory = AiopgBrokerSubscriberQueueDatabaseOperationFactory() + def test_is_subclass(self): + self.assertTrue( + issubclass( + AiopgBrokerSubscriberQueueDatabaseOperationFactory, + (BrokerSubscriberQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory), + ) + ) + def test_build_table_name(self): self.assertEqual("broker_subscriber_queue", self.factory.build_table_name()) + def test_build_count_not_processed(self): + operation = self.factory.build_count_not_processed(retry=3, topics={"foo", "bar"}) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_select_not_processed(self): + operation = self.factory.build_select_not_processed(retry=3, records=100, topics={"foo", "bar"}) + self.assertIsInstance(operation, AiopgDatabaseOperation) + if __name__ == "__main__": unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_validators.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_validators.py new file mode 100644 index 000000000..96dee6a29 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_validators.py @@ -0,0 +1,46 @@ +import unittest +from uuid import ( + uuid4, +) + +from minos.common import ( + ComposedDatabaseOperation, +) +from minos.networks import ( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, +) +from minos.plugins.aiopg import ( + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + AiopgDatabaseOperation, +) + + +class TestAiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory(unittest.TestCase): + def setUp(self) -> None: + self.factory = AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory() + + def test_is_subclass(self): + self.assertTrue( + issubclass( + AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + ) + ) + + def test_build_table_name(self): + self.assertEqual("broker_subscriber_processed_messages", self.factory.build_table_name()) + + def test_build_create_table(self): + operation = self.factory.build_create_table() + self.assertIsInstance(operation, ComposedDatabaseOperation) + self.assertEqual(2, len(operation.operations)) + for sub in operation.operations: + self.assertIsInstance(sub, AiopgDatabaseOperation) + + def test_build_insert_row(self): + operation = self.factory.build_insert_row("foo", uuid4()) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + +if __name__ == "__main__": + unittest.main() From 3036e9228d17f3f30c2fb65d3d109548a4c1f723 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 11:58:37 +0200 Subject: [PATCH 247/324] ISSUE #98 * Increase coverage. * Minor improvements. --- .../repositories/database/factories/abc.py | 3 +- .../aiopg/factories/aggregate/events.py | 42 +++++++--- .../factories/aggregate/snapshots/impl.py | 61 +++++++++----- .../factories/aggregate/snapshots/queries.py | 15 +++- .../aiopg/factories/aggregate/transactions.py | 35 +++++--- .../test_events/test_factory.py | 76 ++++++++++++++++++ .../test_snapshots/test_factory.py | 79 +++++++++++++++++++ .../test_snapshots/test_queries.py | 11 ++- .../test_transactions/test_factory.py | 69 ++++++++++++++++ 9 files changed, 343 insertions(+), 48 deletions(-) create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_factory.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_factory.py create mode 100644 packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_factory.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py index 10866aa5c..288e41b24 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py @@ -2,6 +2,7 @@ ABC, abstractmethod, ) +from collections.abc import Iterable from datetime import ( datetime, ) @@ -35,7 +36,7 @@ def build_create_table(self) -> DatabaseOperation: @abstractmethod def build_submit_row( self, - transaction_uuids: tuple[UUID], + transaction_uuids: Iterable[UUID], uuid: UUID, action: Action, name: str, diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py index 15d2774ff..028b27a35 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py @@ -15,6 +15,7 @@ from psycopg2.sql import ( SQL, Composable, + Identifier, Literal, Placeholder, ) @@ -40,6 +41,13 @@ class AiopgEventDatabaseOperationFactory(EventDatabaseOperationFactory): """Aiopg Event Database Operation Factory class.""" + def build_table_name(self) -> str: + """Get the table name. + + :return: A ``str`` value. + """ + return "aggregate_event" + def build_create_table(self) -> DatabaseOperation: """Build the database operation to create the event table. @@ -68,11 +76,11 @@ def build_create_table(self) -> DatabaseOperation: $$ LANGUAGE plpgsql; """, - lock="aggregate_event", + lock=self.build_table_name(), ), AiopgDatabaseOperation( - """ - CREATE TABLE IF NOT EXISTS aggregate_event ( + f""" + CREATE TABLE IF NOT EXISTS {self.build_table_name()} ( id BIGSERIAL PRIMARY KEY, action ACTION_TYPE NOT NULL, uuid UUID NOT NULL, @@ -84,14 +92,14 @@ def build_create_table(self) -> DatabaseOperation: UNIQUE (uuid, version, transaction_uuid) ); """, - lock="aggregate_event", + lock=self.build_table_name(), ), ] ) def build_submit_row( self, - transaction_uuids: tuple[UUID], + transaction_uuids: Iterable[UUID], uuid: UUID, action: Action, name: str, @@ -118,7 +126,7 @@ def build_submit_row( """ insert_values = SQL( """ - INSERT INTO aggregate_event (id, action, uuid, name, version, data, created_at, transaction_uuid) + INSERT INTO {table_name} (id, action, uuid, name, version, data, created_at, transaction_uuid) VALUES ( default, %(action)s, @@ -151,7 +159,7 @@ def build_submit_row( from_sql, from_parameters = self._build_submit_from(transaction_uuids) - query = insert_values.format(from_parts=from_sql) + query = insert_values.format(from_parts=from_sql, table_name=Identifier(self.build_table_name())) parameters = from_parameters | insert_parameters return AiopgDatabaseOperation(query, parameters, lock) @@ -160,7 +168,7 @@ def _build_submit_from(self, transaction_uuids: Iterable[UUID]) -> tuple[Composa select_transaction = SQL( """ SELECT {index} AS transaction_index, uuid, MAX(version) AS version - FROM aggregate_event + FROM {table_name} WHERE uuid = %(uuid)s AND transaction_uuid = {transaction_uuid} GROUP BY uuid """ @@ -171,7 +179,13 @@ def _build_submit_from(self, transaction_uuids: Iterable[UUID]) -> tuple[Composa name = f"transaction_uuid_{index}" parameters[name] = transaction_uuid - from_query_parts.append(select_transaction.format(index=Literal(index), transaction_uuid=Placeholder(name))) + from_query_parts.append( + select_transaction.format( + index=Literal(index), + transaction_uuid=Placeholder(name), + table_name=Identifier(self.build_table_name()), + ), + ) query = SQL(" UNION ALL ").join(from_query_parts) return query, parameters @@ -193,7 +207,7 @@ def build_select_rows( id_ge: Optional[int] = None, transaction_uuid: Optional[UUID] = None, transaction_uuid_ne: Optional[UUID] = None, - transaction_uuid_in: Optional[tuple[UUID, ...]] = None, + transaction_uuid_in: Optional[Iterable[UUID, ...]] = None, **kwargs, ) -> DatabaseOperation: """Build the database operation to select rows. @@ -216,10 +230,12 @@ def build_select_rows( :return: A ``DatabaseOperation`` instance. """ + if transaction_uuid_in is not None: + transaction_uuid_in = tuple(transaction_uuid_in) - _select_all = """ + _select_all = f""" SELECT uuid, name, version, data, id, action, created_at, transaction_uuid - FROM aggregate_event + FROM {self.build_table_name()} """ conditions = list() @@ -284,7 +300,7 @@ def build_select_max_id(self) -> DatabaseOperation: :return: A ``DatabaseOperation`` instance. """ - return AiopgDatabaseOperation("SELECT MAX(id) FROM aggregate_event;".strip()) + return AiopgDatabaseOperation(f"SELECT MAX(id) FROM {self.build_table_name()};".strip()) AiopgDatabaseClient.register_factory(EventDatabaseOperationFactory, AiopgEventDatabaseOperationFactory) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py index e3abf38d4..46562711a 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py @@ -39,6 +39,20 @@ class AiopgSnapshotDatabaseOperationFactory(SnapshotDatabaseOperationFactory): """Aiopg Snapshot Database Operation Factory class.""" + def build_table_name(self) -> str: + """Get the table name. + + :return: A ``str`` value. + """ + return "snapshot" + + def build_offset_table_name(self) -> str: + """Get the offset table name. + + :return: A ``str`` value. + """ + return "snapshot_aux_offset" + def build_create_table(self) -> DatabaseOperation: """Build the database operation to create the snapshot table. @@ -51,8 +65,8 @@ def build_create_table(self) -> DatabaseOperation: lock="uuid-ossp", ), AiopgDatabaseOperation( - """ - CREATE TABLE IF NOT EXISTS snapshot ( + f""" + CREATE TABLE IF NOT EXISTS {self.build_table_name()} ( uuid UUID NOT NULL, name TEXT NOT NULL, version INT NOT NULL, @@ -64,17 +78,17 @@ def build_create_table(self) -> DatabaseOperation: PRIMARY KEY (uuid, transaction_uuid) ); """, - lock="snapshot", + lock=self.build_table_name(), ), AiopgDatabaseOperation( - """ - CREATE TABLE IF NOT EXISTS snapshot_aux_offset ( + f""" + CREATE TABLE IF NOT EXISTS {self.build_offset_table_name()} ( id bool PRIMARY KEY DEFAULT TRUE, value BIGINT NOT NULL, CONSTRAINT id_uni CHECK (id) ); """, - lock="snapshot_aux_offset", + lock=self.build_offset_table_name(), ), ] ) @@ -86,8 +100,8 @@ def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> Dat :return: A ``DatabaseOperation`` instance. """ return AiopgDatabaseOperation( - """ - DELETE FROM snapshot + f""" + DELETE FROM {self.build_table_name()} WHERE transaction_uuid IN %(transaction_uuids)s; """, {"transaction_uuids": tuple(transaction_uuids)}, @@ -118,8 +132,10 @@ def build_insert( """ return AiopgDatabaseOperation( - """ - INSERT INTO snapshot (uuid, name, version, schema, data, created_at, updated_at, transaction_uuid) + f""" + INSERT INTO {self.build_table_name()} ( + uuid, name, version, schema, data, created_at, updated_at, transaction_uuid + ) VALUES ( %(uuid)s, %(name)s, @@ -153,7 +169,7 @@ def build_query( condition: _Condition, ordering: Optional[_Ordering], limit: Optional[int], - transaction_uuids: tuple[UUID, ...], + transaction_uuids: Iterable[UUID], exclude_deleted: bool, ) -> DatabaseOperation: """Build the query database operation. @@ -172,7 +188,13 @@ def build_query( :return: A ``DatabaseOperation`` instance. """ builder = AiopgSnapshotQueryDatabaseOperationBuilder( - name, condition, ordering, limit, transaction_uuids, exclude_deleted + name=name, + condition=condition, + ordering=ordering, + limit=limit, + transaction_uuids=transaction_uuids, + exclude_deleted=exclude_deleted, + table_name=self.build_table_name(), ) query, parameters = builder.build() @@ -185,14 +207,17 @@ def build_store_offset(self, value: int) -> DatabaseOperation: :return: A ``DatabaseOperation`` instance. """ return AiopgDatabaseOperation( - """ - INSERT INTO snapshot_aux_offset (id, value) + f""" + INSERT INTO {self.build_offset_table_name()} (id, value) VALUES (TRUE, %(value)s) ON CONFLICT (id) - DO UPDATE SET value = GREATEST(%(value)s, (SELECT value FROM snapshot_aux_offset WHERE id = TRUE)); + DO UPDATE SET value = GREATEST( + %(value)s, + (SELECT value FROM {self.build_offset_table_name()} WHERE id = TRUE) + ); """.strip(), {"value": value}, - lock="insert_snapshot_aux_offset", + lock=f"insert_{self.build_offset_table_name()}", ) def build_get_offset(self) -> DatabaseOperation: @@ -201,9 +226,9 @@ def build_get_offset(self) -> DatabaseOperation: :return: A ``DatabaseOperation`` instance. """ return AiopgDatabaseOperation( - """ + f""" SELECT value - FROM snapshot_aux_offset + FROM {self.build_offset_table_name()} WHERE id = TRUE; """ ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/queries.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/queries.py index 07f3fae58..ddbd559e9 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/queries.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/queries.py @@ -4,6 +4,7 @@ from typing import ( Any, + Iterable, Optional, ) from uuid import ( @@ -64,15 +65,21 @@ def __init__( condition: _Condition, ordering: Optional[_Ordering] = None, limit: Optional[int] = None, - transaction_uuids: tuple[UUID, ...] = (NULL_UUID,), + transaction_uuids: Iterable[UUID, ...] = (NULL_UUID,), exclude_deleted: bool = False, + table_name: Optional[str] = None, ): + if not isinstance(transaction_uuids, tuple): + transaction_uuids = tuple(transaction_uuids) + if table_name is None: + table_name = "snapshot" self.name = name self.condition = condition self.ordering = ordering self.limit = limit self.transaction_uuids = transaction_uuids self.exclude_deleted = exclude_deleted + self.table_name = table_name self._parameters = None def build(self) -> tuple[Composable, dict[str, Any]]: @@ -116,7 +123,9 @@ def _build_select_from(self) -> Composable: self._parameters[name] = transaction_uuid from_query_parts.append( - self._SELECT_TRANSACTION_CHUNK.format(index=Literal(index), transaction_uuid=Placeholder(name)) + self._SELECT_TRANSACTION_CHUNK.format( + index=Literal(index), transaction_uuid=Placeholder(name), table_name=Identifier(self.table_name) + ) ) from_query = SQL(" UNION ALL ").join(from_query_parts) @@ -264,7 +273,7 @@ def generate_random_str() -> str: _SELECT_TRANSACTION_CHUNK = SQL( "SELECT {index} AS transaction_index, * " - "FROM snapshot " + "FROM {table_name} " "WHERE name = %(name)s AND transaction_uuid = {transaction_uuid} " ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py index 78a70baf0..5bdef0139 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py @@ -2,6 +2,9 @@ annotations, ) +from collections.abc import ( + Iterable, +) from datetime import ( datetime, ) @@ -33,6 +36,13 @@ class AiopgTransactionDatabaseOperationFactory(TransactionDatabaseOperationFactory): """Aiopg Transaction Database Operation Factory class.""" + def build_table_name(self) -> str: + """Get the table name. + + :return: A ``str`` value. + """ + return "aggregate_transaction" + def build_create_table(self) -> DatabaseOperation: """Build the database operation to create the snapshot table. @@ -64,11 +74,11 @@ def build_create_table(self) -> DatabaseOperation: $$ LANGUAGE plpgsql; """, - lock="aggregate_transaction_enum", + lock="transaction_status", ), AiopgDatabaseOperation( - """ - CREATE TABLE IF NOT EXISTS aggregate_transaction ( + f""" + CREATE TABLE IF NOT EXISTS {self.build_table_name()} ( uuid UUID PRIMARY KEY, destination_uuid UUID NOT NULL, status TRANSACTION_STATUS NOT NULL, @@ -76,7 +86,7 @@ def build_create_table(self) -> DatabaseOperation: updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW() ); """, - lock="aggregate_transaction", + lock=self.build_table_name(), ), ] ) @@ -107,8 +117,8 @@ def build_submit_row( } return AiopgDatabaseOperation( - """ - INSERT INTO aggregate_transaction AS t (uuid, destination_uuid, status, event_offset) + f""" + INSERT INTO {self.build_table_name()} AS t (uuid, destination_uuid, status, event_offset) VALUES (%(uuid)s, %(destination_uuid)s, %(status)s, %(event_offset)s) ON CONFLICT (uuid) DO @@ -130,10 +140,10 @@ def build_select_rows( self, uuid: Optional[UUID] = None, uuid_ne: Optional[UUID] = None, - uuid_in: Optional[tuple[UUID]] = None, + uuid_in: Optional[Iterable[UUID]] = None, destination_uuid: Optional[UUID] = None, status: Optional[str] = None, - status_in: Optional[tuple[str]] = None, + status_in: Optional[Iterable[str]] = None, event_offset: Optional[int] = None, event_offset_lt: Optional[int] = None, event_offset_gt: Optional[int] = None, @@ -167,6 +177,11 @@ def build_select_rows( :param kwargs: Additional named arguments. :return: A ``DatabaseOperation`` instance. """ + if uuid_in is not None: + uuid_in = tuple(uuid_in) + + if status_in is not None: + status_in = tuple(status_in) conditions = list() @@ -203,9 +218,9 @@ def build_select_rows( if updated_at_ge is not None: conditions.append("updated_at >= %(updated_at_ge)s") - select_all = """ + select_all = f""" SELECT uuid, status, event_offset, destination_uuid, updated_at - FROM aggregate_transaction + FROM {self.build_table_name()} """.strip() if not conditions: diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_factory.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_factory.py new file mode 100644 index 000000000..99796c166 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_factory.py @@ -0,0 +1,76 @@ +import unittest +from uuid import ( + uuid4, +) + +from minos.aggregate import ( + Action, + EventDatabaseOperationFactory, +) +from minos.common import ( + ComposedDatabaseOperation, + current_datetime, +) +from minos.plugins.aiopg import ( + AiopgDatabaseOperation, + AiopgEventDatabaseOperationFactory, +) + + +class TestAiopgEventDatabaseOperationFactory(unittest.TestCase): + def setUp(self) -> None: + self.factory = AiopgEventDatabaseOperationFactory() + + def test_is_subclass(self): + self.assertTrue(issubclass(AiopgEventDatabaseOperationFactory, EventDatabaseOperationFactory)) + + def test_build_table_name(self): + self.assertEqual("aggregate_event", self.factory.build_table_name()) + + def test_build_create_table(self): + operation = self.factory.build_create_table() + self.assertIsInstance(operation, ComposedDatabaseOperation) + self.assertEqual(3, len(operation.operations)) + for sub in operation.operations: + self.assertIsInstance(sub, AiopgDatabaseOperation) + + def test_build_submit_row(self): + operation = self.factory.build_submit_row( + transaction_uuids=[uuid4(), uuid4()], + uuid=uuid4(), + action=Action.CREATE, + name="Foo", + version=3, + data=bytes(), + created_at=current_datetime(), + transaction_uuid=uuid4(), + lock="foo", + ) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_select_rows(self): + operation = self.factory.build_select_rows( + uuid=uuid4(), + name="Foo", + version=423453, + version_lt=234, + version_gt=342, + version_le=5433, + version_ge=897, + id=234, + id_lt=34, + id_gt=543, + id_ge=123, + transaction_uuid=uuid4(), + transaction_uuid_ne=uuid4(), + transaction_uuid_in=[uuid4(), uuid4(), uuid4()], + ) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_select_max_id(self): + operation = self.factory.build_select_max_id() + self.assertIsInstance(operation, AiopgDatabaseOperation) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_factory.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_factory.py new file mode 100644 index 000000000..e9df20754 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_factory.py @@ -0,0 +1,79 @@ +import unittest +from uuid import ( + uuid4, +) + +from minos.aggregate import ( + Condition, + Ordering, + SnapshotDatabaseOperationFactory, +) +from minos.common import ( + ComposedDatabaseOperation, + current_datetime, +) +from minos.plugins.aiopg import ( + AiopgDatabaseOperation, + AiopgSnapshotDatabaseOperationFactory, +) + + +class TestAiopgSnapshotDatabaseOperationFactory(unittest.TestCase): + def setUp(self) -> None: + self.factory = AiopgSnapshotDatabaseOperationFactory() + + def test_is_subclass(self): + self.assertTrue(issubclass(AiopgSnapshotDatabaseOperationFactory, SnapshotDatabaseOperationFactory)) + + def test_build_table_name(self): + self.assertEqual("snapshot", self.factory.build_table_name()) + + def test_build_offset_table_name(self): + self.assertEqual("snapshot_aux_offset", self.factory.build_offset_table_name()) + + def test_build_create_table(self): + operation = self.factory.build_create_table() + self.assertIsInstance(operation, ComposedDatabaseOperation) + self.assertEqual(3, len(operation.operations)) + for sub in operation.operations: + self.assertIsInstance(sub, AiopgDatabaseOperation) + + def test_build_delete_by_transactions(self): + operation = self.factory.build_delete_by_transactions({uuid4(), uuid4()}) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_insert(self): + operation = self.factory.build_insert( + uuid=uuid4(), + name="Foo", + version=34243, + schema=bytes(), + data={"foo": "bar"}, + created_at=current_datetime(), + updated_at=current_datetime(), + transaction_uuid=uuid4(), + ) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_query(self): + operation = self.factory.build_query( + name="Foo", + condition=Condition.EQUAL("foo", "bar"), + ordering=Ordering.ASC("foobar"), + limit=2342, + transaction_uuids=[uuid4(), uuid4()], + exclude_deleted=True, + ) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_store_offset(self): + operation = self.factory.build_store_offset(56) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_get_offset(self): + operation = self.factory.build_get_offset() + self.assertIsInstance(operation, AiopgDatabaseOperation) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_queries.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_queries.py index 5fa02ca31..4f5a9f351 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_queries.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_queries.py @@ -12,6 +12,7 @@ ) from psycopg2.sql import ( SQL, + Identifier, Literal, Placeholder, ) @@ -43,7 +44,7 @@ def setUp(self) -> None: } self.base_select = AiopgSnapshotQueryDatabaseOperationBuilder._SELECT_ENTRIES_QUERY.format( from_parts=AiopgSnapshotQueryDatabaseOperationBuilder._SELECT_TRANSACTION_CHUNK.format( - index=Literal(1), transaction_uuid=Placeholder("transaction_uuid_1") + index=Literal(1), transaction_uuid=Placeholder("transaction_uuid_1"), table_name=Identifier("snapshot") ) ) @@ -99,10 +100,14 @@ async def test_build_with_transactions(self): from_parts=SQL(" UNION ALL ").join( [ AiopgSnapshotQueryDatabaseOperationBuilder._SELECT_TRANSACTION_CHUNK.format( - index=Literal(1), transaction_uuid=Placeholder("transaction_uuid_1") + index=Literal(1), + transaction_uuid=Placeholder("transaction_uuid_1"), + table_name=Identifier("snapshot"), ), AiopgSnapshotQueryDatabaseOperationBuilder._SELECT_TRANSACTION_CHUNK.format( - index=Literal(2), transaction_uuid=Placeholder("transaction_uuid_2") + index=Literal(2), + transaction_uuid=Placeholder("transaction_uuid_2"), + table_name=Identifier("snapshot"), ), ] ) diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_factory.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_factory.py new file mode 100644 index 000000000..91e72ac33 --- /dev/null +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_factory.py @@ -0,0 +1,69 @@ +import unittest +from uuid import ( + uuid4, +) + +from minos.aggregate import ( + TransactionDatabaseOperationFactory, + TransactionStatus, +) +from minos.common import ( + ComposedDatabaseOperation, + current_datetime, +) +from minos.plugins.aiopg import ( + AiopgDatabaseOperation, + AiopgTransactionDatabaseOperationFactory, +) + + +class TestAiopgTransactionDatabaseOperationFactory(unittest.TestCase): + def setUp(self) -> None: + self.factory = AiopgTransactionDatabaseOperationFactory() + + def test_is_subclass(self): + self.assertTrue(issubclass(AiopgTransactionDatabaseOperationFactory, TransactionDatabaseOperationFactory)) + + def test_build_table_name(self): + self.assertEqual("aggregate_transaction", self.factory.build_table_name()) + + def test_build_create_table(self): + operation = self.factory.build_create_table() + self.assertIsInstance(operation, ComposedDatabaseOperation) + self.assertEqual(3, len(operation.operations)) + for sub in operation.operations: + self.assertIsInstance(sub, AiopgDatabaseOperation) + + def test_build_submit_row(self): + operation = self.factory.build_submit_row( + uuid=uuid4(), + destination_uuid=uuid4(), + status=TransactionStatus.COMMITTED, + event_offset=234234, + ) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_select_rows(self): + operation = self.factory.build_select_rows( + uuid=uuid4(), + uuid_ne=uuid4(), + uuid_in={uuid4(), uuid4()}, + destination_uuid=uuid4(), + status=TransactionStatus.COMMITTED, + status_in={TransactionStatus.REJECTED, TransactionStatus.RESERVED}, + event_offset=234, + event_offset_lt=24342, + event_offset_gt=3424, + event_offset_le=2342, + event_offset_ge=234342, + updated_at=current_datetime(), + updated_at_lt=current_datetime(), + updated_at_gt=current_datetime(), + updated_at_le=current_datetime(), + updated_at_ge=current_datetime(), + ) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + +if __name__ == "__main__": + unittest.main() From e532da924f261fd52688787810ec9173ecb7da7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 12:06:25 +0200 Subject: [PATCH 248/324] ISSUE #98 * Rename methods. --- .../repositories/database/factories/abc.py | 8 ++--- .../events/repositories/database/impl.py | 8 ++--- .../repositories/database/factories/abc.py | 10 +++---- .../snapshots/repositories/database/impl.py | 10 +++---- .../repositories/database/factories/abc.py | 6 ++-- .../repositories/database/impl.py | 6 ++-- .../tests/utils.py | 24 +++++++-------- .../queues/database/factories/abc.py | 12 ++++---- .../collections/queues/database/impl.py | 14 ++++----- .../duplicates/database/factories/abc.py | 4 +-- .../validators/duplicates/database/impl.py | 4 +-- .../queued/queues/database/factories/abc.py | 4 +-- .../queued/queues/database/impl.py | 4 +-- .../tests/utils.py | 20 ++++++------- .../aiopg/factories/aggregate/events.py | 8 ++--- .../factories/aggregate/snapshots/impl.py | 10 +++---- .../aiopg/factories/aggregate/transactions.py | 6 ++-- .../factories/networks/collections/queues.py | 12 ++++---- .../factories/networks/subscribers/queues.py | 6 ++-- .../networks/subscribers/validators.py | 4 +-- .../test_events/test_factory.py | 16 +++++----- .../test_snapshots/test_factory.py | 20 ++++++------- .../test_transactions/test_factory.py | 12 ++++---- .../test_collections/test_queues.py | 29 +++++++++++++++++++ .../test_publishers/test_queues.py | 29 ------------------- .../test_subscribers/test_queues.py | 8 ++--- .../test_subscribers/test_validators.py | 8 ++--- 27 files changed, 150 insertions(+), 152 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py index 288e41b24..77ffa5b3b 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py @@ -27,14 +27,14 @@ class EventDatabaseOperationFactory(DatabaseOperationFactory, ABC): """Event Database Operation Factory base class.""" @abstractmethod - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """Build the database operation to create the event table. :return: A ``DatabaseOperation`` instance.s """ @abstractmethod - def build_submit_row( + def build_submit( self, transaction_uuids: Iterable[UUID], uuid: UUID, @@ -64,7 +64,7 @@ def build_submit_row( # noinspection PyShadowingBuiltins @abstractmethod - def build_select_rows( + def build_query( self, uuid: Optional[UUID] = None, name: Optional[str] = None, @@ -105,7 +105,7 @@ def build_select_rows( """ @abstractmethod - def build_select_max_id(self) -> DatabaseOperation: + def build_query_offset(self) -> DatabaseOperation: """Build the database operation to get the maximum identifier. :return: A ``DatabaseOperation`` instance. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index 3f45751f1..cb4da8335 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -41,7 +41,7 @@ async def _setup(self): :return: This method does not return anything. """ - operation = self.operation_factory.build_create_table() + operation = self.operation_factory.build_create() await self.submit_query(operation) async def _submit(self, entry: EventEntry, **kwargs) -> EventEntry: @@ -69,15 +69,15 @@ async def _build_submit_operation(self, entry: EventEntry) -> DatabaseOperation: else: transaction_uuids = (NULL_UUID,) - return self.operation_factory.build_submit_row(transaction_uuids=transaction_uuids, **entry.as_raw(), lock=lock) + return self.operation_factory.build_submit(transaction_uuids=transaction_uuids, **entry.as_raw(), lock=lock) async def _select(self, streaming_mode: Optional[bool] = None, **kwargs) -> AsyncIterator[EventEntry]: - operation = self.operation_factory.build_select_rows(**kwargs) + operation = self.operation_factory.build_query(**kwargs) async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): yield EventEntry(*row) @property async def _offset(self) -> int: - operation = self.operation_factory.build_select_max_id() + operation = self.operation_factory.build_query_offset() row = await self.submit_query_and_fetchone(operation) return row[0] or 0 diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/abc.py index 13d173cb2..12b32dfdb 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/abc.py @@ -31,14 +31,14 @@ class SnapshotDatabaseOperationFactory(DatabaseOperationFactory, ABC): """Snapshot Database Operation Factory class.""" @abstractmethod - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """Build the database operation to create the snapshot table. :return: A ``DatabaseOperation`` instance. """ @abstractmethod - def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: + def build_delete(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: """Build the database operation to delete rows by transaction identifiers. :param transaction_uuids: The transaction identifiers. @@ -46,7 +46,7 @@ def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> Dat """ @abstractmethod - def build_insert( + def build_submit( self, uuid: UUID, name: str, @@ -97,7 +97,7 @@ def build_query( """ @abstractmethod - def build_store_offset(self, value: int) -> DatabaseOperation: + def build_submit_offset(self, value: int) -> DatabaseOperation: """Build the database operation to store the offset. :param value: The value to be stored as the new offset. @@ -105,7 +105,7 @@ def build_store_offset(self, value: int) -> DatabaseOperation: """ @abstractmethod - def build_get_offset(self) -> DatabaseOperation: + def build_query_offset(self) -> DatabaseOperation: """Build the database operation to get the current offset. :return: A ``DatabaseOperation`` instance. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py index 084fc8cac..02abfd656 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py @@ -88,7 +88,7 @@ def _from_config(cls, config: Config, **kwargs) -> DatabaseSnapshotRepository: return cls(database_key=None, **kwargs) async def _setup(self) -> None: - operation = self.operation_factory.build_create_table() + operation = self.operation_factory.build_create() await self.submit_query(operation) async def _destroy(self) -> None: @@ -149,7 +149,7 @@ async def _synchronize(self, **kwargs) -> None: await self._store_offset(offset) async def _load_offset(self) -> int: - operation = self.operation_factory.build_get_offset() + operation = self.operation_factory.build_query_offset() # noinspection PyBroadException try: raw = await self.submit_query_and_fetchone(operation) @@ -158,7 +158,7 @@ async def _load_offset(self) -> int: return 0 async def _store_offset(self, offset: int) -> None: - operation = self.operation_factory.build_store_offset(offset) + operation = self.operation_factory.build_submit_offset(offset) await self.submit_query(operation) async def _dispatch_one(self, event_entry: EventEntry, **kwargs) -> SnapshotEntry: @@ -211,7 +211,7 @@ async def _select_one_instance(self, name: str, uuid: UUID, **kwargs) -> RootEnt return snapshot_entry.build(**kwargs) async def _submit_entry(self, snapshot_entry: SnapshotEntry) -> SnapshotEntry: - operation = self.operation_factory.build_insert(**snapshot_entry.as_raw()) + operation = self.operation_factory.build_submit(**snapshot_entry.as_raw()) response = await self.submit_query_and_fetchone(operation) snapshot_entry.created_at, snapshot_entry.updated_at = response @@ -224,5 +224,5 @@ async def _clean_transactions(self, offset: int, **kwargs) -> None: ) transaction_uuids = {transaction.uuid async for transaction in iterable} if len(transaction_uuids): - operation = self.operation_factory.build_delete_by_transactions(transaction_uuids) + operation = self.operation_factory.build_delete(transaction_uuids) await self.submit_query(operation) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py index 18b2443a0..5171be2b6 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py @@ -32,14 +32,14 @@ class TransactionDatabaseOperationFactory(DatabaseOperationFactory, ABC): """Transaction Database Operation Factory base class.""" @abstractmethod - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """Build the database operation to create the snapshot table. :return: A ``DatabaseOperation`` instance. """ @abstractmethod - def build_submit_row( + def build_submit( self, uuid: UUID, destination_uuid: UUID, status: TransactionStatus, event_offset: int, **kwargs ) -> DatabaseOperation: """Build the database operation to submit a row. @@ -53,7 +53,7 @@ def build_submit_row( """ @abstractmethod - def build_select_rows( + def build_query( self, uuid: Optional[UUID] = None, uuid_ne: Optional[UUID] = None, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index d41b511b1..0074e6925 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -34,11 +34,11 @@ def _from_config(cls, config: Config, **kwargs) -> DatabaseTransactionRepository return super()._from_config(config, database_key=None, **kwargs) async def _setup(self): - operation = self.operation_factory.build_create_table() + operation = self.operation_factory.build_create() await self.submit_query(operation) async def _submit(self, transaction: TransactionEntry) -> TransactionEntry: - operation = self.operation_factory.build_submit_row( + operation = self.operation_factory.build_submit( **transaction.as_raw(), ) @@ -52,6 +52,6 @@ async def _submit(self, transaction: TransactionEntry) -> TransactionEntry: return transaction async def _select(self, streaming_mode: Optional[bool] = None, **kwargs) -> AsyncIterator[TransactionEntry]: - operation = self.operation_factory.build_select_rows(**kwargs) + operation = self.operation_factory.build_query(**kwargs) async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): yield TransactionEntry(*row, transaction_repository=self) diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 69001e084..0e717f00e 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -166,17 +166,17 @@ def build_delete(self, database: str) -> DatabaseOperation: class FakeTransactionDatabaseOperationFactory(TransactionDatabaseOperationFactory): """For testing purposes.""" - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """For testing purposes.""" return FakeDatabaseOperation("create") - def build_submit_row( + def build_submit( self, uuid: UUID, destination_uuid: UUID, status: TransactionStatus, event_offset: int, **kwargs ) -> DatabaseOperation: """For testing purposes.""" return FakeDatabaseOperation("submit") - def build_select_rows( + def build_query( self, uuid: Optional[UUID] = None, uuid_ne: Optional[UUID] = None, @@ -206,11 +206,11 @@ def build_select_rows( class FakeEventDatabaseOperationFactory(EventDatabaseOperationFactory): """For testing purposes.""" - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """For testing purposes.""" return FakeDatabaseOperation("create") - def build_submit_row( + def build_submit( self, transaction_uuids: tuple[UUID], uuid: UUID, @@ -226,7 +226,7 @@ def build_submit_row( """For testing purposes.""" return FakeDatabaseOperation("submit") - def build_select_rows( + def build_query( self, uuid: Optional[UUID] = None, name: Optional[str] = None, @@ -248,7 +248,7 @@ def build_select_rows( """For testing purposes.""" return FakeDatabaseOperation("select_rows") - def build_select_max_id(self) -> DatabaseOperation: + def build_query_offset(self) -> DatabaseOperation: """For testing purposes.""" return FakeDatabaseOperation("select_max_id") @@ -259,15 +259,15 @@ def build_select_max_id(self) -> DatabaseOperation: class FakeSnapshotDatabaseOperationFactory(SnapshotDatabaseOperationFactory): """For testing purposes.""" - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """For testing purposes.""" return FakeDatabaseOperation("create") - def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: + def build_delete(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: """For testing purposes.""" return FakeDatabaseOperation("delete") - def build_insert( + def build_submit( self, uuid: UUID, name: str, @@ -293,11 +293,11 @@ def build_query( """For testing purposes.""" return FakeDatabaseOperation("query") - def build_store_offset(self, value: int) -> DatabaseOperation: + def build_submit_offset(self, value: int) -> DatabaseOperation: """For testing purposes.""" return FakeDatabaseOperation("store_offset") - def build_get_offset(self) -> DatabaseOperation: + def build_query_offset(self) -> DatabaseOperation: """For testing purposes.""" return FakeDatabaseOperation("get_offset") diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py index 2a6847aa4..e7bf53f67 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py @@ -17,21 +17,21 @@ class BrokerQueueDatabaseOperationFactory(DatabaseOperationFactory, ABC): """Broker Queue Database Operation Factory class.""" @abstractmethod - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """Build the "create table" query. :return: A ``SQL`` instance. """ @abstractmethod - def build_update_not_processed(self, id_: int) -> DatabaseOperation: + def build_mark_processed(self, id_: int) -> DatabaseOperation: """Build the "update not processed" query. :return: A ``SQL`` instance. """ @abstractmethod - def build_delete_processed(self, id_: int) -> DatabaseOperation: + def build_delete(self, id_: int) -> DatabaseOperation: """Build the "delete processed" query. :return: A ``SQL`` instance. @@ -45,21 +45,21 @@ def build_mark_processing(self, ids: Iterable[int]) -> DatabaseOperation: """ @abstractmethod - def build_count_not_processed(self, retry: int, *args, **kwargs) -> DatabaseOperation: + def build_count(self, retry: int, *args, **kwargs) -> DatabaseOperation: """Build the "count not processed" query. :return: """ @abstractmethod - def build_insert(self, topic: str, data: bytes) -> DatabaseOperation: + def build_submit(self, topic: str, data: bytes) -> DatabaseOperation: """Build the "insert" query. :return: A ``SQL`` instance. """ @abstractmethod - def build_select_not_processed(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: + def build_query(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: """Build the "select not processed" query. :return: A ``SQL`` instance. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index cdfe1e328..61f475b81 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -117,7 +117,7 @@ async def _destroy(self) -> None: await super()._destroy() async def _create_table(self) -> None: - operation = self.operation_factory.build_create_table() + operation = self.operation_factory.build_create() await self.submit_query(operation) async def _start_run(self) -> None: @@ -139,12 +139,12 @@ async def _flush_queue(self): entry = self._queue.get_nowait() except QueueEmpty: break - operation = self.operation_factory.build_update_not_processed(entry.id_) + operation = self.operation_factory.build_mark_processed(entry.id_) await self.submit_query(operation) self._queue.task_done() async def _enqueue(self, message: BrokerMessage) -> None: - operation = self.operation_factory.build_insert(message.topic, message.avro_bytes) + operation = self.operation_factory.build_submit(message.topic, message.avro_bytes) await self.submit_query(operation) await self._notify_enqueued(message) @@ -163,11 +163,11 @@ async def _dequeue(self) -> BrokerMessage: logger.warning( f"There was a problem while trying to deserialize the entry with {entry.id_!r} id: {exc}" ) - operation = self.operation_factory.build_update_not_processed(entry.id_) + operation = self.operation_factory.build_mark_processed(entry.id_) await self.submit_query(operation) continue - operation = self.operation_factory.build_delete_processed(entry.id_) + operation = self.operation_factory.build_delete(entry.id_) await self.submit_query(operation) return message finally: @@ -192,7 +192,7 @@ async def _wait_enqueued(self) -> None: async def _get_count(self) -> int: # noinspection PyTypeChecker - operation = self.operation_factory.build_count_not_processed(self.retry) + operation = self.operation_factory.build_count(self.retry) row = await self.submit_query_and_fetchone(operation) count = row[0] return count @@ -214,7 +214,7 @@ async def _dequeue_batch(self) -> None: await self._queue.put(entry) async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - operation = self.operation_factory.build_select_not_processed(self._retry, self._records) + operation = self.operation_factory.build_query(self._retry, self._records) await client.execute(operation) return [row async for row in client.fetch_all()] diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py index d00bb82e8..d32234805 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py @@ -17,14 +17,14 @@ class BrokerSubscriberDuplicateValidatorDatabaseOperationFactory(DatabaseOperati """Broker Subscriber Duplicate Validator Database Operation Factory class.""" @abstractmethod - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """Build the "create table" query. :return: A ``SQL`` instance. """ @abstractmethod - def build_insert_row(self, topic: str, uuid: UUID) -> DatabaseOperation: + def build_submit(self, topic: str, uuid: UUID) -> DatabaseOperation: """Build the "insert row" query. :return: A ``SQL`` instance. diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py index d767f639f..70d48d148 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py @@ -32,11 +32,11 @@ async def _setup(self) -> None: await self._create_table() async def _create_table(self) -> None: - operation = self.operation_factory.build_create_table() + operation = self.operation_factory.build_create() await self.submit_query(operation) async def _is_unique(self, topic: str, uuid: UUID) -> bool: - operation = self.operation_factory.build_insert_row(topic, uuid) + operation = self.operation_factory.build_submit(topic, uuid) try: await self.submit_query(operation) return True diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py index 7bd4c1e4f..cfa68708b 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py @@ -20,7 +20,7 @@ class BrokerSubscriberQueueDatabaseOperationFactory(BrokerQueueDatabaseOperation """Broker Subscriber Queue Database Operation Factory class.""" @abstractmethod - def build_count_not_processed( + def build_count( self, retry: int, topics: Iterable[str] = tuple(), @@ -33,7 +33,7 @@ def build_count_not_processed( """ @abstractmethod - def build_select_not_processed( + def build_query( self, retry: int, records: int, diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py index c39ba4879..5c3a570cd 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py @@ -33,13 +33,13 @@ class DatabaseBrokerSubscriberQueue( async def _get_count(self) -> int: # noinspection PyTypeChecker - operation = self.operation_factory.build_count_not_processed(self._retry, self.topics) + operation = self.operation_factory.build_count(self._retry, self.topics) row = await self.submit_query_and_fetchone(operation) count = row[0] return count async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - operation = self.operation_factory.build_select_not_processed(self._retry, self._records, self.topics) + operation = self.operation_factory.build_query(self._retry, self._records, self.topics) await client.execute(operation) return [row async for row in client.fetch_all()] diff --git a/packages/core/minos-microservice-networks/tests/utils.py b/packages/core/minos-microservice-networks/tests/utils.py index 018df1a55..ec55352bb 100644 --- a/packages/core/minos-microservice-networks/tests/utils.py +++ b/packages/core/minos-microservice-networks/tests/utils.py @@ -127,15 +127,15 @@ def build_delete(self, database: str) -> DatabaseOperation: class FakeBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory): """For testing purposes.""" - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("create_queue_table") - def build_update_not_processed(self, id_: int) -> DatabaseOperation: + def build_mark_processed(self, id_: int) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("update_not_processed") - def build_delete_processed(self, id_: int) -> DatabaseOperation: + def build_delete(self, id_: int) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("delete_processed") @@ -143,15 +143,15 @@ def build_mark_processing(self, ids: Iterable[int]) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("mark_processing") - def build_count_not_processed(self, retry: int, *args, **kwargs) -> DatabaseOperation: + def build_count(self, retry: int, *args, **kwargs) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("count_not_processed") - def build_insert(self, topic: str, data: bytes) -> DatabaseOperation: + def build_submit(self, topic: str, data: bytes) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("insert") - def build_select_not_processed(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: + def build_query(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("select_not_processed") @@ -172,13 +172,13 @@ class FakeBrokerSubscriberQueueDatabaseOperationFactory( ): """For testing purposes""" - def build_count_not_processed( + def build_count( self, retry: int, topics: Iterable[str] = tuple(), *args, **kwargs ) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("count_not_processed") - def build_select_not_processed( + def build_query( self, retry: int, records: int, topics: Iterable[str] = tuple(), *args, **kwargs ) -> DatabaseOperation: """For testing purposes""" @@ -195,11 +195,11 @@ class FakeBrokerSubscriberDuplicateValidatorDatabaseOperationFactory( ): """For testing purposes""" - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("create_table") - def build_insert_row(self, topic: str, uuid: UUID) -> DatabaseOperation: + def build_submit(self, topic: str, uuid: UUID) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("insert_row") diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py index 028b27a35..44b4b4f21 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py @@ -48,7 +48,7 @@ def build_table_name(self) -> str: """ return "aggregate_event" - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """Build the database operation to create the event table. :return: A ``DatabaseOperation`` instance.s @@ -97,7 +97,7 @@ def build_create_table(self) -> DatabaseOperation: ] ) - def build_submit_row( + def build_submit( self, transaction_uuids: Iterable[UUID], uuid: UUID, @@ -191,7 +191,7 @@ def _build_submit_from(self, transaction_uuids: Iterable[UUID]) -> tuple[Composa return query, parameters # noinspection PyShadowingBuiltins - def build_select_rows( + def build_query( self, uuid: Optional[UUID] = None, name: Optional[str] = None, @@ -295,7 +295,7 @@ def build_select_rows( }, ) - def build_select_max_id(self) -> DatabaseOperation: + def build_query_offset(self) -> DatabaseOperation: """Build the database operation to get the maximum identifier. :return: A ``DatabaseOperation`` instance. diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py index 46562711a..fd78ac5f4 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py @@ -53,7 +53,7 @@ def build_offset_table_name(self) -> str: """ return "snapshot_aux_offset" - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """Build the database operation to create the snapshot table. :return: A ``DatabaseOperation`` instance. @@ -93,7 +93,7 @@ def build_create_table(self) -> DatabaseOperation: ] ) - def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: + def build_delete(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: """Build the database operation to delete rows by transaction identifiers. :param transaction_uuids: The transaction identifiers. @@ -107,7 +107,7 @@ def build_delete_by_transactions(self, transaction_uuids: Iterable[UUID]) -> Dat {"transaction_uuids": tuple(transaction_uuids)}, ) - def build_insert( + def build_submit( self, uuid: UUID, name: str, @@ -200,7 +200,7 @@ def build_query( return AiopgDatabaseOperation(query, parameters) - def build_store_offset(self, value: int) -> DatabaseOperation: + def build_submit_offset(self, value: int) -> DatabaseOperation: """Build the database operation to store the offset. :param value: The value to be stored as the new offset. @@ -220,7 +220,7 @@ def build_store_offset(self, value: int) -> DatabaseOperation: lock=f"insert_{self.build_offset_table_name()}", ) - def build_get_offset(self) -> DatabaseOperation: + def build_query_offset(self) -> DatabaseOperation: """Build the database operation to get the current offset. :return: A ``DatabaseOperation`` instance. diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py index 5bdef0139..6d42e7087 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py @@ -43,7 +43,7 @@ def build_table_name(self) -> str: """ return "aggregate_transaction" - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """Build the database operation to create the snapshot table. :return: A ``DatabaseOperation`` instance. @@ -91,7 +91,7 @@ def build_create_table(self) -> DatabaseOperation: ] ) - def build_submit_row( + def build_submit( self, uuid: UUID, destination_uuid: UUID, @@ -136,7 +136,7 @@ def build_submit_row( lock=uuid.int & (1 << 32) - 1, ) - def build_select_rows( + def build_query( self, uuid: Optional[UUID] = None, uuid_ne: Optional[UUID] = None, diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queues.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queues.py index 135620b36..339453e68 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queues.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/collections/queues.py @@ -34,7 +34,7 @@ def build_table_name(self) -> str: """ raise NotImplementedError - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """Build the "create table" query. :return: A ``SQL`` instance. @@ -53,7 +53,7 @@ def build_create_table(self) -> DatabaseOperation: lock=self.build_table_name(), ) - def build_update_not_processed(self, id_: int) -> DatabaseOperation: + def build_mark_processed(self, id_: int) -> DatabaseOperation: """Build the "update not processed" query. :return: A ``SQL`` instance. @@ -66,7 +66,7 @@ def build_update_not_processed(self, id_: int) -> DatabaseOperation: {"id": id_}, ) - def build_delete_processed(self, id_: int) -> DatabaseOperation: + def build_delete(self, id_: int) -> DatabaseOperation: """Build the "delete processed" query. :return: A ``SQL`` instance. @@ -86,7 +86,7 @@ def build_mark_processing(self, ids: Iterable[int]) -> DatabaseOperation: {"ids": tuple(ids)}, ) - def build_count_not_processed(self, retry: int, *args, **kwargs) -> DatabaseOperation: + def build_count(self, retry: int, *args, **kwargs) -> DatabaseOperation: """Build the "count not processed" query. :return: @@ -99,7 +99,7 @@ def build_count_not_processed(self, retry: int, *args, **kwargs) -> DatabaseOper {"retry": retry}, ) - def build_insert(self, topic: str, data: bytes) -> DatabaseOperation: + def build_submit(self, topic: str, data: bytes) -> DatabaseOperation: """Build the "insert" query. :return: A ``SQL`` instance. @@ -109,7 +109,7 @@ def build_insert(self, topic: str, data: bytes) -> DatabaseOperation: {"topic": topic, "data": data}, ) - def build_select_not_processed(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: + def build_query(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: """Build the "select not processed" query. :return: A ``SQL`` instance. diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queues.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queues.py index de335d995..598496c08 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queues.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queues.py @@ -37,9 +37,7 @@ def build_table_name(self) -> str: """ return "broker_subscriber_queue" - def build_count_not_processed( - self, retry: int, topics: Iterable[str] = tuple(), *args, **kwargs - ) -> DatabaseOperation: + def build_count(self, retry: int, topics: Iterable[str] = tuple(), *args, **kwargs) -> DatabaseOperation: """Build the "count not processed" query. :return: @@ -52,7 +50,7 @@ def build_count_not_processed( {"retry": retry, "topics": tuple(topics)}, ) - def build_select_not_processed( + def build_query( self, retry: int, records: int, topics: Iterable[str] = tuple(), *args, **kwargs ) -> DatabaseOperation: """Build the "select not processed" query. diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validators.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validators.py index 6890c7ff4..f44ca85f1 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validators.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validators.py @@ -36,7 +36,7 @@ def build_table_name() -> str: """ return "broker_subscriber_processed_messages" - def build_create_table(self) -> DatabaseOperation: + def build_create(self) -> DatabaseOperation: """Build the "create table" query. :return: A ``SQL`` instance. @@ -61,7 +61,7 @@ def build_create_table(self) -> DatabaseOperation: ] ) - def build_insert_row(self, topic: str, uuid: UUID) -> DatabaseOperation: + def build_submit(self, topic: str, uuid: UUID) -> DatabaseOperation: """Build the "insert row" query. :return: A ``SQL`` instance. diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_factory.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_factory.py index 99796c166..9c33d3906 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_factory.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_events/test_factory.py @@ -27,15 +27,15 @@ def test_is_subclass(self): def test_build_table_name(self): self.assertEqual("aggregate_event", self.factory.build_table_name()) - def test_build_create_table(self): - operation = self.factory.build_create_table() + def test_build_create(self): + operation = self.factory.build_create() self.assertIsInstance(operation, ComposedDatabaseOperation) self.assertEqual(3, len(operation.operations)) for sub in operation.operations: self.assertIsInstance(sub, AiopgDatabaseOperation) - def test_build_submit_row(self): - operation = self.factory.build_submit_row( + def test_build_submit(self): + operation = self.factory.build_submit( transaction_uuids=[uuid4(), uuid4()], uuid=uuid4(), action=Action.CREATE, @@ -48,8 +48,8 @@ def test_build_submit_row(self): ) self.assertIsInstance(operation, AiopgDatabaseOperation) - def test_build_select_rows(self): - operation = self.factory.build_select_rows( + def test_build_query(self): + operation = self.factory.build_query( uuid=uuid4(), name="Foo", version=423453, @@ -67,8 +67,8 @@ def test_build_select_rows(self): ) self.assertIsInstance(operation, AiopgDatabaseOperation) - def test_build_select_max_id(self): - operation = self.factory.build_select_max_id() + def test_build_query_offset(self): + operation = self.factory.build_query_offset() self.assertIsInstance(operation, AiopgDatabaseOperation) diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_factory.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_factory.py index e9df20754..eccd8d2f1 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_factory.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_factory.py @@ -31,19 +31,19 @@ def test_build_table_name(self): def test_build_offset_table_name(self): self.assertEqual("snapshot_aux_offset", self.factory.build_offset_table_name()) - def test_build_create_table(self): - operation = self.factory.build_create_table() + def test_build_create(self): + operation = self.factory.build_create() self.assertIsInstance(operation, ComposedDatabaseOperation) self.assertEqual(3, len(operation.operations)) for sub in operation.operations: self.assertIsInstance(sub, AiopgDatabaseOperation) - def test_build_delete_by_transactions(self): - operation = self.factory.build_delete_by_transactions({uuid4(), uuid4()}) + def test_build_build_delete(self): + operation = self.factory.build_delete({uuid4(), uuid4()}) self.assertIsInstance(operation, AiopgDatabaseOperation) - def test_build_insert(self): - operation = self.factory.build_insert( + def test_build_submit(self): + operation = self.factory.build_submit( uuid=uuid4(), name="Foo", version=34243, @@ -66,12 +66,12 @@ def test_build_query(self): ) self.assertIsInstance(operation, AiopgDatabaseOperation) - def test_build_store_offset(self): - operation = self.factory.build_store_offset(56) + def test_build_submit_offset(self): + operation = self.factory.build_submit_offset(56) self.assertIsInstance(operation, AiopgDatabaseOperation) - def test_build_get_offset(self): - operation = self.factory.build_get_offset() + def test_build_query_offset(self): + operation = self.factory.build_query_offset() self.assertIsInstance(operation, AiopgDatabaseOperation) diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_factory.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_factory.py index 91e72ac33..d6559ae1d 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_factory.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_transactions/test_factory.py @@ -27,15 +27,15 @@ def test_is_subclass(self): def test_build_table_name(self): self.assertEqual("aggregate_transaction", self.factory.build_table_name()) - def test_build_create_table(self): - operation = self.factory.build_create_table() + def test_build_create(self): + operation = self.factory.build_create() self.assertIsInstance(operation, ComposedDatabaseOperation) self.assertEqual(3, len(operation.operations)) for sub in operation.operations: self.assertIsInstance(sub, AiopgDatabaseOperation) - def test_build_submit_row(self): - operation = self.factory.build_submit_row( + def test_build_submit(self): + operation = self.factory.build_submit( uuid=uuid4(), destination_uuid=uuid4(), status=TransactionStatus.COMMITTED, @@ -43,8 +43,8 @@ def test_build_submit_row(self): ) self.assertIsInstance(operation, AiopgDatabaseOperation) - def test_build_select_rows(self): - operation = self.factory.build_select_rows( + def test_build_query(self): + operation = self.factory.build_query( uuid=uuid4(), uuid_ne=uuid4(), uuid_in={uuid4(), uuid4()}, diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/test_queues.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/test_queues.py index 03fed3d90..c90a12de5 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/test_queues.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_collections/test_queues.py @@ -5,6 +5,7 @@ ) from minos.plugins.aiopg import ( AiopgBrokerQueueDatabaseOperationFactory, + AiopgDatabaseOperation, ) @@ -26,6 +27,34 @@ def test_is_subclass(self): def test_build_table_name(self): self.assertEqual("foo", self.factory.build_table_name()) + def test_build_create(self): + operation = self.factory.build_create() + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_mark_processed(self): + operation = self.factory.build_mark_processed(id_=56) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_delete(self): + operation = self.factory.build_delete(id_=56) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_mark_processing(self): + operation = self.factory.build_mark_processing(ids={56, 78}) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_count(self): + operation = self.factory.build_count(retry=3) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_submit(self): + operation = self.factory.build_submit(topic="foo", data=bytes()) + self.assertIsInstance(operation, AiopgDatabaseOperation) + + def test_build_query(self): + operation = self.factory.build_query(retry=3, records=1000) + self.assertIsInstance(operation, AiopgDatabaseOperation) + if __name__ == "__main__": unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py index f9192ad36..b0f90fe21 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_publishers/test_queues.py @@ -6,7 +6,6 @@ from minos.plugins.aiopg import ( AiopgBrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerQueueDatabaseOperationFactory, - AiopgDatabaseOperation, ) @@ -23,34 +22,6 @@ def test_is_subclass(self): def test_build_table_name(self): self.assertEqual("broker_publisher_queue", self.factory.build_table_name()) - def test_build_create_table(self): - operation = self.factory.build_create_table() - self.assertIsInstance(operation, AiopgDatabaseOperation) - - def test_build_update_not_processed(self): - operation = self.factory.build_update_not_processed(id_=56) - self.assertIsInstance(operation, AiopgDatabaseOperation) - - def test_build_delete_processed(self): - operation = self.factory.build_delete_processed(id_=56) - self.assertIsInstance(operation, AiopgDatabaseOperation) - - def test_build_mark_processing(self): - operation = self.factory.build_mark_processing(ids={56, 78}) - self.assertIsInstance(operation, AiopgDatabaseOperation) - - def test_build_count_not_processed(self): - operation = self.factory.build_count_not_processed(retry=3) - self.assertIsInstance(operation, AiopgDatabaseOperation) - - def test_build_insert(self): - operation = self.factory.build_insert(topic="foo", data=bytes()) - self.assertIsInstance(operation, AiopgDatabaseOperation) - - def test_build_select_not_processed(self): - operation = self.factory.build_select_not_processed(retry=3, records=1000) - self.assertIsInstance(operation, AiopgDatabaseOperation) - if __name__ == "__main__": unittest.main() diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py index ec4e2687f..4367230ca 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_queues.py @@ -25,12 +25,12 @@ def test_is_subclass(self): def test_build_table_name(self): self.assertEqual("broker_subscriber_queue", self.factory.build_table_name()) - def test_build_count_not_processed(self): - operation = self.factory.build_count_not_processed(retry=3, topics={"foo", "bar"}) + def test_build_build_count(self): + operation = self.factory.build_count(retry=3, topics={"foo", "bar"}) self.assertIsInstance(operation, AiopgDatabaseOperation) - def test_build_select_not_processed(self): - operation = self.factory.build_select_not_processed(retry=3, records=100, topics={"foo", "bar"}) + def test_build_build_query(self): + operation = self.factory.build_query(retry=3, records=100, topics={"foo", "bar"}) self.assertIsInstance(operation, AiopgDatabaseOperation) diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_validators.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_validators.py index 96dee6a29..f3d20a54f 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_validators.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_networks/test_subscribers/test_validators.py @@ -30,15 +30,15 @@ def test_is_subclass(self): def test_build_table_name(self): self.assertEqual("broker_subscriber_processed_messages", self.factory.build_table_name()) - def test_build_create_table(self): - operation = self.factory.build_create_table() + def test_build_create(self): + operation = self.factory.build_create() self.assertIsInstance(operation, ComposedDatabaseOperation) self.assertEqual(2, len(operation.operations)) for sub in operation.operations: self.assertIsInstance(sub, AiopgDatabaseOperation) - def test_build_insert_row(self): - operation = self.factory.build_insert_row("foo", uuid4()) + def test_build_submit(self): + operation = self.factory.build_submit("foo", uuid4()) self.assertIsInstance(operation, AiopgDatabaseOperation) From 8cf6238ebd0c39336c7ebeb8c95151a34601d72d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 12:13:21 +0200 Subject: [PATCH 249/324] ISSUE #98 * Rename `register_factory` as `set_factory`. --- .../minos-microservice-aggregate/tests/utils.py | 10 +++++----- .../minos/common/database/clients/abc.py | 2 +- .../test_database/test_clients/test_abc.py | 14 +++++++------- .../core/minos-microservice-common/tests/utils.py | 4 ++-- .../core/minos-microservice-cqrs/tests/utils.py | 4 ++-- .../minos-microservice-networks/tests/utils.py | 10 +++++----- .../plugins/aiopg/factories/aggregate/events.py | 2 +- .../aiopg/factories/aggregate/snapshots/impl.py | 2 +- .../aiopg/factories/aggregate/transactions.py | 2 +- .../minos/plugins/aiopg/factories/common/locks.py | 2 +- .../plugins/aiopg/factories/common/managemens.py | 2 +- .../aiopg/factories/networks/publishers/queues.py | 2 +- .../aiopg/factories/networks/subscribers/queues.py | 2 +- .../factories/networks/subscribers/validators.py | 2 +- 14 files changed, 30 insertions(+), 30 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 0e717f00e..75a814da9 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -145,7 +145,7 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: return FakeDatabaseOperation("release") -FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) +FakeDatabaseClient.set_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): @@ -160,7 +160,7 @@ def build_delete(self, database: str) -> DatabaseOperation: return FakeDatabaseOperation("delete") -FakeDatabaseClient.register_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) +FakeDatabaseClient.set_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) class FakeTransactionDatabaseOperationFactory(TransactionDatabaseOperationFactory): @@ -200,7 +200,7 @@ def build_query( return FakeDatabaseOperation("select") -FakeDatabaseClient.register_factory(TransactionDatabaseOperationFactory, FakeTransactionDatabaseOperationFactory) +FakeDatabaseClient.set_factory(TransactionDatabaseOperationFactory, FakeTransactionDatabaseOperationFactory) class FakeEventDatabaseOperationFactory(EventDatabaseOperationFactory): @@ -253,7 +253,7 @@ def build_query_offset(self) -> DatabaseOperation: return FakeDatabaseOperation("select_max_id") -FakeDatabaseClient.register_factory(EventDatabaseOperationFactory, FakeEventDatabaseOperationFactory) +FakeDatabaseClient.set_factory(EventDatabaseOperationFactory, FakeEventDatabaseOperationFactory) class FakeSnapshotDatabaseOperationFactory(SnapshotDatabaseOperationFactory): @@ -302,7 +302,7 @@ def build_query_offset(self) -> DatabaseOperation: return FakeDatabaseOperation("get_offset") -FakeDatabaseClient.register_factory(SnapshotDatabaseOperationFactory, FakeSnapshotDatabaseOperationFactory) +FakeDatabaseClient.set_factory(SnapshotDatabaseOperationFactory, FakeSnapshotDatabaseOperationFactory) class FakeAsyncIterator: diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 90e95cd33..07a582e4e 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -151,7 +151,7 @@ def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: raise NotImplementedError @classmethod - def register_factory(cls, base: type[DatabaseOperationFactory], impl: type[DatabaseOperationFactory]) -> None: + def set_factory(cls, base: type[DatabaseOperationFactory], impl: type[DatabaseOperationFactory]) -> None: """Register an operation factory implementation for an operation factory interface. :param base: The operation factory interface. diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index 9398a5c36..49b9b6a2e 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -69,7 +69,7 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: return _DatabaseOperation() -_DatabaseClient.register_factory(LockDatabaseOperationFactory, _LockDatabaseOperationFactory) +_DatabaseClient.set_factory(LockDatabaseOperationFactory, _LockDatabaseOperationFactory) class TestDatabaseClient(CommonTestCase): @@ -97,7 +97,7 @@ async def test_is_valid(self): self.assertEqual([call(), call()], mock.call_args_list) async def test_lock(self): - _DatabaseClient.register_factory(LockDatabaseOperationFactory, _LockDatabaseOperationFactory) + _DatabaseClient.set_factory(LockDatabaseOperationFactory, _LockDatabaseOperationFactory) op1 = _DatabaseOperation(lock="foo") client = _DatabaseClient() self.assertIsNone(client.lock) @@ -197,25 +197,25 @@ async def test_fetch_one(self): self.assertEqual([call()], mock.call_args_list) - def test_register_factory(self): + def test_set_factory(self): expected = { LockDatabaseOperationFactory: _LockDatabaseOperationFactory, _DatabaseOperationFactory: _DatabaseOperationFactoryImpl, } try: - _DatabaseClient.register_factory(_DatabaseOperationFactory, _DatabaseOperationFactoryImpl) + _DatabaseClient.set_factory(_DatabaseOperationFactory, _DatabaseOperationFactoryImpl) self.assertEqual(expected, _DatabaseClient._factories) finally: _DatabaseClient._factories.pop(_DatabaseOperationFactory) - def test_register_factory_raises(self): + def test_set_factory_raises(self): with self.assertRaises(ValueError): # noinspection PyTypeChecker - _DatabaseClient.register_factory(object, DatabaseOperationFactory) + _DatabaseClient.set_factory(object, DatabaseOperationFactory) with self.assertRaises(ValueError): - _DatabaseClient.register_factory(_DatabaseOperationFactoryImpl, _DatabaseOperationFactory) + _DatabaseClient.set_factory(_DatabaseOperationFactoryImpl, _DatabaseOperationFactory) def test_get_factory(self): self.assertIsInstance( diff --git a/packages/core/minos-microservice-common/tests/utils.py b/packages/core/minos-microservice-common/tests/utils.py index 43701b670..ffe03e14d 100644 --- a/packages/core/minos-microservice-common/tests/utils.py +++ b/packages/core/minos-microservice-common/tests/utils.py @@ -119,7 +119,7 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: return FakeDatabaseOperation("release") -FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) +FakeDatabaseClient.set_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): @@ -134,7 +134,7 @@ def build_delete(self, database: str) -> DatabaseOperation: return FakeDatabaseOperation("delete") -FakeDatabaseClient.register_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) +FakeDatabaseClient.set_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) class FakeDatabaseOperation(DatabaseOperation): diff --git a/packages/core/minos-microservice-cqrs/tests/utils.py b/packages/core/minos-microservice-cqrs/tests/utils.py index 8cbef68fa..c93e7cced 100644 --- a/packages/core/minos-microservice-cqrs/tests/utils.py +++ b/packages/core/minos-microservice-cqrs/tests/utils.py @@ -118,7 +118,7 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: return FakeDatabaseOperation("release") -FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) +FakeDatabaseClient.set_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): @@ -133,4 +133,4 @@ def build_delete(self, database: str) -> DatabaseOperation: return FakeDatabaseOperation("delete") -FakeDatabaseClient.register_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) +FakeDatabaseClient.set_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-networks/tests/utils.py b/packages/core/minos-microservice-networks/tests/utils.py index ec55352bb..730092ec4 100644 --- a/packages/core/minos-microservice-networks/tests/utils.py +++ b/packages/core/minos-microservice-networks/tests/utils.py @@ -106,7 +106,7 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: return FakeDatabaseOperation("release") -FakeDatabaseClient.register_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) +FakeDatabaseClient.set_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): @@ -121,7 +121,7 @@ def build_delete(self, database: str) -> DatabaseOperation: return FakeDatabaseOperation("delete") -FakeDatabaseClient.register_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) +FakeDatabaseClient.set_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) class FakeBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory): @@ -162,7 +162,7 @@ class FakeBrokerPublisherQueueDatabaseOperationFactory( """For testing purposes""" -FakeDatabaseClient.register_factory( +FakeDatabaseClient.set_factory( BrokerPublisherQueueDatabaseOperationFactory, FakeBrokerPublisherQueueDatabaseOperationFactory ) @@ -185,7 +185,7 @@ def build_query( return FakeDatabaseOperation("select_not_processed") -FakeDatabaseClient.register_factory( +FakeDatabaseClient.set_factory( BrokerSubscriberQueueDatabaseOperationFactory, FakeBrokerSubscriberQueueDatabaseOperationFactory ) @@ -204,7 +204,7 @@ def build_submit(self, topic: str, uuid: UUID) -> DatabaseOperation: return FakeDatabaseOperation("insert_row") -FakeDatabaseClient.register_factory( +FakeDatabaseClient.set_factory( BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, FakeBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py index 44b4b4f21..701578bb2 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/events.py @@ -303,4 +303,4 @@ def build_query_offset(self) -> DatabaseOperation: return AiopgDatabaseOperation(f"SELECT MAX(id) FROM {self.build_table_name()};".strip()) -AiopgDatabaseClient.register_factory(EventDatabaseOperationFactory, AiopgEventDatabaseOperationFactory) +AiopgDatabaseClient.set_factory(EventDatabaseOperationFactory, AiopgEventDatabaseOperationFactory) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py index fd78ac5f4..acc3f9171 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/snapshots/impl.py @@ -234,4 +234,4 @@ def build_query_offset(self) -> DatabaseOperation: ) -AiopgDatabaseClient.register_factory(SnapshotDatabaseOperationFactory, AiopgSnapshotDatabaseOperationFactory) +AiopgDatabaseClient.set_factory(SnapshotDatabaseOperationFactory, AiopgSnapshotDatabaseOperationFactory) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py index 6d42e7087..d98ecfe08 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/aggregate/transactions.py @@ -249,4 +249,4 @@ def build_query( ) -AiopgDatabaseClient.register_factory(TransactionDatabaseOperationFactory, AiopgTransactionDatabaseOperationFactory) +AiopgDatabaseClient.set_factory(TransactionDatabaseOperationFactory, AiopgTransactionDatabaseOperationFactory) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/locks.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/locks.py index 3fee1913b..db23a3249 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/locks.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/locks.py @@ -31,4 +31,4 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: return AiopgDatabaseOperation("select pg_advisory_unlock(%(hashed_key)s)", {"hashed_key": hashed_key}) -AiopgDatabaseClient.register_factory(LockDatabaseOperationFactory, AiopgLockDatabaseOperationFactory) +AiopgDatabaseClient.set_factory(LockDatabaseOperationFactory, AiopgLockDatabaseOperationFactory) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/managemens.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/managemens.py index 119d2bad6..814dec80f 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/managemens.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/common/managemens.py @@ -32,4 +32,4 @@ def build_delete(self, database: str) -> DatabaseOperation: return AiopgDatabaseOperation(f"DROP DATABASE IF EXISTS {database};") -AiopgDatabaseClient.register_factory(ManagementDatabaseOperationFactory, AiopgManagementDatabaseOperationFactory) +AiopgDatabaseClient.set_factory(ManagementDatabaseOperationFactory, AiopgManagementDatabaseOperationFactory) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queues.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queues.py index 77a6dfa92..428ec65fb 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queues.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/publishers/queues.py @@ -23,6 +23,6 @@ def build_table_name(self) -> str: return "broker_publisher_queue" -AiopgDatabaseClient.register_factory( +AiopgDatabaseClient.set_factory( BrokerPublisherQueueDatabaseOperationFactory, AiopgBrokerPublisherQueueDatabaseOperationFactory ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queues.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queues.py index 598496c08..878aa6e70 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queues.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/queues.py @@ -70,7 +70,7 @@ def build_query( ) -AiopgDatabaseClient.register_factory( +AiopgDatabaseClient.set_factory( BrokerSubscriberQueueDatabaseOperationFactory, AiopgBrokerSubscriberQueueDatabaseOperationFactory, ) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validators.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validators.py index f44ca85f1..350897eea 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validators.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/factories/networks/subscribers/validators.py @@ -75,7 +75,7 @@ def build_submit(self, topic: str, uuid: UUID) -> DatabaseOperation: ) -AiopgDatabaseClient.register_factory( +AiopgDatabaseClient.set_factory( BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, ) From d62c26a1d777c7ae0df57c1e1696a6c00703b6c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 12:51:30 +0200 Subject: [PATCH 250/324] ISSUE #98 * Reformat code. --- .../aggregate/events/repositories/database/factories/abc.py | 4 +++- packages/core/minos-microservice-networks/tests/utils.py | 4 +--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py index 77ffa5b3b..80068df56 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py @@ -2,7 +2,9 @@ ABC, abstractmethod, ) -from collections.abc import Iterable +from collections.abc import ( + Iterable, +) from datetime import ( datetime, ) diff --git a/packages/core/minos-microservice-networks/tests/utils.py b/packages/core/minos-microservice-networks/tests/utils.py index 730092ec4..3b7b4d21b 100644 --- a/packages/core/minos-microservice-networks/tests/utils.py +++ b/packages/core/minos-microservice-networks/tests/utils.py @@ -172,9 +172,7 @@ class FakeBrokerSubscriberQueueDatabaseOperationFactory( ): """For testing purposes""" - def build_count( - self, retry: int, topics: Iterable[str] = tuple(), *args, **kwargs - ) -> DatabaseOperation: + def build_count(self, retry: int, topics: Iterable[str] = tuple(), *args, **kwargs) -> DatabaseOperation: """For testing purposes""" return FakeDatabaseOperation("count_not_processed") From 906b937fbd6da417e1f63b7382de3f1d0eac188d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 16:01:38 +0200 Subject: [PATCH 251/324] ISSUE #98 * Add `ProgrammingException`. * Rename `UnableToConnectException` as `ConnectionException`. --- .../snapshots/repositories/database/impl.py | 7 ++- .../repositories/database/impl.py | 3 +- .../test_repositories/test_database.py | 5 +- .../test_repositories/test_database.py | 57 ++++++++++--------- .../minos/common/__init__.py | 3 +- .../minos/common/database/__init__.py | 3 +- .../minos/common/database/clients/__init__.py | 3 +- .../minos/common/database/clients/abc.py | 8 ++- .../common/database/clients/exceptions.py | 6 +- .../minos/common/database/pools.py | 4 +- .../test_database/test_clients/test_abc.py | 9 +++ .../test_common/test_database/test_pools.py | 4 +- .../minos/plugins/aiopg/clients.py | 14 +++-- .../tests/test_aiopg/test_clients.py | 10 +++- .../test_snapshots/test_repository.py | 2 +- 15 files changed, 88 insertions(+), 50 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py index 02abfd656..9d4ecd1fa 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py @@ -19,6 +19,7 @@ DatabaseMixin, Inject, NotProvidedException, + ProgrammingException, import_module, ) @@ -152,10 +153,10 @@ async def _load_offset(self) -> int: operation = self.operation_factory.build_query_offset() # noinspection PyBroadException try: - raw = await self.submit_query_and_fetchone(operation) - return raw[0] - except Exception: + row = await self.submit_query_and_fetchone(operation) + except ProgrammingException: return 0 + return row[0] async def _store_offset(self, offset: int) -> None: operation = self.operation_factory.build_submit_offset(offset) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index 0074e6925..f1be223b0 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -10,6 +10,7 @@ from minos.common import ( Config, DatabaseMixin, + ProgrammingException, ) from ....exceptions import ( @@ -44,7 +45,7 @@ async def _submit(self, transaction: TransactionEntry) -> TransactionEntry: try: updated_at = await self.submit_query_and_fetchone(operation) - except StopAsyncIteration: + except ProgrammingException: raise TransactionRepositoryConflictException( f"{transaction!r} status is invalid respect to the previous one." ) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py index 5a3209948..2c71a647f 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py @@ -22,6 +22,7 @@ from minos.common import ( DatabaseClient, NotProvidedException, + ProgrammingException, classname, current_datetime, ) @@ -58,7 +59,7 @@ async def synchronize(self): DatabaseClient, "fetch_one", side_effect=[ - StopAsyncIteration, + ProgrammingException(""), (current_datetime(), current_datetime()), (current_datetime(), current_datetime()), (current_datetime(), current_datetime()), @@ -232,7 +233,7 @@ async def test_dispatch_ignore_previous_version(self): DatabaseClient, "fetch_one", side_effect=[ - StopAsyncIteration, + ProgrammingException(""), (current_datetime(), current_datetime()), (current_datetime(), current_datetime()), (9999,), diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py index addcdfc4c..f7900acff 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_transactions/test_repositories/test_database.py @@ -6,7 +6,6 @@ from minos.aggregate import ( DatabaseTransactionRepository, TransactionRepository, - TransactionRepositoryConflictException, TransactionStatus, ) from minos.aggregate.testing import ( @@ -14,6 +13,7 @@ ) from minos.common import ( DatabaseClient, + ProgrammingException, current_datetime, ) from tests.utils import ( @@ -48,10 +48,10 @@ async def test_submit_pending_raises(self): "fetch_one", side_effect=[ (current_datetime(),), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), ], ): await super().test_submit_pending_raises() @@ -62,10 +62,10 @@ async def test_submit_reserving_raises(self): "fetch_one", side_effect=[ (current_datetime(),), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), ], ): await super().test_submit_reserving_raises() @@ -76,9 +76,9 @@ async def test_submit_reserved_raises(self): "fetch_one", side_effect=[ (current_datetime(),), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), ], ): await super().test_submit_reserved_raises() @@ -89,12 +89,12 @@ async def test_submit_committing_raises(self): "fetch_one", side_effect=[ (current_datetime(),), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), ], ): await super().test_submit_committing_raises() @@ -105,9 +105,12 @@ async def test_submit_committed_raises(self): "fetch_one", side_effect=[ (current_datetime(),), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), ], ): await super().test_submit_committed_raises() @@ -118,12 +121,12 @@ async def test_submit_rejected_raises(self): "fetch_one", side_effect=[ (current_datetime(),), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), - TransactionRepositoryConflictException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), + ProgrammingException(""), ], ): await super().test_submit_rejected_raises() diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 8bb9b1da2..408ca17a6 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -15,6 +15,7 @@ ) from .database import ( ComposedDatabaseOperation, + ConnectionException, DatabaseClient, DatabaseClientBuilder, DatabaseClientException, @@ -27,7 +28,7 @@ IntegrityException, LockDatabaseOperationFactory, ManagementDatabaseOperationFactory, - UnableToConnectException, + ProgrammingException, ) from .datetime import ( NULL_DATETIME, diff --git a/packages/core/minos-microservice-common/minos/common/database/__init__.py b/packages/core/minos-microservice-common/minos/common/database/__init__.py index 811be8e95..30f604571 100644 --- a/packages/core/minos-microservice-common/minos/common/database/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/__init__.py @@ -1,9 +1,10 @@ from .clients import ( + ConnectionException, DatabaseClient, DatabaseClientBuilder, DatabaseClientException, IntegrityException, - UnableToConnectException, + ProgrammingException, ) from .locks import ( DatabaseLock, diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py index 87f91189d..928f11271 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/__init__.py @@ -3,7 +3,8 @@ DatabaseClientBuilder, ) from .exceptions import ( + ConnectionException, DatabaseClientException, IntegrityException, - UnableToConnectException, + ProgrammingException, ) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index 07a582e4e..dc1f9e010 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -32,6 +32,9 @@ DatabaseOperation, DatabaseOperationFactory, ) +from .exceptions import ( + ProgrammingException, +) if TYPE_CHECKING: from ..locks import ( @@ -137,7 +140,10 @@ async def fetch_one(self) -> Any: :return: This method does not return anything. """ - return await self.fetch_all().__anext__() + try: + return await self.fetch_all().__anext__() + except StopAsyncIteration: + raise ProgrammingException("There are not any value to be fetched.") def fetch_all(self) -> AsyncIterator[Any]: """Fetch all values with an asynchronous iterator. diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/exceptions.py b/packages/core/minos-microservice-common/minos/common/database/clients/exceptions.py index d638a738c..f135f74bf 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/exceptions.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/exceptions.py @@ -7,9 +7,13 @@ class DatabaseClientException(MinosException): """Base exception for database client.""" -class UnableToConnectException(DatabaseClientException): +class ConnectionException(DatabaseClientException): """Exception to be raised when database client is not able to connect to the database.""" class IntegrityException(DatabaseClientException): """Exception to be raised when an integrity check is not satisfied.""" + + +class ProgrammingException(DatabaseClientException): + """Exception to be raised when an integrity check is not satisfied.""" diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index 16aec0c9b..f12ec25c8 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -26,9 +26,9 @@ Pool, ) from .clients import ( + ConnectionException, DatabaseClient, DatabaseClientBuilder, - UnableToConnectException, ) from .locks import ( DatabaseLock, @@ -66,7 +66,7 @@ async def _create_instance(self) -> Optional[DatabaseClient]: try: await instance.setup() - except UnableToConnectException: + except ConnectionException: await sleep(0.1) return None diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index 49b9b6a2e..e7ee8f393 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -22,6 +22,7 @@ DatabaseOperation, DatabaseOperationFactory, LockDatabaseOperationFactory, + ProgrammingException, ) from tests.utils import ( CommonTestCase, @@ -197,6 +198,14 @@ async def test_fetch_one(self): self.assertEqual([call()], mock.call_args_list) + async def test_fetch_one_raises(self): + mock = MagicMock(return_value=FakeAsyncIterator([])) + client = _DatabaseClient() + client._fetch_all = mock + + with self.assertRaises(ProgrammingException): + await client.fetch_one() + def test_set_factory(self): expected = { LockDatabaseOperationFactory: _LockDatabaseOperationFactory, diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index 93cebff72..28dcde22f 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -5,12 +5,12 @@ from minos.common import ( Config, + ConnectionException, DatabaseClient, DatabaseClientBuilder, DatabaseClientPool, DatabaseLock, DatabaseLockPool, - UnableToConnectException, classname, ) from minos.common.testing import ( @@ -78,7 +78,7 @@ async def test_acquire_with_reset(self): self.assertEqual(1, reset_mock.call_count) async def test_acquire_with_raises(self): - with patch.object(FakeDatabaseClient, "setup", side_effect=[UnableToConnectException(""), None]): + with patch.object(FakeDatabaseClient, "setup", side_effect=[ConnectionException(""), None]): async with self.pool.acquire() as client: self.assertIsInstance(client, FakeDatabaseClient) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py index 001e30d2e..825c6b364 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py @@ -18,12 +18,14 @@ from psycopg2 import ( IntegrityError, OperationalError, + ProgrammingError, ) from minos.common import ( + ConnectionException, DatabaseClient, IntegrityException, - UnableToConnectException, + ProgrammingException, ) from .operations import ( @@ -85,7 +87,7 @@ async def _create_connection(self): except OperationalError as exc: msg = f"There was an {exc!r} while trying to get a database connection." logger.warning(msg) - raise UnableToConnectException(msg) + raise ConnectionException(msg) logger.debug(f"Created {self.database!r} database connection identified by {id(self._connection)}!") @@ -113,9 +115,11 @@ async def _reset(self, **kwargs) -> None: # noinspection PyUnusedLocal async def _fetch_all(self) -> AsyncIterator[tuple]: await self._create_cursor() - - async for row in self._cursor: - yield row + try: + async for row in self._cursor: + yield row + except ProgrammingError as exc: + raise ProgrammingException(str(exc)) # noinspection PyUnusedLocal async def _execute(self, operation: AiopgDatabaseOperation) -> None: diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py index 403a094af..efddd6269 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py @@ -16,9 +16,10 @@ ) from minos.common import ( + ConnectionException, DatabaseOperation, IntegrityException, - UnableToConnectException, + ProgrammingException, ) from minos.plugins.aiopg import ( AiopgDatabaseClient, @@ -79,7 +80,7 @@ async def test_connection(self): async def test_connection_raises(self): with patch.object(aiopg, "connect", new_callable=PropertyMock, side_effect=OperationalError): - with self.assertRaises(UnableToConnectException): + with self.assertRaises(ConnectionException): async with AiopgDatabaseClient.from_config(self.config): pass @@ -130,6 +131,11 @@ async def test_fetch_one(self): observed = await client.fetch_one() self.assertIsInstance(observed, tuple) + async def test_fetch_one_raises(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + with self.assertRaises(ProgrammingException): + await client.fetch_one() + async def test_fetch_all(self): async with AiopgDatabaseClient.from_config(self.config) as client: await client.execute(self.operation) diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_repository.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_repository.py index 69ac0c9a6..0181a0845 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_repository.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_repository.py @@ -19,7 +19,7 @@ # noinspection SqlNoDataSourceInspection -class TestDatabaseSnapshotRepositoryWriter(AiopgTestCase, SnapshotRepositoryTestCase): +class TestDatabaseSnapshotRepository(AiopgTestCase, SnapshotRepositoryTestCase): __test__ = True def build_snapshot_repository(self): From 7adb5a10fd6e2544d8294eaf821e26a1c721c7d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 13 Apr 2022 17:26:10 +0200 Subject: [PATCH 252/324] ISSUE #98 * Remove tests code duplication. --- .../minos/aggregate/testing/__init__.py | 9 +- .../aggregate/testing/events/__init__.py | 4 + .../testing/events/repositories/__init__.py | 6 + .../testing/events/repositories/factories.py | 77 ++++++ .../repositories/testcases.py} | 0 .../aggregate/testing/snapshots/__init__.py | 4 + .../snapshots/repositories/__init__.py | 6 + .../snapshots/repositories/factories.py | 78 ++++++ .../repositories/testcases.py} | 136 ++++++----- .../testing/transactions/__init__.py | 4 + .../transactions/repositories/__init__.py | 6 + .../transactions/repositories/factories.py | 62 +++++ .../repositories/testcases.py} | 0 .../test_repositories/test_database.py | 121 +++++---- .../tests/test_config.yml | 6 +- .../tests/utils.py | 231 +----------------- .../minos/common/importlib.py | 15 +- .../minos/common/testing/__init__.py | 10 + .../minos/common/testing/database/__init__.py | 10 + .../minos/common/testing/database/clients.py | 39 +++ .../testing/database/factories/__init__.py | 6 + .../testing/database/factories/locks.py | 25 ++ .../testing/database/factories/managements.py | 25 ++ .../common/testing/database/operations.py | 20 ++ .../{testing.py => testing/testcases.py} | 8 +- .../tests/config/v1.yml | 2 +- .../tests/config/v2.yml | 2 +- .../test_common/test_database/test_locks.py | 12 +- .../test_common/test_database/test_mixins.py | 48 ++-- .../test_common/test_database/test_pools.py | 10 +- .../minos-microservice-common/tests/utils.py | 85 +------ .../tests/test_config.yml | 6 +- .../minos-microservice-cqrs/tests/utils.py | 79 ------ .../minos/networks/testing/__init__.py | 6 + .../networks/testing/brokers/__init__.py | 10 + .../testing/brokers/collections/__init__.py | 3 + .../testing/brokers/collections/queues.py | 46 ++++ .../testing/brokers/publishers/__init__.py | 3 + .../testing/brokers/publishers/queues.py | 21 ++ .../testing/brokers/subscribers/__init__.py | 6 + .../testing/brokers/subscribers/queues.py | 39 +++ .../testing/brokers/subscribers/validators.py | 35 +++ .../tests/test_config.yml | 2 +- .../test_queues/test_database.py | 18 +- .../test_duplicates/test_database.py | 14 +- .../test_queued/test_queues/test_database.py | 14 +- .../tests/utils.py | 167 +------------ .../test_snapshots/test_repository.py | 7 +- 48 files changed, 808 insertions(+), 735 deletions(-) create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/repositories/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/repositories/factories.py rename packages/core/minos-microservice-aggregate/minos/aggregate/testing/{event_repository.py => events/repositories/testcases.py} (100%) create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/factories.py rename packages/core/minos-microservice-aggregate/minos/aggregate/testing/{snapshot_repository.py => snapshots/repositories/testcases.py} (87%) create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/repositories/__init__.py create mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/repositories/factories.py rename packages/core/minos-microservice-aggregate/minos/aggregate/testing/{transaction_repository.py => transactions/repositories/testcases.py} (100%) create mode 100644 packages/core/minos-microservice-common/minos/common/testing/__init__.py create mode 100644 packages/core/minos-microservice-common/minos/common/testing/database/__init__.py create mode 100644 packages/core/minos-microservice-common/minos/common/testing/database/clients.py create mode 100644 packages/core/minos-microservice-common/minos/common/testing/database/factories/__init__.py create mode 100644 packages/core/minos-microservice-common/minos/common/testing/database/factories/locks.py create mode 100644 packages/core/minos-microservice-common/minos/common/testing/database/factories/managements.py create mode 100644 packages/core/minos-microservice-common/minos/common/testing/database/operations.py rename packages/core/minos-microservice-common/minos/common/{testing.py => testing/testcases.py} (97%) create mode 100644 packages/core/minos-microservice-networks/minos/networks/testing/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/testing/brokers/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/testing/brokers/collections/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/testing/brokers/collections/queues.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/testing/brokers/publishers/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/testing/brokers/publishers/queues.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/__init__.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/queues.py create mode 100644 packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/validators.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py index 1ccc48fce..9d205beed 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/__init__.py @@ -1,9 +1,12 @@ -from .event_repository import ( +from .events import ( EventRepositoryTestCase, + MockedEventDatabaseOperationFactory, ) -from .snapshot_repository import ( +from .snapshots import ( + MockedSnapshotDatabaseOperationFactory, SnapshotRepositoryTestCase, ) -from .transaction_repository import ( +from .transactions import ( + MockedTransactionDatabaseOperationFactory, TransactionRepositoryTestCase, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/__init__.py new file mode 100644 index 000000000..33ee0ba5f --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/__init__.py @@ -0,0 +1,4 @@ +from .repositories import ( + EventRepositoryTestCase, + MockedEventDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/repositories/__init__.py new file mode 100644 index 000000000..f8147fc40 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/repositories/__init__.py @@ -0,0 +1,6 @@ +from .factories import ( + MockedEventDatabaseOperationFactory, +) +from .testcases import ( + EventRepositoryTestCase, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/repositories/factories.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/repositories/factories.py new file mode 100644 index 000000000..8bf90cf35 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/repositories/factories.py @@ -0,0 +1,77 @@ +from datetime import ( + datetime, +) +from typing import ( + Optional, +) +from uuid import ( + UUID, +) + +from minos.common import ( + DatabaseOperation, +) +from minos.common.testing import ( + MockedDatabaseClient, + MockedDatabaseOperation, +) + +from ....actions import ( + Action, +) +from ....events import ( + EventDatabaseOperationFactory, +) + + +class MockedEventDatabaseOperationFactory(EventDatabaseOperationFactory): + """For testing purposes.""" + + def build_create(self) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("create") + + def build_submit( + self, + transaction_uuids: tuple[UUID], + uuid: UUID, + action: Action, + name: str, + version: int, + data: bytes, + created_at: datetime, + transaction_uuid: UUID, + lock: Optional[int], + **kwargs, + ) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("submit") + + def build_query( + self, + uuid: Optional[UUID] = None, + name: Optional[str] = None, + version: Optional[int] = None, + version_lt: Optional[int] = None, + version_gt: Optional[int] = None, + version_le: Optional[int] = None, + version_ge: Optional[int] = None, + id: Optional[int] = None, + id_lt: Optional[int] = None, + id_gt: Optional[int] = None, + id_le: Optional[int] = None, + id_ge: Optional[int] = None, + transaction_uuid: Optional[UUID] = None, + transaction_uuid_ne: Optional[UUID] = None, + transaction_uuid_in: Optional[tuple[UUID, ...]] = None, + **kwargs, + ) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("select_rows") + + def build_query_offset(self) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("select_max_id") + + +MockedDatabaseClient.set_factory(EventDatabaseOperationFactory, MockedEventDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/repositories/testcases.py similarity index 100% rename from packages/core/minos-microservice-aggregate/minos/aggregate/testing/event_repository.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/testing/events/repositories/testcases.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/__init__.py new file mode 100644 index 000000000..6395db04a --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/__init__.py @@ -0,0 +1,4 @@ +from .repositories import ( + MockedSnapshotDatabaseOperationFactory, + SnapshotRepositoryTestCase, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/__init__.py new file mode 100644 index 000000000..46b611965 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/__init__.py @@ -0,0 +1,6 @@ +from .factories import ( + MockedSnapshotDatabaseOperationFactory, +) +from .testcases import ( + SnapshotRepositoryTestCase, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/factories.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/factories.py new file mode 100644 index 000000000..183092f8b --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/factories.py @@ -0,0 +1,78 @@ +from collections.abc import ( + Iterable, +) +from datetime import ( + datetime, +) +from typing import ( + Any, + Optional, +) +from uuid import ( + UUID, +) + +from minos.common import ( + DatabaseOperation, +) +from minos.common.testing import ( + MockedDatabaseClient, + MockedDatabaseOperation, +) + +from ....queries import ( + _Condition, + _Ordering, +) +from ....snapshots import ( + SnapshotDatabaseOperationFactory, +) + + +class MockedSnapshotDatabaseOperationFactory(SnapshotDatabaseOperationFactory): + """For testing purposes.""" + + def build_create(self) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("create") + + def build_delete(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("delete") + + def build_submit( + self, + uuid: UUID, + name: str, + version: int, + schema: bytes, + data: dict[str, Any], + created_at: datetime, + updated_at: datetime, + transaction_uuid: UUID, + ) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("insert") + + def build_query( + self, + name: str, + condition: _Condition, + ordering: Optional[_Ordering], + limit: Optional[int], + transaction_uuids: tuple[UUID, ...], + exclude_deleted: bool, + ) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("query") + + def build_submit_offset(self, value: int) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("store_offset") + + def build_query_offset(self) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("get_offset") + + +MockedDatabaseClient.set_factory(SnapshotDatabaseOperationFactory, MockedSnapshotDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/testcases.py similarity index 87% rename from packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/testcases.py index 2a95000df..edf0dc10b 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshot_repository.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/snapshots/repositories/testcases.py @@ -1,3 +1,7 @@ +from __future__ import ( + annotations, +) + from abc import ( ABC, abstractmethod, @@ -41,26 +45,24 @@ ) -class Owner(RootEntity): - """For testing purposes""" - - name: str - surname: str - age: Optional[int] - +class SnapshotRepositoryTestCase(MinosTestCase, ABC): + __test__ = False -class Car(RootEntity): - """For testing purposes""" + snapshot_repository: SnapshotRepository - doors: int - color: str - owner: Optional[Ref[Owner]] + class Owner(RootEntity): + """For testing purposes""" + name: str + surname: str + age: Optional[int] -class SnapshotRepositoryTestCase(MinosTestCase, ABC): - __test__ = False + class Car(RootEntity): + """For testing purposes""" - snapshot_repository: SnapshotRepository + doors: int + color: str + owner: Optional[Ref[SnapshotRepositoryTestCase.Owner]] def setUp(self) -> None: super().setUp() @@ -81,7 +83,7 @@ def build_snapshot_repository(self) -> SnapshotRepository: async def populate(self) -> None: diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) - name: str = classname(Car) + name: str = classname(self.Car) await self.event_repository.create(EventEntry(self.uuid_1, name, 1, diff.avro_bytes)) await self.event_repository.update(EventEntry(self.uuid_1, name, 2, diff.avro_bytes)) @@ -152,15 +154,15 @@ async def test_dispatch(self): # noinspection PyTypeChecker iterable = self.snapshot_repository.find_entries( - Car.classname, Condition.TRUE, Ordering.ASC("updated_at"), exclude_deleted=False + self.Car.classname, Condition.TRUE, Ordering.ASC("updated_at"), exclude_deleted=False ) observed = [v async for v in iterable] # noinspection PyTypeChecker expected = [ - SnapshotEntry(self.uuid_1, Car.classname, 4), + SnapshotEntry(self.uuid_1, self.Car.classname, 4), SnapshotEntry.from_root_entity( - Car( + self.Car( 3, "blue", uuid=self.uuid_2, @@ -170,7 +172,7 @@ async def test_dispatch(self): ) ), SnapshotEntry.from_root_entity( - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -187,7 +189,7 @@ async def test_dispatch_first_transaction(self): # noinspection PyTypeChecker iterable = self.snapshot_repository.find_entries( - Car.classname, + self.Car.classname, Condition.TRUE, Ordering.ASC("updated_at"), exclude_deleted=False, @@ -197,9 +199,9 @@ async def test_dispatch_first_transaction(self): # noinspection PyTypeChecker expected = [ - SnapshotEntry(self.uuid_1, Car.classname, 4), + SnapshotEntry(self.uuid_1, self.Car.classname, 4), SnapshotEntry.from_root_entity( - Car( + self.Car( 3, "blue", uuid=self.uuid_2, @@ -209,7 +211,7 @@ async def test_dispatch_first_transaction(self): ) ), SnapshotEntry.from_root_entity( - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -226,7 +228,7 @@ async def test_dispatch_second_transaction(self): # noinspection PyTypeChecker iterable = self.snapshot_repository.find_entries( - Car.classname, + self.Car.classname, Condition.TRUE, Ordering.ASC("updated_at"), exclude_deleted=False, @@ -236,10 +238,10 @@ async def test_dispatch_second_transaction(self): # noinspection PyTypeChecker expected = [ - SnapshotEntry(self.uuid_1, Car.classname, 4), - SnapshotEntry(self.uuid_2, Car.classname, 4), + SnapshotEntry(self.uuid_1, self.Car.classname, 4), + SnapshotEntry(self.uuid_2, self.Car.classname, 4), SnapshotEntry.from_root_entity( - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -256,7 +258,7 @@ async def test_dispatch_third_transaction(self): # noinspection PyTypeChecker iterable = self.snapshot_repository.find_entries( - Car.classname, + self.Car.classname, Condition.TRUE, Ordering.ASC("updated_at"), exclude_deleted=False, @@ -266,9 +268,9 @@ async def test_dispatch_third_transaction(self): # noinspection PyTypeChecker expected = [ - SnapshotEntry(self.uuid_1, Car.classname, 4), + SnapshotEntry(self.uuid_1, self.Car.classname, 4), SnapshotEntry.from_root_entity( - Car( + self.Car( 3, "blue", uuid=self.uuid_2, @@ -278,7 +280,7 @@ async def test_dispatch_third_transaction(self): ) ), SnapshotEntry.from_root_entity( - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -294,7 +296,7 @@ async def test_dispatch_ignore_previous_version(self): await self.populate() diff = FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]) # noinspection PyTypeChecker - name: str = Car.classname + name: str = self.Car.classname condition = Condition.EQUAL("uuid", self.uuid_1) async def _fn(*args, id_gt: Optional[int] = None, **kwargs): @@ -315,8 +317,8 @@ async def _fn(*args, id_gt: Optional[int] = None, **kwargs): uuid=self.uuid_1, name=name, version=3, - schema=Car.avro_schema, - data=Car(3, "blue", uuid=self.uuid_1, version=1).avro_data, + schema=self.Car.avro_schema, + data=self.Car(3, "blue", uuid=self.uuid_1, version=1).avro_data, created_at=observed[0].created_at, updated_at=observed[0].updated_at, ) @@ -337,7 +339,7 @@ async def test_dispatch_with_offset(self): # noinspection PyTypeChecker entry = EventEntry( uuid=self.uuid_3, - name=Car.classname, + name=self.Car.classname, data=FieldDiffContainer([FieldDiff("doors", int, 3), FieldDiff("color", str, "blue")]).avro_bytes, ) await self.event_repository.create(entry) @@ -361,11 +363,11 @@ async def test_find_by_uuid(self): await self.populate_and_synchronize() condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) - iterable = self.snapshot_repository.find(Car, condition, ordering=Ordering.ASC("updated_at")) + iterable = self.snapshot_repository.find(self.Car, condition, ordering=Ordering.ASC("updated_at")) observed = [v async for v in iterable] expected = [ - Car( + self.Car( 3, "blue", uuid=self.uuid_2, @@ -373,7 +375,7 @@ async def test_find_by_uuid(self): created_at=observed[0].created_at, updated_at=observed[0].updated_at, ), - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -389,7 +391,7 @@ async def test_find_with_transaction(self): condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) iterable = self.snapshot_repository.find( - Car, + self.Car, condition, ordering=Ordering.ASC("updated_at"), transaction=TransactionEntry(self.transaction_1), @@ -397,7 +399,7 @@ async def test_find_with_transaction(self): observed = [v async for v in iterable] expected = [ - Car( + self.Car( 3, "blue", uuid=self.uuid_2, @@ -405,7 +407,7 @@ async def test_find_with_transaction(self): created_at=observed[0].created_at, updated_at=observed[0].updated_at, ), - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -421,7 +423,7 @@ async def test_find_with_transaction_delete(self): condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) iterable = self.snapshot_repository.find( - Car, + self.Car, condition, ordering=Ordering.ASC("updated_at"), transaction=TransactionEntry(self.transaction_2), @@ -429,7 +431,7 @@ async def test_find_with_transaction_delete(self): observed = [v async for v in iterable] expected = [ - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -445,7 +447,7 @@ async def test_find_with_transaction_reverted(self): condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) iterable = self.snapshot_repository.find( - Car, + self.Car, condition, ordering=Ordering.ASC("updated_at"), transaction=TransactionEntry(self.transaction_4), @@ -453,7 +455,7 @@ async def test_find_with_transaction_reverted(self): observed = [v async for v in iterable] expected = [ - Car( + self.Car( 3, "blue", uuid=self.uuid_2, @@ -461,7 +463,7 @@ async def test_find_with_transaction_reverted(self): created_at=observed[0].created_at, updated_at=observed[0].updated_at, ), - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -477,12 +479,12 @@ async def test_find_streaming_true(self): condition = Condition.IN("uuid", [self.uuid_2, self.uuid_3]) iterable = self.snapshot_repository.find( - Car, condition, streaming_mode=True, ordering=Ordering.ASC("updated_at") + self.Car, condition, streaming_mode=True, ordering=Ordering.ASC("updated_at") ) observed = [v async for v in iterable] expected = [ - Car( + self.Car( 3, "blue", uuid=self.uuid_2, @@ -490,7 +492,7 @@ async def test_find_streaming_true(self): created_at=observed[0].created_at, updated_at=observed[0].updated_at, ), - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -506,11 +508,11 @@ async def test_find_with_duplicates(self): uuids = [self.uuid_2, self.uuid_2, self.uuid_3] condition = Condition.IN("uuid", uuids) - iterable = self.snapshot_repository.find(Car, condition, ordering=Ordering.ASC("updated_at")) + iterable = self.snapshot_repository.find(self.Car, condition, ordering=Ordering.ASC("updated_at")) observed = [v async for v in iterable] expected = [ - Car( + self.Car( 3, "blue", uuid=self.uuid_2, @@ -518,7 +520,7 @@ async def test_find_with_duplicates(self): created_at=observed[0].created_at, updated_at=observed[0].updated_at, ), - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -531,16 +533,16 @@ async def test_find_with_duplicates(self): async def test_find_empty(self): await self.populate_and_synchronize() - observed = {v async for v in self.snapshot_repository.find(Car, Condition.FALSE)} + observed = {v async for v in self.snapshot_repository.find(self.Car, Condition.FALSE)} expected = set() self.assertEqual(expected, observed) async def test_get(self): await self.populate_and_synchronize() - observed = await self.snapshot_repository.get(Car, self.uuid_2) + observed = await self.snapshot_repository.get(self.Car, self.uuid_2) - expected = Car( + expected = self.Car( 3, "blue", uuid=self.uuid_2, version=2, created_at=observed.created_at, updated_at=observed.updated_at ) self.assertEqual(expected, observed) @@ -549,10 +551,10 @@ async def test_get_with_transaction(self): await self.populate_and_synchronize() observed = await self.snapshot_repository.get( - Car, self.uuid_2, transaction=TransactionEntry(self.transaction_1) + self.Car, self.uuid_2, transaction=TransactionEntry(self.transaction_1) ) - expected = Car( + expected = self.Car( 3, "blue", uuid=self.uuid_2, version=4, created_at=observed.created_at, updated_at=observed.updated_at ) self.assertEqual(expected, observed) @@ -560,23 +562,23 @@ async def test_get_with_transaction(self): async def test_get_raises(self): await self.populate_and_synchronize() with self.assertRaises(AlreadyDeletedException): - await self.snapshot_repository.get(Car, self.uuid_1) + await self.snapshot_repository.get(self.Car, self.uuid_1) with self.assertRaises(NotFoundException): - await self.snapshot_repository.get(Car, uuid4()) + await self.snapshot_repository.get(self.Car, uuid4()) async def test_get_with_transaction_raises(self): await self.populate_and_synchronize() with self.assertRaises(AlreadyDeletedException): - await self.snapshot_repository.get(Car, self.uuid_2, transaction=TransactionEntry(self.transaction_2)) + await self.snapshot_repository.get(self.Car, self.uuid_2, transaction=TransactionEntry(self.transaction_2)) async def test_find(self): await self.populate_and_synchronize() condition = Condition.EQUAL("color", "blue") - iterable = self.snapshot_repository.find(Car, condition, ordering=Ordering.ASC("updated_at")) + iterable = self.snapshot_repository.find(self.Car, condition, ordering=Ordering.ASC("updated_at")) observed = [v async for v in iterable] expected = [ - Car( + self.Car( 3, "blue", uuid=self.uuid_2, @@ -584,7 +586,7 @@ async def test_find(self): created_at=observed[0].created_at, updated_at=observed[0].updated_at, ), - Car( + self.Car( 3, "blue", uuid=self.uuid_3, @@ -597,11 +599,11 @@ async def test_find(self): async def test_find_all(self): await self.populate_and_synchronize() - iterable = self.snapshot_repository.find(Car, Condition.TRUE, Ordering.ASC("updated_at")) + iterable = self.snapshot_repository.find(self.Car, Condition.TRUE, Ordering.ASC("updated_at")) observed = [v async for v in iterable] expected = [ - Car( + self.Car( 3, "blue", uuid=self.uuid_2, @@ -609,7 +611,7 @@ async def test_find_all(self): created_at=observed[0].created_at, updated_at=observed[0].updated_at, ), - Car( + self.Car( 3, "blue", uuid=self.uuid_3, diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/__init__.py new file mode 100644 index 000000000..08cde5249 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/__init__.py @@ -0,0 +1,4 @@ +from .repositories import ( + MockedTransactionDatabaseOperationFactory, + TransactionRepositoryTestCase, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/repositories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/repositories/__init__.py new file mode 100644 index 000000000..d1a78141e --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/repositories/__init__.py @@ -0,0 +1,6 @@ +from .factories import ( + MockedTransactionDatabaseOperationFactory, +) +from .testcases import ( + TransactionRepositoryTestCase, +) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/repositories/factories.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/repositories/factories.py new file mode 100644 index 000000000..5be8648d4 --- /dev/null +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/repositories/factories.py @@ -0,0 +1,62 @@ +from datetime import ( + datetime, +) +from typing import ( + Optional, +) +from uuid import ( + UUID, +) + +from minos.common import ( + DatabaseOperation, +) +from minos.common.testing import ( + MockedDatabaseClient, + MockedDatabaseOperation, +) + +from ....transactions import ( + TransactionDatabaseOperationFactory, + TransactionStatus, +) + + +class MockedTransactionDatabaseOperationFactory(TransactionDatabaseOperationFactory): + """For testing purposes.""" + + def build_create(self) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("create") + + def build_submit( + self, uuid: UUID, destination_uuid: UUID, status: TransactionStatus, event_offset: int, **kwargs + ) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("submit") + + def build_query( + self, + uuid: Optional[UUID] = None, + uuid_ne: Optional[UUID] = None, + uuid_in: Optional[tuple[UUID]] = None, + destination_uuid: Optional[UUID] = None, + status: Optional[str] = None, + status_in: Optional[tuple[str]] = None, + event_offset: Optional[int] = None, + event_offset_lt: Optional[int] = None, + event_offset_gt: Optional[int] = None, + event_offset_le: Optional[int] = None, + event_offset_ge: Optional[int] = None, + updated_at: Optional[datetime] = None, + updated_at_lt: Optional[datetime] = None, + updated_at_gt: Optional[datetime] = None, + updated_at_le: Optional[datetime] = None, + updated_at_ge: Optional[datetime] = None, + **kwargs, + ) -> DatabaseOperation: + """For testing purposes.""" + return MockedDatabaseOperation("select") + + +MockedDatabaseClient.set_factory(TransactionDatabaseOperationFactory, MockedTransactionDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py b/packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/repositories/testcases.py similarity index 100% rename from packages/core/minos-microservice-aggregate/minos/aggregate/testing/transaction_repository.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/testing/transactions/repositories/testcases.py diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py index 2c71a647f..76eadca7f 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_snapshots/test_repositories/test_database.py @@ -16,9 +16,6 @@ from minos.aggregate.testing import ( SnapshotRepositoryTestCase, ) -from minos.aggregate.testing.snapshot_repository import ( - Car, -) from minos.common import ( DatabaseClient, NotProvidedException, @@ -48,8 +45,8 @@ async def test_is_synced(self): self.event_repository.select = MagicMock(side_effect=[FakeAsyncIterator([1]), FakeAsyncIterator([])]) with patch.object(DatabaseClient, "fetch_one", return_value=(0,)): - self.assertFalse(await self.snapshot_repository.is_synced(Car)) - self.assertTrue(await self.snapshot_repository.is_synced(Car)) + self.assertFalse(await self.snapshot_repository.is_synced(SnapshotRepositoryTestCase.Car)) + self.assertTrue(await self.snapshot_repository.is_synced(SnapshotRepositoryTestCase.Car)) def build_snapshot_repository(self) -> SnapshotRepository: return DatabaseSnapshotRepository.from_config(self.config) @@ -82,7 +79,9 @@ async def synchronize(self): FakeAsyncIterator( [ tuple( - SnapshotEntry.from_root_entity(Car(3, "blue", uuid=self.uuid_1, version=1)) + SnapshotEntry.from_root_entity( + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_1, version=1) + ) .as_raw() .values() ) @@ -100,9 +99,15 @@ async def synchronize(self): async def test_dispatch(self): entries = [ - SnapshotEntry(self.uuid_1, classname(Car), 4, created_at=current_datetime(), updated_at=current_datetime()), + SnapshotEntry( + self.uuid_1, + classname(SnapshotRepositoryTestCase.Car), + 4, + created_at=current_datetime(), + updated_at=current_datetime(), + ), SnapshotEntry.from_root_entity( - Car( + SnapshotRepositoryTestCase.Car( 3, "blue", uuid=self.uuid_2, @@ -112,7 +117,7 @@ async def test_dispatch(self): ) ), SnapshotEntry.from_root_entity( - Car( + SnapshotRepositoryTestCase.Car( 3, "blue", uuid=self.uuid_3, @@ -132,9 +137,15 @@ async def test_dispatch(self): async def test_dispatch_first_transaction(self): entries = [ - SnapshotEntry(self.uuid_1, classname(Car), 4, created_at=current_datetime(), updated_at=current_datetime()), + SnapshotEntry( + self.uuid_1, + classname(SnapshotRepositoryTestCase.Car), + 4, + created_at=current_datetime(), + updated_at=current_datetime(), + ), SnapshotEntry.from_root_entity( - Car( + SnapshotRepositoryTestCase.Car( 3, "blue", uuid=self.uuid_2, @@ -144,7 +155,7 @@ async def test_dispatch_first_transaction(self): ) ), SnapshotEntry.from_root_entity( - Car( + SnapshotRepositoryTestCase.Car( 3, "blue", uuid=self.uuid_3, @@ -164,10 +175,22 @@ async def test_dispatch_first_transaction(self): async def test_dispatch_second_transaction(self): entries = [ - SnapshotEntry(self.uuid_1, classname(Car), 4, created_at=current_datetime(), updated_at=current_datetime()), - SnapshotEntry(self.uuid_2, classname(Car), 4, created_at=current_datetime(), updated_at=current_datetime()), + SnapshotEntry( + self.uuid_1, + classname(SnapshotRepositoryTestCase.Car), + 4, + created_at=current_datetime(), + updated_at=current_datetime(), + ), + SnapshotEntry( + self.uuid_2, + classname(SnapshotRepositoryTestCase.Car), + 4, + created_at=current_datetime(), + updated_at=current_datetime(), + ), SnapshotEntry.from_root_entity( - Car( + SnapshotRepositoryTestCase.Car( 3, "blue", uuid=self.uuid_3, @@ -187,9 +210,15 @@ async def test_dispatch_second_transaction(self): async def test_dispatch_third_transaction(self): entries = [ - SnapshotEntry(self.uuid_1, classname(Car), 4, created_at=current_datetime(), updated_at=current_datetime()), + SnapshotEntry( + self.uuid_1, + classname(SnapshotRepositoryTestCase.Car), + 4, + created_at=current_datetime(), + updated_at=current_datetime(), + ), SnapshotEntry.from_root_entity( - Car( + SnapshotRepositoryTestCase.Car( 3, "blue", uuid=self.uuid_2, @@ -199,7 +228,7 @@ async def test_dispatch_third_transaction(self): ) ), SnapshotEntry.from_root_entity( - Car( + SnapshotRepositoryTestCase.Car( 3, "blue", uuid=self.uuid_3, @@ -221,10 +250,10 @@ async def test_dispatch_ignore_previous_version(self): entries = [ SnapshotEntry( uuid=self.uuid_1, - name=classname(Car), + name=classname(SnapshotRepositoryTestCase.Car), version=3, - schema=Car.avro_schema, - data=Car(3, "blue", uuid=self.uuid_1, version=1).avro_data, + schema=SnapshotRepositoryTestCase.Car.avro_schema, + data=SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_1, version=1).avro_data, created_at=current_datetime(), updated_at=current_datetime(), ) @@ -247,7 +276,9 @@ async def test_dispatch_ignore_previous_version(self): FakeAsyncIterator( [ tuple( - SnapshotEntry.from_root_entity(Car(3, "blue", uuid=self.uuid_1, version=5)) + SnapshotEntry.from_root_entity( + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_1, version=5) + ) .as_raw() .values() ) @@ -286,8 +317,8 @@ async def test_dispatch_with_offset(self): async def test_find_by_uuid(self): entities = [ - Car(3, "blue", uuid=self.uuid_2, version=2), - Car(3, "blue", uuid=self.uuid_3, version=1), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_2, version=2), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_3, version=1), ] with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): with patch.object( @@ -301,8 +332,8 @@ async def test_find_by_uuid(self): async def test_find_with_transaction(self): entities = [ - Car(3, "blue", uuid=self.uuid_2, version=4), - Car(3, "blue", uuid=self.uuid_3, version=1), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_2, version=4), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_3, version=1), ] with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): with patch.object( @@ -315,7 +346,7 @@ async def test_find_with_transaction(self): await super().test_find_with_transaction() async def test_find_with_transaction_delete(self): - entities = [Car(3, "blue", uuid=self.uuid_3, version=1)] + entities = [SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_3, version=1)] with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): with patch.object( DatabaseClient, @@ -328,8 +359,8 @@ async def test_find_with_transaction_delete(self): async def test_find_with_transaction_reverted(self): entities = [ - Car(3, "blue", uuid=self.uuid_2, version=2), - Car(3, "blue", uuid=self.uuid_3, version=1), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_2, version=2), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_3, version=1), ] with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): with patch.object( @@ -343,8 +374,8 @@ async def test_find_with_transaction_reverted(self): async def test_find_streaming_true(self): entities = [ - Car(3, "blue", uuid=self.uuid_2, version=2), - Car(3, "blue", uuid=self.uuid_3, version=1), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_2, version=2), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_3, version=1), ] with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): with patch.object( @@ -358,8 +389,8 @@ async def test_find_streaming_true(self): async def test_find_with_duplicates(self): entities = [ - Car(3, "blue", uuid=self.uuid_2, version=2), - Car(3, "blue", uuid=self.uuid_3, version=1), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_2, version=2), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_3, version=1), ] with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): with patch.object( @@ -385,7 +416,7 @@ async def test_find_empty(self): async def test_get(self): entities = [ - Car(3, "blue", uuid=self.uuid_2, version=2), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_2, version=2), ] with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): with patch.object( @@ -398,7 +429,7 @@ async def test_get(self): await super().test_get() async def test_get_with_transaction(self): - entities = [Car(3, "blue", uuid=self.uuid_2, version=4)] + entities = [SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_2, version=4)] with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): with patch.object( DatabaseClient, @@ -415,7 +446,15 @@ async def test_get_raises(self): DatabaseClient, "fetch_all", side_effect=[ - FakeAsyncIterator([tuple(SnapshotEntry(self.uuid_1, classname(Car), 1).as_raw().values())]), + FakeAsyncIterator( + [ + tuple( + SnapshotEntry(self.uuid_1, classname(SnapshotRepositoryTestCase.Car), 1) + .as_raw() + .values() + ) + ] + ), FakeAsyncIterator([]), ], ): @@ -427,15 +466,15 @@ async def test_get_with_transaction_raises(self): DatabaseClient, "fetch_all", return_value=FakeAsyncIterator( - [tuple(SnapshotEntry(self.uuid_1, classname(Car), 1).as_raw().values())] + [tuple(SnapshotEntry(self.uuid_1, classname(SnapshotRepositoryTestCase.Car), 1).as_raw().values())] ), ): await super().test_get_with_transaction_raises() async def test_find(self): entities = [ - Car(3, "blue", uuid=self.uuid_2, version=2), - Car(3, "blue", uuid=self.uuid_3, version=1), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_2, version=2), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_3, version=1), ] with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): with patch.object( @@ -449,8 +488,8 @@ async def test_find(self): async def test_find_all(self): entities = [ - Car(3, "blue", uuid=self.uuid_2, version=2), - Car(3, "blue", uuid=self.uuid_3, version=1), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_2, version=2), + SnapshotRepositoryTestCase.Car(3, "blue", uuid=self.uuid_3, version=1), ] with patch.object(DatabaseClient, "fetch_one", return_value=(9999,)): with patch.object( diff --git a/packages/core/minos-microservice-aggregate/tests/test_config.yml b/packages/core/minos-microservice-aggregate/tests/test_config.yml index 38b0f3152..ed9905abd 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_config.yml +++ b/packages/core/minos-microservice-aggregate/tests/test_config.yml @@ -2,14 +2,14 @@ service: name: Order aggregate: tests.utils.Order repository: - client: tests.utils.FakeDatabaseClient + client: minos.common.testing.MockedDatabaseClient database: order_db user: minos password: min0s host: localhost port: 5432 snapshot: - client: tests.utils.FakeDatabaseClient + client: minos.common.testing.MockedDatabaseClient database: order_db user: minos password: min0s @@ -22,7 +22,7 @@ broker: host: localhost port: 9092 queue: - client: tests.utils.FakeDatabaseClient + client: minos.common.testing.MockedDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-aggregate/tests/utils.py b/packages/core/minos-microservice-aggregate/tests/utils.py index 75a814da9..aa9333287 100644 --- a/packages/core/minos-microservice-aggregate/tests/utils.py +++ b/packages/core/minos-microservice-aggregate/tests/utils.py @@ -5,18 +5,10 @@ from abc import ( ABC, ) -from collections.abc import ( - AsyncIterator, - Iterable, -) -from datetime import ( - datetime, -) from pathlib import ( Path, ) from typing import ( - Any, Optional, ) from uuid import ( @@ -24,35 +16,23 @@ ) from minos.aggregate import ( - Action, Aggregate, Entity, EntitySet, - EventDatabaseOperationFactory, ExternalEntity, InMemoryEventRepository, InMemorySnapshotRepository, InMemoryTransactionRepository, Ref, RootEntity, - SnapshotDatabaseOperationFactory, - TransactionDatabaseOperationFactory, - TransactionStatus, ValueObject, ValueObjectSet, -) -from minos.aggregate.queries import ( - _Condition, - _Ordering, + testing, ) from minos.common import ( - DatabaseClient, DatabaseClientPool, - DatabaseOperation, Lock, - LockDatabaseOperationFactory, LockPool, - ManagementDatabaseOperationFactory, PoolFactory, ) from minos.common.testing import ( @@ -69,6 +49,8 @@ class AggregateTestCase(MinosTestCase, ABC): + testing_module = testing + def get_config_file_path(self): return CONFIG_FILE_PATH @@ -98,213 +80,6 @@ def get_injections(self): ] -class FakeDatabaseClient(DatabaseClient): - """For testing purposes""" - - def __init__(self, *args, **kwargs): - super().__init__(*args, **kwargs) - self.kwargs = kwargs - self._response = tuple() - - async def _is_valid(self, **kwargs) -> bool: - """For testing purposes""" - return True - - async def _reset(self, **kwargs) -> None: - """For testing purposes""" - self._response = tuple() - - async def _execute(self, operation: FakeDatabaseOperation) -> None: - """For testing purposes""" - self._response = operation.response - - async def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: - """For testing purposes""" - for value in self._response: - yield value - - -class FakeDatabaseOperation(DatabaseOperation): - """For testing purposes""" - - def __init__(self, content: str, response: Optional[Iterable[Any]] = tuple(), *args, **kwargs): - super().__init__(*args, **kwargs) - self.content = content - self.response = tuple(response) - - -class FakeLockDatabaseOperationFactory(LockDatabaseOperationFactory): - """For testing purposes""" - - def build_acquire(self, hashed_key: int) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("acquire") - - def build_release(self, hashed_key: int) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("release") - - -FakeDatabaseClient.set_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) - - -class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): - """For testing purposes""" - - def build_create(self, database: str) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("create") - - def build_delete(self, database: str) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("delete") - - -FakeDatabaseClient.set_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) - - -class FakeTransactionDatabaseOperationFactory(TransactionDatabaseOperationFactory): - """For testing purposes.""" - - def build_create(self) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("create") - - def build_submit( - self, uuid: UUID, destination_uuid: UUID, status: TransactionStatus, event_offset: int, **kwargs - ) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("submit") - - def build_query( - self, - uuid: Optional[UUID] = None, - uuid_ne: Optional[UUID] = None, - uuid_in: Optional[tuple[UUID]] = None, - destination_uuid: Optional[UUID] = None, - status: Optional[str] = None, - status_in: Optional[tuple[str]] = None, - event_offset: Optional[int] = None, - event_offset_lt: Optional[int] = None, - event_offset_gt: Optional[int] = None, - event_offset_le: Optional[int] = None, - event_offset_ge: Optional[int] = None, - updated_at: Optional[datetime] = None, - updated_at_lt: Optional[datetime] = None, - updated_at_gt: Optional[datetime] = None, - updated_at_le: Optional[datetime] = None, - updated_at_ge: Optional[datetime] = None, - **kwargs, - ) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("select") - - -FakeDatabaseClient.set_factory(TransactionDatabaseOperationFactory, FakeTransactionDatabaseOperationFactory) - - -class FakeEventDatabaseOperationFactory(EventDatabaseOperationFactory): - """For testing purposes.""" - - def build_create(self) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("create") - - def build_submit( - self, - transaction_uuids: tuple[UUID], - uuid: UUID, - action: Action, - name: str, - version: int, - data: bytes, - created_at: datetime, - transaction_uuid: UUID, - lock: Optional[int], - **kwargs, - ) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("submit") - - def build_query( - self, - uuid: Optional[UUID] = None, - name: Optional[str] = None, - version: Optional[int] = None, - version_lt: Optional[int] = None, - version_gt: Optional[int] = None, - version_le: Optional[int] = None, - version_ge: Optional[int] = None, - id: Optional[int] = None, - id_lt: Optional[int] = None, - id_gt: Optional[int] = None, - id_le: Optional[int] = None, - id_ge: Optional[int] = None, - transaction_uuid: Optional[UUID] = None, - transaction_uuid_ne: Optional[UUID] = None, - transaction_uuid_in: Optional[tuple[UUID, ...]] = None, - **kwargs, - ) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("select_rows") - - def build_query_offset(self) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("select_max_id") - - -FakeDatabaseClient.set_factory(EventDatabaseOperationFactory, FakeEventDatabaseOperationFactory) - - -class FakeSnapshotDatabaseOperationFactory(SnapshotDatabaseOperationFactory): - """For testing purposes.""" - - def build_create(self) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("create") - - def build_delete(self, transaction_uuids: Iterable[UUID]) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("delete") - - def build_submit( - self, - uuid: UUID, - name: str, - version: int, - schema: bytes, - data: dict[str, Any], - created_at: datetime, - updated_at: datetime, - transaction_uuid: UUID, - ) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("insert") - - def build_query( - self, - name: str, - condition: _Condition, - ordering: Optional[_Ordering], - limit: Optional[int], - transaction_uuids: tuple[UUID, ...], - exclude_deleted: bool, - ) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("query") - - def build_submit_offset(self, value: int) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("store_offset") - - def build_query_offset(self) -> DatabaseOperation: - """For testing purposes.""" - return FakeDatabaseOperation("get_offset") - - -FakeDatabaseClient.set_factory(SnapshotDatabaseOperationFactory, FakeSnapshotDatabaseOperationFactory) - - class FakeAsyncIterator: """For testing purposes.""" diff --git a/packages/core/minos-microservice-common/minos/common/importlib.py b/packages/core/minos-microservice-common/minos/common/importlib.py index f917f2a21..b27aa8908 100644 --- a/packages/core/minos-microservice-common/minos/common/importlib.py +++ b/packages/core/minos-microservice-common/minos/common/importlib.py @@ -1,5 +1,8 @@ import importlib import pkgutil +from contextlib import ( + suppress, +) from functools import ( lru_cache, ) @@ -22,7 +25,7 @@ def import_module(module_name: str) -> Union[type, Callable, ModuleType]: parts = module_name.rsplit(".", 1) try: - kallable = importlib.import_module(parts[0]) + kallable = _import_module(parts[0]) except ImportError: raise MinosImportException(f"Error importing {module_name!r}: the module does not exist") @@ -35,6 +38,16 @@ def import_module(module_name: str) -> Union[type, Callable, ModuleType]: return kallable +def _import_module(module_name: str) -> Union[type, Callable, ModuleType]: + try: + return importlib.import_module(module_name) + except ImportError as exc: + if "." in module_name: + with suppress(MinosImportException): + return import_module(module_name) + raise exc + + def classname(cls: Union[type, Callable]) -> str: """Compute the given class full name. diff --git a/packages/core/minos-microservice-common/minos/common/testing/__init__.py b/packages/core/minos-microservice-common/minos/common/testing/__init__.py new file mode 100644 index 000000000..01fd17cc3 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/testing/__init__.py @@ -0,0 +1,10 @@ +from .database import ( + MockedDatabaseClient, + MockedDatabaseOperation, + MockedLockDatabaseOperationFactory, + MockedManagementDatabaseOperationFactory, +) +from .testcases import ( + DatabaseMinosTestCase, + MinosTestCase, +) diff --git a/packages/core/minos-microservice-common/minos/common/testing/database/__init__.py b/packages/core/minos-microservice-common/minos/common/testing/database/__init__.py new file mode 100644 index 000000000..03b3ef9a7 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/testing/database/__init__.py @@ -0,0 +1,10 @@ +from .clients import ( + MockedDatabaseClient, +) +from .factories import ( + MockedLockDatabaseOperationFactory, + MockedManagementDatabaseOperationFactory, +) +from .operations import ( + MockedDatabaseOperation, +) diff --git a/packages/core/minos-microservice-common/minos/common/testing/database/clients.py b/packages/core/minos-microservice-common/minos/common/testing/database/clients.py new file mode 100644 index 000000000..cc6ec8aae --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/testing/database/clients.py @@ -0,0 +1,39 @@ +from collections.abc import ( + AsyncIterator, +) +from typing import ( + Any, +) + +from ...database import ( + DatabaseClient, +) +from .operations import ( + MockedDatabaseOperation, +) + + +class MockedDatabaseClient(DatabaseClient): + """For testing purposes""" + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self.kwargs = kwargs + self._response = tuple() + + async def _is_valid(self, **kwargs) -> bool: + """For testing purposes""" + return True + + async def _reset(self, **kwargs) -> None: + """For testing purposes""" + self._response = tuple() + + async def _execute(self, operation: MockedDatabaseOperation) -> None: + """For testing purposes""" + self._response = operation.response + + async def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: + """For testing purposes""" + for value in self._response: + yield value diff --git a/packages/core/minos-microservice-common/minos/common/testing/database/factories/__init__.py b/packages/core/minos-microservice-common/minos/common/testing/database/factories/__init__.py new file mode 100644 index 000000000..9aadffc99 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/testing/database/factories/__init__.py @@ -0,0 +1,6 @@ +from .locks import ( + MockedLockDatabaseOperationFactory, +) +from .managements import ( + MockedManagementDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-common/minos/common/testing/database/factories/locks.py b/packages/core/minos-microservice-common/minos/common/testing/database/factories/locks.py new file mode 100644 index 000000000..9cad4761d --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/testing/database/factories/locks.py @@ -0,0 +1,25 @@ +from ....database import ( + DatabaseOperation, + LockDatabaseOperationFactory, +) +from ..clients import ( + MockedDatabaseClient, +) +from ..operations import ( + MockedDatabaseOperation, +) + + +class MockedLockDatabaseOperationFactory(LockDatabaseOperationFactory): + """For testing purposes""" + + def build_acquire(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("acquire") + + def build_release(self, hashed_key: int) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("release") + + +MockedDatabaseClient.set_factory(LockDatabaseOperationFactory, MockedLockDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-common/minos/common/testing/database/factories/managements.py b/packages/core/minos-microservice-common/minos/common/testing/database/factories/managements.py new file mode 100644 index 000000000..3819967b6 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/testing/database/factories/managements.py @@ -0,0 +1,25 @@ +from ....database import ( + DatabaseOperation, + ManagementDatabaseOperationFactory, +) +from ..clients import ( + MockedDatabaseClient, +) +from ..operations import ( + MockedDatabaseOperation, +) + + +class MockedManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): + """For testing purposes""" + + def build_create(self, database: str) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("create") + + def build_delete(self, database: str) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("delete") + + +MockedDatabaseClient.set_factory(ManagementDatabaseOperationFactory, MockedManagementDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-common/minos/common/testing/database/operations.py b/packages/core/minos-microservice-common/minos/common/testing/database/operations.py new file mode 100644 index 000000000..ac6d000e2 --- /dev/null +++ b/packages/core/minos-microservice-common/minos/common/testing/database/operations.py @@ -0,0 +1,20 @@ +from collections.abc import ( + Iterable, +) +from typing import ( + Any, + Optional, +) + +from ...database import ( + DatabaseOperation, +) + + +class MockedDatabaseOperation(DatabaseOperation): + """For testing purposes""" + + def __init__(self, content: str, response: Optional[Iterable[Any]] = tuple(), *args, **kwargs): + super().__init__(*args, **kwargs) + self.content = content + self.response = tuple(response) diff --git a/packages/core/minos-microservice-common/minos/common/testing.py b/packages/core/minos-microservice-common/minos/common/testing/testcases.py similarity index 97% rename from packages/core/minos-microservice-common/minos/common/testing.py rename to packages/core/minos-microservice-common/minos/common/testing/testcases.py index e868b54e8..d9e718ab0 100644 --- a/packages/core/minos-microservice-common/minos/common/testing.py +++ b/packages/core/minos-microservice-common/minos/common/testing/testcases.py @@ -20,19 +20,19 @@ uuid4, ) -from .config import ( +from ..config import ( Config, ) -from .database import ( +from ..database import ( DatabaseClient, DatabaseClientPool, ManagementDatabaseOperationFactory, ) -from .injections import ( +from ..injections import ( DependencyInjector, InjectableMixin, ) -from .pools import ( +from ..pools import ( PoolFactory, ) diff --git a/packages/core/minos-microservice-common/tests/config/v1.yml b/packages/core/minos-microservice-common/tests/config/v1.yml index 1240496a0..950aaa4e1 100644 --- a/packages/core/minos-microservice-common/tests/config/v1.yml +++ b/packages/core/minos-microservice-common/tests/config/v1.yml @@ -19,7 +19,7 @@ service: - tests.utils.FakeSagaManager - tests.utils.FakeCustomInjection repository: - client: tests.utils.FakeDatabaseClient + client: minos.common.testing.MockedDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-common/tests/config/v2.yml b/packages/core/minos-microservice-common/tests/config/v2.yml index a331350b4..37a2a4010 100644 --- a/packages/core/minos-microservice-common/tests/config/v2.yml +++ b/packages/core/minos-microservice-common/tests/config/v2.yml @@ -6,7 +6,7 @@ serializer: client: tests.utils.FakeSerializer databases: default: - client: tests.utils.FakeDatabaseClient + client: minos.common.testing.MockedDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py index bcdd40a6d..f18159339 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_locks.py @@ -4,8 +4,8 @@ DatabaseLock, Lock, ) -from tests.utils import ( - FakeDatabaseClient, +from minos.common.testing import ( + MockedDatabaseClient, ) @@ -14,22 +14,22 @@ def test_base(self): self.assertTrue(issubclass(DatabaseLock, Lock)) async def test_client(self): - client = FakeDatabaseClient() + client = MockedDatabaseClient() lock = DatabaseLock(client, "foo") self.assertEqual(client, lock.client) async def test_key(self): - client = FakeDatabaseClient() + client = MockedDatabaseClient() lock = DatabaseLock(client, "foo") self.assertEqual("foo", lock.key) async def test_key_raises(self): - client = FakeDatabaseClient() + client = MockedDatabaseClient() with self.assertRaises(ValueError): DatabaseLock(client, []) async def test_hashed_key(self): - client = FakeDatabaseClient() + client = MockedDatabaseClient() lock = DatabaseLock(client, "foo") self.assertEqual(hash("foo"), lock.hashed_key) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py index dd5939ec2..3222c4f98 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py @@ -9,12 +9,12 @@ ) from minos.common.testing import ( DatabaseMinosTestCase, + MockedDatabaseClient, + MockedDatabaseOperation, + MockedLockDatabaseOperationFactory, ) from tests.utils import ( CommonTestCase, - FakeDatabaseClient, - FakeDatabaseOperation, - FakeLockDatabaseOperationFactory, ) @@ -43,20 +43,20 @@ async def test_pool(self): self.assertIsInstance(database.database_pool, DatabaseClientPool) async def test_operation_factory(self): - operation_factory = FakeLockDatabaseOperationFactory() + operation_factory = MockedLockDatabaseOperationFactory() mixin = DatabaseMixin(operation_factory=operation_factory) self.assertEqual(operation_factory, mixin.operation_factory) async def test_operation_factory_from_cls_init(self): mixin = DatabaseMixin(operation_factory_cls=LockDatabaseOperationFactory) - self.assertIsInstance(mixin.operation_factory, FakeLockDatabaseOperationFactory) + self.assertIsInstance(mixin.operation_factory, MockedLockDatabaseOperationFactory) async def test_operation_factory_from_cls_generic(self): class _DatabaseMixin(DatabaseMixin[LockDatabaseOperationFactory]): """For testing purposes.""" mixin = _DatabaseMixin() - self.assertIsInstance(mixin.operation_factory, FakeLockDatabaseOperationFactory) + self.assertIsInstance(mixin.operation_factory, MockedLockDatabaseOperationFactory) async def test_operation_factory_none(self): mixin = DatabaseMixin() @@ -70,31 +70,31 @@ class _DatabaseMixin(DatabaseMixin[int]): _DatabaseMixin() async def test_submit_query(self): - op1 = FakeDatabaseOperation("create_table") - op2 = FakeDatabaseOperation("check_exist", [(True,)]) + op1 = MockedDatabaseOperation("create_table") + op2 = MockedDatabaseOperation("check_exist", [(True,)]) async with DatabaseMixin() as database: await database.submit_query(op1) - async with FakeDatabaseClient(**self.config.get_default_database()) as client: + async with MockedDatabaseClient(**self.config.get_default_database()) as client: await client.execute(op2) self.assertTrue((await client.fetch_one())[0]) async def test_submit_query_locked(self): - op1 = FakeDatabaseOperation("create_table", lock=1234) - op2 = FakeDatabaseOperation("check_exist", [(True,)]) + op1 = MockedDatabaseOperation("create_table", lock=1234) + op2 = MockedDatabaseOperation("check_exist", [(True,)]) async with DatabaseMixin() as database: await database.submit_query(op1) - async with FakeDatabaseClient(**self.config.get_default_database()) as client: + async with MockedDatabaseClient(**self.config.get_default_database()) as client: await client.execute(op2) self.assertTrue((await client.fetch_one())[0]) async def test_submit_query_and_fetchone(self): - op1 = FakeDatabaseOperation("create_table") - op2 = FakeDatabaseOperation("insert") - op3 = FakeDatabaseOperation("select", [(3,), (4,), (5,)]) + op1 = MockedDatabaseOperation("create_table") + op2 = MockedDatabaseOperation("insert") + op3 = MockedDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: await database.submit_query(op1) @@ -105,9 +105,9 @@ async def test_submit_query_and_fetchone(self): self.assertEqual((3,), observed) async def test_submit_query_and_iter(self): - op1 = FakeDatabaseOperation("create_table") - op2 = FakeDatabaseOperation("insert") - op3 = FakeDatabaseOperation("select", [(3,), (4,), (5,)]) + op1 = MockedDatabaseOperation("create_table") + op2 = MockedDatabaseOperation("insert") + op3 = MockedDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: await database.submit_query(op1) @@ -117,9 +117,9 @@ async def test_submit_query_and_iter(self): self.assertEqual([(3,), (4,), (5,)], observed) async def test_submit_query_and_iter_streaming_mode_true(self): - op1 = FakeDatabaseOperation("create_table") - op2 = FakeDatabaseOperation("insert") - op3 = FakeDatabaseOperation("select", [(3,), (4,), (5,)]) + op1 = MockedDatabaseOperation("create_table") + op2 = MockedDatabaseOperation("insert") + op3 = MockedDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: await database.submit_query(op1) @@ -130,9 +130,9 @@ async def test_submit_query_and_iter_streaming_mode_true(self): self.assertEqual([(3,), (4,), (5,)], observed) async def test_submit_query_and_iter_locked(self): - op1 = FakeDatabaseOperation("create_table", lock=1234) - op2 = FakeDatabaseOperation("insert") - op3 = FakeDatabaseOperation("select", [(3,), (4,), (5,)]) + op1 = MockedDatabaseOperation("create_table", lock=1234) + op2 = MockedDatabaseOperation("insert") + op3 = MockedDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: await database.submit_query(op1) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py index 28dcde22f..bfe2d53b8 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_pools.py @@ -15,11 +15,11 @@ ) from minos.common.testing import ( DatabaseMinosTestCase, + MockedDatabaseClient, ) from tests.utils import ( CONFIG_FILE_PATH, CommonTestCase, - FakeDatabaseClient, ) @@ -44,7 +44,7 @@ async def asyncTearDown(self): def test_from_config(self): pool = DatabaseClientPool.from_config(self.config, key="event") self.assertIsInstance(pool.client_builder, DatabaseClientBuilder) - self.assertEqual(FakeDatabaseClient, pool.client_builder.instance_cls) + self.assertEqual(MockedDatabaseClient, pool.client_builder.instance_cls) def test_from_config_client_builder(self): config = Config(CONFIG_FILE_PATH, databases_default_client=classname(DatabaseClientBuilder)) @@ -72,15 +72,15 @@ async def test_acquire_multiple_same_time(self): self.assertNotEqual(c1, c2) async def test_acquire_with_reset(self): - with patch.object(FakeDatabaseClient, "reset") as reset_mock: + with patch.object(MockedDatabaseClient, "reset") as reset_mock: async with self.pool.acquire(): self.assertEqual(0, reset_mock.call_count) self.assertEqual(1, reset_mock.call_count) async def test_acquire_with_raises(self): - with patch.object(FakeDatabaseClient, "setup", side_effect=[ConnectionException(""), None]): + with patch.object(MockedDatabaseClient, "setup", side_effect=[ConnectionException(""), None]): async with self.pool.acquire() as client: - self.assertIsInstance(client, FakeDatabaseClient) + self.assertIsInstance(client, MockedDatabaseClient) class TestDatabaseLockPool(CommonTestCase, DatabaseMinosTestCase): diff --git a/packages/core/minos-microservice-common/tests/utils.py b/packages/core/minos-microservice-common/tests/utils.py index ffe03e14d..b7090bbae 100644 --- a/packages/core/minos-microservice-common/tests/utils.py +++ b/packages/core/minos-microservice-common/tests/utils.py @@ -2,39 +2,27 @@ annotations, ) -from collections.abc import ( - AsyncIterator, - Iterable, -) from pathlib import ( Path, ) -from typing import ( - Any, - Optional, -) from minos.common import ( BuildableMixin, Builder, - DatabaseClient, - DatabaseOperation, Injectable, Lock, - LockDatabaseOperationFactory, LockPool, - ManagementDatabaseOperationFactory, Port, -) -from minos.common.testing import ( - MinosTestCase, + testing, ) BASE_PATH = Path(__file__).parent CONFIG_FILE_PATH = BASE_PATH / "config" / "v2.yml" -class CommonTestCase(MinosTestCase): +class CommonTestCase(testing.MinosTestCase): + testing_module = testing + def get_config_file_path(self) -> Path: return CONFIG_FILE_PATH @@ -81,71 +69,6 @@ async def __anext__(self): raise StopAsyncIteration -class FakeDatabaseClient(DatabaseClient): - """For testing purposes""" - - def __init__(self, *args, **kwargs): - super().__init__(*args, **kwargs) - self.kwargs = kwargs - self._response = tuple() - - async def _is_valid(self, **kwargs) -> bool: - """For testing purposes""" - return True - - async def _reset(self, **kwargs) -> None: - """For testing purposes""" - self._response = tuple() - - async def _execute(self, operation: FakeDatabaseOperation) -> None: - """For testing purposes""" - self._response = operation.response - - async def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: - """For testing purposes""" - for value in self._response: - yield value - - -class FakeLockDatabaseOperationFactory(LockDatabaseOperationFactory): - """For testing purposes""" - - def build_acquire(self, hashed_key: int) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("acquire") - - def build_release(self, hashed_key: int) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("release") - - -FakeDatabaseClient.set_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) - - -class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): - """For testing purposes""" - - def build_create(self, database: str) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("create") - - def build_delete(self, database: str) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("delete") - - -FakeDatabaseClient.set_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) - - -class FakeDatabaseOperation(DatabaseOperation): - """For testing purposes""" - - def __init__(self, content: str, response: Optional[Iterable[Any]] = tuple(), *args, **kwargs): - super().__init__(*args, **kwargs) - self.content = content - self.response = tuple(response) - - class FakeLock(Lock): """For testing purposes.""" diff --git a/packages/core/minos-microservice-cqrs/tests/test_config.yml b/packages/core/minos-microservice-cqrs/tests/test_config.yml index c56d1d5c1..ee1e9270b 100644 --- a/packages/core/minos-microservice-cqrs/tests/test_config.yml +++ b/packages/core/minos-microservice-cqrs/tests/test_config.yml @@ -8,7 +8,7 @@ broker: host: localhost port: 9092 queue: - client: tests.utils.FakeDatabaseClient + client: minos.common.testing.MockedDatabaseClient database: order_db user: minos password: min0s @@ -17,14 +17,14 @@ broker: records: 10 retry: 2 repository: - client: tests.utils.FakeDatabaseClient + client: minos.common.testing.MockedDatabaseClient database: order_db user: minos password: min0s host: localhost port: 5432 snapshot: - client: tests.utils.FakeDatabaseClient + client: minos.common.testing.MockedDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-cqrs/tests/utils.py b/packages/core/minos-microservice-cqrs/tests/utils.py index c93e7cced..a70c6b4cf 100644 --- a/packages/core/minos-microservice-cqrs/tests/utils.py +++ b/packages/core/minos-microservice-cqrs/tests/utils.py @@ -2,29 +2,15 @@ annotations, ) -from collections.abc import ( - AsyncIterator, - Iterable, -) from pathlib import ( Path, ) -from typing import ( - Any, - Optional, -) from minos.aggregate import ( ExternalEntity, Ref, RootEntity, ) -from minos.common import ( - DatabaseClient, - DatabaseOperation, - LockDatabaseOperationFactory, - ManagementDatabaseOperationFactory, -) from minos.cqrs import ( CommandService, QueryService, @@ -69,68 +55,3 @@ class Bar(ExternalEntity): """For testing purposes""" name: str - - -class FakeDatabaseClient(DatabaseClient): - """For testing purposes""" - - def __init__(self, *args, **kwargs): - super().__init__(*args, **kwargs) - self.kwargs = kwargs - self._response = tuple() - - async def _is_valid(self, **kwargs) -> bool: - """For testing purposes""" - return True - - async def _reset(self, **kwargs) -> None: - """For testing purposes""" - self._response = tuple() - - async def _execute(self, operation: FakeDatabaseOperation) -> None: - """For testing purposes""" - self._response = operation.response - - async def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: - """For testing purposes""" - for value in self._response: - yield value - - -class FakeDatabaseOperation(DatabaseOperation): - """For testing purposes""" - - def __init__(self, content: str, response: Optional[Iterable[Any]] = tuple(), *args, **kwargs): - super().__init__(*args, **kwargs) - self.content = content - self.response = tuple(response) - - -class FakeLockDatabaseOperationFactory(LockDatabaseOperationFactory): - """For testing purposes""" - - def build_acquire(self, hashed_key: int) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("acquire") - - def build_release(self, hashed_key: int) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("release") - - -FakeDatabaseClient.set_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) - - -class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): - """For testing purposes""" - - def build_create(self, database: str) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("create") - - def build_delete(self, database: str) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("delete") - - -FakeDatabaseClient.set_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) diff --git a/packages/core/minos-microservice-networks/minos/networks/testing/__init__.py b/packages/core/minos-microservice-networks/minos/networks/testing/__init__.py new file mode 100644 index 000000000..451f42047 --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/testing/__init__.py @@ -0,0 +1,6 @@ +from .brokers import ( + MockedBrokerPublisherQueueDatabaseOperationFactory, + MockedBrokerQueueDatabaseOperationFactory, + MockedBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + MockedBrokerSubscriberQueueDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/testing/brokers/__init__.py b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/__init__.py new file mode 100644 index 000000000..8d6486131 --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/__init__.py @@ -0,0 +1,10 @@ +from .collections import ( + MockedBrokerQueueDatabaseOperationFactory, +) +from .publishers import ( + MockedBrokerPublisherQueueDatabaseOperationFactory, +) +from .subscribers import ( + MockedBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + MockedBrokerSubscriberQueueDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/testing/brokers/collections/__init__.py b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/collections/__init__.py new file mode 100644 index 000000000..2f2dbc0d3 --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/collections/__init__.py @@ -0,0 +1,3 @@ +from .queues import ( + MockedBrokerQueueDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/testing/brokers/collections/queues.py b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/collections/queues.py new file mode 100644 index 000000000..2d8f47bac --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/collections/queues.py @@ -0,0 +1,46 @@ +from collections.abc import ( + Iterable, +) + +from minos.common import ( + DatabaseOperation, +) +from minos.common.testing import ( + MockedDatabaseOperation, +) + +from ....brokers import ( + BrokerQueueDatabaseOperationFactory, +) + + +class MockedBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory): + """For testing purposes.""" + + def build_create(self) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("create_queue_table") + + def build_mark_processed(self, id_: int) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("update_not_processed") + + def build_delete(self, id_: int) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("delete_processed") + + def build_mark_processing(self, ids: Iterable[int]) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("mark_processing") + + def build_count(self, retry: int, *args, **kwargs) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("count_not_processed") + + def build_submit(self, topic: str, data: bytes) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("insert") + + def build_query(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("select_not_processed") diff --git a/packages/core/minos-microservice-networks/minos/networks/testing/brokers/publishers/__init__.py b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/publishers/__init__.py new file mode 100644 index 000000000..3100d864b --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/publishers/__init__.py @@ -0,0 +1,3 @@ +from .queues import ( + MockedBrokerPublisherQueueDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/testing/brokers/publishers/queues.py b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/publishers/queues.py new file mode 100644 index 000000000..8afd22f4e --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/publishers/queues.py @@ -0,0 +1,21 @@ +from minos.common.testing import ( + MockedDatabaseClient, +) +from minos.networks import ( + BrokerPublisherQueueDatabaseOperationFactory, +) + +from ..collections import ( + MockedBrokerQueueDatabaseOperationFactory, +) + + +class MockedBrokerPublisherQueueDatabaseOperationFactory( + BrokerPublisherQueueDatabaseOperationFactory, MockedBrokerQueueDatabaseOperationFactory +): + """For testing purposes""" + + +MockedDatabaseClient.set_factory( + BrokerPublisherQueueDatabaseOperationFactory, MockedBrokerPublisherQueueDatabaseOperationFactory +) diff --git a/packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/__init__.py b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/__init__.py new file mode 100644 index 000000000..c4c2368bc --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/__init__.py @@ -0,0 +1,6 @@ +from .queues import ( + MockedBrokerSubscriberQueueDatabaseOperationFactory, +) +from .validators import ( + MockedBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/queues.py b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/queues.py new file mode 100644 index 000000000..ff480ee5a --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/queues.py @@ -0,0 +1,39 @@ +from collections.abc import ( + Iterable, +) + +from minos.common import ( + DatabaseOperation, +) +from minos.common.testing import ( + MockedDatabaseClient, + MockedDatabaseOperation, +) + +from ....brokers import ( + BrokerSubscriberQueueDatabaseOperationFactory, +) +from ..collections import ( + MockedBrokerQueueDatabaseOperationFactory, +) + + +class MockedBrokerSubscriberQueueDatabaseOperationFactory( + BrokerSubscriberQueueDatabaseOperationFactory, MockedBrokerQueueDatabaseOperationFactory +): + """For testing purposes""" + + def build_count(self, retry: int, topics: Iterable[str] = tuple(), *args, **kwargs) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("count_not_processed") + + def build_query( + self, retry: int, records: int, topics: Iterable[str] = tuple(), *args, **kwargs + ) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("select_not_processed") + + +MockedDatabaseClient.set_factory( + BrokerSubscriberQueueDatabaseOperationFactory, MockedBrokerSubscriberQueueDatabaseOperationFactory +) diff --git a/packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/validators.py b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/validators.py new file mode 100644 index 000000000..cf1230143 --- /dev/null +++ b/packages/core/minos-microservice-networks/minos/networks/testing/brokers/subscribers/validators.py @@ -0,0 +1,35 @@ +from uuid import ( + UUID, +) + +from minos.common import ( + DatabaseOperation, +) +from minos.common.testing import ( + MockedDatabaseClient, + MockedDatabaseOperation, +) + +from ....brokers import ( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, +) + + +class MockedBrokerSubscriberDuplicateValidatorDatabaseOperationFactory( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory +): + """For testing purposes""" + + def build_create(self) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("create_table") + + def build_submit(self, topic: str, uuid: UUID) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("insert_row") + + +MockedDatabaseClient.set_factory( + BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, + MockedBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-networks/tests/test_config.yml b/packages/core/minos-microservice-networks/tests/test_config.yml index ca4b4ee59..15153c1ff 100644 --- a/packages/core/minos-microservice-networks/tests/test_config.yml +++ b/packages/core/minos-microservice-networks/tests/test_config.yml @@ -16,7 +16,7 @@ rest: host: localhost port: 8080 repository: - client: tests.utils.FakeDatabaseClient + client: minos.common.testing.MockedDatabaseClient database: order_db user: minos password: min0s diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_database.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_database.py index df23c2b9c..c0fba03b6 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_database.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_database.py @@ -16,6 +16,7 @@ ) from minos.common.testing import ( DatabaseMinosTestCase, + MockedDatabaseClient, ) from minos.networks import ( BrokerMessageV1, @@ -23,10 +24,11 @@ BrokerQueue, DatabaseBrokerQueue, ) +from minos.networks.testing import ( + MockedBrokerQueueDatabaseOperationFactory, +) from tests.utils import ( FakeAsyncIterator, - FakeBrokerQueueDatabaseOperationFactory, - FakeDatabaseClient, NetworksTestCase, ) @@ -34,7 +36,7 @@ class TestDatabaseBrokerQueue(NetworksTestCase, DatabaseMinosTestCase): def setUp(self) -> None: super().setUp() - self.operation_factory = FakeBrokerQueueDatabaseOperationFactory() + self.operation_factory = MockedBrokerQueueDatabaseOperationFactory() def test_is_subclass(self): self.assertTrue(issubclass(DatabaseBrokerQueue, (BrokerQueue, DatabaseMixin))) @@ -55,7 +57,7 @@ async def test_enqueue(self): message = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) with patch.object( - FakeDatabaseClient, + MockedDatabaseClient, "fetch_all", side_effect=chain( [FakeAsyncIterator([(0,)]), FakeAsyncIterator([(1, message.avro_bytes)])], @@ -78,7 +80,7 @@ async def test_aiter(self): await queue.enqueue(messages[1]) with patch.object( - FakeDatabaseClient, + MockedDatabaseClient, "fetch_all", side_effect=chain( [ @@ -104,7 +106,7 @@ async def test_dequeue_with_count(self): ] with patch.object( - FakeDatabaseClient, + MockedDatabaseClient, "fetch_all", return_value=FakeAsyncIterator([[1, messages[0].avro_bytes], [2, bytes()], [3, messages[1].avro_bytes]]), ): @@ -123,7 +125,7 @@ async def test_dequeue_with_notify(self): ] with patch.object( - FakeDatabaseClient, + MockedDatabaseClient, "fetch_all", side_effect=chain( [ @@ -155,7 +157,7 @@ async def test_dequeue_ordered(self): ] with patch.object( - FakeDatabaseClient, + MockedDatabaseClient, "fetch_all", side_effect=chain( [ diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_database.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_database.py index bfbe9709c..300867e87 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_database.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_database.py @@ -8,16 +8,18 @@ ) from minos.common.testing import ( DatabaseMinosTestCase, + MockedDatabaseClient, ) from minos.networks import ( BrokerMessageV1, BrokerMessageV1Payload, - BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, BrokerSubscriberValidator, DatabaseBrokerSubscriberDuplicateValidator, ) +from minos.networks.testing import ( + MockedBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, +) from tests.utils import ( - FakeDatabaseClient, NetworksTestCase, ) @@ -29,14 +31,18 @@ def test_is_subclass(self): async def test_operation_factory(self): validator = DatabaseBrokerSubscriberDuplicateValidator.from_config(self.config) - self.assertIsInstance(validator.operation_factory, BrokerSubscriberDuplicateValidatorDatabaseOperationFactory) + self.assertIsInstance( + validator.operation_factory, MockedBrokerSubscriberDuplicateValidatorDatabaseOperationFactory + ) async def test_is_valid(self): one = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) two = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) three = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) - with patch.object(FakeDatabaseClient, "execute", side_effect=[None, None, None, IntegrityException(""), None]): + with patch.object( + MockedDatabaseClient, "execute", side_effect=[None, None, None, IntegrityException(""), None] + ): async with DatabaseBrokerSubscriberDuplicateValidator.from_config(self.config) as validator: self.assertTrue(await validator.is_valid(one)) self.assertTrue(await validator.is_valid(two)) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_database.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_database.py index 955158e94..8ac420655 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_database.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_database.py @@ -12,19 +12,21 @@ from minos.common.testing import ( DatabaseMinosTestCase, + MockedDatabaseClient, ) from minos.networks import ( BrokerMessageV1, BrokerMessageV1Payload, BrokerSubscriberQueue, - BrokerSubscriberQueueDatabaseOperationFactory, DatabaseBrokerQueue, DatabaseBrokerSubscriberQueue, DatabaseBrokerSubscriberQueueBuilder, ) +from minos.networks.testing import ( + MockedBrokerSubscriberQueueDatabaseOperationFactory, +) from tests.utils import ( FakeAsyncIterator, - FakeDatabaseClient, NetworksTestCase, ) @@ -36,13 +38,13 @@ def test_is_subclass(self): async def test_operation_factory(self): queue = DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) - self.assertIsInstance(queue.operation_factory, BrokerSubscriberQueueDatabaseOperationFactory) + self.assertIsInstance(queue.operation_factory, MockedBrokerSubscriberQueueDatabaseOperationFactory) async def test_enqueue(self): message = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) with patch.object( - FakeDatabaseClient, + MockedDatabaseClient, "fetch_all", side_effect=chain( [FakeAsyncIterator([(0,)]), FakeAsyncIterator([(1, message.avro_bytes)])], @@ -60,7 +62,7 @@ async def test_dequeue_with_count(self): ] with patch.object( - FakeDatabaseClient, + MockedDatabaseClient, "fetch_all", side_effect=[ FakeAsyncIterator( @@ -84,7 +86,7 @@ async def test_dequeue_with_notify(self): BrokerMessageV1("bar", BrokerMessageV1Payload("foo")), ] with patch.object( - FakeDatabaseClient, + MockedDatabaseClient, "fetch_all", side_effect=[ FakeAsyncIterator([(0,)]), diff --git a/packages/core/minos-microservice-networks/tests/utils.py b/packages/core/minos-microservice-networks/tests/utils.py index 6a22b160c..d357189ee 100644 --- a/packages/core/minos-microservice-networks/tests/utils.py +++ b/packages/core/minos-microservice-networks/tests/utils.py @@ -5,10 +5,6 @@ from abc import ( ABC, ) -from collections.abc import ( - AsyncIterator, - Iterable, -) from datetime import ( timedelta, ) @@ -23,31 +19,21 @@ Callable, Optional, ) -from uuid import ( - UUID, -) from minos.common import ( - DatabaseClient, - DatabaseOperation, DeclarativeModel, - LockDatabaseOperationFactory, - ManagementDatabaseOperationFactory, ) from minos.common.testing import ( MinosTestCase, ) from minos.networks import ( - BrokerPublisherQueueDatabaseOperationFactory, - BrokerQueueDatabaseOperationFactory, - BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, - BrokerSubscriberQueueDatabaseOperationFactory, EnrouteDecorator, HttpConnector, Request, Response, WrappedRequest, enroute, + testing, ) BASE_PATH = Path(__file__).parent @@ -55,159 +41,12 @@ class NetworksTestCase(MinosTestCase, ABC): + testing_module = testing + def get_config_file_path(self): return CONFIG_FILE_PATH -class FakeDatabaseClient(DatabaseClient): - """For testing purposes""" - - def __init__(self, *args, **kwargs): - super().__init__(*args, **kwargs) - self.kwargs = kwargs - self._response = tuple() - - async def _is_valid(self, **kwargs) -> bool: - """For testing purposes""" - return True - - async def _reset(self, **kwargs) -> None: - """For testing purposes""" - self._response = tuple() - - async def _execute(self, operation: FakeDatabaseOperation) -> None: - """For testing purposes""" - self._response = operation.response - - async def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: - """For testing purposes""" - for value in self._response: - yield value - - -class FakeDatabaseOperation(DatabaseOperation): - """For testing purposes""" - - def __init__(self, content: str, response: Optional[Iterable[Any]] = tuple(), *args, **kwargs): - super().__init__(*args, **kwargs) - self.content = content - self.response = tuple(response) - - -class FakeLockDatabaseOperationFactory(LockDatabaseOperationFactory): - """For testing purposes""" - - def build_acquire(self, hashed_key: int) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("acquire") - - def build_release(self, hashed_key: int) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("release") - - -FakeDatabaseClient.set_factory(LockDatabaseOperationFactory, FakeLockDatabaseOperationFactory) - - -class FakeManagementDatabaseOperationFactory(ManagementDatabaseOperationFactory): - """For testing purposes""" - - def build_create(self, database: str) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("create") - - def build_delete(self, database: str) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("delete") - - -FakeDatabaseClient.set_factory(ManagementDatabaseOperationFactory, FakeManagementDatabaseOperationFactory) - - -class FakeBrokerQueueDatabaseOperationFactory(BrokerQueueDatabaseOperationFactory): - """For testing purposes.""" - - def build_create(self) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("create_queue_table") - - def build_mark_processed(self, id_: int) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("update_not_processed") - - def build_delete(self, id_: int) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("delete_processed") - - def build_mark_processing(self, ids: Iterable[int]) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("mark_processing") - - def build_count(self, retry: int, *args, **kwargs) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("count_not_processed") - - def build_submit(self, topic: str, data: bytes) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("insert") - - def build_query(self, retry: int, records: int, *args, **kwargs) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("select_not_processed") - - -class FakeBrokerPublisherQueueDatabaseOperationFactory( - BrokerPublisherQueueDatabaseOperationFactory, FakeBrokerQueueDatabaseOperationFactory -): - """For testing purposes""" - - -FakeDatabaseClient.set_factory( - BrokerPublisherQueueDatabaseOperationFactory, FakeBrokerPublisherQueueDatabaseOperationFactory -) - - -class FakeBrokerSubscriberQueueDatabaseOperationFactory( - BrokerSubscriberQueueDatabaseOperationFactory, FakeBrokerQueueDatabaseOperationFactory -): - """For testing purposes""" - - def build_count(self, retry: int, topics: Iterable[str] = tuple(), *args, **kwargs) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("count_not_processed") - - def build_query( - self, retry: int, records: int, topics: Iterable[str] = tuple(), *args, **kwargs - ) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("select_not_processed") - - -FakeDatabaseClient.set_factory( - BrokerSubscriberQueueDatabaseOperationFactory, FakeBrokerSubscriberQueueDatabaseOperationFactory -) - - -class FakeBrokerSubscriberDuplicateValidatorDatabaseOperationFactory( - BrokerSubscriberDuplicateValidatorDatabaseOperationFactory -): - """For testing purposes""" - - def build_create(self) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("create_table") - - def build_submit(self, topic: str, uuid: UUID) -> DatabaseOperation: - """For testing purposes""" - return FakeDatabaseOperation("insert_row") - - -FakeDatabaseClient.set_factory( - BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, - FakeBrokerSubscriberDuplicateValidatorDatabaseOperationFactory, -) - - @total_ordering class FakeModel(DeclarativeModel): """For testing purposes""" diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_repository.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_repository.py index 0181a0845..791e82b7c 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_repository.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_factories/test_aggregate/test_snapshots/test_repository.py @@ -6,9 +6,6 @@ from minos.aggregate.testing import ( SnapshotRepositoryTestCase, ) -from minos.aggregate.testing.snapshot_repository import ( - Car, -) from minos.plugins.aiopg import ( AiopgDatabaseClient, AiopgDatabaseOperation, @@ -46,9 +43,9 @@ async def test_setup_snapshot_aux_offset_table(self): async def test_is_synced(self): await self.populate() - self.assertFalse(await self.snapshot_repository.is_synced(Car)) + self.assertFalse(await self.snapshot_repository.is_synced(SnapshotRepositoryTestCase.Car)) await self.snapshot_repository.synchronize() - self.assertTrue(await self.snapshot_repository.is_synced(Car)) + self.assertTrue(await self.snapshot_repository.is_synced(SnapshotRepositoryTestCase.Car)) if __name__ == "__main__": From 405f31fd8d3671842e7e1399b138eb1280f46721 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 08:42:15 +0200 Subject: [PATCH 253/324] ISSUE #98 * Ignore code duplication on `testing` module. --- .sonarcloud.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.sonarcloud.properties b/.sonarcloud.properties index f65be1b2a..566fa3ed0 100644 --- a/.sonarcloud.properties +++ b/.sonarcloud.properties @@ -1,3 +1,3 @@ sonar.python.version=3.9 sonar.exclusions=tutorials/** -sonar.cpd.exclusions=**/tests/** \ No newline at end of file +sonar.cpd.exclusions=**/tests/**, **/testing/** \ No newline at end of file From 47a0aaeb404a711d2e44de1e04c4abfd9ebbd873 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 08:54:30 +0200 Subject: [PATCH 254/324] ISSUE #98 * Raise a `MinosConfigException` when requested database does not exist. --- .../minos/common/config/abc.py | 9 ++++--- .../tests/test_common/test_config/test_abc.py | 3 ++- .../test_config/test_v2/test_base.py | 27 ------------------- 3 files changed, 8 insertions(+), 31 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/config/abc.py b/packages/core/minos-microservice-common/minos/common/config/abc.py index 9c4714094..60e38c1d2 100644 --- a/packages/core/minos-microservice-common/minos/common/config/abc.py +++ b/packages/core/minos-microservice-common/minos/common/config/abc.py @@ -145,18 +145,21 @@ def get_default_database(self): :return: A ``dict`` containing the database's config values. """ - return self.get_database_by_name("default") + return self.get_database_by_name(None) - def get_database_by_name(self, name: str) -> dict[str, Any]: + def get_database_by_name(self, name: Optional[str]) -> dict[str, Any]: """Get the database value by name. :param name: The name of the database. If ``None`` is provided then the default database will be used. :return: A ``dict`` containing the database's config values. """ + if name is None: + name = "default" + databases = self.get_databases() if name not in databases: - name = "default" + raise MinosConfigException(f"{name!r} database is not configured") return databases[name] diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_abc.py index f8c6077bf..1ae4ac008 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_abc.py @@ -147,7 +147,8 @@ def test_get_database_unknown(self): mock = MagicMock(return_value={"default": "foo"}) self.config._get_databases = mock - self.assertEqual("foo", self.config.get_database_by_name("unknown")) + with self.assertRaises(MinosConfigException): + self.config.get_database_by_name("unknown") self.assertEqual([call()], mock.call_args_list) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py index ff0d2bc8d..163d8b6d5 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v2/test_base.py @@ -191,15 +191,6 @@ def test_database_default(self): self.assertEqual("localhost", database_config["host"]) self.assertEqual(5432, database_config["port"]) - def test_database_event(self): - config = ConfigV2(self.file_path, with_environment=False) - database_config = config.get_database_by_name("event") - self.assertEqual("order_db", database_config["database"]) - self.assertEqual("minos", database_config["user"]) - self.assertEqual("min0s", database_config["password"]) - self.assertEqual("localhost", database_config["host"]) - self.assertEqual(5432, database_config["port"]) - def test_database_query(self): config = ConfigV2(self.file_path, with_environment=False) query_database = config.get_database_by_name("query") @@ -209,24 +200,6 @@ def test_database_query(self): self.assertEqual("localhost", query_database["host"]) self.assertEqual(5432, query_database["port"]) - def test_database_snapshot(self): - config = ConfigV2(self.file_path, with_environment=False) - snapshot = config.get_database_by_name("snapshot") - self.assertEqual("order_db", snapshot["database"]) - self.assertEqual("minos", snapshot["user"]) - self.assertEqual("min0s", snapshot["password"]) - self.assertEqual("localhost", snapshot["host"]) - self.assertEqual(5432, snapshot["port"]) - - def test_database_broker(self): - config = ConfigV2(self.file_path, with_environment=False) - snapshot = config.get_database_by_name("broker") - self.assertEqual("order_db", snapshot["database"]) - self.assertEqual("minos", snapshot["user"]) - self.assertEqual("min0s", snapshot["password"]) - self.assertEqual("localhost", snapshot["host"]) - self.assertEqual(5432, snapshot["port"]) - def test_database_saga(self): config = ConfigV2(self.file_path, with_environment=False) saga = config.get_database_by_name("saga") From 9933c0334d8ec0967e3f774d047168336a7a58f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 09:36:37 +0200 Subject: [PATCH 255/324] ISSUE #98 * Add support for multiple databases. --- .../events/repositories/database/impl.py | 8 ++++---- .../snapshots/repositories/database/impl.py | 10 ++++------ .../repositories/database/impl.py | 8 ++++---- .../minos/common/__init__.py | 1 + .../minos/common/database/mixins.py | 20 +++++++++++++++++-- .../minos/common/pools.py | 15 ++++++++++++-- .../tests/config/v2.yml | 1 + .../test_common/test_database/test_mixins.py | 7 +++++++ .../tests/test_common/test_pools.py | 12 +++++++++-- .../collections/queues/database/impl.py | 5 ++++- .../validators/duplicates/database/impl.py | 8 ++++++++ 11 files changed, 74 insertions(+), 21 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index cb4da8335..f6f83c48b 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -9,7 +9,6 @@ from minos.common import ( NULL_UUID, - Config, DatabaseMixin, DatabaseOperation, IntegrityException, @@ -32,9 +31,10 @@ class DatabaseEventRepository(DatabaseMixin[EventDatabaseOperationFactory], EventRepository): """Database-based implementation of the event repository class.""" - @classmethod - def _from_config(cls, config: Config, **kwargs) -> Optional[EventRepository]: - return super()._from_config(config, database_key=None, **kwargs) + def __init__(self, *args, database_key: Optional[tuple[str]] = None, **kwargs): + if database_key is None: + database_key = ("aggregate", "event") + super().__init__(*args, database_key=database_key, **kwargs) async def _setup(self): """Setup miscellaneous repository things. diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py index 9d4ecd1fa..1f4fa23e2 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py @@ -15,7 +15,6 @@ from minos.common import ( NULL_UUID, - Config, DatabaseMixin, Inject, NotProvidedException, @@ -71,9 +70,12 @@ def __init__( *args, event_repository: EventRepository, transaction_repository: TransactionRepository, + database_key: Optional[tuple[str]] = None, **kwargs, ): - super().__init__(*args, **kwargs) + if database_key is None: + database_key = ("aggregate", "snapshot") + super().__init__(*args, database_key=database_key, **kwargs) if event_repository is None: raise NotProvidedException("An event repository instance is required.") @@ -84,10 +86,6 @@ def __init__( self._event_repository = event_repository self._transaction_repository = transaction_repository - @classmethod - def _from_config(cls, config: Config, **kwargs) -> DatabaseSnapshotRepository: - return cls(database_key=None, **kwargs) - async def _setup(self) -> None: operation = self.operation_factory.build_create() await self.submit_query(operation) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index f1be223b0..ca9cc4b3b 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -8,7 +8,6 @@ ) from minos.common import ( - Config, DatabaseMixin, ProgrammingException, ) @@ -30,9 +29,10 @@ class DatabaseTransactionRepository(DatabaseMixin[TransactionDatabaseOperationFactory], TransactionRepository): """Database Transaction Repository class.""" - @classmethod - def _from_config(cls, config: Config, **kwargs) -> DatabaseTransactionRepository: - return super()._from_config(config, database_key=None, **kwargs) + def __init__(self, *args, database_key: Optional[tuple[str]] = None, **kwargs): + if database_key is None: + database_key = ("aggregate", "transaction") + super().__init__(*args, database_key=database_key, **kwargs) async def _setup(self): operation = self.operation_factory.build_create() diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 408ca17a6..968bd051a 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -113,6 +113,7 @@ from .pools import ( MinosPool, Pool, + PoolException, PoolFactory, ) from .ports import ( diff --git a/packages/core/minos-microservice-common/minos/common/database/mixins.py b/packages/core/minos-microservice-common/minos/common/database/mixins.py index 13602518c..cb7696240 100644 --- a/packages/core/minos-microservice-common/minos/common/database/mixins.py +++ b/packages/core/minos-microservice-common/minos/common/database/mixins.py @@ -1,3 +1,6 @@ +from contextlib import ( + suppress, +) from typing import ( AsyncIterator, Generic, @@ -14,6 +17,7 @@ Inject, ) from ..pools import ( + PoolException, PoolFactory, ) from ..setup import ( @@ -39,15 +43,16 @@ def __init__( self, database_pool: Optional[DatabaseClientPool] = None, pool_factory: Optional[PoolFactory] = None, - database_key: Optional[str] = None, + database_key: Optional[tuple[str]] = None, operation_factory: Optional[GenericDatabaseOperationFactory] = None, operation_factory_cls: Optional[type[GenericDatabaseOperationFactory]] = None, *args, **kwargs, ): super().__init__(*args, **kwargs, pool_factory=pool_factory) + if database_pool is None and pool_factory is not None: - database_pool = pool_factory.get_pool(type_="database", identifier=database_key) + database_pool = self._get_pool_from_factory(pool_factory, database_key) if not isinstance(database_pool, DatabaseClientPool): raise NotProvidedException(f"A {DatabaseClientPool!r} instance is required. Obtained: {database_pool}") @@ -62,6 +67,17 @@ def __init__( self._operation_factory = operation_factory + @staticmethod + def _get_pool_from_factory(pool_factory: PoolFactory, database_key: Optional[tuple[str]]): + if database_key is None: + database_key = tuple() + + for identifier in database_key: + with suppress(PoolException): + return pool_factory.get_pool(type_="database", identifier=identifier) + + return pool_factory.get_pool(type_="database") + @property def operation_factory(self) -> Optional[GenericDatabaseOperationFactory]: """Get the operation factory if any. diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index 9ffcce19b..c16c57176 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -29,6 +29,10 @@ from .config import ( Config, ) +from .exceptions import ( + MinosConfigException, + MinosException, +) from .injections import ( Injectable, ) @@ -87,7 +91,10 @@ def get_pool(self, type_: str, identifier: Optional[str] = None, **kwargs) -> Po def _create_pool(self, type_: str, **kwargs) -> Pool: # noinspection PyTypeChecker pool_cls = self._get_pool_cls(type_) - pool = pool_cls.from_config(self._config, **kwargs) + try: + pool = pool_cls.from_config(self._config, **kwargs) + except MinosConfigException: + raise PoolException("The pool could not be built.") return pool def _get_pool_cls(self, type_: str) -> type[Pool]: @@ -97,7 +104,7 @@ def _get_pool_cls(self, type_: str) -> type[Pool]: pool_cls = self._config.get_pools().get("types", dict()).get(type_) if pool_cls is None: - raise ValueError( + raise PoolException( f"There is not any provided {type!r} to build pools that matches the given type: {type_!r}" ) @@ -175,3 +182,7 @@ class MinosPool(Pool, Generic[P], ABC): def __init__(self, *args, **kwargs): warnings.warn(f"{MinosPool!r} has been deprecated. Use {Pool} instead.", DeprecationWarning) super().__init__(*args, **kwargs) + + +class PoolException(MinosException): + """Exception to be raised when some problem related with a pool happens.""" diff --git a/packages/core/minos-microservice-common/tests/config/v2.yml b/packages/core/minos-microservice-common/tests/config/v2.yml index 37a2a4010..5222904d1 100644 --- a/packages/core/minos-microservice-common/tests/config/v2.yml +++ b/packages/core/minos-microservice-common/tests/config/v2.yml @@ -15,6 +15,7 @@ databases: saga: path: "./order.lmdb" query: + client: minos.common.testing.MockedDatabaseClient database: order_query_db user: minos password: min0s diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py index 3222c4f98..9bba39406 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py @@ -33,6 +33,13 @@ async def test_constructor_with_pool_factory(self): # noinspection PyUnresolvedReferences self.assertEqual(pool_factory.get_pool("database"), database.database_pool) + async def test_constructor_with_pool_factory_and_database_key(self): + pool_factory = PoolFactory(self.config, {"database": DatabaseClientPool}) + # noinspection PyTypeChecker + database = DatabaseMixin(pool_factory=pool_factory, database_key=("query", "unknown")) + # noinspection PyUnresolvedReferences + self.assertEqual(pool_factory.get_pool("database", "query"), database.database_pool) + async def test_constructor_raises(self): with self.assertRaises(NotProvidedException): # noinspection PyArgumentEqualDefault diff --git a/packages/core/minos-microservice-common/tests/test_common/test_pools.py b/packages/core/minos-microservice-common/tests/test_common/test_pools.py index dbd6dea4e..f0607679f 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_pools.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_pools.py @@ -10,6 +10,7 @@ ) from unittest.mock import ( MagicMock, + patch, ) from aiomisc import ( @@ -17,8 +18,10 @@ ) from minos.common import ( + MinosConfigException, MinosPool, Pool, + PoolException, PoolFactory, SetupMixin, ) @@ -55,10 +58,15 @@ def test_get_pool_with_key(self): self.assertEqual(lock_a, self.factory.get_pool("lock", "a")) self.assertEqual(lock_b, self.factory.get_pool("lock", "b")) - def test_get_pool_raises(self): - with self.assertRaises(ValueError): + def test_get_pool_cls_raises(self): + with self.assertRaises(PoolException): self.factory.get_pool("something") + def test_get_pool_identifier_raises(self): + with patch.object(SetupMixin, "from_config", side_effect=MinosConfigException("")): + with self.assertRaises(PoolException): + self.factory.get_pool("database") + class TestPool(unittest.IsolatedAsyncioTestCase): def test_abstract(self): diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index 61f475b81..a43bd43f8 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -65,9 +65,12 @@ def __init__( *args, retry: Optional[int] = None, records: Optional[int] = None, + database_key: Optional[tuple[str]] = None, **kwargs, ): - super().__init__(*args, **kwargs) + if database_key is None: + database_key = ("broker",) + super().__init__(*args, database_key=database_key, **kwargs) if retry is None: retry = 2 diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py index 70d48d148..6b7c3dcf8 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py @@ -2,6 +2,9 @@ annotations, ) +from typing import ( + Optional, +) from uuid import ( UUID, ) @@ -27,6 +30,11 @@ class DatabaseBrokerSubscriberDuplicateValidator( ): """Database Broker Subscriber Duplicate Detector class.""" + def __init__(self, *args, database_key: Optional[tuple[str]] = None, **kwargs): + if database_key is None: + database_key = ("broker",) + super().__init__(*args, database_key=database_key, **kwargs) + async def _setup(self) -> None: await super()._setup() await self._create_table() From 9649f2e2410bbc451f2762be7b530d737ce6fd82 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 09:50:56 +0200 Subject: [PATCH 256/324] ISSUE #98 * Be resilient to undefined saga config. --- .../minos/saga/executions/storage.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/storage.py b/packages/core/minos-microservice-saga/minos/saga/executions/storage.py index 3bcf75ef5..c2a31a201 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/storage.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/storage.py @@ -2,6 +2,9 @@ annotations, ) +from contextlib import ( + suppress, +) from typing import ( Type, Union, @@ -12,6 +15,7 @@ from minos.common import ( Config, + MinosConfigException, MinosJsonBinaryProtocol, MinosStorage, MinosStorageLmdb, @@ -46,7 +50,9 @@ def from_config(cls, config: Config, **kwargs) -> SagaExecutionStorage: :param kwargs: Additional named arguments. :return: A new ``SagaExecutionStorage`` instance. """ - return cls(**(config.get_database_by_name("saga") | kwargs)) + with suppress(MinosConfigException): + kwargs |= config.get_database_by_name("saga") + return cls(**kwargs) def store(self, execution: SagaExecution) -> None: """Store an execution. From f990278c21eece0a59c63b554a51a75aa200c168 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 10:04:45 +0200 Subject: [PATCH 257/324] ISSUE #98 * Rename `submit_query` as `execute_on_database`. * Rename `submit_query_and_fetchone` as `execute_on_database_and_fetch_one`. * Rename `submit_query_and_fetchall` as `execute_on_database_and_fetch_all`. --- .../events/repositories/database/impl.py | 18 +++---- .../snapshots/repositories/database/impl.py | 24 +++++----- .../repositories/database/impl.py | 12 ++--- .../minos/common/database/mixins.py | 14 +++--- .../test_common/test_database/test_mixins.py | 48 +++++++++---------- .../collections/queues/database/impl.py | 28 +++++------ .../validators/duplicates/database/impl.py | 8 ++-- .../queued/queues/database/impl.py | 6 +-- .../test_queues/test_database.py | 4 +- .../test_queued/test_queues/test_database.py | 2 +- .../test_duplicates/test_database.py | 2 +- .../test_queued/test_queues/test_database.py | 2 +- 12 files changed, 85 insertions(+), 83 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py index f6f83c48b..0f549e33e 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/impl.py @@ -41,14 +41,14 @@ async def _setup(self): :return: This method does not return anything. """ - operation = self.operation_factory.build_create() - await self.submit_query(operation) + operation = self.database_operation_factory.build_create() + await self.execute_on_database(operation) async def _submit(self, entry: EventEntry, **kwargs) -> EventEntry: operation = await self._build_submit_operation(entry) try: - response = await self.submit_query_and_fetchone(operation) + response = await self.execute_on_database_and_fetch_one(operation) except IntegrityException: raise EventRepositoryConflictException( f"{entry!r} could not be submitted due to a key (uuid, version, transaction) collision", @@ -69,15 +69,17 @@ async def _build_submit_operation(self, entry: EventEntry) -> DatabaseOperation: else: transaction_uuids = (NULL_UUID,) - return self.operation_factory.build_submit(transaction_uuids=transaction_uuids, **entry.as_raw(), lock=lock) + return self.database_operation_factory.build_submit( + transaction_uuids=transaction_uuids, **entry.as_raw(), lock=lock + ) async def _select(self, streaming_mode: Optional[bool] = None, **kwargs) -> AsyncIterator[EventEntry]: - operation = self.operation_factory.build_query(**kwargs) - async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): + operation = self.database_operation_factory.build_query(**kwargs) + async for row in self.execute_on_database_and_fetch_all(operation, streaming_mode=streaming_mode): yield EventEntry(*row) @property async def _offset(self) -> int: - operation = self.operation_factory.build_query_offset() - row = await self.submit_query_and_fetchone(operation) + operation = self.database_operation_factory.build_query_offset() + row = await self.execute_on_database_and_fetch_one(operation) return row[0] or 0 diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py index 1f4fa23e2..2f80ae02b 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/impl.py @@ -87,8 +87,8 @@ def __init__( self._transaction_repository = transaction_repository async def _setup(self) -> None: - operation = self.operation_factory.build_create() - await self.submit_query(operation) + operation = self.database_operation_factory.build_create() + await self.execute_on_database(operation) async def _destroy(self) -> None: await super()._destroy() @@ -110,11 +110,11 @@ async def _find_entries( else: transaction_uuids = await transaction.uuids - operation = self.operation_factory.build_query( + operation = self.database_operation_factory.build_query( name, condition, ordering, limit, transaction_uuids, exclude_deleted ) - async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): + async for row in self.execute_on_database_and_fetch_all(operation, streaming_mode=streaming_mode): yield SnapshotEntry(*row) async def is_synced(self, name: str, **kwargs) -> bool: @@ -148,17 +148,17 @@ async def _synchronize(self, **kwargs) -> None: await self._store_offset(offset) async def _load_offset(self) -> int: - operation = self.operation_factory.build_query_offset() + operation = self.database_operation_factory.build_query_offset() # noinspection PyBroadException try: - row = await self.submit_query_and_fetchone(operation) + row = await self.execute_on_database_and_fetch_one(operation) except ProgrammingException: return 0 return row[0] async def _store_offset(self, offset: int) -> None: - operation = self.operation_factory.build_submit_offset(offset) - await self.submit_query(operation) + operation = self.database_operation_factory.build_submit_offset(offset) + await self.execute_on_database(operation) async def _dispatch_one(self, event_entry: EventEntry, **kwargs) -> SnapshotEntry: if event_entry.action.is_delete: @@ -210,8 +210,8 @@ async def _select_one_instance(self, name: str, uuid: UUID, **kwargs) -> RootEnt return snapshot_entry.build(**kwargs) async def _submit_entry(self, snapshot_entry: SnapshotEntry) -> SnapshotEntry: - operation = self.operation_factory.build_submit(**snapshot_entry.as_raw()) - response = await self.submit_query_and_fetchone(operation) + operation = self.database_operation_factory.build_submit(**snapshot_entry.as_raw()) + response = await self.execute_on_database_and_fetch_one(operation) snapshot_entry.created_at, snapshot_entry.updated_at = response @@ -223,5 +223,5 @@ async def _clean_transactions(self, offset: int, **kwargs) -> None: ) transaction_uuids = {transaction.uuid async for transaction in iterable} if len(transaction_uuids): - operation = self.operation_factory.build_delete(transaction_uuids) - await self.submit_query(operation) + operation = self.database_operation_factory.build_delete(transaction_uuids) + await self.execute_on_database(operation) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py index ca9cc4b3b..2b0ac0026 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/impl.py @@ -35,16 +35,16 @@ def __init__(self, *args, database_key: Optional[tuple[str]] = None, **kwargs): super().__init__(*args, database_key=database_key, **kwargs) async def _setup(self): - operation = self.operation_factory.build_create() - await self.submit_query(operation) + operation = self.database_operation_factory.build_create() + await self.execute_on_database(operation) async def _submit(self, transaction: TransactionEntry) -> TransactionEntry: - operation = self.operation_factory.build_submit( + operation = self.database_operation_factory.build_submit( **transaction.as_raw(), ) try: - updated_at = await self.submit_query_and_fetchone(operation) + updated_at = await self.execute_on_database_and_fetch_one(operation) except ProgrammingException: raise TransactionRepositoryConflictException( f"{transaction!r} status is invalid respect to the previous one." @@ -53,6 +53,6 @@ async def _submit(self, transaction: TransactionEntry) -> TransactionEntry: return transaction async def _select(self, streaming_mode: Optional[bool] = None, **kwargs) -> AsyncIterator[TransactionEntry]: - operation = self.operation_factory.build_query(**kwargs) - async for row in self.submit_query_and_iter(operation, streaming_mode=streaming_mode): + operation = self.database_operation_factory.build_query(**kwargs) + async for row in self.execute_on_database_and_fetch_all(operation, streaming_mode=streaming_mode): yield TransactionEntry(*row, transaction_repository=self) diff --git a/packages/core/minos-microservice-common/minos/common/database/mixins.py b/packages/core/minos-microservice-common/minos/common/database/mixins.py index cb7696240..48c64a06e 100644 --- a/packages/core/minos-microservice-common/minos/common/database/mixins.py +++ b/packages/core/minos-microservice-common/minos/common/database/mixins.py @@ -79,7 +79,7 @@ def _get_pool_from_factory(pool_factory: PoolFactory, database_key: Optional[tup return pool_factory.get_pool(type_="database") @property - def operation_factory(self) -> Optional[GenericDatabaseOperationFactory]: + def database_operation_factory(self) -> Optional[GenericDatabaseOperationFactory]: """Get the operation factory if any. :return: A ``OperationFactory`` if it has been set or ``None`` otherwise. @@ -101,8 +101,8 @@ def _get_generic_operation_factory(self) -> Optional[type[GenericDatabaseOperati raise TypeError(f"{type(self)!r} must contain a {DatabaseOperationFactory!r} as generic value.") return operation_factory_cls - async def submit_query_and_fetchone(self, operation: DatabaseOperation) -> tuple: - """Submit a SQL query and gets the first response. + async def execute_on_database_and_fetch_one(self, operation: DatabaseOperation) -> tuple: + """Submit an Operation and get the first response. :param operation: The operation to be executed. :return: This method does not return anything. @@ -112,10 +112,10 @@ async def submit_query_and_fetchone(self, operation: DatabaseOperation) -> tuple return await client.fetch_one() # noinspection PyUnusedLocal - async def submit_query_and_iter( + async def execute_on_database_and_fetch_all( self, operation: DatabaseOperation, streaming_mode: Optional[bool] = None ) -> AsyncIterator[tuple]: - """Submit a SQL query and return an asynchronous iterator. + """Submit an Operation and return an asynchronous iterator. :param operation: The operation to be executed. :param streaming_mode: If ``True`` return the values in streaming directly from the database (keep an open @@ -139,8 +139,8 @@ async def submit_query_and_iter( yield value # noinspection PyUnusedLocal - async def submit_query(self, operation: DatabaseOperation) -> None: - """Submit a SQL query. + async def execute_on_database(self, operation: DatabaseOperation) -> None: + """Submit an Operation. :param operation: The operation to be executed. :return: This method does not return anything. diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py index 9bba39406..a0433e187 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_mixins.py @@ -52,22 +52,22 @@ async def test_pool(self): async def test_operation_factory(self): operation_factory = MockedLockDatabaseOperationFactory() mixin = DatabaseMixin(operation_factory=operation_factory) - self.assertEqual(operation_factory, mixin.operation_factory) + self.assertEqual(operation_factory, mixin.database_operation_factory) async def test_operation_factory_from_cls_init(self): mixin = DatabaseMixin(operation_factory_cls=LockDatabaseOperationFactory) - self.assertIsInstance(mixin.operation_factory, MockedLockDatabaseOperationFactory) + self.assertIsInstance(mixin.database_operation_factory, MockedLockDatabaseOperationFactory) async def test_operation_factory_from_cls_generic(self): class _DatabaseMixin(DatabaseMixin[LockDatabaseOperationFactory]): """For testing purposes.""" mixin = _DatabaseMixin() - self.assertIsInstance(mixin.operation_factory, MockedLockDatabaseOperationFactory) + self.assertIsInstance(mixin.database_operation_factory, MockedLockDatabaseOperationFactory) async def test_operation_factory_none(self): mixin = DatabaseMixin() - self.assertEqual(None, mixin.operation_factory) + self.assertEqual(None, mixin.database_operation_factory) async def test_operation_factory_from_cls_generic_raises(self): class _DatabaseMixin(DatabaseMixin[int]): @@ -76,76 +76,76 @@ class _DatabaseMixin(DatabaseMixin[int]): with self.assertRaises(TypeError): _DatabaseMixin() - async def test_submit_query(self): + async def test_execute_on_database(self): op1 = MockedDatabaseOperation("create_table") op2 = MockedDatabaseOperation("check_exist", [(True,)]) async with DatabaseMixin() as database: - await database.submit_query(op1) + await database.execute_on_database(op1) async with MockedDatabaseClient(**self.config.get_default_database()) as client: await client.execute(op2) self.assertTrue((await client.fetch_one())[0]) - async def test_submit_query_locked(self): + async def test_execute_on_database_locked(self): op1 = MockedDatabaseOperation("create_table", lock=1234) op2 = MockedDatabaseOperation("check_exist", [(True,)]) async with DatabaseMixin() as database: - await database.submit_query(op1) + await database.execute_on_database(op1) async with MockedDatabaseClient(**self.config.get_default_database()) as client: await client.execute(op2) self.assertTrue((await client.fetch_one())[0]) - async def test_submit_query_and_fetchone(self): + async def test_execute_on_database_and_fetch_one(self): op1 = MockedDatabaseOperation("create_table") op2 = MockedDatabaseOperation("insert") op3 = MockedDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: - await database.submit_query(op1) - await database.submit_query(op2) + await database.execute_on_database(op1) + await database.execute_on_database(op2) - observed = await database.submit_query_and_fetchone(op3) + observed = await database.execute_on_database_and_fetch_one(op3) self.assertEqual((3,), observed) - async def test_submit_query_and_iter(self): + async def test_execute_on_database_and_fetch_all(self): op1 = MockedDatabaseOperation("create_table") op2 = MockedDatabaseOperation("insert") op3 = MockedDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: - await database.submit_query(op1) - await database.submit_query(op2) - observed = [v async for v in database.submit_query_and_iter(op3)] + await database.execute_on_database(op1) + await database.execute_on_database(op2) + observed = [v async for v in database.execute_on_database_and_fetch_all(op3)] self.assertEqual([(3,), (4,), (5,)], observed) - async def test_submit_query_and_iter_streaming_mode_true(self): + async def test_execute_on_database_and_fetch_all_streaming_mode_true(self): op1 = MockedDatabaseOperation("create_table") op2 = MockedDatabaseOperation("insert") op3 = MockedDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: - await database.submit_query(op1) - await database.submit_query(op2) + await database.execute_on_database(op1) + await database.execute_on_database(op2) - observed = [v async for v in database.submit_query_and_iter(op3, streaming_mode=True)] + observed = [v async for v in database.execute_on_database_and_fetch_all(op3, streaming_mode=True)] self.assertEqual([(3,), (4,), (5,)], observed) - async def test_submit_query_and_iter_locked(self): + async def test_execute_on_database_and_fetch_all_locked(self): op1 = MockedDatabaseOperation("create_table", lock=1234) op2 = MockedDatabaseOperation("insert") op3 = MockedDatabaseOperation("select", [(3,), (4,), (5,)]) async with DatabaseMixin() as database: - await database.submit_query(op1) - await database.submit_query(op2) + await database.execute_on_database(op1) + await database.execute_on_database(op2) - observed = [v async for v in database.submit_query_and_iter(op3)] + observed = [v async for v in database.execute_on_database_and_fetch_all(op3)] self.assertEqual([(3,), (4,), (5,)], observed) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py index a43bd43f8..05c876780 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/impl.py @@ -120,8 +120,8 @@ async def _destroy(self) -> None: await super()._destroy() async def _create_table(self) -> None: - operation = self.operation_factory.build_create() - await self.submit_query(operation) + operation = self.database_operation_factory.build_create() + await self.execute_on_database(operation) async def _start_run(self) -> None: if self._run_task is None: @@ -142,13 +142,13 @@ async def _flush_queue(self): entry = self._queue.get_nowait() except QueueEmpty: break - operation = self.operation_factory.build_mark_processed(entry.id_) - await self.submit_query(operation) + operation = self.database_operation_factory.build_mark_processed(entry.id_) + await self.execute_on_database(operation) self._queue.task_done() async def _enqueue(self, message: BrokerMessage) -> None: - operation = self.operation_factory.build_submit(message.topic, message.avro_bytes) - await self.submit_query(operation) + operation = self.database_operation_factory.build_submit(message.topic, message.avro_bytes) + await self.execute_on_database(operation) await self._notify_enqueued(message) # noinspection PyUnusedLocal @@ -166,12 +166,12 @@ async def _dequeue(self) -> BrokerMessage: logger.warning( f"There was a problem while trying to deserialize the entry with {entry.id_!r} id: {exc}" ) - operation = self.operation_factory.build_mark_processed(entry.id_) - await self.submit_query(operation) + operation = self.database_operation_factory.build_mark_processed(entry.id_) + await self.execute_on_database(operation) continue - operation = self.operation_factory.build_delete(entry.id_) - await self.submit_query(operation) + operation = self.database_operation_factory.build_delete(entry.id_) + await self.execute_on_database(operation) return message finally: self._queue.task_done() @@ -195,8 +195,8 @@ async def _wait_enqueued(self) -> None: async def _get_count(self) -> int: # noinspection PyTypeChecker - operation = self.operation_factory.build_count(self.retry) - row = await self.submit_query_and_fetchone(operation) + operation = self.database_operation_factory.build_count(self.retry) + row = await self.execute_on_database_and_fetch_one(operation) count = row[0] return count @@ -210,14 +210,14 @@ async def _dequeue_batch(self) -> None: entries = [_Entry(*row) for row in rows] ids = tuple(entry.id_ for entry in entries) - operation = self.operation_factory.build_mark_processing(ids) + operation = self.database_operation_factory.build_mark_processing(ids) await client.execute(operation) for entry in entries: await self._queue.put(entry) async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - operation = self.operation_factory.build_query(self._retry, self._records) + operation = self.database_operation_factory.build_query(self._retry, self._records) await client.execute(operation) return [row async for row in client.fetch_all()] diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py index 6b7c3dcf8..d802ad567 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/impl.py @@ -40,13 +40,13 @@ async def _setup(self) -> None: await self._create_table() async def _create_table(self) -> None: - operation = self.operation_factory.build_create() - await self.submit_query(operation) + operation = self.database_operation_factory.build_create() + await self.execute_on_database(operation) async def _is_unique(self, topic: str, uuid: UUID) -> bool: - operation = self.operation_factory.build_submit(topic, uuid) + operation = self.database_operation_factory.build_submit(topic, uuid) try: - await self.submit_query(operation) + await self.execute_on_database(operation) return True except IntegrityException: return False diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py index 5c3a570cd..7bbee880c 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/impl.py @@ -33,13 +33,13 @@ class DatabaseBrokerSubscriberQueue( async def _get_count(self) -> int: # noinspection PyTypeChecker - operation = self.operation_factory.build_count(self._retry, self.topics) - row = await self.submit_query_and_fetchone(operation) + operation = self.database_operation_factory.build_count(self._retry, self.topics) + row = await self.execute_on_database_and_fetch_one(operation) count = row[0] return count async def _dequeue_rows(self, client: DatabaseClient) -> list[Any]: - operation = self.operation_factory.build_query(self._retry, self._records, self.topics) + operation = self.database_operation_factory.build_query(self._retry, self._records, self.topics) await client.execute(operation) return [row async for row in client.fetch_all()] diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_database.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_database.py index c0fba03b6..7852320ee 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_database.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_collections/test_queues/test_database.py @@ -44,14 +44,14 @@ def test_is_subclass(self): def test_constructor(self): queue = DatabaseBrokerQueue(operation_factory=self.operation_factory) self.assertEqual(self.pool_factory.get_pool("database"), queue.database_pool) - self.assertEqual(self.operation_factory, queue.operation_factory) + self.assertEqual(self.operation_factory, queue.database_operation_factory) self.assertEqual(2, queue.retry) self.assertEqual(1000, queue.records) async def test_operation_factory(self): queue = DatabaseBrokerQueue.from_config(self.config, operation_factory=self.operation_factory) - self.assertEqual(self.operation_factory, queue.operation_factory) + self.assertEqual(self.operation_factory, queue.database_operation_factory) async def test_enqueue(self): message = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_database.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_database.py index ea49824c0..4d44c31d6 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_database.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_publishers/test_queued/test_queues/test_database.py @@ -21,7 +21,7 @@ def test_is_subclass(self): async def test_operation_factory(self): queue = DatabaseBrokerPublisherQueue.from_config(self.config) - self.assertIsInstance(queue.operation_factory, BrokerPublisherQueueDatabaseOperationFactory) + self.assertIsInstance(queue.database_operation_factory, BrokerPublisherQueueDatabaseOperationFactory) if __name__ == "__main__": diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_database.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_database.py index 300867e87..5f4e71c99 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_database.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_filtered/test_validators/test_duplicates/test_database.py @@ -32,7 +32,7 @@ async def test_operation_factory(self): validator = DatabaseBrokerSubscriberDuplicateValidator.from_config(self.config) self.assertIsInstance( - validator.operation_factory, MockedBrokerSubscriberDuplicateValidatorDatabaseOperationFactory + validator.database_operation_factory, MockedBrokerSubscriberDuplicateValidatorDatabaseOperationFactory ) async def test_is_valid(self): diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_database.py b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_database.py index 8ac420655..eb42d9f18 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_database.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_brokers/test_subscribers/test_queued/test_queues/test_database.py @@ -38,7 +38,7 @@ def test_is_subclass(self): async def test_operation_factory(self): queue = DatabaseBrokerSubscriberQueue.from_config(self.config, topics={"foo", "bar"}) - self.assertIsInstance(queue.operation_factory, MockedBrokerSubscriberQueueDatabaseOperationFactory) + self.assertIsInstance(queue.database_operation_factory, MockedBrokerSubscriberQueueDatabaseOperationFactory) async def test_enqueue(self): message = BrokerMessageV1("foo", BrokerMessageV1Payload("bar")) From f366197c793ac2a445c77060d208071c443fb90a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 10:18:26 +0200 Subject: [PATCH 258/324] ISSUE #98 * Update `README.md`. --- .../plugins/minos-database-aiopg/README.md | 25 ++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/packages/plugins/minos-database-aiopg/README.md b/packages/plugins/minos-database-aiopg/README.md index e69c5b280..c05e24ad0 100644 --- a/packages/plugins/minos-database-aiopg/README.md +++ b/packages/plugins/minos-database-aiopg/README.md @@ -22,9 +22,28 @@ Install the dependency: pip install minos-database-aiopg ``` -Modify `config.yml` file: - -[TODO] +Set the database client on the `config.yml` file: + +```yaml +... +databases: + default: + client: minos.plugins.aiopg.AiopgDatabaseClient + database: order_db + user: minos + password: min0s + host: localhost + port: 5432 + query: + client: minos.plugins.aiopg.AiopgDatabaseClient + database: order_query_db + user: minos + password: min0s + host: localhost + port: 5432 + ... +... +``` ## Documentation From 772e3302c7917154a3eb3f49415b86d976aa70f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 11:48:40 +0200 Subject: [PATCH 259/324] ISSUE #98 * Fix minor bugs. --- .../minos/plugins/aiopg/__init__.py | 6 + .../plugins/minos-database-aiopg/poetry.lock | 104 ++++----- .../minos-database-aiopg/pyproject.toml | 6 +- poetry.lock | 221 ++++++++++-------- pyproject.toml | 1 + 5 files changed, 179 insertions(+), 159 deletions(-) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py index 15ff2a727..b6329ef10 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py @@ -1,3 +1,9 @@ +"""The aiopg plugin of the Minos Framework.""" + +__author__ = "Minos Framework Devs" +__email__ = "hey@minos.run" +__version__ = "0.0.0" + from .clients import ( AiopgDatabaseClient, ) diff --git a/packages/plugins/minos-database-aiopg/poetry.lock b/packages/plugins/minos-database-aiopg/poetry.lock index 305d0cd6c..594d758c3 100644 --- a/packages/plugins/minos-database-aiopg/poetry.lock +++ b/packages/plugins/minos-database-aiopg/poetry.lock @@ -230,7 +230,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.6.0" +version = "0.7.0.dev1" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -239,9 +239,8 @@ develop = true [package.dependencies] cached-property = "^1.5.2" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" -psycopg2-binary = "^2.9.3" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" [package.source] type = "directory" @@ -249,7 +248,7 @@ url = "../../core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.1" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -258,7 +257,6 @@ develop = true [package.dependencies] aiomisc = ">=14.0.3,<15.8.0" -aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" @@ -273,7 +271,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -281,10 +279,8 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" -psycopg2-binary = "^2.9.3" +minos-microservice-common = "^0.7.0*" [package.source] type = "directory" @@ -300,7 +296,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -327,15 +323,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -439,11 +435,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -461,7 +457,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "1810729aaeb2889a1550499890e0b5377ddf4f57896bdfbce6023ee2673399cb" +content-hash = "b43594cabd6bbb5636025c9351168e25f8c2e066080128dabe87e8e7cbc1188e" [metadata.files] aiomisc = [ @@ -680,38 +676,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -722,8 +718,8 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, @@ -851,8 +847,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/plugins/minos-database-aiopg/pyproject.toml b/packages/plugins/minos-database-aiopg/pyproject.toml index f98dd1d25..0bb1ef2ae 100644 --- a/packages/plugins/minos-database-aiopg/pyproject.toml +++ b/packages/plugins/minos-database-aiopg/pyproject.toml @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" -minos-microservice-aggregate = "^0.6.0" +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = true } aiopg = "^1.2.1" psycopg2-binary = "^2.9.3" diff --git a/poetry.lock b/poetry.lock index 4f4f02b67..03561d4f8 100644 --- a/poetry.lock +++ b/poetry.lock @@ -539,7 +539,7 @@ python-versions = "*" [[package]] name = "minos-broker-kafka" -version = "0.6.1" +version = "0.7.0.dev1" description = "The kafka plugin of the Minos Framework" category = "main" optional = false @@ -550,8 +550,8 @@ develop = true aiokafka = "^0.7.0" cached-property = "^1.5.2" kafka-python = "^2.0.2" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" [package.source] type = "directory" @@ -559,7 +559,7 @@ url = "packages/plugins/minos-broker-kafka" [[package]] name = "minos-broker-rabbitmq" -version = "0.6.0" +version = "0.7.0.dev1" description = "The rabbitmq plugin of the Minos Framework" category = "main" optional = false @@ -568,16 +568,36 @@ develop = true [package.dependencies] aio-pika = "^7.1.0" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" [package.source] type = "directory" url = "packages/plugins/minos-broker-rabbitmq" +[[package]] +name = "minos-database-aiopg" +version = "0.0.0" +description = "The aiopg plugin of the Minos Framework" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +aiopg = "^1.2.1" +minos-microservice-aggregate = "^0.7.0*" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" +psycopg2-binary = "^2.9.3" + +[package.source] +type = "directory" +url = "packages/plugins/minos-database-aiopg" + [[package]] name = "minos-discovery-kong" -version = "0.1.0a0" +version = "0.7.0.dev1" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" category = "main" optional = false @@ -586,8 +606,8 @@ develop = true [package.dependencies] httpx = "^0.22.0" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" [package.source] type = "directory" @@ -595,7 +615,7 @@ url = "packages/plugins/minos-discovery-kong" [[package]] name = "minos-discovery-minos" -version = "0.6.0" +version = "0.7.0.dev1" description = "The minos-discovery plugin of the Minos Framework" category = "main" optional = false @@ -604,8 +624,8 @@ develop = true [package.dependencies] aiohttp = "^3.8.1" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" [package.source] type = "directory" @@ -613,7 +633,7 @@ url = "packages/plugins/minos-discovery-minos" [[package]] name = "minos-http-aiohttp" -version = "0.6.0" +version = "0.7.0.dev1" description = "The aiohttp plugin of the Minos Framework" category = "main" optional = false @@ -623,8 +643,8 @@ develop = true [package.dependencies] aiohttp = "^3.8.1" cached-property = "^1.5.2" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" orjson = "^3.6.7" [package.source] @@ -633,7 +653,7 @@ url = "packages/plugins/minos-http-aiohttp" [[package]] name = "minos-microservice-aggregate" -version = "0.6.0" +version = "0.7.0.dev1" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -642,9 +662,8 @@ develop = true [package.dependencies] cached-property = "^1.5.2" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" -psycopg2-binary = "^2.9.3" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" [package.source] type = "directory" @@ -652,7 +671,7 @@ url = "packages/core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.1" +version = "0.7.0.dev1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -660,8 +679,7 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiomisc = ">=14.0.3,<16.0.0" -aiopg = "^1.2.1" +aiomisc = ">=14.0.3,<15.8.0" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" @@ -676,7 +694,7 @@ url = "packages/core/minos-microservice-common" [[package]] name = "minos-microservice-cqrs" -version = "0.6.0" +version = "0.7.0.dev1" description = "The CQRS pattern of the Minos Framework" category = "main" optional = false @@ -684,9 +702,9 @@ python-versions = "^3.9" develop = true [package.dependencies] -minos-microservice-aggregate = "^0.6.0" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-aggregate = "^0.7.0*" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" [package.source] type = "directory" @@ -694,7 +712,7 @@ url = "packages/core/minos-microservice-cqrs" [[package]] name = "minos-microservice-networks" -version = "0.6.0" +version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -702,10 +720,8 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiopg = "^1.2.1" crontab = "^0.23.0" -minos-microservice-common = "^0.6.0" -psycopg2-binary = "^2.9.3" +minos-microservice-common = "^0.7.0*" [package.source] type = "directory" @@ -713,7 +729,7 @@ url = "packages/core/minos-microservice-networks" [[package]] name = "minos-microservice-saga" -version = "0.6.0" +version = "0.7.0.dev1" description = "The SAGA pattern of the Minos Framework" category = "main" optional = false @@ -722,9 +738,9 @@ develop = true [package.dependencies] cached-property = "^1.5.2" -minos-microservice-aggregate = "^0.6.0" -minos-microservice-common = "^0.6.0" -minos-microservice-networks = "^0.6.0" +minos-microservice-aggregate = "^0.7.0*" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" [package.source] type = "directory" @@ -764,7 +780,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -811,15 +827,15 @@ python-versions = ">=2.6" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -835,11 +851,11 @@ testing = ["pytest", "pytest-benchmark"] [[package]] name = "pre-commit" -version = "2.17.0" +version = "2.18.1" description = "A framework for managing and maintaining multi-language pre-commit hooks." category = "dev" optional = false -python-versions = ">=3.6.1" +python-versions = ">=3.7" [package.dependencies] cfgv = ">=2.0.0" @@ -891,14 +907,14 @@ python-versions = ">=3.5" [[package]] name = "pyparsing" -version = "3.0.7" -description = "Python parsing module" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.6.8" [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" @@ -1027,18 +1043,18 @@ test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] [[package]] name = "sphinx-autodoc-typehints" -version = "1.17.0" +version = "1.18.1" description = "Type hints (PEP 484) support for the Sphinx autodoc extension" category = "dev" optional = false python-versions = ">=3.7" [package.dependencies] -Sphinx = ">=4" +Sphinx = ">=4.5" [package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] +testing = ["covdefaults (>=2.2)", "coverage (>=6.3)", "diff-cover (>=6.4)", "nptyping (>=2)", "pytest (>=7.1)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=4.1)"] +type_comments = ["typed-ast (>=1.5.2)"] [[package]] name = "sphinx-rtd-theme" @@ -1156,11 +1172,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "urllib3" @@ -1190,7 +1206,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [[package]] name = "virtualenv" -version = "20.14.0" +version = "20.14.1" description = "Virtual Python Environment builder" category = "dev" optional = false @@ -1220,20 +1236,20 @@ multidict = ">=4.0" [[package]] name = "zipp" -version = "3.7.0" +version = "3.8.0" description = "Backport of pathlib-compatible object wrapper for zip files" category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=8.2)", "rst.linker (>=1.9)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy"] +docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.0.1)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "4e102ab779801a2396115a74fff13797e569fe6751d8a5f659331d2e7ff6bbf9" +content-hash = "e1e3295c405de56c506d6a0365be96f8b7b282f16589522940c7a2a50dee7690" [metadata.files] aio-pika = [ @@ -1734,6 +1750,7 @@ mccabe = [ ] minos-broker-kafka = [] minos-broker-rabbitmq = [] +minos-database-aiopg = [] minos-discovery-kong = [] minos-discovery-minos = [] minos-http-aiohttp = [] @@ -1816,38 +1833,38 @@ nodeenv = [ {file = "nodeenv-1.6.0.tar.gz", hash = "sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -1865,16 +1882,16 @@ pbr = [ {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, + {file = "pre_commit-2.18.1-py2.py3-none-any.whl", hash = "sha256:02226e69564ebca1a070bd1f046af866aa1c318dbc430027c50ab832ed2b73f2"}, + {file = "pre_commit-2.18.1.tar.gz", hash = "sha256:5d445ee1fa8738d506881c5d84f83c62bb5be6b2838e32207433647e8e5ebe10"}, ] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, @@ -1951,8 +1968,8 @@ pygments = [ {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, ] pyparsing = [ - {file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"}, - {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, @@ -2022,8 +2039,8 @@ sphinx = [ {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, ] sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, + {file = "sphinx_autodoc_typehints-1.18.1-py3-none-any.whl", hash = "sha256:f8f5bb7c13a9a71537dc2be2eb3b9e28a9711e2454df63587005eacf6fbac453"}, + {file = "sphinx_autodoc_typehints-1.18.1.tar.gz", hash = "sha256:07631c5f0c6641e5ba27143494aefc657e029bed3982138d659250e617f6f929"}, ] sphinx-rtd-theme = [ {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, @@ -2066,8 +2083,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] urllib3 = [ {file = "urllib3-1.26.9-py2.py3-none-any.whl", hash = "sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14"}, @@ -2092,8 +2109,8 @@ uvloop = [ {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, ] virtualenv = [ - {file = "virtualenv-20.14.0-py2.py3-none-any.whl", hash = "sha256:1e8588f35e8b42c6ec6841a13c5e88239de1e6e4e4cedfd3916b306dc826ec66"}, - {file = "virtualenv-20.14.0.tar.gz", hash = "sha256:8e5b402037287126e81ccde9432b95a8be5b19d36584f64957060a3488c11ca8"}, + {file = "virtualenv-20.14.1-py2.py3-none-any.whl", hash = "sha256:e617f16e25b42eb4f6e74096b9c9e37713cf10bf30168fb4a739f3fa8f898a3a"}, + {file = "virtualenv-20.14.1.tar.gz", hash = "sha256:ef589a79795589aada0c1c5b319486797c03b67ac3984c48c669c0e4f50df3a5"}, ] yarl = [ {file = "yarl-1.7.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:f2a8508f7350512434e41065684076f640ecce176d262a7d54f0da41d99c5a95"}, @@ -2170,6 +2187,6 @@ yarl = [ {file = "yarl-1.7.2.tar.gz", hash = "sha256:45399b46d60c253327a460e99856752009fcee5f5d3c80b2f7c0cae1c38d56dd"}, ] zipp = [ - {file = "zipp-3.7.0-py3-none-any.whl", hash = "sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375"}, - {file = "zipp-3.7.0.tar.gz", hash = "sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d"}, + {file = "zipp-3.8.0-py3-none-any.whl", hash = "sha256:c4f6e5bbf48e74f7a38e7cc5b0480ff42b0ae5178957d564d18932525d5cf099"}, + {file = "zipp-3.8.0.tar.gz", hash = "sha256:56bf8aadb83c24db6c4b577e13de374ccfb67da2078beba1d037c17980bf43ad"}, ] diff --git a/pyproject.toml b/pyproject.toml index c7fc20b6c..a4437c649 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -13,6 +13,7 @@ minos-microservice-aggregate = { path = "packages/core/minos-microservice-aggreg minos-microservice-saga = { path = "packages/core/minos-microservice-saga", develop = true } minos-microservice-cqrs = { path = "packages/core/minos-microservice-cqrs", develop = true } minos-broker-kafka = { path = "packages/plugins/minos-broker-kafka", develop = true } +minos-database-aiopg = { path = "packages/plugins/minos-database-aiopg", develop = true } minos-discovery-minos = { path = "packages/plugins/minos-discovery-minos", develop = true } minos-discovery-kong = { path = "packages/plugins/minos-discovery-kong", develop = true } minos-broker-rabbitmq = { path = "packages/plugins/minos-broker-rabbitmq", develop = true } From 4ecea706f7259242c9b98349c22d4009ff4c541a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 11:53:57 +0200 Subject: [PATCH 260/324] ISSUE #99 * Add `minos-database-lmdb` package skeleton --- .../workflows/minos-database-lmdb-publish.yml | 33 + .../workflows/minos-database-lmdb-tests.yml | 49 + .../plugins/minos-database-lmdb/AUTHORS.md | 15 + .../plugins/minos-database-lmdb/HISTORY.md | 2 + packages/plugins/minos-database-lmdb/LICENSE | 21 + packages/plugins/minos-database-lmdb/Makefile | 37 + .../plugins/minos-database-lmdb/README.md | 55 ++ .../minos-database-lmdb/RUNTHETESTS.md | 20 + .../minos/plugins/lmdb/__init__.py | 5 + .../minos/plugins/lmdb/factories/__init__.py | 0 .../plugins/minos-database-lmdb/poetry.lock | 889 ++++++++++++++++++ .../plugins/minos-database-lmdb/poetry.toml | 2 + .../minos-database-lmdb/pyproject.toml | 49 + .../plugins/minos-database-lmdb/setup.cfg | 28 + .../minos-database-lmdb/tests/__init__.py | 0 .../minos-database-lmdb/tests/test_config.yml | 5 + .../tests/test_lmdb/__init__.py | 0 .../test_lmdb/test_factories/__init__.py | 0 .../minos-database-lmdb/tests/utils.py | 88 ++ 19 files changed, 1298 insertions(+) create mode 100644 .github/workflows/minos-database-lmdb-publish.yml create mode 100644 .github/workflows/minos-database-lmdb-tests.yml create mode 100644 packages/plugins/minos-database-lmdb/AUTHORS.md create mode 100644 packages/plugins/minos-database-lmdb/HISTORY.md create mode 100644 packages/plugins/minos-database-lmdb/LICENSE create mode 100644 packages/plugins/minos-database-lmdb/Makefile create mode 100644 packages/plugins/minos-database-lmdb/README.md create mode 100644 packages/plugins/minos-database-lmdb/RUNTHETESTS.md create mode 100644 packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py create mode 100644 packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/__init__.py create mode 100644 packages/plugins/minos-database-lmdb/poetry.lock create mode 100644 packages/plugins/minos-database-lmdb/poetry.toml create mode 100644 packages/plugins/minos-database-lmdb/pyproject.toml create mode 100644 packages/plugins/minos-database-lmdb/setup.cfg create mode 100644 packages/plugins/minos-database-lmdb/tests/__init__.py create mode 100644 packages/plugins/minos-database-lmdb/tests/test_config.yml create mode 100644 packages/plugins/minos-database-lmdb/tests/test_lmdb/__init__.py create mode 100644 packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/__init__.py create mode 100644 packages/plugins/minos-database-lmdb/tests/utils.py diff --git a/.github/workflows/minos-database-lmdb-publish.yml b/.github/workflows/minos-database-lmdb-publish.yml new file mode 100644 index 000000000..fc5721f93 --- /dev/null +++ b/.github/workflows/minos-database-lmdb-publish.yml @@ -0,0 +1,33 @@ +name: "Publish: minos-database-lmdb" + +on: + push: + branches: + - '*.*.x' + paths: + - 'packages/plugins/minos-database-lmdb/**' + +jobs: + deploy: + runs-on: ubuntu-latest + container: python:3.9-buster + defaults: + run: + working-directory: packages/plugins/minos-database-lmdb + + steps: + + - name: Check out repository code + uses: actions/checkout@v2 + + - name: Install Poetry + uses: snok/install-poetry@v1 + + - name: Install dependencies + run: make install + + - name: Publish package + run: make release + env: + POETRY_HTTP_BASIC_PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }} + POETRY_HTTP_BASIC_PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }} diff --git a/.github/workflows/minos-database-lmdb-tests.yml b/.github/workflows/minos-database-lmdb-tests.yml new file mode 100644 index 000000000..85eee5a98 --- /dev/null +++ b/.github/workflows/minos-database-lmdb-tests.yml @@ -0,0 +1,49 @@ +name: "Test: minos-database-lmdb" + +on: + push: + branches: + - main + - '*.*.x' + pull_request: + paths: + - 'packages/plugins/minos-database-lmdb/**' + - 'packages/core/minos-microservice-saga/**' + - 'packages/core/minos-microservice-common/**' + +jobs: + build: + runs-on: ubuntu-latest + container: python:3.9-buster + defaults: + run: + working-directory: packages/plugins/minos-database-lmdb + + steps: + - name: Check out repository code + uses: actions/checkout@v2 + + - name: Install Poetry + uses: snok/install-poetry@v1 + + - name: Install dependencies + run: make install + + - name: Lint package + run: make lint + + - name: Test package with coverage + run: make coverage + + - name: Publish coverage + uses: codecov/codecov-action@v2 + with: + token: ${{ secrets.CODECOV_TOKEN }} + files: ./packages/plugins/minos-database-lmdb/coverage.xml + fail_ci_if_error: true + + - name: Generate documentation + run: make docs + + - name: Generate build + run: make dist diff --git a/packages/plugins/minos-database-lmdb/AUTHORS.md b/packages/plugins/minos-database-lmdb/AUTHORS.md new file mode 100644 index 000000000..30ff94991 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/AUTHORS.md @@ -0,0 +1,15 @@ +# Credits + +## Development Lead + +* Andrea Mucci + +## Core Devs + +* Sergio Garcia Prado +* Vladyslav Fenchak +* Alberto Amigo Alonso + +## Contributors + +None yet. Why not be the first? diff --git a/packages/plugins/minos-database-lmdb/HISTORY.md b/packages/plugins/minos-database-lmdb/HISTORY.md new file mode 100644 index 000000000..e0e57d3b3 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/HISTORY.md @@ -0,0 +1,2 @@ +# History + diff --git a/packages/plugins/minos-database-lmdb/LICENSE b/packages/plugins/minos-database-lmdb/LICENSE new file mode 100644 index 000000000..4daf85bf2 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2021 Clariteia + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/packages/plugins/minos-database-lmdb/Makefile b/packages/plugins/minos-database-lmdb/Makefile new file mode 100644 index 000000000..2016f9e38 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/Makefile @@ -0,0 +1,37 @@ +.PHONY: docs + +lint: + poetry run flake8 + +test: + poetry run pytest + +coverage: + poetry run coverage run -m pytest + poetry run coverage report -m + poetry run coverage xml + +reformat: + poetry run black --line-length 120 minos tests + poetry run isort minos tests + +release: + $(MAKE) dist + poetry publish + +dist: + poetry build + ls -l dist + +install: + poetry install + +update: + poetry update + +check: + $(MAKE) install + $(MAKE) reformat + $(MAKE) lint + $(MAKE) test + $(MAKE) dist diff --git a/packages/plugins/minos-database-lmdb/README.md b/packages/plugins/minos-database-lmdb/README.md new file mode 100644 index 000000000..97d6019de --- /dev/null +++ b/packages/plugins/minos-database-lmdb/README.md @@ -0,0 +1,55 @@ +

+ Minos logo +

+ +## minos-database-lmdb + +[![PyPI Latest Release](https://img.shields.io/pypi/v/minos-database-lmdb.svg)](https://pypi.org/project/minos-database-lmdb/) +[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://minos-framework.github.io/minos-python) +[![License](https://img.shields.io/github/license/minos-framework/minos-python.svg)](https://github.com/minos-framework/minos-python/blob/main/LICENSE) +[![Coverage](https://codecov.io/github/minos-framework/minos-python/coverage.svg?branch=main)](https://codecov.io/gh/minos-framework/minos-python) +[![Stack Overflow](https://img.shields.io/badge/Stack%20Overflow-Ask%20a%20question-green)](https://stackoverflow.com/questions/tagged/minos) + +## Summary + +Minos is a framework which helps you create [reactive](https://www.reactivemanifesto.org/) microservices in Python. Internally, it leverages Event Sourcing, CQRS and a message driven architecture to fulfil the commitments of an asynchronous environment. + +## Installation + +Install the dependency: + +```shell +pip install minos-database-lmdb +``` + +Set the database client on the `config.yml` file: + +```yaml +... +databases: + foobar: + client: minos.plugins.lmdb.LmdbDatabaseClient + path: "./foobar.lmdb" + ... +... +``` + +## Documentation + +The official API Reference is publicly available at the [GitHub Pages](https://minos-framework.github.io/minos-python). + +## Source Code + +The source code of this project is hosted at the [GitHub Repository](https://github.com/minos-framework/minos-python). + +## Getting Help + +For usage questions, the best place to go to is [StackOverflow](https://stackoverflow.com/questions/tagged/minos). + +## Discussion and Development + +Most development discussions take place over the [GitHub Issues](https://github.com/minos-framework/minos-python/issues). In addition, a [Gitter channel](https://gitter.im/minos-framework/community) is available for development-related questions. + +## License + +This project is distributed under the [MIT](https://raw.githubusercontent.com/minos-framework/minos-python/main/LICENSE) license. diff --git a/packages/plugins/minos-database-lmdb/RUNTHETESTS.md b/packages/plugins/minos-database-lmdb/RUNTHETESTS.md new file mode 100644 index 000000000..386e2b0e7 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/RUNTHETESTS.md @@ -0,0 +1,20 @@ +# Run the tests + +In order to run the tests, please make sure you have the `Docker Engine `_ +and `Docker Compose `_ installed. + +Move into tests/ directory + +`cd tests/` + +Run service dependencies: + +`docker-compose up -d` + +Install library dependencies: + +`make install` + +Run tests: + +`make test` diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py new file mode 100644 index 000000000..b72319b08 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py @@ -0,0 +1,5 @@ +"""The lmdb plugin of the Minos Framework.""" + +__author__ = "Minos Framework Devs" +__email__ = "hey@minos.run" +__version__ = "0.0.0" diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/__init__.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-lmdb/poetry.lock b/packages/plugins/minos-database-lmdb/poetry.lock new file mode 100644 index 000000000..d5ee172aa --- /dev/null +++ b/packages/plugins/minos-database-lmdb/poetry.lock @@ -0,0 +1,889 @@ +[[package]] +name = "aiomisc" +version = "15.7.3" +description = "aiomisc - miscellaneous utils for asyncio" +category = "main" +optional = false +python-versions = "*" + +[package.dependencies] +colorlog = "*" + +[package.extras] +aiohttp = ["aiohttp"] +asgi = ["aiohttp-asgi"] +carbon = ["aiocarbon (>=0.15,<1.0)"] +contextvars = ["contextvars (>=2.4,<3.0)"] +cron = ["croniter (>=0.3.34,<0.4.0)"] +develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-timeout", "coveralls", "croniter (>=0.3.34,<0.4.0)", "fastapi", "freezegun (<1.1)", "mypy (>=0.782,<1.0)", "pylava", "pytest", "pytest-cov (>=3.0,<4.0)", "pytest-freezegun (>=0.4.2,<0.5.0)", "pytest-rst", "pytest-subtests", "rich", "setproctitle", "sphinx-autobuild", "sphinx-intl", "sphinx (>=3.5.1)", "timeout-decorator", "tox (>=2.4)", "types-croniter"] +raven = ["raven-aiohttp"] +uvloop = ["uvloop (>=0.14,<1)"] + +[[package]] +name = "aiopg" +version = "1.3.3" +description = "Postgres integration with asyncio." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +async-timeout = ">=3.0,<5.0" +psycopg2-binary = ">=2.8.4" + +[package.extras] +sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] + +[[package]] +name = "async-timeout" +version = "4.0.2" +description = "Timeout context manager for asyncio programs" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "atomicwrites" +version = "1.4.0" +description = "Atomic file writes." +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" + +[[package]] +name = "attrs" +version = "21.4.0" +description = "Classes Without Boilerplate" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[package.extras] +dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] +docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] +tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] +tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "six", "mypy", "pytest-mypy-plugins", "cloudpickle"] + +[[package]] +name = "black" +version = "22.3.0" +description = "The uncompromising code formatter." +category = "dev" +optional = false +python-versions = ">=3.6.2" + +[package.dependencies] +click = ">=8.0.0" +mypy-extensions = ">=0.4.3" +pathspec = ">=0.9.0" +platformdirs = ">=2" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} +typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} + +[package.extras] +colorama = ["colorama (>=0.4.3)"] +d = ["aiohttp (>=3.7.4)"] +jupyter = ["ipython (>=7.8.0)", "tokenize-rt (>=3.2.0)"] +uvloop = ["uvloop (>=0.15.2)"] + +[[package]] +name = "cached-property" +version = "1.5.2" +description = "A decorator for caching properties in classes." +category = "main" +optional = false +python-versions = "*" + +[[package]] +name = "click" +version = "8.1.2" +description = "Composable command line interface toolkit" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} + +[[package]] +name = "colorama" +version = "0.4.4" +description = "Cross-platform colored terminal text." +category = "main" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "colorlog" +version = "6.6.0" +description = "Add colours to the output of Python's logging module." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +colorama = {version = "*", markers = "sys_platform == \"win32\""} + +[package.extras] +development = ["black", "flake8", "mypy", "pytest", "types-colorama"] + +[[package]] +name = "coverage" +version = "6.3.2" +description = "Code coverage measurement for Python" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.extras] +toml = ["tomli"] + +[[package]] +name = "crontab" +version = "0.23.0" +description = "Parse and use crontab schedules in Python" +category = "main" +optional = false +python-versions = "*" + +[[package]] +name = "dependency-injector" +version = "4.39.1" +description = "Dependency injection framework for Python" +category = "main" +optional = false +python-versions = "*" + +[package.dependencies] +six = ">=1.7.0,<=1.16.0" + +[package.extras] +aiohttp = ["aiohttp"] +flask = ["flask"] +pydantic = ["pydantic"] +yaml = ["pyyaml"] + +[[package]] +name = "fastavro" +version = "1.4.10" +description = "Fast read/write of AVRO files" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.extras] +codecs = ["python-snappy", "zstandard", "lz4"] +lz4 = ["lz4"] +snappy = ["python-snappy"] +zstandard = ["zstandard"] + +[[package]] +name = "flake8" +version = "4.0.1" +description = "the modular source code checker: pep8 pyflakes and co" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +mccabe = ">=0.6.0,<0.7.0" +pycodestyle = ">=2.8.0,<2.9.0" +pyflakes = ">=2.4.0,<2.5.0" + +[[package]] +name = "iniconfig" +version = "1.1.1" +description = "iniconfig: brain-dead simple config-ini parsing" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "isort" +version = "5.10.1" +description = "A Python utility / library to sort Python imports." +category = "dev" +optional = false +python-versions = ">=3.6.1,<4.0" + +[package.extras] +pipfile_deprecated_finder = ["pipreqs", "requirementslib"] +requirements_deprecated_finder = ["pipreqs", "pip-api"] +colors = ["colorama (>=0.4.3,<0.5.0)"] +plugins = ["setuptools"] + +[[package]] +name = "lmdb" +version = "1.3.0" +description = "Universal Python binding for the LMDB 'Lightning' Database" +category = "main" +optional = false +python-versions = "*" + +[[package]] +name = "mccabe" +version = "0.6.1" +description = "McCabe checker, plugin for flake8" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "minos-microservice-aggregate" +version = "0.7.0.dev1" +description = "The Aggregate pattern of the Minos Framework" +category = "main" +optional = false +python-versions = ">=3.9,<4.0" + +[package.dependencies] +cached-property = ">=1.5.2,<2.0.0" +minos-microservice-common = "*" +minos-microservice-networks = "*" +psycopg2-binary = ">=2.9.3,<3.0.0" + +[[package]] +name = "minos-microservice-common" +version = "0.7.0.dev1" +description = "The common core of the Minos Framework" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +aiomisc = ">=14.0.3,<15.8.0" +cached-property = "^1.5.2" +dependency-injector = "^4.32.2" +fastavro = "^1.4.0" +lmdb = "^1.2.1" +orjson = "^3.5.2" +PyYAML = ">=5.4.1,<7.0.0" +uvloop = "^0.16.0" + +[package.source] +type = "directory" +url = "../../core/minos-microservice-common" + +[[package]] +name = "minos-microservice-networks" +version = "0.7.0.dev1" +description = "The networks core of the Minos Framework" +category = "main" +optional = false +python-versions = ">=3.9,<4.0" + +[package.dependencies] +aiopg = ">=1.2.1,<2.0.0" +crontab = ">=0.23.0,<0.24.0" +minos-microservice-common = "*" +psycopg2-binary = ">=2.9.3,<3.0.0" + +[[package]] +name = "minos-microservice-saga" +version = "0.7.0.dev1" +description = "The SAGA pattern of the Minos Framework" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +cached-property = "^1.5.2" +minos-microservice-aggregate = "^0.7.0*" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" + +[package.source] +type = "directory" +url = "../../core/minos-microservice-saga" + +[[package]] +name = "mypy-extensions" +version = "0.4.3" +description = "Experimental type system extensions for programs checked with the mypy typechecker." +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "orjson" +version = "3.6.8" +description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" +category = "main" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "packaging" +version = "21.3" +description = "Core utilities for Python packages" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" + +[[package]] +name = "pathspec" +version = "0.9.0" +description = "Utility library for gitignore style pattern matching of file paths." +category = "dev" +optional = false +python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" + +[[package]] +name = "platformdirs" +version = "2.5.2" +description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.extras] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] + +[[package]] +name = "pluggy" +version = "1.0.0" +description = "plugin and hook calling mechanisms for python" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.extras] +dev = ["pre-commit", "tox"] +testing = ["pytest", "pytest-benchmark"] + +[[package]] +name = "psycopg2-binary" +version = "2.9.3" +description = "psycopg2 - Python-PostgreSQL Database Adapter" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "py" +version = "1.11.0" +description = "library with cross-python path, ini-parsing, io, code, log facilities" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "pycodestyle" +version = "2.8.0" +description = "Python style guide checker" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "pyflakes" +version = "2.4.0" +description = "passive checker of Python programs" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" + +[[package]] +name = "pyparsing" +version = "3.0.8" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" +category = "dev" +optional = false +python-versions = ">=3.6.8" + +[package.extras] +diagrams = ["railroad-diagrams", "jinja2"] + +[[package]] +name = "pytest" +version = "7.1.1" +description = "pytest: simple powerful testing with Python" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +atomicwrites = {version = ">=1.0", markers = "sys_platform == \"win32\""} +attrs = ">=19.2.0" +colorama = {version = "*", markers = "sys_platform == \"win32\""} +iniconfig = "*" +packaging = "*" +pluggy = ">=0.12,<2.0" +py = ">=1.8.2" +tomli = ">=1.0.0" + +[package.extras] +testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2.7.2)", "requests", "xmlschema"] + +[[package]] +name = "pyyaml" +version = "6.0" +description = "YAML parser and emitter for Python" +category = "main" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "six" +version = "1.16.0" +description = "Python 2 and 3 compatibility utilities" +category = "main" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" + +[[package]] +name = "tomli" +version = "2.0.1" +description = "A lil' TOML parser" +category = "dev" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "typing-extensions" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" +category = "dev" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "uvloop" +version = "0.16.0" +description = "Fast implementation of asyncio event loop on top of libuv" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.extras] +dev = ["Cython (>=0.29.24,<0.30.0)", "pytest (>=3.6.0)", "Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)", "aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] +docs = ["Sphinx (>=4.1.2,<4.2.0)", "sphinxcontrib-asyncio (>=0.3.0,<0.4.0)", "sphinx-rtd-theme (>=0.5.2,<0.6.0)"] +test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,<2.8.0)", "pyOpenSSL (>=19.0.0,<19.1.0)", "mypy (>=0.800)"] + +[metadata] +lock-version = "1.1" +python-versions = "^3.9" +content-hash = "e5afbafb18fd7321396f685b06978dd1181179b0fd8bf0b1ef41ff0d969ca798" + +[metadata.files] +aiomisc = [ + {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, + {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, +] +aiopg = [ + {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, + {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, +] +async-timeout = [ + {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, + {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, +] +atomicwrites = [ + {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, + {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, +] +attrs = [ + {file = "attrs-21.4.0-py2.py3-none-any.whl", hash = "sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4"}, + {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, +] +black = [ + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, +] +cached-property = [ + {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, + {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, +] +click = [ + {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, + {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, +] +colorama = [ + {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, + {file = "colorama-0.4.4.tar.gz", hash = "sha256:5941b2b48a20143d2267e95b1c2a7603ce057ee39fd88e7329b0c292aa16869b"}, +] +colorlog = [ + {file = "colorlog-6.6.0-py2.py3-none-any.whl", hash = "sha256:351c51e866c86c3217f08e4b067a7974a678be78f07f85fc2d55b8babde6d94e"}, + {file = "colorlog-6.6.0.tar.gz", hash = "sha256:344f73204009e4c83c5b6beb00b3c45dc70fcdae3c80db919e0a4171d006fde8"}, +] +coverage = [ + {file = "coverage-6.3.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:9b27d894748475fa858f9597c0ee1d4829f44683f3813633aaf94b19cb5453cf"}, + {file = "coverage-6.3.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:37d1141ad6b2466a7b53a22e08fe76994c2d35a5b6b469590424a9953155afac"}, + {file = "coverage-6.3.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f9987b0354b06d4df0f4d3e0ec1ae76d7ce7cbca9a2f98c25041eb79eec766f1"}, + {file = "coverage-6.3.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:26e2deacd414fc2f97dd9f7676ee3eaecd299ca751412d89f40bc01557a6b1b4"}, + {file = "coverage-6.3.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4dd8bafa458b5c7d061540f1ee9f18025a68e2d8471b3e858a9dad47c8d41903"}, + {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:46191097ebc381fbf89bdce207a6c107ac4ec0890d8d20f3360345ff5976155c"}, + {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:6f89d05e028d274ce4fa1a86887b071ae1755082ef94a6740238cd7a8178804f"}, + {file = "coverage-6.3.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:58303469e9a272b4abdb9e302a780072c0633cdcc0165db7eec0f9e32f901e05"}, + {file = "coverage-6.3.2-cp310-cp310-win32.whl", hash = "sha256:2fea046bfb455510e05be95e879f0e768d45c10c11509e20e06d8fcaa31d9e39"}, + {file = "coverage-6.3.2-cp310-cp310-win_amd64.whl", hash = "sha256:a2a8b8bcc399edb4347a5ca8b9b87e7524c0967b335fbb08a83c8421489ddee1"}, + {file = "coverage-6.3.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:f1555ea6d6da108e1999b2463ea1003fe03f29213e459145e70edbaf3e004aaa"}, + {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e5f4e1edcf57ce94e5475fe09e5afa3e3145081318e5fd1a43a6b4539a97e518"}, + {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7a15dc0a14008f1da3d1ebd44bdda3e357dbabdf5a0b5034d38fcde0b5c234b7"}, + {file = "coverage-6.3.2-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:21b7745788866028adeb1e0eca3bf1101109e2dc58456cb49d2d9b99a8c516e6"}, + {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:8ce257cac556cb03be4a248d92ed36904a59a4a5ff55a994e92214cde15c5bad"}, + {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:b0be84e5a6209858a1d3e8d1806c46214e867ce1b0fd32e4ea03f4bd8b2e3359"}, + {file = "coverage-6.3.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:acf53bc2cf7282ab9b8ba346746afe703474004d9e566ad164c91a7a59f188a4"}, + {file = "coverage-6.3.2-cp37-cp37m-win32.whl", hash = "sha256:8bdde1177f2311ee552f47ae6e5aa7750c0e3291ca6b75f71f7ffe1f1dab3dca"}, + {file = "coverage-6.3.2-cp37-cp37m-win_amd64.whl", hash = "sha256:b31651d018b23ec463e95cf10070d0b2c548aa950a03d0b559eaa11c7e5a6fa3"}, + {file = "coverage-6.3.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:07e6db90cd9686c767dcc593dff16c8c09f9814f5e9c51034066cad3373b914d"}, + {file = "coverage-6.3.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:2c6dbb42f3ad25760010c45191e9757e7dce981cbfb90e42feef301d71540059"}, + {file = "coverage-6.3.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c76aeef1b95aff3905fb2ae2d96e319caca5b76fa41d3470b19d4e4a3a313512"}, + {file = "coverage-6.3.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:8cf5cfcb1521dc3255d845d9dca3ff204b3229401994ef8d1984b32746bb45ca"}, + {file = "coverage-6.3.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8fbbdc8d55990eac1b0919ca69eb5a988a802b854488c34b8f37f3e2025fa90d"}, + {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ec6bc7fe73a938933d4178c9b23c4e0568e43e220aef9472c4f6044bfc6dd0f0"}, + {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:9baff2a45ae1f17c8078452e9e5962e518eab705e50a0aa8083733ea7d45f3a6"}, + {file = "coverage-6.3.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:fd9e830e9d8d89b20ab1e5af09b32d33e1a08ef4c4e14411e559556fd788e6b2"}, + {file = "coverage-6.3.2-cp38-cp38-win32.whl", hash = "sha256:f7331dbf301b7289013175087636bbaf5b2405e57259dd2c42fdcc9fcc47325e"}, + {file = "coverage-6.3.2-cp38-cp38-win_amd64.whl", hash = "sha256:68353fe7cdf91f109fc7d474461b46e7f1f14e533e911a2a2cbb8b0fc8613cf1"}, + {file = "coverage-6.3.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b78e5afb39941572209f71866aa0b206c12f0109835aa0d601e41552f9b3e620"}, + {file = "coverage-6.3.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:4e21876082ed887baed0146fe222f861b5815455ada3b33b890f4105d806128d"}, + {file = "coverage-6.3.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:34626a7eee2a3da12af0507780bb51eb52dca0e1751fd1471d0810539cefb536"}, + {file = "coverage-6.3.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1ebf730d2381158ecf3dfd4453fbca0613e16eaa547b4170e2450c9707665ce7"}, + {file = "coverage-6.3.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dd6fe30bd519694b356cbfcaca9bd5c1737cddd20778c6a581ae20dc8c04def2"}, + {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:96f8a1cb43ca1422f36492bebe63312d396491a9165ed3b9231e778d43a7fca4"}, + {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:dd035edafefee4d573140a76fdc785dc38829fe5a455c4bb12bac8c20cfc3d69"}, + {file = "coverage-6.3.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:5ca5aeb4344b30d0bec47481536b8ba1181d50dbe783b0e4ad03c95dc1296684"}, + {file = "coverage-6.3.2-cp39-cp39-win32.whl", hash = "sha256:f5fa5803f47e095d7ad8443d28b01d48c0359484fec1b9d8606d0e3282084bc4"}, + {file = "coverage-6.3.2-cp39-cp39-win_amd64.whl", hash = "sha256:9548f10d8be799551eb3a9c74bbf2b4934ddb330e08a73320123c07f95cc2d92"}, + {file = "coverage-6.3.2-pp36.pp37.pp38-none-any.whl", hash = "sha256:18d520c6860515a771708937d2f78f63cc47ab3b80cb78e86573b0a760161faf"}, + {file = "coverage-6.3.2.tar.gz", hash = "sha256:03e2a7826086b91ef345ff18742ee9fc47a6839ccd517061ef8fa1976e652ce9"}, +] +crontab = [ + {file = "crontab-0.23.0.tar.gz", hash = "sha256:ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733"}, +] +dependency-injector = [ + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, +] +fastavro = [ + {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, + {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, + {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, + {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, + {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, + {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, + {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, + {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, + {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, + {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, + {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, + {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, + {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, + {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, + {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, + {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, +] +flake8 = [ + {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, + {file = "flake8-4.0.1.tar.gz", hash = "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"}, +] +iniconfig = [ + {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, + {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, +] +isort = [ + {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, + {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, +] +lmdb = [ + {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, + {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, + {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, + {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, + {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, + {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, + {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, + {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, + {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, + {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, + {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, + {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, + {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, + {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, + {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, + {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, + {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, + {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, + {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, + {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, + {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, + {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, + {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, + {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, + {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, + {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, + {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, +] +mccabe = [ + {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, + {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, +] +minos-microservice-aggregate = [ + {file = "minos-microservice-aggregate-0.7.0.dev1.tar.gz", hash = "sha256:b67fa15603c2d72e4d83ebcd9ec3fc08102bdd5d5657dc7d1c816888abdabd38"}, + {file = "minos_microservice_aggregate-0.7.0.dev1-py3-none-any.whl", hash = "sha256:dc93c1a0b246f204047be9ddb427fe20ebb40f2ee2bb097cc99d444e64430c20"}, +] +minos-microservice-common = [] +minos-microservice-networks = [ + {file = "minos-microservice-networks-0.7.0.dev1.tar.gz", hash = "sha256:1bead5cde921405627327166b5f318565f18a5cc517043391931b940e46328b1"}, + {file = "minos_microservice_networks-0.7.0.dev1-py3-none-any.whl", hash = "sha256:f39daca1ebd1b698ce0dc29f66e00c28dc27ae9dd06c1982df8b90ead92230d1"}, +] +minos-microservice-saga = [] +mypy-extensions = [ + {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, + {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, +] +orjson = [ + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, +] +packaging = [ + {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, + {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, +] +pathspec = [ + {file = "pathspec-0.9.0-py2.py3-none-any.whl", hash = "sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a"}, + {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, +] +platformdirs = [ + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, +] +pluggy = [ + {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, + {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, +] +psycopg2-binary = [ + {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, + {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, + {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, + {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, + {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, + {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, +] +py = [ + {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, + {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, +] +pycodestyle = [ + {file = "pycodestyle-2.8.0-py2.py3-none-any.whl", hash = "sha256:720f8b39dde8b293825e7ff02c475f3077124006db4f440dcbc9a20b76548a20"}, + {file = "pycodestyle-2.8.0.tar.gz", hash = "sha256:eddd5847ef438ea1c7870ca7eb78a9d47ce0cdb4851a5523949f2601d0cbbe7f"}, +] +pyflakes = [ + {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, + {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, +] +pyparsing = [ + {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, + {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, +] +pytest = [ + {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, + {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, +] +pyyaml = [ + {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, + {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, + {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, + {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4"}, + {file = "PyYAML-6.0-cp36-cp36m-win32.whl", hash = "sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293"}, + {file = "PyYAML-6.0-cp36-cp36m-win_amd64.whl", hash = "sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57"}, + {file = "PyYAML-6.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9"}, + {file = "PyYAML-6.0-cp37-cp37m-win32.whl", hash = "sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737"}, + {file = "PyYAML-6.0-cp37-cp37m-win_amd64.whl", hash = "sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d"}, + {file = "PyYAML-6.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287"}, + {file = "PyYAML-6.0-cp38-cp38-win32.whl", hash = "sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78"}, + {file = "PyYAML-6.0-cp38-cp38-win_amd64.whl", hash = "sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0"}, + {file = "PyYAML-6.0-cp39-cp39-win32.whl", hash = "sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb"}, + {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, + {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, +] +six = [ + {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, + {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, +] +tomli = [ + {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, + {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, +] +typing-extensions = [ + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, +] +uvloop = [ + {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, + {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:30ba9dcbd0965f5c812b7c2112a1ddf60cf904c1c160f398e7eed3a6b82dcd9c"}, + {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:bd53f7f5db562f37cd64a3af5012df8cac2c464c97e732ed556800129505bd64"}, + {file = "uvloop-0.16.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:772206116b9b57cd625c8a88f2413df2fcfd0b496eb188b82a43bed7af2c2ec9"}, + {file = "uvloop-0.16.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:b572256409f194521a9895aef274cea88731d14732343da3ecdb175228881638"}, + {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:04ff57aa137230d8cc968f03481176041ae789308b4d5079118331ab01112450"}, + {file = "uvloop-0.16.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3a19828c4f15687675ea912cc28bbcb48e9bb907c801873bd1519b96b04fb805"}, + {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e814ac2c6f9daf4c36eb8e85266859f42174a4ff0d71b99405ed559257750382"}, + {file = "uvloop-0.16.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:bd8f42ea1ea8f4e84d265769089964ddda95eb2bb38b5cbe26712b0616c3edee"}, + {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:647e481940379eebd314c00440314c81ea547aa636056f554d491e40503c8464"}, + {file = "uvloop-0.16.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e0d26fa5875d43ddbb0d9d79a447d2ace4180d9e3239788208527c4784f7cab"}, + {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:6ccd57ae8db17d677e9e06192e9c9ec4bd2066b77790f9aa7dede2cc4008ee8f"}, + {file = "uvloop-0.16.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:089b4834fd299d82d83a25e3335372f12117a7d38525217c2258e9b9f4578897"}, + {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98d117332cc9e5ea8dfdc2b28b0a23f60370d02e1395f88f40d1effd2cb86c4f"}, + {file = "uvloop-0.16.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1e5f2e2ff51aefe6c19ee98af12b4ae61f5be456cd24396953244a30880ad861"}, + {file = "uvloop-0.16.0.tar.gz", hash = "sha256:f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228"}, +] diff --git a/packages/plugins/minos-database-lmdb/poetry.toml b/packages/plugins/minos-database-lmdb/poetry.toml new file mode 100644 index 000000000..ab1033bd3 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/poetry.toml @@ -0,0 +1,2 @@ +[virtualenvs] +in-project = true diff --git a/packages/plugins/minos-database-lmdb/pyproject.toml b/packages/plugins/minos-database-lmdb/pyproject.toml new file mode 100644 index 000000000..a16db1303 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/pyproject.toml @@ -0,0 +1,49 @@ +[tool.poetry] +name = "minos-database-lmdb" +version = "0.0.0" +description = "The lmdb plugin of the Minos Framework" +readme = "README.md" +repository = "https://github.com/minos-framework/minos-python" +homepage = "https://www.minos.run/" +authors = ["Minos Framework Devs "] +license = "MIT" +classifiers = [ + "Development Status :: 4 - Beta", + "Intended Audience :: Developers", + "Natural Language :: English", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3.9", +] +keywords = [ + "clariteia", + "minos", + "microservice", + "saga", +] +packages = [ + { include = "minos" } +] +include = [ + "AUTHORS.md", + "HISTORY.md", + "LICENSE", +] + +[tool.poetry.dependencies] +python = "^3.9" +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-saga = { version ="^0.7.0*", allow-prereleases = true } +lmdb = "^1.2.1" + +[tool.poetry.dev-dependencies] +minos-microservice-common = { path = "../../core/minos-microservice-common", develop = true } +minos-microservice-saga = { path = "../../core/minos-microservice-saga", develop = true } +black = "^22.3" +isort = "^5.8.0" +pytest = "^7.0.1" +coverage = "^6.3" +flake8 = "^4.0.1" + +[build-system] +requires = ["poetry-core>=1.0.0"] +build-backend = "poetry.core.masonry.api" diff --git a/packages/plugins/minos-database-lmdb/setup.cfg b/packages/plugins/minos-database-lmdb/setup.cfg new file mode 100644 index 000000000..dbb9ac849 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/setup.cfg @@ -0,0 +1,28 @@ +[coverage:run] +source = + minos + +[coverage:report] +exclude_lines = + pragma: no cover + raise NotImplementedError + if TYPE_CHECKING: + pass +precision = 2 + +[flake8] +filename = + ./minos/**/*.py, + ./tests/**/*.py, + ./examples/**/*.py +max-line-length = 120 +per-file-ignores = + ./**/__init__.py:F401,W391 + +[isort] +known_first_party=minos +multi_line_output = 3 +include_trailing_comma = True +force_grid_wrap = 1 +use_parentheses = True +line_length = 120 diff --git a/packages/plugins/minos-database-lmdb/tests/__init__.py b/packages/plugins/minos-database-lmdb/tests/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-lmdb/tests/test_config.yml b/packages/plugins/minos-database-lmdb/tests/test_config.yml new file mode 100644 index 000000000..7ac6b848f --- /dev/null +++ b/packages/plugins/minos-database-lmdb/tests/test_config.yml @@ -0,0 +1,5 @@ +version: 2 +databases: + foobar: + client: minos.plugins.lmdb.LmdbDatabaseClient + path: "./foobar.lmdb" \ No newline at end of file diff --git a/packages/plugins/minos-database-lmdb/tests/test_lmdb/__init__.py b/packages/plugins/minos-database-lmdb/tests/test_lmdb/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/__init__.py b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-lmdb/tests/utils.py b/packages/plugins/minos-database-lmdb/tests/utils.py new file mode 100644 index 000000000..b2b080c94 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/tests/utils.py @@ -0,0 +1,88 @@ +from pathlib import ( + Path, +) + +from minos.aggregate import ( + InMemoryEventRepository, + InMemorySnapshotRepository, + InMemoryTransactionRepository, +) +from minos.common import ( + DatabaseClientPool, + Lock, + LockPool, + PoolFactory, +) +from minos.common.testing import ( + DatabaseMinosTestCase, +) +from minos.networks import ( + BrokerClientPool, + InMemoryBrokerPublisher, + InMemoryBrokerSubscriberBuilder, +) + +BASE_PATH = Path(__file__).parent +CONFIG_FILE_PATH = BASE_PATH / "test_config.yml" + + +class LmdbTestCase(DatabaseMinosTestCase): + def get_config_file_path(self) -> Path: + return CONFIG_FILE_PATH + + def get_injections(self): + pool_factory = PoolFactory.from_config( + self.config, + default_classes={ + "broker": BrokerClientPool, + "lock": FakeLockPool, + "database": DatabaseClientPool, + }, + ) + broker_publisher = InMemoryBrokerPublisher() + broker_subscriber_builder = InMemoryBrokerSubscriberBuilder() + transaction_repository = InMemoryTransactionRepository( + lock_pool=pool_factory.get_pool("lock"), + ) + event_repository = InMemoryEventRepository( + broker_publisher=broker_publisher, + transaction_repository=transaction_repository, + lock_pool=pool_factory.get_pool("lock"), + ) + snapshot_repository = InMemorySnapshotRepository( + event_repository=event_repository, + transaction_repository=transaction_repository, + ) + return [ + pool_factory, + broker_publisher, + broker_subscriber_builder, + transaction_repository, + event_repository, + snapshot_repository, + ] + + +class FakeLock(Lock): + """For testing purposes.""" + + def __init__(self, key=None, *args, **kwargs): + if key is None: + key = "fake" + super().__init__(key, *args, **kwargs) + + async def acquire(self) -> None: + """For testing purposes.""" + + async def release(self): + """For testing purposes.""" + + +class FakeLockPool(LockPool): + """For testing purposes.""" + + async def _create_instance(self): + return FakeLock() + + async def _destroy_instance(self, instance) -> None: + """For testing purposes.""" From c29325bcfa21fe3731643025062362d4805550ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 12:07:46 +0200 Subject: [PATCH 261/324] ISSUE #99 * Add `minos-database-lmdb` classes skeleton --- .../minos/saga/__init__.py | 1 + .../minos/saga/executions/__init__.py | 3 + .../saga/executions/database/__init__.py | 3 + .../saga/executions/database/factories.py | 11 ++ .../minos/plugins/lmdb/__init__.py | 10 ++ .../minos/plugins/lmdb/clients.py | 25 ++++ .../minos/plugins/lmdb/factories/__init__.py | 3 + .../plugins/lmdb/factories/saga/__init__.py | 3 + .../plugins/lmdb/factories/saga/executions.py | 7 + .../minos/plugins/lmdb/operations.py | 7 + .../plugins/minos-database-lmdb/poetry.lock | 136 +++--------------- .../minos-database-lmdb/pyproject.toml | 2 + .../tests/test_lmdb/test_clients.py | 17 +++ 13 files changed, 112 insertions(+), 116 deletions(-) create mode 100644 packages/core/minos-microservice-saga/minos/saga/executions/database/__init__.py create mode 100644 packages/core/minos-microservice-saga/minos/saga/executions/database/factories.py create mode 100644 packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py create mode 100644 packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/__init__.py create mode 100644 packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py create mode 100644 packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py create mode 100644 packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py diff --git a/packages/core/minos-microservice-saga/minos/saga/__init__.py b/packages/core/minos-microservice-saga/minos/saga/__init__.py index c424053b1..4fb7e1814 100644 --- a/packages/core/minos-microservice-saga/minos/saga/__init__.py +++ b/packages/core/minos-microservice-saga/minos/saga/__init__.py @@ -53,6 +53,7 @@ RequestExecutor, ResponseExecutor, SagaExecution, + SagaExecutionDatabaseOperationFactory, SagaExecutionStorage, SagaStatus, SagaStepExecution, diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/__init__.py b/packages/core/minos-microservice-saga/minos/saga/executions/__init__.py index 2080ae9f9..167dd4134 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/__init__.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/__init__.py @@ -1,6 +1,9 @@ from .commit import ( TransactionCommitter, ) +from .database import ( + SagaExecutionDatabaseOperationFactory, +) from .executors import ( Executor, LocalExecutor, diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/database/__init__.py b/packages/core/minos-microservice-saga/minos/saga/executions/database/__init__.py new file mode 100644 index 000000000..28e96babc --- /dev/null +++ b/packages/core/minos-microservice-saga/minos/saga/executions/database/__init__.py @@ -0,0 +1,3 @@ +from .factories import ( + SagaExecutionDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/database/factories.py b/packages/core/minos-microservice-saga/minos/saga/executions/database/factories.py new file mode 100644 index 000000000..1d6caad28 --- /dev/null +++ b/packages/core/minos-microservice-saga/minos/saga/executions/database/factories.py @@ -0,0 +1,11 @@ +from abc import ( + ABC, +) + +from minos.common import ( + DatabaseOperationFactory, +) + + +class SagaExecutionDatabaseOperationFactory(DatabaseOperationFactory, ABC): + """TODO""" diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py index b72319b08..b8ffc4a15 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py @@ -3,3 +3,13 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.0.0" + +from .clients import ( + LmdbDatabaseClient, +) +from .factories import ( + LmdbSagaExecutionDatabaseOperationFactory, +) +from .operations import ( + LmdbDatabaseOperation, +) diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py new file mode 100644 index 000000000..ce16da3f6 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py @@ -0,0 +1,25 @@ +from typing import ( + Any, + AsyncIterator, +) + +from minos.common import ( + DatabaseClient, + DatabaseOperation, +) + + +class LmdbDatabaseClient(DatabaseClient): + """TODO""" + + async def _is_valid(self, **kwargs) -> bool: + pass + + async def _reset(self, **kwargs) -> None: + pass + + async def _execute(self, operation: DatabaseOperation) -> None: + pass + + def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: + pass diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/__init__.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/__init__.py index e69de29bb..c4229a23b 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/__init__.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/__init__.py @@ -0,0 +1,3 @@ +from .saga import ( + LmdbSagaExecutionDatabaseOperationFactory, +) diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/__init__.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/__init__.py new file mode 100644 index 000000000..b81951056 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/__init__.py @@ -0,0 +1,3 @@ +from .executions import ( + LmdbSagaExecutionDatabaseOperationFactory, +) diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py new file mode 100644 index 000000000..381f5793f --- /dev/null +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py @@ -0,0 +1,7 @@ +from minos.saga import ( + SagaExecutionDatabaseOperationFactory, +) + + +class LmdbSagaExecutionDatabaseOperationFactory(SagaExecutionDatabaseOperationFactory): + """TODO""" diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py new file mode 100644 index 000000000..1307cd33e --- /dev/null +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py @@ -0,0 +1,7 @@ +from minos.common import ( + DatabaseOperation, +) + + +class LmdbDatabaseOperation(DatabaseOperation): + """TODO""" diff --git a/packages/plugins/minos-database-lmdb/poetry.lock b/packages/plugins/minos-database-lmdb/poetry.lock index d5ee172aa..0c2aef563 100644 --- a/packages/plugins/minos-database-lmdb/poetry.lock +++ b/packages/plugins/minos-database-lmdb/poetry.lock @@ -19,29 +19,6 @@ develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-ti raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - -[[package]] -name = "async-timeout" -version = "4.0.2" -description = "Timeout context manager for asyncio programs" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "atomicwrites" version = "1.4.0" @@ -234,13 +211,17 @@ version = "0.7.0.dev1" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false -python-versions = ">=3.9,<4.0" +python-versions = "^3.9" +develop = true [package.dependencies] -cached-property = ">=1.5.2,<2.0.0" -minos-microservice-common = "*" -minos-microservice-networks = "*" -psycopg2-binary = ">=2.9.3,<3.0.0" +cached-property = "^1.5.2" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" + +[package.source] +type = "directory" +url = "../../core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" @@ -271,13 +252,16 @@ version = "0.7.0.dev1" description = "The networks core of the Minos Framework" category = "main" optional = false -python-versions = ">=3.9,<4.0" +python-versions = "^3.9" +develop = true [package.dependencies] -aiopg = ">=1.2.1,<2.0.0" -crontab = ">=0.23.0,<0.24.0" -minos-microservice-common = "*" -psycopg2-binary = ">=2.9.3,<3.0.0" +crontab = "^0.23.0" +minos-microservice-common = "^0.7.0*" + +[package.source] +type = "directory" +url = "../../core/minos-microservice-networks" [[package]] name = "minos-microservice-saga" @@ -357,14 +341,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "py" version = "1.11.0" @@ -469,21 +445,13 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "e5afbafb18fd7321396f685b06978dd1181179b0fd8bf0b1ef41ff0d969ca798" +content-hash = "13984b2345050619e558ec2b7f5d7042811ef69ab784f48b842086de883d0b6a" [metadata.files] aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] -async-timeout = [ - {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, - {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, -] atomicwrites = [ {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, @@ -680,15 +648,9 @@ mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] -minos-microservice-aggregate = [ - {file = "minos-microservice-aggregate-0.7.0.dev1.tar.gz", hash = "sha256:b67fa15603c2d72e4d83ebcd9ec3fc08102bdd5d5657dc7d1c816888abdabd38"}, - {file = "minos_microservice_aggregate-0.7.0.dev1-py3-none-any.whl", hash = "sha256:dc93c1a0b246f204047be9ddb427fe20ebb40f2ee2bb097cc99d444e64430c20"}, -] +minos-microservice-aggregate = [] minos-microservice-common = [] -minos-microservice-networks = [ - {file = "minos-microservice-networks-0.7.0.dev1.tar.gz", hash = "sha256:1bead5cde921405627327166b5f318565f18a5cc517043391931b940e46328b1"}, - {file = "minos_microservice_networks-0.7.0.dev1-py3-none-any.whl", hash = "sha256:f39daca1ebd1b698ce0dc29f66e00c28dc27ae9dd06c1982df8b90ead92230d1"}, -] +minos-microservice-networks = [] minos-microservice-saga = [] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, @@ -744,64 +706,6 @@ pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, diff --git a/packages/plugins/minos-database-lmdb/pyproject.toml b/packages/plugins/minos-database-lmdb/pyproject.toml index a16db1303..d2e063afc 100644 --- a/packages/plugins/minos-database-lmdb/pyproject.toml +++ b/packages/plugins/minos-database-lmdb/pyproject.toml @@ -38,6 +38,8 @@ lmdb = "^1.2.1" [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../../core/minos-microservice-common", develop = true } minos-microservice-saga = { path = "../../core/minos-microservice-saga", develop = true } +minos-microservice-networks = { path = "../../core/minos-microservice-networks", develop = true } +minos-microservice-aggregate = { path = "../../core/minos-microservice-aggregate", develop = true } black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" diff --git a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py new file mode 100644 index 000000000..3e2109cd2 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py @@ -0,0 +1,17 @@ +import unittest + +from minos.common import ( + DatabaseOperation, +) +from minos.plugins.lmdb import ( + LmdbDatabaseOperation, +) + + +class TestLmdbDatabaseClient(unittest.TestCase): + def test_subclass(self) -> None: + self.assertTrue(issubclass(LmdbDatabaseOperation, DatabaseOperation)) + + +if __name__ == "__main__": + unittest.main() From e7ca7e105665823088cc9331df917dbfc6745a93 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 12:09:56 +0200 Subject: [PATCH 262/324] ISSUE #99 * Add `minos-database-lmdb` to pre-commit config. --- .pre-commit-config.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 84470da60..46f97e088 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -51,6 +51,13 @@ repos: files: ^packages/plugins/minos-database-aiopg/ language: system + - id: minos-database-lmdb-check + pass_filenames: false + entry: make --directory=packages/plugins/minos-database-lmdb check + name: Check minos-database-lmdb + files: ^packages/plugins/minos-database-lmdb/ + language: system + - id: minos-discovery-minos-check pass_filenames: false entry: make --directory=packages/plugins/minos-discovery-minos check From f5e60d08fcc543146526fd585a124a3f719e1d9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 13:18:27 +0200 Subject: [PATCH 263/324] ISSUE #99 * Add initial implementation of the `LmdbDatabaseClient`. --- .../minos/plugins/lmdb/clients.py | 123 +++++++++++++- .../minos/plugins/lmdb/operations.py | 26 +++ .../tests/test_lmdb/test_clients.py | 158 +++++++++++++++++- 3 files changed, 299 insertions(+), 8 deletions(-) diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py index ce16da3f6..825cce17a 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py @@ -1,25 +1,136 @@ +from __future__ import ( + annotations, +) + +from pathlib import ( + Path, +) from typing import ( Any, - AsyncIterator, + Optional, + Union, +) + +from lmdb import ( + Environment, ) from minos.common import ( DatabaseClient, DatabaseOperation, + MinosAvroDatabaseProtocol, + MinosBinaryProtocol, +) + +from .operations import ( + LmdbDatabaseOperation, + LmdbDatabaseOperationType, ) class LmdbDatabaseClient(DatabaseClient): """TODO""" + _environment: Optional[Environment] + + def __init__( + self, + path: Optional[Union[str, Path]] = None, + max_tables: int = 100, + map_size: int = int(1e9), + protocol: type[MinosBinaryProtocol] = MinosAvroDatabaseProtocol, + *args, + **kwargs, + ): + super().__init__(*args, **kwargs) + if path is None: + path = ".lmdb" + + self._path = path + self._max_tables = max_tables + self._map_size = map_size + self._protocol = protocol + self._tables = {} + + self._prefetched = None + + self._environment = None + + async def _setup(self) -> None: + await super()._setup() + self._create_environment() + + async def _destroy(self) -> None: + await super()._destroy() + self._close_environment() + + def _create_environment(self) -> None: + self._environment = Environment(str(self._path), max_dbs=self._max_tables, map_size=self._map_size) + + def _close_environment(self) -> None: + if self._environment is not None: + self._environment.close() + async def _is_valid(self, **kwargs) -> bool: - pass + return True async def _reset(self, **kwargs) -> None: - pass + self._prefetched = None + self._environment.sync() + + async def _fetch_all(self, *args, **kwargs) -> Any: + prefetched = self._prefetched + self._prefetched = None + yield prefetched async def _execute(self, operation: DatabaseOperation) -> None: - pass + if not isinstance(operation, LmdbDatabaseOperation): + raise ValueError(f"The operation must be a {LmdbDatabaseOperation!r} instance. Obtained: {operation!r}") + + mapper = { + LmdbDatabaseOperationType.CREATE: self._create, + LmdbDatabaseOperationType.READ: self._read, + LmdbDatabaseOperationType.UPDATE: self._update, + LmdbDatabaseOperationType.DELETE: self._delete, + } + + fn = mapper[operation.type_] + + fn(table=operation.table, key=operation.key, value=operation.value) + + # noinspection PyUnusedLocal + def _create(self, table: str, key: str, value: Any, **kwargs) -> None: + table = self._get_table(table) + with self._environment.begin(write=True) as transaction: + encoded = self._protocol.encode(value) + transaction.put(key.encode(), encoded, db=table) + + # noinspection PyUnusedLocal + def _read(self, table: str, key: str, **kwargs): + table = self._get_table(table) + with self._environment.begin(db=table) as transaction: + value_binary = transaction.get(key.encode()) + if value_binary is not None: + value = self._protocol.decode(value_binary) + else: + value = None + + self._prefetched = value + + # noinspection PyUnusedLocal + def _delete(self, table: str, key: str, **kwargs) -> None: + table = self._get_table(table) + with self._environment.begin(write=True, db=table) as transaction: + transaction.delete(key.encode()) + + # noinspection PyUnusedLocal + def _update(self, table: str, key: str, value: Any, **kwargs) -> None: + table = self._get_table(table) + with self._environment.begin(write=True, db=table) as transaction: + encoded = self._protocol.encode(value) + transaction.put(key.encode(), encoded, db=table, overwrite=True) - def _fetch_all(self, *args, **kwargs) -> AsyncIterator[Any]: - pass + def _get_table(self, table: str) -> Any: + if table not in self._tables: + self._tables[table] = self._environment.open_db(table.encode()) + return self._tables[table] diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py index 1307cd33e..f21ba3b03 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py @@ -1,7 +1,33 @@ +from enum import ( + Enum, +) +from typing import ( + Any, + Optional, +) + from minos.common import ( DatabaseOperation, ) +class LmdbDatabaseOperationType(str, Enum): + """TODO""" + + CREATE = "create" + READ = "read" + UPDATE = "update" + DELETE = "delete" + + class LmdbDatabaseOperation(DatabaseOperation): """TODO""" + + def __init__( + self, type_: LmdbDatabaseOperationType, table: str, key: str, value: Optional[Any] = None, *args, **kwargs + ): + super().__init__(*args, **kwargs) + self.type_ = type_ + self.table = table + self.key = key + self.value = value diff --git a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py index 3e2109cd2..6f793ffeb 100644 --- a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py +++ b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py @@ -1,16 +1,170 @@ +import shutil import unittest +from pathlib import ( + Path, +) from minos.common import ( + DatabaseClient, DatabaseOperation, ) from minos.plugins.lmdb import ( + LmdbDatabaseClient, LmdbDatabaseOperation, ) +from minos.plugins.lmdb.operations import ( + LmdbDatabaseOperationType, +) +from tests.utils import ( + BASE_PATH, +) -class TestLmdbDatabaseClient(unittest.TestCase): +class TestLmdbDatabaseClient(unittest.IsolatedAsyncioTestCase): + def setUp(self) -> None: + super().setUp() + self.path = BASE_PATH / "order.lmdb" + def test_subclass(self) -> None: - self.assertTrue(issubclass(LmdbDatabaseOperation, DatabaseOperation)) + self.assertTrue(issubclass(LmdbDatabaseClient, DatabaseClient)) + + def tearDown(self) -> None: + shutil.rmtree(self.path, ignore_errors=True) + shutil.rmtree(".lmdb", ignore_errors=True) + + async def test_constructor_default_path(self): + async with LmdbDatabaseClient(): + self.assertTrue(Path(".lmdb").exists()) + + async def test_is_valid(self): + async with LmdbDatabaseClient(self.path) as client: + self.assertTrue(await client.is_valid()) + + async def test_execute_raises_unsupported(self): + class _DatabaseOperation(DatabaseOperation): + """For testing purposes.""" + + async with LmdbDatabaseClient(self.path) as client: + with self.assertRaises(ValueError): + await client.execute(_DatabaseOperation()) + + async def test_execute_create_text(self): + create_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, "TestOne", "first", "Text Value") + read_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestOne", "first") + + async with LmdbDatabaseClient(self.path) as client: + await client.execute(create_op) + await client.execute(read_op) + + self.assertEqual("Text Value", await client.fetch_one()) + + async def test_execute_create_int(self): + create_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, "TestOne", "first", 123) + read_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestOne", "first") + + async with LmdbDatabaseClient(self.path) as client: + await client.execute(create_op) + await client.execute(read_op) + + self.assertEqual(123, await client.fetch_one()) + + async def test_execute_create_dict(self): + create_op = LmdbDatabaseOperation( + LmdbDatabaseOperationType.CREATE, "TestOne", "first", {"key_one": "hello", "key_two": "minos"} + ) + read_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestOne", "first") + + async with LmdbDatabaseClient(self.path) as client: + await client.execute(create_op) + await client.execute(read_op) + + self.assertEqual({"key_one": "hello", "key_two": "minos"}, await client.fetch_one()) + + async def test_execute_create_multi_dict(self): + create_op = LmdbDatabaseOperation( + LmdbDatabaseOperationType.CREATE, + "TestOne", + "first", + {"key_one": "hello", "key_two": {"sub_key": "this is a sub text"}}, + ) + read_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestOne", "first") + + async with LmdbDatabaseClient(self.path) as client: + await client.execute(create_op) + await client.execute(read_op) + + self.assertEqual( + {"key_one": "hello", "key_two": {"sub_key": "this is a sub text"}}, await client.fetch_one() + ) + + async def test_execute_create_list(self): + create_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, "TestOne", "first", ["hello", "minos"]) + read_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestOne", "first") + + async with LmdbDatabaseClient(self.path) as client: + await client.execute(create_op) + await client.execute(read_op) + + self.assertEqual(["hello", "minos"], await client.fetch_one()) + + async def test_execute_create_multi_table(self): + create_op_1 = LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, "TestOne", "first", "Text Value") + create_op_2 = LmdbDatabaseOperation( + LmdbDatabaseOperationType.CREATE, "TestTwo", "first_double", "Text Double Value" + ) + create_op_3 = LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, "TestTwo", "first", "Text Value Diff") + + read_op_1 = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestOne", "first") + read_op_2 = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestTwo", "first_double") + read_op_3 = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestTwo", "first") + + async with LmdbDatabaseClient(self.path) as client: + await client.execute(create_op_1) + await client.execute(create_op_2) + await client.execute(create_op_3) + + await client.execute(read_op_1) + self.assertEqual("Text Value", await client.fetch_one()) + + await client.execute(read_op_2) + self.assertEqual("Text Double Value", await client.fetch_one()) + + await client.execute(read_op_3) + self.assertEqual("Text Value Diff", await client.fetch_one()) + + async def test_execute_delete(self): + create_op_1 = LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, "TestOne", "first", "Text Value") + create_op_2 = LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, "TestOne", "second", "Text Second Value") + delete_op_1 = LmdbDatabaseOperation(LmdbDatabaseOperationType.DELETE, "TestOne", "first") + read_op_1 = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestOne", "second") + read_op_2 = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestOne", "first") + + async with LmdbDatabaseClient(self.path) as client: + await client.execute(create_op_1) + await client.execute(create_op_2) + await client.execute(delete_op_1) + + await client.execute(read_op_1) + self.assertEqual("Text Second Value", await client.fetch_one()) + + await client.execute(read_op_2) + self.assertEqual(None, await client.fetch_one()) + + async def test_execute_update(self): + create_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, "TestOne", "first", "Text Value") + update_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.UPDATE, "TestOne", "first", "Updated Text Value") + read_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, "TestOne", "first") + + async with LmdbDatabaseClient(self.path) as client: + await client.execute(create_op) + await client.execute(read_op) + + self.assertEqual("Text Value", await client.fetch_one()) + + await client.execute(update_op) + await client.execute(read_op) + + self.assertEqual("Updated Text Value", await client.fetch_one()) if __name__ == "__main__": From 0d6c3167e437e270aa13b13b4fe12706a7ccf1ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 13:42:22 +0200 Subject: [PATCH 264/324] ISSUE #99 * Refactor `SagaExecutionStorage` as `SagaExecutionRepository`. * Add `DatabaseSagaExecutionRepository`. --- .../minos/saga/__init__.py | 3 +- .../minos/saga/executions/__init__.py | 11 ++- .../saga/executions/repositories/__init__.py | 7 ++ .../minos/saga/executions/repositories/abc.py | 62 +++++++++++++ .../{ => repositories}/database/__init__.py | 3 + .../{ => repositories}/database/factories.py | 0 .../executions/repositories/database/impl.py | 68 ++++++++++++++ .../minos/saga/executions/storage.py | 90 ------------------- .../minos/saga/manager.py | 25 ++++-- .../test_repositories/__init__.py | 0 .../test_databases/__init__.py | 0 .../test_databases/test_impl.py | 83 +++++++++++++++++ .../test_saga/test_executions/test_storage.py | 77 ---------------- .../tests/test_saga/test_manager.py | 10 +-- 14 files changed, 252 insertions(+), 187 deletions(-) create mode 100644 packages/core/minos-microservice-saga/minos/saga/executions/repositories/__init__.py create mode 100644 packages/core/minos-microservice-saga/minos/saga/executions/repositories/abc.py rename packages/core/minos-microservice-saga/minos/saga/executions/{ => repositories}/database/__init__.py (54%) rename packages/core/minos-microservice-saga/minos/saga/executions/{ => repositories}/database/factories.py (100%) create mode 100644 packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py delete mode 100644 packages/core/minos-microservice-saga/minos/saga/executions/storage.py create mode 100644 packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/__init__.py create mode 100644 packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/__init__.py create mode 100644 packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/test_impl.py delete mode 100644 packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py diff --git a/packages/core/minos-microservice-saga/minos/saga/__init__.py b/packages/core/minos-microservice-saga/minos/saga/__init__.py index 4fb7e1814..260a0ab5f 100644 --- a/packages/core/minos-microservice-saga/minos/saga/__init__.py +++ b/packages/core/minos-microservice-saga/minos/saga/__init__.py @@ -46,6 +46,7 @@ ) from .executions import ( ConditionalSagaStepExecution, + DatabaseSagaExecutionRepository, Executor, LocalExecutor, LocalSagaStepExecution, @@ -54,7 +55,7 @@ ResponseExecutor, SagaExecution, SagaExecutionDatabaseOperationFactory, - SagaExecutionStorage, + SagaExecutionRepository, SagaStatus, SagaStepExecution, SagaStepStatus, diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/__init__.py b/packages/core/minos-microservice-saga/minos/saga/executions/__init__.py index 167dd4134..e4c55b270 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/__init__.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/__init__.py @@ -1,15 +1,17 @@ from .commit import ( TransactionCommitter, ) -from .database import ( - SagaExecutionDatabaseOperationFactory, -) from .executors import ( Executor, LocalExecutor, RequestExecutor, ResponseExecutor, ) +from .repositories import ( + DatabaseSagaExecutionRepository, + SagaExecutionDatabaseOperationFactory, + SagaExecutionRepository, +) from .saga import ( SagaExecution, ) @@ -23,6 +25,3 @@ RemoteSagaStepExecution, SagaStepExecution, ) -from .storage import ( - SagaExecutionStorage, -) diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/__init__.py b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/__init__.py new file mode 100644 index 000000000..bb39208d1 --- /dev/null +++ b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/__init__.py @@ -0,0 +1,7 @@ +from .abc import ( + SagaExecutionRepository, +) +from .database import ( + DatabaseSagaExecutionRepository, + SagaExecutionDatabaseOperationFactory, +) diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/abc.py b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/abc.py new file mode 100644 index 000000000..4bc0987eb --- /dev/null +++ b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/abc.py @@ -0,0 +1,62 @@ +from abc import ( + ABC, + abstractmethod, +) +from typing import ( + Union, +) +from uuid import ( + UUID, +) + +from minos.common import ( + SetupMixin, +) + +from ..saga import ( + SagaExecution, +) + + +class SagaExecutionRepository(SetupMixin, ABC): + """TODO""" + + async def store(self, execution: SagaExecution) -> None: + """Store an execution. + + :param execution: Execution to be stored. + :return: This method does not return anything. + """ + return await self._store(execution) + + async def _store(self, execution: SagaExecution) -> None: + raise NotImplementedError + + async def load(self, uuid: Union[str, UUID]) -> SagaExecution: + """Load the saga execution stored on the given key. + + :param uuid: The key to identify the execution. + :return: A ``SagaExecution`` instance. + """ + if not isinstance(uuid, UUID): + uuid = UUID(uuid) + return await self._load(uuid) + + @abstractmethod + async def _load(self, uuid: UUID) -> SagaExecution: + raise NotImplementedError + + async def delete(self, uuid: Union[SagaExecution, str, UUID]) -> None: + """Delete the reference of the given key. + + :param uuid: Execution key to be deleted. + :return: This method does not return anything. + """ + if isinstance(uuid, SagaExecution): + uuid = uuid.uuid + if not isinstance(uuid, UUID): + uuid = UUID(uuid) + return await self._delete(uuid) + + async def _delete(self, key: UUID) -> None: + raise NotImplementedError diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/database/__init__.py b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/__init__.py similarity index 54% rename from packages/core/minos-microservice-saga/minos/saga/executions/database/__init__.py rename to packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/__init__.py index 28e96babc..ff16cd986 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/database/__init__.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/__init__.py @@ -1,3 +1,6 @@ from .factories import ( SagaExecutionDatabaseOperationFactory, ) +from .impl import ( + DatabaseSagaExecutionRepository, +) diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/database/factories.py b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/factories.py similarity index 100% rename from packages/core/minos-microservice-saga/minos/saga/executions/database/factories.py rename to packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/factories.py diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py new file mode 100644 index 000000000..e0f2a65a6 --- /dev/null +++ b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py @@ -0,0 +1,68 @@ +from __future__ import ( + annotations, +) + +from contextlib import ( + suppress, +) +from typing import ( + Type, +) +from uuid import ( + UUID, +) + +from minos.common import ( + Config, + MinosConfigException, + MinosJsonBinaryProtocol, + MinosStorage, + MinosStorageLmdb, +) + +from ....exceptions import ( + SagaExecutionNotFoundException, +) +from ...saga import ( + SagaExecution, +) +from ..abc import ( + SagaExecutionRepository, +) + + +class DatabaseSagaExecutionRepository(SagaExecutionRepository): + """Saga Execution Storage class.""" + + def __init__( + self, + storage_cls: Type[MinosStorage] = MinosStorageLmdb, + protocol=MinosJsonBinaryProtocol, + db_name: str = "LocalState", + *args, + **kwargs, + ): + super().__init__(*args, **kwargs) + self.db_name = db_name + self._storage = storage_cls.build(protocol=protocol, **kwargs) + + @classmethod + def _from_config(cls, config: Config, **kwargs) -> SagaExecutionRepository: + with suppress(MinosConfigException): + kwargs |= config.get_database_by_name("saga") + return cls(**kwargs) + + async def _store(self, execution: SagaExecution) -> None: + key = str(execution.uuid) + value = execution.raw + self._storage.update(table=self.db_name, key=key, value=value) + + async def _delete(self, uuid: UUID) -> None: + self._storage.delete(table=self.db_name, key=str(uuid)) + + async def _load(self, uuid: UUID) -> SagaExecution: + value = self._storage.get(table=self.db_name, key=str(uuid)) + if value is None: + raise SagaExecutionNotFoundException(f"The execution identified by {uuid} was not found.") + execution = SagaExecution.from_raw(value) + return execution diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/storage.py b/packages/core/minos-microservice-saga/minos/saga/executions/storage.py deleted file mode 100644 index c2a31a201..000000000 --- a/packages/core/minos-microservice-saga/minos/saga/executions/storage.py +++ /dev/null @@ -1,90 +0,0 @@ -from __future__ import ( - annotations, -) - -from contextlib import ( - suppress, -) -from typing import ( - Type, - Union, -) -from uuid import ( - UUID, -) - -from minos.common import ( - Config, - MinosConfigException, - MinosJsonBinaryProtocol, - MinosStorage, - MinosStorageLmdb, -) - -from ..exceptions import ( - SagaExecutionNotFoundException, -) -from .saga import ( - SagaExecution, -) - - -class SagaExecutionStorage: - """Saga Execution Storage class.""" - - def __init__( - self, - storage_cls: Type[MinosStorage] = MinosStorageLmdb, - protocol=MinosJsonBinaryProtocol, - db_name: str = "LocalState", - **kwargs, - ): - self.db_name = db_name - self._storage = storage_cls.build(protocol=protocol, **kwargs) - - @classmethod - def from_config(cls, config: Config, **kwargs) -> SagaExecutionStorage: - """Build an instance from config. - - :param config: Config instance. - :param kwargs: Additional named arguments. - :return: A new ``SagaExecutionStorage`` instance. - """ - with suppress(MinosConfigException): - kwargs |= config.get_database_by_name("saga") - return cls(**kwargs) - - def store(self, execution: SagaExecution) -> None: - """Store an execution. - - :param execution: Execution to be stored. - :return: This method does not return anything. - """ - key = str(execution.uuid) - value = execution.raw - self._storage.update(table=self.db_name, key=key, value=value) - - def load(self, key: Union[str, UUID]) -> SagaExecution: - """Load the saga execution stored on the given key. - - :param key: The key to identify the execution. - :return: A ``SagaExecution`` instance. - """ - key = str(key) - value = self._storage.get(table=self.db_name, key=key) - if value is None: - raise SagaExecutionNotFoundException(f"The execution identified by {key} was not found.") - execution = SagaExecution.from_raw(value) - return execution - - def delete(self, key: Union[SagaExecution, str, UUID]) -> None: - """Delete the reference of the given key. - - :param key: Execution key to be deleted. - :return: This method does not return anything. - """ - if isinstance(key, SagaExecution): - key = key.uuid - - key = str(key) - self._storage.delete(table=self.db_name, key=key) diff --git a/packages/core/minos-microservice-saga/minos/saga/manager.py b/packages/core/minos-microservice-saga/minos/saga/manager.py index 590b46e9f..cb997759a 100644 --- a/packages/core/minos-microservice-saga/minos/saga/manager.py +++ b/packages/core/minos-microservice-saga/minos/saga/manager.py @@ -45,8 +45,9 @@ SagaPausedExecutionStepException, ) from .executions import ( + DatabaseSagaExecutionRepository, SagaExecution, - SagaExecutionStorage, + SagaExecutionRepository, SagaStatus, ) from .messages import ( @@ -66,7 +67,7 @@ class SagaManager(SetupMixin): @Inject() def __init__( self, - storage: SagaExecutionStorage, + storage: SagaExecutionRepository, broker_pool: Optional[BrokerClientPool] = None, pool_factory: Optional[PoolFactory] = None, *args, @@ -92,9 +93,17 @@ def _from_config(cls, *args, config: Config, **kwargs) -> SagaManager: :param kwargs: Additional named arguments. :return: A new ``SagaManager`` instance. """ - storage = SagaExecutionStorage.from_config(config, **kwargs) + storage = DatabaseSagaExecutionRepository.from_config(config, **kwargs) return cls(storage=storage, **kwargs) + async def _setup(self) -> None: + await super()._setup() + await self.storage.setup() + + async def _destroy(self) -> None: + await self.storage.destroy() + await super()._destroy() + async def run( self, definition: Optional[Saga] = None, @@ -161,7 +170,7 @@ async def _run_new( return await self._run(execution, **kwargs) async def _load_and_run(self, response: SagaResponse, **kwargs) -> Union[UUID, SagaExecution]: - execution = self.storage.load(response.uuid) + execution = await self.storage.load(response.uuid) return await self._run(execution, response=response, **kwargs) async def _run( @@ -178,7 +187,7 @@ async def _run( else: await self._run_with_pause_on_memory(execution, **kwargs) except SagaFailedExecutionException as exc: - self.storage.store(execution) + await self.storage.store(execution) if raise_on_error: raise exc logger.exception(f"The execution identified by {execution.uuid!s} failed") @@ -194,7 +203,7 @@ async def _run( headers["related_services"] = ",".join(related_services) if execution.status == SagaStatus.Finished: - self.storage.delete(execution) + await self.storage.delete(execution) if return_execution: return execution @@ -207,7 +216,7 @@ async def _run_with_pause_on_disk(self, execution: SagaExecution, autocommit: bo if autocommit: await execution.commit(**kwargs) except SagaPausedExecutionStepException: - self.storage.store(execution) + await self.storage.store(execution) except SagaFailedExecutionException as exc: if autocommit: await execution.reject(**kwargs) @@ -225,7 +234,7 @@ async def _run_with_pause_on_memory( await execution.execute(response=response, autocommit=False, **kwargs) except SagaPausedExecutionStepException: response = await self._get_response(broker, execution, **kwargs) - self.storage.store(execution) + await self.storage.store(execution) if autocommit: await execution.commit(**kwargs) except SagaFailedExecutionException as exc: diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/__init__.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/__init__.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/test_impl.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/test_impl.py new file mode 100644 index 000000000..a1d374c70 --- /dev/null +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/test_impl.py @@ -0,0 +1,83 @@ +import unittest +from shutil import ( + rmtree, +) + +from minos.saga import ( + DatabaseSagaExecutionRepository, + SagaExecution, + SagaExecutionNotFoundException, + SagaPausedExecutionStepException, + SagaResponse, +) +from tests.utils import ( + ADD_ORDER, + DB_PATH, + Foo, + SagaTestCase, +) + + +class TestDatabaseSagaExecutionRepository(SagaTestCase): + async def asyncSetUp(self) -> None: + await super().asyncSetUp() + + execution = SagaExecution.from_definition(ADD_ORDER) + with self.assertRaises(SagaPausedExecutionStepException): + await execution.execute() + + response = SagaResponse(Foo("hola"), {"ticket"}) + with self.assertRaises(SagaPausedExecutionStepException): + await execution.execute(response) + + self.execution = execution + + def tearDown(self) -> None: + rmtree(DB_PATH, ignore_errors=True) + super().tearDown() + + async def test_store(self): + async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: + await repository.store(self.execution) + + self.assertEqual(self.execution, await repository.load(self.execution.uuid)) + + async def test_store_overwrite(self): + async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: + await repository.store(self.execution) + self.assertEqual(self.execution, await repository.load(self.execution.uuid)) + + another = SagaExecution.from_definition(ADD_ORDER) + another.uuid = self.execution.uuid + await repository.store(another) + + self.assertNotEqual(self.execution, await repository.load(self.execution.uuid)) + self.assertEqual(another, await repository.load(self.execution.uuid)) + + async def test_load_from_str(self): + async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: + await repository.store(self.execution) + self.assertEqual(self.execution, await repository.load(str(self.execution.uuid))) + + async def test_load_raises(self): + async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: + with self.assertRaises(SagaExecutionNotFoundException): + await repository.load(self.execution.uuid) + + async def test_delete(self): + async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: + await repository.store(self.execution) + await repository.delete(self.execution) + with self.assertRaises(SagaExecutionNotFoundException): + await repository.load(self.execution.uuid) + + async def test_delete_from_str(self): + async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: + await repository.store(self.execution) + await repository.delete(str(self.execution.uuid)) + with self.assertRaises(SagaExecutionNotFoundException): + await repository.load(self.execution.uuid) + + +if __name__ == "__main__": + unittest.main() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py deleted file mode 100644 index 8c174118d..000000000 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_storage.py +++ /dev/null @@ -1,77 +0,0 @@ -import unittest -from shutil import ( - rmtree, -) - -from minos.saga import ( - SagaExecution, - SagaExecutionNotFoundException, - SagaExecutionStorage, - SagaPausedExecutionStepException, - SagaResponse, -) -from tests.utils import ( - ADD_ORDER, - DB_PATH, - Foo, - SagaTestCase, -) - - -class TestSagaExecutionStorage(SagaTestCase): - DB_PATH = DB_PATH - - async def asyncSetUp(self) -> None: - await super().asyncSetUp() - - execution = SagaExecution.from_definition(ADD_ORDER) - with self.assertRaises(SagaPausedExecutionStepException): - await execution.execute() - - response = SagaResponse(Foo("hola"), {"ticket"}) - with self.assertRaises(SagaPausedExecutionStepException): - await execution.execute(response) - - self.execution = execution - - def tearDown(self) -> None: - rmtree(self.DB_PATH, ignore_errors=True) - super().tearDown() - - def test_store(self): - storage = SagaExecutionStorage(path=self.DB_PATH) - - storage.store(self.execution) - - self.assertEqual(self.execution, storage.load(self.execution.uuid)) - - def test_store_overwrite(self): - storage = SagaExecutionStorage(path=self.DB_PATH) - - storage.store(self.execution) - self.assertEqual(self.execution, storage.load(self.execution.uuid)) - - another = SagaExecution.from_definition(ADD_ORDER) - another.uuid = self.execution.uuid - storage.store(another) - - self.assertNotEqual(self.execution, storage.load(self.execution.uuid)) - self.assertEqual(another, storage.load(self.execution.uuid)) - - def test_load_raises(self): - storage = SagaExecutionStorage(path=self.DB_PATH) - - with self.assertRaises(SagaExecutionNotFoundException): - storage.load(self.execution.uuid) - - def test_delete(self): - storage = SagaExecutionStorage(path=self.DB_PATH) - - storage.store(self.execution) - storage.delete(self.execution) - with self.assertRaises(SagaExecutionNotFoundException): - storage.load(self.execution.uuid) - - -if __name__ == "__main__": - unittest.main() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py index ca4fec8a4..db8f9bd1c 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py @@ -27,7 +27,7 @@ SagaContext, SagaExecution, SagaExecutionNotFoundException, - SagaExecutionStorage, + SagaExecutionRepository, SagaFailedExecutionException, SagaManager, SagaResponse, @@ -76,7 +76,7 @@ def tearDown(self) -> None: super().tearDown() def test_constructor(self): - self.assertIsInstance(self.manager.storage, SagaExecutionStorage) + self.assertIsInstance(self.manager.storage, SagaExecutionRepository) self.assertIsInstance(self.manager, SagaManager) def test_constructor_without_broker(self): @@ -103,7 +103,7 @@ async def test_run_with_pause_on_memory(self): self.assertEqual(SagaStatus.Finished, execution.status) with self.assertRaises(SagaExecutionNotFoundException): - self.manager.storage.load(execution.uuid) + await self.manager.storage.load(execution.uuid) observed = self.broker_publisher.messages expected = self._build_expected_messages(observed) @@ -181,7 +181,7 @@ async def test_run_with_pause_on_disk(self): self.assertEqual(SagaStatus.Finished, execution.status) with self.assertRaises(SagaExecutionNotFoundException): - self.manager.storage.load(self.uuid) + await self.manager.storage.load(self.uuid) observed = self.broker_publisher.messages expected = self._build_expected_messages(observed) @@ -232,7 +232,7 @@ async def test_run_with_pause_on_disk_with_headers(self): async def test_run_with_pause_on_disk_returning_uuid(self): uuid = await self.manager.run(ADD_ORDER, return_execution=False, pause_on_disk=True) - execution = self.manager.storage.load(uuid) + execution = await self.manager.storage.load(uuid) self.assertIsInstance(execution, SagaExecution) self.assertEqual(SagaStatus.Paused, execution.status) From eb1b32f0886e33db783ec836bcacfe1e5022caf3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 17:02:24 +0200 Subject: [PATCH 265/324] ISSUE #99 * Add `minos.saga.testing` module. * Implement `LmdbSagaExecutionDatabaseOperationFactory`. --- .../minos/saga/definitions/steps/abc.py | 2 + .../repositories/database/factories.py | 20 +++ .../executions/repositories/database/impl.py | 49 +++---- .../minos/saga/executions/saga.py | 2 + .../minos/saga/manager.py | 2 +- .../minos/saga/testing.py | 136 ++++++++++++++++++ .../minos-microservice-saga/tests/config.yml | 16 ++- .../test_databases/test_impl.py | 82 ++++------- .../tests/test_saga/test_manager.py | 42 ++++-- .../minos-microservice-saga/tests/utils.py | 3 + .../minos/plugins/lmdb/clients.py | 4 +- .../plugins/lmdb/factories/saga/executions.py | 43 ++++++ .../minos-database-lmdb/tests/test_config.yml | 9 +- .../test_factories/test_saga/__init__.py | 0 .../test_saga/test_repositories.py | 31 ++++ 15 files changed, 332 insertions(+), 109 deletions(-) create mode 100644 packages/core/minos-microservice-saga/minos/saga/testing.py create mode 100644 packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/__init__.py create mode 100644 packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_repositories.py diff --git a/packages/core/minos-microservice-saga/minos/saga/definitions/steps/abc.py b/packages/core/minos-microservice-saga/minos/saga/definitions/steps/abc.py index f01dfd28d..f0b3f03f9 100644 --- a/packages/core/minos-microservice-saga/minos/saga/definitions/steps/abc.py +++ b/packages/core/minos-microservice-saga/minos/saga/definitions/steps/abc.py @@ -55,6 +55,8 @@ def from_raw(cls, raw: Union[dict[str, Any], SagaStep], **kwargs) -> SagaStep: if isinstance(raw, cls): return raw + raw = raw.copy() + if "cls" in raw: # noinspection PyTypeChecker step_cls: type = import_module(raw.pop("cls")) diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/factories.py b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/factories.py index 1d6caad28..408df38ee 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/factories.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/factories.py @@ -1,11 +1,31 @@ from abc import ( ABC, + abstractmethod, +) +from uuid import ( + UUID, ) from minos.common import ( + DatabaseOperation, DatabaseOperationFactory, ) class SagaExecutionDatabaseOperationFactory(DatabaseOperationFactory, ABC): """TODO""" + + @abstractmethod + def build_store(self, uuid: UUID, **kwargs) -> DatabaseOperation: + """TODO""" + raise NotImplementedError + + @abstractmethod + def build_load(self, uuid: UUID) -> DatabaseOperation: + """TODO""" + raise NotImplementedError + + @abstractmethod + def build_delete(self, uuid: UUID) -> DatabaseOperation: + """TODO""" + raise NotImplementedError diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py index e0f2a65a6..98a7d20b8 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py @@ -2,22 +2,15 @@ annotations, ) -from contextlib import ( - suppress, -) from typing import ( - Type, + Optional, ) from uuid import ( UUID, ) from minos.common import ( - Config, - MinosConfigException, - MinosJsonBinaryProtocol, - MinosStorage, - MinosStorageLmdb, + DatabaseMixin, ) from ....exceptions import ( @@ -29,39 +22,31 @@ from ..abc import ( SagaExecutionRepository, ) +from .factories import ( + SagaExecutionDatabaseOperationFactory, +) -class DatabaseSagaExecutionRepository(SagaExecutionRepository): +class DatabaseSagaExecutionRepository(SagaExecutionRepository, DatabaseMixin[SagaExecutionDatabaseOperationFactory]): """Saga Execution Storage class.""" - def __init__( - self, - storage_cls: Type[MinosStorage] = MinosStorageLmdb, - protocol=MinosJsonBinaryProtocol, - db_name: str = "LocalState", - *args, - **kwargs, - ): - super().__init__(*args, **kwargs) - self.db_name = db_name - self._storage = storage_cls.build(protocol=protocol, **kwargs) - - @classmethod - def _from_config(cls, config: Config, **kwargs) -> SagaExecutionRepository: - with suppress(MinosConfigException): - kwargs |= config.get_database_by_name("saga") - return cls(**kwargs) + def __init__(self, *args, database_key: Optional[tuple[str]] = None, **kwargs): + if database_key is None: + database_key = ("saga",) + super().__init__(*args, database_key=database_key, **kwargs) async def _store(self, execution: SagaExecution) -> None: - key = str(execution.uuid) - value = execution.raw - self._storage.update(table=self.db_name, key=key, value=value) + operation = self.database_operation_factory.build_store(**execution.raw) + await self.execute_on_database(operation) async def _delete(self, uuid: UUID) -> None: - self._storage.delete(table=self.db_name, key=str(uuid)) + operation = self.database_operation_factory.build_delete(uuid) + await self.execute_on_database(operation) async def _load(self, uuid: UUID) -> SagaExecution: - value = self._storage.get(table=self.db_name, key=str(uuid)) + operation = self.database_operation_factory.build_load(uuid) + + value = await self.execute_on_database_and_fetch_one(operation) if value is None: raise SagaExecutionNotFoundException(f"The execution identified by {uuid} was not found.") execution = SagaExecution.from_raw(value) diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/saga.py b/packages/core/minos-microservice-saga/minos/saga/executions/saga.py index 6c0c6548e..d3b38cd05 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/saga.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/saga.py @@ -93,6 +93,8 @@ def from_raw(cls, raw: Union[dict[str, Any], SagaExecution], **kwargs) -> SagaEx if isinstance(raw, cls): return raw + raw = raw.copy() + current = raw | kwargs current["definition"] = Saga.from_raw(current["definition"]) current["status"] = SagaStatus.from_raw(current["status"]) diff --git a/packages/core/minos-microservice-saga/minos/saga/manager.py b/packages/core/minos-microservice-saga/minos/saga/manager.py index cb997759a..e927cceaa 100644 --- a/packages/core/minos-microservice-saga/minos/saga/manager.py +++ b/packages/core/minos-microservice-saga/minos/saga/manager.py @@ -85,7 +85,7 @@ def __init__( self.broker_pool = broker_pool @classmethod - def _from_config(cls, *args, config: Config, **kwargs) -> SagaManager: + def _from_config(cls, config: Config, **kwargs) -> SagaManager: """Build an instance from config. :param args: Additional positional arguments. diff --git a/packages/core/minos-microservice-saga/minos/saga/testing.py b/packages/core/minos-microservice-saga/minos/saga/testing.py new file mode 100644 index 000000000..e1da76cd0 --- /dev/null +++ b/packages/core/minos-microservice-saga/minos/saga/testing.py @@ -0,0 +1,136 @@ +from abc import ( + ABC, + abstractmethod, +) +from uuid import ( + UUID, +) + +from minos.common import ( + DatabaseOperation, + DeclarativeModel, +) +from minos.common.testing import ( + MinosTestCase, + MockedDatabaseClient, + MockedDatabaseOperation, +) + +from .context import ( + SagaContext, +) +from .definitions import ( + Saga, +) +from .exceptions import ( + SagaExecutionNotFoundException, +) +from .executions import ( + SagaExecution, + SagaExecutionDatabaseOperationFactory, + SagaExecutionRepository, +) + + +class MockedSagaExecutionDatabaseOperationFactory(SagaExecutionDatabaseOperationFactory): + """For testing purposes""" + + def build_store(self, uuid: UUID, **kwargs) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("create_table") + + def build_load(self, uuid: UUID) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("create_table") + + def build_delete(self, uuid: UUID) -> DatabaseOperation: + """For testing purposes""" + return MockedDatabaseOperation("create_table") + + +MockedDatabaseClient.set_factory( + SagaExecutionDatabaseOperationFactory, + MockedSagaExecutionDatabaseOperationFactory, +) + + +class Foo(DeclarativeModel): + """For testing purposes.""" + + foo: str + + +def _fn1(context: SagaContext) -> SagaContext: # pragma: no cover + context["payment"] = "payment" + return context + + +def _fn2(context: SagaContext) -> SagaContext: # pragma: no cover + context["payment"] = None + return context + + +_SAGA = Saga().local_step(_fn1).on_failure(_fn2).commit() + + +class SagaExecutionRepositoryTestCase(MinosTestCase, ABC): + __test__ = False + + def setUp(self) -> None: + super().setUp() + self.saga_execution_repository = self.build_saga_execution_repository() + + async def asyncSetUp(self) -> None: + await super().asyncSetUp() + + await self.saga_execution_repository.setup() + + execution = SagaExecution.from_definition(_SAGA) + await execution.execute(autocommit=False) + + self.execution = execution + + self.another = SagaExecution.from_definition(_SAGA) + + async def asyncTearDown(self): + await self.saga_execution_repository.destroy() + await super().asyncTearDown() + + @abstractmethod + def build_saga_execution_repository(self) -> SagaExecutionRepository: + """For testing purposes.""" + + async def test_store(self): + await self.saga_execution_repository.store(self.execution) + + self.assertEqual(self.execution, await self.saga_execution_repository.load(self.execution.uuid)) + + async def test_store_overwrite(self): + await self.saga_execution_repository.store(self.execution) + self.assertEqual(self.execution, await self.saga_execution_repository.load(self.execution.uuid)) + + self.another.uuid = self.execution.uuid + await self.saga_execution_repository.store(self.another) + + self.assertNotEqual(self.execution, await self.saga_execution_repository.load(self.execution.uuid)) + self.assertEqual(self.another, await self.saga_execution_repository.load(self.execution.uuid)) + + async def test_load_from_str(self): + await self.saga_execution_repository.store(self.execution) + self.assertEqual(self.execution, await self.saga_execution_repository.load(str(self.execution.uuid))) + + async def test_load_raises(self): + with self.assertRaises(SagaExecutionNotFoundException): + await self.saga_execution_repository.load(self.execution.uuid) + + async def test_delete(self): + await self.saga_execution_repository.store(self.execution) + await self.saga_execution_repository.delete(self.execution) + with self.assertRaises(SagaExecutionNotFoundException): + await self.saga_execution_repository.load(self.execution.uuid) + + async def test_delete_from_str(self): + await self.saga_execution_repository.store(self.execution) + await self.saga_execution_repository.delete(str(self.execution.uuid)) + with self.assertRaises(SagaExecutionNotFoundException): + await self.saga_execution_repository.load(self.execution.uuid) diff --git a/packages/core/minos-microservice-saga/tests/config.yml b/packages/core/minos-microservice-saga/tests/config.yml index 2c8c0b3a9..15a7dff17 100644 --- a/packages/core/minos-microservice-saga/tests/config.yml +++ b/packages/core/minos-microservice-saga/tests/config.yml @@ -1,6 +1,10 @@ -service: - name: order - aggregate: tests.utils.Order -saga: - storage: - path: "./order.lmdb" +version: 2 +name: order + +databases: + saga: + client: minos.common.testing.MockedDatabaseClient + path: "./order.lmdb" + +pools: + database: minos.common.DatabaseClientPool diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/test_impl.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/test_impl.py index a1d374c70..39169fb29 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/test_impl.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/test_impl.py @@ -1,82 +1,54 @@ import unittest -from shutil import ( - rmtree, +from unittest.mock import ( + patch, ) +from minos.common import ( + DatabaseClient, +) from minos.saga import ( DatabaseSagaExecutionRepository, - SagaExecution, - SagaExecutionNotFoundException, - SagaPausedExecutionStepException, - SagaResponse, + SagaExecutionRepository, +) +from minos.saga.testing import ( + SagaExecutionRepositoryTestCase, ) from tests.utils import ( - ADD_ORDER, - DB_PATH, - Foo, SagaTestCase, ) -class TestDatabaseSagaExecutionRepository(SagaTestCase): - async def asyncSetUp(self) -> None: - await super().asyncSetUp() - - execution = SagaExecution.from_definition(ADD_ORDER) - with self.assertRaises(SagaPausedExecutionStepException): - await execution.execute() - - response = SagaResponse(Foo("hola"), {"ticket"}) - with self.assertRaises(SagaPausedExecutionStepException): - await execution.execute(response) +class TestDatabaseSagaExecutionRepository(SagaTestCase, SagaExecutionRepositoryTestCase): + __test__ = True - self.execution = execution - - def tearDown(self) -> None: - rmtree(DB_PATH, ignore_errors=True) - super().tearDown() + def build_saga_execution_repository(self) -> SagaExecutionRepository: + return DatabaseSagaExecutionRepository.from_config(self.config) async def test_store(self): - async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: - await repository.store(self.execution) - - self.assertEqual(self.execution, await repository.load(self.execution.uuid)) + with patch.object(DatabaseClient, "fetch_one", side_effect=[self.execution.raw]): + await super().test_store() async def test_store_overwrite(self): - async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: - await repository.store(self.execution) - self.assertEqual(self.execution, await repository.load(self.execution.uuid)) - - another = SagaExecution.from_definition(ADD_ORDER) - another.uuid = self.execution.uuid - await repository.store(another) - - self.assertNotEqual(self.execution, await repository.load(self.execution.uuid)) - self.assertEqual(another, await repository.load(self.execution.uuid)) + another_raw = self.another.raw + another_raw["uuid"] = self.execution.uuid + with patch.object(DatabaseClient, "fetch_one", side_effect=[self.execution.raw, another_raw, another_raw]): + await super().test_store_overwrite() async def test_load_from_str(self): - async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: - await repository.store(self.execution) - self.assertEqual(self.execution, await repository.load(str(self.execution.uuid))) + with patch.object(DatabaseClient, "fetch_one", side_effect=[self.execution.raw]): + await super().test_load_from_str() async def test_load_raises(self): - async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: - with self.assertRaises(SagaExecutionNotFoundException): - await repository.load(self.execution.uuid) + with patch.object(DatabaseClient, "fetch_one", side_effect=[None]): + await super().test_load_raises() async def test_delete(self): - async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: - await repository.store(self.execution) - await repository.delete(self.execution) - with self.assertRaises(SagaExecutionNotFoundException): - await repository.load(self.execution.uuid) + with patch.object(DatabaseClient, "fetch_one", side_effect=[None]): + await super().test_delete() async def test_delete_from_str(self): - async with DatabaseSagaExecutionRepository(path=DB_PATH) as repository: - await repository.store(self.execution) - await repository.delete(str(self.execution.uuid)) - with self.assertRaises(SagaExecutionNotFoundException): - await repository.load(self.execution.uuid) + with patch.object(DatabaseClient, "fetch_one", side_effect=[None]): + await super().test_delete_from_str() if __name__ == "__main__": diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py index db8f9bd1c..fa0422c56 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py @@ -14,6 +14,8 @@ ) from minos.common import ( + DatabaseClient, + DatabaseClientPool, NotProvidedException, ) from minos.networks import ( @@ -33,6 +35,9 @@ SagaResponse, SagaStatus, ) +from minos.saga.testing import ( + MockedSagaExecutionDatabaseOperationFactory, +) from tests.utils import ( ADD_ORDER, DB_PATH, @@ -80,8 +85,9 @@ def test_constructor(self): self.assertIsInstance(self.manager, SagaManager) def test_constructor_without_broker(self): + database_pool = DatabaseClientPool.from_config(self.config, identifier="saga") with self.assertRaises(NotProvidedException): - SagaManager.from_config(self.config, broker_pool=None, pool_factory=None) + SagaManager.from_config(self.config, broker_pool=None, pool_factory=None, database_pool=database_pool) async def test_context_manager(self): async with self.manager as saga_manager: @@ -103,7 +109,8 @@ async def test_run_with_pause_on_memory(self): self.assertEqual(SagaStatus.Finished, execution.status) with self.assertRaises(SagaExecutionNotFoundException): - await self.manager.storage.load(execution.uuid) + with patch.object(DatabaseClient, "fetch_one", side_effect=[None]): + await self.manager.storage.load(execution.uuid) observed = self.broker_publisher.messages expected = self._build_expected_messages(observed) @@ -173,15 +180,18 @@ async def test_run_with_pause_on_disk(self): self.assertEqual(SagaStatus.Paused, execution.status) response = SagaResponse([Foo("foo")], {"foo"}, uuid=execution.uuid) - execution = await self.manager.run(response=response, pause_on_disk=True) + with patch.object(DatabaseClient, "fetch_one", side_effect=[execution.raw]): + execution = await self.manager.run(response=response, pause_on_disk=True) self.assertEqual(SagaStatus.Paused, execution.status) response = SagaResponse([Foo("foo")], {"foo"}, uuid=execution.uuid) - execution = await self.manager.run(response=response, pause_on_disk=True) + with patch.object(DatabaseClient, "fetch_one", side_effect=[execution.raw]): + execution = await self.manager.run(response=response, pause_on_disk=True) self.assertEqual(SagaStatus.Finished, execution.status) with self.assertRaises(SagaExecutionNotFoundException): - await self.manager.storage.load(self.uuid) + with patch.object(DatabaseClient, "fetch_one", side_effect=[None]): + await self.manager.storage.load(self.uuid) observed = self.broker_publisher.messages expected = self._build_expected_messages(observed) @@ -194,13 +204,15 @@ async def test_run_with_pause_on_disk_without_commit(self): self.assertEqual(SagaStatus.Paused, execution.status) response = SagaResponse([Foo("foo")], {"foo"}, uuid=execution.uuid) - execution = await self.manager.run(response=response, pause_on_disk=True) + with patch.object(DatabaseClient, "fetch_one", side_effect=[execution.raw]): + execution = await self.manager.run(response=response, pause_on_disk=True) self.assertEqual(SagaStatus.Paused, execution.status) response = SagaResponse([Foo("foo")], {"foo"}, uuid=execution.uuid) with patch("minos.saga.SagaExecution.commit") as commit_mock: - execution = await self.manager.run(response=response, pause_on_disk=True, autocommit=False) + with patch.object(DatabaseClient, "fetch_one", side_effect=[execution.raw]): + execution = await self.manager.run(response=response, pause_on_disk=True, autocommit=False) self.assertEqual(SagaStatus.Finished, execution.status) self.assertEqual(0, commit_mock.call_count) @@ -220,19 +232,27 @@ async def test_run_with_pause_on_disk_with_headers(self): request_headers = {"related_services": "one"} REQUEST_HEADERS_CONTEXT_VAR.set(request_headers) response = SagaResponse([Foo("foo")], {"foo"}, uuid=execution.uuid) - execution = await self.manager.run(response=response, pause_on_disk=True) + with patch.object(DatabaseClient, "fetch_one", side_effect=[execution.raw]): + execution = await self.manager.run(response=response, pause_on_disk=True) self.assertEqual(SagaStatus.Paused, execution.status) self.assertEqual({"foo", "one", "order"}, set(request_headers["related_services"].split(","))) request_headers = {"related_services": "one"} REQUEST_HEADERS_CONTEXT_VAR.set(request_headers) response = SagaResponse([Foo("foo")], {"foo", "bar"}, uuid=execution.uuid) - await self.manager.run(response=response, pause_on_disk=True) + with patch.object(DatabaseClient, "fetch_one", side_effect=[execution.raw]): + await self.manager.run(response=response, pause_on_disk=True) self.assertEqual({"foo", "bar", "one", "order"}, set(request_headers["related_services"].split(","))) async def test_run_with_pause_on_disk_returning_uuid(self): - uuid = await self.manager.run(ADD_ORDER, return_execution=False, pause_on_disk=True) - execution = await self.manager.storage.load(uuid) + with patch.object( + MockedSagaExecutionDatabaseOperationFactory, + "build_store", + side_effect=MockedSagaExecutionDatabaseOperationFactory().build_store, + ) as mock: + uuid = await self.manager.run(ADD_ORDER, return_execution=False, pause_on_disk=True) + with patch.object(DatabaseClient, "fetch_one", side_effect=[mock.call_args.kwargs]): + execution = await self.manager.storage.load(uuid) self.assertIsInstance(execution, SagaExecution) self.assertEqual(SagaStatus.Paused, execution.status) diff --git a/packages/core/minos-microservice-saga/tests/utils.py b/packages/core/minos-microservice-saga/tests/utils.py index f8234e5b6..4a4203831 100644 --- a/packages/core/minos-microservice-saga/tests/utils.py +++ b/packages/core/minos-microservice-saga/tests/utils.py @@ -34,6 +34,7 @@ SagaContext, SagaRequest, SagaResponse, + testing, ) BASE_PATH = Path(__file__).parent @@ -42,6 +43,8 @@ class SagaTestCase(MinosTestCase): + testing_module = testing + def get_config_file_path(self): return CONFIG_FILE_PATH diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py index 825cce17a..3b563b79e 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py @@ -18,8 +18,8 @@ from minos.common import ( DatabaseClient, DatabaseOperation, - MinosAvroDatabaseProtocol, MinosBinaryProtocol, + MinosJsonBinaryProtocol, ) from .operations import ( @@ -38,7 +38,7 @@ def __init__( path: Optional[Union[str, Path]] = None, max_tables: int = 100, map_size: int = int(1e9), - protocol: type[MinosBinaryProtocol] = MinosAvroDatabaseProtocol, + protocol: type[MinosBinaryProtocol] = MinosJsonBinaryProtocol, *args, **kwargs, ): diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py index 381f5793f..264c0f808 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py @@ -1,7 +1,50 @@ +from uuid import ( + UUID, +) + +from minos.common import ( + DatabaseOperation, +) from minos.saga import ( SagaExecutionDatabaseOperationFactory, ) +from ...clients import ( + LmdbDatabaseClient, +) +from ...operations import ( + LmdbDatabaseOperation, + LmdbDatabaseOperationType, +) + class LmdbSagaExecutionDatabaseOperationFactory(SagaExecutionDatabaseOperationFactory): """TODO""" + + # noinspection PyMethodMayBeStatic + def build_table_name(self) -> str: + """Get the table name. + + :return: A ``str`` value. + """ + return "LocalState" + + def build_store(self, uuid: UUID, **kwargs) -> DatabaseOperation: + """TODO""" + key = str(uuid) + value = kwargs | {"uuid": str(uuid)} + + return LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, self.build_table_name(), key, value) + + def build_load(self, uuid: UUID) -> DatabaseOperation: + """TODO""" + key = str(uuid) + return LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, self.build_table_name(), key) + + def build_delete(self, uuid: UUID) -> DatabaseOperation: + """TODO""" + key = str(uuid) + return LmdbDatabaseOperation(LmdbDatabaseOperationType.DELETE, self.build_table_name(), key) + + +LmdbDatabaseClient.set_factory(SagaExecutionDatabaseOperationFactory, LmdbSagaExecutionDatabaseOperationFactory) diff --git a/packages/plugins/minos-database-lmdb/tests/test_config.yml b/packages/plugins/minos-database-lmdb/tests/test_config.yml index 7ac6b848f..1e7658440 100644 --- a/packages/plugins/minos-database-lmdb/tests/test_config.yml +++ b/packages/plugins/minos-database-lmdb/tests/test_config.yml @@ -1,5 +1,10 @@ version: 2 +name: order databases: - foobar: + default: + client: minos.common.testing.MockedDatabaseClient + saga: client: minos.plugins.lmdb.LmdbDatabaseClient - path: "./foobar.lmdb" \ No newline at end of file + path: "./saga.lmdb" +pools: + database: minos.common.DatabaseClientPool \ No newline at end of file diff --git a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/__init__.py b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_repositories.py b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_repositories.py new file mode 100644 index 000000000..33ed57080 --- /dev/null +++ b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_repositories.py @@ -0,0 +1,31 @@ +import unittest +from shutil import ( + rmtree, +) + +from minos.saga import ( + DatabaseSagaExecutionRepository, + SagaExecutionRepository, +) +from minos.saga.testing import ( + SagaExecutionRepositoryTestCase, +) +from tests.utils import ( + LmdbTestCase, +) + + +class TestDatabaseSagaExecutionRepository(LmdbTestCase, SagaExecutionRepositoryTestCase): + __test__ = True + + def build_saga_execution_repository(self) -> SagaExecutionRepository: + return DatabaseSagaExecutionRepository.from_config(self.config) + + def tearDown(self) -> None: + path = self.config.get_database_by_name("saga")["path"] + rmtree(path, ignore_errors=True) + super().tearDown() + + +if __name__ == "__main__": + unittest.main() From 6b30628ba592cbfc5b645b467721451cf9fb53e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 17:36:29 +0200 Subject: [PATCH 266/324] ISSUE #? * Improve integration between `ConfigV1` and `PoolFactory`. * Minor improvements. --- .../aggregate/snapshots/repositories/abc.py | 3 +- .../minos/common/config/v1.py | 49 ++++++++++++++++++- .../minos/common/database/pools.py | 5 -- .../minos/common/locks.py | 4 -- .../test_config/test_v1/test_base.py | 15 ++++-- .../minos-microservice-common/tests/utils.py | 7 ++- .../minos/networks/brokers/pools.py | 2 - 7 files changed, 63 insertions(+), 22 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py index a047d5f16..29f923ff1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/abc.py @@ -190,7 +190,8 @@ async def find_entries( performed to the global snapshot. :param exclude_deleted: If ``True``, deleted ``RootEntity`` entries are included, otherwise deleted ``RootEntity`` entries are filtered. - :param synchronize: TODO + :param synchronize: If ``True`` a synchronization is performed before processing the query, otherwise the query + is performed without any synchronization step. :param kwargs: Additional named arguments. :return: An asynchronous iterator that containing the ``RootEntity`` instances. """ diff --git a/packages/core/minos-microservice-common/minos/common/config/v1.py b/packages/core/minos-microservice-common/minos/common/config/v1.py index d61366029..b7aabd9e6 100644 --- a/packages/core/minos-microservice-common/minos/common/config/v1.py +++ b/packages/core/minos-microservice-common/minos/common/config/v1.py @@ -121,6 +121,27 @@ def _get_saga(self) -> dict[str, Any]: return saga def _get_injections(self) -> list[type[InjectableMixin]]: + from ..pools import ( + Pool, + PoolFactory, + ) + + injections = self._get_raw_injections() + injections = [ + injection + for injection in injections + if not (issubclass(injection, Pool) or issubclass(injection, PoolFactory)) + ] + with suppress(MinosConfigException): + pool_factory = self._get_pools().get("factory") + if pool_factory is not None: + # noinspection PyTypeChecker + injections.insert(0, pool_factory) + + # noinspection PyTypeChecker + return injections + + def _get_raw_injections(self) -> list[type[InjectableMixin]]: try: injections = self.get_by_key("service.injections") if isinstance(injections, dict): @@ -217,7 +238,31 @@ def _get_services(self) -> list[type]: return services def _get_pools(self) -> dict[str, type]: - return dict() + from ..pools import ( + Pool, + PoolFactory, + ) + + factory = next( + (injection for injection in self._get_raw_injections() if issubclass(injection, PoolFactory)), PoolFactory + ) + injections = [injection for injection in self._get_raw_injections() if issubclass(injection, Pool)] + if not len(injections): + return dict() + + types = dict() + for injection in injections: + if "lock" in injection.__name__.lower(): + types["lock"] = injection + elif "database" in injection.__name__.lower(): + types["database"] = injection + elif "broker" in injection.__name__.lower(): + types["broker"] = injection + + return { + "factory": factory, + "types": types, + } def _get_routers(self) -> list[type]: try: @@ -266,7 +311,7 @@ def _get_database_broker(self): return self._get_database_by_name("broker.queue") def _get_database_saga(self) -> dict[str, Any]: - raw = self.get_by_key("saga.storage") + raw = self._get_database_by_name("saga.storage") return raw def _get_database_event(self) -> dict[str, Any]: diff --git a/packages/core/minos-microservice-common/minos/common/database/pools.py b/packages/core/minos-microservice-common/minos/common/database/pools.py index f12ec25c8..70b2ff54a 100644 --- a/packages/core/minos-microservice-common/minos/common/database/pools.py +++ b/packages/core/minos-microservice-common/minos/common/database/pools.py @@ -16,9 +16,6 @@ from ..config import ( Config, ) -from ..injections import ( - Injectable, -) from ..locks import ( LockPool, ) @@ -37,7 +34,6 @@ logger = logging.getLogger(__name__) -@Injectable("database_pool") class DatabaseClientPool(Pool[DatabaseClient]): """Database Client Pool class.""" @@ -49,7 +45,6 @@ def __init__(self, client_builder: DatabaseClientBuilder, *args, **kwargs): @classmethod def _from_config(cls, config: Config, identifier: Optional[str] = None, **kwargs): base_builder = config.get_database_by_name(identifier).get("client") - if base_builder is None: raise ValueError(f"{base_builder!r} is not a {DatabaseClientBuilder!r} instance.") elif issubclass(base_builder, DatabaseClient): diff --git a/packages/core/minos-microservice-common/minos/common/locks.py b/packages/core/minos-microservice-common/minos/common/locks.py index f26f0019a..bf21dbf6b 100644 --- a/packages/core/minos-microservice-common/minos/common/locks.py +++ b/packages/core/minos-microservice-common/minos/common/locks.py @@ -14,9 +14,6 @@ cached_property, ) -from .injections import ( - Injectable, -) from .pools import ( Pool, ) @@ -65,6 +62,5 @@ def hashed_key(self) -> int: return self.key -@Injectable("lock_pool") class LockPool(Pool[Lock], ABC): """Lock Pool class.""" diff --git a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py index f73eb24dc..8f9421473 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_config/test_v1/test_base.py @@ -7,6 +7,7 @@ Config, ConfigV1, MinosConfigException, + PoolFactory, ) from tests.utils import ( BASE_PATH, @@ -51,9 +52,7 @@ def test_name(self): def test_injections(self): expected = [ - FakeLockPool, - FakeDatabasePool, - FakeBrokerClientPool, + PoolFactory, FakeHttpConnector, FakeBrokerPublisher, FakeBrokerSubscriberBuilder, @@ -185,7 +184,15 @@ def test_interface_unknown(self): config.get_interface_by_name("unknown") def test_pools(self): - self.assertEqual(dict(), self.config.get_pools()) + expected = { + "factory": PoolFactory, + "types": { + "lock": FakeLockPool, + "database": FakeDatabasePool, + "broker": FakeBrokerClientPool, + }, + } + self.assertEqual(expected, self.config.get_pools()) def test_services(self): self.assertEqual([float, int], self.config.get_services()) diff --git a/packages/core/minos-microservice-common/tests/utils.py b/packages/core/minos-microservice-common/tests/utils.py index b7090bbae..5180a96c9 100644 --- a/packages/core/minos-microservice-common/tests/utils.py +++ b/packages/core/minos-microservice-common/tests/utils.py @@ -12,6 +12,7 @@ Injectable, Lock, LockPool, + Pool, Port, testing, ) @@ -163,13 +164,11 @@ class FakeBrokerSubscriberBuilder(Builder[FakeBrokerSubscriber]): FakeBrokerSubscriber.set_builder(FakeBrokerSubscriberBuilder) -@Injectable("database_pool") -class FakeDatabasePool: +class FakeDatabasePool(Pool): """For testing purposes.""" -@Injectable("broker_pool") -class FakeBrokerClientPool: +class FakeBrokerClientPool(Pool): """For testing purposes.""" diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py b/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py index 66df5475c..ecb298245 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py @@ -14,7 +14,6 @@ from minos.common import ( Config, - Injectable, Pool, ) @@ -28,7 +27,6 @@ logger = logging.getLogger(__name__) -@Injectable("broker_pool") class BrokerClientPool(Pool): """Broker Client Pool class.""" From f656e920ca3f2ba1d1cf9b76cbd7cc0630c79108 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 17:47:27 +0200 Subject: [PATCH 267/324] ISSUE #99 * Minos change --- .../plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py | 1 + .../plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py index b8ffc4a15..98c192e2a 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py @@ -12,4 +12,5 @@ ) from .operations import ( LmdbDatabaseOperation, + LmdbDatabaseOperationType, ) diff --git a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py index 6f793ffeb..542306f6c 100644 --- a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py +++ b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py @@ -11,8 +11,6 @@ from minos.plugins.lmdb import ( LmdbDatabaseClient, LmdbDatabaseOperation, -) -from minos.plugins.lmdb.operations import ( LmdbDatabaseOperationType, ) from tests.utils import ( From 13a852db8b9da124bd6cc58b12959c6f0fd3908d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Mon, 18 Apr 2022 17:53:58 +0200 Subject: [PATCH 268/324] ISSUE #99 * Add docstring. --- .../minos/saga/executions/repositories/abc.py | 2 +- .../repositories/database/factories.py | 21 +++++++++++++++---- .../minos/plugins/lmdb/clients.py | 2 +- .../plugins/lmdb/factories/saga/executions.py | 21 +++++++++++++++---- .../minos/plugins/lmdb/operations.py | 4 ++-- 5 files changed, 38 insertions(+), 12 deletions(-) diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/abc.py b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/abc.py index 4bc0987eb..b5943b36c 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/abc.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/abc.py @@ -19,7 +19,7 @@ class SagaExecutionRepository(SetupMixin, ABC): - """TODO""" + """Saga Execution Repository class.""" async def store(self, execution: SagaExecution) -> None: """Store an execution. diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/factories.py b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/factories.py index 408df38ee..6ed321b40 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/factories.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/factories.py @@ -13,19 +13,32 @@ class SagaExecutionDatabaseOperationFactory(DatabaseOperationFactory, ABC): - """TODO""" + """Saga Execution Database Operation Factory class.""" @abstractmethod def build_store(self, uuid: UUID, **kwargs) -> DatabaseOperation: - """TODO""" + """Build the database operation to store a saga execution. + + :param uuid: The identifier of the saga execution. + :param kwargs: The attributes of the saga execution. + :return: A ``DatabaseOperation`` instance. + """ raise NotImplementedError @abstractmethod def build_load(self, uuid: UUID) -> DatabaseOperation: - """TODO""" + """Build the database operation to load a saga execution. + + :param uuid: The identifier of the saga execution. + :return: A ``DatabaseOperation`` instance. + """ raise NotImplementedError @abstractmethod def build_delete(self, uuid: UUID) -> DatabaseOperation: - """TODO""" + """Build the database operation to delete a saga execution. + + :param uuid: The identifier of the saga execution. + :return: A ``DatabaseOperation`` instance. + """ raise NotImplementedError diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py index 3b563b79e..5e0a6fdad 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py @@ -29,7 +29,7 @@ class LmdbDatabaseClient(DatabaseClient): - """TODO""" + """Lmdb Database Client class.""" _environment: Optional[Environment] diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py index 264c0f808..a3919f478 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/factories/saga/executions.py @@ -19,7 +19,7 @@ class LmdbSagaExecutionDatabaseOperationFactory(SagaExecutionDatabaseOperationFactory): - """TODO""" + """Lmdb Saga Execution Database Operation Factory class.""" # noinspection PyMethodMayBeStatic def build_table_name(self) -> str: @@ -30,19 +30,32 @@ def build_table_name(self) -> str: return "LocalState" def build_store(self, uuid: UUID, **kwargs) -> DatabaseOperation: - """TODO""" + """Build the database operation to store a saga execution. + + :param uuid: The identifier of the saga execution. + :param kwargs: The attributes of the saga execution. + :return: A ``DatabaseOperation`` instance. + """ key = str(uuid) value = kwargs | {"uuid": str(uuid)} return LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, self.build_table_name(), key, value) def build_load(self, uuid: UUID) -> DatabaseOperation: - """TODO""" + """Build the database operation to load a saga execution. + + :param uuid: The identifier of the saga execution. + :return: A ``DatabaseOperation`` instance. + """ key = str(uuid) return LmdbDatabaseOperation(LmdbDatabaseOperationType.READ, self.build_table_name(), key) def build_delete(self, uuid: UUID) -> DatabaseOperation: - """TODO""" + """Build the database operation to delete a saga execution. + + :param uuid: The identifier of the saga execution. + :return: A ``DatabaseOperation`` instance. + """ key = str(uuid) return LmdbDatabaseOperation(LmdbDatabaseOperationType.DELETE, self.build_table_name(), key) diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py index f21ba3b03..908a4abd7 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/operations.py @@ -12,7 +12,7 @@ class LmdbDatabaseOperationType(str, Enum): - """TODO""" + """Lmdb Database Operation Type class.""" CREATE = "create" READ = "read" @@ -21,7 +21,7 @@ class LmdbDatabaseOperationType(str, Enum): class LmdbDatabaseOperation(DatabaseOperation): - """TODO""" + """Lmdb Database Operation class.""" def __init__( self, type_: LmdbDatabaseOperationType, table: str, key: str, value: Optional[Any] = None, *args, **kwargs From 457e95c46383b3dce40b13911a0a5fb7384994e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 19 Apr 2022 08:50:35 +0200 Subject: [PATCH 269/324] ISSUE #99 * Add tests for `SagaExecutionRepository`. --- .../test_repositories/test_abc.py | 96 +++++++++++++++++++ 1 file changed, 96 insertions(+) create mode 100644 packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_abc.py diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_abc.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_abc.py new file mode 100644 index 000000000..9fc19f32a --- /dev/null +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_abc.py @@ -0,0 +1,96 @@ +import unittest +from unittest.mock import ( + AsyncMock, + call, +) +from uuid import ( + UUID, +) + +from minos.saga import ( + SagaExecution, + SagaExecutionRepository, +) +from tests.utils import ( + ADD_ORDER, + SagaTestCase, +) + + +class _SagaExecutionRepository(SagaExecutionRepository): + async def _store(self, execution: SagaExecution) -> None: + """For testing purposes.""" + + async def _load(self, uuid: UUID) -> SagaExecution: + """For testing purposes.""" + + async def _delete(self, key: UUID) -> None: + """For testing purposes.""" + + +class TestSagaExecutionRepository(SagaTestCase): + async def test_store(self): + mock = AsyncMock() + repository = _SagaExecutionRepository() + repository._store = mock + execution = SagaExecution.from_definition(ADD_ORDER) + + await repository.store(execution) + + self.assertEqual([call(execution)], mock.call_args_list) + + async def test_load(self): + execution = SagaExecution.from_definition(ADD_ORDER) + repository = _SagaExecutionRepository() + mock = AsyncMock(return_value=execution) + repository._load = mock + + observed = await repository.load(execution.uuid) + + self.assertEqual(execution, observed) + self.assertEqual([call(execution.uuid)], mock.call_args_list) + + async def test_load_from_str(self): + execution = SagaExecution.from_definition(ADD_ORDER) + repository = _SagaExecutionRepository() + mock = AsyncMock(return_value=execution) + repository._load = mock + + observed = await repository.load(str(execution.uuid)) + + self.assertEqual(execution, observed) + self.assertEqual([call(execution.uuid)], mock.call_args_list) + + async def test_delete(self): + execution = SagaExecution.from_definition(ADD_ORDER) + repository = _SagaExecutionRepository() + mock = AsyncMock(return_value=execution) + repository._delete = mock + + await repository.delete(execution) + + self.assertEqual([call(execution.uuid)], mock.call_args_list) + + async def test_delete_from_uuid(self): + execution = SagaExecution.from_definition(ADD_ORDER) + repository = _SagaExecutionRepository() + mock = AsyncMock(return_value=execution) + repository._delete = mock + + await repository.delete(execution.uuid) + + self.assertEqual([call(execution.uuid)], mock.call_args_list) + + async def test_delete_from_str(self): + execution = SagaExecution.from_definition(ADD_ORDER) + repository = _SagaExecutionRepository() + mock = AsyncMock(return_value=execution) + repository._delete = mock + + await repository.delete(str(execution.uuid)) + + self.assertEqual([call(execution.uuid)], mock.call_args_list) + + +if __name__ == "__main__": + unittest.main() From 305567cb44e37f66f7cd094c75e0f01ff49e17e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 19 Apr 2022 09:01:07 +0200 Subject: [PATCH 270/324] ISSUE #99 * Add tests for `LmdbSagaExecutionDatabaseOperationFactory`. --- .../__init__.py | 0 .../test_database/test_factories.py | 24 ++++++++++ .../test_impl.py | 0 .../test_saga/test_factories.py | 44 +++++++++++++++++++ 4 files changed, 68 insertions(+) rename packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/{test_databases => test_database}/__init__.py (100%) create mode 100644 packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_factories.py rename packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/{test_databases => test_database}/test_impl.py (100%) create mode 100644 packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_factories.py diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/__init__.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/__init__.py similarity index 100% rename from packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/__init__.py rename to packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/__init__.py diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_factories.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_factories.py new file mode 100644 index 000000000..7471a2f38 --- /dev/null +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_factories.py @@ -0,0 +1,24 @@ +import unittest +from abc import ( + ABC, +) + +from minos.common import ( + DatabaseOperationFactory, +) +from minos.saga import ( + SagaExecutionDatabaseOperationFactory, +) + + +class TestSagaExecutionDatabaseOperationFactory(unittest.TestCase): + def test_abstract(self): + self.assertTrue(issubclass(SagaExecutionDatabaseOperationFactory, (DatabaseOperationFactory, ABC))) + # noinspection PyUnresolvedReferences + self.assertEqual( + {"build_store", "build_load", "build_delete"}, SagaExecutionDatabaseOperationFactory.__abstractmethods__ + ) + + +if __name__ == '__main__': + unittest.main() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/test_impl.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_impl.py similarity index 100% rename from packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_databases/test_impl.py rename to packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_impl.py diff --git a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_factories.py b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_factories.py new file mode 100644 index 000000000..f02d48b3f --- /dev/null +++ b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_factories.py @@ -0,0 +1,44 @@ +import unittest +from uuid import ( + uuid4, +) + +from minos.plugins.lmdb import ( + LmdbDatabaseOperation, + LmdbDatabaseOperationType, + LmdbSagaExecutionDatabaseOperationFactory, +) +from minos.saga import ( + SagaExecutionDatabaseOperationFactory, +) + + +class TestLmdbSagaExecutionDatabaseOperationFactory(unittest.TestCase): + def test_is_subclass(self): + self.assertTrue(issubclass(LmdbSagaExecutionDatabaseOperationFactory, SagaExecutionDatabaseOperationFactory)) + + def test_build_store(self): + factory = LmdbSagaExecutionDatabaseOperationFactory() + + operation = factory.build_store(uuid4(), foo="bar") + self.assertIsInstance(operation, LmdbDatabaseOperation) + self.assertEqual(LmdbDatabaseOperationType.CREATE, operation.type_) + + def test_build_load(self): + pass + factory = LmdbSagaExecutionDatabaseOperationFactory() + + operation = factory.build_load(uuid4()) + self.assertIsInstance(operation, LmdbDatabaseOperation) + self.assertEqual(LmdbDatabaseOperationType.READ, operation.type_) + + def test_build_delete(self): + factory = LmdbSagaExecutionDatabaseOperationFactory() + + operation = factory.build_delete(uuid4()) + self.assertIsInstance(operation, LmdbDatabaseOperation) + self.assertEqual(LmdbDatabaseOperationType.DELETE, operation.type_) + + +if __name__ == "__main__": + unittest.main() From 4394cb5f4f63bc3c37862cd7bc0df39c7a92223a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 19 Apr 2022 09:05:34 +0200 Subject: [PATCH 271/324] ISSUE #99 * Remove `lmdb` dependency from `minos-microservice-common`. * Remove `MinosStorage` and `MinosStorageLmdb` classes from `minos-microservice-common`. --- .../minos/common/__init__.py | 4 - .../minos/common/storage/__init__.py | 6 - .../minos/common/storage/abc.py | 62 ---------- .../minos/common/storage/lmdb.py | 115 ------------------ .../minos-microservice-common/poetry.lock | 39 +----- .../minos-microservice-common/pyproject.toml | 1 - .../test_common/test_storage/__init__.py | 1 - .../test_common/test_storage/test_lmdb.py | 105 ---------------- .../test_database/test_factories.py | 2 +- 9 files changed, 2 insertions(+), 333 deletions(-) delete mode 100644 packages/core/minos-microservice-common/minos/common/storage/__init__.py delete mode 100644 packages/core/minos-microservice-common/minos/common/storage/abc.py delete mode 100644 packages/core/minos-microservice-common/minos/common/storage/lmdb.py delete mode 100644 packages/core/minos-microservice-common/tests/test_common/test_storage/__init__.py delete mode 100644 packages/core/minos-microservice-common/tests/test_common/test_storage/test_lmdb.py diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 968bd051a..1c38ac410 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -133,10 +133,6 @@ MinosSetup, SetupMixin, ) -from .storage import ( - MinosStorage, - MinosStorageLmdb, -) from .uuid import ( NULL_UUID, UUID_REGEX, diff --git a/packages/core/minos-microservice-common/minos/common/storage/__init__.py b/packages/core/minos-microservice-common/minos/common/storage/__init__.py deleted file mode 100644 index 18d5870d3..000000000 --- a/packages/core/minos-microservice-common/minos/common/storage/__init__.py +++ /dev/null @@ -1,6 +0,0 @@ -from .abc import ( - MinosStorage, -) -from .lmdb import ( - MinosStorageLmdb, -) diff --git a/packages/core/minos-microservice-common/minos/common/storage/abc.py b/packages/core/minos-microservice-common/minos/common/storage/abc.py deleted file mode 100644 index cefc9292f..000000000 --- a/packages/core/minos-microservice-common/minos/common/storage/abc.py +++ /dev/null @@ -1,62 +0,0 @@ -from __future__ import ( - annotations, -) - -from abc import ( - ABC, - abstractmethod, -) -from typing import ( - Any, - Optional, -) - - -class MinosStorage(ABC): - """Minos Storage interface.""" - - @abstractmethod - def add(self, **kwargs) -> None: - """Store a value. - - :param kwargs: Additional named arguments. - :return: This method does not return anything. - """ - raise NotImplementedError - - @abstractmethod - def get(self, **kwargs) -> Optional[Any]: - """Get the stored value.. - - :param kwargs: Additional named arguments. - :return: The stored value. - """ - raise NotImplementedError - - @abstractmethod - def delete(self, **kwargs) -> None: - """Delete the stored value. - - :param kwargs: - :return: This method does not return anything. - """ - raise NotImplementedError - - @abstractmethod - def update(self, **kwargs) -> None: - """Update the stored value. - - :param kwargs: Additional named arguments. - :return: This method does not return anything. - """ - raise NotImplementedError - - @classmethod - @abstractmethod - def build(cls, **kwargs) -> MinosStorage: - """Build a new instance. - - :param kwargs: Additional named arguments. - :return: A new ``MinosStorage`` instance. - """ - raise NotImplementedError diff --git a/packages/core/minos-microservice-common/minos/common/storage/lmdb.py b/packages/core/minos-microservice-common/minos/common/storage/lmdb.py deleted file mode 100644 index 3e1a1ed26..000000000 --- a/packages/core/minos-microservice-common/minos/common/storage/lmdb.py +++ /dev/null @@ -1,115 +0,0 @@ -from __future__ import ( - annotations, -) - -from pathlib import ( - Path, -) -from typing import ( - Any, - Optional, - Type, - Union, -) - -import lmdb - -from ..protocol import ( - MinosAvroDatabaseProtocol, - MinosBinaryProtocol, -) -from .abc import ( - MinosStorage, -) - - -class MinosStorageLmdb(MinosStorage): - """Minos Storage LMDB class""" - - __slots__ = "_env", "_protocol", "_tables" - - # noinspection PyUnusedLocal - def __init__( - self, env: lmdb.Environment, protocol: Type[MinosBinaryProtocol] = MinosAvroDatabaseProtocol, **kwargs - ): - self._env: lmdb.Environment = env - self._protocol = protocol - self._tables = {} - - def add(self, table: str, key: str, value: Any) -> None: - """Store a value. - - :param table: Table in which the data is stored. - :param key: Key that identifies the data. - :param value: Data to be stored. - :return: This method does not return anything. - """ - db_instance = self._get_table(table) - with self._env.begin(write=True) as txn: - value_bytes: bytes = self._protocol.encode(value) - txn.put(key.encode(), value_bytes, db=db_instance) - - def get(self, table: str, key: str) -> Optional[Any]: - """Get the stored value.. - - :param table: Table in which the data is stored. - :param key: Key that identifies the data. - :return: The stored value or ``None`` if it's empty. - """ - db_instance = self._get_table(table) - with self._env.begin(db=db_instance) as txn: - value_binary = txn.get(key.encode()) - if value_binary is not None: - # decode the returned value - return self._protocol.decode(value_binary) - return None - - def delete(self, table: str, key: str) -> None: - """Delete the stored value. - - :param table: Table in which the data is stored. - :param key: Key that identifies the data. - :return: This method does not return anything. - """ - db_instance = self._get_table(table) - with self._env.begin(write=True, db=db_instance) as txn: - txn.delete(key.encode()) - - def update(self, table: str, key: str, value: Any) -> None: - """Update the stored value. - - :param table: Table in which the data is stored. - :param key: Key that identifies the data. - :param value: Data to be stored. - :return: This method does not return anything. - """ - db_instance = self._get_table(table) - with self._env.begin(write=True, db=db_instance) as txn: - value_bytes: bytes = self._protocol.encode(value) - txn.put(key.encode(), value_bytes, db=db_instance, overwrite=True) - - def _get_table(self, table: str): - if table in self._tables: - return self._tables[table] - else: - # create a new table - self._tables[table] = self._env.open_db(table.encode()) - return self._tables[table] - - @classmethod - def build( - cls, path: Optional[Union[str, Path]] = None, max_db: int = 10, map_size: int = int(1e9), **kwargs - ) -> MinosStorageLmdb: - """Build a new instance. - - :param path: Path in which the database is stored. - :param max_db: Maximum number of available databases. - :param map_size: Maximum number of entries to be stored on the database. Default set to 1GB - :param kwargs: Additional named arguments. - :return: A ``MinosStorageLmdb`` instance. - """ - if path is None: - path = ".lmdb" - - env: lmdb.Environment = lmdb.open(str(path), max_dbs=max_db, map_size=map_size) - return cls(env, **kwargs) diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index 65af87063..ee5ec595e 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -181,14 +181,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -360,7 +352,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "fa95fd5d2d8811d958396a78489d81ebc4f8945e7b4139e9e94b1d2797bb1377" +content-hash = "a9c5c5ba881792ac49e650321cd77db64874c6c55089b3d7f14a992a272f50f6" [metadata.files] aiomisc = [ @@ -527,35 +519,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index 8e3b573ae..c3fd9aa9a 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -34,7 +34,6 @@ python = "^3.9" aiomisc = ">=14.0.3,<15.8.0" fastavro = "^1.4.0" orjson = "^3.5.2" -lmdb = "^1.2.1" PyYAML = ">=5.4.1,<7.0.0" dependency-injector = "^4.32.2" cached-property = "^1.5.2" diff --git a/packages/core/minos-microservice-common/tests/test_common/test_storage/__init__.py b/packages/core/minos-microservice-common/tests/test_common/test_storage/__init__.py deleted file mode 100644 index 8b1378917..000000000 --- a/packages/core/minos-microservice-common/tests/test_common/test_storage/__init__.py +++ /dev/null @@ -1 +0,0 @@ - diff --git a/packages/core/minos-microservice-common/tests/test_common/test_storage/test_lmdb.py b/packages/core/minos-microservice-common/tests/test_common/test_storage/test_lmdb.py deleted file mode 100644 index 7245670b5..000000000 --- a/packages/core/minos-microservice-common/tests/test_common/test_storage/test_lmdb.py +++ /dev/null @@ -1,105 +0,0 @@ -import shutil -import unittest -from pathlib import ( - Path, -) - -from minos.common import ( - MinosStorageLmdb, -) -from tests.utils import ( - BASE_PATH, -) - - -class TestMinosStorageLmdb(unittest.TestCase): - def setUp(self) -> None: - self.path = BASE_PATH / "order.lmdb" - - def tearDown(self) -> None: - shutil.rmtree(self.path, ignore_errors=True) - shutil.rmtree(".lmdb", ignore_errors=True) - - def test_constructor_default_path(self): - MinosStorageLmdb.build() - self.assertTrue(Path(".lmdb").exists()) - - def test_storage_add_text(self): - storage = MinosStorageLmdb.build(self.path) - storage.add("TestOne", "first", "Text Value") - - value_returned = storage.get("TestOne", "first") - assert value_returned == "Text Value" - - def test_storage_add_int(self): - storage = MinosStorageLmdb.build(self.path) - storage.add("TestOne", "first", 123) - - value_returned = storage.get("TestOne", "first") - assert value_returned == 123 - - def test_storage_add_dict(self): - storage = MinosStorageLmdb.build(self.path) - storage.add("TestOne", "first", {"key_one": "hello", "key_two": "minos"}) - - value_returned = storage.get("TestOne", "first") - assert value_returned["key_one"] == "hello" - assert value_returned["key_two"] == "minos" - - def test_storage_add_multi_dict(self): - storage = MinosStorageLmdb.build(self.path) - storage.add("TestOne", "first", {"key_one": "hello", "key_two": {"sub_key": "this is a sub text"}}) - - value_returned = storage.get("TestOne", "first") - assert value_returned["key_one"] == "hello" - assert value_returned["key_two"]["sub_key"] == "this is a sub text" - - def test_storage_add_list(self): - storage = MinosStorageLmdb.build(self.path) - storage.add("TestOne", "first", ["hello", "minos"]) - - value_returned = storage.get("TestOne", "first") - assert value_returned[0] == "hello" - assert value_returned[1] == "minos" - - def test_storage_add_multi_table(self): - storage = MinosStorageLmdb.build(self.path) - storage.add("TestOne", "first", "Text Value") - storage.add("TestTwo", "first_double", "Text Double Value") - storage.add("TestTwo", "first", "Text Value Diff") - - value_returned = storage.get("TestOne", "first") - assert value_returned == "Text Value" - - value_returned = storage.get("TestTwo", "first_double") - assert value_returned == "Text Double Value" - - value_returned = storage.get("TestTwo", "first") - assert value_returned == "Text Value Diff" - - def test_storage_delete(self): - storage = MinosStorageLmdb.build(self.path) - storage.add("TestOne", "first", "Text Value") - storage.add("TestOne", "second", "Text Second Value") - - storage.delete("TestOne", "first") - value_returned = storage.get("TestOne", "second") - assert value_returned == "Text Second Value" - - exception_value = storage.get("TestOne", "first") - assert exception_value is None - - def test_storage_update(self): - storage = MinosStorageLmdb.build(self.path) - storage.add("TestOne", "first", "Text Value") - - value_returned = storage.get("TestOne", "first") - assert value_returned == "Text Value" - - storage.update("TestOne", "first", "Updated Text Value") - updated_value = storage.get("TestOne", "first") - assert updated_value == "Updated Text Value" - - -if __name__ == "__main__": - unittest.main() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_factories.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_factories.py index 7471a2f38..b49d2f91c 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_factories.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_factories.py @@ -20,5 +20,5 @@ def test_abstract(self): ) -if __name__ == '__main__': +if __name__ == "__main__": unittest.main() From 74b480d550a665a9eb53eab8dadeea2041a6e1bc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 19 Apr 2022 09:22:30 +0200 Subject: [PATCH 272/324] ISSUE #99 * Add support for handling of not found cases to `LmdbDatabaseClient`. --- .../minos/common/database/mixins.py | 7 +++++-- .../executions/repositories/database/impl.py | 6 ++++-- .../test_repositories/test_database/test_impl.py | 7 ++++--- .../tests/test_saga/test_manager.py | 5 +++-- .../minos/plugins/lmdb/clients.py | 16 +++++++++------- .../tests/test_lmdb/test_clients.py | 4 +++- .../test_factories/test_saga/test_factories.py | 1 - 7 files changed, 28 insertions(+), 18 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/mixins.py b/packages/core/minos-microservice-common/minos/common/database/mixins.py index 48c64a06e..3042a2650 100644 --- a/packages/core/minos-microservice-common/minos/common/database/mixins.py +++ b/packages/core/minos-microservice-common/minos/common/database/mixins.py @@ -1,8 +1,11 @@ +from collections.abc import ( + AsyncIterator, +) from contextlib import ( suppress, ) from typing import ( - AsyncIterator, + Any, Generic, Optional, TypeVar, @@ -101,7 +104,7 @@ def _get_generic_operation_factory(self) -> Optional[type[GenericDatabaseOperati raise TypeError(f"{type(self)!r} must contain a {DatabaseOperationFactory!r} as generic value.") return operation_factory_cls - async def execute_on_database_and_fetch_one(self, operation: DatabaseOperation) -> tuple: + async def execute_on_database_and_fetch_one(self, operation: DatabaseOperation) -> Any: """Submit an Operation and get the first response. :param operation: The operation to be executed. diff --git a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py index 98a7d20b8..958acad7a 100644 --- a/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py +++ b/packages/core/minos-microservice-saga/minos/saga/executions/repositories/database/impl.py @@ -11,6 +11,7 @@ from minos.common import ( DatabaseMixin, + ProgrammingException, ) from ....exceptions import ( @@ -46,8 +47,9 @@ async def _delete(self, uuid: UUID) -> None: async def _load(self, uuid: UUID) -> SagaExecution: operation = self.database_operation_factory.build_load(uuid) - value = await self.execute_on_database_and_fetch_one(operation) - if value is None: + try: + value = await self.execute_on_database_and_fetch_one(operation) + except ProgrammingException: raise SagaExecutionNotFoundException(f"The execution identified by {uuid} was not found.") execution = SagaExecution.from_raw(value) return execution diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_impl.py b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_impl.py index 39169fb29..a0f2a74d1 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_impl.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_executions/test_repositories/test_database/test_impl.py @@ -5,6 +5,7 @@ from minos.common import ( DatabaseClient, + ProgrammingException, ) from minos.saga import ( DatabaseSagaExecutionRepository, @@ -39,15 +40,15 @@ async def test_load_from_str(self): await super().test_load_from_str() async def test_load_raises(self): - with patch.object(DatabaseClient, "fetch_one", side_effect=[None]): + with patch.object(DatabaseClient, "fetch_one", side_effect=[ProgrammingException("")]): await super().test_load_raises() async def test_delete(self): - with patch.object(DatabaseClient, "fetch_one", side_effect=[None]): + with patch.object(DatabaseClient, "fetch_one", side_effect=[ProgrammingException("")]): await super().test_delete() async def test_delete_from_str(self): - with patch.object(DatabaseClient, "fetch_one", side_effect=[None]): + with patch.object(DatabaseClient, "fetch_one", side_effect=[ProgrammingException("")]): await super().test_delete_from_str() diff --git a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py index fa0422c56..7f4454941 100644 --- a/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py +++ b/packages/core/minos-microservice-saga/tests/test_saga/test_manager.py @@ -17,6 +17,7 @@ DatabaseClient, DatabaseClientPool, NotProvidedException, + ProgrammingException, ) from minos.networks import ( REQUEST_HEADERS_CONTEXT_VAR, @@ -109,7 +110,7 @@ async def test_run_with_pause_on_memory(self): self.assertEqual(SagaStatus.Finished, execution.status) with self.assertRaises(SagaExecutionNotFoundException): - with patch.object(DatabaseClient, "fetch_one", side_effect=[None]): + with patch.object(DatabaseClient, "fetch_one", side_effect=[ProgrammingException("")]): await self.manager.storage.load(execution.uuid) observed = self.broker_publisher.messages @@ -190,7 +191,7 @@ async def test_run_with_pause_on_disk(self): self.assertEqual(SagaStatus.Finished, execution.status) with self.assertRaises(SagaExecutionNotFoundException): - with patch.object(DatabaseClient, "fetch_one", side_effect=[None]): + with patch.object(DatabaseClient, "fetch_one", side_effect=[ProgrammingException("")]): await self.manager.storage.load(self.uuid) observed = self.broker_publisher.messages diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py index 5e0a6fdad..317728701 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py @@ -27,6 +27,8 @@ LmdbDatabaseOperationType, ) +not_found_sentinel = object() + class LmdbDatabaseClient(DatabaseClient): """Lmdb Database Client class.""" @@ -52,7 +54,7 @@ def __init__( self._protocol = protocol self._tables = {} - self._prefetched = None + self._prefetched = not_found_sentinel self._environment = None @@ -79,8 +81,10 @@ async def _reset(self, **kwargs) -> None: self._environment.sync() async def _fetch_all(self, *args, **kwargs) -> Any: + if self._prefetched is not_found_sentinel: + return prefetched = self._prefetched - self._prefetched = None + self._prefetched = not_found_sentinel yield prefetched async def _execute(self, operation: DatabaseOperation) -> None: @@ -109,11 +113,9 @@ def _create(self, table: str, key: str, value: Any, **kwargs) -> None: def _read(self, table: str, key: str, **kwargs): table = self._get_table(table) with self._environment.begin(db=table) as transaction: - value_binary = transaction.get(key.encode()) - if value_binary is not None: - value = self._protocol.decode(value_binary) - else: - value = None + value = transaction.get(key.encode(), default=not_found_sentinel) + if value is not not_found_sentinel: + value = self._protocol.decode(value) self._prefetched = value diff --git a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py index 542306f6c..5c772f2ff 100644 --- a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py +++ b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_clients.py @@ -7,6 +7,7 @@ from minos.common import ( DatabaseClient, DatabaseOperation, + ProgrammingException, ) from minos.plugins.lmdb import ( LmdbDatabaseClient, @@ -146,7 +147,8 @@ async def test_execute_delete(self): self.assertEqual("Text Second Value", await client.fetch_one()) await client.execute(read_op_2) - self.assertEqual(None, await client.fetch_one()) + with self.assertRaises(ProgrammingException): + self.assertEqual(None, await client.fetch_one()) async def test_execute_update(self): create_op = LmdbDatabaseOperation(LmdbDatabaseOperationType.CREATE, "TestOne", "first", "Text Value") diff --git a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_factories.py b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_factories.py index f02d48b3f..e1e3fd274 100644 --- a/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_factories.py +++ b/packages/plugins/minos-database-lmdb/tests/test_lmdb/test_factories/test_saga/test_factories.py @@ -25,7 +25,6 @@ def test_build_store(self): self.assertEqual(LmdbDatabaseOperationType.CREATE, operation.type_) def test_build_load(self): - pass factory = LmdbSagaExecutionDatabaseOperationFactory() operation = factory.build_load(uuid4()) From bb819b876d1c448edcf28d977113120d40ce277f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 19 Apr 2022 09:29:11 +0200 Subject: [PATCH 273/324] ISSUE #99 * Minor improvement. --- packages/plugins/minos-database-lmdb/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/plugins/minos-database-lmdb/README.md b/packages/plugins/minos-database-lmdb/README.md index 97d6019de..caf05926b 100644 --- a/packages/plugins/minos-database-lmdb/README.md +++ b/packages/plugins/minos-database-lmdb/README.md @@ -27,9 +27,9 @@ Set the database client on the `config.yml` file: ```yaml ... databases: - foobar: + saga: client: minos.plugins.lmdb.LmdbDatabaseClient - path: "./foobar.lmdb" + path: "./saga.lmdb" ... ... ``` From de05f5c44ac3efbbbe6eacac0240f8888b392aed Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Tue, 19 Apr 2022 09:56:38 +0200 Subject: [PATCH 274/324] ISSUE #390 --- .../minos/plugins/kong/client.py | 45 +++++++++++++++++-- .../plugins/minos-discovery-kong/poetry.lock | 32 ++++++++++++- .../minos-discovery-kong/pyproject.toml | 2 + .../tests/test_config.yml | 1 + .../tests/test_kong/test_client.py | 41 +++++++++++++++++ 5 files changed, 116 insertions(+), 5 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index 0f7f522a3..3b4433596 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -1,15 +1,37 @@ +from __future__ import ( + annotations, +) +from abc import ABC from uuid import ( UUID, ) import httpx as httpx +from datetime import datetime +from datetime import timedelta + +import jwt +from minos.common import ( + SetupMixin, + Config, +) +from pytz import utc -class KongClient: +class KongClient: #(ABC, SetupMixin): """Kong Client class.""" - def __init__(self, route): - self.route = route + def __init__(self, route: str, **kwargs): #def __init__(self, host: str, port: str, token_expiration_minutes: int, **kwargs): + super().__init__(**kwargs) + self.route = route #f"http://{host}:{port}" + #self.token_expiration_minutes = token_expiration_minutes + + # @classmethod + # def _from_config(cls, config: Config, **kwargs) -> KongClient: + # discovery_config = config.get_discovery() + # + # token_expiration = discovery_config.get("token-exp-minutes") + # return cls(token_expiration=token_expiration, **kwargs) @staticmethod async def register_service( @@ -130,8 +152,23 @@ async def activate_basic_auth_plugin_on_route(self, route_id: str): return resp async def activate_jwt_plugin_on_route(self, route_id: str): - payload = {"name": "jwt", "config": {"secret_is_base64": False, "run_on_preflight": True}} + payload = {"name": "jwt", + "config": {"secret_is_base64": False, "run_on_preflight": True, "claims_to_verify": ["exp", "nbf"]}} async with httpx.AsyncClient() as client: resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) return resp + + async def get_jwt_token(self, key: str, secret: str, algorithm: str = 'HS256', exp: datetime = None, nbf: datetime = None) -> str: + payload = {"iss": key, "exp": exp, "nbf": nbf} + + current = datetime.now(tz=utc) + + if not exp: + #payload["exp"] = current + timedelta(minutes=self.token_expiration_minutes) + payload["exp"] = current + timedelta(minutes=120) + + if not nbf: + payload["nbf"] = current + + return jwt.encode(payload, secret, algorithm=algorithm) diff --git a/packages/plugins/minos-discovery-kong/poetry.lock b/packages/plugins/minos-discovery-kong/poetry.lock index 86d2b2810..93f13ec58 100644 --- a/packages/plugins/minos-discovery-kong/poetry.lock +++ b/packages/plugins/minos-discovery-kong/poetry.lock @@ -453,6 +453,20 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" +[[package]] +name = "pyjwt" +version = "2.3.0" +description = "JSON Web Token implementation in Python" +category = "main" +optional = false +python-versions = ">=3.6" + +[package.extras] +crypto = ["cryptography (>=3.3.1)"] +dev = ["sphinx", "sphinx-rtd-theme", "zope.interface", "cryptography (>=3.3.1)", "pytest (>=6.0.0,<7.0.0)", "coverage[toml] (==5.0.4)", "mypy", "pre-commit"] +docs = ["sphinx", "sphinx-rtd-theme", "zope.interface"] +tests = ["pytest (>=6.0.0,<7.0.0)", "coverage[toml] (==5.0.4)"] + [[package]] name = "pyparsing" version = "3.0.8" @@ -485,6 +499,14 @@ toml = "*" [package.extras] testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xmlschema"] +[[package]] +name = "pytz" +version = "2022.1" +description = "World timezone definitions, modern and historical" +category = "main" +optional = false +python-versions = "*" + [[package]] name = "pyyaml" version = "6.0" @@ -563,7 +585,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "7cc1a8e54ecde83eecf19cfa5c6e636ebf1f1e2e9bfb4c3a4d69a0d188d53715" +content-hash = "a4bba089f11aeccbc7cbc7f0cedb301d87d26d1c12075a2a233c5bf9901027b7" [metadata.files] aiomisc = [ @@ -928,6 +950,10 @@ pyflakes = [ {file = "pyflakes-2.4.0-py2.py3-none-any.whl", hash = "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"}, {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] +pyjwt = [ + {file = "PyJWT-2.3.0-py3-none-any.whl", hash = "sha256:e0c4bb8d9f0af0c7f5b1ec4c5036309617d03d56932877f2f7a0beeb5318322f"}, + {file = "PyJWT-2.3.0.tar.gz", hash = "sha256:b888b4d56f06f6dcd777210c334e69c737be74755d3e5e9ee3fe67dc18a0ee41"}, +] pyparsing = [ {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, @@ -936,6 +962,10 @@ pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, {file = "pytest-6.2.5.tar.gz", hash = "sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89"}, ] +pytz = [ + {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, + {file = "pytz-2022.1.tar.gz", hash = "sha256:1e760e2fe6a8163bc0b3d9a19c4f84342afa0a2affebfaa84b01b978a02ecaa7"}, +] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index 7299ee51f..33aeb87f6 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -35,6 +35,8 @@ python = "^3.9" minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } httpx = "^0.22.0" +pytz = "^2022.1" +PyJWT = "^2.3.0" [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../../core/minos-microservice-common", develop = true } diff --git a/packages/plugins/minos-discovery-kong/tests/test_config.yml b/packages/plugins/minos-discovery-kong/tests/test_config.yml index 2a18cf385..64a72f9c0 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_config.yml +++ b/packages/plugins/minos-discovery-kong/tests/test_config.yml @@ -2,5 +2,6 @@ discovery: connector: minos.networks.DiscoveryConnector client: minos.networks.InMemoryDiscoveryClient auth-type: jwt + token-exp-minutes: 60 host: localhost port: 8001 diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 43c5715ed..e716b3b8c 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -13,6 +13,11 @@ from tests.utils import ( TEST_HOST, ) +from datetime import datetime +from datetime import timedelta + +import jwt +from pytz import utc PROTOCOL = "http" @@ -177,6 +182,42 @@ async def test_activate_jwt_plugin_on_route(self): self.assertTrue(201 == response.status_code) + async def test_jwt_token_generation(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) + + self.assertTrue(201 == response.status_code) + resp = response.json() + + response = await self.kong.add_jwt_to_consumer(consumer=resp["id"]) + + self.assertTrue(201 == response.status_code) + resp = response.json() + + token = await self.kong.get_jwt_token(key=resp['key'], secret=resp['secret']) + + self.assertGreater(len(token), 50) + + async def test_jwt_token_generation_with_expiration(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) + + self.assertTrue(201 == response.status_code) + resp = response.json() + + response = await self.kong.add_jwt_to_consumer(consumer=resp["id"]) + + self.assertTrue(201 == response.status_code) + resp = response.json() + + current = datetime.now(tz=utc) + token = await self.kong.get_jwt_token(key=resp['key'], secret=resp['secret'], + exp=current + timedelta(minutes=10), nbf=current + timedelta(minutes=9)) + + self.assertGreater(len(token), 50) + if __name__ == "__main__": unittest.main() From 6527dbb9944705331bedd33f8f245e063b9905d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 19 Apr 2022 11:40:18 +0200 Subject: [PATCH 275/324] ISSUE #43 * Implement circuit breaker for `aiopg` connection failures. --- .../minos/plugins/aiopg/clients.py | 58 ++++++++++++++----- .../tests/test_aiopg/test_clients.py | 37 ++++++++++-- 2 files changed, 76 insertions(+), 19 deletions(-) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py index 825c6b364..05d2b1c76 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py @@ -3,8 +3,12 @@ ) import logging +from asyncio import ( + TimeoutError, +) from collections.abc import ( AsyncIterator, + Iterable, ) from typing import ( Optional, @@ -22,6 +26,7 @@ ) from minos.common import ( + CircuitBreakerMixin, ConnectionException, DatabaseClient, IntegrityException, @@ -35,7 +40,7 @@ logger = logging.getLogger(__name__) -class AiopgDatabaseClient(DatabaseClient): +class AiopgDatabaseClient(DatabaseClient, CircuitBreakerMixin): """Aiopg Database Client class.""" _connection: Optional[Connection] @@ -48,10 +53,17 @@ def __init__( port: Optional[int] = None, user: Optional[str] = None, password: Optional[str] = None, + circuit_breaker_exceptions: Iterable[type] = tuple(), + connection_timeout: Optional[float] = None, + cursor_timeout: Optional[float] = None, *args, **kwargs, ): - super().__init__(*args, **kwargs) + super().__init__( + *args, + **kwargs, + circuit_breaker_exceptions=(OperationalError, TimeoutError, *circuit_breaker_exceptions), + ) if host is None: host = "localhost" @@ -61,6 +73,10 @@ def __init__( user = "postgres" if password is None: password = "" + if connection_timeout is None: + connection_timeout = 1 + if cursor_timeout is None: + cursor_timeout = 60 self._database = database self._host = host @@ -68,6 +84,9 @@ def __init__( self._user = user self._password = password + self._connection_timeout = connection_timeout + self._cursor_timeout = cursor_timeout + self._connection = None self._cursor = None @@ -80,19 +99,22 @@ async def _destroy(self) -> None: await self._close_connection() async def _create_connection(self): - try: - self._connection = await aiopg.connect( - host=self.host, port=self.port, dbname=self.database, user=self.user, password=self.password - ) - except OperationalError as exc: - msg = f"There was an {exc!r} while trying to get a database connection." - logger.warning(msg) - raise ConnectionException(msg) + self._connection = await self.with_circuit_breaker(self._connect) logger.debug(f"Created {self.database!r} database connection identified by {id(self._connection)}!") + async def _connect(self) -> Connection: + return await aiopg.connect( + timeout=self._connection_timeout, + host=self.host, + port=self.port, + dbname=self.database, + user=self.user, + password=self.password, + ) + async def _close_connection(self): - if self._connection is not None and not self._connection.closed: + if await self.is_valid(): await self._connection.close() self._connection = None logger.debug(f"Destroyed {self.database!r} database connection identified by {id(self._connection)}!") @@ -114,12 +136,18 @@ async def _reset(self, **kwargs) -> None: # noinspection PyUnusedLocal async def _fetch_all(self) -> AsyncIterator[tuple]: - await self._create_cursor() + if self._cursor is None: + raise ProgrammingException("An operation must be executed before fetching any value.") + try: async for row in self._cursor: yield row except ProgrammingError as exc: raise ProgrammingException(str(exc)) + except OperationalError as exc: + msg = f"There was an {exc!r} while trying to connect to the database." + logger.warning(msg) + raise ConnectionException(msg) # noinspection PyUnusedLocal async def _execute(self, operation: AiopgDatabaseOperation) -> None: @@ -131,10 +159,14 @@ async def _execute(self, operation: AiopgDatabaseOperation) -> None: await self._cursor.execute(operation=operation.query, parameters=operation.parameters) except IntegrityError as exc: raise IntegrityException(f"The requested operation raised a integrity error: {exc!r}") + except OperationalError as exc: + msg = f"There was an {exc!r} while trying to connect to the database." + logger.warning(msg) + raise ConnectionException(msg) async def _create_cursor(self): if self._cursor is None: - self._cursor = await self._connection.cursor() + self._cursor = await self._connection.cursor(timeout=self._cursor_timeout) async def _destroy_cursor(self, **kwargs): if self._cursor is not None: diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py index efddd6269..e980edbf2 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py @@ -13,6 +13,7 @@ from psycopg2 import ( IntegrityError, OperationalError, + ProgrammingError, ) from minos.common import ( @@ -30,7 +31,7 @@ ) -# noinspection SqlNoDataSourceInspection +# noinspection SqlNoDataSourceInspection,SqlDialectInspection class TestAiopgDatabaseClient(AiopgTestCase): def setUp(self): super().setUp() @@ -79,10 +80,14 @@ async def test_connection(self): self.assertIsNone(client.connection) async def test_connection_raises(self): - with patch.object(aiopg, "connect", new_callable=PropertyMock, side_effect=OperationalError): - with self.assertRaises(ConnectionException): - async with AiopgDatabaseClient.from_config(self.config): - pass + async with AiopgDatabaseClient.from_config(self.config) as c1: + + async def _fn(): + return c1.connection + + with patch.object(aiopg, "connect", new_callable=PropertyMock, side_effect=(OperationalError, _fn())): + async with AiopgDatabaseClient.from_config(self.config) as c2: + self.assertEqual(c1.connection, c2.connection) async def test_cursor(self): client = AiopgDatabaseClient.from_config(self.config) @@ -125,17 +130,37 @@ async def test_execute_raises_integrity(self): with self.assertRaises(IntegrityException): await client.execute(self.operation) + async def test_execute_raises_operational(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + with patch.object(Cursor, "execute", side_effect=OperationalError): + with self.assertRaises(ConnectionException): + await client.execute(self.operation) + async def test_fetch_one(self): async with AiopgDatabaseClient.from_config(self.config) as client: await client.execute(self.operation) observed = await client.fetch_one() self.assertIsInstance(observed, tuple) - async def test_fetch_one_raises(self): + async def test_fetch_one_raises_programming_empty(self): async with AiopgDatabaseClient.from_config(self.config) as client: with self.assertRaises(ProgrammingException): await client.fetch_one() + async def test_fetch_one_raises_programming(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + await client.execute(self.operation) + with patch.object(Cursor, "fetchone", side_effect=ProgrammingError): + with self.assertRaises(ProgrammingException): + await client.fetch_one() + + async def test_fetch_one_raises_operational(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + await client.execute(self.operation) + with patch.object(Cursor, "fetchone", side_effect=OperationalError): + with self.assertRaises(ConnectionException): + await client.fetch_one() + async def test_fetch_all(self): async with AiopgDatabaseClient.from_config(self.config) as client: await client.execute(self.operation) From f8f590a3cd276702b7832dce25350a90fb972099 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Tue, 19 Apr 2022 12:29:13 +0200 Subject: [PATCH 276/324] ISSUE #390 --- .../minos/plugins/kong/client.py | 60 ++++++++++++------- .../minos/plugins/kong/discovery.py | 26 ++++---- .../tests/test_kong/test_client.py | 49 ++++++++++++--- 3 files changed, 95 insertions(+), 40 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index 3b4433596..20a03f9fc 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -1,37 +1,52 @@ from __future__ import ( annotations, ) -from abc import ABC + +from abc import ( + ABC, +) +from datetime import ( + datetime, + timedelta, +) from uuid import ( UUID, ) import httpx as httpx -from datetime import datetime -from datetime import timedelta - import jwt +from pytz import ( + utc, +) + from minos.common import ( - SetupMixin, Config, + SetupMixin, ) -from pytz import utc -class KongClient: #(ABC, SetupMixin): +class KongClient(ABC, SetupMixin): """Kong Client class.""" - def __init__(self, route: str, **kwargs): #def __init__(self, host: str, port: str, token_expiration_minutes: int, **kwargs): + def __init__(self, host: str = None, port: str = None, token_expiration_sec: int = 60 * 5, **kwargs): super().__init__(**kwargs) - self.route = route #f"http://{host}:{port}" - #self.token_expiration_minutes = token_expiration_minutes + if host is None: + host = "localhost" + if port is None: + port = 8001 + + self.route = f"http://{host}:{port}" + self.token_expiration_sec = token_expiration_sec + + @classmethod + def _from_config(cls, config: Config, **kwargs) -> KongClient: + discovery_config = config.get_discovery() - # @classmethod - # def _from_config(cls, config: Config, **kwargs) -> KongClient: - # discovery_config = config.get_discovery() - # - # token_expiration = discovery_config.get("token-exp-minutes") - # return cls(token_expiration=token_expiration, **kwargs) + token_expiration_sec = discovery_config.get("token-exp-minutes") + host = discovery_config.get("host") + port = discovery_config.get("port") + + return cls(host=host, port=port, token_expiration_sec=token_expiration_sec, **kwargs) @staticmethod async def register_service( @@ -152,21 +167,24 @@ async def activate_basic_auth_plugin_on_route(self, route_id: str): return resp async def activate_jwt_plugin_on_route(self, route_id: str): - payload = {"name": "jwt", - "config": {"secret_is_base64": False, "run_on_preflight": True, "claims_to_verify": ["exp", "nbf"]}} + payload = { + "name": "jwt", + "config": {"secret_is_base64": False, "run_on_preflight": True, "claims_to_verify": ["exp", "nbf"]}, + } async with httpx.AsyncClient() as client: resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) return resp - async def get_jwt_token(self, key: str, secret: str, algorithm: str = 'HS256', exp: datetime = None, nbf: datetime = None) -> str: + async def get_jwt_token( + self, key: str, secret: str, algorithm: str = "HS256", exp: datetime = None, nbf: datetime = None + ) -> str: payload = {"iss": key, "exp": exp, "nbf": nbf} current = datetime.now(tz=utc) if not exp: - #payload["exp"] = current + timedelta(minutes=self.token_expiration_minutes) - payload["exp"] = current + timedelta(minutes=120) + payload["exp"] = current + timedelta(seconds=self.token_expiration_sec) if not nbf: payload["nbf"] = current diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py index 330b2c5b0..0687df4fd 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py @@ -41,6 +41,7 @@ def __init__( host: Optional[str] = None, port: Optional[int] = None, circuit_breaker_exceptions: Iterable[type] = tuple(), + client: KongClient = None, **kwargs, ): if host is None: @@ -50,7 +51,11 @@ def __init__( super().__init__( host, port, circuit_breaker_exceptions=(httpx.HTTPStatusError, *circuit_breaker_exceptions), **kwargs ) - self.kong = KongClient(self.route) + + if client is None: + client = KongClient() + + self.client = client self.auth_type = None if "auth_type" in kwargs: @@ -66,8 +71,9 @@ def _from_config(cls, config: Config, **kwargs) -> KongDiscoveryClient: auth_type = config.get_by_key("discovery.auth-type") except Exception: auth_type = None + client = KongClient.from_config(config) - return super()._from_config(config, auth_type=auth_type, **kwargs) + return super()._from_config(config, auth_type=auth_type, client=client, **kwargs) async def subscribe( self, host: str, port: int, name: str, endpoints: list[dict[str, str]], *args, **kwargs @@ -83,13 +89,13 @@ async def subscribe( :return: This method does not return anything. """ - fnsr = partial(self.kong.register_service, self.route, name, host, port) + fnsr = partial(self.client.register_service, self.route, name, host, port) response_service = await self.with_circuit_breaker(fnsr) # register a service if response_service.status_code == 409: # service already exist # if service already exist, delete and add again - fn_delete = partial(self.kong.delete_service, self.route, name) + fn_delete = partial(self.client.delete_service, self.route, name) await self.with_circuit_breaker(fn_delete) # delete the service - fnsr = partial(self.kong.register_service, self.route, name, host, port) + fnsr = partial(self.client.register_service, self.route, name, host, port) response_service = await self.with_circuit_breaker(fnsr) # send the servie subscription again content_service = response_service.json() # get the servie information like the id @@ -98,7 +104,7 @@ async def subscribe( endpointClass = Endpoint(endpoint["url"]) fn = partial( - self.kong.create_route, + self.client.create_route, self.route, ["http"], [endpoint["method"]], @@ -111,15 +117,15 @@ async def subscribe( if "authenticated" in endpoint and self.auth_type: if self.auth_type == "basic-auth": - fn = partial(self.kong.activate_basic_auth_plugin_on_route, route_id=resp["id"]) + fn = partial(self.client.activate_basic_auth_plugin_on_route, route_id=resp["id"]) await self.with_circuit_breaker(fn) elif self.auth_type == "jwt": - fn = partial(self.kong.activate_jwt_plugin_on_route, route_id=resp["id"]) + fn = partial(self.client.activate_jwt_plugin_on_route, route_id=resp["id"]) await self.with_circuit_breaker(fn) if "authorized_groups" in endpoint: fn = partial( - self.kong.activate_acl_plugin_on_route, route_id=resp["id"], allow=endpoint["authorized_groups"] + self.client.activate_acl_plugin_on_route, route_id=resp["id"], allow=endpoint["authorized_groups"] ) await self.with_circuit_breaker(fn) @@ -133,6 +139,6 @@ async def unsubscribe(self, name: str, *args, **kwargs) -> httpx.Response: :param kwargs: Additional named arguments. :return: This method does not return anything. """ - fn = partial(self.kong.delete_service, self.route, name) + fn = partial(self.client.delete_service, self.route, name) response = await self.with_circuit_breaker(fn) return response diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index e716b3b8c..567161156 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -1,23 +1,29 @@ import os import unittest +from datetime import ( + datetime, + timedelta, +) from uuid import ( uuid4, ) import httpx +from pytz import ( + utc, +) +from minos.common import ( + Config, +) from minos.plugins.kong import ( KongClient, KongDiscoveryClient, ) from tests.utils import ( + CONFIG_FILE_PATH, TEST_HOST, ) -from datetime import datetime -from datetime import timedelta - -import jwt -from pytz import utc PROTOCOL = "http" @@ -28,7 +34,7 @@ class TestKongDiscoveryClient(unittest.IsolatedAsyncioTestCase): def setUp(self) -> None: self.client = KongDiscoveryClient(self.KONG_HOST, self.KONG_PORT, circuit_breaker_time=0.1) - self.kong = KongClient(self.client.route) + self.kong = KongClient() @staticmethod def generate_underscore_uuid(): @@ -195,7 +201,7 @@ async def test_jwt_token_generation(self): self.assertTrue(201 == response.status_code) resp = response.json() - token = await self.kong.get_jwt_token(key=resp['key'], secret=resp['secret']) + token = await self.kong.get_jwt_token(key=resp["key"], secret=resp["secret"]) self.assertGreater(len(token), 50) @@ -213,11 +219,36 @@ async def test_jwt_token_generation_with_expiration(self): resp = response.json() current = datetime.now(tz=utc) - token = await self.kong.get_jwt_token(key=resp['key'], secret=resp['secret'], - exp=current + timedelta(minutes=10), nbf=current + timedelta(minutes=9)) + token = await self.kong.get_jwt_token( + key=resp["key"], + secret=resp["secret"], + exp=current + timedelta(minutes=10), + nbf=current + timedelta(minutes=9), + ) self.assertGreater(len(token), 50) +class TestKongClientFromConfig(unittest.IsolatedAsyncioTestCase): + KONG_HOST = os.getenv("KONG_HOST", "localhost") + KONG_PORT = os.getenv("KONG_PORT", 8001) + + def setUp(self) -> None: + config = Config(CONFIG_FILE_PATH) + self.kong = KongClient.from_config(config=config) + + @staticmethod + def generate_underscore_uuid(): + name = str(uuid4()) + return name.replace("-", "_") + + async def test_create_consumer(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) + + self.assertTrue(201 == response.status_code) + + if __name__ == "__main__": unittest.main() From f6ac210320756077c2fe53e680286399c54e4d79 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Tue, 19 Apr 2022 12:50:38 +0200 Subject: [PATCH 277/324] ISSUE #390 --- .../minos-discovery-kong/minos/plugins/kong/client.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index 20a03f9fc..f94aeb212 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -28,14 +28,15 @@ class KongClient(ABC, SetupMixin): """Kong Client class.""" - def __init__(self, host: str = None, port: str = None, token_expiration_sec: int = 60 * 5, **kwargs): + def __init__(self, protocol: str = "http", host: str = None, port: str = None, token_expiration_sec: int = 60 * 5, + **kwargs): super().__init__(**kwargs) if host is None: host = "localhost" if port is None: port = 8001 - self.route = f"http://{host}:{port}" + self.route = f"{protocol}://{host}:{port}" self.token_expiration_sec = token_expiration_sec @classmethod From a27d30b634acdc2ef81f6c21485a17428e8427ee Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Tue, 19 Apr 2022 13:20:56 +0200 Subject: [PATCH 278/324] ISSUE #390 --- .../plugins/minos-discovery-kong/minos/plugins/kong/client.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index f94aeb212..d92341eea 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -28,13 +28,15 @@ class KongClient(ABC, SetupMixin): """Kong Client class.""" - def __init__(self, protocol: str = "http", host: str = None, port: str = None, token_expiration_sec: int = 60 * 5, + def __init__(self, protocol: str = "http", host: str = None, port: str = None, token_expiration_sec: int = None, **kwargs): super().__init__(**kwargs) if host is None: host = "localhost" if port is None: port = 8001 + if token_expiration_sec is None: + token_expiration_sec = 60 * 5 self.route = f"{protocol}://{host}:{port}" self.token_expiration_sec = token_expiration_sec From 0c6f6d2db8aaa9102167d0979bf30b8a748a89d8 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Tue, 19 Apr 2022 11:21:08 +0000 Subject: [PATCH 279/324] Restyled by black --- .../minos-discovery-kong/minos/plugins/kong/client.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index d92341eea..bb12f42ca 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -28,8 +28,9 @@ class KongClient(ABC, SetupMixin): """Kong Client class.""" - def __init__(self, protocol: str = "http", host: str = None, port: str = None, token_expiration_sec: int = None, - **kwargs): + def __init__( + self, protocol: str = "http", host: str = None, port: str = None, token_expiration_sec: int = None, **kwargs + ): super().__init__(**kwargs) if host is None: host = "localhost" From b90ddfe6bc63d12aaa91e72c42b363593816b235 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 19 Apr 2022 13:32:08 +0200 Subject: [PATCH 280/324] ISSUE #43 * Improve `AiopgDatabaseClient` adding support for connection recreation during breakages. --- .../minos/common/database/clients/abc.py | 3 +- .../minos/common/pools.py | 6 +-- .../minos/common/testing/database/clients.py | 4 -- .../test_database/test_clients/test_abc.py | 5 +- .../minos/networks/brokers/pools.py | 6 +-- .../minos/plugins/aiopg/clients.py | 53 ++++++++++++------- .../tests/test_aiopg/test_clients.py | 53 +++++++++++++++---- .../minos/plugins/lmdb/clients.py | 3 -- 8 files changed, 84 insertions(+), 49 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index dc1f9e010..b878b301a 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -66,9 +66,8 @@ async def is_valid(self, **kwargs) -> bool: """ return await self._is_valid(**kwargs) - @abstractmethod async def _is_valid(self, **kwargs) -> bool: - raise NotImplementedError + return True async def _destroy(self) -> None: await self.reset() diff --git a/packages/core/minos-microservice-common/minos/common/pools.py b/packages/core/minos-microservice-common/minos/common/pools.py index c16c57176..3432db575 100644 --- a/packages/core/minos-microservice-common/minos/common/pools.py +++ b/packages/core/minos-microservice-common/minos/common/pools.py @@ -112,15 +112,15 @@ def _get_pool_cls(self, type_: str) -> type[Pool]: class _PoolBase(PoolBase, ABC): - def __init__(self, *args, maxsize: int = 10, recycle: Optional[int] = 300, **kwargs): + def __init__(self, *args, maxsize: int = 10, recycle: Optional[int] = None, **kwargs): super().__init__(maxsize=maxsize, recycle=recycle) class Pool(SetupMixin, _PoolBase, Generic[P], ABC): """Base class for Pool implementations in minos""" - def __init__(self, *args, maxsize: int = 10, recycle: Optional[int] = 300, already_setup: bool = True, **kwargs): - super().__init__(*args, maxsize=maxsize, recycle=recycle, already_setup=already_setup, **kwargs) + def __init__(self, *args, already_setup: bool = True, **kwargs): + super().__init__(*args, already_setup=already_setup, **kwargs) # noinspection PyUnresolvedReferences async def __acquire(self) -> Any: # pragma: no cover diff --git a/packages/core/minos-microservice-common/minos/common/testing/database/clients.py b/packages/core/minos-microservice-common/minos/common/testing/database/clients.py index cc6ec8aae..90b1b4d3a 100644 --- a/packages/core/minos-microservice-common/minos/common/testing/database/clients.py +++ b/packages/core/minos-microservice-common/minos/common/testing/database/clients.py @@ -21,10 +21,6 @@ def __init__(self, *args, **kwargs): self.kwargs = kwargs self._response = tuple() - async def _is_valid(self, **kwargs) -> bool: - """For testing purposes""" - return True - async def _reset(self, **kwargs) -> None: """For testing purposes""" self._response = tuple() diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index e7ee8f393..fbedcca2c 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -33,9 +33,6 @@ class _DatabaseClient(DatabaseClient): """For testing purposes.""" - async def _is_valid(self, **kwargs) -> bool: - """For testing purposes.""" - async def _reset(self, **kwargs) -> None: """For testing purposes.""" @@ -76,7 +73,7 @@ def build_release(self, hashed_key: int) -> DatabaseOperation: class TestDatabaseClient(CommonTestCase): def test_abstract(self): self.assertTrue(issubclass(DatabaseClient, (ABC, BuildableMixin))) - expected = {"_is_valid", "_execute", "_fetch_all", "_reset"} + expected = {"_execute", "_fetch_all", "_reset"} # noinspection PyUnresolvedReferences self.assertEqual(expected, DatabaseClient.__abstractmethods__) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py b/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py index ecb298245..fecf1929c 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/pools.py @@ -30,10 +30,8 @@ class BrokerClientPool(Pool): """Broker Client Pool class.""" - def __init__( - self, instance_kwargs: dict[str, Any], maxsize: int = 5, recycle: Optional[int] = 3600, *args, **kwargs - ): - super().__init__(maxsize=maxsize, recycle=recycle, *args, **kwargs) + def __init__(self, instance_kwargs: dict[str, Any], maxsize: int = 5, *args, **kwargs): + super().__init__(maxsize=maxsize, *args, **kwargs) self._instance_kwargs = instance_kwargs @classmethod diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py index 05d2b1c76..32ef122e6 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py @@ -10,6 +10,9 @@ AsyncIterator, Iterable, ) +from functools import ( + partial, +) from typing import ( Optional, ) @@ -92,15 +95,20 @@ def __init__( async def _setup(self) -> None: await super()._setup() - await self._create_connection() + await self.recreate() async def _destroy(self) -> None: await super()._destroy() - await self._close_connection() + await self.close() - async def _create_connection(self): - self._connection = await self.with_circuit_breaker(self._connect) + async def recreate(self) -> None: + """Recreate the database connection. + :return: This method does not return anything. + """ + await self.close() + + self._connection = await self.with_circuit_breaker(self._connect) logger.debug(f"Created {self.database!r} database connection identified by {id(self._connection)}!") async def _connect(self) -> Connection: @@ -113,13 +121,23 @@ async def _connect(self) -> Connection: password=self.password, ) - async def _close_connection(self): - if await self.is_valid(): + async def close(self) -> None: + """Close database connection. + + :return: This method does not return anything. + """ + if await self.is_connected(): await self._connection.close() - self._connection = None - logger.debug(f"Destroyed {self.database!r} database connection identified by {id(self._connection)}!") - async def _is_valid(self) -> bool: + if self._connection is not None: + logger.debug(f"Destroyed {self.database!r} database connection identified by {id(self._connection)}!") + self._connection = None + + async def is_connected(self) -> bool: + """Check if the client is connected. + + :return: ``True`` if it is connected or ``False`` otherwise. + """ if self._connection is None: return False @@ -154,19 +172,18 @@ async def _execute(self, operation: AiopgDatabaseOperation) -> None: if not isinstance(operation, AiopgDatabaseOperation): raise ValueError(f"The operation must be a {AiopgDatabaseOperation!r} instance. Obtained: {operation!r}") - await self._create_cursor() + fn = partial(self._execute_cursor, operation=operation.query, parameters=operation.parameters) try: - await self._cursor.execute(operation=operation.query, parameters=operation.parameters) + await self.with_circuit_breaker(fn) except IntegrityError as exc: raise IntegrityException(f"The requested operation raised a integrity error: {exc!r}") - except OperationalError as exc: - msg = f"There was an {exc!r} while trying to connect to the database." - logger.warning(msg) - raise ConnectionException(msg) - async def _create_cursor(self): - if self._cursor is None: - self._cursor = await self._connection.cursor(timeout=self._cursor_timeout) + async def _execute_cursor(self, operation: str, parameters: dict): + if not await self.is_connected(): + await self.recreate() + + self._cursor = await self._connection.cursor(timeout=self._cursor_timeout) + await self._cursor.execute(operation=operation, parameters=parameters) async def _destroy_cursor(self, **kwargs): if self._cursor is not None: diff --git a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py index e980edbf2..8c1d935cc 100644 --- a/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py +++ b/packages/plugins/minos-database-aiopg/tests/test_aiopg/test_clients.py @@ -54,23 +54,27 @@ def test_from_config(self): self.assertEqual(default_database["host"], client.host) self.assertEqual(default_database["port"], client.port) - async def test_is_valid_true(self): + async def test_is_valid(self): async with AiopgDatabaseClient.from_config(self.config) as client: self.assertTrue(await client.is_valid()) - async def test_is_valid_false_not_setup(self): + async def test_is_connected_true(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + self.assertTrue(await client.is_connected()) + + async def test_is_connected_false_not_setup(self): client = AiopgDatabaseClient.from_config(self.config) - self.assertFalse(await client.is_valid()) + self.assertFalse(await client.is_connected()) - async def test_is_valid_false_operational_error(self): + async def test_is_connected_false_operational_error(self): async with AiopgDatabaseClient.from_config(self.config) as client: with patch.object(Connection, "isolation_level", new_callable=PropertyMock, side_effect=OperationalError): - self.assertFalse(await client.is_valid()) + self.assertFalse(await client.is_connected()) - async def test_is_valid_false_closed(self): + async def test_is_connected_false_closed(self): async with AiopgDatabaseClient.from_config(self.config) as client: with patch.object(Connection, "closed", new_callable=PropertyMock, return_valud=False): - self.assertFalse(await client.is_valid()) + self.assertFalse(await client.is_connected()) async def test_connection(self): client = AiopgDatabaseClient.from_config(self.config) @@ -79,7 +83,7 @@ async def test_connection(self): self.assertIsInstance(client.connection, Connection) self.assertIsNone(client.connection) - async def test_connection_raises(self): + async def test_connection_with_circuit_breaker(self): async with AiopgDatabaseClient.from_config(self.config) as c1: async def _fn(): @@ -89,6 +93,18 @@ async def _fn(): async with AiopgDatabaseClient.from_config(self.config) as c2: self.assertEqual(c1.connection, c2.connection) + async def test_connection_recreate(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + c1 = client.connection + self.assertIsInstance(c1, Connection) + + await client.recreate() + + c2 = client.connection + self.assertIsInstance(c2, Connection) + + self.assertNotEqual(c1, c2) + async def test_cursor(self): client = AiopgDatabaseClient.from_config(self.config) self.assertIsNone(client.cursor) @@ -116,6 +132,14 @@ async def test_execute(self): execute_mock.call_args_list, ) + async def test_execute_disconnected(self): + async with AiopgDatabaseClient.from_config(self.config) as client: + await client.close() + self.assertFalse(await client.is_connected()) + + await client.execute(self.operation) + self.assertTrue(await client.is_connected()) + async def test_execute_raises_unsupported(self): class _DatabaseOperation(DatabaseOperation): """For testing purposes.""" @@ -132,9 +156,16 @@ async def test_execute_raises_integrity(self): async def test_execute_raises_operational(self): async with AiopgDatabaseClient.from_config(self.config) as client: - with patch.object(Cursor, "execute", side_effect=OperationalError): - with self.assertRaises(ConnectionException): - await client.execute(self.operation) + with patch.object(Cursor, "execute", side_effect=(OperationalError, None)) as mock: + await client.execute(self.operation) + + self.assertEqual( + [ + call(operation=self.operation.query, parameters=self.operation.parameters), + call(operation=self.operation.query, parameters=self.operation.parameters), + ], + mock.call_args_list, + ) async def test_fetch_one(self): async with AiopgDatabaseClient.from_config(self.config) as client: diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py index 317728701..851457a34 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py @@ -73,9 +73,6 @@ def _close_environment(self) -> None: if self._environment is not None: self._environment.close() - async def _is_valid(self, **kwargs) -> bool: - return True - async def _reset(self, **kwargs) -> None: self._prefetched = None self._environment.sync() From 4c8ab9068a8eff3d18550eb6f3fb13d338530014 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Tue, 19 Apr 2022 15:25:42 +0200 Subject: [PATCH 281/324] ISSUE #398 --- .../minos/plugins/kong/client.py | 18 +++++- .../minos/plugins/kong/discovery.py | 5 ++ .../tests/test_kong/test_client.py | 56 ++++++++++++++++++- .../tests/test_kong/test_discovery.py | 6 +- 4 files changed, 79 insertions(+), 6 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index bb12f42ca..77728cc57 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -90,6 +90,7 @@ async def create_route( methods: list[str], paths: list[str], service: str, + regex_priority: int, strip_path: bool = False, ): url = f"{endpoint}/routes" @@ -98,6 +99,7 @@ async def create_route( "methods": methods, "paths": paths, "service": {"id": service}, + "regex_priority": regex_priority, "strip_path": strip_path, } @@ -180,7 +182,7 @@ async def activate_jwt_plugin_on_route(self, route_id: str): resp = await client.post(f"{self.route}/routes/{route_id}/plugins", json=payload) return resp - async def get_jwt_token( + async def generate_jwt_token( self, key: str, secret: str, algorithm: str = "HS256", exp: datetime = None, nbf: datetime = None ) -> str: payload = {"iss": key, "exp": exp, "nbf": nbf} @@ -194,3 +196,17 @@ async def get_jwt_token( payload["nbf"] = current return jwt.encode(payload, secret, algorithm=algorithm) + + @staticmethod + async def decode_token(token: str, algorithm: str = "HS256"): + return jwt.decode(token, options={"verify_signature": False}, algorithms=[algorithm]) + + async def get_jwt_by_id(self, id: str): + async with httpx.AsyncClient() as client: + resp = await client.get(f"{self.route}/jwts/{id}") + return resp + + async def get_consumer_jwts(self, consumer: str): + async with httpx.AsyncClient() as client: + resp = await client.get(f"{self.route}/consumers/{consumer}/jwt") + return resp diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py index 0687df4fd..fd269ff3e 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py @@ -103,6 +103,10 @@ async def subscribe( for endpoint in endpoints: endpointClass = Endpoint(endpoint["url"]) + regex_priority = 0 + if "regex_priority" in endpoint: + regex_priority = endpoint["regex_priority"] + fn = partial( self.client.create_route, self.route, @@ -110,6 +114,7 @@ async def subscribe( [endpoint["method"]], [endpointClass.path_as_str], content_service["id"], + regex_priority, False, ) response = await self.with_circuit_breaker(fn) # send the route request diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 567161156..0541216e0 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -151,6 +151,7 @@ async def test_activate_basic_auth_plugin_on_route(self): methods=["GET"], paths=["/foo"], service=res["id"], + regex_priority=2, strip_path=False, ) @@ -178,6 +179,7 @@ async def test_activate_jwt_plugin_on_route(self): methods=["GET"], paths=["/foo"], service=res["id"], + regex_priority=0, strip_path=False, ) @@ -201,7 +203,7 @@ async def test_jwt_token_generation(self): self.assertTrue(201 == response.status_code) resp = response.json() - token = await self.kong.get_jwt_token(key=resp["key"], secret=resp["secret"]) + token = await self.kong.generate_jwt_token(key=resp["key"], secret=resp["secret"]) self.assertGreater(len(token), 50) @@ -219,7 +221,7 @@ async def test_jwt_token_generation_with_expiration(self): resp = response.json() current = datetime.now(tz=utc) - token = await self.kong.get_jwt_token( + token = await self.kong.generate_jwt_token( key=resp["key"], secret=resp["secret"], exp=current + timedelta(minutes=10), @@ -228,6 +230,56 @@ async def test_jwt_token_generation_with_expiration(self): self.assertGreater(len(token), 50) + async def test_token_decode(self): + res = await self.kong.decode_token( + "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJ5ZTBRdURsNG03UW1qbnpFR0pJaUVyQnZieFBqSXM3VyIsImV4cCI6MTY1" + "MDM2NzE0NywibmJmIjoxNjUwMzY3MDI3fQ.SDH5Zq1mUSU0GkCyC_kF81_uoiF45u62Hgwnuv4wl5U") + self.assertIn('iss', res) + self.assertIn('exp', res) + self.assertIn('nbf', res) + + async def test_get_token_by_id(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) + + self.assertTrue(201 == response.status_code) + resp = response.json() + + response = await self.kong.add_jwt_to_consumer(consumer=resp["id"]) + + self.assertTrue(201 == response.status_code) + resp = response.json() + + token = await self.kong.generate_jwt_token(key=resp["key"], secret=resp["secret"]) + + self.assertGreater(len(token), 50) + + response = await self.kong.get_jwt_by_id(resp['id']) + self.assertTrue(200 == response.status_code) + resp = response.json() + + self.assertIn('key', resp) + self.assertIn('secret', resp) + + async def test_get_consumer_jwts(self): + user_uuid = uuid4() + user_name = self.generate_underscore_uuid() + response = await self.kong.create_consumer(username=user_name, user=user_uuid, tags=[]) + + self.assertTrue(201 == response.status_code) + resp = response.json() + consumer_id = resp["id"] + response = await self.kong.add_jwt_to_consumer(consumer=resp["id"]) + + self.assertTrue(201 == response.status_code) + + response = await self.kong.get_consumer_jwts(consumer_id) + self.assertTrue(200 == response.status_code) + resp = response.json() + + self.assertEqual(len(resp['data']), 1) + class TestKongClientFromConfig(unittest.IsolatedAsyncioTestCase): KONG_HOST = os.getenv("KONG_HOST", "localhost") diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py index 000e093ab..de05a0869 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py @@ -87,9 +87,9 @@ async def test_subscribe_with_auth(self): 5660, name, [ - {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, - {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"]}, + {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"], "regex_priority": 0}, + {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"], "regex_priority": 0}, + {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"], "regex_priority": 0}, ], ) self.assertTrue(201 == response.status_code) From 75978b3cad20a8e2b6c1560146f02131f92284fc Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Tue, 19 Apr 2022 13:25:53 +0000 Subject: [PATCH 282/324] Restyled by black --- .../tests/test_kong/test_client.py | 17 ++++++------- .../tests/test_kong/test_discovery.py | 24 ++++++++++++++++--- 2 files changed, 30 insertions(+), 11 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py index 0541216e0..551f6257e 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_client.py @@ -233,10 +233,11 @@ async def test_jwt_token_generation_with_expiration(self): async def test_token_decode(self): res = await self.kong.decode_token( "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJ5ZTBRdURsNG03UW1qbnpFR0pJaUVyQnZieFBqSXM3VyIsImV4cCI6MTY1" - "MDM2NzE0NywibmJmIjoxNjUwMzY3MDI3fQ.SDH5Zq1mUSU0GkCyC_kF81_uoiF45u62Hgwnuv4wl5U") - self.assertIn('iss', res) - self.assertIn('exp', res) - self.assertIn('nbf', res) + "MDM2NzE0NywibmJmIjoxNjUwMzY3MDI3fQ.SDH5Zq1mUSU0GkCyC_kF81_uoiF45u62Hgwnuv4wl5U" + ) + self.assertIn("iss", res) + self.assertIn("exp", res) + self.assertIn("nbf", res) async def test_get_token_by_id(self): user_uuid = uuid4() @@ -255,12 +256,12 @@ async def test_get_token_by_id(self): self.assertGreater(len(token), 50) - response = await self.kong.get_jwt_by_id(resp['id']) + response = await self.kong.get_jwt_by_id(resp["id"]) self.assertTrue(200 == response.status_code) resp = response.json() - self.assertIn('key', resp) - self.assertIn('secret', resp) + self.assertIn("key", resp) + self.assertIn("secret", resp) async def test_get_consumer_jwts(self): user_uuid = uuid4() @@ -278,7 +279,7 @@ async def test_get_consumer_jwts(self): self.assertTrue(200 == response.status_code) resp = response.json() - self.assertEqual(len(resp['data']), 1) + self.assertEqual(len(resp["data"]), 1) class TestKongClientFromConfig(unittest.IsolatedAsyncioTestCase): diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py index de05a0869..71d4c0381 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_discovery.py @@ -87,9 +87,27 @@ async def test_subscribe_with_auth(self): 5660, name, [ - {"url": "/", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"], "regex_priority": 0}, - {"url": "/foo", "method": "POST", "authenticated": True, "authorized_groups": ["super_admin", "admin"], "regex_priority": 0}, - {"url": "/bar", "method": "GET", "authenticated": True, "authorized_groups": ["super_admin", "admin"], "regex_priority": 0}, + { + "url": "/", + "method": "GET", + "authenticated": True, + "authorized_groups": ["super_admin", "admin"], + "regex_priority": 0, + }, + { + "url": "/foo", + "method": "POST", + "authenticated": True, + "authorized_groups": ["super_admin", "admin"], + "regex_priority": 0, + }, + { + "url": "/bar", + "method": "GET", + "authenticated": True, + "authorized_groups": ["super_admin", "admin"], + "regex_priority": 0, + }, ], ) self.assertTrue(201 == response.status_code) From a5d79af356dafb7b81e483ce1a7d5b4d79543a35 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 20 Apr 2022 09:09:48 +0200 Subject: [PATCH 283/324] ISSUE #43 * Improve exception handling. --- .../minos/plugins/aiopg/clients.py | 37 ++++++++++--------- 1 file changed, 20 insertions(+), 17 deletions(-) diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py index 32ef122e6..f49610012 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/clients.py @@ -65,7 +65,7 @@ def __init__( super().__init__( *args, **kwargs, - circuit_breaker_exceptions=(OperationalError, TimeoutError, *circuit_breaker_exceptions), + circuit_breaker_exceptions=(ConnectionException, *circuit_breaker_exceptions), ) if host is None: @@ -112,14 +112,17 @@ async def recreate(self) -> None: logger.debug(f"Created {self.database!r} database connection identified by {id(self._connection)}!") async def _connect(self) -> Connection: - return await aiopg.connect( - timeout=self._connection_timeout, - host=self.host, - port=self.port, - dbname=self.database, - user=self.user, - password=self.password, - ) + try: + return await aiopg.connect( + timeout=self._connection_timeout, + host=self.host, + port=self.port, + dbname=self.database, + user=self.user, + password=self.password, + ) + except (OperationalError, TimeoutError) as exc: + raise ConnectionException(f"There was not possible to connect to the database: {exc!r}") async def close(self) -> None: """Close database connection. @@ -163,9 +166,7 @@ async def _fetch_all(self) -> AsyncIterator[tuple]: except ProgrammingError as exc: raise ProgrammingException(str(exc)) except OperationalError as exc: - msg = f"There was an {exc!r} while trying to connect to the database." - logger.warning(msg) - raise ConnectionException(msg) + raise ConnectionException(f"There was not possible to connect to the database: {exc!r}") # noinspection PyUnusedLocal async def _execute(self, operation: AiopgDatabaseOperation) -> None: @@ -173,17 +174,19 @@ async def _execute(self, operation: AiopgDatabaseOperation) -> None: raise ValueError(f"The operation must be a {AiopgDatabaseOperation!r} instance. Obtained: {operation!r}") fn = partial(self._execute_cursor, operation=operation.query, parameters=operation.parameters) - try: - await self.with_circuit_breaker(fn) - except IntegrityError as exc: - raise IntegrityException(f"The requested operation raised a integrity error: {exc!r}") + await self.with_circuit_breaker(fn) async def _execute_cursor(self, operation: str, parameters: dict): if not await self.is_connected(): await self.recreate() self._cursor = await self._connection.cursor(timeout=self._cursor_timeout) - await self._cursor.execute(operation=operation, parameters=parameters) + try: + await self._cursor.execute(operation=operation, parameters=parameters) + except OperationalError as exc: + raise ConnectionException(f"There was not possible to connect to the database: {exc!r}") + except IntegrityError as exc: + raise IntegrityException(f"The requested operation raised a integrity error: {exc!r}") async def _destroy_cursor(self, **kwargs): if self._cursor is not None: From 1563754ac9e1f9480cdab15ffd104bfc3579cc6a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 20 Apr 2022 09:10:42 +0200 Subject: [PATCH 284/324] ISSUE #? * Raise a `StopAsyncIteration` when consumer is stopped. --- .../minos/plugins/kafka/subscriber.py | 7 +++---- .../tests/test_kafka/test_subscriber.py | 10 +--------- 2 files changed, 4 insertions(+), 13 deletions(-) diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py index 92c59bdbe..1166d0f41 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/subscriber.py @@ -166,10 +166,9 @@ def admin_client(self): async def _receive(self) -> BrokerMessage: try: record = await self.client.getone() - except ConsumerStoppedError as exc: - if self.already_destroyed: - raise StopAsyncIteration - raise exc + except ConsumerStoppedError: + raise StopAsyncIteration + bytes_ = record.value message = BrokerMessage.from_avro_bytes(bytes_) return message diff --git a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py index 4614d9b4f..27b7db855 100644 --- a/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py +++ b/packages/plugins/minos-broker-kafka/tests/test_kafka/test_subscriber.py @@ -201,20 +201,12 @@ async def test_receive(self): self.assertEqual(messages[0], await subscriber.receive()) self.assertEqual(messages[1], await subscriber.receive()) - async def test_receive_already_stopped_raises(self): - subscriber = KafkaBrokerSubscriber.from_config(CONFIG_FILE_PATH, topics={"foo", "bar"}) - get_mock = AsyncMock(side_effect=ConsumerStoppedError) - subscriber.client.getone = get_mock - - with self.assertRaises(StopAsyncIteration): - await subscriber.receive() - async def test_receive_stopped(self): async with KafkaBrokerSubscriber.from_config(CONFIG_FILE_PATH, topics={"foo", "bar"}) as subscriber: get_mock = AsyncMock(side_effect=ConsumerStoppedError) subscriber.client.getone = get_mock - with self.assertRaises(ConsumerStoppedError): + with self.assertRaises(StopAsyncIteration): await subscriber.receive() From 0313fbd1bb94110239252bc3969aa9ba440e0cf3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 20 Apr 2022 09:17:07 +0200 Subject: [PATCH 285/324] ISSUE #? * Simplify module hierarchies. --- .../repositories/database/{factories/abc.py => factories.py} | 2 +- .../events/repositories/database/factories/__init__.py | 3 --- .../repositories/database/{factories/abc.py => factories.py} | 2 +- .../snapshots/repositories/database/factories/__init__.py | 3 --- .../repositories/database/{factories/abc.py => factories.py} | 2 +- .../transactions/repositories/database/factories/__init__.py | 3 --- .../common/database/locks/{factories/abc.py => factories.py} | 2 +- .../minos/common/database/locks/factories/__init__.py | 3 --- .../database/{managements/factories.py => managements.py} | 2 +- .../minos/common/database/managements/__init__.py | 3 --- .../common/database/{operations/abc.py => operations.py} | 0 .../minos/common/database/operations/__init__.py | 5 ----- .../{test_operations/test_abc.py => test_operations.py} | 0 .../test_common/test_database/test_operations/__init__.py | 0 .../queues/database/{factories/abc.py => factories.py} | 0 .../collections/queues/database/factories/__init__.py | 3 --- .../duplicates/database/{factories/abc.py => factories.py} | 0 .../validators/duplicates/database/factories/__init__.py | 3 --- .../queues/database/{factories/abc.py => factories.py} | 2 +- .../subscribers/queued/queues/database/factories/__init__.py | 3 --- 20 files changed, 6 insertions(+), 35 deletions(-) rename packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/{factories/abc.py => factories.py} (99%) delete mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py rename packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/{factories/abc.py => factories.py} (99%) delete mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/__init__.py rename packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/{factories/abc.py => factories.py} (99%) delete mode 100644 packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py rename packages/core/minos-microservice-common/minos/common/database/locks/{factories/abc.py => factories.py} (96%) delete mode 100644 packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py rename packages/core/minos-microservice-common/minos/common/database/{managements/factories.py => managements.py} (96%) delete mode 100644 packages/core/minos-microservice-common/minos/common/database/managements/__init__.py rename packages/core/minos-microservice-common/minos/common/database/{operations/abc.py => operations.py} (100%) delete mode 100644 packages/core/minos-microservice-common/minos/common/database/operations/__init__.py rename packages/core/minos-microservice-common/tests/test_common/test_database/{test_operations/test_abc.py => test_operations.py} (100%) delete mode 100644 packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/__init__.py rename packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/{factories/abc.py => factories.py} (100%) delete mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py rename packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/{factories/abc.py => factories.py} (100%) delete mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py rename packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/{factories/abc.py => factories.py} (96%) delete mode 100644 packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories.py similarity index 99% rename from packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories.py index 80068df56..1860507f9 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories.py @@ -20,7 +20,7 @@ DatabaseOperationFactory, ) -from .....actions import ( +from ....actions import ( Action, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py deleted file mode 100644 index c78f0abb4..000000000 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/events/repositories/database/factories/__init__.py +++ /dev/null @@ -1,3 +0,0 @@ -from .abc import ( - EventDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories.py similarity index 99% rename from packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/abc.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories.py index 12b32dfdb..fe0d06937 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories.py @@ -21,7 +21,7 @@ DatabaseOperationFactory, ) -from .....queries import ( +from ....queries import ( _Condition, _Ordering, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/__init__.py deleted file mode 100644 index 0ac79d093..000000000 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/snapshots/repositories/database/factories/__init__.py +++ /dev/null @@ -1,3 +0,0 @@ -from .abc import ( - SnapshotDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories.py similarity index 99% rename from packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py rename to packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories.py index 5171be2b6..f5f23579f 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/abc.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories.py @@ -23,7 +23,7 @@ ) if TYPE_CHECKING: - from ....entries import ( + from ...entries import ( TransactionStatus, ) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py deleted file mode 100644 index c9fea61b2..000000000 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/transactions/repositories/database/factories/__init__.py +++ /dev/null @@ -1,3 +0,0 @@ -from .abc import ( - TransactionDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories.py similarity index 96% rename from packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py rename to packages/core/minos-microservice-common/minos/common/database/locks/factories.py index f16e689dd..b24f1a8fa 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/factories/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/factories.py @@ -3,7 +3,7 @@ abstractmethod, ) -from ...operations import ( +from ..operations import ( DatabaseOperation, DatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py b/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py deleted file mode 100644 index 47511313b..000000000 --- a/packages/core/minos-microservice-common/minos/common/database/locks/factories/__init__.py +++ /dev/null @@ -1,3 +0,0 @@ -from .abc import ( - LockDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-common/minos/common/database/managements/factories.py b/packages/core/minos-microservice-common/minos/common/database/managements.py similarity index 96% rename from packages/core/minos-microservice-common/minos/common/database/managements/factories.py rename to packages/core/minos-microservice-common/minos/common/database/managements.py index d84c5ebbe..729036d44 100644 --- a/packages/core/minos-microservice-common/minos/common/database/managements/factories.py +++ b/packages/core/minos-microservice-common/minos/common/database/managements.py @@ -3,7 +3,7 @@ abstractmethod, ) -from ..operations import ( +from .operations import ( DatabaseOperation, DatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-common/minos/common/database/managements/__init__.py b/packages/core/minos-microservice-common/minos/common/database/managements/__init__.py deleted file mode 100644 index a00b0ae0d..000000000 --- a/packages/core/minos-microservice-common/minos/common/database/managements/__init__.py +++ /dev/null @@ -1,3 +0,0 @@ -from .factories import ( - ManagementDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/abc.py b/packages/core/minos-microservice-common/minos/common/database/operations.py similarity index 100% rename from packages/core/minos-microservice-common/minos/common/database/operations/abc.py rename to packages/core/minos-microservice-common/minos/common/database/operations.py diff --git a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py b/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py deleted file mode 100644 index 96a05c57c..000000000 --- a/packages/core/minos-microservice-common/minos/common/database/operations/__init__.py +++ /dev/null @@ -1,5 +0,0 @@ -from .abc import ( - ComposedDatabaseOperation, - DatabaseOperation, - DatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations.py similarity index 100% rename from packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/test_abc.py rename to packages/core/minos-microservice-common/tests/test_common/test_database/test_operations.py diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/__init__.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_operations/__init__.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories.py similarity index 100% rename from packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/abc.py rename to packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories.py diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py deleted file mode 100644 index f00f6af3a..000000000 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/collections/queues/database/factories/__init__.py +++ /dev/null @@ -1,3 +0,0 @@ -from .abc import ( - BrokerQueueDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories.py similarity index 100% rename from packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/abc.py rename to packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories.py diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py deleted file mode 100644 index a96d4d6bc..000000000 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/filtered/validators/duplicates/database/factories/__init__.py +++ /dev/null @@ -1,3 +0,0 @@ -from .abc import ( - BrokerSubscriberDuplicateValidatorDatabaseOperationFactory, -) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories.py similarity index 96% rename from packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py rename to packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories.py index cfa68708b..a9ceacf23 100644 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/abc.py +++ b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories.py @@ -10,7 +10,7 @@ DatabaseOperation, ) -from ......collections import ( +from .....collections import ( BrokerQueueDatabaseOperationFactory, ) diff --git a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py b/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py deleted file mode 100644 index ec7ac9533..000000000 --- a/packages/core/minos-microservice-networks/minos/networks/brokers/subscribers/queued/queues/database/factories/__init__.py +++ /dev/null @@ -1,3 +0,0 @@ -from .abc import ( - BrokerSubscriberQueueDatabaseOperationFactory, -) From c8dd6a214b917ac251fde0e68c3fc6bc6d5ead16 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Wed, 20 Apr 2022 19:07:37 +0200 Subject: [PATCH 286/324] ISSUE #403 --- .../plugins/minos-discovery-kong/README.md | 35 +++++++++++++++++++ .../minos/plugins/kong/discovery.py | 2 +- .../minos/plugins/kong/utils.py | 20 +++++++++++ .../tests/test_kong/test_utils.py | 26 ++++++++++++++ 4 files changed, 82 insertions(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/README.md b/packages/plugins/minos-discovery-kong/README.md index 82c52a039..b6c081107 100644 --- a/packages/plugins/minos-discovery-kong/README.md +++ b/packages/plugins/minos-discovery-kong/README.md @@ -63,6 +63,22 @@ services: - NODE_ENV=production ``` +## Decorators +Decorator `@enroute` can support next params: + - `path` - route url path. + - `method` - HTTP method. + - `authenticated` (Optional) - True if route need authentication. + - `authorized_groups` (Optional) - Groups which can access to specified route (they must exist in Kong). + - `regex_priority` (Optional) - A number used to choose which route resolves a given request when several routes match it using regexes simultaneously. When two routes match the path and have the same regex_priority, the older one (lowest created_at) is used. Note that the priority for non-regex routes is different (longer non-regex routes are matched before shorter ones). Defaults to 0. + +Example: +```python + @enroute.rest.command(f"/users/{{uuid:{UUID_REGEX.pattern}}}/jwt", "POST", authenticated=True, authorized_groups=["admin"], regex_priority=2) + @enroute.broker.command("GetUserJWT") + async def foo(self, request: Request) -> Response: + ... +``` + ## Authentication Modify `config.yml` file. Add new middleware and modify discovery section: @@ -85,6 +101,23 @@ Currently, there are 2 possible types of authentication: - `basic-auth` - `jwt` +For jwt auth type you can specify default token expiration. Example: +```yaml +... +middleware: + ... + - minos.plugins.kong.middleware + +discovery: + connector: minos.networks.DiscoveryConnector + client: minos.plugins.kong.KongDiscoveryClient + host: localhost + auth-type: jwt + token-exp-minutes: 60 + port: 8001 +... +``` + For the route to be authenticated with the method specified above, a parameter called `authenticated` must be passed: ```python class CategoryCommandService(CommandService): @@ -222,6 +255,8 @@ class UserCommandService(CommandService): ``` You can get read the official docs [here](https://pantsel.github.io/konga/). + + ## Documentation The official API Reference is publicly available at the [GitHub Pages](https://minos-framework.github.io/minos-python). diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py index fd269ff3e..fe6d51355 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py @@ -112,7 +112,7 @@ async def subscribe( self.route, ["http"], [endpoint["method"]], - [endpointClass.path_as_str], + [endpointClass.path_as_regex], content_service["id"], regex_priority, False, diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/utils.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/utils.py index 431a3dcad..5874e12af 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/utils.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/utils.py @@ -1,3 +1,6 @@ +import re + + class PathPart: def __init__(self, name: str): self.name = name @@ -5,6 +8,8 @@ def __init__(self, name: str): class Endpoint: + part_path_pattern = r"\{\S+:.+\}" + def __init__(self, path: str): self.path: tuple[PathPart] = tuple(PathPart(path_part) for path_part in path.split("/")) @@ -16,3 +21,18 @@ def path_as_str(self) -> str: part.name = ".*" list_parts.append(str(part.name)) return "/".join(list_parts) + + @property + def path_as_regex(self) -> str: + list_parts = [] + for part in self.path: + if part.is_generic: + if re.match(self.part_path_pattern, part.name): + regex = part.name.split(":")[1] + regex = regex[:-1] + list_parts.append(regex) + else: + list_parts.append(".*") + else: + list_parts.append(part.name) + return "/".join(list_parts) diff --git a/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py b/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py index 79dab4025..e9ff524b3 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py +++ b/packages/plugins/minos-discovery-kong/tests/test_kong/test_utils.py @@ -18,3 +18,29 @@ def test_path_constructor(self) -> None: self.assertIsInstance(pathpart, PathPart) self.assertEqual(pathpart.name, "minos") self.assertEqual(pathpart.is_generic, False) + + def test_path_as_str(self) -> None: + pathpart = Endpoint(r"/user/{uuid:\w{8}-\w{4}-\w{4}-\w{4}-\w{12}}") + self.assertEqual(pathpart.path_as_str, "/user/.*") + + def test_path_as_regex(self) -> None: + # pylint: disable=W605 + pathpart = Endpoint(r"/user/{uuid:\w{8}-\w{4}-\w{4}-\w{4}-\w{12}}") + self.assertEqual(pathpart.path_as_regex, "/user/\\w{8}-\\w{4}-\\w{4}-\\w{4}-\\w{12}") + + def test_path_as_regex_simple_parameter(self) -> None: + pathpart = Endpoint("/user/{uuid}") + self.assertEqual(pathpart.path_as_regex, "/user/.*") + + def test_path_as_regex_parameter(self) -> None: + pathpart = Endpoint("/user/{:uuid}") + self.assertEqual(pathpart.path_as_regex, "/user/.*") + + def test_path_as_regex_multiple_parameter(self) -> None: + pathpart = Endpoint("/user/{:uuid}/{:uuid}") + self.assertEqual(pathpart.path_as_regex, "/user/.*/.*") + + def test_path_as_regex_uuid(self) -> None: + # pylint: disable=W605 + pathpart = Endpoint(r"/user/{uuid:\w{8}-\w{4}-\w{4}-\w{4}-\w{12}}/test") + self.assertEqual(pathpart.path_as_regex, "/user/\\w{8}-\\w{4}-\\w{4}-\\w{4}-\\w{12}/test") From 0170855d1e5fd558321fb6a394db71f0e48a5d52 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Wed, 20 Apr 2022 22:01:16 +0200 Subject: [PATCH 287/324] ISSUE #403 --- .../plugins/minos-discovery-kong/README.md | 80 +++++++++++++++++++ 1 file changed, 80 insertions(+) diff --git a/packages/plugins/minos-discovery-kong/README.md b/packages/plugins/minos-discovery-kong/README.md index b6c081107..7ea054d2e 100644 --- a/packages/plugins/minos-discovery-kong/README.md +++ b/packages/plugins/minos-discovery-kong/README.md @@ -78,6 +78,18 @@ Example: async def foo(self, request: Request) -> Response: ... ``` +## Route path +It is important to know that it is best to define routes with a regular expression when it is an id, uuid or similar. This is to avoid collisions with similar routes. +Instead of using: +```python +@enroute.rest.command("/users/{uuid}", "POST") +``` +Use: +```python +import re +UUID_REGEX = re.compile(r"\w{8}-\w{4}-\w{4}-\w{4}-\w{12}") +@enroute.rest.command(f"/users/{{uuid:{UUID_REGEX.pattern}}}", "POST") +``` ## Authentication @@ -118,6 +130,74 @@ discovery: ... ``` +### JWT Token creation & refresh +Example on how to create and refresh token. You need to store in database or similar the secret and key returned form kong in order to refresh existing token. +```python +from minos.common import ( + UUID_REGEX, + NotProvidedException, + Config, + Inject, +) +from minos.cqrs import ( + CommandService, +) +from minos.networks import ( + Request, + Response, + enroute, +) + +from ..aggregates import ( + User, +) +from minos.plugins.kong import KongClient + +class UserCommandService(CommandService): + """UserCommandService class.""" + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self.kong = self._get_kong_client() + + @staticmethod + @Inject() + def _get_kong_client(config: Config) -> KongClient: + """Get the service name.""" + if config is None: + raise NotProvidedException("The config object must be provided.") + return KongClient.from_config(config) + + @enroute.rest.command(f"/users/{{uuid:{UUID_REGEX.pattern}}}/jwt", "POST", authenticated=True, + authorized_groups=["admin"], regex_priority=3) + @enroute.broker.command("GetUserJWT") + async def create_user_jwt(self, request: Request) -> Response: + params = await request.params() + uuid = params["uuid"] + user = await User.get(uuid) + + if user.uuid == request.user: + token = await self.add_jwt_to_consumer(request.headers.get("X-Consumer-ID")) + return Response({"token": token}) + else: + return Response(status=404) + + async def add_jwt_to_consumer(self, consumer: str): + resp = await self.kong.add_jwt_to_consumer(consumer=consumer) + res = resp.json() + self.key = res['key'] + self.secret = res['secret'] + token = await self.kong.generate_jwt_token(key=self.key, secret=self.secret) + return token + + @enroute.rest.command(f"/users/{{uuid:{UUID_REGEX.pattern}}}/refresh-jwt", "POST", authenticated=True, + authorized_groups=["admin"], regex_priority=3) + @enroute.broker.command("RefreshJWT") + async def refresh_jwt(self, request: Request) -> Response: + token = await self.kong.generate_jwt_token(key=self.key, secret=self.secret) + return Response({"token": token}) +``` + For the route to be authenticated with the method specified above, a parameter called `authenticated` must be passed: ```python class CategoryCommandService(CommandService): From c5f4a1e09eb74c4d07963725eec126a37c927fea Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 21 Apr 2022 10:30:29 +0200 Subject: [PATCH 288/324] ISSUE #390 --- .../minos/plugins/kong/client.py | 13 +++++-------- .../minos/plugins/kong/discovery.py | 2 +- .../minos-discovery-kong/tests/test_config.yml | 2 +- 3 files changed, 7 insertions(+), 10 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index 77728cc57..07a8a6f68 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -1,10 +1,6 @@ from __future__ import ( annotations, ) - -from abc import ( - ABC, -) from datetime import ( datetime, timedelta, @@ -22,14 +18,15 @@ from minos.common import ( Config, SetupMixin, + current_datetime ) -class KongClient(ABC, SetupMixin): +class KongClient(SetupMixin): """Kong Client class.""" def __init__( - self, protocol: str = "http", host: str = None, port: str = None, token_expiration_sec: int = None, **kwargs + self, protocol: str = "http", host: str = None, port: int = None, token_expiration_sec: int = None, **kwargs ): super().__init__(**kwargs) if host is None: @@ -46,7 +43,7 @@ def __init__( def _from_config(cls, config: Config, **kwargs) -> KongClient: discovery_config = config.get_discovery() - token_expiration_sec = discovery_config.get("token-exp-minutes") + token_expiration_sec = discovery_config.get("token-exp") host = discovery_config.get("host") port = discovery_config.get("port") @@ -187,7 +184,7 @@ async def generate_jwt_token( ) -> str: payload = {"iss": key, "exp": exp, "nbf": nbf} - current = datetime.now(tz=utc) + current = current_datetime() if not exp: payload["exp"] = current + timedelta(seconds=self.token_expiration_sec) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py index fe6d51355..b64a06677 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/discovery.py @@ -53,7 +53,7 @@ def __init__( ) if client is None: - client = KongClient() + client = KongClient(host=host, port=port) self.client = client diff --git a/packages/plugins/minos-discovery-kong/tests/test_config.yml b/packages/plugins/minos-discovery-kong/tests/test_config.yml index 64a72f9c0..dbcda81b7 100644 --- a/packages/plugins/minos-discovery-kong/tests/test_config.yml +++ b/packages/plugins/minos-discovery-kong/tests/test_config.yml @@ -2,6 +2,6 @@ discovery: connector: minos.networks.DiscoveryConnector client: minos.networks.InMemoryDiscoveryClient auth-type: jwt - token-exp-minutes: 60 + token-exp: 60 host: localhost port: 8001 From 4c9363c6de75aa4622bf9490bf93910c751fe8e2 Mon Sep 17 00:00:00 2001 From: Vladyslav Fenchak Date: Thu, 21 Apr 2022 10:37:46 +0200 Subject: [PATCH 289/324] ISSUE #390 --- packages/plugins/minos-discovery-kong/README.md | 2 +- .../plugins/minos-discovery-kong/minos/plugins/kong/client.py | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/README.md b/packages/plugins/minos-discovery-kong/README.md index 7ea054d2e..d5b931a25 100644 --- a/packages/plugins/minos-discovery-kong/README.md +++ b/packages/plugins/minos-discovery-kong/README.md @@ -125,7 +125,7 @@ discovery: client: minos.plugins.kong.KongDiscoveryClient host: localhost auth-type: jwt - token-exp-minutes: 60 + token-exp: 60 # seconds port: 8001 ... ``` diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index 07a8a6f68..f0a07d4c1 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -11,9 +11,6 @@ import httpx as httpx import jwt -from pytz import ( - utc, -) from minos.common import ( Config, From 565a9070a7ea9824542dbe26dd75a8932828b90b Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Thu, 21 Apr 2022 08:37:55 +0000 Subject: [PATCH 290/324] Restyled by black --- .../minos-discovery-kong/minos/plugins/kong/client.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index f0a07d4c1..a436a0169 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -12,11 +12,7 @@ import httpx as httpx import jwt -from minos.common import ( - Config, - SetupMixin, - current_datetime -) +from minos.common import Config, SetupMixin, current_datetime class KongClient(SetupMixin): From 6f32a09a659b24a2c6573f2736ea860124b5c7c1 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Thu, 21 Apr 2022 08:37:56 +0000 Subject: [PATCH 291/324] Restyled by isort --- .../minos-discovery-kong/minos/plugins/kong/client.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index a436a0169..4c3be03f3 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -1,6 +1,7 @@ from __future__ import ( annotations, ) + from datetime import ( datetime, timedelta, @@ -12,7 +13,11 @@ import httpx as httpx import jwt -from minos.common import Config, SetupMixin, current_datetime +from minos.common import ( + Config, + SetupMixin, + current_datetime, +) class KongClient(SetupMixin): From 58cbe1513e44f1dd0ef09f53e62ccbdac4678557 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 21 Apr 2022 13:10:23 +0200 Subject: [PATCH 292/324] ISSUE #? * Remove `minos.networks.Builder`. --- .../minos/networks/__init__.py | 1 - .../minos/networks/utils.py | 11 ----------- .../tests/test_networks/test_utils.py | 14 -------------- 3 files changed, 26 deletions(-) diff --git a/packages/core/minos-microservice-networks/minos/networks/__init__.py b/packages/core/minos-microservice-networks/minos/networks/__init__.py index 0dd2582c7..c9de575e6 100644 --- a/packages/core/minos-microservice-networks/minos/networks/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/__init__.py @@ -140,7 +140,6 @@ SystemService, ) from .utils import ( - Builder, consume_queue, get_host_ip, get_host_name, diff --git a/packages/core/minos-microservice-networks/minos/networks/utils.py b/packages/core/minos-microservice-networks/minos/networks/utils.py index d2984217d..e53442643 100644 --- a/packages/core/minos-microservice-networks/minos/networks/utils.py +++ b/packages/core/minos-microservice-networks/minos/networks/utils.py @@ -4,13 +4,10 @@ import re import socket -import warnings from asyncio import ( QueueEmpty, ) -from minos.common import Builder as CommonBuilder - def get_host_ip() -> str: """Get the host ip. @@ -54,11 +51,3 @@ async def consume_queue(queue, max_count: int) -> None: queue.get_nowait() except QueueEmpty: break - - -class Builder(CommonBuilder): - """Builder class.""" - - def __init__(self, *args, **kwargs): - warnings.warn(f"{Builder!r} has been deprecated. Use {CommonBuilder} instead.", DeprecationWarning) - super().__init__(*args, **kwargs) diff --git a/packages/core/minos-microservice-networks/tests/test_networks/test_utils.py b/packages/core/minos-microservice-networks/tests/test_networks/test_utils.py index 5e4cc21fd..fcbe773f8 100644 --- a/packages/core/minos-microservice-networks/tests/test_networks/test_utils.py +++ b/packages/core/minos-microservice-networks/tests/test_networks/test_utils.py @@ -1,12 +1,9 @@ import unittest -import warnings from asyncio import ( Queue, ) -from minos.common import Builder as CommonBuilder from minos.networks import ( - Builder, consume_queue, ) @@ -32,16 +29,5 @@ async def test_consume_queue_full(self): self.assertTrue(queue.empty()) -class TestBuilder(unittest.TestCase): - def test_is_subclass(self): - self.assertTrue(issubclass(Builder, CommonBuilder)) - - def test_warnings(self): - with warnings.catch_warnings(): - warnings.simplefilter("ignore", DeprecationWarning) - builder = Builder() - self.assertIsInstance(builder, CommonBuilder) - - if __name__ == "__main__": unittest.main() From 485ca21f2a9c032818908d127ccf341e91327126 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 21 Apr 2022 13:13:01 +0200 Subject: [PATCH 293/324] v0.7.0.dev2 --- .../minos/aggregate/__init__.py | 2 +- .../minos-microservice-aggregate/poetry.lock | 128 ++++------ .../pyproject.toml | 2 +- .../minos/common/__init__.py | 2 +- .../minos-microservice-common/poetry.lock | 86 +++---- .../minos-microservice-common/pyproject.toml | 2 +- .../minos/cqrs/__init__.py | 2 +- .../core/minos-microservice-cqrs/poetry.lock | 231 ++++-------------- .../minos-microservice-cqrs/pyproject.toml | 2 +- .../minos/networks/__init__.py | 2 +- .../minos-microservice-networks/poetry.lock | 126 ++++------ .../pyproject.toml | 2 +- .../minos/saga/__init__.py | 2 +- .../core/minos-microservice-saga/poetry.lock | 231 ++++-------------- .../minos-microservice-saga/pyproject.toml | 2 +- .../minos/plugins/kafka/__init__.py | 2 +- .../plugins/minos-broker-kafka/poetry.lock | 228 ++++------------- .../plugins/minos-broker-kafka/pyproject.toml | 2 +- .../minos/plugins/rabbitmq/__init__.py | 2 +- .../plugins/minos-broker-rabbitmq/poetry.lock | 228 ++++------------- .../minos-broker-rabbitmq/pyproject.toml | 2 +- .../minos/plugins/aiopg/__init__.py | 2 +- .../plugins/minos-database-aiopg/poetry.lock | 44 +--- .../minos-database-aiopg/pyproject.toml | 2 +- .../minos/plugins/lmdb/__init__.py | 2 +- .../plugins/minos-database-lmdb/poetry.lock | 9 +- .../minos-database-lmdb/pyproject.toml | 2 +- .../minos/plugins/kong/__init__.py | 2 +- .../plugins/minos-discovery-kong/poetry.lock | 228 ++++------------- .../minos-discovery-kong/pyproject.toml | 2 +- .../minos/plugins/graphql/__init__.py | 2 +- .../plugins/minos-router-graphql/poetry.lock | 228 ++++------------- .../minos-router-graphql/pyproject.toml | 2 +- poetry.lock | 101 ++++++-- pyproject.toml | 6 +- 35 files changed, 522 insertions(+), 1396 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index 3c99d6c3a..05bcc105c 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev2" from .actions import ( Action, diff --git a/packages/core/minos-microservice-aggregate/poetry.lock b/packages/core/minos-microservice-aggregate/poetry.lock index 6a47dc8e4..99664df97 100644 --- a/packages/core/minos-microservice-aggregate/poetry.lock +++ b/packages/core/minos-microservice-aggregate/poetry.lock @@ -189,14 +189,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -207,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -219,7 +211,6 @@ aiomisc = ">=14.0.3,<15.8.0" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -230,7 +221,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -255,7 +246,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -282,15 +273,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -386,11 +377,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -578,35 +569,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -618,38 +580,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -660,8 +622,8 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, @@ -731,8 +693,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index d8b52373b..d36820a8f 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-aggregate" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The Aggregate pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 1c38ac410..2b8693c9f 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -1,7 +1,7 @@ """The common core of the Minos Framework.""" __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev2" from .builders import ( BuildableMixin, diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index ee5ec595e..540e1fe91 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -199,7 +199,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -226,15 +226,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -330,11 +330,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -528,38 +528,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -570,8 +570,8 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, @@ -641,8 +641,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index c3fd9aa9a..eaba45f67 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py b/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py index 2f34314d9..daeca9061 100644 --- a/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py +++ b/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev2" from .exceptions import ( MinosCqrsException, diff --git a/packages/core/minos-microservice-cqrs/poetry.lock b/packages/core/minos-microservice-cqrs/poetry.lock index bc0c15e2b..d3a586e83 100644 --- a/packages/core/minos-microservice-cqrs/poetry.lock +++ b/packages/core/minos-microservice-cqrs/poetry.lock @@ -19,29 +19,6 @@ develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-ti raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - -[[package]] -name = "async-timeout" -version = "4.0.2" -description = "Timeout context manager for asyncio programs" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "atomicwrites" version = "1.4.0" @@ -212,14 +189,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -230,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -241,7 +210,6 @@ develop = true cached-property = "^1.5.2" minos-microservice-common = "^0.7.0*" minos-microservice-networks = "^0.7.0*" -psycopg2-binary = "^2.9.3" [package.source] type = "directory" @@ -249,7 +217,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -258,11 +226,9 @@ develop = true [package.dependencies] aiomisc = ">=14.0.3,<15.8.0" -aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -273,7 +239,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -281,10 +247,8 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiopg = "^1.2.1" crontab = "^0.23.0" minos-microservice-common = "^0.7.0*" -psycopg2-binary = "^2.9.3" [package.source] type = "directory" @@ -300,7 +264,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -327,15 +291,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -349,14 +313,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "py" version = "1.11.0" @@ -439,11 +395,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -468,14 +424,6 @@ aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] -async-timeout = [ - {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, - {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, -] atomicwrites = [ {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, @@ -639,35 +587,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -680,38 +599,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -722,71 +641,13 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, @@ -851,8 +712,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index 25286b446..c5e02738e 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-cqrs" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The CQRS pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-networks/minos/networks/__init__.py b/packages/core/minos-microservice-networks/minos/networks/__init__.py index c9de575e6..d3ae24f8e 100644 --- a/packages/core/minos-microservice-networks/minos/networks/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev2" from .brokers import ( REQUEST_HEADERS_CONTEXT_VAR, diff --git a/packages/core/minos-microservice-networks/poetry.lock b/packages/core/minos-microservice-networks/poetry.lock index e894a9c2c..fd5f64712 100644 --- a/packages/core/minos-microservice-networks/poetry.lock +++ b/packages/core/minos-microservice-networks/poetry.lock @@ -189,14 +189,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -207,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -219,7 +211,6 @@ aiomisc = ">=14.0.3,<15.8.0" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -238,7 +229,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -265,15 +256,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -369,11 +360,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -561,35 +552,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -600,38 +562,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -642,8 +604,8 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, @@ -713,8 +675,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index 6f43b7185..1120a73b1 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-saga/minos/saga/__init__.py b/packages/core/minos-microservice-saga/minos/saga/__init__.py index 260a0ab5f..351dee65a 100644 --- a/packages/core/minos-microservice-saga/minos/saga/__init__.py +++ b/packages/core/minos-microservice-saga/minos/saga/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev2" from .context import ( SagaContext, diff --git a/packages/core/minos-microservice-saga/poetry.lock b/packages/core/minos-microservice-saga/poetry.lock index 9b8d56bdf..ee6de98e1 100644 --- a/packages/core/minos-microservice-saga/poetry.lock +++ b/packages/core/minos-microservice-saga/poetry.lock @@ -19,29 +19,6 @@ develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-ti raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - -[[package]] -name = "async-timeout" -version = "4.0.2" -description = "Timeout context manager for asyncio programs" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "atomicwrites" version = "1.4.0" @@ -212,14 +189,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -230,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -241,7 +210,6 @@ develop = true cached-property = "^1.5.2" minos-microservice-common = "^0.7.0*" minos-microservice-networks = "^0.7.0*" -psycopg2-binary = "^2.9.3" [package.source] type = "directory" @@ -249,7 +217,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -258,11 +226,9 @@ develop = true [package.dependencies] aiomisc = ">=14.0.3,<15.8.0" -aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -273,7 +239,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -281,10 +247,8 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiopg = "^1.2.1" crontab = "^0.23.0" minos-microservice-common = "^0.7.0*" -psycopg2-binary = "^2.9.3" [package.source] type = "directory" @@ -300,7 +264,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -327,15 +291,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -349,14 +313,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "py" version = "1.11.0" @@ -439,11 +395,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -468,14 +424,6 @@ aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] -async-timeout = [ - {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, - {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, -] atomicwrites = [ {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, @@ -639,35 +587,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -680,38 +599,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -722,71 +641,13 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, @@ -851,8 +712,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index 2aeb27abb..e34329c61 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-saga" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The SAGA pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py index e1a448f99..17537c081 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev2" from .common import ( KafkaBrokerBuilderMixin, diff --git a/packages/plugins/minos-broker-kafka/poetry.lock b/packages/plugins/minos-broker-kafka/poetry.lock index 917f8a71e..5bb6c4143 100644 --- a/packages/plugins/minos-broker-kafka/poetry.lock +++ b/packages/plugins/minos-broker-kafka/poetry.lock @@ -33,29 +33,6 @@ develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-ti raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - -[[package]] -name = "async-timeout" -version = "4.0.2" -description = "Timeout context manager for asyncio programs" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "atomicwrites" version = "1.4.0" @@ -237,14 +214,6 @@ python-versions = "*" [package.extras] crc32c = ["crc32c"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -255,7 +224,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -264,11 +233,9 @@ develop = true [package.dependencies] aiomisc = ">=14.0.3,<15.8.0" -aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -279,7 +246,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -287,10 +254,8 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiopg = "^1.2.1" crontab = "^0.23.0" minos-microservice-common = "^0.7.0*" -psycopg2-binary = "^2.9.3" [package.source] type = "directory" @@ -306,7 +271,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -333,15 +298,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -355,14 +320,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "py" version = "1.11.0" @@ -453,11 +410,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -505,14 +462,6 @@ aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] -async-timeout = [ - {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, - {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, -] atomicwrites = [ {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, @@ -680,35 +629,6 @@ kafka-python = [ {file = "kafka-python-2.0.2.tar.gz", hash = "sha256:04dfe7fea2b63726cd6f3e79a2d86e709d608d74406638c5da33a01d45a9d7e3"}, {file = "kafka_python-2.0.2-py2.py3-none-any.whl", hash = "sha256:2d92418c7cb1c298fa6c7f0fb3519b520d0d7526ac6cb7ae2a4fc65a51a94b6e"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -720,38 +640,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -762,71 +682,13 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, @@ -895,8 +757,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/plugins/minos-broker-kafka/pyproject.toml b/packages/plugins/minos-broker-kafka/pyproject.toml index 21325bcdf..c3efa2ee0 100644 --- a/packages/plugins/minos-broker-kafka/pyproject.toml +++ b/packages/plugins/minos-broker-kafka/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-broker-kafka" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The kafka plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py b/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py index 562bf559f..8367efc3d 100644 --- a/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py +++ b/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev2" from .common import ( RabbitMQBrokerBuilderMixin, diff --git a/packages/plugins/minos-broker-rabbitmq/poetry.lock b/packages/plugins/minos-broker-rabbitmq/poetry.lock index c9108fa32..7be5608d0 100644 --- a/packages/plugins/minos-broker-rabbitmq/poetry.lock +++ b/packages/plugins/minos-broker-rabbitmq/poetry.lock @@ -34,21 +34,6 @@ develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-ti raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - [[package]] name = "aiormq" version = "6.2.3" @@ -64,14 +49,6 @@ yarl = "*" [package.extras] develop = ["aiomisc (>=11.0,<12.0)", "coverage (!=4.3)", "coveralls", "pylava", "pytest", "pytest-cov", "tox (>=2.4)"] -[[package]] -name = "async-timeout" -version = "4.0.2" -description = "Timeout context manager for asyncio programs" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "atomicwrites" version = "1.4.0" @@ -250,14 +227,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -268,7 +237,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -277,11 +246,9 @@ develop = true [package.dependencies] aiomisc = ">=14.0.3,<15.8.0" -aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -292,7 +259,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -300,10 +267,8 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiopg = "^1.2.1" crontab = "^0.23.0" minos-microservice-common = "^0.7.0*" -psycopg2-binary = "^2.9.3" [package.source] type = "directory" @@ -327,7 +292,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -366,15 +331,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -388,14 +353,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "py" version = "1.11.0" @@ -486,11 +443,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -531,18 +488,10 @@ aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] aiormq = [ {file = "aiormq-6.2.3-py3-none-any.whl", hash = "sha256:95f0da57edd55f214a2e6c5b7ac98fa58a7c33911acd0d3315e86926b2dd2605"}, {file = "aiormq-6.2.3.tar.gz", hash = "sha256:db6c1e6e384f1d4dafe19f8df70c6dfc994932b40f4e542690016023ff8e952b"}, ] -async-timeout = [ - {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, - {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, -] atomicwrites = [ {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, @@ -710,35 +659,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -811,38 +731,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -856,71 +776,13 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, @@ -989,8 +851,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/plugins/minos-broker-rabbitmq/pyproject.toml b/packages/plugins/minos-broker-rabbitmq/pyproject.toml index 9b3d256be..ff2f9a597 100644 --- a/packages/plugins/minos-broker-rabbitmq/pyproject.toml +++ b/packages/plugins/minos-broker-rabbitmq/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-broker-rabbitmq" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The rabbitmq plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py index b6329ef10..152433c47 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.0.0" +__version__ = "0.7.0.dev2" from .clients import ( AiopgDatabaseClient, diff --git a/packages/plugins/minos-database-aiopg/poetry.lock b/packages/plugins/minos-database-aiopg/poetry.lock index 594d758c3..29e4acb6c 100644 --- a/packages/plugins/minos-database-aiopg/poetry.lock +++ b/packages/plugins/minos-database-aiopg/poetry.lock @@ -212,14 +212,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -230,7 +222,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -248,7 +240,7 @@ url = "../../core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -260,7 +252,6 @@ aiomisc = ">=14.0.3,<15.8.0" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -271,7 +262,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -635,35 +626,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, diff --git a/packages/plugins/minos-database-aiopg/pyproject.toml b/packages/plugins/minos-database-aiopg/pyproject.toml index 0bb1ef2ae..ddd897287 100644 --- a/packages/plugins/minos-database-aiopg/pyproject.toml +++ b/packages/plugins/minos-database-aiopg/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-database-aiopg" -version = "0.0.0" +version = "0.7.0.dev2" description = "The aiopg plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py index 98c192e2a..24074b81d 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.0.0" +__version__ = "0.7.0.dev2" from .clients import ( LmdbDatabaseClient, diff --git a/packages/plugins/minos-database-lmdb/poetry.lock b/packages/plugins/minos-database-lmdb/poetry.lock index 0c2aef563..875f0f579 100644 --- a/packages/plugins/minos-database-lmdb/poetry.lock +++ b/packages/plugins/minos-database-lmdb/poetry.lock @@ -207,7 +207,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -225,7 +225,7 @@ url = "../../core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -237,7 +237,6 @@ aiomisc = ">=14.0.3,<15.8.0" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -248,7 +247,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -265,7 +264,7 @@ url = "../../core/minos-microservice-networks" [[package]] name = "minos-microservice-saga" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The SAGA pattern of the Minos Framework" category = "main" optional = false diff --git a/packages/plugins/minos-database-lmdb/pyproject.toml b/packages/plugins/minos-database-lmdb/pyproject.toml index d2e063afc..7e3b9c1cb 100644 --- a/packages/plugins/minos-database-lmdb/pyproject.toml +++ b/packages/plugins/minos-database-lmdb/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-database-lmdb" -version = "0.0.0" +version = "0.7.0.dev2" description = "The lmdb plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index 0d4a9459f..7d6888d9d 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -1,6 +1,6 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev2" from .client import ( KongClient, diff --git a/packages/plugins/minos-discovery-kong/poetry.lock b/packages/plugins/minos-discovery-kong/poetry.lock index 93f13ec58..317c08de6 100644 --- a/packages/plugins/minos-discovery-kong/poetry.lock +++ b/packages/plugins/minos-discovery-kong/poetry.lock @@ -19,21 +19,6 @@ develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-ti raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - [[package]] name = "anyio" version = "3.5.0" @@ -51,14 +36,6 @@ doc = ["packaging", "sphinx-rtd-theme", "sphinx-autodoc-typehints (>=1.2.0)"] test = ["coverage[toml] (>=4.5)", "hypothesis (>=4.0)", "pytest (>=6.0)", "pytest-mock (>=3.6.1)", "trustme", "contextlib2", "uvloop (<0.15)", "mock (>=4)", "uvloop (>=0.15)"] trio = ["trio (>=0.16)"] -[[package]] -name = "async-timeout" -version = "4.0.2" -description = "Timeout context manager for asyncio programs" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "atomicwrites" version = "1.4.0" @@ -303,14 +280,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -321,7 +290,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -330,11 +299,9 @@ develop = true [package.dependencies] aiomisc = ">=14.0.3,<15.8.0" -aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -345,7 +312,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -353,10 +320,8 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiopg = "^1.2.1" crontab = "^0.23.0" minos-microservice-common = "^0.7.0*" -psycopg2-binary = "^2.9.3" [package.source] type = "directory" @@ -372,7 +337,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -399,15 +364,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -421,14 +386,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "py" version = "1.11.0" @@ -563,11 +520,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -592,18 +549,10 @@ aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] anyio = [ {file = "anyio-3.5.0-py3-none-any.whl", hash = "sha256:b5fa16c5ff93fa1046f2eeb5bbff2dad4d3514d6cda61d02816dba34fa8c3c2e"}, {file = "anyio-3.5.0.tar.gz", hash = "sha256:a0aeffe2fb1fdf374a8e4b471444f0f3ac4fb9f5a5b542b48824475e0042a5a6"}, ] -async-timeout = [ - {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, - {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, -] atomicwrites = [ {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, @@ -791,35 +740,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -831,38 +751,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -873,71 +793,13 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, @@ -1022,8 +884,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index 33aeb87f6..dd4a45e56 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-kong" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py b/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py index 7edb5204a..84740e242 100644 --- a/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py +++ b/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev2" from .builders import ( GraphQLSchemaBuilder, diff --git a/packages/plugins/minos-router-graphql/poetry.lock b/packages/plugins/minos-router-graphql/poetry.lock index 30e4b6736..4ab43836d 100644 --- a/packages/plugins/minos-router-graphql/poetry.lock +++ b/packages/plugins/minos-router-graphql/poetry.lock @@ -19,29 +19,6 @@ develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-ti raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - -[[package]] -name = "async-timeout" -version = "4.0.2" -description = "Timeout context manager for asyncio programs" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "atomicwrites" version = "1.4.0" @@ -220,14 +197,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -238,7 +207,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -247,11 +216,9 @@ develop = true [package.dependencies] aiomisc = ">=14.0.3,<15.8.0" -aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -262,7 +229,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -270,10 +237,8 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiopg = "^1.2.1" crontab = "^0.23.0" minos-microservice-common = "^0.7.0*" -psycopg2-binary = "^2.9.3" [package.source] type = "directory" @@ -289,7 +254,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -316,15 +281,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -338,14 +303,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "py" version = "1.11.0" @@ -436,11 +393,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -465,14 +422,6 @@ aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] -async-timeout = [ - {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, - {file = "async_timeout-4.0.2-py3-none-any.whl", hash = "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"}, -] atomicwrites = [ {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, {file = "atomicwrites-1.4.0.tar.gz", hash = "sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a"}, @@ -640,35 +589,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -680,38 +600,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -722,71 +642,13 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, @@ -855,8 +717,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/plugins/minos-router-graphql/pyproject.toml b/packages/plugins/minos-router-graphql/pyproject.toml index 0e3ba9242..e756b6550 100644 --- a/packages/plugins/minos-router-graphql/pyproject.toml +++ b/packages/plugins/minos-router-graphql/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-router-graphql" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The graphql plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/poetry.lock b/poetry.lock index 03561d4f8..3307b49c4 100644 --- a/poetry.lock +++ b/poetry.lock @@ -166,11 +166,11 @@ tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (> [[package]] name = "babel" -version = "2.9.1" +version = "2.10.1" description = "Internationalization utilities" category = "dev" optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" +python-versions = ">=3.6" [package.dependencies] pytz = ">=2015.7" @@ -364,6 +364,14 @@ category = "main" optional = false python-versions = ">=3.7" +[[package]] +name = "graphql-core" +version = "3.2.1" +description = "GraphQL implementation for Python, a port of GraphQL.js, the JavaScript reference implementation for GraphQL." +category = "main" +optional = false +python-versions = ">=3.6,<4" + [[package]] name = "h11" version = "0.12.0" @@ -539,7 +547,7 @@ python-versions = "*" [[package]] name = "minos-broker-kafka" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The kafka plugin of the Minos Framework" category = "main" optional = false @@ -559,7 +567,7 @@ url = "packages/plugins/minos-broker-kafka" [[package]] name = "minos-broker-rabbitmq" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The rabbitmq plugin of the Minos Framework" category = "main" optional = false @@ -577,7 +585,7 @@ url = "packages/plugins/minos-broker-rabbitmq" [[package]] name = "minos-database-aiopg" -version = "0.0.0" +version = "0.7.0.dev2" description = "The aiopg plugin of the Minos Framework" category = "main" optional = false @@ -595,9 +603,27 @@ psycopg2-binary = "^2.9.3" type = "directory" url = "packages/plugins/minos-database-aiopg" +[[package]] +name = "minos-database-lmdb" +version = "0.7.0.dev2" +description = "The lmdb plugin of the Minos Framework" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +lmdb = "^1.2.1" +minos-microservice-common = "^0.7.0*" +minos-microservice-saga = "^0.7.0*" + +[package.source] +type = "directory" +url = "packages/plugins/minos-database-lmdb" + [[package]] name = "minos-discovery-kong" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" category = "main" optional = false @@ -608,6 +634,8 @@ develop = true httpx = "^0.22.0" minos-microservice-common = "^0.7.0*" minos-microservice-networks = "^0.7.0*" +PyJWT = "^2.3.0" +pytz = "^2022.1" [package.source] type = "directory" @@ -653,7 +681,7 @@ url = "packages/plugins/minos-http-aiohttp" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -671,7 +699,7 @@ url = "packages/core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The common core of the Minos Framework" category = "main" optional = false @@ -683,7 +711,6 @@ aiomisc = ">=14.0.3,<15.8.0" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -694,7 +721,7 @@ url = "packages/core/minos-microservice-common" [[package]] name = "minos-microservice-cqrs" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The CQRS pattern of the Minos Framework" category = "main" optional = false @@ -712,7 +739,7 @@ url = "packages/core/minos-microservice-cqrs" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -729,7 +756,7 @@ url = "packages/core/minos-microservice-networks" [[package]] name = "minos-microservice-saga" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "The SAGA pattern of the Minos Framework" category = "main" optional = false @@ -746,6 +773,24 @@ minos-microservice-networks = "^0.7.0*" type = "directory" url = "packages/core/minos-microservice-saga" +[[package]] +name = "minos-router-graphql" +version = "0.7.0.dev2" +description = "The graphql plugin of the Minos Framework" +category = "main" +optional = false +python-versions = "^3.9" +develop = true + +[package.dependencies] +graphql-core = "^3.2.0" +minos-microservice-common = "^0.7.0*" +minos-microservice-networks = "^0.7.0*" + +[package.source] +type = "directory" +url = "packages/plugins/minos-router-graphql" + [[package]] name = "mistune" version = "0.8.4" @@ -905,6 +950,20 @@ category = "dev" optional = false python-versions = ">=3.5" +[[package]] +name = "pyjwt" +version = "2.3.0" +description = "JSON Web Token implementation in Python" +category = "main" +optional = false +python-versions = ">=3.6" + +[package.extras] +crypto = ["cryptography (>=3.3.1)"] +dev = ["sphinx", "sphinx-rtd-theme", "zope.interface", "cryptography (>=3.3.1)", "pytest (>=6.0.0,<7.0.0)", "coverage[toml] (==5.0.4)", "mypy", "pre-commit"] +docs = ["sphinx", "sphinx-rtd-theme", "zope.interface"] +tests = ["pytest (>=6.0.0,<7.0.0)", "coverage[toml] (==5.0.4)"] + [[package]] name = "pyparsing" version = "3.0.8" @@ -941,7 +1000,7 @@ testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2. name = "pytz" version = "2022.1" description = "World timezone definitions, modern and historical" -category = "dev" +category = "main" optional = false python-versions = "*" @@ -1249,7 +1308,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "e1e3295c405de56c506d6a0365be96f8b7b282f16589522940c7a2a50dee7690" +content-hash = "641d9f3d1d942481fc82f0d8ea83e8d8b7d24831330c2589e9b14a163b5728cd" [metadata.files] aio-pika = [ @@ -1390,8 +1449,8 @@ attrs = [ {file = "attrs-21.4.0.tar.gz", hash = "sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"}, ] babel = [ - {file = "Babel-2.9.1-py2.py3-none-any.whl", hash = "sha256:ab49e12b91d937cd11f0b67cb259a57ab4ad2b59ac7a3b41d6c06c0ac5b0def9"}, - {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, + {file = "Babel-2.10.1-py3-none-any.whl", hash = "sha256:3f349e85ad3154559ac4930c3918247d319f21910d5ce4b25d439ed8693b98d2"}, + {file = "Babel-2.10.1.tar.gz", hash = "sha256:98aeaca086133efb3e1e2aad0396987490c8425929ddbcfe0550184fdc54cd13"}, ] black = [ {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, @@ -1625,6 +1684,10 @@ frozenlist = [ {file = "frozenlist-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:772965f773757a6026dea111a15e6e2678fbd6216180f82a48a40b27de1ee2ab"}, {file = "frozenlist-1.3.0.tar.gz", hash = "sha256:ce6f2ba0edb7b0c1d8976565298ad2deba6f8064d2bebb6ffce2ca896eb35b0b"}, ] +graphql-core = [ + {file = "graphql-core-3.2.1.tar.gz", hash = "sha256:9d1bf141427b7d54be944587c8349df791ce60ade2e3cccaf9c56368c133c201"}, + {file = "graphql_core-3.2.1-py3-none-any.whl", hash = "sha256:f83c658e4968998eed1923a2e3e3eddd347e005ac0315fbb7ca4d70ea9156323"}, +] h11 = [ {file = "h11-0.12.0-py3-none-any.whl", hash = "sha256:36a3cb8c0a032f56e2da7084577878a035d3b61d104230d4bd49c0c6b555a9c6"}, {file = "h11-0.12.0.tar.gz", hash = "sha256:47222cb6067e4a307d535814917cd98fd0a57b6788ce715755fa2b6c28b56042"}, @@ -1751,6 +1814,7 @@ mccabe = [ minos-broker-kafka = [] minos-broker-rabbitmq = [] minos-database-aiopg = [] +minos-database-lmdb = [] minos-discovery-kong = [] minos-discovery-minos = [] minos-http-aiohttp = [] @@ -1759,6 +1823,7 @@ minos-microservice-common = [] minos-microservice-cqrs = [] minos-microservice-networks = [] minos-microservice-saga = [] +minos-router-graphql = [] mistune = [ {file = "mistune-0.8.4-py2.py3-none-any.whl", hash = "sha256:88a1051873018da288eee8538d476dffe1262495144b33ecb586c4ab266bb8d4"}, {file = "mistune-0.8.4.tar.gz", hash = "sha256:59a3429db53c50b5c6bcc8a07f8848cb00d7dc8bdb431a4ab41920d201d4756e"}, @@ -1967,6 +2032,10 @@ pygments = [ {file = "Pygments-2.11.2-py3-none-any.whl", hash = "sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65"}, {file = "Pygments-2.11.2.tar.gz", hash = "sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a"}, ] +pyjwt = [ + {file = "PyJWT-2.3.0-py3-none-any.whl", hash = "sha256:e0c4bb8d9f0af0c7f5b1ec4c5036309617d03d56932877f2f7a0beeb5318322f"}, + {file = "PyJWT-2.3.0.tar.gz", hash = "sha256:b888b4d56f06f6dcd777210c334e69c737be74755d3e5e9ee3fe67dc18a0ee41"}, +] pyparsing = [ {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, diff --git a/pyproject.toml b/pyproject.toml index a4437c649..2a7f7ef87 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-python" -version = "0.7.0.dev1" +version = "0.7.0.dev2" description = "" authors = ["Minos Framework Devs "] license = "MIT" @@ -13,11 +13,13 @@ minos-microservice-aggregate = { path = "packages/core/minos-microservice-aggreg minos-microservice-saga = { path = "packages/core/minos-microservice-saga", develop = true } minos-microservice-cqrs = { path = "packages/core/minos-microservice-cqrs", develop = true } minos-broker-kafka = { path = "packages/plugins/minos-broker-kafka", develop = true } +minos-broker-rabbitmq = { path = "packages/plugins/minos-broker-rabbitmq", develop = true } minos-database-aiopg = { path = "packages/plugins/minos-database-aiopg", develop = true } +minos-database-lmdb = { path = "packages/plugins/minos-database-lmdb", develop = true } minos-discovery-minos = { path = "packages/plugins/minos-discovery-minos", develop = true } minos-discovery-kong = { path = "packages/plugins/minos-discovery-kong", develop = true } -minos-broker-rabbitmq = { path = "packages/plugins/minos-broker-rabbitmq", develop = true } minos-http-aiohttp = { path = "packages/plugins/minos-http-aiohttp", develop = true } +minos-router-graphql = { path = "packages/plugins/minos-router-graphql", develop = true } [tool.poetry.dev-dependencies] black = "^22.3" From d30ed3c7585e4103c6143e7e09e8063032d38ad5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 21 Apr 2022 18:54:52 +0200 Subject: [PATCH 294/324] ISSUE #? * Update docstring. --- .../plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py | 2 ++ .../plugins/minos-discovery-kong/minos/plugins/kong/__init__.py | 2 ++ .../minos-router-graphql/minos/plugins/graphql/handlers.py | 2 ++ 3 files changed, 6 insertions(+) diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py index 851457a34..91b116f4b 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/clients.py @@ -1,3 +1,5 @@ +"""This module contains the implementation of the lmdb client.""" + from __future__ import ( annotations, ) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index 7d6888d9d..6dc56767d 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -1,3 +1,5 @@ +"""The kong plugin of the Minos Framework.""" + __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" __version__ = "0.7.0.dev2" diff --git a/packages/plugins/minos-router-graphql/minos/plugins/graphql/handlers.py b/packages/plugins/minos-router-graphql/minos/plugins/graphql/handlers.py index cee09f688..27dc9e76d 100644 --- a/packages/plugins/minos-router-graphql/minos/plugins/graphql/handlers.py +++ b/packages/plugins/minos-router-graphql/minos/plugins/graphql/handlers.py @@ -1,3 +1,5 @@ +"""This module contains the implementation of the graphql handler.""" + import logging import traceback from typing import ( From e8a39f1b1cc78dceac0467b6bfcd0a5432450528 Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Sat, 23 Apr 2022 22:10:10 +0200 Subject: [PATCH 295/324] modified history --- packages/plugins/minos-discovery-kong/HISTORY.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/HISTORY.md b/packages/plugins/minos-discovery-kong/HISTORY.md index 0dfc78464..0e12b8de9 100644 --- a/packages/plugins/minos-discovery-kong/HISTORY.md +++ b/packages/plugins/minos-discovery-kong/HISTORY.md @@ -1,5 +1,5 @@ # History -## 0.1.0a0 (2022-03-31) +## 0.1.0a1 (2022-03-31) * First Alpha release From 1b302a0615081b504d1533af175a363454e9c02f Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Sat, 23 Apr 2022 22:23:23 +0200 Subject: [PATCH 296/324] added dev3 for kong --- .../plugins/minos-discovery-kong/minos/plugins/kong/client.py | 3 ++- packages/plugins/minos-discovery-kong/pyproject.toml | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index 4c3be03f3..dd3baffc6 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -42,10 +42,11 @@ def _from_config(cls, config: Config, **kwargs) -> KongClient: discovery_config = config.get_discovery() token_expiration_sec = discovery_config.get("token-exp") + protocol = discovery_config.get("protocol") host = discovery_config.get("host") port = discovery_config.get("port") - return cls(host=host, port=port, token_expiration_sec=token_expiration_sec, **kwargs) + return cls(protocol=protocol, host=host, port=port, token_expiration_sec=token_expiration_sec, **kwargs) @staticmethod async def register_service( diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index dd4a45e56..62f267657 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-kong" -version = "0.7.0.dev2" +version = "0.7.0.dev3" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" From 2bc5f6641bb1593cf078f0a4d11a034183502e3e Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Sat, 23 Apr 2022 22:24:40 +0200 Subject: [PATCH 297/324] Update __init__.py --- .../plugins/minos-discovery-kong/minos/plugins/kong/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index 6dc56767d..7f445b65e 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev3" from .client import ( KongClient, From 573d26c06f6e2250575db247bb7e6f498d0b740a Mon Sep 17 00:00:00 2001 From: Andrea Mucci Date: Sat, 23 Apr 2022 22:30:57 +0200 Subject: [PATCH 298/324] correct error --- .../plugins/minos-discovery-kong/minos/plugins/kong/client.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py index dd3baffc6..af99ad784 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/client.py @@ -24,13 +24,15 @@ class KongClient(SetupMixin): """Kong Client class.""" def __init__( - self, protocol: str = "http", host: str = None, port: int = None, token_expiration_sec: int = None, **kwargs + self, protocol: str = None, host: str = None, port: int = None, token_expiration_sec: int = None, **kwargs ): super().__init__(**kwargs) if host is None: host = "localhost" if port is None: port = 8001 + if protocol is None: + protocol = "http" if token_expiration_sec is None: token_expiration_sec = 60 * 5 From c93022680bfb0472ab67bea5f06643f46e5efcf3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:15:47 +0000 Subject: [PATCH 299/324] Bump black in /packages/core/minos-microservice-aggregate Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../minos-microservice-aggregate/poetry.lock | 54 +++++++++---------- .../pyproject.toml | 2 +- 2 files changed, 28 insertions(+), 28 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/poetry.lock b/packages/core/minos-microservice-aggregate/poetry.lock index 16f003c05..1d96106ab 100644 --- a/packages/core/minos-microservice-aggregate/poetry.lock +++ b/packages/core/minos-microservice-aggregate/poetry.lock @@ -85,7 +85,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +96,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -381,7 +381,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -871,7 +871,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "7371da2d5d13ab97d2bd9539bab6c57260134ac0a0859728f2f9a685323002ad" +content-hash = "595b8281b98245ff9fbf794b8aeb92a9ff554d5af9aede9642fcd51485952dc7" [metadata.files] aiomisc = [ @@ -903,29 +903,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index bc41cf257..bd10fb0b8 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -39,7 +39,7 @@ psycopg2-binary = "^2.9.3" [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../minos-microservice-common", develop = true } minos-microservice-networks = { path = "../minos-microservice-networks", develop = true } -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From 5fc897c407748c9380a50acab3a9e6c58d94a7c9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:16:46 +0000 Subject: [PATCH 300/324] Bump pytest in /packages/core/minos-microservice-cqrs Bumps [pytest](https://github.com/pytest-dev/pytest) from 7.1.1 to 7.1.2. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/7.1.1...7.1.2) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/core/minos-microservice-cqrs/poetry.lock | 10 +++++----- packages/core/minos-microservice-cqrs/pyproject.toml | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/core/minos-microservice-cqrs/poetry.lock b/packages/core/minos-microservice-cqrs/poetry.lock index 270a6d262..e80be3635 100644 --- a/packages/core/minos-microservice-cqrs/poetry.lock +++ b/packages/core/minos-microservice-cqrs/poetry.lock @@ -400,7 +400,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -593,7 +593,7 @@ diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pytest" -version = "7.1.1" +version = "7.1.2" description = "pytest: simple powerful testing with Python" category = "dev" optional = false @@ -890,7 +890,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "23501a6766a4dd4ee55a8b51c4860646b8408e31948d63ad9517a99f1b6d4894" +content-hash = "3564938420ef9ede101647390155abab59a84a801e49eb701b40bfa5932171d3" [metadata.files] aiomisc = [ @@ -1351,8 +1351,8 @@ pyparsing = [ {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, ] pytest = [ - {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, - {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, + {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, + {file = "pytest-7.1.2.tar.gz", hash = "sha256:a06a0425453864a270bc45e71f783330a7428defb4230fb5e6a731fde06ecd45"}, ] pytz = [ {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index 29c04e203..462775e0f 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -41,7 +41,7 @@ minos-microservice-networks = { path = "../minos-microservice-networks", develop minos-microservice-aggregate = { path = "../minos-microservice-aggregate", develop = true } black = "^22.1" isort = "^5.8.0" -pytest = "^7.0.1" +pytest = "^7.1.2" coverage = "^6.3" flake8 = "^4.0.1" Sphinx = "^4.0.1" From 32fb57d18d878538b54de9cd18ce51395c423cc3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:17:07 +0000 Subject: [PATCH 301/324] Bump pytest in /packages/core/minos-microservice-aggregate Bumps [pytest](https://github.com/pytest-dev/pytest) from 7.1.1 to 7.1.2. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/7.1.1...7.1.2) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/core/minos-microservice-aggregate/poetry.lock | 10 +++++----- .../core/minos-microservice-aggregate/pyproject.toml | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/poetry.lock b/packages/core/minos-microservice-aggregate/poetry.lock index 16f003c05..d53a62d0a 100644 --- a/packages/core/minos-microservice-aggregate/poetry.lock +++ b/packages/core/minos-microservice-aggregate/poetry.lock @@ -381,7 +381,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -574,7 +574,7 @@ diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pytest" -version = "7.1.1" +version = "7.1.2" description = "pytest: simple powerful testing with Python" category = "dev" optional = false @@ -871,7 +871,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "7371da2d5d13ab97d2bd9539bab6c57260134ac0a0859728f2f9a685323002ad" +content-hash = "c621c7102ecfaf5fd3c41e0bcc98af5a5da5619a568d29bc98c9dec28b084e3a" [metadata.files] aiomisc = [ @@ -1331,8 +1331,8 @@ pyparsing = [ {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, ] pytest = [ - {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, - {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, + {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, + {file = "pytest-7.1.2.tar.gz", hash = "sha256:a06a0425453864a270bc45e71f783330a7428defb4230fb5e6a731fde06ecd45"}, ] pytz = [ {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index bc41cf257..79e08e57c 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -41,7 +41,7 @@ minos-microservice-common = { path = "../minos-microservice-common", develop = t minos-microservice-networks = { path = "../minos-microservice-networks", develop = true } black = "^22.1" isort = "^5.8.0" -pytest = "^7.0.1" +pytest = "^7.1.2" coverage = "^6.3" flake8 = "^4.0.1" Sphinx = "^4.0.1" From b6b5d235c40412d9c5a7a2cb3b3f3dba5c2659cc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:17:33 +0000 Subject: [PATCH 302/324] Bump black in /packages/core/minos-microservice-cqrs Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../core/minos-microservice-cqrs/poetry.lock | 54 +++++++++---------- .../minos-microservice-cqrs/pyproject.toml | 2 +- 2 files changed, 28 insertions(+), 28 deletions(-) diff --git a/packages/core/minos-microservice-cqrs/poetry.lock b/packages/core/minos-microservice-cqrs/poetry.lock index 270a6d262..dd9f41022 100644 --- a/packages/core/minos-microservice-cqrs/poetry.lock +++ b/packages/core/minos-microservice-cqrs/poetry.lock @@ -85,7 +85,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +96,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -400,7 +400,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -890,7 +890,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "23501a6766a4dd4ee55a8b51c4860646b8408e31948d63ad9517a99f1b6d4894" +content-hash = "b54e7783b6e7f94388d141829c72e622d6b77191bdde3df6acb53d9f4b657f39" [metadata.files] aiomisc = [ @@ -922,29 +922,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index 29c04e203..970e00569 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -39,7 +39,7 @@ minos-microservice-networks = "^0.6.0" minos-microservice-common = { path = "../minos-microservice-common", develop = true } minos-microservice-networks = { path = "../minos-microservice-networks", develop = true } minos-microservice-aggregate = { path = "../minos-microservice-aggregate", develop = true } -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From e68a1a9dabee69548927694ca8b612207c92f8e1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:17:58 +0000 Subject: [PATCH 303/324] Bump black in /packages/core/minos-microservice-common Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../minos-microservice-common/poetry.lock | 52 +++++++++---------- .../minos-microservice-common/pyproject.toml | 2 +- 2 files changed, 27 insertions(+), 27 deletions(-) diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index 62682cf99..c6ca07a7a 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -85,7 +85,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +96,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -820,7 +820,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "fbf86feb57cef7a80f0568f8da50f945ebeb84d401d32fa5a3bde0bac05febda" +content-hash = "5753a21e12b21b9eec1a7188527e9f17ec7ff624b2796e1b8b413a8beed30948" [metadata.files] aiomisc = [ @@ -852,29 +852,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index d453cf3ef..be1855cf9 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -42,7 +42,7 @@ cached-property = "^1.5.2" uvloop = "^0.16.0" [tool.poetry.dev-dependencies] -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From a52fd0f138bb9090a2dea4250502654f35b2e92a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:18:17 +0000 Subject: [PATCH 304/324] Bump pytest in /packages/core/minos-microservice-saga Bumps [pytest](https://github.com/pytest-dev/pytest) from 7.1.1 to 7.1.2. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/7.1.1...7.1.2) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/core/minos-microservice-saga/poetry.lock | 10 +++++----- packages/core/minos-microservice-saga/pyproject.toml | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/core/minos-microservice-saga/poetry.lock b/packages/core/minos-microservice-saga/poetry.lock index 8cf474bb3..6110c42e4 100644 --- a/packages/core/minos-microservice-saga/poetry.lock +++ b/packages/core/minos-microservice-saga/poetry.lock @@ -400,7 +400,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -593,7 +593,7 @@ diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pytest" -version = "7.1.1" +version = "7.1.2" description = "pytest: simple powerful testing with Python" category = "dev" optional = false @@ -890,7 +890,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "f59b3c5c588ce969df14fed260965c6573d9ab3ba6e755966d45736cf3aeb3c7" +content-hash = "18d1b028140a9ec55909523f7cedee848eeee97a68fcefa661a0dfabf5aedad9" [metadata.files] aiomisc = [ @@ -1351,8 +1351,8 @@ pyparsing = [ {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, ] pytest = [ - {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, - {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, + {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, + {file = "pytest-7.1.2.tar.gz", hash = "sha256:a06a0425453864a270bc45e71f783330a7428defb4230fb5e6a731fde06ecd45"}, ] pytz = [ {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index d84cb5294..53da2b29d 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -42,7 +42,7 @@ minos-microservice-networks = { path = "../minos-microservice-networks", develop minos-microservice-aggregate = { path = "../minos-microservice-aggregate", develop = true } black = "^22.1" isort = "^5.8.0" -pytest = "^7.0.1" +pytest = "^7.1.2" coverage = "^6.3" flake8 = "^4.0.1" Sphinx = "^4.0.1" From 7f172cca0fd52f7a8c3303c9c37ba2eff0765b3b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:18:21 +0000 Subject: [PATCH 305/324] Bump black from 22.1.0 to 22.3.0 Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- poetry.lock | 56 +++++++++++++++++++++++++------------------------- pyproject.toml | 2 +- 2 files changed, 29 insertions(+), 29 deletions(-) diff --git a/poetry.lock b/poetry.lock index 6609ea7c0..58ddeeed8 100644 --- a/poetry.lock +++ b/poetry.lock @@ -160,7 +160,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -171,7 +171,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -475,7 +475,7 @@ python-versions = "*" [[package]] name = "minos-broker-kafka" -version = "0.6.0" +version = "0.6.1" description = "The kafka plugin of the Minos Framework" category = "main" optional = false @@ -570,7 +570,7 @@ url = "packages/core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -1129,7 +1129,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "30fddce08ca9aacf52b35da308a7eb6d6734425b5d5cdc9395d3734effd25e9d" +content-hash = "bd6051aedc0d148b6f175df19b88e2e1b666f807fdbc777d8541549512c17cfd" [metadata.files] aio-pika = [ @@ -1270,29 +1270,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/pyproject.toml b/pyproject.toml index afca500c3..7a174bda9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -18,7 +18,7 @@ minos-broker-rabbitmq = { path = "packages/plugins/minos-broker-rabbitmq", devel minos-http-aiohttp = { path = "packages/plugins/minos-http-aiohttp", develop = true } [tool.poetry.dev-dependencies] -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From eca00c892ab19662c3236dc8f8c6d4de4b99d9ba Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:18:29 +0000 Subject: [PATCH 306/324] Bump pytest in /packages/core/minos-microservice-networks Bumps [pytest](https://github.com/pytest-dev/pytest) from 7.1.1 to 7.1.2. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/7.1.1...7.1.2) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/core/minos-microservice-networks/poetry.lock | 10 +++++----- .../core/minos-microservice-networks/pyproject.toml | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/core/minos-microservice-networks/poetry.lock b/packages/core/minos-microservice-networks/poetry.lock index b0100b80f..2c724ad2c 100644 --- a/packages/core/minos-microservice-networks/poetry.lock +++ b/packages/core/minos-microservice-networks/poetry.lock @@ -381,7 +381,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -555,7 +555,7 @@ diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pytest" -version = "7.1.1" +version = "7.1.2" description = "pytest: simple powerful testing with Python" category = "dev" optional = false @@ -852,7 +852,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "ea88425476960ab086eadc6616f36d6cbdc2e2e92e95c4a1cd2f5a4ae7907738" +content-hash = "8c6bf58ce9d4d2349dccac0d7819cbccc16228173e667cc04ae75e9c720f49d1" [metadata.files] aiomisc = [ @@ -1311,8 +1311,8 @@ pyparsing = [ {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, ] pytest = [ - {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, - {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, + {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, + {file = "pytest-7.1.2.tar.gz", hash = "sha256:a06a0425453864a270bc45e71f783330a7428defb4230fb5e6a731fde06ecd45"}, ] pytz = [ {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index 0b59df1d1..5276ded50 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -40,7 +40,7 @@ psycopg2-binary = "^2.9.3" minos-microservice-common = { path = "../minos-microservice-common", develop = true } black = "^22.1" isort = "^5.8.0" -pytest = "^7.0.1" +pytest = "^7.1.2" coverage = "^6.3" flake8 = "^4.0.1" Sphinx = "^4.0.1" From 54f2e2b31c6591d864a9dae0dc2a31c147428a17 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:19:08 +0000 Subject: [PATCH 307/324] Bump pytest from 7.1.1 to 7.1.2 Bumps [pytest](https://github.com/pytest-dev/pytest) from 7.1.1 to 7.1.2. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/7.1.1...7.1.2) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- poetry.lock | 12 ++++++------ pyproject.toml | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/poetry.lock b/poetry.lock index 6609ea7c0..8fd1f7bd1 100644 --- a/poetry.lock +++ b/poetry.lock @@ -475,7 +475,7 @@ python-versions = "*" [[package]] name = "minos-broker-kafka" -version = "0.6.0" +version = "0.6.1" description = "The kafka plugin of the Minos Framework" category = "main" optional = false @@ -570,7 +570,7 @@ url = "packages/core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -820,7 +820,7 @@ diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pytest" -version = "7.1.1" +version = "7.1.2" description = "pytest: simple powerful testing with Python" category = "dev" optional = false @@ -1129,7 +1129,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "30fddce08ca9aacf52b35da308a7eb6d6734425b5d5cdc9395d3734effd25e9d" +content-hash = "c61300b0b1c3e36c0d0c85027aff9a7be077e4ff1100686607dca6804459cfb5" [metadata.files] aio-pika = [ @@ -1834,8 +1834,8 @@ pyparsing = [ {file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"}, ] pytest = [ - {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, - {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, + {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, + {file = "pytest-7.1.2.tar.gz", hash = "sha256:a06a0425453864a270bc45e71f783330a7428defb4230fb5e6a731fde06ecd45"}, ] pytz = [ {file = "pytz-2022.1-py2.py3-none-any.whl", hash = "sha256:e68985985296d9a66a881eb3193b0906246245294a881e7c8afe623866ac6a5c"}, diff --git a/pyproject.toml b/pyproject.toml index afca500c3..08a4e2aa1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -20,7 +20,7 @@ minos-http-aiohttp = { path = "packages/plugins/minos-http-aiohttp", develop = t [tool.poetry.dev-dependencies] black = "^22.1" isort = "^5.8.0" -pytest = "^7.0.1" +pytest = "^7.1.2" coverage = "^6.3" flake8 = "^4.0.1" Sphinx = "^4.0.1" From ac0d8a1f3354e3e6ced428324f45238a49e8868f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:19:24 +0000 Subject: [PATCH 308/324] Bump black in /packages/core/minos-microservice-networks Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../minos-microservice-networks/poetry.lock | 54 +++++++++---------- .../pyproject.toml | 2 +- 2 files changed, 28 insertions(+), 28 deletions(-) diff --git a/packages/core/minos-microservice-networks/poetry.lock b/packages/core/minos-microservice-networks/poetry.lock index b0100b80f..1bcc152c0 100644 --- a/packages/core/minos-microservice-networks/poetry.lock +++ b/packages/core/minos-microservice-networks/poetry.lock @@ -85,7 +85,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +96,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -381,7 +381,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -852,7 +852,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "ea88425476960ab086eadc6616f36d6cbdc2e2e92e95c4a1cd2f5a4ae7907738" +content-hash = "d5f8ad9c8522f5daf4ab000f252e1c0d0dd602adbb8f1976760afb2ed1322def" [metadata.files] aiomisc = [ @@ -884,29 +884,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index 0b59df1d1..a7350c019 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -38,7 +38,7 @@ psycopg2-binary = "^2.9.3" [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../minos-microservice-common", develop = true } -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From 6f74a49003a8c17c310193189546dea75d75a971 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:19:38 +0000 Subject: [PATCH 309/324] Bump dependency-injector in /packages/core/minos-microservice-common Bumps [dependency-injector](https://github.com/ets-labs/python-dependency-injector) from 4.39.0 to 4.39.1. - [Release notes](https://github.com/ets-labs/python-dependency-injector/releases) - [Commits](https://github.com/ets-labs/python-dependency-injector/compare/4.39.0...4.39.1) --- updated-dependencies: - dependency-name: dependency-injector dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- .../minos-microservice-common/poetry.lock | 74 +++++++++---------- 1 file changed, 37 insertions(+), 37 deletions(-) diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index 62682cf99..871f322f0 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -186,7 +186,7 @@ toml = ["tomli"] [[package]] name = "dependency-injector" -version = "4.39.0" +version = "4.39.1" description = "Dependency injection framework for Python" category = "main" optional = false @@ -948,42 +948,42 @@ coverage = [ {file = "coverage-6.3.2.tar.gz", hash = "sha256:03e2a7826086b91ef345ff18742ee9fc47a6839ccd517061ef8fa1976e652ce9"}, ] dependency-injector = [ - {file = "dependency-injector-4.39.0.tar.gz", hash = "sha256:35d6c03683f512bcc8b0c950890ac40ce19bdacc7de4d59249dd61ed818f0930"}, - {file = "dependency_injector-4.39.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f046a5dbe7e5764fae9a69423f66241a8fdb62acea5c32b0c41a7da94b7f6da3"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dfdd78f7d97c1f6ba4a3926a2e404507a4f77ecbd610d4a1b37dedb5c0b57ad1"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:512c23da829bb8ac2ae13f33aa017acf58ae9408e7796a146e1644e8b8471b5b"}, - {file = "dependency_injector-4.39.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:7dc81df7f566bfdacdee448bc71085acd163b935860d2b2504b4f32840b3b692"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win32.whl", hash = "sha256:9ffc5393700f45d740abecc50cdc1251eae69e50516ec9d0a48fba0e875ed083"}, - {file = "dependency_injector-4.39.0-cp310-cp310-win_amd64.whl", hash = "sha256:9118f36a3df1e9819074ccb35734d663812c8f6ef81d45c8e4ec81ce5dccac9c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:1ff723aaf096fabb05cf8b08ba99888538a2a77e03a5082b70cd54eb9df619f3"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7bb913900ceb1766f55dc628052d8e191a9c2b1737a0d775fbc230af90ab2c1e"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:329e801eb46b9933432481d3142e563e28a90d77952edac43126264c36ed2278"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:1c1a67c699ae2c0234f07d121736fa44e8fe2d56c14b2fd210c3e04a151620bb"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win32.whl", hash = "sha256:e1347defd46fe9067f857b1174bdb1b19458232ac1a485507df2ddff084cf31c"}, - {file = "dependency_injector-4.39.0-cp36-cp36m-win_amd64.whl", hash = "sha256:9581c4c90f1aaf85ffb9b06bac7ac592df7076522881145321a9dd0702fee828"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8da8ff05fa17e852aa5831a600177e5bb72bf53b8a184f6922ae715387a460ba"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:58a56999cebd8b2ba9c19e514e383924865e5f7d6273f8e5b7d85468d9042059"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:4914332d6145fb7cfc5f2236a823a3859b92a7e75566ffca0987dcc0f7f7be53"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:00aea40ee2d400a8091947ad97cda34b230628aeeac1774f8fa9a3500b5704b2"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win32.whl", hash = "sha256:b94a64bc73d86d04b33c698fae4b9dad2536a8534ac6922c8226764da5d62d17"}, - {file = "dependency_injector-4.39.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4f59cc0b0d3beb82875d94b7e725b5097a7a454e8e323625ba6ac3095a29300e"}, - {file = "dependency_injector-4.39.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:7a8d840348f01d997e32394dba36e09c1ecd312b286befb6b3ca27526002ae94"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:92097ffabca89d1539e200f91bfa13ff8ca502c9057391c3b78787d50fe502ed"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:0d4a889e116fe76742ef6ff27d5e93ee9e364cbe7bbc6678df8c5dd54597a6fc"}, - {file = "dependency_injector-4.39.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a31e00961fdc1b3808a9e2adeb1107ec4bba0ad3a90b116af9d116a667e4626a"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win32.whl", hash = "sha256:717720a220eee611ea96c0089246ec2103b168303ca2cd2c8a7cd3856da6f689"}, - {file = "dependency_injector-4.39.0-cp38-cp38-win_amd64.whl", hash = "sha256:05c0bbef90182a0d35d4d3f9ab879109070d204394578b12f0eff9eca51987ef"}, - {file = "dependency_injector-4.39.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:f10bf8d146edffbee2ba5c5776395625c98048a31997afd481ce27792afee2af"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:30c093b155c01e50723e8ecd2a14230daa4417356c8fb5a27369ae5be24b21d9"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dda8a85c8221e6ee433caa01c1bc4fed610381924780e04470572682569cdb8f"}, - {file = "dependency_injector-4.39.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ff8df47a901218a3257650f3f3a6b402dd58cb4f57b4a34d6e8092112f6e8480"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win32.whl", hash = "sha256:e078c84c19ae73883a57e9b35edd843925b2b44833cd098708139a98abee5a96"}, - {file = "dependency_injector-4.39.0-cp39-cp39-win_amd64.whl", hash = "sha256:c02b6796320d6b9363d566045eeec243fa4a412ad68dcc6b2391307e93d0d401"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:865bf5ceba3e32f00e36bfcbefb1267b10df961fb2aab809f5e205968e1cd59b"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3ce8645ffd8cc15a7bbd20c02e6439a61c1566a1db22766893bf79981fb89a4e"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:dbdab8b024055865926a78ecbc3a6280345f4615e5c505511bbd7c6c322b1796"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:af996d66350704261382dc4e10f324eba5d23e35c04a9e75c7cb58fbea7f1f1d"}, - {file = "dependency_injector-4.39.0-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:d390c6e97fec13fba832b7e39e07c43760ed3d46af4887005f679c0ab6eb9b2e"}, + {file = "dependency-injector-4.39.1.tar.gz", hash = "sha256:9ab76dc5e19b2692aaca49e00f9b41a087138d139b0ec985f92ff0498f038772"}, + {file = "dependency_injector-4.39.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c788a3d5482e63b5fd55e14fc258f1ff0b51b411927ab132ef0f689cb5d1183f"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d0832e0457a360725cd1d1037b77b85478aeeaacc60e85ecceeb8020409e7b62"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:d51998fff9704fd01d11c3c48f4e88d8506cb6afa1ee41409a881a5a51dae3fc"}, + {file = "dependency_injector-4.39.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ea484cd13fc62966bf5582df0816205feee072d18f228aac75f7807b43f223ae"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win32.whl", hash = "sha256:17389e53ec29ca13570319cf2065dcc4c2f6d36db5dd792bb1e8f2c39a9f146b"}, + {file = "dependency_injector-4.39.1-cp310-cp310-win_amd64.whl", hash = "sha256:55b0988489267c5a580f419133770ffe293057f2064da1c9ad6a2cc69666739b"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b297c3e79d3633cc56366386ae1f7dbce1587673cca2f559c368c1e936a1fa94"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2728827c5abb2420c5811e218262ae1b77a48e76cc9eebc6b4f55fee48a1a18d"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:029e42b064ab8cb5b2559be040ff682c7aa81592f1654a82355475956df17803"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:305e3db3f4bf40f64caaa1303e03005174e78d2339d2ae517b34c011ec2300f9"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win32.whl", hash = "sha256:a661dd23a5e4e2f6bf4a729de7fadbe148c9a4a298dbcadfc5a94584b6930970"}, + {file = "dependency_injector-4.39.1-cp36-cp36m-win_amd64.whl", hash = "sha256:340d6e7af5c4729d20c837d6d1e8a2626c24a05259dff746406cc823e26ba1e7"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a1553dac1c95f0de1f910b0025ee4570ea078a07d576bcdc2168990e719cea50"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c7baaa64d93359ee08c15d68579cc803e11d9becaf961f5a66b94ff627248e1"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:7a27bf1951a066cf347b886cc7ab0f37dcbd1ad59bffcfe721c8c12a189a150d"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:da6e2d685f7d0c65257f08133b68d9bf74ec319b90a0f21b4f629d168ce5f68f"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win32.whl", hash = "sha256:a8ddd03ca86e67e9d3cc038793d34fbfccab12e6145df813e72bf14f9371f2ea"}, + {file = "dependency_injector-4.39.1-cp37-cp37m-win_amd64.whl", hash = "sha256:e01a319ea05cd86b520201386dcb53a81a5400cb82fcc2f006bd7e92c0c51a0a"}, + {file = "dependency_injector-4.39.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:4704804bde25b694aa65201927937a9d82d8bc055cb3dadc68eb05988bd34fa9"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0935d50b263169e7b0826a2fb6be80d6a4f2a7c59e6dd9876f86da3243bea9eb"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:3c34aa5abb1826b6189f47daf6e469d4293c1d01693233da2c1b923816270cc5"}, + {file = "dependency_injector-4.39.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:db64904c9b9a88756cfece3e3ed078a2b57127642711dd08af342dba8abf9667"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win32.whl", hash = "sha256:66ebe728194adc8720dbc4d662edbbfa55659ff23c9c493fb2dae0bfd4df5734"}, + {file = "dependency_injector-4.39.1-cp38-cp38-win_amd64.whl", hash = "sha256:4349974620f630d6726808e1291ec99713b64d449b84eb01581ee807a5a5c224"}, + {file = "dependency_injector-4.39.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:d87cad0899b05cd08931bfb68ddf7be77711a67b0649c37f2045d7808977b082"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8efd965e5cfdd9f339ec895e73c119569851adedc175088d34a670f5206fea63"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:27f69485ca6b85c31d162ee86cf6ef71bb71dce9cd2b5d0745425dfc551eefa1"}, + {file = "dependency_injector-4.39.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:a25b63de59dff04ec78f5161f00c0222a04a23def5d1f0eda14e389a32baf428"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win32.whl", hash = "sha256:a14274f50d125b4579314c355e22af07def1a96641ca94bd75edcf1400b89477"}, + {file = "dependency_injector-4.39.1-cp39-cp39-win_amd64.whl", hash = "sha256:9950039d00625f9252cd26378a4406342b256886bb61e4db8b65e9f01270f53e"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:6d7f39cd54678741e132e13da3a1367ac18058cbda61fe39d61c8583aa6fd757"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2368c7ba3c9ffaf816ea0f2d14c78d481491b805f62ac8496a78a51397d4689"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:84e32407bb16c58aa0d4b5ed8485537bc66ccc14cfffae7022f1204e35ec939a"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f2d80a42c546e1f934d427b071630d86653cd4a60c74b570c4ffb03025c1f1f9"}, + {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] distlib = [ {file = "distlib-0.3.4-py2.py3-none-any.whl", hash = "sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b"}, From 6889c89beef42df2fe9b762cb6332e0fa06bd32c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:19:52 +0000 Subject: [PATCH 310/324] Bump pre-commit from 2.17.0 to 2.18.1 Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 2.17.0 to 2.18.1. - [Release notes](https://github.com/pre-commit/pre-commit/releases) - [Changelog](https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md) - [Commits](https://github.com/pre-commit/pre-commit/compare/v2.17.0...v2.18.1) --- updated-dependencies: - dependency-name: pre-commit dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- poetry.lock | 14 +++++++------- pyproject.toml | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/poetry.lock b/poetry.lock index 6609ea7c0..eab6a934e 100644 --- a/poetry.lock +++ b/poetry.lock @@ -475,7 +475,7 @@ python-versions = "*" [[package]] name = "minos-broker-kafka" -version = "0.6.0" +version = "0.6.1" description = "The kafka plugin of the Minos Framework" category = "main" optional = false @@ -570,7 +570,7 @@ url = "packages/core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -753,11 +753,11 @@ testing = ["pytest", "pytest-benchmark"] [[package]] name = "pre-commit" -version = "2.17.0" +version = "2.18.1" description = "A framework for managing and maintaining multi-language pre-commit hooks." category = "dev" optional = false -python-versions = ">=3.6.1" +python-versions = ">=3.7" [package.dependencies] cfgv = ">=2.0.0" @@ -1129,7 +1129,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "30fddce08ca9aacf52b35da308a7eb6d6734425b5d5cdc9395d3734effd25e9d" +content-hash = "13059ad4c86631a866af52ba05574ac981214cd6f196a4da968d8baacd554b6d" [metadata.files] aio-pika = [ @@ -1752,8 +1752,8 @@ pluggy = [ {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] pre-commit = [ - {file = "pre_commit-2.17.0-py2.py3-none-any.whl", hash = "sha256:725fa7459782d7bec5ead072810e47351de01709be838c2ce1726b9591dad616"}, - {file = "pre_commit-2.17.0.tar.gz", hash = "sha256:c1a8040ff15ad3d648c70cc3e55b93e4d2d5b687320955505587fd79bbaed06a"}, + {file = "pre_commit-2.18.1-py2.py3-none-any.whl", hash = "sha256:02226e69564ebca1a070bd1f046af866aa1c318dbc430027c50ab832ed2b73f2"}, + {file = "pre_commit-2.18.1.tar.gz", hash = "sha256:5d445ee1fa8738d506881c5d84f83c62bb5be6b2838e32207433647e8e5ebe10"}, ] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, diff --git a/pyproject.toml b/pyproject.toml index afca500c3..d148270c0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -24,7 +24,7 @@ pytest = "^7.0.1" coverage = "^6.3" flake8 = "^4.0.1" Sphinx = "^4.0.1" -pre-commit = "^2.12.1" +pre-commit = "^2.18.1" sphinx-autodoc-typehints = "^1.17.0" sphinxcontrib-apidoc = "^0.3.0" sphinx-rtd-theme = "^1.0.0" From 98ef8ae649082f1ae938145e1639b7ef131cf771 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:20:31 +0000 Subject: [PATCH 311/324] Bump sphinx-autodoc-typehints from 1.17.0 to 1.18.1 Bumps [sphinx-autodoc-typehints](https://github.com/tox-dev/sphinx-autodoc-typehints) from 1.17.0 to 1.18.1. - [Release notes](https://github.com/tox-dev/sphinx-autodoc-typehints/releases) - [Changelog](https://github.com/tox-dev/sphinx-autodoc-typehints/blob/main/CHANGELOG.md) - [Commits](https://github.com/tox-dev/sphinx-autodoc-typehints/compare/1.17.0...1.18.1) --- updated-dependencies: - dependency-name: sphinx-autodoc-typehints dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- poetry.lock | 18 +++++++++--------- pyproject.toml | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/poetry.lock b/poetry.lock index 6609ea7c0..fed29453e 100644 --- a/poetry.lock +++ b/poetry.lock @@ -475,7 +475,7 @@ python-versions = "*" [[package]] name = "minos-broker-kafka" -version = "0.6.0" +version = "0.6.1" description = "The kafka plugin of the Minos Framework" category = "main" optional = false @@ -570,7 +570,7 @@ url = "packages/core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -923,18 +923,18 @@ test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] [[package]] name = "sphinx-autodoc-typehints" -version = "1.17.0" +version = "1.18.1" description = "Type hints (PEP 484) support for the Sphinx autodoc extension" category = "dev" optional = false python-versions = ">=3.7" [package.dependencies] -Sphinx = ">=4" +Sphinx = ">=4.5" [package.extras] -testing = ["covdefaults (>=2)", "coverage (>=6)", "diff-cover (>=6.4)", "nptyping (>=1)", "pytest (>=6)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=3.5)"] -type_comments = ["typed-ast (>=1.4.0)"] +testing = ["covdefaults (>=2.2)", "coverage (>=6.3)", "diff-cover (>=6.4)", "nptyping (>=2)", "pytest (>=7.1)", "pytest-cov (>=3)", "sphobjinv (>=2)", "typing-extensions (>=4.1)"] +type_comments = ["typed-ast (>=1.5.2)"] [[package]] name = "sphinx-rtd-theme" @@ -1129,7 +1129,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "30fddce08ca9aacf52b35da308a7eb6d6734425b5d5cdc9395d3734effd25e9d" +content-hash = "60e1cebe09e2812f8fa1836db690e8ff537cfb9e367d92b710532890becbe9c1" [metadata.files] aio-pika = [ @@ -1893,8 +1893,8 @@ sphinx = [ {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, ] sphinx-autodoc-typehints = [ - {file = "sphinx_autodoc_typehints-1.17.0-py3-none-any.whl", hash = "sha256:081daf53077b4ae1c28347d6d858e13e63aefe3b4aacef79fd717dd60687b470"}, - {file = "sphinx_autodoc_typehints-1.17.0.tar.gz", hash = "sha256:51c7b3f5cb9ccd15d0b52088c62df3094f1abd9612930340365c26def8629a14"}, + {file = "sphinx_autodoc_typehints-1.18.1-py3-none-any.whl", hash = "sha256:f8f5bb7c13a9a71537dc2be2eb3b9e28a9711e2454df63587005eacf6fbac453"}, + {file = "sphinx_autodoc_typehints-1.18.1.tar.gz", hash = "sha256:07631c5f0c6641e5ba27143494aefc657e029bed3982138d659250e617f6f929"}, ] sphinx-rtd-theme = [ {file = "sphinx_rtd_theme-1.0.0-py2.py3-none-any.whl", hash = "sha256:4d35a56f4508cfee4c4fb604373ede6feae2a306731d533f409ef5c3496fdbd8"}, diff --git a/pyproject.toml b/pyproject.toml index afca500c3..08dc6cd6f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -25,7 +25,7 @@ coverage = "^6.3" flake8 = "^4.0.1" Sphinx = "^4.0.1" pre-commit = "^2.12.1" -sphinx-autodoc-typehints = "^1.17.0" +sphinx-autodoc-typehints = "^1.18.1" sphinxcontrib-apidoc = "^0.3.0" sphinx-rtd-theme = "^1.0.0" m2r2 = "^0.3.2" From 17be5d0754c80fe8ae80ee15628b02f1910e2ecb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:20:35 +0000 Subject: [PATCH 312/324] Bump black in /packages/core/minos-microservice-saga Bumps [black](https://github.com/psf/black) from 22.1.0 to 22.3.0. - [Release notes](https://github.com/psf/black/releases) - [Changelog](https://github.com/psf/black/blob/main/CHANGES.md) - [Commits](https://github.com/psf/black/compare/22.1.0...22.3.0) --- updated-dependencies: - dependency-name: black dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .../core/minos-microservice-saga/poetry.lock | 54 +++++++++---------- .../minos-microservice-saga/pyproject.toml | 2 +- 2 files changed, 28 insertions(+), 28 deletions(-) diff --git a/packages/core/minos-microservice-saga/poetry.lock b/packages/core/minos-microservice-saga/poetry.lock index 8cf474bb3..0519522f2 100644 --- a/packages/core/minos-microservice-saga/poetry.lock +++ b/packages/core/minos-microservice-saga/poetry.lock @@ -85,7 +85,7 @@ pytz = ">=2015.7" [[package]] name = "black" -version = "22.1.0" +version = "22.3.0" description = "The uncompromising code formatter." category = "dev" optional = false @@ -96,7 +96,7 @@ click = ">=8.0.0" mypy-extensions = ">=0.4.3" pathspec = ">=0.9.0" platformdirs = ">=2" -tomli = ">=1.1.0" +tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} typing-extensions = {version = ">=3.10.0.0", markers = "python_version < \"3.10\""} [package.extras] @@ -400,7 +400,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.6.0" +version = "0.6.1" description = "The common core of the Minos Framework" category = "main" optional = false @@ -890,7 +890,7 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest- [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "f59b3c5c588ce969df14fed260965c6573d9ab3ba6e755966d45736cf3aeb3c7" +content-hash = "7164ecfa0b42883ace81248af84523e575b0a5814f99541de7800401251a10ac" [metadata.files] aiomisc = [ @@ -922,29 +922,29 @@ babel = [ {file = "Babel-2.9.1.tar.gz", hash = "sha256:bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0"}, ] black = [ - {file = "black-22.1.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:1297c63b9e1b96a3d0da2d85d11cd9bf8664251fd69ddac068b98dc4f34f73b6"}, - {file = "black-22.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2ff96450d3ad9ea499fc4c60e425a1439c2120cbbc1ab959ff20f7c76ec7e866"}, - {file = "black-22.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e21e1f1efa65a50e3960edd068b6ae6d64ad6235bd8bfea116a03b21836af71"}, - {file = "black-22.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e2f69158a7d120fd641d1fa9a921d898e20d52e44a74a6fbbcc570a62a6bc8ab"}, - {file = "black-22.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:228b5ae2c8e3d6227e4bde5920d2fc66cc3400fde7bcc74f480cb07ef0b570d5"}, - {file = "black-22.1.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b1a5ed73ab4c482208d20434f700d514f66ffe2840f63a6252ecc43a9bc77e8a"}, - {file = "black-22.1.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:35944b7100af4a985abfcaa860b06af15590deb1f392f06c8683b4381e8eeaf0"}, - {file = "black-22.1.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7835fee5238fc0a0baf6c9268fb816b5f5cd9b8793423a75e8cd663c48d073ba"}, - {file = "black-22.1.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dae63f2dbf82882fa3b2a3c49c32bffe144970a573cd68d247af6560fc493ae1"}, - {file = "black-22.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5fa1db02410b1924b6749c245ab38d30621564e658297484952f3d8a39fce7e8"}, - {file = "black-22.1.0-cp37-cp37m-win_amd64.whl", hash = "sha256:c8226f50b8c34a14608b848dc23a46e5d08397d009446353dad45e04af0c8e28"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:2d6f331c02f0f40aa51a22e479c8209d37fcd520c77721c034517d44eecf5912"}, - {file = "black-22.1.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:742ce9af3086e5bd07e58c8feb09dbb2b047b7f566eb5f5bc63fd455814979f3"}, - {file = "black-22.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:fdb8754b453fb15fad3f72cd9cad3e16776f0964d67cf30ebcbf10327a3777a3"}, - {file = "black-22.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5660feab44c2e3cb24b2419b998846cbb01c23c7fe645fee45087efa3da2d61"}, - {file = "black-22.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:6f2f01381f91c1efb1451998bd65a129b3ed6f64f79663a55fe0e9b74a5f81fd"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:efbadd9b52c060a8fc3b9658744091cb33c31f830b3f074422ed27bad2b18e8f"}, - {file = "black-22.1.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8871fcb4b447206904932b54b567923e5be802b9b19b744fdff092bd2f3118d0"}, - {file = "black-22.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ccad888050f5393f0d6029deea2a33e5ae371fd182a697313bdbd835d3edaf9c"}, - {file = "black-22.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07e5c049442d7ca1a2fc273c79d1aecbbf1bc858f62e8184abe1ad175c4f7cc2"}, - {file = "black-22.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:373922fc66676133ddc3e754e4509196a8c392fec3f5ca4486673e685a421321"}, - {file = "black-22.1.0-py3-none-any.whl", hash = "sha256:3524739d76b6b3ed1132422bf9d82123cd1705086723bc3e235ca39fd21c667d"}, - {file = "black-22.1.0.tar.gz", hash = "sha256:a7c0192d35635f6fc1174be575cb7915e92e5dd629ee79fdaf0dcfa41a80afb5"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:2497f9c2386572e28921fa8bec7be3e51de6801f7459dffd6e62492531c47e09"}, + {file = "black-22.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:5795a0375eb87bfe902e80e0c8cfaedf8af4d49694d69161e5bd3206c18618bb"}, + {file = "black-22.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:e3556168e2e5c49629f7b0f377070240bd5511e45e25a4497bb0073d9dda776a"}, + {file = "black-22.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67c8301ec94e3bcc8906740fe071391bce40a862b7be0b86fb5382beefecd968"}, + {file = "black-22.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:fd57160949179ec517d32ac2ac898b5f20d68ed1a9c977346efbac9c2f1e779d"}, + {file = "black-22.3.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:cc1e1de68c8e5444e8f94c3670bb48a2beef0e91dddfd4fcc29595ebd90bb9ce"}, + {file = "black-22.3.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d2fc92002d44746d3e7db7cf9313cf4452f43e9ea77a2c939defce3b10b5c82"}, + {file = "black-22.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:a6342964b43a99dbc72f72812bf88cad8f0217ae9acb47c0d4f141a6416d2d7b"}, + {file = "black-22.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:328efc0cc70ccb23429d6be184a15ce613f676bdfc85e5fe8ea2a9354b4e9015"}, + {file = "black-22.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06f9d8846f2340dfac80ceb20200ea5d1b3f181dd0556b47af4e8e0b24fa0a6b"}, + {file = "black-22.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:ad4efa5fad66b903b4a5f96d91461d90b9507a812b3c5de657d544215bb7877a"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8477ec6bbfe0312c128e74644ac8a02ca06bcdb8982d4ee06f209be28cdf163"}, + {file = "black-22.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:637a4014c63fbf42a692d22b55d8ad6968a946b4a6ebc385c5505d9625b6a464"}, + {file = "black-22.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:863714200ada56cbc366dc9ae5291ceb936573155f8bf8e9de92aef51f3ad0f0"}, + {file = "black-22.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10dbe6e6d2988049b4655b2b739f98785a884d4d6b85bc35133a8fb9a2233176"}, + {file = "black-22.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:cee3e11161dde1b2a33a904b850b0899e0424cc331b7295f2a9698e79f9a69a0"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:5891ef8abc06576985de8fa88e95ab70641de6c1fca97e2a15820a9b69e51b20"}, + {file = "black-22.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:30d78ba6bf080eeaf0b7b875d924b15cd46fec5fd044ddfbad38c8ea9171043a"}, + {file = "black-22.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ee8f1f7228cce7dffc2b464f07ce769f478968bfb3dd1254a4c2eeed84928aad"}, + {file = "black-22.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ee227b696ca60dd1c507be80a6bc849a5a6ab57ac7352aad1ffec9e8b805f21"}, + {file = "black-22.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:9b542ced1ec0ceeff5b37d69838106a6348e60db7b8fdd245294dc1d26136265"}, + {file = "black-22.3.0-py3-none-any.whl", hash = "sha256:bc58025940a896d7e5356952228b68f793cf5fcb342be703c3a2669a1488cb72"}, + {file = "black-22.3.0.tar.gz", hash = "sha256:35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79"}, ] cached-property = [ {file = "cached-property-1.5.2.tar.gz", hash = "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130"}, diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index d84cb5294..b97d55c84 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -40,7 +40,7 @@ cached-property = "^1.5.2" minos-microservice-common = { path = "../minos-microservice-common", develop = true } minos-microservice-networks = { path = "../minos-microservice-networks", develop = true } minos-microservice-aggregate = { path = "../minos-microservice-aggregate", develop = true } -black = "^22.1" +black = "^22.3" isort = "^5.8.0" pytest = "^7.0.1" coverage = "^6.3" From 058bd35839a84be457ba6b110f109ea5f5f17634 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 May 2022 04:21:01 +0000 Subject: [PATCH 313/324] Bump fastavro in /packages/core/minos-microservice-common Bumps [fastavro](https://github.com/fastavro/fastavro) from 1.4.10 to 1.4.11. - [Release notes](https://github.com/fastavro/fastavro/releases) - [Changelog](https://github.com/fastavro/fastavro/blob/master/ChangeLog) - [Commits](https://github.com/fastavro/fastavro/compare/1.4.10...1.4.11) --- updated-dependencies: - dependency-name: fastavro dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- .../minos-microservice-common/poetry.lock | 34 +++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index 62682cf99..4ec9f04f5 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -219,7 +219,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "fastavro" -version = "1.4.10" +version = "1.4.11" description = "Fast read/write of AVRO files" category = "main" optional = false @@ -994,22 +994,22 @@ docutils = [ {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, ] fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, + {file = "fastavro-1.4.11-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:44f01008f95d685edacc4b10366c755d25612df00924349f7d34a29f08522ce3"}, + {file = "fastavro-1.4.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18f5e736d12e67348f253da8a332d7c3b483ca04f2b6e772befa79d1a46bac9d"}, + {file = "fastavro-1.4.11-cp310-cp310-win_amd64.whl", hash = "sha256:8dca11bc3191cd7de0a3c4b76a70dac493356a219e96ebcde0def1f06faddef7"}, + {file = "fastavro-1.4.11-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:7a2a0bf03686f9d860e8f8476be000f5b3e6cc9af6853dbabab2ef9cfa5dc3a0"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0c17e3decfac260e1be4d02d1903d2483eec2f3ce7f92c9b808a0f6a81572c4b"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19ba25c6529f50722a7618cc4ca24c7d265def57fd9f94e4e554e1df8cce38d2"}, + {file = "fastavro-1.4.11-cp37-cp37m-win_amd64.whl", hash = "sha256:ceaba04da9419f40899a670eb62eb373a127b511bb8e3ae4f6f1f23ec49bd0e4"}, + {file = "fastavro-1.4.11-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:732eab3a1ae5d2c3f4b52e747c55bcc41c4df0eb7e8a395038080741a3c0a934"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c03d3c802b71f44e7b3442abae961bba996258244bd222b242ad1e5cb7754e57"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cb7475a9b25b9f8aebe7eb756dafedd0369434571062f3883d894281befd7c"}, + {file = "fastavro-1.4.11-cp38-cp38-win_amd64.whl", hash = "sha256:ce0776f54591aef90bcd02bd919964abe4c2ad2a10a4336c3a1b66cef289b41c"}, + {file = "fastavro-1.4.11-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:621e72cc365c9539d7590e7b43e48a62e6bfb4c2de7c16837fed54d113d7312c"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:842b25782f911ee8c626f9d9fedc2ef01aeac272536fe90ee6d45b2ae7cdb024"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f8491bfcba25c9d661289f884688e5a4f56f2ee389a240d0ad02692495a9a087"}, + {file = "fastavro-1.4.11-cp39-cp39-win_amd64.whl", hash = "sha256:c94130a8c8d80073eb0276844915aa5e928ae322024e76dc57943542ccda211c"}, + {file = "fastavro-1.4.11.tar.gz", hash = "sha256:7c64332ad52de0134be9a933ca986514c3ff85c63d54bc5398c31f0498ac1820"}, ] filelock = [ {file = "filelock-3.6.0-py3-none-any.whl", hash = "sha256:f8314284bfffbdcfa0ff3d7992b023d4c628ced6feb957351d4c48d059f56bc0"}, From 2a15cdb749aa171c2fd57a7e85254d9995ec15d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 3 May 2022 09:12:35 +0200 Subject: [PATCH 314/324] ISSUE #442 * Fix bug related with locking and `ComposedDatabaseOperation`. --- .../minos/common/database/clients/abc.py | 2 +- .../test_common/test_database/test_clients/test_abc.py | 8 +++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index b878b301a..b42341803 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -100,7 +100,7 @@ async def execute(self, operation: DatabaseOperation) -> None: if isinstance(operation, ComposedDatabaseOperation): for op in operation.operations: - await wait_for(self._execute(op), operation.timeout) + await wait_for(self.execute(op), operation.timeout) else: await wait_for(self._execute(operation), operation.timeout) diff --git a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py index fbedcca2c..70dc2207a 100644 --- a/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py +++ b/packages/core/minos-microservice-common/tests/test_common/test_database/test_clients/test_abc.py @@ -133,13 +133,15 @@ async def test_execute(self): self.assertEqual([call(operation)], mock.call_args_list) async def test_execute_composed(self): - mock = AsyncMock() client = _DatabaseClient() - client._execute = mock + mock = AsyncMock(side_effect=client.execute) + client.execute = mock composed = ComposedDatabaseOperation([_DatabaseOperation(), _DatabaseOperation()]) await client.execute(composed) - self.assertEqual([call(composed.operations[0]), call(composed.operations[1])], mock.call_args_list) + self.assertEqual( + [call(composed), call(composed.operations[0]), call(composed.operations[1])], mock.call_args_list + ) async def test_execute_with_lock(self): op1 = _DatabaseOperation(lock="foo") From bc75c124e7e2bb1c10455ce18b059c290f39a9b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 3 May 2022 09:21:52 +0200 Subject: [PATCH 315/324] ISSUE #415 * Fix bug related with `pyparsing` import instead of `typing`. --- .../minos/common/database/locks/impl.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/locks/impl.py b/packages/core/minos-microservice-common/minos/common/database/locks/impl.py index b0dba9646..3fb1a434b 100644 --- a/packages/core/minos-microservice-common/minos/common/database/locks/impl.py +++ b/packages/core/minos-microservice-common/minos/common/database/locks/impl.py @@ -5,8 +5,7 @@ from collections.abc import ( Hashable, ) - -from pyparsing import ( +from typing import ( Optional, ) From 1e6471e64475ecb58b689ac3a773839093a4e1c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 3 May 2022 09:44:10 +0200 Subject: [PATCH 316/324] * Update dependencies. --- .../minos-microservice-networks/poetry.lock | 58 +++++++------------ 1 file changed, 21 insertions(+), 37 deletions(-) diff --git a/packages/core/minos-microservice-networks/poetry.lock b/packages/core/minos-microservice-networks/poetry.lock index 4d0422d42..f1766e691 100644 --- a/packages/core/minos-microservice-networks/poetry.lock +++ b/packages/core/minos-microservice-networks/poetry.lock @@ -73,7 +73,7 @@ python-versions = "*" [[package]] name = "click" -version = "8.1.2" +version = "8.1.3" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -142,7 +142,7 @@ yaml = ["pyyaml"] [[package]] name = "fastavro" -version = "1.4.10" +version = "1.4.11" description = "Fast read/write of AVRO files" category = "main" optional = false @@ -199,15 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -<<<<<<< HEAD -version = "0.6.1" -======= -<<<<<<< HEAD -version = "0.6.1" -======= version = "0.7.0.dev2" ->>>>>>> origin/0.7.0 ->>>>>>> origin/0.7.0 description = "The common core of the Minos Framework" category = "main" optional = false @@ -390,15 +382,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -<<<<<<< HEAD -content-hash = "8c6bf58ce9d4d2349dccac0d7819cbccc16228173e667cc04ae75e9c720f49d1" -======= -<<<<<<< HEAD -content-hash = "d5f8ad9c8522f5daf4ab000f252e1c0d0dd602adbb8f1976760afb2ed1322def" -======= -content-hash = "fb90fd955533067f90236079e7f071d3f45f6d4cf0d28398f4a1ac2654576755" ->>>>>>> origin/0.7.0 ->>>>>>> origin/0.7.0 +content-hash = "ff4af32fdc2d848f93f56844f1f726f760ead3537fef11cf58b6ba4468e62dd0" [metadata.files] aiomisc = [ @@ -443,8 +427,8 @@ cached-property = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] click = [ - {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, - {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, + {file = "click-8.1.3-py3-none-any.whl", hash = "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48"}, + {file = "click-8.1.3.tar.gz", hash = "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -539,22 +523,22 @@ dependency-injector = [ {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, + {file = "fastavro-1.4.11-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:44f01008f95d685edacc4b10366c755d25612df00924349f7d34a29f08522ce3"}, + {file = "fastavro-1.4.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18f5e736d12e67348f253da8a332d7c3b483ca04f2b6e772befa79d1a46bac9d"}, + {file = "fastavro-1.4.11-cp310-cp310-win_amd64.whl", hash = "sha256:8dca11bc3191cd7de0a3c4b76a70dac493356a219e96ebcde0def1f06faddef7"}, + {file = "fastavro-1.4.11-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:7a2a0bf03686f9d860e8f8476be000f5b3e6cc9af6853dbabab2ef9cfa5dc3a0"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0c17e3decfac260e1be4d02d1903d2483eec2f3ce7f92c9b808a0f6a81572c4b"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19ba25c6529f50722a7618cc4ca24c7d265def57fd9f94e4e554e1df8cce38d2"}, + {file = "fastavro-1.4.11-cp37-cp37m-win_amd64.whl", hash = "sha256:ceaba04da9419f40899a670eb62eb373a127b511bb8e3ae4f6f1f23ec49bd0e4"}, + {file = "fastavro-1.4.11-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:732eab3a1ae5d2c3f4b52e747c55bcc41c4df0eb7e8a395038080741a3c0a934"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c03d3c802b71f44e7b3442abae961bba996258244bd222b242ad1e5cb7754e57"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cb7475a9b25b9f8aebe7eb756dafedd0369434571062f3883d894281befd7c"}, + {file = "fastavro-1.4.11-cp38-cp38-win_amd64.whl", hash = "sha256:ce0776f54591aef90bcd02bd919964abe4c2ad2a10a4336c3a1b66cef289b41c"}, + {file = "fastavro-1.4.11-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:621e72cc365c9539d7590e7b43e48a62e6bfb4c2de7c16837fed54d113d7312c"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:842b25782f911ee8c626f9d9fedc2ef01aeac272536fe90ee6d45b2ae7cdb024"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f8491bfcba25c9d661289f884688e5a4f56f2ee389a240d0ad02692495a9a087"}, + {file = "fastavro-1.4.11-cp39-cp39-win_amd64.whl", hash = "sha256:c94130a8c8d80073eb0276844915aa5e928ae322024e76dc57943542ccda211c"}, + {file = "fastavro-1.4.11.tar.gz", hash = "sha256:7c64332ad52de0134be9a933ca986514c3ff85c63d54bc5398c31f0498ac1820"}, ] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, From 8d02a8238e019a344746f58ce77b61cf7e8d8778 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 3 May 2022 11:27:08 +0200 Subject: [PATCH 317/324] ISSUE #446 * Fix bug related with non-hashable `Entity` instances within `EntitySet`. --- .../minos/aggregate/entities/collections.py | 2 +- .../test_aggregate/test_entities/test_collections.py | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/entities/collections.py b/packages/core/minos-microservice-aggregate/minos/aggregate/entities/collections.py index 62da179b2..16c5392c0 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/entities/collections.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/entities/collections.py @@ -141,7 +141,7 @@ def decode_data(cls, decoder: DataDecoder, target: Any, type_: ModelType, **kwar :return: A decoded instance. """ data_cls = get_args(type_.type_hints["data"])[1] - target = {decoder.build(v, data_cls, **kwargs) for v in target} + target = (decoder.build(v, data_cls, **kwargs) for v in target) target = {str(v["uuid"]): v for v in target} decoded = decoder.build(target, type_.type_hints["data"], **kwargs) return cls(decoded, additional_type_hints=type_.type_hints) diff --git a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_collections.py b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_collections.py index 9a655318f..e1acb1035 100644 --- a/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_collections.py +++ b/packages/core/minos-microservice-aggregate/tests/test_aggregate/test_entities/test_collections.py @@ -8,6 +8,7 @@ from minos.aggregate import ( Action, + Entity, EntitySet, IncrementalSetDiff, IncrementalSetDiffEntry, @@ -20,6 +21,10 @@ ) +class _NotHashable(Entity): + foo: set[int] + + class TestEntitySet(unittest.TestCase): def test_data(self): raw = {OrderItem("John"), OrderItem("Michael")} @@ -139,6 +144,10 @@ def test_avro_bytes(self): expected = EntitySet({OrderItem("John"), OrderItem("Michael")}) self.assertEqual(expected, Model.from_avro_bytes(expected.avro_bytes)) + def test_avro_bytes_not_hashable(self): + expected = EntitySet([_NotHashable({1}), _NotHashable({2})]) + self.assertEqual(expected, Model.from_avro_bytes(expected.avro_bytes)) + class TestEntitySetDiff(unittest.TestCase): def setUp(self) -> None: From d18e39f17d39ad00bf2981b9d3f98e7a310c4a47 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 3 May 2022 12:12:28 +0200 Subject: [PATCH 318/324] ISSUE #442 * Improve timeout behaviour. --- .../minos/common/database/clients/abc.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py index b42341803..dfa38e273 100644 --- a/packages/core/minos-microservice-common/minos/common/database/clients/abc.py +++ b/packages/core/minos-microservice-common/minos/common/database/clients/abc.py @@ -99,11 +99,14 @@ async def execute(self, operation: DatabaseOperation) -> None: await self._create_lock(operation.lock) if isinstance(operation, ComposedDatabaseOperation): - for op in operation.operations: - await wait_for(self.execute(op), operation.timeout) + await wait_for(self._execute_composed(operation), operation.timeout) else: await wait_for(self._execute(operation), operation.timeout) + async def _execute_composed(self, operation: ComposedDatabaseOperation) -> None: + for op in operation.operations: + await self.execute(op) + @abstractmethod async def _execute(self, operation: DatabaseOperation) -> None: raise NotImplementedError From 99d6f2655ebac60c35cdd6e3ea7f349a5699f83f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 3 May 2022 12:44:15 +0200 Subject: [PATCH 319/324] ISSUE #416 * Fix bug related with `poetry`'s `include`. --- packages/core/minos-microservice-aggregate/pyproject.toml | 8 ++++---- packages/core/minos-microservice-common/pyproject.toml | 8 ++++---- packages/core/minos-microservice-cqrs/pyproject.toml | 8 ++++---- packages/core/minos-microservice-networks/pyproject.toml | 8 ++++---- packages/core/minos-microservice-saga/pyproject.toml | 8 ++++---- packages/plugins/minos-broker-kafka/pyproject.toml | 8 ++++---- packages/plugins/minos-broker-rabbitmq/pyproject.toml | 8 ++++---- packages/plugins/minos-database-aiopg/pyproject.toml | 8 ++++---- packages/plugins/minos-database-lmdb/pyproject.toml | 8 ++++---- packages/plugins/minos-discovery-kong/pyproject.toml | 8 ++++---- packages/plugins/minos-discovery-minos/pyproject.toml | 8 ++++---- packages/plugins/minos-http-aiohttp/pyproject.toml | 8 ++++---- packages/plugins/minos-router-graphql/pyproject.toml | 8 ++++---- 13 files changed, 52 insertions(+), 52 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index 4da185423..238522a3b 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index eaba45f67..8fa771db5 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index 38785d7eb..89791accd 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index c2880086b..65fb9fed6 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index ad2dd2d1b..6b7722501 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/plugins/minos-broker-kafka/pyproject.toml b/packages/plugins/minos-broker-kafka/pyproject.toml index c3efa2ee0..f550cf1ac 100644 --- a/packages/plugins/minos-broker-kafka/pyproject.toml +++ b/packages/plugins/minos-broker-kafka/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/plugins/minos-broker-rabbitmq/pyproject.toml b/packages/plugins/minos-broker-rabbitmq/pyproject.toml index ff2f9a597..614a3f6f5 100644 --- a/packages/plugins/minos-broker-rabbitmq/pyproject.toml +++ b/packages/plugins/minos-broker-rabbitmq/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/plugins/minos-database-aiopg/pyproject.toml b/packages/plugins/minos-database-aiopg/pyproject.toml index ddd897287..8d950c42c 100644 --- a/packages/plugins/minos-database-aiopg/pyproject.toml +++ b/packages/plugins/minos-database-aiopg/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/plugins/minos-database-lmdb/pyproject.toml b/packages/plugins/minos-database-lmdb/pyproject.toml index 7e3b9c1cb..4869409b0 100644 --- a/packages/plugins/minos-database-lmdb/pyproject.toml +++ b/packages/plugins/minos-database-lmdb/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index 62f267657..08d7ee703 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -22,12 +22,12 @@ keywords = [ "kong" ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/plugins/minos-discovery-minos/pyproject.toml b/packages/plugins/minos-discovery-minos/pyproject.toml index 9ee7b064a..dd4d66c8f 100644 --- a/packages/plugins/minos-discovery-minos/pyproject.toml +++ b/packages/plugins/minos-discovery-minos/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/plugins/minos-http-aiohttp/pyproject.toml b/packages/plugins/minos-http-aiohttp/pyproject.toml index c8e689ede..bc4bfb877 100644 --- a/packages/plugins/minos-http-aiohttp/pyproject.toml +++ b/packages/plugins/minos-http-aiohttp/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] diff --git a/packages/plugins/minos-router-graphql/pyproject.toml b/packages/plugins/minos-router-graphql/pyproject.toml index e756b6550..864d24e6b 100644 --- a/packages/plugins/minos-router-graphql/pyproject.toml +++ b/packages/plugins/minos-router-graphql/pyproject.toml @@ -21,12 +21,12 @@ keywords = [ "saga", ] packages = [ - { include = "minos" } + { include = "minos" }, ] include = [ - "AUTHORS.md", - "HISTORY.md", - "LICENSE", + { path = "AUTHORS.md", format = "sdist" }, + { path = "HISTORY.md", format = "sdist" }, + { path = "LICENSE", format = "sdist" }, ] [tool.poetry.dependencies] From 8705efb33073c3671ded9b31850dcc7a56c80314 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Tue, 3 May 2022 13:06:51 +0200 Subject: [PATCH 320/324] v0.7.0.dev4 --- .../minos/aggregate/__init__.py | 2 +- .../minos-microservice-aggregate/poetry.lock | 4 +- .../pyproject.toml | 2 +- .../minos/common/__init__.py | 2 +- .../minos-microservice-common/pyproject.toml | 2 +- .../minos/cqrs/__init__.py | 2 +- .../core/minos-microservice-cqrs/poetry.lock | 6 +- .../minos-microservice-cqrs/pyproject.toml | 2 +- .../minos/networks/__init__.py | 2 +- .../minos-microservice-networks/poetry.lock | 2 +- .../pyproject.toml | 2 +- .../minos/saga/__init__.py | 2 +- .../core/minos-microservice-saga/poetry.lock | 6 +- .../minos-microservice-saga/pyproject.toml | 2 +- .../minos/plugins/kafka/__init__.py | 2 +- .../plugins/minos-broker-kafka/poetry.lock | 44 +-- .../plugins/minos-broker-kafka/pyproject.toml | 2 +- .../minos/plugins/rabbitmq/__init__.py | 2 +- .../plugins/minos-broker-rabbitmq/poetry.lock | 49 ++-- .../minos-broker-rabbitmq/pyproject.toml | 2 +- .../minos/plugins/aiopg/__init__.py | 2 +- .../plugins/minos-database-aiopg/poetry.lock | 52 ++-- .../minos-database-aiopg/pyproject.toml | 2 +- .../minos/plugins/lmdb/__init__.py | 2 +- .../plugins/minos-database-lmdb/poetry.lock | 54 ++-- .../minos-database-lmdb/pyproject.toml | 2 +- .../minos/plugins/kong/__init__.py | 2 +- .../plugins/minos-discovery-kong/poetry.lock | 44 +-- .../minos-discovery-kong/pyproject.toml | 2 +- .../minos/plugins/minos_discovery/__init__.py | 2 +- .../plugins/minos-discovery-minos/poetry.lock | 256 +++++------------- .../minos-discovery-minos/pyproject.toml | 2 +- .../minos/plugins/aiohttp/__init__.py | 2 +- .../plugins/minos-http-aiohttp/poetry.lock | 256 +++++------------- .../plugins/minos-http-aiohttp/pyproject.toml | 2 +- .../minos/plugins/graphql/__init__.py | 2 +- .../plugins/minos-router-graphql/poetry.lock | 44 +-- .../minos-router-graphql/pyproject.toml | 2 +- poetry.lock | 26 +- pyproject.toml | 2 +- 40 files changed, 322 insertions(+), 575 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index 05bcc105c..485ebae0a 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev4" from .actions import ( Action, diff --git a/packages/core/minos-microservice-aggregate/poetry.lock b/packages/core/minos-microservice-aggregate/poetry.lock index 132f2cc0e..6ee724dac 100644 --- a/packages/core/minos-microservice-aggregate/poetry.lock +++ b/packages/core/minos-microservice-aggregate/poetry.lock @@ -199,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -221,7 +221,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index 238522a3b..9bbb9219b 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-aggregate" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The Aggregate pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 2b8693c9f..8a62ffb30 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -1,7 +1,7 @@ """The common core of the Minos Framework.""" __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev4" from .builders import ( BuildableMixin, diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index 8fa771db5..ea8a30e2c 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py b/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py index daeca9061..b55b1ce36 100644 --- a/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py +++ b/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev4" from .exceptions import ( MinosCqrsException, diff --git a/packages/core/minos-microservice-cqrs/poetry.lock b/packages/core/minos-microservice-cqrs/poetry.lock index 03dd6e376..3397f38b8 100644 --- a/packages/core/minos-microservice-cqrs/poetry.lock +++ b/packages/core/minos-microservice-cqrs/poetry.lock @@ -199,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -217,7 +217,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -239,7 +239,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index 89791accd..771222db8 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-cqrs" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The CQRS pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-networks/minos/networks/__init__.py b/packages/core/minos-microservice-networks/minos/networks/__init__.py index d3ae24f8e..48a6cc111 100644 --- a/packages/core/minos-microservice-networks/minos/networks/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev4" from .brokers import ( REQUEST_HEADERS_CONTEXT_VAR, diff --git a/packages/core/minos-microservice-networks/poetry.lock b/packages/core/minos-microservice-networks/poetry.lock index f1766e691..80b51479f 100644 --- a/packages/core/minos-microservice-networks/poetry.lock +++ b/packages/core/minos-microservice-networks/poetry.lock @@ -199,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index 65fb9fed6..7e7607ffc 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-saga/minos/saga/__init__.py b/packages/core/minos-microservice-saga/minos/saga/__init__.py index 351dee65a..0cc5ab168 100644 --- a/packages/core/minos-microservice-saga/minos/saga/__init__.py +++ b/packages/core/minos-microservice-saga/minos/saga/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev4" from .context import ( SagaContext, diff --git a/packages/core/minos-microservice-saga/poetry.lock b/packages/core/minos-microservice-saga/poetry.lock index 187317553..984e71bc1 100644 --- a/packages/core/minos-microservice-saga/poetry.lock +++ b/packages/core/minos-microservice-saga/poetry.lock @@ -199,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -217,7 +217,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -239,7 +239,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index 6b7722501..2de75d4a7 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-saga" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The SAGA pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py index 17537c081..95f997c26 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev4" from .common import ( KafkaBrokerBuilderMixin, diff --git a/packages/plugins/minos-broker-kafka/poetry.lock b/packages/plugins/minos-broker-kafka/poetry.lock index 5bb6c4143..9b0a4e460 100644 --- a/packages/plugins/minos-broker-kafka/poetry.lock +++ b/packages/plugins/minos-broker-kafka/poetry.lock @@ -87,7 +87,7 @@ python-versions = "*" [[package]] name = "click" -version = "8.1.2" +version = "8.1.3" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -156,7 +156,7 @@ yaml = ["pyyaml"] [[package]] name = "fastavro" -version = "1.4.10" +version = "1.4.11" description = "Fast read/write of AVRO files" category = "main" optional = false @@ -224,7 +224,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -246,7 +246,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -500,8 +500,8 @@ cached-property = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] click = [ - {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, - {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, + {file = "click-8.1.3-py3-none-any.whl", hash = "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48"}, + {file = "click-8.1.3.tar.gz", hash = "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -596,22 +596,22 @@ dependency-injector = [ {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, + {file = "fastavro-1.4.11-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:44f01008f95d685edacc4b10366c755d25612df00924349f7d34a29f08522ce3"}, + {file = "fastavro-1.4.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18f5e736d12e67348f253da8a332d7c3b483ca04f2b6e772befa79d1a46bac9d"}, + {file = "fastavro-1.4.11-cp310-cp310-win_amd64.whl", hash = "sha256:8dca11bc3191cd7de0a3c4b76a70dac493356a219e96ebcde0def1f06faddef7"}, + {file = "fastavro-1.4.11-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:7a2a0bf03686f9d860e8f8476be000f5b3e6cc9af6853dbabab2ef9cfa5dc3a0"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0c17e3decfac260e1be4d02d1903d2483eec2f3ce7f92c9b808a0f6a81572c4b"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19ba25c6529f50722a7618cc4ca24c7d265def57fd9f94e4e554e1df8cce38d2"}, + {file = "fastavro-1.4.11-cp37-cp37m-win_amd64.whl", hash = "sha256:ceaba04da9419f40899a670eb62eb373a127b511bb8e3ae4f6f1f23ec49bd0e4"}, + {file = "fastavro-1.4.11-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:732eab3a1ae5d2c3f4b52e747c55bcc41c4df0eb7e8a395038080741a3c0a934"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c03d3c802b71f44e7b3442abae961bba996258244bd222b242ad1e5cb7754e57"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cb7475a9b25b9f8aebe7eb756dafedd0369434571062f3883d894281befd7c"}, + {file = "fastavro-1.4.11-cp38-cp38-win_amd64.whl", hash = "sha256:ce0776f54591aef90bcd02bd919964abe4c2ad2a10a4336c3a1b66cef289b41c"}, + {file = "fastavro-1.4.11-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:621e72cc365c9539d7590e7b43e48a62e6bfb4c2de7c16837fed54d113d7312c"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:842b25782f911ee8c626f9d9fedc2ef01aeac272536fe90ee6d45b2ae7cdb024"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f8491bfcba25c9d661289f884688e5a4f56f2ee389a240d0ad02692495a9a087"}, + {file = "fastavro-1.4.11-cp39-cp39-win_amd64.whl", hash = "sha256:c94130a8c8d80073eb0276844915aa5e928ae322024e76dc57943542ccda211c"}, + {file = "fastavro-1.4.11.tar.gz", hash = "sha256:7c64332ad52de0134be9a933ca986514c3ff85c63d54bc5398c31f0498ac1820"}, ] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, diff --git a/packages/plugins/minos-broker-kafka/pyproject.toml b/packages/plugins/minos-broker-kafka/pyproject.toml index f550cf1ac..4ac743f56 100644 --- a/packages/plugins/minos-broker-kafka/pyproject.toml +++ b/packages/plugins/minos-broker-kafka/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-broker-kafka" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The kafka plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py b/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py index 8367efc3d..79b794f09 100644 --- a/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py +++ b/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev4" from .common import ( RabbitMQBrokerBuilderMixin, diff --git a/packages/plugins/minos-broker-rabbitmq/poetry.lock b/packages/plugins/minos-broker-rabbitmq/poetry.lock index 7be5608d0..ae85670c9 100644 --- a/packages/plugins/minos-broker-rabbitmq/poetry.lock +++ b/packages/plugins/minos-broker-rabbitmq/poetry.lock @@ -1,6 +1,6 @@ [[package]] name = "aio-pika" -version = "7.1.2" +version = "7.2.0" description = "Wrapper for the aiormq for asyncio and humans." category = "main" optional = false @@ -103,7 +103,7 @@ python-versions = "*" [[package]] name = "click" -version = "8.1.2" +version = "8.1.3" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -172,7 +172,7 @@ yaml = ["pyyaml"] [[package]] name = "fastavro" -version = "1.4.10" +version = "1.4.11" description = "Fast read/write of AVRO files" category = "main" optional = false @@ -237,7 +237,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -259,7 +259,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -481,8 +481,7 @@ content-hash = "2b66ade14c61be67e8928576bec9684c7798cc021994c6815a8a0e25b47f5d5b [metadata.files] aio-pika = [ - {file = "aio-pika-7.1.2.tar.gz", hash = "sha256:b754ba114ce3cfbc5fb444c0d41c5f74f5cfff34c2c87fef3eab0ba796ec3e94"}, - {file = "aio_pika-7.1.2-py3-none-any.whl", hash = "sha256:47fbd996d6ff4a8b1ea0148091b9e056c3a581fd4be863801eba8fce690cd243"}, + {file = "aio_pika-7.2.0-py3-none-any.whl", hash = "sha256:9b741aa81b3dd3917ec1a4910ab0766e4e568bac498831c6a02f0c96936b2d3c"}, ] aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, @@ -530,8 +529,8 @@ cached-property = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] click = [ - {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, - {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, + {file = "click-8.1.3-py3-none-any.whl", hash = "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48"}, + {file = "click-8.1.3.tar.gz", hash = "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -626,22 +625,22 @@ dependency-injector = [ {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, + {file = "fastavro-1.4.11-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:44f01008f95d685edacc4b10366c755d25612df00924349f7d34a29f08522ce3"}, + {file = "fastavro-1.4.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18f5e736d12e67348f253da8a332d7c3b483ca04f2b6e772befa79d1a46bac9d"}, + {file = "fastavro-1.4.11-cp310-cp310-win_amd64.whl", hash = "sha256:8dca11bc3191cd7de0a3c4b76a70dac493356a219e96ebcde0def1f06faddef7"}, + {file = "fastavro-1.4.11-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:7a2a0bf03686f9d860e8f8476be000f5b3e6cc9af6853dbabab2ef9cfa5dc3a0"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0c17e3decfac260e1be4d02d1903d2483eec2f3ce7f92c9b808a0f6a81572c4b"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19ba25c6529f50722a7618cc4ca24c7d265def57fd9f94e4e554e1df8cce38d2"}, + {file = "fastavro-1.4.11-cp37-cp37m-win_amd64.whl", hash = "sha256:ceaba04da9419f40899a670eb62eb373a127b511bb8e3ae4f6f1f23ec49bd0e4"}, + {file = "fastavro-1.4.11-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:732eab3a1ae5d2c3f4b52e747c55bcc41c4df0eb7e8a395038080741a3c0a934"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c03d3c802b71f44e7b3442abae961bba996258244bd222b242ad1e5cb7754e57"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cb7475a9b25b9f8aebe7eb756dafedd0369434571062f3883d894281befd7c"}, + {file = "fastavro-1.4.11-cp38-cp38-win_amd64.whl", hash = "sha256:ce0776f54591aef90bcd02bd919964abe4c2ad2a10a4336c3a1b66cef289b41c"}, + {file = "fastavro-1.4.11-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:621e72cc365c9539d7590e7b43e48a62e6bfb4c2de7c16837fed54d113d7312c"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:842b25782f911ee8c626f9d9fedc2ef01aeac272536fe90ee6d45b2ae7cdb024"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f8491bfcba25c9d661289f884688e5a4f56f2ee389a240d0ad02692495a9a087"}, + {file = "fastavro-1.4.11-cp39-cp39-win_amd64.whl", hash = "sha256:c94130a8c8d80073eb0276844915aa5e928ae322024e76dc57943542ccda211c"}, + {file = "fastavro-1.4.11.tar.gz", hash = "sha256:7c64332ad52de0134be9a933ca986514c3ff85c63d54bc5398c31f0498ac1820"}, ] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, diff --git a/packages/plugins/minos-broker-rabbitmq/pyproject.toml b/packages/plugins/minos-broker-rabbitmq/pyproject.toml index 614a3f6f5..293aef865 100644 --- a/packages/plugins/minos-broker-rabbitmq/pyproject.toml +++ b/packages/plugins/minos-broker-rabbitmq/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-broker-rabbitmq" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The rabbitmq plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py index 152433c47..244a6f058 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev4" from .clients import ( AiopgDatabaseClient, diff --git a/packages/plugins/minos-database-aiopg/poetry.lock b/packages/plugins/minos-database-aiopg/poetry.lock index 29e4acb6c..4ec152b32 100644 --- a/packages/plugins/minos-database-aiopg/poetry.lock +++ b/packages/plugins/minos-database-aiopg/poetry.lock @@ -96,7 +96,7 @@ python-versions = "*" [[package]] name = "click" -version = "8.1.2" +version = "8.1.3" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -165,7 +165,7 @@ yaml = ["pyyaml"] [[package]] name = "fastavro" -version = "1.4.10" +version = "1.4.11" description = "Fast read/write of AVRO files" category = "main" optional = false @@ -222,7 +222,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -240,7 +240,7 @@ url = "../../core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -262,7 +262,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -381,7 +381,7 @@ diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" -version = "7.1.1" +version = "7.1.2" description = "pytest: simple powerful testing with Python" category = "dev" optional = false @@ -501,8 +501,8 @@ cached-property = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] click = [ - {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, - {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, + {file = "click-8.1.3-py3-none-any.whl", hash = "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48"}, + {file = "click-8.1.3.tar.gz", hash = "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -597,22 +597,22 @@ dependency-injector = [ {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, + {file = "fastavro-1.4.11-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:44f01008f95d685edacc4b10366c755d25612df00924349f7d34a29f08522ce3"}, + {file = "fastavro-1.4.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18f5e736d12e67348f253da8a332d7c3b483ca04f2b6e772befa79d1a46bac9d"}, + {file = "fastavro-1.4.11-cp310-cp310-win_amd64.whl", hash = "sha256:8dca11bc3191cd7de0a3c4b76a70dac493356a219e96ebcde0def1f06faddef7"}, + {file = "fastavro-1.4.11-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:7a2a0bf03686f9d860e8f8476be000f5b3e6cc9af6853dbabab2ef9cfa5dc3a0"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0c17e3decfac260e1be4d02d1903d2483eec2f3ce7f92c9b808a0f6a81572c4b"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19ba25c6529f50722a7618cc4ca24c7d265def57fd9f94e4e554e1df8cce38d2"}, + {file = "fastavro-1.4.11-cp37-cp37m-win_amd64.whl", hash = "sha256:ceaba04da9419f40899a670eb62eb373a127b511bb8e3ae4f6f1f23ec49bd0e4"}, + {file = "fastavro-1.4.11-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:732eab3a1ae5d2c3f4b52e747c55bcc41c4df0eb7e8a395038080741a3c0a934"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c03d3c802b71f44e7b3442abae961bba996258244bd222b242ad1e5cb7754e57"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cb7475a9b25b9f8aebe7eb756dafedd0369434571062f3883d894281befd7c"}, + {file = "fastavro-1.4.11-cp38-cp38-win_amd64.whl", hash = "sha256:ce0776f54591aef90bcd02bd919964abe4c2ad2a10a4336c3a1b66cef289b41c"}, + {file = "fastavro-1.4.11-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:621e72cc365c9539d7590e7b43e48a62e6bfb4c2de7c16837fed54d113d7312c"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:842b25782f911ee8c626f9d9fedc2ef01aeac272536fe90ee6d45b2ae7cdb024"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f8491bfcba25c9d661289f884688e5a4f56f2ee389a240d0ad02692495a9a087"}, + {file = "fastavro-1.4.11-cp39-cp39-win_amd64.whl", hash = "sha256:c94130a8c8d80073eb0276844915aa5e928ae322024e76dc57943542ccda211c"}, + {file = "fastavro-1.4.11.tar.gz", hash = "sha256:7c64332ad52de0134be9a933ca986514c3ff85c63d54bc5398c31f0498ac1820"}, ] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, @@ -762,8 +762,8 @@ pyparsing = [ {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ - {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, - {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, + {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, + {file = "pytest-7.1.2.tar.gz", hash = "sha256:a06a0425453864a270bc45e71f783330a7428defb4230fb5e6a731fde06ecd45"}, ] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, diff --git a/packages/plugins/minos-database-aiopg/pyproject.toml b/packages/plugins/minos-database-aiopg/pyproject.toml index 8d950c42c..ea8875efb 100644 --- a/packages/plugins/minos-database-aiopg/pyproject.toml +++ b/packages/plugins/minos-database-aiopg/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-database-aiopg" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The aiopg plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py index 24074b81d..aa1c7ac56 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev4" from .clients import ( LmdbDatabaseClient, diff --git a/packages/plugins/minos-database-lmdb/poetry.lock b/packages/plugins/minos-database-lmdb/poetry.lock index 875f0f579..a77e8913d 100644 --- a/packages/plugins/minos-database-lmdb/poetry.lock +++ b/packages/plugins/minos-database-lmdb/poetry.lock @@ -73,7 +73,7 @@ python-versions = "*" [[package]] name = "click" -version = "8.1.2" +version = "8.1.3" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -142,7 +142,7 @@ yaml = ["pyyaml"] [[package]] name = "fastavro" -version = "1.4.10" +version = "1.4.11" description = "Fast read/write of AVRO files" category = "main" optional = false @@ -207,7 +207,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -225,7 +225,7 @@ url = "../../core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -247,7 +247,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -264,7 +264,7 @@ url = "../../core/minos-microservice-networks" [[package]] name = "minos-microservice-saga" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The SAGA pattern of the Minos Framework" category = "main" optional = false @@ -377,7 +377,7 @@ diagrams = ["railroad-diagrams", "jinja2"] [[package]] name = "pytest" -version = "7.1.1" +version = "7.1.2" description = "pytest: simple powerful testing with Python" category = "dev" optional = false @@ -489,8 +489,8 @@ cached-property = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] click = [ - {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, - {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, + {file = "click-8.1.3-py3-none-any.whl", hash = "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48"}, + {file = "click-8.1.3.tar.gz", hash = "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -585,22 +585,22 @@ dependency-injector = [ {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, + {file = "fastavro-1.4.11-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:44f01008f95d685edacc4b10366c755d25612df00924349f7d34a29f08522ce3"}, + {file = "fastavro-1.4.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18f5e736d12e67348f253da8a332d7c3b483ca04f2b6e772befa79d1a46bac9d"}, + {file = "fastavro-1.4.11-cp310-cp310-win_amd64.whl", hash = "sha256:8dca11bc3191cd7de0a3c4b76a70dac493356a219e96ebcde0def1f06faddef7"}, + {file = "fastavro-1.4.11-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:7a2a0bf03686f9d860e8f8476be000f5b3e6cc9af6853dbabab2ef9cfa5dc3a0"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0c17e3decfac260e1be4d02d1903d2483eec2f3ce7f92c9b808a0f6a81572c4b"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19ba25c6529f50722a7618cc4ca24c7d265def57fd9f94e4e554e1df8cce38d2"}, + {file = "fastavro-1.4.11-cp37-cp37m-win_amd64.whl", hash = "sha256:ceaba04da9419f40899a670eb62eb373a127b511bb8e3ae4f6f1f23ec49bd0e4"}, + {file = "fastavro-1.4.11-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:732eab3a1ae5d2c3f4b52e747c55bcc41c4df0eb7e8a395038080741a3c0a934"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c03d3c802b71f44e7b3442abae961bba996258244bd222b242ad1e5cb7754e57"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cb7475a9b25b9f8aebe7eb756dafedd0369434571062f3883d894281befd7c"}, + {file = "fastavro-1.4.11-cp38-cp38-win_amd64.whl", hash = "sha256:ce0776f54591aef90bcd02bd919964abe4c2ad2a10a4336c3a1b66cef289b41c"}, + {file = "fastavro-1.4.11-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:621e72cc365c9539d7590e7b43e48a62e6bfb4c2de7c16837fed54d113d7312c"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:842b25782f911ee8c626f9d9fedc2ef01aeac272536fe90ee6d45b2ae7cdb024"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f8491bfcba25c9d661289f884688e5a4f56f2ee389a240d0ad02692495a9a087"}, + {file = "fastavro-1.4.11-cp39-cp39-win_amd64.whl", hash = "sha256:c94130a8c8d80073eb0276844915aa5e928ae322024e76dc57943542ccda211c"}, + {file = "fastavro-1.4.11.tar.gz", hash = "sha256:7c64332ad52de0134be9a933ca986514c3ff85c63d54bc5398c31f0498ac1820"}, ] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, @@ -722,8 +722,8 @@ pyparsing = [ {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, ] pytest = [ - {file = "pytest-7.1.1-py3-none-any.whl", hash = "sha256:92f723789a8fdd7180b6b06483874feca4c48a5c76968e03bb3e7f806a1869ea"}, - {file = "pytest-7.1.1.tar.gz", hash = "sha256:841132caef6b1ad17a9afde46dc4f6cfa59a05f9555aae5151f73bdf2820ca63"}, + {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, + {file = "pytest-7.1.2.tar.gz", hash = "sha256:a06a0425453864a270bc45e71f783330a7428defb4230fb5e6a731fde06ecd45"}, ] pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, diff --git a/packages/plugins/minos-database-lmdb/pyproject.toml b/packages/plugins/minos-database-lmdb/pyproject.toml index 4869409b0..a699b437a 100644 --- a/packages/plugins/minos-database-lmdb/pyproject.toml +++ b/packages/plugins/minos-database-lmdb/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-database-lmdb" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The lmdb plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index 7f445b65e..9284e69c8 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev3" +__version__ = "0.7.0.dev4" from .client import ( KongClient, diff --git a/packages/plugins/minos-discovery-kong/poetry.lock b/packages/plugins/minos-discovery-kong/poetry.lock index 317c08de6..0e9fbd76d 100644 --- a/packages/plugins/minos-discovery-kong/poetry.lock +++ b/packages/plugins/minos-discovery-kong/poetry.lock @@ -109,7 +109,7 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.1.2" +version = "8.1.3" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -178,7 +178,7 @@ yaml = ["pyyaml"] [[package]] name = "fastavro" -version = "1.4.10" +version = "1.4.11" description = "Fast read/write of AVRO files" category = "main" optional = false @@ -290,7 +290,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -312,7 +312,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -599,8 +599,8 @@ charset-normalizer = [ {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, - {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, + {file = "click-8.1.3-py3-none-any.whl", hash = "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48"}, + {file = "click-8.1.3.tar.gz", hash = "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -695,22 +695,22 @@ dependency-injector = [ {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, + {file = "fastavro-1.4.11-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:44f01008f95d685edacc4b10366c755d25612df00924349f7d34a29f08522ce3"}, + {file = "fastavro-1.4.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18f5e736d12e67348f253da8a332d7c3b483ca04f2b6e772befa79d1a46bac9d"}, + {file = "fastavro-1.4.11-cp310-cp310-win_amd64.whl", hash = "sha256:8dca11bc3191cd7de0a3c4b76a70dac493356a219e96ebcde0def1f06faddef7"}, + {file = "fastavro-1.4.11-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:7a2a0bf03686f9d860e8f8476be000f5b3e6cc9af6853dbabab2ef9cfa5dc3a0"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0c17e3decfac260e1be4d02d1903d2483eec2f3ce7f92c9b808a0f6a81572c4b"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19ba25c6529f50722a7618cc4ca24c7d265def57fd9f94e4e554e1df8cce38d2"}, + {file = "fastavro-1.4.11-cp37-cp37m-win_amd64.whl", hash = "sha256:ceaba04da9419f40899a670eb62eb373a127b511bb8e3ae4f6f1f23ec49bd0e4"}, + {file = "fastavro-1.4.11-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:732eab3a1ae5d2c3f4b52e747c55bcc41c4df0eb7e8a395038080741a3c0a934"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c03d3c802b71f44e7b3442abae961bba996258244bd222b242ad1e5cb7754e57"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cb7475a9b25b9f8aebe7eb756dafedd0369434571062f3883d894281befd7c"}, + {file = "fastavro-1.4.11-cp38-cp38-win_amd64.whl", hash = "sha256:ce0776f54591aef90bcd02bd919964abe4c2ad2a10a4336c3a1b66cef289b41c"}, + {file = "fastavro-1.4.11-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:621e72cc365c9539d7590e7b43e48a62e6bfb4c2de7c16837fed54d113d7312c"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:842b25782f911ee8c626f9d9fedc2ef01aeac272536fe90ee6d45b2ae7cdb024"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f8491bfcba25c9d661289f884688e5a4f56f2ee389a240d0ad02692495a9a087"}, + {file = "fastavro-1.4.11-cp39-cp39-win_amd64.whl", hash = "sha256:c94130a8c8d80073eb0276844915aa5e928ae322024e76dc57943542ccda211c"}, + {file = "fastavro-1.4.11.tar.gz", hash = "sha256:7c64332ad52de0134be9a933ca986514c3ff85c63d54bc5398c31f0498ac1820"}, ] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index 08d7ee703..c03aa5815 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-kong" -version = "0.7.0.dev3" +version = "0.7.0.dev4" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py b/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py index 9f4dbd476..c63e65556 100644 --- a/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py +++ b/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev4" from .client import ( MinosDiscoveryClient, diff --git a/packages/plugins/minos-discovery-minos/poetry.lock b/packages/plugins/minos-discovery-minos/poetry.lock index 4b8937fd7..7369be101 100644 --- a/packages/plugins/minos-discovery-minos/poetry.lock +++ b/packages/plugins/minos-discovery-minos/poetry.lock @@ -39,21 +39,6 @@ develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-ti raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - [[package]] name = "aiosignal" version = "1.2.0" @@ -138,7 +123,7 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.1.2" +version = "8.1.3" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -207,7 +192,7 @@ yaml = ["pyyaml"] [[package]] name = "fastavro" -version = "1.4.10" +version = "1.4.11" description = "Fast read/write of AVRO files" category = "main" optional = false @@ -270,14 +255,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -288,7 +265,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -297,11 +274,9 @@ develop = true [package.dependencies] aiomisc = ">=14.0.3,<15.8.0" -aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -312,7 +287,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -320,10 +295,8 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiopg = "^1.2.1" crontab = "^0.23.0" minos-microservice-common = "^0.7.0*" -psycopg2-binary = "^2.9.3" [package.source] type = "directory" @@ -347,7 +320,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -374,15 +347,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -396,14 +369,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "py" version = "1.11.0" @@ -494,11 +459,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -609,10 +574,6 @@ aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] aiosignal = [ {file = "aiosignal-1.2.0-py3-none-any.whl", hash = "sha256:26e62109036cd181df6e6ad646f91f0dcfd05fe16d0cb924138ff2ab75d64e3a"}, {file = "aiosignal-1.2.0.tar.gz", hash = "sha256:78ed67db6c7b7ced4f98e495e572106d5c432a93e1ddd1bf475e1dc05f5b7df2"}, @@ -663,8 +624,8 @@ charset-normalizer = [ {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, - {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, + {file = "click-8.1.3-py3-none-any.whl", hash = "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48"}, + {file = "click-8.1.3.tar.gz", hash = "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -759,22 +720,22 @@ dependency-injector = [ {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, + {file = "fastavro-1.4.11-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:44f01008f95d685edacc4b10366c755d25612df00924349f7d34a29f08522ce3"}, + {file = "fastavro-1.4.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18f5e736d12e67348f253da8a332d7c3b483ca04f2b6e772befa79d1a46bac9d"}, + {file = "fastavro-1.4.11-cp310-cp310-win_amd64.whl", hash = "sha256:8dca11bc3191cd7de0a3c4b76a70dac493356a219e96ebcde0def1f06faddef7"}, + {file = "fastavro-1.4.11-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:7a2a0bf03686f9d860e8f8476be000f5b3e6cc9af6853dbabab2ef9cfa5dc3a0"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0c17e3decfac260e1be4d02d1903d2483eec2f3ce7f92c9b808a0f6a81572c4b"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19ba25c6529f50722a7618cc4ca24c7d265def57fd9f94e4e554e1df8cce38d2"}, + {file = "fastavro-1.4.11-cp37-cp37m-win_amd64.whl", hash = "sha256:ceaba04da9419f40899a670eb62eb373a127b511bb8e3ae4f6f1f23ec49bd0e4"}, + {file = "fastavro-1.4.11-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:732eab3a1ae5d2c3f4b52e747c55bcc41c4df0eb7e8a395038080741a3c0a934"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c03d3c802b71f44e7b3442abae961bba996258244bd222b242ad1e5cb7754e57"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cb7475a9b25b9f8aebe7eb756dafedd0369434571062f3883d894281befd7c"}, + {file = "fastavro-1.4.11-cp38-cp38-win_amd64.whl", hash = "sha256:ce0776f54591aef90bcd02bd919964abe4c2ad2a10a4336c3a1b66cef289b41c"}, + {file = "fastavro-1.4.11-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:621e72cc365c9539d7590e7b43e48a62e6bfb4c2de7c16837fed54d113d7312c"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:842b25782f911ee8c626f9d9fedc2ef01aeac272536fe90ee6d45b2ae7cdb024"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f8491bfcba25c9d661289f884688e5a4f56f2ee389a240d0ad02692495a9a087"}, + {file = "fastavro-1.4.11-cp39-cp39-win_amd64.whl", hash = "sha256:c94130a8c8d80073eb0276844915aa5e928ae322024e76dc57943542ccda211c"}, + {file = "fastavro-1.4.11.tar.gz", hash = "sha256:7c64332ad52de0134be9a933ca986514c3ff85c63d54bc5398c31f0498ac1820"}, ] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, @@ -853,35 +814,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -954,38 +886,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -996,71 +928,13 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, @@ -1129,8 +1003,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/plugins/minos-discovery-minos/pyproject.toml b/packages/plugins/minos-discovery-minos/pyproject.toml index dd4d66c8f..8273085ca 100644 --- a/packages/plugins/minos-discovery-minos/pyproject.toml +++ b/packages/plugins/minos-discovery-minos/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-minos" -version = "0.7.0.dev1" +version = "0.7.0.dev4" description = "The minos-discovery plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py index 5b548d3a8..ed6edd6a4 100644 --- a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py +++ b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev1" +__version__ = "0.7.0.dev4" from .connectors import ( AioHttpConnector, diff --git a/packages/plugins/minos-http-aiohttp/poetry.lock b/packages/plugins/minos-http-aiohttp/poetry.lock index 5f54411d9..0d67b092c 100644 --- a/packages/plugins/minos-http-aiohttp/poetry.lock +++ b/packages/plugins/minos-http-aiohttp/poetry.lock @@ -39,21 +39,6 @@ develop = ["aiocontextvars (==0.2.2)", "aiohttp-asgi", "aiohttp (<4)", "async-ti raven = ["raven-aiohttp"] uvloop = ["uvloop (>=0.14,<1)"] -[[package]] -name = "aiopg" -version = "1.3.3" -description = "Postgres integration with asyncio." -category = "main" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -async-timeout = ">=3.0,<5.0" -psycopg2-binary = ">=2.8.4" - -[package.extras] -sa = ["sqlalchemy[postgresql_psycopg2binary] (>=1.3,<1.5)"] - [[package]] name = "aiosignal" version = "1.2.0" @@ -138,7 +123,7 @@ unicode_backport = ["unicodedata2"] [[package]] name = "click" -version = "8.1.2" +version = "8.1.3" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -207,7 +192,7 @@ yaml = ["pyyaml"] [[package]] name = "fastavro" -version = "1.4.10" +version = "1.4.11" description = "Fast read/write of AVRO files" category = "main" optional = false @@ -270,14 +255,6 @@ requirements_deprecated_finder = ["pipreqs", "pip-api"] colors = ["colorama (>=0.4.3,<0.5.0)"] plugins = ["setuptools"] -[[package]] -name = "lmdb" -version = "1.3.0" -description = "Universal Python binding for the LMDB 'Lightning' Database" -category = "main" -optional = false -python-versions = "*" - [[package]] name = "mccabe" version = "0.6.1" @@ -288,7 +265,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev1" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -297,11 +274,9 @@ develop = true [package.dependencies] aiomisc = ">=14.0.3,<15.8.0" -aiopg = "^1.2.1" cached-property = "^1.5.2" dependency-injector = "^4.32.2" fastavro = "^1.4.0" -lmdb = "^1.2.1" orjson = "^3.5.2" PyYAML = ">=5.4.1,<7.0.0" uvloop = "^0.16.0" @@ -312,7 +287,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev1" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -320,10 +295,8 @@ python-versions = "^3.9" develop = true [package.dependencies] -aiopg = "^1.2.1" crontab = "^0.23.0" minos-microservice-common = "^0.7.0*" -psycopg2-binary = "^2.9.3" [package.source] type = "directory" @@ -347,7 +320,7 @@ python-versions = "*" [[package]] name = "orjson" -version = "3.6.7" +version = "3.6.8" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" category = "main" optional = false @@ -374,15 +347,15 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "platformdirs" -version = "2.5.1" +version = "2.5.2" description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] +docs = ["furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)", "sphinx (>=4)"] +test = ["appdirs (==1.4.4)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)", "pytest (>=6)"] [[package]] name = "pluggy" @@ -396,14 +369,6 @@ python-versions = ">=3.6" dev = ["pre-commit", "tox"] testing = ["pytest", "pytest-benchmark"] -[[package]] -name = "psycopg2-binary" -version = "2.9.3" -description = "psycopg2 - Python-PostgreSQL Database Adapter" -category = "main" -optional = false -python-versions = ">=3.6" - [[package]] name = "py" version = "1.11.0" @@ -494,11 +459,11 @@ python-versions = ">=3.7" [[package]] name = "typing-extensions" -version = "4.1.1" -description = "Backported and Experimental Type Hints for Python 3.6+" +version = "4.2.0" +description = "Backported and Experimental Type Hints for Python 3.7+" category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [[package]] name = "uvloop" @@ -609,10 +574,6 @@ aiomisc = [ {file = "aiomisc-15.7.3-py3-none-any.whl", hash = "sha256:0403e83268e98d0f2a125a70d13303fe1a2358e36db3daf02df032c7fa4f1525"}, {file = "aiomisc-15.7.3.tar.gz", hash = "sha256:ba250a34bd4609ced36111cb50580f57c3d52f3955f953a53ecb2986988baedc"}, ] -aiopg = [ - {file = "aiopg-1.3.3-py3-none-any.whl", hash = "sha256:2842dd8741460eeef940032dcb577bfba4d4115205dd82a73ce13b3271f5bf0a"}, - {file = "aiopg-1.3.3.tar.gz", hash = "sha256:547c6ba4ea0d73c2a11a2f44387d7133cc01d3c6f3b8ed976c0ac1eff4f595d7"}, -] aiosignal = [ {file = "aiosignal-1.2.0-py3-none-any.whl", hash = "sha256:26e62109036cd181df6e6ad646f91f0dcfd05fe16d0cb924138ff2ab75d64e3a"}, {file = "aiosignal-1.2.0.tar.gz", hash = "sha256:78ed67db6c7b7ced4f98e495e572106d5c432a93e1ddd1bf475e1dc05f5b7df2"}, @@ -663,8 +624,8 @@ charset-normalizer = [ {file = "charset_normalizer-2.0.12-py3-none-any.whl", hash = "sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"}, ] click = [ - {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, - {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, + {file = "click-8.1.3-py3-none-any.whl", hash = "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48"}, + {file = "click-8.1.3.tar.gz", hash = "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -759,22 +720,22 @@ dependency-injector = [ {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, + {file = "fastavro-1.4.11-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:44f01008f95d685edacc4b10366c755d25612df00924349f7d34a29f08522ce3"}, + {file = "fastavro-1.4.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18f5e736d12e67348f253da8a332d7c3b483ca04f2b6e772befa79d1a46bac9d"}, + {file = "fastavro-1.4.11-cp310-cp310-win_amd64.whl", hash = "sha256:8dca11bc3191cd7de0a3c4b76a70dac493356a219e96ebcde0def1f06faddef7"}, + {file = "fastavro-1.4.11-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:7a2a0bf03686f9d860e8f8476be000f5b3e6cc9af6853dbabab2ef9cfa5dc3a0"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0c17e3decfac260e1be4d02d1903d2483eec2f3ce7f92c9b808a0f6a81572c4b"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19ba25c6529f50722a7618cc4ca24c7d265def57fd9f94e4e554e1df8cce38d2"}, + {file = "fastavro-1.4.11-cp37-cp37m-win_amd64.whl", hash = "sha256:ceaba04da9419f40899a670eb62eb373a127b511bb8e3ae4f6f1f23ec49bd0e4"}, + {file = "fastavro-1.4.11-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:732eab3a1ae5d2c3f4b52e747c55bcc41c4df0eb7e8a395038080741a3c0a934"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c03d3c802b71f44e7b3442abae961bba996258244bd222b242ad1e5cb7754e57"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cb7475a9b25b9f8aebe7eb756dafedd0369434571062f3883d894281befd7c"}, + {file = "fastavro-1.4.11-cp38-cp38-win_amd64.whl", hash = "sha256:ce0776f54591aef90bcd02bd919964abe4c2ad2a10a4336c3a1b66cef289b41c"}, + {file = "fastavro-1.4.11-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:621e72cc365c9539d7590e7b43e48a62e6bfb4c2de7c16837fed54d113d7312c"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:842b25782f911ee8c626f9d9fedc2ef01aeac272536fe90ee6d45b2ae7cdb024"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f8491bfcba25c9d661289f884688e5a4f56f2ee389a240d0ad02692495a9a087"}, + {file = "fastavro-1.4.11-cp39-cp39-win_amd64.whl", hash = "sha256:c94130a8c8d80073eb0276844915aa5e928ae322024e76dc57943542ccda211c"}, + {file = "fastavro-1.4.11.tar.gz", hash = "sha256:7c64332ad52de0134be9a933ca986514c3ff85c63d54bc5398c31f0498ac1820"}, ] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, @@ -853,35 +814,6 @@ isort = [ {file = "isort-5.10.1-py3-none-any.whl", hash = "sha256:6f62d78e2f89b4500b080fe3a81690850cd254227f27f75c3a0c491a1f351ba7"}, {file = "isort-5.10.1.tar.gz", hash = "sha256:e8443a5e7a020e9d7f97f1d7d9cd17c88bcb3bc7e218bf9cf5095fe550be2951"}, ] -lmdb = [ - {file = "lmdb-1.3.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:63cb73fe7ce9eb93d992d632c85a0476b4332670d9e6a2802b5062f603b7809f"}, - {file = "lmdb-1.3.0-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:abbc439cd9fe60ffd6197009087ea885ac150017dc85384093b1d376f83f0ec4"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6260a526e4ad85b1f374a5ba9475bf369fb07e7728ea6ec57226b02c40d1976b"}, - {file = "lmdb-1.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e568ae0887ae196340947d9800136e90feaed6b86a261ef01f01b2ba65fc8106"}, - {file = "lmdb-1.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:d6a816954d212f40fd15007cd81ab7a6bebb77436d949a6a9ae04af57fc127f3"}, - {file = "lmdb-1.3.0-cp35-cp35m-macosx_10_14_x86_64.whl", hash = "sha256:fa6439356e591d3249ab0e1778a6f8d8408e993f66dc911914c78208f5310309"}, - {file = "lmdb-1.3.0-cp35-cp35m-win_amd64.whl", hash = "sha256:c6adbd6f7f9048e97f31a069e652eb51020a81e80a0ce92dbb9810d21da2409a"}, - {file = "lmdb-1.3.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:eefb392f6b5cd43aada49258c5a79be11cb2c8cd3fc3e2d9319a1e0b9f906458"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5a14aca2651c3af6f0d0a6b9168200eea0c8f2d27c40b01a442f33329a6e8dff"}, - {file = "lmdb-1.3.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2cfa4aa9c67f8aee89b23005e98d1f3f32490b6b905fd1cb604b207cbd5755ab"}, - {file = "lmdb-1.3.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7da05d70fcc6561ac6b09e9fb1bf64b7ca294652c64c8a2889273970cee796b9"}, - {file = "lmdb-1.3.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:008243762decf8f6c90430a9bced56290ebbcdb5e877d90e42343bb97033e494"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:17215a42a4b9814c383deabecb160581e4fb75d00198eef0e3cea54f230ffbea"}, - {file = "lmdb-1.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:65334eafa5d430b18d81ebd5362559a41483c362e1931f6e1b15bab2ecb7d75d"}, - {file = "lmdb-1.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:18c69fabdaf04efaf246587739cc1062b3e57c6ef0743f5c418df89e5e7e7b9b"}, - {file = "lmdb-1.3.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:41318717ab5d15ad2d6d263d34fbf614a045210f64b25e59ce734bb2105e421f"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:df2724bad7820114a205472994091097d0fa65a3e5fff5a8e688d123fb8c6326"}, - {file = "lmdb-1.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5ddd590e1c7fcb395931aa3782fb89b9db4550ab2d81d006ecd239e0d462bc41"}, - {file = "lmdb-1.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:4172fba19417d7b29409beca7d73c067b54e5d8ab1fb9b51d7b4c1445d20a167"}, - {file = "lmdb-1.3.0-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:2df38115dd9428a54d59ae7c712a4c7cce0d6b1d66056de4b1a8c38718066106"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:d9103aa4908f0bca43c5911ca067d4e3d01f682dff0c0381a1239bd2bd757984"}, - {file = "lmdb-1.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:394df860c3f93cfd92b6f4caba785f38208cc9614c18b3803f83a2cc1695042f"}, - {file = "lmdb-1.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:62ab28e3593bdc318ea2f2fa1574e5fca3b6d1f264686d773ba54a637d4f563b"}, - {file = "lmdb-1.3.0-pp27-pypy_73-macosx_10_7_x86_64.whl", hash = "sha256:e6a704b3baced9182836c7f77b769f23856f3a8f62d0282b1bc1feaf81a86712"}, - {file = "lmdb-1.3.0-pp27-pypy_73-win_amd64.whl", hash = "sha256:08f4b5129f4683802569b02581142e415c8dcc0ff07605983ec1b07804cecbad"}, - {file = "lmdb-1.3.0-pp36-pypy36_pp73-win32.whl", hash = "sha256:f291e3f561f58dddf63a92a5a6a4b8af3a0920b6705d35e2f80e52e86ee238a2"}, - {file = "lmdb-1.3.0.tar.gz", hash = "sha256:60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e"}, -] mccabe = [ {file = "mccabe-0.6.1-py2.py3-none-any.whl", hash = "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42"}, {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, @@ -954,38 +886,38 @@ mypy-extensions = [ {file = "mypy_extensions-0.4.3.tar.gz", hash = "sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"}, ] orjson = [ - {file = "orjson-3.6.7-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:93188a9d6eb566419ad48befa202dfe7cd7a161756444b99c4ec77faea9352a4"}, - {file = "orjson-3.6.7-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:82515226ecb77689a029061552b5df1802b75d861780c401e96ca6bc8495f775"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3af57ffab7848aaec6ba6b9e9b41331250b57bf696f9d502bacdc71a0ebab0ba"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:a7297504d1142e7efa236ffc53f056d73934a993a08646dbcee89fc4308a8fcf"}, - {file = "orjson-3.6.7-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:5a50cde0dbbde255ce751fd1bca39d00ecd878ba0903c0480961b31984f2fab7"}, - {file = "orjson-3.6.7-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:d21f9a2d1c30e58070f93988db4cad154b9009fafbde238b52c1c760e3607fbe"}, - {file = "orjson-3.6.7-cp310-none-win_amd64.whl", hash = "sha256:e152464c4606b49398afd911777decebcf9749cc8810c5b4199039e1afb0991e"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:0a65f3c403f38b0117c6dd8e76e85a7bd51fcd92f06c5598dfeddbc44697d3e5"}, - {file = "orjson-3.6.7-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:6c47cfca18e41f7f37b08ff3e7abf5ada2d0f27b5ade934f05be5fc5bb956e9d"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:63185af814c243fad7a72441e5f98120c9ecddf2675befa486d669fb65539e9b"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b2da6fde42182b80b40df2e6ab855c55090ebfa3fcc21c182b7ad1762b61d55c"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:48c5831ec388b4e2682d4ff56d6bfa4a2ef76c963f5e75f4ff4785f9cf338a80"}, - {file = "orjson-3.6.7-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:913fac5d594ccabf5e8fbac15b9b3bb9c576d537d49eeec9f664e7a64dde4c4b"}, - {file = "orjson-3.6.7-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:58f244775f20476e5851e7546df109f75160a5178d44257d437ba6d7e562bfe8"}, - {file = "orjson-3.6.7-cp37-none-win_amd64.whl", hash = "sha256:2d5f45c6b85e5f14646df2d32ecd7ff20fcccc71c0ea1155f4d3df8c5299bbb7"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:612d242493afeeb2068bc72ff2544aa3b1e627578fcf92edee9daebb5893ffea"}, - {file = "orjson-3.6.7-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:539cdc5067db38db27985e257772d073cd2eb9462d0a41bde96da4e4e60bd99b"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:6d103b721bbc4f5703f62b3882e638c0b65fcdd48622531c7ffd45047ef8e87c"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb10a20f80e95102dd35dfbc3a22531661b44a09b55236b012a446955846b023"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:bb68d0da349cf8a68971a48ad179434f75256159fe8b0715275d9b49fa23b7a3"}, - {file = "orjson-3.6.7-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:4a2c7d0a236aaeab7f69c17b7ab4c078874e817da1bfbb9827cb8c73058b3050"}, - {file = "orjson-3.6.7-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:3be045ca3b96119f592904cf34b962969ce97bd7843cbfca084009f6c8d2f268"}, - {file = "orjson-3.6.7-cp38-none-win_amd64.whl", hash = "sha256:bd765c06c359d8a814b90f948538f957fa8a1f55ad1aaffcdc5771996aaea061"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:7dd9e1e46c0776eee9e0649e3ae9584ea368d96851bcaeba18e217fa5d755283"}, - {file = "orjson-3.6.7-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:c4b4f20a1e3df7e7c83717aff0ef4ab69e42ce2fb1f5234682f618153c458406"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:7107a5673fd0b05adbb58bf71c1578fc84d662d29c096eb6d998982c8635c221"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a08b6940dd9a98ccf09785890112a0f81eadb4f35b51b9a80736d1725437e22c"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:f5d1648e5a9d1070f3628a69a7c6c17634dbb0caf22f2085eca6910f7427bf1f"}, - {file = "orjson-3.6.7-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:e6201494e8dff2ce7fd21da4e3f6dfca1a3fed38f9dcefc972f552f6596a7621"}, - {file = "orjson-3.6.7-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:70d0386abe02879ebaead2f9632dd2acb71000b4721fd8c1a2fb8c031a38d4d5"}, - {file = "orjson-3.6.7-cp39-none-win_amd64.whl", hash = "sha256:d9a3288861bfd26f3511fb4081561ca768674612bac59513cb9081bb61fcc87f"}, - {file = "orjson-3.6.7.tar.gz", hash = "sha256:a4bb62b11289b7620eead2f25695212e9ac77fcfba76f050fa8a540fb5c32401"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_7_x86_64.whl", hash = "sha256:3a287a650458de2211db03681b71c3e5cb2212b62f17a39df8ad99fc54855d0f"}, + {file = "orjson-3.6.8-cp310-cp310-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:5204e25c12cea58e524fc82f7c27ed0586f592f777b33075a92ab7b3eb3687c2"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77e8386393add64f959c044e0fb682364fd0e611a6f477aa13f0e6a733bd6a28"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:279f2d2af393fdf8601020744cb206b91b54ad60fb8401e0761819c7bda1f4e4"}, + {file = "orjson-3.6.8-cp310-cp310-manylinux_2_24_x86_64.whl", hash = "sha256:c31c9f389be7906f978ed4192eb58a4b74a37ad60556a0b88ddc47c576697770"}, + {file = "orjson-3.6.8-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0db5c5a0c5b89f092d52f6e5a3701660a9d6ffa9e2968b3ce17c2bc4f5eb0414"}, + {file = "orjson-3.6.8-cp310-none-win_amd64.whl", hash = "sha256:eb22485847b9a0c4bbedc668df860126ac931edbed1d456cf41a59f3cb961ed8"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_7_x86_64.whl", hash = "sha256:1a5fe569310bc819279bd4d5f2c349910b104ed3207936246dd5d5e0b085e74a"}, + {file = "orjson-3.6.8-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:ccb356a47ab1067cd3549847e9db1d279a63fe0482d315b3ffd6e7abef35ef77"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ab29c069c222248ce302a25855b4e1664f9436e8ae5a131fb0859daf31676d2b"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d2b5e4cba9e774ac011071d9d27760f97f4b8cd46003e971d122e712f971345"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:c311ec504414d22834d5b972a209619925b48263856a11a14d90230f9682d49c"}, + {file = "orjson-3.6.8-cp37-cp37m-manylinux_2_24_x86_64.whl", hash = "sha256:a3dfec7950b90fb8d143743503ee53fa06b32e6068bdea792fc866284da3d71d"}, + {file = "orjson-3.6.8-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:b890dbbada2cbb26eb29bd43a848426f007f094bb0758df10dfe7a438e1cb4b4"}, + {file = "orjson-3.6.8-cp37-none-win_amd64.whl", hash = "sha256:9143ae2c52771525be9ad11a7a8cc8e7fd75391b107e7e644a9e0050496f6b4f"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_7_x86_64.whl", hash = "sha256:33a82199fd42f6436f833e210ae5129c922a5c355629356ca7a8e82964da7285"}, + {file = "orjson-3.6.8-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:90159ea8b9a5a2a98fa33dc7b421cfac4d2ae91ba5e1058f5909e7f059f6b467"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:656fbe15d9ef0733e740d9def78f4fdb4153102f4836ee774a05123499005931"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7be3be6153843e0f01351b1313a5ad4723595427680dac2dfff22a37e652ce02"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:dd24f66b6697ee7424f7da575ec6cbffc8ede441114d53470949cda4d97c6e56"}, + {file = "orjson-3.6.8-cp38-cp38-manylinux_2_24_x86_64.whl", hash = "sha256:b07c780f7345ecf5901356dc21dee0669defc489c38ce7b9ab0f5e008cc0385c"}, + {file = "orjson-3.6.8-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ea32015a5d8a4ce00d348a0de5dc7040e0ad58f970a8fcbb5713a1eac129e493"}, + {file = "orjson-3.6.8-cp38-none-win_amd64.whl", hash = "sha256:c5a3e382194c838988ec128a26b08aa92044e5e055491cc4056142af0c1c54d7"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_7_x86_64.whl", hash = "sha256:83a8424e857ae1bf53530e88b4eb2f16ca2b489073b924e655f1575cacd7f52a"}, + {file = "orjson-3.6.8-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl", hash = "sha256:81e1a6a2d67f15007dadacbf9ba5d3d79237e5e33786c028557fe5a2b72f1c9a"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:137b539881c77866eba86ff6a11df910daf2eb9ab8f1acae62f879e83d7c38af"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cbd358f3b3ad539a27e36900e8e7d172d0e1b72ad9dd7d69544dcbc0f067ee7"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:6ab94701542d40b90903ecfc339333f458884979a01cb9268bc662cc67a5f6d8"}, + {file = "orjson-3.6.8-cp39-cp39-manylinux_2_24_x86_64.whl", hash = "sha256:32b6f26593a9eb606b40775826beb0dac152e3d224ea393688fced036045a821"}, + {file = "orjson-3.6.8-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:afd9e329ebd3418cac3cd747769b1d52daa25fa672bbf414ab59f0e0881b32b9"}, + {file = "orjson-3.6.8-cp39-none-win_amd64.whl", hash = "sha256:0c89b419914d3d1f65a1b0883f377abe42a6e44f6624ba1c63e8846cbfc2fa60"}, + {file = "orjson-3.6.8.tar.gz", hash = "sha256:e19d23741c5de13689bb316abfccea15a19c264e3ec8eb332a5319a583595ace"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, @@ -996,71 +928,13 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, + {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, + {file = "platformdirs-2.5.2.tar.gz", hash = "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19"}, ] pluggy = [ {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] -psycopg2-binary = [ - {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:539b28661b71da7c0e428692438efbcd048ca21ea81af618d845e06ebfd29478"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6e82d38390a03da28c7985b394ec3f56873174e2c88130e6966cb1c946508e65"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:57804fc02ca3ce0dbfbef35c4b3a4a774da66d66ea20f4bda601294ad2ea6092"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_aarch64.whl", hash = "sha256:083a55275f09a62b8ca4902dd11f4b33075b743cf0d360419e2051a8a5d5ff76"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-manylinux_2_24_ppc64le.whl", hash = "sha256:0a29729145aaaf1ad8bafe663131890e2111f13416b60e460dae0a96af5905c9"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:3a79d622f5206d695d7824cbf609a4f5b88ea6d6dab5f7c147fc6d333a8787e4"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:090f3348c0ab2cceb6dfbe6bf721ef61262ddf518cd6cc6ecc7d334996d64efa"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:a9e1f75f96ea388fbcef36c70640c4efbe4650658f3d6a2967b4cc70e907352e"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c3ae8e75eb7160851e59adc77b3a19a976e50622e44fd4fd47b8b18208189d42"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win32.whl", hash = "sha256:7b1e9b80afca7b7a386ef087db614faebbf8839b7f4db5eb107d0f1a53225029"}, - {file = "psycopg2_binary-2.9.3-cp310-cp310-win_amd64.whl", hash = "sha256:8b344adbb9a862de0c635f4f0425b7958bf5a4b927c8594e6e8d261775796d53"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:e847774f8ffd5b398a75bc1c18fbb56564cda3d629fe68fd81971fece2d3c67e"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68641a34023d306be959101b345732360fc2ea4938982309b786f7be1b43a4a1"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3303f8807f342641851578ee7ed1f3efc9802d00a6f83c101d21c608cb864460"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_aarch64.whl", hash = "sha256:e3699852e22aa68c10de06524a3721ade969abf382da95884e6a10ff798f9281"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-manylinux_2_24_ppc64le.whl", hash = "sha256:526ea0378246d9b080148f2d6681229f4b5964543c170dd10bf4faaab6e0d27f"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:b1c8068513f5b158cf7e29c43a77eb34b407db29aca749d3eb9293ee0d3103ca"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:15803fa813ea05bef089fa78835118b5434204f3a17cb9f1e5dbfd0b9deea5af"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_ppc64le.whl", hash = "sha256:152f09f57417b831418304c7f30d727dc83a12761627bb826951692cc6491e57"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:404224e5fef3b193f892abdbf8961ce20e0b6642886cfe1fe1923f41aaa75c9d"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win32.whl", hash = "sha256:1f6b813106a3abdf7b03640d36e24669234120c72e91d5cbaeb87c5f7c36c65b"}, - {file = "psycopg2_binary-2.9.3-cp36-cp36m-win_amd64.whl", hash = "sha256:2d872e3c9d5d075a2e104540965a1cf898b52274a5923936e5bfddb58c59c7c2"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:10bb90fb4d523a2aa67773d4ff2b833ec00857f5912bafcfd5f5414e45280fb1"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:874a52ecab70af13e899f7847b3e074eeb16ebac5615665db33bce8a1009cf33"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a29b3ca4ec9defec6d42bf5feb36bb5817ba3c0230dd83b4edf4bf02684cd0ae"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_aarch64.whl", hash = "sha256:12b11322ea00ad8db8c46f18b7dfc47ae215e4df55b46c67a94b4effbaec7094"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-manylinux_2_24_ppc64le.whl", hash = "sha256:53293533fcbb94c202b7c800a12c873cfe24599656b341f56e71dd2b557be063"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c381bda330ddf2fccbafab789d83ebc6c53db126e4383e73794c74eedce855ef"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:9d29409b625a143649d03d0fd7b57e4b92e0ecad9726ba682244b73be91d2fdb"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:183a517a3a63503f70f808b58bfbf962f23d73b6dccddae5aa56152ef2bcb232"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:15c4e4cfa45f5a60599d9cec5f46cd7b1b29d86a6390ec23e8eebaae84e64554"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win32.whl", hash = "sha256:adf20d9a67e0b6393eac162eb81fb10bc9130a80540f4df7e7355c2dd4af9fba"}, - {file = "psycopg2_binary-2.9.3-cp37-cp37m-win_amd64.whl", hash = "sha256:2f9ffd643bc7349eeb664eba8864d9e01f057880f510e4681ba40a6532f93c71"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:def68d7c21984b0f8218e8a15d514f714d96904265164f75f8d3a70f9c295667"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dffc08ca91c9ac09008870c9eb77b00a46b3378719584059c034b8945e26b272"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:280b0bb5cbfe8039205c7981cceb006156a675362a00fe29b16fbc264e242834"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_aarch64.whl", hash = "sha256:af9813db73395fb1fc211bac696faea4ca9ef53f32dc0cfa27e4e7cf766dcf24"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_24_ppc64le.whl", hash = "sha256:63638d875be8c2784cfc952c9ac34e2b50e43f9f0a0660b65e2a87d656b3116c"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:ffb7a888a047696e7f8240d649b43fb3644f14f0ee229077e7f6b9f9081635bd"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0c9d5450c566c80c396b7402895c4369a410cab5a82707b11aee1e624da7d004"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:d1c1b569ecafe3a69380a94e6ae09a4789bbb23666f3d3a08d06bbd2451f5ef1"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8fc53f9af09426a61db9ba357865c77f26076d48669f2e1bb24d85a22fb52307"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win32.whl", hash = "sha256:6472a178e291b59e7f16ab49ec8b4f3bdada0a879c68d3817ff0963e722a82ce"}, - {file = "psycopg2_binary-2.9.3-cp38-cp38-win_amd64.whl", hash = "sha256:35168209c9d51b145e459e05c31a9eaeffa9a6b0fd61689b48e07464ffd1a83e"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-macosx_10_14_x86_64.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:47133f3f872faf28c1e87d4357220e809dfd3fa7c64295a4a148bcd1e6e34ec9"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:91920527dea30175cc02a1099f331aa8c1ba39bf8b7762b7b56cbf54bc5cce42"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:887dd9aac71765ac0d0bac1d0d4b4f2c99d5f5c1382d8b770404f0f3d0ce8a39"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_aarch64.whl", hash = "sha256:1f14c8b0942714eb3c74e1e71700cbbcb415acbc311c730370e70c578a44a25c"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-manylinux_2_24_ppc64le.whl", hash = "sha256:7af0dd86ddb2f8af5da57a976d27cd2cd15510518d582b478fbb2292428710b4"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93cd1967a18aa0edd4b95b1dfd554cf15af657cb606280996d393dadc88c3c35"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:bda845b664bb6c91446ca9609fc69f7db6c334ec5e4adc87571c34e4f47b7ddb"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:01310cf4cf26db9aea5158c217caa92d291f0500051a6469ac52166e1a16f5b7"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99485cab9ba0fa9b84f1f9e1fef106f44a46ef6afdeec8885e0b88d0772b49e8"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win32.whl", hash = "sha256:46f0e0a6b5fa5851bbd9ab1bc805eef362d3a230fbdfbc209f4a236d0a7a990d"}, - {file = "psycopg2_binary-2.9.3-cp39-cp39-win_amd64.whl", hash = "sha256:accfe7e982411da3178ec690baaceaad3c278652998b2c45828aaac66cd8285f"}, -] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, @@ -1129,8 +1003,8 @@ tomli = [ {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] typing-extensions = [ - {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, - {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, + {file = "typing_extensions-4.2.0-py3-none-any.whl", hash = "sha256:6657594ee297170d19f67d55c05852a874e7eb634f4f753dbd667855e07c1708"}, + {file = "typing_extensions-4.2.0.tar.gz", hash = "sha256:f1c24655a0da0d1b67f07e17a5e6b2a105894e6824b92096378bb3668ef02376"}, ] uvloop = [ {file = "uvloop-0.16.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:6224f1401025b748ffecb7a6e2652b17768f30b1a6a3f7b44660e5b5b690b12d"}, diff --git a/packages/plugins/minos-http-aiohttp/pyproject.toml b/packages/plugins/minos-http-aiohttp/pyproject.toml index bc4bfb877..d7e929b79 100644 --- a/packages/plugins/minos-http-aiohttp/pyproject.toml +++ b/packages/plugins/minos-http-aiohttp/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-http-aiohttp" -version = "0.7.0.dev1" +version = "0.7.0.dev4" description = "The aiohttp plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py b/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py index 84740e242..e233dfdee 100644 --- a/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py +++ b/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev2" +__version__ = "0.7.0.dev4" from .builders import ( GraphQLSchemaBuilder, diff --git a/packages/plugins/minos-router-graphql/poetry.lock b/packages/plugins/minos-router-graphql/poetry.lock index 4ab43836d..ff7a7d4f3 100644 --- a/packages/plugins/minos-router-graphql/poetry.lock +++ b/packages/plugins/minos-router-graphql/poetry.lock @@ -73,7 +73,7 @@ python-versions = "*" [[package]] name = "click" -version = "8.1.2" +version = "8.1.3" description = "Composable command line interface toolkit" category = "dev" optional = false @@ -142,7 +142,7 @@ yaml = ["pyyaml"] [[package]] name = "fastavro" -version = "1.4.10" +version = "1.4.11" description = "Fast read/write of AVRO files" category = "main" optional = false @@ -207,7 +207,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -229,7 +229,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -460,8 +460,8 @@ cached-property = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] click = [ - {file = "click-8.1.2-py3-none-any.whl", hash = "sha256:24e1a4a9ec5bf6299411369b208c1df2188d9eb8d916302fe6bf03faed227f1e"}, - {file = "click-8.1.2.tar.gz", hash = "sha256:479707fe14d9ec9a0757618b7a100a0ae4c4e236fac5b7f80ca68028141a1a72"}, + {file = "click-8.1.3-py3-none-any.whl", hash = "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48"}, + {file = "click-8.1.3.tar.gz", hash = "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e"}, ] colorama = [ {file = "colorama-0.4.4-py2.py3-none-any.whl", hash = "sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2"}, @@ -556,22 +556,22 @@ dependency-injector = [ {file = "dependency_injector-4.39.1-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ca126bbed370b8c002c859ebeb76f6d83eba2d7fb5d66f37f47cfc19661d2889"}, ] fastavro = [ - {file = "fastavro-1.4.10-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:f225c81e869b3cefef6f2b478cd452693181ed7e645be3cea4d82024354ecaa0"}, - {file = "fastavro-1.4.10-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7669302c9124b7cd6c1bdff80c77116b2290c984814077fb7d01d7389586054"}, - {file = "fastavro-1.4.10-cp310-cp310-win_amd64.whl", hash = "sha256:995525bdfbdfef205ea148b5bc6a9fe5ccf921931123c39d9aad75a2b661681e"}, - {file = "fastavro-1.4.10-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:64244c53f1e4853184c2f7383d0332e1dcb34c38c05e6613530ade0378e8acfc"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c60965da6dc7a91e00ccd84d84797fad746555f44e8a816c4cc460fb231c44fe"}, - {file = "fastavro-1.4.10-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10eb25378f37dc00c10e83c4c0442c1a6d1b871f74a6dfdfc12b6447962bbdd0"}, - {file = "fastavro-1.4.10-cp37-cp37m-win_amd64.whl", hash = "sha256:d5719adf6045fc743de5fa738d561a81e58dc782c94f1b16cb21b5dd6253e7fd"}, - {file = "fastavro-1.4.10-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:24c4a1a8cc92e135ecfcd9cbd1f6cfa088cbc74d78c18e02a609cb11fa33778d"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0934490b0c3bcfd6bcbacbcb5144c6b5e4298cda209fbb17c856adf5405127dd"}, - {file = "fastavro-1.4.10-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a23763d73412c077aee401a0368c64cbc23859e26711dbae78a3cf0227f65165"}, - {file = "fastavro-1.4.10-cp38-cp38-win_amd64.whl", hash = "sha256:09f1dfdd8192ae09e0f477d1f024d8054fccdb099ad495d2a796bcee3cadebd1"}, - {file = "fastavro-1.4.10-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:0c6695753fa3035bbd0fa5cb21bf1b5dad39483c669b32ca0bb55fb07c1ccc87"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:35f960dbba04647d8d6d5616f879622d2a1e8a84eb2d2e02a883a22e0803463a"}, - {file = "fastavro-1.4.10-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9660878ca01e3dbbee12385c5902a2b6b12ecbb5af4733d1026175a14b1ef67f"}, - {file = "fastavro-1.4.10-cp39-cp39-win_amd64.whl", hash = "sha256:64cbd386e408b3bcb2de53b1f847163073eb0d0d0338db65f76051c6ba9a9bc1"}, - {file = "fastavro-1.4.10.tar.gz", hash = "sha256:a24f9dd803c44bfb599476b000f9bd0088f7ac2401e6c20818f38d8af12785a0"}, + {file = "fastavro-1.4.11-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:44f01008f95d685edacc4b10366c755d25612df00924349f7d34a29f08522ce3"}, + {file = "fastavro-1.4.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18f5e736d12e67348f253da8a332d7c3b483ca04f2b6e772befa79d1a46bac9d"}, + {file = "fastavro-1.4.11-cp310-cp310-win_amd64.whl", hash = "sha256:8dca11bc3191cd7de0a3c4b76a70dac493356a219e96ebcde0def1f06faddef7"}, + {file = "fastavro-1.4.11-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:7a2a0bf03686f9d860e8f8476be000f5b3e6cc9af6853dbabab2ef9cfa5dc3a0"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0c17e3decfac260e1be4d02d1903d2483eec2f3ce7f92c9b808a0f6a81572c4b"}, + {file = "fastavro-1.4.11-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19ba25c6529f50722a7618cc4ca24c7d265def57fd9f94e4e554e1df8cce38d2"}, + {file = "fastavro-1.4.11-cp37-cp37m-win_amd64.whl", hash = "sha256:ceaba04da9419f40899a670eb62eb373a127b511bb8e3ae4f6f1f23ec49bd0e4"}, + {file = "fastavro-1.4.11-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:732eab3a1ae5d2c3f4b52e747c55bcc41c4df0eb7e8a395038080741a3c0a934"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c03d3c802b71f44e7b3442abae961bba996258244bd222b242ad1e5cb7754e57"}, + {file = "fastavro-1.4.11-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cb7475a9b25b9f8aebe7eb756dafedd0369434571062f3883d894281befd7c"}, + {file = "fastavro-1.4.11-cp38-cp38-win_amd64.whl", hash = "sha256:ce0776f54591aef90bcd02bd919964abe4c2ad2a10a4336c3a1b66cef289b41c"}, + {file = "fastavro-1.4.11-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:621e72cc365c9539d7590e7b43e48a62e6bfb4c2de7c16837fed54d113d7312c"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:842b25782f911ee8c626f9d9fedc2ef01aeac272536fe90ee6d45b2ae7cdb024"}, + {file = "fastavro-1.4.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f8491bfcba25c9d661289f884688e5a4f56f2ee389a240d0ad02692495a9a087"}, + {file = "fastavro-1.4.11-cp39-cp39-win_amd64.whl", hash = "sha256:c94130a8c8d80073eb0276844915aa5e928ae322024e76dc57943542ccda211c"}, + {file = "fastavro-1.4.11.tar.gz", hash = "sha256:7c64332ad52de0134be9a933ca986514c3ff85c63d54bc5398c31f0498ac1820"}, ] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, diff --git a/packages/plugins/minos-router-graphql/pyproject.toml b/packages/plugins/minos-router-graphql/pyproject.toml index 864d24e6b..751fc5eb4 100644 --- a/packages/plugins/minos-router-graphql/pyproject.toml +++ b/packages/plugins/minos-router-graphql/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-router-graphql" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The graphql plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/poetry.lock b/poetry.lock index 9b901c98f..4ced573c3 100644 --- a/poetry.lock +++ b/poetry.lock @@ -547,7 +547,7 @@ python-versions = "*" [[package]] name = "minos-broker-kafka" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The kafka plugin of the Minos Framework" category = "main" optional = false @@ -567,7 +567,7 @@ url = "packages/plugins/minos-broker-kafka" [[package]] name = "minos-broker-rabbitmq" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The rabbitmq plugin of the Minos Framework" category = "main" optional = false @@ -585,7 +585,7 @@ url = "packages/plugins/minos-broker-rabbitmq" [[package]] name = "minos-database-aiopg" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The aiopg plugin of the Minos Framework" category = "main" optional = false @@ -605,7 +605,7 @@ url = "packages/plugins/minos-database-aiopg" [[package]] name = "minos-database-lmdb" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The lmdb plugin of the Minos Framework" category = "main" optional = false @@ -623,7 +623,7 @@ url = "packages/plugins/minos-database-lmdb" [[package]] name = "minos-discovery-kong" -version = "0.7.0.dev3" +version = "0.7.0.dev4" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" category = "main" optional = false @@ -643,7 +643,7 @@ url = "packages/plugins/minos-discovery-kong" [[package]] name = "minos-discovery-minos" -version = "0.7.0.dev1" +version = "0.7.0.dev4" description = "The minos-discovery plugin of the Minos Framework" category = "main" optional = false @@ -661,7 +661,7 @@ url = "packages/plugins/minos-discovery-minos" [[package]] name = "minos-http-aiohttp" -version = "0.7.0.dev1" +version = "0.7.0.dev4" description = "The aiohttp plugin of the Minos Framework" category = "main" optional = false @@ -681,7 +681,7 @@ url = "packages/plugins/minos-http-aiohttp" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -699,7 +699,7 @@ url = "packages/core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The common core of the Minos Framework" category = "main" optional = false @@ -721,7 +721,7 @@ url = "packages/core/minos-microservice-common" [[package]] name = "minos-microservice-cqrs" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The CQRS pattern of the Minos Framework" category = "main" optional = false @@ -739,7 +739,7 @@ url = "packages/core/minos-microservice-cqrs" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -756,7 +756,7 @@ url = "packages/core/minos-microservice-networks" [[package]] name = "minos-microservice-saga" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The SAGA pattern of the Minos Framework" category = "main" optional = false @@ -775,7 +775,7 @@ url = "packages/core/minos-microservice-saga" [[package]] name = "minos-router-graphql" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "The graphql plugin of the Minos Framework" category = "main" optional = false diff --git a/pyproject.toml b/pyproject.toml index 1786bb1d1..3bef0da05 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-python" -version = "0.7.0.dev2" +version = "0.7.0.dev4" description = "" authors = ["Minos Framework Devs "] license = "MIT" From fc5cdcd00518a96bbdfeecc68303e2f2820df312 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 11 May 2022 12:32:52 +0200 Subject: [PATCH 321/324] v0.7.0 --- README.md | 67 +++++++++++-------- .../minos-microservice-aggregate/HISTORY.md | 16 ++++- .../minos/aggregate/__init__.py | 2 +- .../minos-microservice-aggregate/poetry.lock | 12 ++-- .../pyproject.toml | 6 +- .../core/minos-microservice-common/HISTORY.md | 20 +++++- .../minos/common/__init__.py | 2 +- .../minos-microservice-common/poetry.lock | 6 +- .../minos-microservice-common/pyproject.toml | 2 +- .../core/minos-microservice-cqrs/HISTORY.md | 7 ++ .../minos/cqrs/__init__.py | 2 +- .../core/minos-microservice-cqrs/poetry.lock | 14 ++-- .../minos-microservice-cqrs/pyproject.toml | 8 +-- .../minos-microservice-networks/HISTORY.md | 19 +++++- .../minos/networks/__init__.py | 2 +- .../minos-microservice-networks/poetry.lock | 10 +-- .../pyproject.toml | 4 +- .../core/minos-microservice-saga/HISTORY.md | 9 +++ .../minos/saga/__init__.py | 2 +- .../core/minos-microservice-saga/poetry.lock | 14 ++-- .../minos-microservice-saga/pyproject.toml | 8 +-- .../plugins/minos-broker-kafka/HISTORY.md | 9 ++- .../minos/plugins/kafka/__init__.py | 2 +- .../plugins/minos-broker-kafka/poetry.lock | 12 ++-- .../plugins/minos-broker-kafka/pyproject.toml | 6 +- .../plugins/minos-broker-rabbitmq/HISTORY.md | 9 ++- .../minos/plugins/rabbitmq/__init__.py | 2 +- .../plugins/minos-broker-rabbitmq/poetry.lock | 12 ++-- .../minos-broker-rabbitmq/pyproject.toml | 6 +- .../plugins/minos-database-aiopg/HISTORY.md | 14 ++++ .../minos/plugins/aiopg/__init__.py | 2 +- .../plugins/minos-database-aiopg/poetry.lock | 14 ++-- .../minos-database-aiopg/pyproject.toml | 8 +-- .../plugins/minos-database-lmdb/HISTORY.md | 5 ++ .../minos/plugins/lmdb/__init__.py | 2 +- .../plugins/minos-database-lmdb/poetry.lock | 16 ++--- .../minos-database-lmdb/pyproject.toml | 6 +- .../plugins/minos-discovery-kong/HISTORY.md | 6 +- .../minos/plugins/kong/__init__.py | 2 +- .../plugins/minos-discovery-kong/poetry.lock | 12 ++-- .../minos-discovery-kong/pyproject.toml | 6 +- .../plugins/minos-discovery-minos/HISTORY.md | 9 ++- .../minos/plugins/minos_discovery/__init__.py | 2 +- .../plugins/minos-discovery-minos/poetry.lock | 12 ++-- .../minos-discovery-minos/pyproject.toml | 6 +- .../plugins/minos-http-aiohttp/HISTORY.md | 9 ++- .../minos/plugins/aiohttp/__init__.py | 2 +- .../plugins/minos-http-aiohttp/poetry.lock | 12 ++-- .../plugins/minos-http-aiohttp/pyproject.toml | 6 +- .../plugins/minos-router-graphql/HISTORY.md | 7 ++ .../minos/plugins/graphql/__init__.py | 2 +- .../plugins/minos-router-graphql/poetry.lock | 12 ++-- .../minos-router-graphql/pyproject.toml | 6 +- poetry.lock | 44 ++++++------ pyproject.toml | 2 +- 55 files changed, 322 insertions(+), 192 deletions(-) diff --git a/README.md b/README.md index 11d551960..d08af18a2 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ [![GitHub Repo stars](https://img.shields.io/github/stars/minos-framework/minos-python?label=GitHub)] [![PyPI Latest Release](https://img.shields.io/pypi/v/minos-microservice-common.svg)](https://pypi.org/project/minos-microservice-common/) -[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://minos-framework.github.io/minos-python) +[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://github.com/minos-framework/minos-python/tree/main) [![License](https://img.shields.io/github/license/minos-framework/minos-python.svg)](https://github.com/minos-framework/minos-python/blob/main/LICENSE) [![Coverage](https://codecov.io/github/minos-framework/minos-python/coverage.svg?branch=main)](https://codecov.io/gh/minos-framework/minos-python) [![Stack Overflow](https://img.shields.io/badge/Stack%20Overflow-Ask%20a%20question-green)](https://stackoverflow.com/questions/tagged/minos) @@ -62,7 +62,7 @@ For more information, visit the [`minos-cli`](https://github.com/minos-framework ## Documentation -The best place to start learning how to use the Minos Framework is at [Minos Learn](https://www.minos.run/learn/). The official API Reference is publicly available at the [GitHub Pages](https://minos-framework.github.io/minos-python). +The best place to start learning how to use the Minos Framework is at [Minos Learn](https://www.minos.run/learn/). The official API Reference is publicly available at the [GitHub Pages](https://github.com/minos-framework/minos-python/tree/main). ## QuickStart @@ -136,7 +136,9 @@ pip install \ minos-microservice-networks \ minos-microservice-saga \ minos-broker-kafka \ - minos-http-aiohttp + minos-http-aiohttp \ + minos-http-aiopg \ + minos-http-lmbdb ``` ### Configure a Microservice @@ -165,26 +167,28 @@ aggregate: entities: - main.Foo repositories: - transaction: minos.aggregate.PostgreSqlTransactionRepository - event: minos.aggregate.PostgreSqlEventRepository - snapshot: minos.aggregate.PostgreSqlSnapshotRepository + transaction: minos.aggregate.DatabaseTransactionRepository + event: minos.aggregate.DatabaseEventRepository + snapshot: minos.aggregate.DatabaseSnapshotRepository databases: default: + client: minos.plugins.aiopg.AiopgDatabaseClient database: foo_db user: minos password: min0s saga: + client: minos.plugins.lmdb.LmdbDatabaseClient path: "./foo.lmdb" interfaces: broker: port: minos.networks.BrokerPort publisher: client: minos.plugins.kafka.KafkaBrokerPublisher - queue: minos.networks.PostgreSqlBrokerPublisherQueue + queue: minos.networks.DatabaseBrokerPublisherQueue subscriber: client: minos.plugins.kafka.KafkaBrokerSubscriber - queue: minos.networks.PostgreSqlBrokerSubscriberQueue - validator: minos.networks.PostgreSqlBrokerSubscriberDuplicateValidator + queue: minos.networks.DatabaseBrokerSubscriberQueue + validator: minos.networks.DatabaseBrokerSubscriberDuplicateValidator http: port: minos.networks.HttpPort connector: @@ -193,8 +197,8 @@ interfaces: periodic: port: minos.networks.PeriodicPort pools: - lock: minos.common.PostgreSqlLockPool - databasse: minos.common.PostgreSqlPool + lock: minos.common.DatabaseLockPool + database: minos.common.DatabaseClientPool broker: minos.networks.BrokerClientPool saga: manager: minos.saga.SagaManager @@ -981,26 +985,28 @@ aggregate: entities: - main.FooBar repositories: - transaction: minos.aggregate.PostgreSqlTransactionRepository - event: minos.aggregate.PostgreSqlEventRepository - snapshot: minos.aggregate.PostgreSqlSnapshotRepository + transaction: minos.aggregate.DatabaseTransactionRepository + event: minos.aggregate.DatabaseEventRepository + snapshot: minos.aggregate.DatabaseSnapshotRepository databases: default: + client: minos.plugins.aiopg.AiopgDatabaseClient database: foobar_db user: minos password: min0s saga: + client: minos.plugins.lmdb.LmdbDatabaseClient path: "./foobar.lmdb" interfaces: broker: port: minos.networks.BrokerPort publisher: client: minos.plugins.kafka.KafkaBrokerPublisher - queue: minos.networks.PostgreSqlBrokerPublisherQueue + queue: minos.networks.DatabaseBrokerPublisherQueue subscriber: client: minos.plugins.kafka.KafkaBrokerSubscriber - queue: minos.networks.PostgreSqlBrokerSubscriberQueue - validator: minos.networks.PostgreSqlBrokerSubscriberDuplicateValidator + queue: minos.networks.DatabaseBrokerSubscriberQueue + validator: minos.networks.DatabaseBrokerSubscriberDuplicateValidator http: port: minos.networks.HttpPort connector: @@ -1009,8 +1015,8 @@ interfaces: periodic: port: minos.networks.PeriodicPort pools: - lock: minos.common.PostgreSqlLockPool - databasse: minos.common.PostgreSqlPool + lock: minos.common.DatabaseLockPool + database: minos.common.DatabaseClientPool broker: minos.networks.BrokerClientPool saga: manager: minos.saga.SagaManager @@ -1123,21 +1129,24 @@ This project follows a modular structure based on python packages. The core packages provide the base implementation of the framework. -* [minos-microservice-aggregate](https://minos-framework.github.io/minos-python/packages/core/minos-microservice-aggregate): The Aggregate pattern implementation. -* [minos-microservice-common](https://minos-framework.github.io/minos-python/packages/core/minos-microservice-common): The common core package. -* [minos-microservice-cqrs](https://minos-framework.github.io/minos-python/packages/core/minos-microservice-cqrs): The CQRS pattern implementation. -* [minos-microservice-networks](https://minos-framework.github.io/minos-python/packages/core/minos-microservice-networks): The networks core package. -* [minos-microservice-saga](https://minos-framework.github.io/minos-python/packages/core/minos-microservice-saga): The SAGA pattern implementation. +* [minos-microservice-aggregate](https://github.com/minos-framework/minos-python/tree/main/packages/core/minos-microservice-aggregate): The Aggregate pattern implementation. +* [minos-microservice-common](https://github.com/minos-framework/minos-python/tree/main/packages/core/minos-microservice-common): The common core package. +* [minos-microservice-cqrs](https://github.com/minos-framework/minos-python/tree/main/packages/core/minos-microservice-cqrs): The CQRS pattern implementation. +* [minos-microservice-networks](https://github.com/minos-framework/minos-python/tree/main/packages/core/minos-microservice-networks): The networks core package. +* [minos-microservice-saga](https://github.com/minos-framework/minos-python/tree/main/packages/core/minos-microservice-saga): The SAGA pattern implementation. ### Plugins The plugin packages provide connectors to external technologies like brokers, discovery services, databases, serializers and so on. -* [minos-broker-kafka](https://minos-framework.github.io/minos-python/packages/plugins/minos-broker-kafka): The `kafka` plugin package. -* [minos-broker-rabbitmq](https://minos-framework.github.io/minos-python/packages/plugins/minos-broker-rabbitmq): The `rabbitmq` plugin package. -* [minos-discovery-minos](https://minos-framework.github.io/minos-python/packages/plugins/minos-discovery-minos): The `minos-discovery` plugin package. -* [minos-http-aiohttp](https://minos-framework.github.io/minos-python/packages/plugins/minos-http-aiohttp): The `aiohttp` plugin package. -* [minos-router-graphql](https://minos-framework.github.io/minos-python/packages/plugins/minos-router-graphql): The `grapqhl` plugin package. +* [minos-broker-kafka](https://github.com/minos-framework/minos-python/tree/main/packages/plugins/minos-broker-kafka): The `kafka` plugin package. +* [minos-broker-rabbitmq](https://github.com/minos-framework/minos-python/tree/main/packages/plugins/minos-broker-rabbitmq): The `rabbitmq` plugin package. +* [minos-database-aiopg](https://github.com/minos-framework/minos-python/tree/main/packages/plugins/minos-database-aiopg): The `aiopg` plugin package. +* [minos-database-lmdb](https://github.com/minos-framework/minos-python/tree/main/packages/plugins/minos-database-lmdb): The `lmdb` plugin package. +* [minos-discovery-kong](https://github.com/minos-framework/minos-python/tree/main/packages/plugins/minos-discovery-kong): The `kong` plugin package. +* [minos-discovery-minos](https://github.com/minos-framework/minos-python/tree/main/packages/plugins/minos-discovery-minos): The `minos-discovery` plugin package. +* [minos-http-aiohttp](https://github.com/minos-framework/minos-python/tree/main/packages/plugins/minos-http-aiohttp): The `aiohttp` plugin package. +* [minos-router-graphql](https://github.com/minos-framework/minos-python/tree/main/packages/plugins/minos-router-graphql): The `grapqhl` plugin package. ## Source Code diff --git a/packages/core/minos-microservice-aggregate/HISTORY.md b/packages/core/minos-microservice-aggregate/HISTORY.md index da6af7328..23f7ba1fa 100644 --- a/packages/core/minos-microservice-aggregate/HISTORY.md +++ b/packages/core/minos-microservice-aggregate/HISTORY.md @@ -95,4 +95,18 @@ ## 0.6.0 (2022-03-28) * Replace `dependency-injector`'s injection classes by the ones provided by the `minos.common.injections` module. -* Be compatible with latest `minos.common.Config` API. \ No newline at end of file +* Be compatible with latest `minos.common.Config` API. + +## 0.7.0 (2022-05-11) + +* Rename `PostgreSqlEventRepository` as `DatabaseEventRepository`. +* Add `EventDatabaseOperationFactory` as the abstract class to be implemented by database clients. +* Move `PostgreSqlSnapshotQueryBuilder` to the `minos-database-aiopg` package. +* Rename `PostgreSqlSnapshotRepository` as `DatabaseSnapshotRepository`. +* Add `SnapshotDatabaseOperationFactory` as the abstract class to be implemented by database clients. +* Remove `PostgreSqlSnapshotReader`, `PostgreSqlSnapshotSetup` and `PostgreSqlSnapshotWriter`. +* Rename `PostgreSqlTransactionRepository` as `DatabaseTransactionRepository`. +* Add `TransactionDatabaseOperationFactory` as the abstract class to be implemented by database clients. +* Unify documentation building pipeline across all `minos-python` packages. +* Fix documentation building warnings. +* Fix bug related with package building and additional files like `AUTHORS.md`, `HISTORY.md`, etc. \ No newline at end of file diff --git a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py index 485ebae0a..d2a62b0a1 100644 --- a/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py +++ b/packages/core/minos-microservice-aggregate/minos/aggregate/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .actions import ( Action, diff --git a/packages/core/minos-microservice-aggregate/poetry.lock b/packages/core/minos-microservice-aggregate/poetry.lock index 6ee724dac..320c8dbb3 100644 --- a/packages/core/minos-microservice-aggregate/poetry.lock +++ b/packages/core/minos-microservice-aggregate/poetry.lock @@ -199,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -221,7 +221,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -321,7 +321,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -399,7 +399,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "1b0305c24bc3b9e430a9fc9bf8ef83a979fc032672aeea3e57ab5bd96f5cb307" +content-hash = "bb4749d094a965e391cdb0fe9f4047fb174514d533e7c08855238d1e83cce3ed" [metadata.files] aiomisc = [ @@ -642,8 +642,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index 9bbb9219b..9b44086a9 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-aggregate" -version = "0.7.0.dev4" +version = "0.7.0" description = "The Aggregate pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } cached-property = "^1.5.2" [tool.poetry.dev-dependencies] diff --git a/packages/core/minos-microservice-common/HISTORY.md b/packages/core/minos-microservice-common/HISTORY.md index cd4549887..6f0baa6c6 100644 --- a/packages/core/minos-microservice-common/HISTORY.md +++ b/packages/core/minos-microservice-common/HISTORY.md @@ -302,4 +302,22 @@ routers: ## 0.6.1 (2022-04-01) -* Fix bug that didn't show the correct exception traceback when microservice failures occurred. \ No newline at end of file +* Fix bug that didn't show the correct exception traceback when microservice failures occurred. + +## 0.7.0 (2022-05-11) + +* Add `DatabaseClient`, `DatabaseClientBuilder` as the base client to execute operation over a database and the builder class. +* Rename `PostgreSqlPool` as `DatabaseClientPool`. +* Add `DatabaseOperation`, `ComposedDatabaseOperation` and `DatabaseOperationFactory` as the classes to build operations to be executed over the database. +* Add `ConnectionException`, `DatabaseClientException`, `IntegrityException`, `ProgrammingException` as the base exceptions to be raised by the `DatabaseClient`. +* Rename `PostgreSqlLock` and `PostgreSqlLockPool` as `DatabaseLock` and `DatabaseLockPool`. +* Rename `PostgreSqlMinosDatabase` as `DatabaseMixin`. +* Add `LockDatabaseOperationFactory` as the base operation factory for locking operations. +* Add `ManagementDatabaseOperationFactory` as the base operation factory for management operations (creation, deletion, etc.). +* Add `TypeHintParser` to unify `ModelType`'s type hints. +* Add `PoolException` as the base exception for pools. +* Add `PoolFactory` as the class with the purpose to build and manage `Pool` instances. +* Remove `MinosStorage` and move `MinosStorageLmdb` to the `minos-database-lmdb` package. +* Unify documentation building pipeline across all `minos-python` packages. +* Fix documentation building warnings. +* Fix bug related with package building and additional files like `AUTHORS.md`, `HISTORY.md`, etc. \ No newline at end of file diff --git a/packages/core/minos-microservice-common/minos/common/__init__.py b/packages/core/minos-microservice-common/minos/common/__init__.py index 8a62ffb30..c0dc48674 100644 --- a/packages/core/minos-microservice-common/minos/common/__init__.py +++ b/packages/core/minos-microservice-common/minos/common/__init__.py @@ -1,7 +1,7 @@ """The common core of the Minos Framework.""" __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .builders import ( BuildableMixin, diff --git a/packages/core/minos-microservice-common/poetry.lock b/packages/core/minos-microservice-common/poetry.lock index 3bc3d4647..f9b875d37 100644 --- a/packages/core/minos-microservice-common/poetry.lock +++ b/packages/core/minos-microservice-common/poetry.lock @@ -274,7 +274,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -590,8 +590,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, diff --git a/packages/core/minos-microservice-common/pyproject.toml b/packages/core/minos-microservice-common/pyproject.toml index ea8a30e2c..b98ed8919 100644 --- a/packages/core/minos-microservice-common/pyproject.toml +++ b/packages/core/minos-microservice-common/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" diff --git a/packages/core/minos-microservice-cqrs/HISTORY.md b/packages/core/minos-microservice-cqrs/HISTORY.md index 87647e2d5..59240e9a1 100644 --- a/packages/core/minos-microservice-cqrs/HISTORY.md +++ b/packages/core/minos-microservice-cqrs/HISTORY.md @@ -78,3 +78,10 @@ * Replace `dependency-injector`'s injection classes by the ones provided by the `minos.common.injections` module. * Be compatible with latest `minos.common.Config` API. + +## 0.7.0 (2022-05-11) + +* Minor improvements. +* Unify documentation building pipeline across all `minos-python` packages. +* Fix documentation building warnings. +* Fix bug related with package building and additional files like `AUTHORS.md`, `HISTORY.md`, etc. \ No newline at end of file diff --git a/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py b/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py index b55b1ce36..131612889 100644 --- a/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py +++ b/packages/core/minos-microservice-cqrs/minos/cqrs/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .exceptions import ( MinosCqrsException, diff --git a/packages/core/minos-microservice-cqrs/poetry.lock b/packages/core/minos-microservice-cqrs/poetry.lock index 3397f38b8..cb9f296e0 100644 --- a/packages/core/minos-microservice-cqrs/poetry.lock +++ b/packages/core/minos-microservice-cqrs/poetry.lock @@ -199,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev4" +version = "0.7.0" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -217,7 +217,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -239,7 +239,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -339,7 +339,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -417,7 +417,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "0947911015ea72e7aceed3b9d79efa69c701be56ba98348b9edf058ff7c82712" +content-hash = "31fcebfdf02fa9e5d6d2d8ff3eaaf63f44de9684b7b2c994b2ea889c78b2d733" [metadata.files] aiomisc = [ @@ -661,8 +661,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index 771222db8..23a9eb4d4 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-cqrs" -version = "0.7.0.dev4" +version = "0.7.0" description = "The CQRS pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../minos-microservice-common", develop = true } diff --git a/packages/core/minos-microservice-networks/HISTORY.md b/packages/core/minos-microservice-networks/HISTORY.md index f422e8cb8..25e2d093f 100644 --- a/packages/core/minos-microservice-networks/HISTORY.md +++ b/packages/core/minos-microservice-networks/HISTORY.md @@ -211,4 +211,21 @@ * Add `OpenAPIService` and `AsynAPIService` classes as the services that provide `openapi` and `asynciapi` specifications of the microservice. * Add `SystemService` as the service that implements System Health checker. * Replace `dependency-injector`'s injection classes by the ones provided by the `minos.common.injections` module. -* Be compatible with latest `minos.common.Config` API. \ No newline at end of file +* Be compatible with latest `minos.common.Config` API. + +## 0.7.0 (2022-05-11) + +* Rename `PostgreSqlBrokerPublisherQueue` as `DatabaseBrokerPublisherQueue`. +* Rename `PostgreSqlBrokerPublisherQueueQueryFactory` as `BrokerPublisherQueueDatabaseOperationFactory`. +* Rename `PostgreSqlBrokerQueue` as `DatabaseBrokerQueue`. +* Rename `PostgreSqlBrokerQueueBuilder` as `DatabaseBrokerQueueBuilder`. +* Rename `PostgreSqlBrokerSubscriberDuplicateValidator` as `DatabaseBrokerSubscriberDuplicateValidator`. +* Rename `PostgreSqlBrokerSubscriberDuplicateValidatorBuilder` as `DatabaseBrokerSubscriberDuplicateValidatorBuilder`. +* Rename `PostgreSqlBrokerSubscriberDuplicateValidatorQueryFactory` as `BrokerSubscriberDuplicateValidatorDatabaseOperationFactory`. +* Rename `PostgreSqlBrokerSubscriberQueue` as `DatabaseBrokerSubscriberQueue`. +* Rename `PostgreSqlBrokerSubscriberQueueBuilder` as `DatabaseBrokerSubscriberQueueBuilder`. +* Rename `PostgreSqlBrokerSubscriberQueueQueryFactory` as `BrokerSubscriberQueueDatabaseOperationFactory`. +* Move `Builder` to the `minos-microservice-common` package. +* Unify documentation building pipeline across all `minos-python` packages. +* Fix documentation building warnings. +* Fix bug related with package building and additional files like `AUTHORS.md`, `HISTORY.md`, etc. \ No newline at end of file diff --git a/packages/core/minos-microservice-networks/minos/networks/__init__.py b/packages/core/minos-microservice-networks/minos/networks/__init__.py index 48a6cc111..93a82ac0c 100644 --- a/packages/core/minos-microservice-networks/minos/networks/__init__.py +++ b/packages/core/minos-microservice-networks/minos/networks/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .brokers import ( REQUEST_HEADERS_CONTEXT_VAR, diff --git a/packages/core/minos-microservice-networks/poetry.lock b/packages/core/minos-microservice-networks/poetry.lock index 80b51479f..69e0ccbdd 100644 --- a/packages/core/minos-microservice-networks/poetry.lock +++ b/packages/core/minos-microservice-networks/poetry.lock @@ -199,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -304,7 +304,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -382,7 +382,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "ff4af32fdc2d848f93f56844f1f726f760ead3537fef11cf58b6ba4468e62dd0" +content-hash = "da7c8e23212bedf0d8263513f83692142646803a85382d956367a823572781eb" [metadata.files] aiomisc = [ @@ -624,8 +624,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index 7e7607ffc..3d2b6950e 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,7 +31,7 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } crontab = "^0.23.0" [tool.poetry.dev-dependencies] diff --git a/packages/core/minos-microservice-saga/HISTORY.md b/packages/core/minos-microservice-saga/HISTORY.md index 940e9b4b7..5e2ce4f63 100644 --- a/packages/core/minos-microservice-saga/HISTORY.md +++ b/packages/core/minos-microservice-saga/HISTORY.md @@ -157,3 +157,12 @@ * Replace `dependency-injector`'s injection classes by the ones provided by the `minos.common.injections` module. * Be compatible with latest `minos.common.Config` API. + +## 0.7.0 (2022-05-11) + +* Rename `SagaExecutionStorage` as `SagaExecutionRepository`. +* Add `DatabaseSagaExecutionRepository` as the implementation of the `SagaExecutionRepository` over a database. +* Add `SagaExecutionDatabaseOperationFactory` as the base operation factory to store saga executions. +* Unify documentation building pipeline across all `minos-python` packages. +* Fix documentation building warnings. +* Fix bug related with package building and additional files like `AUTHORS.md`, `HISTORY.md`, etc. \ No newline at end of file diff --git a/packages/core/minos-microservice-saga/minos/saga/__init__.py b/packages/core/minos-microservice-saga/minos/saga/__init__.py index 0cc5ab168..eec096ef9 100644 --- a/packages/core/minos-microservice-saga/minos/saga/__init__.py +++ b/packages/core/minos-microservice-saga/minos/saga/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .context import ( SagaContext, diff --git a/packages/core/minos-microservice-saga/poetry.lock b/packages/core/minos-microservice-saga/poetry.lock index 984e71bc1..b2d776e62 100644 --- a/packages/core/minos-microservice-saga/poetry.lock +++ b/packages/core/minos-microservice-saga/poetry.lock @@ -199,7 +199,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev4" +version = "0.7.0" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -217,7 +217,7 @@ url = "../minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -239,7 +239,7 @@ url = "../minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -339,7 +339,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -417,7 +417,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "e74a25ec1ffa361532680faa162e7ea2877562db649d9ca59c4aea2ddecec0f7" +content-hash = "9c4e0c0e329efda161e7508ce5f9c895804c0ac5586971be2c10cb2298b07a7a" [metadata.files] aiomisc = [ @@ -661,8 +661,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index 2de75d4a7..88ee9645f 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-microservice-saga" -version = "0.7.0.dev4" +version = "0.7.0" description = "The SAGA pattern of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } cached-property = "^1.5.2" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-broker-kafka/HISTORY.md b/packages/plugins/minos-broker-kafka/HISTORY.md index 3f99566f9..6a930063c 100644 --- a/packages/plugins/minos-broker-kafka/HISTORY.md +++ b/packages/plugins/minos-broker-kafka/HISTORY.md @@ -22,4 +22,11 @@ ## 0.6.1 (2022-04-01) -* Improve `KafkaBrokerSubscriber`'s destroying process. \ No newline at end of file +* Improve `KafkaBrokerSubscriber`'s destroying process. + +## 0.7.0 (2022-05-11) + +* Remove `InMemoryQueuedKafkaBrokerPublisher`, `PostgreSqlQueuedKafkaBrokerPublisher`, `InMemoryQueuedKafkaBrokerSubscriberBuilder` and `PostgreSqlQueuedKafkaBrokerSubscriberBuilder` in favor of the use of `minos.networks.BrokerPublisherBuilder` and `minos.networks.BrokerSubscriberBuilder`. +* Unify documentation building pipeline across all `minos-python` packages. +* Fix documentation building warnings. +* Fix bug related with package building and additional files like `AUTHORS.md`, `HISTORY.md`, etc. \ No newline at end of file diff --git a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py index 95f997c26..d55a2580b 100644 --- a/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py +++ b/packages/plugins/minos-broker-kafka/minos/plugins/kafka/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .common import ( KafkaBrokerBuilderMixin, diff --git a/packages/plugins/minos-broker-kafka/poetry.lock b/packages/plugins/minos-broker-kafka/poetry.lock index 9b0a4e460..41d502113 100644 --- a/packages/plugins/minos-broker-kafka/poetry.lock +++ b/packages/plugins/minos-broker-kafka/poetry.lock @@ -224,7 +224,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -246,7 +246,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -346,7 +346,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -432,7 +432,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "83dc6e09d794b3da6df0d99473af5ec70635027ee12d410e98eb29f830339979" +content-hash = "f1c1da04f1d4b12cdd5ad94b0e8ca485e81b635c8cf7fb000302a98b94a77b76" [metadata.files] aiokafka = [ @@ -702,8 +702,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-broker-kafka/pyproject.toml b/packages/plugins/minos-broker-kafka/pyproject.toml index 4ac743f56..d94faac46 100644 --- a/packages/plugins/minos-broker-kafka/pyproject.toml +++ b/packages/plugins/minos-broker-kafka/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-broker-kafka" -version = "0.7.0.dev4" +version = "0.7.0" description = "The kafka plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } aiokafka = "^0.7.0" cached-property = "^1.5.2" kafka-python = "^2.0.2" diff --git a/packages/plugins/minos-broker-rabbitmq/HISTORY.md b/packages/plugins/minos-broker-rabbitmq/HISTORY.md index 7641106a6..9bb8cd040 100644 --- a/packages/plugins/minos-broker-rabbitmq/HISTORY.md +++ b/packages/plugins/minos-broker-rabbitmq/HISTORY.md @@ -4,4 +4,11 @@ * Add `RabbitMQBrokerPublisher` as the implementation of the `rabbitmq` publisher. * Add `RabbitMQBrokerSubscriber` as the implementation of the `rabbitmq` subscriber. -* Add `RabbitMQBrokerPublisherBuilder`, `RabbitMQBrokerSubscriberBuilder` and `RabbitMQBrokerBuilderMixin` classes to ease the building proces. \ No newline at end of file +* Add `RabbitMQBrokerPublisherBuilder`, `RabbitMQBrokerSubscriberBuilder` and `RabbitMQBrokerBuilderMixin` classes to ease the building proces. + +## 0.7.0 (2022-05-11) + +* Minor improvements. +* Unify documentation building pipeline across all `minos-python` packages. +* Fix documentation building warnings. +* Fix bug related with package building and additional files like `AUTHORS.md`, `HISTORY.md`, etc. \ No newline at end of file diff --git a/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py b/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py index 79b794f09..6c068bac7 100644 --- a/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py +++ b/packages/plugins/minos-broker-rabbitmq/minos/plugins/rabbitmq/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .common import ( RabbitMQBrokerBuilderMixin, diff --git a/packages/plugins/minos-broker-rabbitmq/poetry.lock b/packages/plugins/minos-broker-rabbitmq/poetry.lock index ae85670c9..1da551fae 100644 --- a/packages/plugins/minos-broker-rabbitmq/poetry.lock +++ b/packages/plugins/minos-broker-rabbitmq/poetry.lock @@ -237,7 +237,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -259,7 +259,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -379,7 +379,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -477,7 +477,7 @@ multidict = ">=4.0" [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "2b66ade14c61be67e8928576bec9684c7798cc021994c6815a8a0e25b47f5d5b" +content-hash = "05401fb78073e6eadaa8742a61ec7a4e51ae167316296622b31a62f34d8a0d75" [metadata.files] aio-pika = [ @@ -795,8 +795,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-broker-rabbitmq/pyproject.toml b/packages/plugins/minos-broker-rabbitmq/pyproject.toml index 293aef865..c5738e084 100644 --- a/packages/plugins/minos-broker-rabbitmq/pyproject.toml +++ b/packages/plugins/minos-broker-rabbitmq/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-broker-rabbitmq" -version = "0.7.0.dev4" +version = "0.7.0" description = "The rabbitmq plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } aio-pika = "^7.1.0" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-database-aiopg/HISTORY.md b/packages/plugins/minos-database-aiopg/HISTORY.md index e0e57d3b3..69847e31e 100644 --- a/packages/plugins/minos-database-aiopg/HISTORY.md +++ b/packages/plugins/minos-database-aiopg/HISTORY.md @@ -1,2 +1,16 @@ # History +## 0.7.0 (2022-05-11) + +* Add `AiopgDatabaseClient` as the `minos.common.DatabaseClient` implementation for `postgres`. +* Add `AiopgDatabaseOperation` as the `minos.common.DatabaseOperation` implementation for `postgres`. +* Add `AiopgLockDatabaseOperationFactory` as the `minos.common.LockDatabaseOperationFactory` implementation for `postgres`. +* Add `AiopgManagementDatabaseOperationFactory` as the `minos.common.ManagementDatabaseOperationFactory` implementation for `postgres`. +* Add `AiopgBrokerPublisherQueueDatabaseOperationFactory` as the `minos.networks.BrokerPublisherQueueDatabaseOperationFactory` implementation for `postgres`. +* Add `AiopgBrokerQueueDatabaseOperationFactory` as the `minos.networks.BrokerQueueDatabaseOperationFactory` implementation for `postgres`. +* Add `AiopgBrokerSubscriberDuplicateValidatorDatabaseOperationFactory` as the `minos.networks.BrokerSubscriberDuplicateValidatorDatabaseOperationFactory` implementation for `postgres`. +* Add `AiopgBrokerSubscriberQueueDatabaseOperationFactory` as the `minos.networks.BrokerSubscriberQueueDatabaseOperationFactory` implementation for `postgres`. +* Add `AiopgEventDatabaseOperationFactory` as the `minos.aggregate.EventDatabaseOperationFactory` implementation for `postgres`. +* Add `AiopgSnapshotDatabaseOperationFactory` as the `minos.aggregate.SnapshotDatabaseOperationFactory` implementation for `postgres`. +* Add `AiopgSnapshotQueryDatabaseOperationBuilder` to ease the complex snapshot's query building for `postgres`. +* Add `AiopgTransactionDatabaseOperationFactory` as the `minos.aggregate.TransactionDatabaseOperationFactory` implementation for `postgres`. diff --git a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py index 244a6f058..741adcd86 100644 --- a/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py +++ b/packages/plugins/minos-database-aiopg/minos/plugins/aiopg/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .clients import ( AiopgDatabaseClient, diff --git a/packages/plugins/minos-database-aiopg/poetry.lock b/packages/plugins/minos-database-aiopg/poetry.lock index 4ec152b32..253463678 100644 --- a/packages/plugins/minos-database-aiopg/poetry.lock +++ b/packages/plugins/minos-database-aiopg/poetry.lock @@ -222,7 +222,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev4" +version = "0.7.0" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -240,7 +240,7 @@ url = "../../core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -262,7 +262,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -370,7 +370,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -448,7 +448,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "b43594cabd6bbb5636025c9351168e25f8c2e066080128dabe87e8e7cbc1188e" +content-hash = "f78d54e68fdc33507bb37390aeea31e5baca08414e07441c8466567d919fbabb" [metadata.files] aiomisc = [ @@ -758,8 +758,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, diff --git a/packages/plugins/minos-database-aiopg/pyproject.toml b/packages/plugins/minos-database-aiopg/pyproject.toml index ea8875efb..f48b647b4 100644 --- a/packages/plugins/minos-database-aiopg/pyproject.toml +++ b/packages/plugins/minos-database-aiopg/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-database-aiopg" -version = "0.7.0.dev4" +version = "0.7.0" description = "The aiopg plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = false } aiopg = "^1.2.1" psycopg2-binary = "^2.9.3" diff --git a/packages/plugins/minos-database-lmdb/HISTORY.md b/packages/plugins/minos-database-lmdb/HISTORY.md index e0e57d3b3..28596c46d 100644 --- a/packages/plugins/minos-database-lmdb/HISTORY.md +++ b/packages/plugins/minos-database-lmdb/HISTORY.md @@ -1,2 +1,7 @@ # History +## 0.7.0 (2022-05-11) + +* Add `LmdbDatabaseClient` as the `minos.common.DatabaseClient` implementation for `lmdb`. +* Add `LmdbDatabaseOperation` and `LmdbDatabaseOperationType` classes to define `minos.common.DatabaseOperation`s compatible with the `lmdb` database. +* Add `LmdbSagaExecutionDatabaseOperationFactory` as the `minos.saga.SagaExecutionDatabaseOperationFactory` implementation for `lmdb`. diff --git a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py index aa1c7ac56..9995ff1b2 100644 --- a/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py +++ b/packages/plugins/minos-database-lmdb/minos/plugins/lmdb/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .clients import ( LmdbDatabaseClient, diff --git a/packages/plugins/minos-database-lmdb/poetry.lock b/packages/plugins/minos-database-lmdb/poetry.lock index a77e8913d..ed23b8b18 100644 --- a/packages/plugins/minos-database-lmdb/poetry.lock +++ b/packages/plugins/minos-database-lmdb/poetry.lock @@ -207,7 +207,7 @@ python-versions = "*" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev4" +version = "0.7.0" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -225,7 +225,7 @@ url = "../../core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -247,7 +247,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -264,7 +264,7 @@ url = "../../core/minos-microservice-networks" [[package]] name = "minos-microservice-saga" -version = "0.7.0.dev4" +version = "0.7.0" description = "The SAGA pattern of the Minos Framework" category = "main" optional = false @@ -366,7 +366,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -444,7 +444,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "13984b2345050619e558ec2b7f5d7042811ef69ab784f48b842086de883d0b6a" +content-hash = "a5014ce6fcb07d6f9f1f2437093513fa25d2f20ba4463197773ff28b96a5ef35" [metadata.files] aiomisc = [ @@ -718,8 +718,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, diff --git a/packages/plugins/minos-database-lmdb/pyproject.toml b/packages/plugins/minos-database-lmdb/pyproject.toml index a699b437a..83830face 100644 --- a/packages/plugins/minos-database-lmdb/pyproject.toml +++ b/packages/plugins/minos-database-lmdb/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-database-lmdb" -version = "0.7.0.dev4" +version = "0.7.0" description = "The lmdb plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-saga = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-saga = { version ="^0.7.0*", allow-prereleases = false } lmdb = "^1.2.1" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-discovery-kong/HISTORY.md b/packages/plugins/minos-discovery-kong/HISTORY.md index 0e12b8de9..7cbf44ec0 100644 --- a/packages/plugins/minos-discovery-kong/HISTORY.md +++ b/packages/plugins/minos-discovery-kong/HISTORY.md @@ -1,5 +1,7 @@ # History -## 0.1.0a1 (2022-03-31) +## 0.7.0 (2022-05-11) -* First Alpha release +* Add `KongClient` as a class to interact with the `kong` API Gateway. +* Add `KongDiscoveryClient` as the `minos.networks.DiscoveryClient` implementation for the `kong` API Gateway. +* Add `middleware` function to automatically extract the user identifier from request's header variable set by the `kong` API Gateway. \ No newline at end of file diff --git a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py index 9284e69c8..3bbf4686d 100644 --- a/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py +++ b/packages/plugins/minos-discovery-kong/minos/plugins/kong/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .client import ( KongClient, diff --git a/packages/plugins/minos-discovery-kong/poetry.lock b/packages/plugins/minos-discovery-kong/poetry.lock index 0e9fbd76d..a75ae5ebf 100644 --- a/packages/plugins/minos-discovery-kong/poetry.lock +++ b/packages/plugins/minos-discovery-kong/poetry.lock @@ -290,7 +290,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -312,7 +312,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -426,7 +426,7 @@ tests = ["pytest (>=6.0.0,<7.0.0)", "coverage[toml] (==5.0.4)"] [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -542,7 +542,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "a4bba089f11aeccbc7cbc7f0cedb301d87d26d1c12075a2a233c5bf9901027b7" +content-hash = "333b3e74778377251713c2011a0b1bd6630a1e082e5b7a3b8700ccf195626cd3" [metadata.files] aiomisc = [ @@ -817,8 +817,8 @@ pyjwt = [ {file = "PyJWT-2.3.0.tar.gz", hash = "sha256:b888b4d56f06f6dcd777210c334e69c737be74755d3e5e9ee3fe67dc18a0ee41"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index c03aa5815..2587d1660 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-kong" -version = "0.7.0.dev4" +version = "0.7.0" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -32,8 +32,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } httpx = "^0.22.0" pytz = "^2022.1" PyJWT = "^2.3.0" diff --git a/packages/plugins/minos-discovery-minos/HISTORY.md b/packages/plugins/minos-discovery-minos/HISTORY.md index 1596265df..16bdde6cf 100644 --- a/packages/plugins/minos-discovery-minos/HISTORY.md +++ b/packages/plugins/minos-discovery-minos/HISTORY.md @@ -11,4 +11,11 @@ ## 0.6.0 (2022-03-28) -* Integrate `minos.common.CircuitBreakerMixin` into the `MinosDiscoveryClient` to be tolerant to connection failures to `minos-discovery`. \ No newline at end of file +* Integrate `minos.common.CircuitBreakerMixin` into the `MinosDiscoveryClient` to be tolerant to connection failures to `minos-discovery`. + +## 0.7.0 (2022-05-11) + +* Minor improvements. +* Unify documentation building pipeline across all `minos-python` packages. +* Fix documentation building warnings. +* Fix bug related with package building and additional files like `AUTHORS.md`, `HISTORY.md`, etc. \ No newline at end of file diff --git a/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py b/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py index c63e65556..92662cc7c 100644 --- a/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py +++ b/packages/plugins/minos-discovery-minos/minos/plugins/minos_discovery/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .client import ( MinosDiscoveryClient, diff --git a/packages/plugins/minos-discovery-minos/poetry.lock b/packages/plugins/minos-discovery-minos/poetry.lock index 7369be101..b34d83729 100644 --- a/packages/plugins/minos-discovery-minos/poetry.lock +++ b/packages/plugins/minos-discovery-minos/poetry.lock @@ -265,7 +265,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -287,7 +287,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -395,7 +395,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -493,7 +493,7 @@ multidict = ">=4.0" [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "8de1ddcc7e0efd18606f140ff12b1863992d8867b595de724e91b86baddc47c1" +content-hash = "3c8f704eaee2197547064141837553faeea37617af244aa0644387a2f7c2f682" [metadata.files] aiohttp = [ @@ -948,8 +948,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-discovery-minos/pyproject.toml b/packages/plugins/minos-discovery-minos/pyproject.toml index 8273085ca..2af00d08c 100644 --- a/packages/plugins/minos-discovery-minos/pyproject.toml +++ b/packages/plugins/minos-discovery-minos/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-discovery-minos" -version = "0.7.0.dev4" +version = "0.7.0" description = "The minos-discovery plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } aiohttp = "^3.8.1" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-http-aiohttp/HISTORY.md b/packages/plugins/minos-http-aiohttp/HISTORY.md index 507f1d38d..833e918e7 100644 --- a/packages/plugins/minos-http-aiohttp/HISTORY.md +++ b/packages/plugins/minos-http-aiohttp/HISTORY.md @@ -3,4 +3,11 @@ ## 0.6.0 (2022-03-28) * Add `AioHttpConnector` as the implementation of the `aiohttp` server. -* Add `AioHttpRequest`, `AioHttpResponse` and `AioHttpResponseException` classes as the request/response wrappers for `aiohttp`. \ No newline at end of file +* Add `AioHttpRequest`, `AioHttpResponse` and `AioHttpResponseException` classes as the request/response wrappers for `aiohttp`. + +## 0.7.0 (2022-05-11) + +* Now `AioHttpRequest`'s `headers` attribute is mutable. +* Unify documentation building pipeline across all `minos-python` packages. +* Fix documentation building warnings. +* Fix bug related with package building and additional files like `AUTHORS.md`, `HISTORY.md`, etc. \ No newline at end of file diff --git a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py index ed6edd6a4..b4de6d65d 100644 --- a/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py +++ b/packages/plugins/minos-http-aiohttp/minos/plugins/aiohttp/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .connectors import ( AioHttpConnector, diff --git a/packages/plugins/minos-http-aiohttp/poetry.lock b/packages/plugins/minos-http-aiohttp/poetry.lock index 0d67b092c..28634757a 100644 --- a/packages/plugins/minos-http-aiohttp/poetry.lock +++ b/packages/plugins/minos-http-aiohttp/poetry.lock @@ -265,7 +265,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -287,7 +287,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -395,7 +395,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -493,7 +493,7 @@ multidict = ">=4.0" [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "9ed872e521aee3a92c874dfb20d4f7c6eed8c1f252ef22657578b97ea0ad0d03" +content-hash = "5ff2df19716fefd78095278add594f005e5783892b37d7787097ef23ed4b0125" [metadata.files] aiohttp = [ @@ -948,8 +948,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-http-aiohttp/pyproject.toml b/packages/plugins/minos-http-aiohttp/pyproject.toml index d7e929b79..d7e75ef91 100644 --- a/packages/plugins/minos-http-aiohttp/pyproject.toml +++ b/packages/plugins/minos-http-aiohttp/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-http-aiohttp" -version = "0.7.0.dev4" +version = "0.7.0" description = "The aiohttp plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } aiohttp = "^3.8.1" orjson = "^3.6.7" cached-property = "^1.5.2" diff --git a/packages/plugins/minos-router-graphql/HISTORY.md b/packages/plugins/minos-router-graphql/HISTORY.md index caaf8c036..0cc129c48 100644 --- a/packages/plugins/minos-router-graphql/HISTORY.md +++ b/packages/plugins/minos-router-graphql/HISTORY.md @@ -6,3 +6,10 @@ * Add `GraphQlHandler` class to handle `graphql` requests. * Add `GraphQlHttpRouter` class to route `http` request to `graphql`. * Add `GraphQlEnroute`, `GraphQlEnrouteDecorator`, `GraphQlCommandEnrouteDecorator` and `GraphQlQueryEnrouteDecorator` decorators. + +## 0.7.0 (2022-05-11) + +* Minor improvements. +* Unify documentation building pipeline across all `minos-python` packages. +* Fix documentation building warnings. +* Fix bug related with package building and additional files like `AUTHORS.md`, `HISTORY.md`, etc. \ No newline at end of file diff --git a/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py b/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py index e233dfdee..c1d9b3c4f 100644 --- a/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py +++ b/packages/plugins/minos-router-graphql/minos/plugins/graphql/__init__.py @@ -2,7 +2,7 @@ __author__ = "Minos Framework Devs" __email__ = "hey@minos.run" -__version__ = "0.7.0.dev4" +__version__ = "0.7.0" from .builders import ( GraphQLSchemaBuilder, diff --git a/packages/plugins/minos-router-graphql/poetry.lock b/packages/plugins/minos-router-graphql/poetry.lock index ff7a7d4f3..ea9dcf36f 100644 --- a/packages/plugins/minos-router-graphql/poetry.lock +++ b/packages/plugins/minos-router-graphql/poetry.lock @@ -207,7 +207,7 @@ python-versions = "*" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -229,7 +229,7 @@ url = "../../core/minos-microservice-common" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -329,7 +329,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -415,7 +415,7 @@ test = ["aiohttp", "flake8 (>=3.9.2,<3.10.0)", "psutil", "pycodestyle (>=2.7.0,< [metadata] lock-version = "1.1" python-versions = "^3.9" -content-hash = "4e128a7d215b0b372007e4d0eb730675ac7998a38c17ead9ce794683f29a3941" +content-hash = "167e12c889eba2e0981bd549009fdbcbc5c46cefbc19b919181666e78be3bdb2" [metadata.files] aiomisc = [ @@ -662,8 +662,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-6.2.5-py3-none-any.whl", hash = "sha256:7310f8d27bc79ced999e760ca304d69f6ba6c6649c0b60fb0e04a4a77cacc134"}, diff --git a/packages/plugins/minos-router-graphql/pyproject.toml b/packages/plugins/minos-router-graphql/pyproject.toml index 751fc5eb4..201f57838 100644 --- a/packages/plugins/minos-router-graphql/pyproject.toml +++ b/packages/plugins/minos-router-graphql/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-router-graphql" -version = "0.7.0.dev4" +version = "0.7.0" description = "The graphql plugin of the Minos Framework" readme = "README.md" repository = "https://github.com/minos-framework/minos-python" @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = true } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = true } +minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } graphql-core = "^3.2.0" [tool.poetry.dev-dependencies] diff --git a/poetry.lock b/poetry.lock index 4ced573c3..da4f4a2ad 100644 --- a/poetry.lock +++ b/poetry.lock @@ -547,7 +547,7 @@ python-versions = "*" [[package]] name = "minos-broker-kafka" -version = "0.7.0.dev4" +version = "0.7.0" description = "The kafka plugin of the Minos Framework" category = "main" optional = false @@ -567,7 +567,7 @@ url = "packages/plugins/minos-broker-kafka" [[package]] name = "minos-broker-rabbitmq" -version = "0.7.0.dev4" +version = "0.7.0" description = "The rabbitmq plugin of the Minos Framework" category = "main" optional = false @@ -585,7 +585,7 @@ url = "packages/plugins/minos-broker-rabbitmq" [[package]] name = "minos-database-aiopg" -version = "0.7.0.dev4" +version = "0.7.0" description = "The aiopg plugin of the Minos Framework" category = "main" optional = false @@ -605,7 +605,7 @@ url = "packages/plugins/minos-database-aiopg" [[package]] name = "minos-database-lmdb" -version = "0.7.0.dev4" +version = "0.7.0" description = "The lmdb plugin of the Minos Framework" category = "main" optional = false @@ -623,7 +623,7 @@ url = "packages/plugins/minos-database-lmdb" [[package]] name = "minos-discovery-kong" -version = "0.7.0.dev4" +version = "0.7.0" description = "The minos-kong plugin offer an interface that permit integrate Minos Microservice with Kong API Gateway" category = "main" optional = false @@ -643,7 +643,7 @@ url = "packages/plugins/minos-discovery-kong" [[package]] name = "minos-discovery-minos" -version = "0.7.0.dev4" +version = "0.7.0" description = "The minos-discovery plugin of the Minos Framework" category = "main" optional = false @@ -661,7 +661,7 @@ url = "packages/plugins/minos-discovery-minos" [[package]] name = "minos-http-aiohttp" -version = "0.7.0.dev4" +version = "0.7.0" description = "The aiohttp plugin of the Minos Framework" category = "main" optional = false @@ -681,7 +681,7 @@ url = "packages/plugins/minos-http-aiohttp" [[package]] name = "minos-microservice-aggregate" -version = "0.7.0.dev4" +version = "0.7.0" description = "The Aggregate pattern of the Minos Framework" category = "main" optional = false @@ -699,7 +699,7 @@ url = "packages/core/minos-microservice-aggregate" [[package]] name = "minos-microservice-common" -version = "0.7.0.dev4" +version = "0.7.0" description = "The common core of the Minos Framework" category = "main" optional = false @@ -721,7 +721,7 @@ url = "packages/core/minos-microservice-common" [[package]] name = "minos-microservice-cqrs" -version = "0.7.0.dev4" +version = "0.7.0" description = "The CQRS pattern of the Minos Framework" category = "main" optional = false @@ -739,7 +739,7 @@ url = "packages/core/minos-microservice-cqrs" [[package]] name = "minos-microservice-networks" -version = "0.7.0.dev4" +version = "0.7.0" description = "The networks core of the Minos Framework" category = "main" optional = false @@ -756,7 +756,7 @@ url = "packages/core/minos-microservice-networks" [[package]] name = "minos-microservice-saga" -version = "0.7.0.dev4" +version = "0.7.0" description = "The SAGA pattern of the Minos Framework" category = "main" optional = false @@ -775,7 +775,7 @@ url = "packages/core/minos-microservice-saga" [[package]] name = "minos-router-graphql" -version = "0.7.0.dev4" +version = "0.7.0" description = "The graphql plugin of the Minos Framework" category = "main" optional = false @@ -864,7 +864,7 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" [[package]] name = "pbr" -version = "5.8.1" +version = "5.9.0" description = "Python Build Reasonableness" category = "dev" optional = false @@ -896,7 +896,7 @@ testing = ["pytest", "pytest-benchmark"] [[package]] name = "pre-commit" -version = "2.18.1" +version = "2.19.0" description = "A framework for managing and maintaining multi-language pre-commit hooks." category = "dev" optional = false @@ -966,7 +966,7 @@ tests = ["pytest (>=6.0.0,<7.0.0)", "coverage[toml] (==5.0.4)"] [[package]] name = "pyparsing" -version = "3.0.8" +version = "3.0.9" description = "pyparsing module - Classes and methods to define and execute parsing grammars" category = "dev" optional = false @@ -1942,8 +1942,8 @@ pathspec = [ {file = "pathspec-0.9.0.tar.gz", hash = "sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"}, ] pbr = [ - {file = "pbr-5.8.1-py2.py3-none-any.whl", hash = "sha256:27108648368782d07bbf1cb468ad2e2eeef29086affd14087a6d04b7de8af4ec"}, - {file = "pbr-5.8.1.tar.gz", hash = "sha256:66bc5a34912f408bb3925bf21231cb6f59206267b7f63f3503ef865c1a292e25"}, + {file = "pbr-5.9.0-py2.py3-none-any.whl", hash = "sha256:e547125940bcc052856ded43be8e101f63828c2d94239ffbe2b327ba3d5ccf0a"}, + {file = "pbr-5.9.0.tar.gz", hash = "sha256:e8dca2f4b43560edef58813969f52a56cef023146cbb8931626db80e6c1c4308"}, ] platformdirs = [ {file = "platformdirs-2.5.2-py3-none-any.whl", hash = "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788"}, @@ -1954,8 +1954,8 @@ pluggy = [ {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, ] pre-commit = [ - {file = "pre_commit-2.18.1-py2.py3-none-any.whl", hash = "sha256:02226e69564ebca1a070bd1f046af866aa1c318dbc430027c50ab832ed2b73f2"}, - {file = "pre_commit-2.18.1.tar.gz", hash = "sha256:5d445ee1fa8738d506881c5d84f83c62bb5be6b2838e32207433647e8e5ebe10"}, + {file = "pre_commit-2.19.0-py2.py3-none-any.whl", hash = "sha256:10c62741aa5704faea2ad69cb550ca78082efe5697d6f04e5710c3c229afdd10"}, + {file = "pre_commit-2.19.0.tar.gz", hash = "sha256:4233a1e38621c87d9dda9808c6606d7e7ba0e087cd56d3fe03202a01d2919615"}, ] psycopg2-binary = [ {file = "psycopg2-binary-2.9.3.tar.gz", hash = "sha256:761df5313dc15da1502b21453642d7599d26be88bff659382f8f9747c7ebea4e"}, @@ -2036,8 +2036,8 @@ pyjwt = [ {file = "PyJWT-2.3.0.tar.gz", hash = "sha256:b888b4d56f06f6dcd777210c334e69c737be74755d3e5e9ee3fe67dc18a0ee41"}, ] pyparsing = [ - {file = "pyparsing-3.0.8-py3-none-any.whl", hash = "sha256:ef7b523f6356f763771559412c0d7134753f037822dad1b16945b7b846f7ad06"}, - {file = "pyparsing-3.0.8.tar.gz", hash = "sha256:7bf433498c016c4314268d95df76c81b842a4cb2b276fa3312cfb1e1d85f6954"}, + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] pytest = [ {file = "pytest-7.1.2-py3-none-any.whl", hash = "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c"}, diff --git a/pyproject.toml b/pyproject.toml index 3bef0da05..4a274b72e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "minos-python" -version = "0.7.0.dev4" +version = "0.7.0" description = "" authors = ["Minos Framework Devs "] license = "MIT" From a766d53c4c75ffe9189befd6cb8f187b6383f87a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 11 May 2022 12:38:37 +0200 Subject: [PATCH 322/324] * Minor fix. --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d08af18a2..6bd6fdac2 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ [![GitHub Repo stars](https://img.shields.io/github/stars/minos-framework/minos-python?label=GitHub)] [![PyPI Latest Release](https://img.shields.io/pypi/v/minos-microservice-common.svg)](https://pypi.org/project/minos-microservice-common/) -[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://github.com/minos-framework/minos-python/tree/main) +[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://minos-framework.github.io/minos-python) [![License](https://img.shields.io/github/license/minos-framework/minos-python.svg)](https://github.com/minos-framework/minos-python/blob/main/LICENSE) [![Coverage](https://codecov.io/github/minos-framework/minos-python/coverage.svg?branch=main)](https://codecov.io/gh/minos-framework/minos-python) [![Stack Overflow](https://img.shields.io/badge/Stack%20Overflow-Ask%20a%20question-green)](https://stackoverflow.com/questions/tagged/minos) @@ -62,7 +62,7 @@ For more information, visit the [`minos-cli`](https://github.com/minos-framework ## Documentation -The best place to start learning how to use the Minos Framework is at [Minos Learn](https://www.minos.run/learn/). The official API Reference is publicly available at the [GitHub Pages](https://github.com/minos-framework/minos-python/tree/main). +The best place to start learning how to use the Minos Framework is at [Minos Learn](https://www.minos.run/learn/). The official API Reference is publicly available at the [GitHub Pages](https://minos-framework.github.io/minos-python). ## QuickStart From aa35da64c199e8f3c997d1f43944401ed6ad87f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Wed, 11 May 2022 12:44:41 +0200 Subject: [PATCH 323/324] * Fix bug related with dependency constraints (2). --- packages/core/minos-microservice-aggregate/pyproject.toml | 4 ++-- packages/core/minos-microservice-cqrs/pyproject.toml | 6 +++--- packages/core/minos-microservice-networks/pyproject.toml | 2 +- packages/core/minos-microservice-saga/pyproject.toml | 6 +++--- packages/plugins/minos-broker-kafka/pyproject.toml | 4 ++-- packages/plugins/minos-broker-rabbitmq/pyproject.toml | 4 ++-- packages/plugins/minos-database-aiopg/pyproject.toml | 6 +++--- packages/plugins/minos-database-lmdb/pyproject.toml | 4 ++-- packages/plugins/minos-discovery-kong/pyproject.toml | 4 ++-- packages/plugins/minos-discovery-minos/pyproject.toml | 4 ++-- packages/plugins/minos-http-aiohttp/pyproject.toml | 4 ++-- packages/plugins/minos-router-graphql/pyproject.toml | 4 ++-- 12 files changed, 26 insertions(+), 26 deletions(-) diff --git a/packages/core/minos-microservice-aggregate/pyproject.toml b/packages/core/minos-microservice-aggregate/pyproject.toml index 9b44086a9..1f789bd55 100644 --- a/packages/core/minos-microservice-aggregate/pyproject.toml +++ b/packages/core/minos-microservice-aggregate/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" cached-property = "^1.5.2" [tool.poetry.dev-dependencies] diff --git a/packages/core/minos-microservice-cqrs/pyproject.toml b/packages/core/minos-microservice-cqrs/pyproject.toml index 23a9eb4d4..722535d61 100644 --- a/packages/core/minos-microservice-cqrs/pyproject.toml +++ b/packages/core/minos-microservice-cqrs/pyproject.toml @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-aggregate = "^0.7.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" [tool.poetry.dev-dependencies] minos-microservice-common = { path = "../minos-microservice-common", develop = true } diff --git a/packages/core/minos-microservice-networks/pyproject.toml b/packages/core/minos-microservice-networks/pyproject.toml index 3d2b6950e..8fc0e5ae6 100644 --- a/packages/core/minos-microservice-networks/pyproject.toml +++ b/packages/core/minos-microservice-networks/pyproject.toml @@ -31,7 +31,7 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = "^0.7.0" crontab = "^0.23.0" [tool.poetry.dev-dependencies] diff --git a/packages/core/minos-microservice-saga/pyproject.toml b/packages/core/minos-microservice-saga/pyproject.toml index 88ee9645f..b3dbdfd01 100644 --- a/packages/core/minos-microservice-saga/pyproject.toml +++ b/packages/core/minos-microservice-saga/pyproject.toml @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-aggregate = "^0.7.0" +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" cached-property = "^1.5.2" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-broker-kafka/pyproject.toml b/packages/plugins/minos-broker-kafka/pyproject.toml index d94faac46..8c5c0f60a 100644 --- a/packages/plugins/minos-broker-kafka/pyproject.toml +++ b/packages/plugins/minos-broker-kafka/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" aiokafka = "^0.7.0" cached-property = "^1.5.2" kafka-python = "^2.0.2" diff --git a/packages/plugins/minos-broker-rabbitmq/pyproject.toml b/packages/plugins/minos-broker-rabbitmq/pyproject.toml index c5738e084..c4176ff49 100644 --- a/packages/plugins/minos-broker-rabbitmq/pyproject.toml +++ b/packages/plugins/minos-broker-rabbitmq/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" aio-pika = "^7.1.0" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-database-aiopg/pyproject.toml b/packages/plugins/minos-database-aiopg/pyproject.toml index f48b647b4..6b370da46 100644 --- a/packages/plugins/minos-database-aiopg/pyproject.toml +++ b/packages/plugins/minos-database-aiopg/pyproject.toml @@ -31,9 +31,9 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-aggregate = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" +minos-microservice-aggregate = "^0.7.0" aiopg = "^1.2.1" psycopg2-binary = "^2.9.3" diff --git a/packages/plugins/minos-database-lmdb/pyproject.toml b/packages/plugins/minos-database-lmdb/pyproject.toml index 83830face..45f6b469f 100644 --- a/packages/plugins/minos-database-lmdb/pyproject.toml +++ b/packages/plugins/minos-database-lmdb/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-saga = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = "^0.7.0" +minos-microservice-saga = "^0.7.0" lmdb = "^1.2.1" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-discovery-kong/pyproject.toml b/packages/plugins/minos-discovery-kong/pyproject.toml index 2587d1660..be802b3cb 100644 --- a/packages/plugins/minos-discovery-kong/pyproject.toml +++ b/packages/plugins/minos-discovery-kong/pyproject.toml @@ -32,8 +32,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" httpx = "^0.22.0" pytz = "^2022.1" PyJWT = "^2.3.0" diff --git a/packages/plugins/minos-discovery-minos/pyproject.toml b/packages/plugins/minos-discovery-minos/pyproject.toml index 2af00d08c..c2566b226 100644 --- a/packages/plugins/minos-discovery-minos/pyproject.toml +++ b/packages/plugins/minos-discovery-minos/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" aiohttp = "^3.8.1" [tool.poetry.dev-dependencies] diff --git a/packages/plugins/minos-http-aiohttp/pyproject.toml b/packages/plugins/minos-http-aiohttp/pyproject.toml index d7e75ef91..e9c1fd95f 100644 --- a/packages/plugins/minos-http-aiohttp/pyproject.toml +++ b/packages/plugins/minos-http-aiohttp/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" aiohttp = "^3.8.1" orjson = "^3.6.7" cached-property = "^1.5.2" diff --git a/packages/plugins/minos-router-graphql/pyproject.toml b/packages/plugins/minos-router-graphql/pyproject.toml index 201f57838..cbc64181a 100644 --- a/packages/plugins/minos-router-graphql/pyproject.toml +++ b/packages/plugins/minos-router-graphql/pyproject.toml @@ -31,8 +31,8 @@ include = [ [tool.poetry.dependencies] python = "^3.9" -minos-microservice-common = { version ="^0.7.0*", allow-prereleases = false } -minos-microservice-networks = { version ="^0.7.0*", allow-prereleases = false } +minos-microservice-common = "^0.7.0" +minos-microservice-networks = "^0.7.0" graphql-core = "^3.2.0" [tool.poetry.dev-dependencies] From f9f6ae4ece78b3e4de0b2744a39f69df18f9c886 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Garc=C3=ADa=20Prado?= Date: Thu, 12 May 2022 09:25:13 +0200 Subject: [PATCH 324/324] * Minor improvement. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 6bd6fdac2..7b69b2d31 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ # minos-python: The framework which helps you create reactive microservices in Python -[![GitHub Repo stars](https://img.shields.io/github/stars/minos-framework/minos-python?label=GitHub)] +[![GitHub Repo stars](https://img.shields.io/github/stars/minos-framework/minos-python?label=GitHub)](https://github.com/minos-framework/minos-python/stargazers) [![PyPI Latest Release](https://img.shields.io/pypi/v/minos-microservice-common.svg)](https://pypi.org/project/minos-microservice-common/) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/minos-framework/minos-python/pages%20build%20and%20deployment?label=docs)](https://minos-framework.github.io/minos-python) [![License](https://img.shields.io/github/license/minos-framework/minos-python.svg)](https://github.com/minos-framework/minos-python/blob/main/LICENSE)