From 677e7a23462a18021c6232a3697e1ad1ef04fc70 Mon Sep 17 00:00:00 2001 From: Aman Singh Rawat Date: Mon, 12 Jan 2026 12:20:39 +0530 Subject: [PATCH 1/2] Fix return type of read_folder function --- dskit/io.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dskit/io.py b/dskit/io.py index 8e8c9c7..2f7240b 100644 --- a/dskit/io.py +++ b/dskit/io.py @@ -29,7 +29,8 @@ def load(filepath): def read_folder(folder_path, file_type='csv'): """ - Loads multiple files from a folder and concatenates them. + Load multiple files from a folder and returns + a list of pandas Dataframe. """ if not os.path.exists(folder_path): raise FileNotFoundError(f"The folder '{folder_path}' was not found.") @@ -47,7 +48,7 @@ def read_folder(folder_path, file_type='csv'): df_list.append(df) if df_list: - return pd.concat(df_list, ignore_index=True) + return df_list else: return None From 2df34210c227d19d6cf3c9d8b2b51245bb694c15 Mon Sep 17 00:00:00 2001 From: Aman Singh Rawat Date: Mon, 12 Jan 2026 15:15:54 +0530 Subject: [PATCH 2/2] Apply suggestion from @Copilot Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- dskit/io.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dskit/io.py b/dskit/io.py index 2f7240b..412008c 100644 --- a/dskit/io.py +++ b/dskit/io.py @@ -29,8 +29,8 @@ def load(filepath): def read_folder(folder_path, file_type='csv'): """ - Load multiple files from a folder and returns - a list of pandas Dataframe. + Load multiple files from a folder and return + a list of pandas DataFrames. """ if not os.path.exists(folder_path): raise FileNotFoundError(f"The folder '{folder_path}' was not found.")