From 04212da52b3cfd9b06b9ada0726c43156ba3cf2e Mon Sep 17 00:00:00 2001 From: Alexander Dahmen Date: Wed, 12 Mar 2025 15:16:32 +0100 Subject: [PATCH 1/2] Provide functionality to run the linter and tests for one service Signed-off-by: Alexander Dahmen --- .github/workflows/ci.yaml | 4 ++-- Makefile | 12 ++++++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index f94e44139..76ee2a3bc 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -23,6 +23,6 @@ jobs: poetry config virtualenvs.create false make install-dev - name: Lint - run: make lint + run: make lint-services - name: Test - run: make test + run: make test-services diff --git a/Makefile b/Makefile index 782ada543..34c00d989 100644 --- a/Makefile +++ b/Makefile @@ -12,13 +12,13 @@ install-dev: # install core. This needs to be done last or it will get overriden by the dependency installation of the services poetry install -C core --no-root; pip install -e core -test: +test-services: # test core cd core && poetry install --with dev && pytest # test services @for f in $(shell ls ${SERVICES_DIR}); do set -e; cd ${SERVICES_DIR}/$${f}; poetry install --with dev;sh -c 'pytest || ([ $$? = 5 ] && exit 0 || exit $$?)'; cd ../..; done -lint: +lint-services: # lint core cd core && poetry install --no-root --only dev &&flake8 . # lint examples. Use configuration from core @@ -26,6 +26,14 @@ lint: # lint services @for f in $(shell ls ${SERVICES_DIR}); do set -e; cd ${SERVICES_DIR}/$${f};poetry install --no-root --only dev; flake8 .; cd ../..; done +test: + echo "Testing service ${service}" + cd ${SERVICES_DIR}/${service}; poetry install --with dev;sh -c 'pytest || ([ $$? = 5 ] && exit 0 || exit $$?)'; cd ../..; + +lint: + echo "Linting service ${service}" + cd ${SERVICES_DIR}/${service};poetry install --no-root --only dev; flake8 .; cd ../..; + update-dependencies: # lock core cd core && poetry lock From 6e2ff34656f98c6ce3d7afb405ecdfcb116c3b48 Mon Sep 17 00:00:00 2001 From: SDK Generator Bot Date: Wed, 12 Mar 2025 14:48:30 +0000 Subject: [PATCH 2/2] Generate objectstorage --- .../src/stackit/objectstorage/configuration.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/services/objectstorage/src/stackit/objectstorage/configuration.py b/services/objectstorage/src/stackit/objectstorage/configuration.py index 7eecafd92..ea5c61b5c 100644 --- a/services/objectstorage/src/stackit/objectstorage/configuration.py +++ b/services/objectstorage/src/stackit/objectstorage/configuration.py @@ -32,7 +32,7 @@ def __init__( ) """Constructor """ - self._base_path = "https://object-storage.api.eu01.stackit.cloud" + self._base_path = "https://object-storage.api.stackit.cloud" """Default Base url """ self.server_index = 0 if server_index is None else server_index @@ -56,13 +56,12 @@ def get_host_settings(self): """ return [ { - "url": "https://object-storage.api.{region}stackit.cloud", + "url": "https://object-storage.api.stackit.cloud", "description": "No description provided", "variables": { "region": { "description": "No description provided", - "default_value": "eu01.", - "enum_values": ["eu01.", "eu02."], + "default_value": "global", } }, }