Issue
What is the issue?
parse_export_format() in application/utils/spreadsheet_parsers.py calls validate_export_csv_rows() on line 206, but that function is never defined anywhere in the codebase. The only validation function that exists is validate_import_csv_rows() (line 136, same file).
This was introduced in commit 605bb6d during the CSV validation refactor (PR #682), where the function was defined under one name but called under another.
Expected Behaviour
Calling POST /rest/v1/cre_csv_import with a valid CSV file should run validation and import the data.
Actual Behaviour
Every call to parse_export_format() raises:
NameError: name 'validate_export_csv_rows' is not defined
The import endpoint is completely broken. The existing unit test test_parse_export_format also fails immediately for the same reason.
Steps to reproduce
POST /rest/v1/cre_csv_import
with any CSV file. The 500 is raised before any CSV content is inspected.
Issue
What is the issue?
parse_export_format()inapplication/utils/spreadsheet_parsers.pycallsvalidate_export_csv_rows()on line 206, but that function is never defined anywhere in the codebase. The only validation function that exists isvalidate_import_csv_rows()(line 136, same file).This was introduced in commit 605bb6d during the CSV validation refactor (PR #682), where the function was defined under one name but called under another.
Expected Behaviour
Calling
POST /rest/v1/cre_csv_importwith a valid CSV file should run validation and import the data.Actual Behaviour
Every call to
parse_export_format()raises:The import endpoint is completely broken. The existing unit test
test_parse_export_formatalso fails immediately for the same reason.Steps to reproduce
with any CSV file. The 500 is raised before any CSV content is inspected.