Skip to content

Commit a0622c1

Browse files
committed
update ui print message
to not confuse users about container vs. model IDs
1 parent 62a24c6 commit a0622c1

File tree

3 files changed

+4
-5
lines changed

3 files changed

+4
-5
lines changed

cli/medperf/commands/mlcube/delete_keys.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def __init__(self, container_id: int, approved: bool = False):
1919
def get_approval(self):
2020
msg = (
2121
"Please confirm that you wish to revoke access to the "
22-
f"container {self.container_id} by deleting all its keys."
22+
"container by deleting all its keys."
2323
)
2424

2525
if not self.approved and not approval_prompt(msg):

cli/medperf/commands/mlcube/grant_access.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def get_approval(self):
5959
msg = (
6060
f"Please confirm that you wish to give all Data Owners "
6161
f"registered in Benchmark (UID: {self.benchmark_id}) access to "
62-
f"the Model (UID: {self.model_id}).\n"
62+
"your Model.\n"
6363
)
6464

6565
if not self.approved and not approval_prompt(msg):

cli/medperf/entities/encrypted_key.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,8 @@ def get_user_container_key(cls, container_id: int) -> EncryptedKey:
5555
user_cert.id, filters=filters
5656
)
5757
if len(keys) == 0:
58-
raise PrivateContainerAccessError(
59-
f"You don't have access to the container {container_id}"
60-
)
58+
logging.debug(f"No keys found for container {container_id}")
59+
raise PrivateContainerAccessError("You don't have access to the container")
6160

6261
if len(keys) > 1:
6362
raise MedperfException("Internal error: expected only one key.")

0 commit comments

Comments
 (0)