From 22c3d8069244000aa40cd92385a7a31588f44aca Mon Sep 17 00:00:00 2001 From: Katon Minhas Date: Mon, 2 Mar 2026 19:53:16 +0000 Subject: [PATCH] Merged in feature/update-postprocessing-columns (pull request #893) move column order to final step * move column order to final step * Black Approved-by: Siddhant Medar --- src/pipelines/shared/postprocessing/postprocess.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/pipelines/shared/postprocessing/postprocess.py b/src/pipelines/shared/postprocessing/postprocess.py index e3cb3a0..542a106 100644 --- a/src/pipelines/shared/postprocessing/postprocess.py +++ b/src/pipelines/shared/postprocessing/postprocess.py @@ -136,9 +136,6 @@ def standard_postprocess(df, constants: Constants): df = postprocessing_funcs.attach_sid_column(df) - # Standardize output column order - this should ALWAYS be the final postprocessing step - df = postprocessing_funcs.reorder_columns(df, FIELD_FORMAT_MAPPING) - df["FILE_NAME"] = df["FILE_NAME"].apply(postprocessing_funcs.standardize_file_name) # This will remove non-standard characters from every cell in the DataFrame @@ -147,6 +144,8 @@ def standard_postprocess(df, constants: Constants): # Remove N/A values from all columns (standard cleaning for all outputs) df = postprocessing_funcs.clean_na_values(df) + # Standardize output column order - this should ALWAYS be the final postprocessing step + df = postprocessing_funcs.reorder_columns(df, FIELD_FORMAT_MAPPING) return df