Skip to content

Commit bc8e501

Browse files
committed
[IMP] export_bg: clean data rows before writing to Excel
closes #363 X-original-commit: 69042b2 Signed-off-by: Filoquin adhoc <maq@adhoc.com.ar> Signed-off-by: Franco Leyes <lef@adhoc.com.ar>
1 parent 04a5e1f commit bc8e501

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

export_bg/models/export_bg_mixin.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,8 @@ def _combine_chunks(self, export_id, export_format):
129129
ws.write_row(0, 0, chunk_data["headers"])
130130
row_num = 1
131131
for row in chunk_data["rows"]:
132-
ws.write_row(row_num, 0, row)
132+
cleaned_row = [str(cell) if isinstance(cell, (dict, list)) else cell for cell in row]
133+
ws.write_row(row_num, 0, cleaned_row)
133134
row_num += 1
134135
wb.close()
135136
chunks.unlink()

0 commit comments

Comments
 (0)