Skip to content

Commit

Permalink
oops again
Browse files Browse the repository at this point in the history
  • Loading branch information
angel-ruiz7 committed May 31, 2024
1 parent b8492b7 commit 6586c8c
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions llmfoundry/utils/exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -361,9 +361,13 @@ def __init__(self, timeout: int) -> None:
class DatasetMissingFileError(UserError):
"""Error thrown when a dataset cannot find a file."""

def __init__(self, file_name: str, supported_extensions: Optional[List[str]]) -> None:
def __init__(
self,
file_name: str,
supported_extensions: Optional[List[str]] = None,
) -> None:
message = "Could not find the file '{file_name}' with any of the supported extensions: "
if supported_extensions is not None:
if supported_extensions is not None:
message += ', '.join(supported_extensions) + '.'
message += ' Please check your train / eval data and try again.'
super().__init__(message, file_name=file_name)
Expand Down

0 comments on commit 6586c8c

Please sign in to comment.