Skip to content

Commit 4e69b43

Browse files
author
Andrei Neagu
committed
refactor
1 parent b886131 commit 4e69b43

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/models-library/src/models_library/utils/labels_annotations.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ def to_labels(
2828
"""converts config into labels annotations"""
2929

3030
# FIXME: null is loaded as 'null' string value? is that correct? json -> None upon deserialization?
31-
labels = {}
31+
labels: LabelsAnnotationsDict = {}
3232
for key, value in config.items():
3333
if trim_key_head:
3434
if isinstance(value, str):
@@ -57,7 +57,7 @@ def from_labels(
5757
for key, label in labels.items():
5858
if key.startswith(f"{prefix_key}."):
5959
try:
60-
value = json.loads(label)
60+
value = json.loads(label) # type: ignore
6161
except JSONDecodeError:
6262
value = label
6363

0 commit comments

Comments
 (0)