From cf92a0186b57054cff0c1db09854ef5d9193d87a Mon Sep 17 00:00:00 2001
From: Erik Reid <erik.reid@geant.org>
Date: Sun, 9 Apr 2023 13:47:25 +0200
Subject: [PATCH] change imports of geant_service_orchestrator to gso

---
 README.md                                | 2 +-
 gso/main.py                              | 4 ++--
 gso/products/__init__.py                 | 2 +-
 gso/products/product_types/device.py     | 2 +-
 gso/services/ipam.py                     | 2 +-
 gso/services/provisioning_proxy.py       | 4 ++--
 gso/services/resource_manager.py         | 2 +-
 gso/workflows/device/create_device.py    | 4 ++--
 gso/workflows/device/terminate_device.py | 2 +-
 tox.ini                                  | 2 +-
 10 files changed, 13 insertions(+), 13 deletions(-)

diff --git a/README.md b/README.md
index f48cf09d..909a22cd 100644
--- a/README.md
+++ b/README.md
@@ -12,7 +12,7 @@ This is a dummy implementation of a trunk service in workflow orchestrator. The
 - ``pip install -e .``
 - Create ``oss-params.json``
 - Export the oss-params file: ``export OSS_PARAMS_FILENAME="/path/to/file.json"``
-- The core of workflow orchestrator can be started with ``uvicorn --host 0.0.0.0 --port 8080 main:app`` from inside the ``geant_service_orchestrator`` directory of this repo.
+- The core of workflow orchestrator can be started with ``uvicorn --host 0.0.0.0 --port 8080 main:app`` from inside the ``gso`` directory of this repo.
 - The GUI can be started with ``yarn start``.
 
 ## Structure description
diff --git a/gso/main.py b/gso/main.py
index 9ea59ed7..ba2582a8 100644
--- a/gso/main.py
+++ b/gso/main.py
@@ -1,8 +1,8 @@
 from orchestrator import OrchestratorCore
 from orchestrator.cli.main import app as core_cli
 from orchestrator.settings import AppSettings
-import geant_service_orchestrator.products  # noqa: F401
-import geant_service_orchestrator.workflows  # noqa: F401
+import gso.products  # noqa: F401
+import gso.workflows  # noqa: F401
 
 
 app = OrchestratorCore(base_settings=AppSettings())
diff --git a/gso/products/__init__.py b/gso/products/__init__.py
index 057aaece..e9a3658f 100644
--- a/gso/products/__init__.py
+++ b/gso/products/__init__.py
@@ -1,6 +1,6 @@
 from orchestrator.domain import SUBSCRIPTION_MODEL_REGISTRY
 
-from geant_service_orchestrator.products.product_types.device import Device
+from gso.products.product_types.device import Device
 
 SUBSCRIPTION_MODEL_REGISTRY.update(
     {
diff --git a/gso/products/product_types/device.py b/gso/products/product_types/device.py
index 0b20fa90..e79762c1 100644
--- a/gso/products/product_types/device.py
+++ b/gso/products/product_types/device.py
@@ -1,7 +1,7 @@
 from orchestrator.domain.base import SubscriptionModel
 from orchestrator.types import SubscriptionLifecycle, strEnum
 
-from geant_service_orchestrator.products.product_blocks.device \
+from gso.products.product_blocks.device \
     import DeviceBlock, DeviceBlockInactive, DeviceBlockProvisioning
 
 
diff --git a/gso/services/ipam.py b/gso/services/ipam.py
index 021bcb44..6e63130c 100644
--- a/gso/services/ipam.py
+++ b/gso/services/ipam.py
@@ -1,6 +1,6 @@
 import ipaddress
 from pydantic import BaseSettings
-from geant_service_orchestrator import settings
+from gso import settings
 
 
 class ServiceNetworks(BaseSettings):
diff --git a/gso/services/provisioning_proxy.py b/gso/services/provisioning_proxy.py
index 2a3626d3..d06bfafa 100644
--- a/gso/services/provisioning_proxy.py
+++ b/gso/services/provisioning_proxy.py
@@ -1,6 +1,6 @@
-from geant_service_orchestrator.products.product_types.device \
+from gso.products.product_types.device \
     import DeviceBlock
-from geant_service_orchestrator import settings
+from gso import settings
 import requests
 
 
diff --git a/gso/services/resource_manager.py b/gso/services/resource_manager.py
index f591e8a3..334e7b3e 100644
--- a/gso/services/resource_manager.py
+++ b/gso/services/resource_manager.py
@@ -1,4 +1,4 @@
-from geant_service_orchestrator import settings
+from gso import settings
 import requests
 
 
diff --git a/gso/workflows/device/create_device.py b/gso/workflows/device/create_device.py
index f8bffe75..19d06a7d 100644
--- a/gso/workflows/device/create_device.py
+++ b/gso/workflows/device/create_device.py
@@ -11,8 +11,8 @@ from orchestrator.workflow import done, init, step, workflow
 from orchestrator.workflows.steps import resync, set_status
 from orchestrator.workflows.steps import store_process_subscription
 from orchestrator.workflows.utils import wrap_create_initial_input_form
-from geant_service_orchestrator.products.product_types import device
-from geant_service_orchestrator.services import ipam, provisioning_proxy
+from gso.products.product_types import device
+from gso.services import ipam, provisioning_proxy
 
 
 def initial_input_form_generator(product_name: str) -> FormGenerator:
diff --git a/gso/workflows/device/terminate_device.py b/gso/workflows/device/terminate_device.py
index 5c175778..686128a1 100644
--- a/gso/workflows/device/terminate_device.py
+++ b/gso/workflows/device/terminate_device.py
@@ -11,7 +11,7 @@ from orchestrator.workflows.steps import (
 )
 from orchestrator.workflows.utils import wrap_modify_initial_input_form
 
-from geant_service_orchestrator.products.product_types.device import Device
+from gso.products.product_types.device import Device
 
 
 def initial_input_form_generator(subscription_id: UUIDstr) -> InputForm:
diff --git a/tox.ini b/tox.ini
index 733d4a37..7973b25a 100644
--- a/tox.ini
+++ b/tox.ini
@@ -9,7 +9,7 @@ deps =
 
 commands =
     coverage erase
-    coverage run --source geant_service_orchestrator -m pytest {posargs}
+    coverage run --source gso -m pytest {posargs}
     coverage xml
     coverage html
     # coverage report --fail-under 80
-- 
GitLab