Skip to content

Commit

Permalink
feat: adds default missing return case
Browse files Browse the repository at this point in the history
  • Loading branch information
bhimrazy committed Jul 6, 2024
1 parent c8c88b9 commit 8248410
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/litdata/utilities/dataset_utilities.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ def load_index_file(input_dir: str) -> Dict[str, Any]:
data = json.load(f)
if "chunks" not in data:
raise KeyError(f"'chunks' not found in the index file at {index_filepath}.")
return data
except KeyError as e:
# Verify the presence of MDS shards
# For more details, refer to the MosaicML Streaming documentation: https://github.com/mosaicml/streaming
Expand Down

0 comments on commit 8248410

Please sign in to comment.