Skip to content
Snippets Groups Projects
Commit 4a31f85c authored by Xavier Morel's avatar Xavier Morel
Browse files

[FIX] base_import: CSV import error from windows

Missing bit from #10374: because the _read_xls function is a generator
it is *entirely* lazy and Python doesn't execute *any* code when it's
initially called, which means the file is actually (tentatively) parsed
when the first line is requested which happens outside of
_read_file (and thus of the fallback mechanism implemented by #10374).

Fix by splitting _read_xls between the opening of the workbook (eager)
and the actual iteration (which remains lazy).
parent 3b26d1e2
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment