Skip to content

Commit bf044aa

Browse files
authored
Fix UnboundLocalError when saving model to model catalog (#497)
2 parents 68c9ec4 + 88b299f commit bf044aa

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

ads/catalog/model.py

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -82,11 +82,11 @@
8282
_WORK_REQUEST_INTERVAL_IN_SEC = 3
8383

8484

85-
class ModelWithActiveDeploymentError(Exception): # pragma: no cover
85+
class ModelWithActiveDeploymentError(Exception): # pragma: no cover
8686
pass
8787

8888

89-
class ModelArtifactSizeError(Exception): # pragma: no cover
89+
class ModelArtifactSizeError(Exception): # pragma: no cover
9090
def __init__(self, max_artifact_size: str):
9191
super().__init__(
9292
f"The model artifacts size is greater than `{max_artifact_size}`. "
@@ -391,7 +391,6 @@ def show_in_notebook(self, display_format: str = "dataframe") -> None:
391391
Nothing.
392392
"""
393393
if display_format == "dataframe":
394-
395394
from IPython.core.display import display
396395

397396
display(self.to_dataframe())
@@ -1560,9 +1559,9 @@ def _wait_for_work_request(
15601559
if work_request_logs:
15611560
new_work_request_logs = work_request_logs[i:]
15621561

1563-
for wr_item in new_work_request_logs:
1564-
progress.update(wr_item.message)
1565-
i += 1
1562+
for wr_item in new_work_request_logs:
1563+
progress.update(wr_item.message)
1564+
i += 1
15661565

15671566
if work_request.data.status in STOP_STATE:
15681567
if work_request.data.status != WorkRequest.STATUS_SUCCEEDED:

0 commit comments

Comments
 (0)