From db8880fa950ebf8d690c33ebc614e871cf15dc94 Mon Sep 17 00:00:00 2001 From: Pedro Crespo-Valero <32402063+pcrespov@users.noreply.github.com> Date: Mon, 4 Nov 2024 10:57:15 +0100 Subject: [PATCH] drafted requirements --- services/director/requirements/Makefile | 7 - services/director/requirements/_base.in | 77 ++----- services/director/requirements/_base.txt | 152 ------------- services/director/requirements/_test.in | 31 +-- services/director/requirements/_test.txt | 251 ---------------------- services/director/requirements/_tools.in | 6 +- services/director/requirements/_tools.txt | 45 ---- services/director/requirements/ci.txt | 10 +- services/director/requirements/dev.txt | 7 + services/director/requirements/prod.txt | 7 +- 10 files changed, 49 insertions(+), 544 deletions(-) delete mode 100644 services/director/requirements/_base.txt delete mode 100644 services/director/requirements/_test.txt delete mode 100644 services/director/requirements/_tools.txt diff --git a/services/director/requirements/Makefile b/services/director/requirements/Makefile index 7aacec9e5ee..3f25442b790 100644 --- a/services/director/requirements/Makefile +++ b/services/director/requirements/Makefile @@ -4,10 +4,3 @@ include ../../../requirements/base.Makefile # Add here any extra explicit dependency: e.g. _migration.txt: _base.txt - - -_test.txt: _base.txt _test.in - ## NOTE: this recipe override has to be removed - ## to execute target upgrades e.g. due to vulnerability of - ## a library. - @echo INFO: test.txt is frozen. Skipping upgrade. diff --git a/services/director/requirements/_base.in b/services/director/requirements/_base.in index 0618d6c7759..2c0510eb962 100644 --- a/services/director/requirements/_base.in +++ b/services/director/requirements/_base.in @@ -1,70 +1,19 @@ # -# Specifies third-party dependencies for 'director' +# Specifies third-party dependencies for 'services/web/server/src' # +--constraint ../../../requirements/constraints.txt -# IMPORTANT: All requirements (including the packages in this repository) as FROZEN to those in itisfoundation/director:master-2020-11-05--14-45.c8669fb52659b684514fefa4f3b4599f57f276a0 -# - current service is going to be replaced by director-v2 -# -# +# intra-repo required dependencies +--requirement ../../../packages/models-library/requirements/_base.in +--requirement ../../../packages/settings-library/requirements/_base.in -# This list was obtained as follows -# -# $ docker pull itisfoundation/director:master-2020-11-05--14-45.c8669fb52659b684514fefa4f3b4599f57f276a0 -# master-2020-11-05--14-45.c8669fb52659b684514fefa4f3b4599f57f276a0: Pulling from itisfoundation/director -# Digest: sha256:84ba999ca348bf9d56d9ef0af2e3494ede0cd06d357d289e2a09a4191e7a56d3 -# Status: Image is up to date for itisfoundation/director:master-2020-11-05--14-45.c8669fb52659b684514fefa4f3b4599f57f276a0 -# docker.io/itisfoundation/director:master-2020-11-05--14-45.c8669fb52659b684514fefa4f3b4599f57f276a0 -# -# $ docker inspect itisfoundation/director:master-2020-11-05--14-45.c8669fb52659b684514fefa4f3b4599f57f276a0| jq '.[0] | .RepoTags, .ContainerConfig.Labels' -# [ -# "itisfoundation/director:master-2020-11-05--14-45.c8669fb52659b684514fefa4f3b4599f57f276a0" -# ] -# { -# "io.osparc.api-version": "0.1.0", -# "maintainer": "sanderegg", -# "org.label-schema.build-date": "2020-11-05T14:02:31Z", -# "org.label-schema.schema-version": "1.0", -# "org.label-schema.vcs-ref": "c8669fb", -# "org.label-schema.vcs-url": "https://github.com/ITISFoundation/osparc-simcore.git" -# } -# -# $ docker run -it itisfoundation/director:master-2020-11-05--14-45.c8669fb52659b684514fefa4f3b4599f57f276a0 pip freeze -# +# service-library[fastapi] +--requirement ../../../packages/service-library/requirements/_base.in +--requirement ../../../packages/service-library/requirements/_fastapi.in -aiodebug==1.1.2 -aiodocker==0.14.0 -aiohttp==3.3.2 -aiohttp-apiset @ git+https://github.com/ITISFoundation/aiohttp_apiset.git@5c8a61ceb6de7ed9e09db5b4609b458a0d3773df -aiopg==1.0.0 -aiozipkin==0.7.1 -async-generator==1.10 -async-timeout==3.0.1 -asyncio-extras==1.3.2 -attrs==20.2.0 -certifi==2019.3.9 -chardet==3.0.4 -dataclasses==0.7 -idna==2.8 -idna-ssl==1.1.0 -isodate==0.6.0 -jsonschema==2.6.0 -lazy-object-proxy==1.4.3 -multidict==4.5.2 -openapi-core==0.12.0 -openapi-spec-validator==0.2.9 -prometheus-client==0.8.0 -psycopg2-binary==2.8.6 -pydantic==1.7.2 -PyYAML==5.4 # CVE-2020-1747 -requests==2.27.1 # -simcore-service-library @ git+https://github.com/ITISFoundation/osparc-simcore.git@c8669fb52659b684514fefa4f3b4599f57f276a0#egg=simcore-service-library&subdirectory=packages/service-library -six==1.12.0 -SQLAlchemy==1.3.20 -strict-rfc3339==0.7 -tenacity==6.0.0 -trafaret==2.1.0 -ujson==4.0.1 -urllib3==1.26.5 # CVE-2021-33503 -Werkzeug==1.0.1 -yarl==1.3.0 +aiodocker +fastapi[all] +httpx +prometheus-client +pydantic diff --git a/services/director/requirements/_base.txt b/services/director/requirements/_base.txt deleted file mode 100644 index 2c6e016526f..00000000000 --- a/services/director/requirements/_base.txt +++ /dev/null @@ -1,152 +0,0 @@ -aiodebug==1.1.2 - # via - # -r requirements/_base.in - # simcore-service-library -aiodocker==0.14.0 - # via -r requirements/_base.in -aiohttp==3.3.2 - # via - # -r requirements/_base.in - # aiodocker - # aiohttp-apiset - # aiozipkin - # simcore-service-library -aiohttp-apiset @ git+https://github.com/ITISFoundation/aiohttp_apiset.git@5c8a61ceb6de7ed9e09db5b4609b458a0d3773df - # via -r requirements/_base.in -aiopg==1.0.0 - # via - # -r requirements/_base.in - # simcore-service-library -aiozipkin==0.7.1 - # via - # -r requirements/_base.in - # simcore-service-library -async-generator==1.10 - # via - # -r requirements/_base.in - # asyncio-extras -async-timeout==3.0.1 - # via - # -r requirements/_base.in - # aiohttp -asyncio-extras==1.3.2 - # via -r requirements/_base.in -attrs==20.2.0 - # via - # -r requirements/_base.in - # aiohttp - # openapi-core - # simcore-service-library -certifi==2019.3.9 - # via - # -r requirements/_base.in - # requests -chardet==3.0.4 - # via - # -r requirements/_base.in - # aiohttp -charset-normalizer==2.0.12 - # via requests -dataclasses==0.7 - # via -r requirements/_base.in -idna==2.8 - # via - # -r requirements/_base.in - # idna-ssl - # requests - # yarl -idna-ssl==1.1.0 - # via - # -r requirements/_base.in - # aiohttp -isodate==0.6.0 - # via - # -r requirements/_base.in - # openapi-core -jsonschema==2.6.0 - # via - # -r requirements/_base.in - # aiohttp-apiset - # openapi-spec-validator - # simcore-service-library -lazy-object-proxy==1.4.3 - # via - # -r requirements/_base.in - # openapi-core - # simcore-service-library -multidict==4.5.2 - # via - # -r requirements/_base.in - # aiohttp - # yarl -openapi-core==0.12.0 - # via - # -r requirements/_base.in - # simcore-service-library -openapi-spec-validator==0.2.9 - # via - # -r requirements/_base.in - # openapi-core -prometheus-client==0.8.0 - # via - # -r requirements/_base.in - # simcore-service-library -psycopg2-binary==2.8.6 - # via - # -r requirements/_base.in - # aiopg - # simcore-service-library -pydantic==1.7.2 - # via - # -r requirements/_base.in - # simcore-service-library -pyyaml==5.4 - # via - # -r requirements/_base.in - # aiohttp-apiset - # openapi-spec-validator - # simcore-service-library -requests==2.27.1 - # via -r requirements/_base.in -simcore-service-library @ git+https://github.com/ITISFoundation/osparc-simcore.git@c8669fb52659b684514fefa4f3b4599f57f276a0#egg=simcore-service-library&subdirectory=packages/service-library - # via -r requirements/_base.in -six==1.12.0 - # via - # -r requirements/_base.in - # isodate - # openapi-core - # openapi-spec-validator - # tenacity -sqlalchemy==1.3.20 - # via - # -r requirements/_base.in - # simcore-service-library -strict-rfc3339==0.7 - # via - # -r requirements/_base.in - # openapi-core -tenacity==6.0.0 - # via - # -r requirements/_base.in - # simcore-service-library -trafaret==2.1.0 - # via - # -r requirements/_base.in - # simcore-service-library -ujson==4.0.1 - # via - # -r requirements/_base.in - # simcore-service-library -urllib3==1.26.5 - # via - # -r requirements/_base.in - # requests -werkzeug==1.0.1 - # via - # -r requirements/_base.in - # simcore-service-library -yarl==1.3.0 - # via - # -r requirements/_base.in - # aiodocker - # aiohttp diff --git a/services/director/requirements/_test.in b/services/director/requirements/_test.in index d480d049a73..eafeb199342 100644 --- a/services/director/requirements/_test.in +++ b/services/director/requirements/_test.in @@ -1,32 +1,23 @@ +# Specifies dependencies required to run 'services/api-server/test' +# both for unit and integration tests!! # -# Specifies dependencies required to run 'director' -# - -# frozen specs ---requirement _base.txt +--constraint ../../../requirements/constraints.txt -# NOTE: -# FROZEN (see notes in _base.in) -# DO NOT CHANGE ANYTHING HERE. -# IT WON'T HAVE ANY EFFECT +# Adds base AS CONSTRAINT specs, not requirement. +# - Resulting _text.txt is a frozen list of EXTRA packages for testing, besides _base.txt # - -# FROZEN as well (DO NOT CHANGE anything in pytest-simcore, it will have no effect in the director package) -pytest-simcore @ git+https://github.com/ITISFoundation/osparc-simcore.git@79f866219bf650c5eeb4fcdf8f017319087c92c7#egg=pytest-simcore&subdirectory=packages/pytest-simcore - +--constraint _base.txt # testing -aioresponses -coverage==4.5.1 # TODO: Downgraded because of a bug https://github.com/nedbat/coveragepy/issues/716 docker -openapi-spec-validator~=0.2 # TODO: this library is limiting jsonschema<3 -ptvsd -pylint +faker +jsonref pytest -pytest-aiohttp # incompatible with pytest-asyncio. See https://github.com/pytest-dev/pytest-asyncio/issues/76 +pytest-asyncio pytest-cov +pytest-docker pytest-instafail pytest-mock pytest-runner pytest-sugar -python-dotenv +respx diff --git a/services/director/requirements/_test.txt b/services/director/requirements/_test.txt deleted file mode 100644 index 97f4c9313fa..00000000000 --- a/services/director/requirements/_test.txt +++ /dev/null @@ -1,251 +0,0 @@ -# -# This file is autogenerated by pip-compile with python 3.6 -# To update, run: -# -# pip-compile --output-file=requirements/_test.txt --strip-extras requirements/_test.in -# -aiodebug==1.1.2 - # via - # -r requirements/_base.txt - # simcore-service-library -aiodocker==0.14.0 - # via -r requirements/_base.txt -aiohttp==3.3.2 - # via - # -r requirements/_base.txt - # aiodocker - # aiohttp-apiset - # aioresponses - # aiozipkin - # pytest-aiohttp - # simcore-service-library -aiohttp-apiset @ git+https://github.com/ITISFoundation/aiohttp_apiset.git@5c8a61ceb6de7ed9e09db5b4609b458a0d3773df - # via -r requirements/_base.txt -aiopg==1.0.0 - # via - # -r requirements/_base.txt - # simcore-service-library -aioresponses==0.7.2 - # via -r requirements/_test.in -aiozipkin==0.7.1 - # via - # -r requirements/_base.txt - # simcore-service-library -astroid==2.4.2 - # via pylint -async-generator==1.10 - # via - # -r requirements/_base.txt - # asyncio-extras -async-timeout==3.0.1 - # via - # -r requirements/_base.txt - # aiohttp -asyncio-extras==1.3.2 - # via -r requirements/_base.txt -attrs==20.2.0 - # via - # -r requirements/_base.txt - # aiohttp - # openapi-core - # pytest - # simcore-service-library -certifi==2019.3.9 - # via - # -r requirements/_base.txt - # requests -chardet==3.0.4 - # via - # -r requirements/_base.txt - # aiohttp -charset-normalizer==2.0.12 - # via - # -r requirements/_base.txt - # requests -coverage==4.5.1 - # via - # -r requirements/_test.in - # coveralls - # pytest-cov -dataclasses==0.7 - # via - # -r requirements/_base.txt - # pydantic -docker==4.3.1 - # via -r requirements/_test.in -docopt==0.6.2 - # via coveralls -idna==2.8 - # via - # -r requirements/_base.txt - # idna-ssl - # requests - # yarl -idna-ssl==1.1.0 - # via - # -r requirements/_base.txt - # aiohttp -importlib-metadata==2.0.0 - # via - # pluggy - # pytest -iniconfig==1.1.1 - # via pytest -isodate==0.6.0 - # via - # -r requirements/_base.txt - # openapi-core -isort==5.6.4 - # via pylint -jsonschema==2.6.0 - # via - # -r requirements/_base.txt - # aiohttp-apiset - # openapi-spec-validator - # simcore-service-library -lazy-object-proxy==1.4.3 - # via - # -r requirements/_base.txt - # astroid - # openapi-core - # simcore-service-library -mccabe==0.6.1 - # via pylint -multidict==4.5.2 - # via - # -r requirements/_base.txt - # aiohttp - # yarl -openapi-core==0.12.0 - # via - # -r requirements/_base.txt - # simcore-service-library -openapi-spec-validator==0.2.9 - # via - # -r requirements/_base.txt - # -r requirements/_test.in - # openapi-core -packaging==20.4 - # via - # pytest - # pytest-sugar -pluggy==0.13.1 - # via pytest -prometheus-client==0.8.0 - # via - # -r requirements/_base.txt - # simcore-service-library -psycopg2-binary==2.8.6 - # via - # -r requirements/_base.txt - # aiopg - # simcore-service-library -ptvsd==4.3.2 - # via -r requirements/_test.in -py==1.9.0 - # via pytest -pydantic==1.7.2 - # via - # -r requirements/_base.txt - # simcore-service-library -pylint==2.6.0 - # via -r requirements/_test.in -pyparsing==2.4.7 - # via packaging -pytest==6.1.2 - # via - # -r requirements/_test.in - # pytest-aiohttp - # pytest-cov - # pytest-instafail - # pytest-mock - # pytest-simcore - # pytest-sugar -pytest-aiohttp==0.3.0 - # via -r requirements/_test.in -pytest-cov==2.10.1 - # via -r requirements/_test.in -pytest-instafail==0.4.2 - # via -r requirements/_test.in -pytest-mock==3.3.1 - # via -r requirements/_test.in -pytest-runner==5.2 - # via -r requirements/_test.in -pytest-simcore @ git+https://github.com/ITISFoundation/osparc-simcore.git@79f866219bf650c5eeb4fcdf8f017319087c92c7#subdirectory=packages/pytest-simcore - # via -r requirements/_test.in -pytest-sugar==0.9.4 - # via -r requirements/_test.in -python-dotenv==0.15.0 - # via -r requirements/_test.in -pyyaml==5.4 - # via - # -r requirements/_base.txt - # aiohttp-apiset - # openapi-spec-validator - # simcore-service-library -requests==2.27.1 - # via - # -r requirements/_base.txt - # codecov - # coveralls - # docker -simcore-service-library @ git+https://github.com/ITISFoundation/osparc-simcore.git@c8669fb52659b684514fefa4f3b4599f57f276a0#subdirectory=packages/service-library - # via -r requirements/_base.txt -six==1.12.0 - # via - # -r requirements/_base.txt - # astroid - # docker - # isodate - # openapi-core - # openapi-spec-validator - # packaging - # tenacity - # websocket-client -sqlalchemy==1.3.20 - # via - # -r requirements/_base.txt - # simcore-service-library -strict-rfc3339==0.7 - # via - # -r requirements/_base.txt - # openapi-core -tenacity==6.0.0 - # via - # -r requirements/_base.txt - # simcore-service-library -termcolor==1.1.0 - # via pytest-sugar -toml==0.10.2 - # via - # pylint - # pytest -trafaret==2.1.0 - # via - # -r requirements/_base.txt - # simcore-service-library -typed-ast==1.4.1 - # via astroid -ujson==4.0.1 - # via - # -r requirements/_base.txt - # simcore-service-library -urllib3==1.26.5 - # via - # -r requirements/_base.txt - # requests -websocket-client==0.57.0 - # via docker -werkzeug==1.0.1 - # via - # -r requirements/_base.txt - # simcore-service-library -wrapt==1.12.1 - # via astroid -yarl==1.3.0 - # via - # -r requirements/_base.txt - # aiodocker - # aiohttp -zipp==3.4.0 - # via importlib-metadata diff --git a/services/director/requirements/_tools.in b/services/director/requirements/_tools.in index 05f1ab1646f..52a9a39d162 100644 --- a/services/director/requirements/_tools.in +++ b/services/director/requirements/_tools.in @@ -1,7 +1,7 @@ +--constraint ../../../requirements/constraints.txt --constraint _base.txt --constraint _test.txt +--requirement ../../../requirements/devenv.txt + watchdog[watchmedo] -black~=20.8b0 -pip-tools -bump2version diff --git a/services/director/requirements/_tools.txt b/services/director/requirements/_tools.txt deleted file mode 100644 index 821e63f1a10..00000000000 --- a/services/director/requirements/_tools.txt +++ /dev/null @@ -1,45 +0,0 @@ -appdirs==1.4.4 - # via black -black==20.8b1 - # via -r requirements/_tools.in -bump2version==1.0.1 - # via -r requirements/_tools.in -click==8.0.3 - # via - # black - # pip-tools -mypy-extensions==0.4.3 - # via black -pathspec==0.9.0 - # via black -pep517==0.12.0 - # via pip-tools -pip==24.2 - # via pip-tools -pip-tools==6.4.0 - # via -r requirements/_tools.in -pyyaml==5.4 - # via - # -c requirements/_base.txt - # -c requirements/_test.txt - # watchdog -regex==2022.1.18 - # via black -setuptools==75.2.0 - # via pip-tools -toml==0.10.2 - # via - # -c requirements/_test.txt - # black -tomli==1.2.3 - # via pep517 -typed-ast==1.4.1 - # via - # -c requirements/_test.txt - # black -typing-extensions==4.0.1 - # via black -watchdog==2.1.6 - # via -r requirements/_tools.in -wheel==0.37.1 - # via pip-tools diff --git a/services/director/requirements/ci.txt b/services/director/requirements/ci.txt index 8edcd5f2bfe..e805fec3802 100644 --- a/services/director/requirements/ci.txt +++ b/services/director/requirements/ci.txt @@ -7,7 +7,15 @@ # # installs base + tests requirements +--requirement _base.txt --requirement _test.txt +--requirement _tools.txt + +# installs this repo's packages +simcore-models-library @ ../../packages/models-library +pytest-simcore @ ../../packages/pytest-simcore/ +simcore-service-library[fastapi] @ ../../packages/service-library +simcore-settings-library @ ../../packages/settings-library/ # installs current package -. +simcore-service-director @ . diff --git a/services/director/requirements/dev.txt b/services/director/requirements/dev.txt index dac3f0a494b..f278b7206fd 100644 --- a/services/director/requirements/dev.txt +++ b/services/director/requirements/dev.txt @@ -12,5 +12,12 @@ --requirement _test.txt --requirement _tools.txt + +# installs this repo's packages +--editable ../../packages/models-library +--editable ../../packages/pytest-simcore/ +--editable ../../packages/service-library[fastapi] +--editable ../../packages/settings-library/ + # installs current package --editable . diff --git a/services/director/requirements/prod.txt b/services/director/requirements/prod.txt index dc0ec561efe..8a8b1d29125 100644 --- a/services/director/requirements/prod.txt +++ b/services/director/requirements/prod.txt @@ -9,5 +9,10 @@ # installs base requirements --requirement _base.txt +# installs this repo's packages +simcore-models-library @ ../../packages/models-library +simcore-service-library[fastapi] @ ../../packages/service-library +simcore-settings-library @ ../../packages/settings-library/ + # installs current package -. +simcore-service-director @ .