Skip to content

Commit 69346bd

Browse files
committed
@GitHK review: fix wrong type and deprecation
1 parent 03fbccf commit 69346bd

File tree

3 files changed

+12
-15
lines changed

3 files changed

+12
-15
lines changed

packages/aws-library/src/aws_library/s3/__init__.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222
)
2323

2424
__all__: tuple[str, ...] = (
25-
"CopiedBytesTransferredCallback",
26-
"MultiPartUploadLinks",
2725
"PRESIGNED_LINK_MAX_SIZE",
2826
"S3_MAX_FILE_SIZE",
27+
"CopiedBytesTransferredCallback",
28+
"MultiPartUploadLinks",
2929
"S3AccessError",
3030
"S3BucketInvalidError",
3131
"S3DestinationNotEmptyError",
@@ -37,8 +37,8 @@
3737
"S3RuntimeError",
3838
"S3UploadNotFoundError",
3939
"SimcoreS3API",
40-
"UploadedBytesTransferredCallback",
4140
"UploadID",
41+
"UploadedBytesTransferredCallback",
4242
)
4343

4444
# nopycln: file

packages/models-library/src/models_library/projects_nodes.py

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -238,20 +238,21 @@ class Node(BaseModel):
238238
Field(description="The short name of the node", examples=["JupyterLab"]),
239239
]
240240
progress: Annotated[
241-
int | None,
241+
float | None,
242242
Field(
243243
ge=0,
244244
le=100,
245-
description="the node progress value (deprecated in DB, still used for API only)",
246-
deprecated=True, # <-- Think this is not true, it is still used by the File Picker (frontend nodes)
245+
description="the node progress value",
246+
deprecated=True, # NOTE: still used in the File Picker (frontend nodes) and must be removed first from there before retiring it here
247247
),
248248
] = None
249249

250-
thumbnail: Annotated[ # <-- (DEPRECATED) Can be removed
250+
thumbnail: Annotated[
251251
str | HttpUrl | None,
252252
Field(
253253
description="url of the latest screenshot of the node",
254254
examples=["https://placeimg.com/171/96/tech/grayscale/?0.jpg"],
255+
deprecated=True,
255256
),
256257
] = None
257258

@@ -316,7 +317,7 @@ class Node(BaseModel):
316317
deprecated=True,
317318
alias="outputNode",
318319
),
319-
] = None # <-- (DEPRECATED) Can be removed
320+
] = None
320321

321322
output_nodes: Annotated[ # <-- (DEPRECATED) Can be removed
322323
list[NodeID] | None,
@@ -327,7 +328,7 @@ class Node(BaseModel):
327328
),
328329
] = None
329330

330-
parent: Annotated[ # <-- (DEPRECATED) Can be removed
331+
parent: Annotated[
331332
NodeID | None,
332333
Field(
333334
description="Parent's (group-nodes') node ID s. Used to group",

services/api-server/src/simcore_service_api_server/models/domain/projects.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,12 @@
44
from models_library.projects_nodes import InputTypes, Node, OutputTypes
55
from models_library.projects_nodes_io import SimCoreFileLink
66

7-
assert AccessRights # nosec
8-
assert InputTypes # nosec
9-
assert Node # nosec
10-
assert OutputTypes # nosec
11-
assert SimCoreFileLink # nosec
12-
137
__all__: tuple[str, ...] = (
148
"AccessRights",
159
"InputTypes",
1610
"Node",
1711
"OutputTypes",
1812
"SimCoreFileLink",
1913
)
14+
15+
# nopycln: file

0 commit comments

Comments
 (0)