Skip to content

Commit 097abff

Browse files
🐛 Fix osparc wrapper issues due to openapi.json update (#230)
1 parent 0cc39f6 commit 097abff

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

.github/workflows/build-python-client.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ jobs:
6565
strategy:
6666
max-parallel: 4
6767
matrix:
68-
python-version: [3.8, 3.9, 3.10.14]
68+
python-version: [3.9, 3.10.14, 3.11]
6969
steps:
7070
- uses: actions/checkout@v3
7171
- name: Set up Python ${{ matrix.python-version }}

clients/python/src/osparc/_api_files_api.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
FileUploadCompletionBody,
2626
FileUploadData,
2727
UploadedPart,
28+
UserFile,
2829
)
2930
from urllib.parse import urljoin
3031
import aiofiles
@@ -150,11 +151,12 @@ async def upload_file_async(
150151
# if a file has the same sha256 checksum
151152
# and name they are considered equal
152153
return file_result
153-
client_file: ClientFile = ClientFile(
154+
user_file = UserFile(
154155
filename=file.name,
155156
filesize=file.stat().st_size,
156157
sha256_checksum=checksum,
157158
)
159+
client_file = ClientFile(user_file)
158160
client_upload_schema: ClientFileUploadData = super().get_upload_links(
159161
client_file=client_file, _request_timeout=timeout_seconds, **kwargs
160162
)

clients/python/src/osparc/_api_solvers_api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ def iter_jobs(self, solver_key: str, version: str, **kwargs) -> PaginationIterab
7777
"""
7878

7979
def _pagination_method():
80-
return super(SolversApi, self).get_jobs_page(
80+
return super(SolversApi, self).list_jobs_paginated(
8181
solver_key=solver_key,
8282
version=version,
8383
limit=_DEFAULT_PAGINATION_LIMIT,

clients/python/src/osparc/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@
5959
from osparc_client.models.users_group import UsersGroup as UsersGroup
6060
from osparc_client.models.validation_error import ValidationError as ValidationError
6161
from osparc_client.models.wallet_status import WalletStatus as WalletStatus
62-
62+
from osparc_client.models.user_file import UserFile as UserFile
6363
from ._models import JobInputs as JobInputs
6464
from ._models import JobOutputs as JobOutputs
6565
from ._models import JobMetadata as JobMetadata

0 commit comments

Comments
 (0)