Skip to content

Commit

Permalink
Change cluster errors from NetworkError to UserError (#1586)
Browse files Browse the repository at this point in the history
  • Loading branch information
irenedea authored Oct 11, 2024
1 parent e6e74a2 commit aad13c4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions llmfoundry/utils/exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -310,15 +310,15 @@ def __init__(self, input: dict) -> None:


## Convert Delta to JSON exceptions
class ClusterDoesNotExistError(NetworkError):
class ClusterDoesNotExistError(UserError):
"""Error thrown when the cluster does not exist."""

def __init__(self, cluster_id: str) -> None:
message = f'Cluster with id {cluster_id} does not exist. Check cluster id and try again!'
super().__init__(message, cluster_id=cluster_id)


class ClusterInvalidAccessMode(NetworkError):
class ClusterInvalidAccessMode(UserError):
"""Error thrown when the cluster does not exist."""

def __init__(self, cluster_id: str, access_mode: str) -> None:
Expand Down

0 comments on commit aad13c4

Please sign in to comment.