Skip to content

Commit a09768a

Browse files
committed
feat(ver): add v1alpha1 version
1 parent 81e2387 commit a09768a

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

scaleway_qaas_client/v1alpha1/client.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ def __init__(self, project_id: str, secret_key: str, url: str = _DEFAULT_URL):
121121
raise Exception("QaasClient: secret_key cannot be None")
122122

123123
self.__project_id = project_id
124-
url = url if url else _DEFAULT_URL
124+
url = url or _DEFAULT_URL
125125

126126
self.__client = AuthenticatedClient(
127127
base_url=url,
@@ -226,7 +226,7 @@ def create_session(
226226
if not platform_id:
227227
raise Exception("create_session: platform_id cannot be None")
228228

229-
name = name if name else f"qs-{randomname.get_name()}"
229+
name = name or f"qs-{randomname.get_name()}"
230230

231231
if isinstance(max_duration, str):
232232
max_duration = f"{timeparse(max_duration)}s"
@@ -403,7 +403,7 @@ def create_job(
403403
raise Exception("create_job: payload cannot be None")
404404

405405
payload = payload if isinstance(payload, str) else json.dumps(payload)
406-
name = name if name else f"qj-{randomname.get_name()}"
406+
name = name or f"qj-{randomname.get_name()}"
407407

408408
response = _create_job_sync(
409409
client=self.__client,
@@ -588,7 +588,7 @@ def create_process(
588588
if not input:
589589
raise Exception("create_process: input cannot be None")
590590

591-
name = name if name else f"qp-{randomname.get_name()}"
591+
name = name or f"qp-{randomname.get_name()}"
592592

593593
input = input if isinstance(input, str) else json.dumps(input)
594594

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
setup(
2424
name="scaleway_qaas_client",
25-
version="0.1.14",
25+
version="0.1.15",
2626
project_urls={
2727
"Documentation": "https://www.scaleway.com/en/quantum-as-a-service/",
2828
"Source": "https://github.com/scaleway/scaleway-qaas-client-pythom",

tests/test_api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import time
1616
import uuid
1717

18-
from scaleway_qaas_client import QaaSClient
18+
from scaleway_qaas_client.v1alpha1 import QaaSClient
1919

2020
_RANDOM_UUID = str(uuid.uuid4())
2121
_TEST_PLATFORM_NAME = os.environ.get("TEST_PLATFORM_NAME", "aer_simulation_pop_c16m128")

0 commit comments

Comments
 (0)