Skip to content

Commit d6b56c0

Browse files
Addressing review comments
1 parent 087312e commit d6b56c0

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

ads/model/datascience_model.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2499,7 +2499,9 @@ def get_custom_metadata_artifact(
24992499
artifact_file_path = os.path.join(target_dir, f"{metadata_key_name}")
25002500

25012501
if not override and is_path_exists(artifact_file_path):
2502-
raise FileExistsError(f"File already exists: {artifact_file_path}")
2502+
raise FileExistsError(
2503+
f"File already exists: {artifact_file_path}. Please use boolean override parameter to override the file content."
2504+
)
25032505

25042506
with open(artifact_file_path, "wb") as _file:
25052507
_file.write(file_content)
@@ -2538,7 +2540,9 @@ def get_defined_metadata_artifact(
25382540
artifact_file_path = os.path.join(target_dir, f"{metadata_key_name}")
25392541

25402542
if not override and is_path_exists(artifact_file_path):
2541-
raise FileExistsError(f"File already exists: {artifact_file_path}")
2543+
raise FileExistsError(
2544+
f"File already exists: {artifact_file_path}. Please use boolean override parameter to override the file content."
2545+
)
25422546

25432547
with open(artifact_file_path, "wb") as _file:
25442548
_file.write(file_content)

0 commit comments

Comments
 (0)