Open elgow opened 1 year ago
The temp file creation at pylightxl.py:191
f.write(fn.read()) fn = 'pylightxlIOtemp_wb.xlsx'
fails if the current directory is not writable. This can easily happen in a web server.
Python provides a standard way to create a temporory file with the tempfile module as follows:
with tempfile.NamedTemporaryFile(prefix='pylightxlIOtemp_wb', suffix='.xlsx', delete=False) as f: tmp_name = f.name f.write(fn.read()) fn = tmp_name
PR to follow.
The temp file creation at pylightxl.py:191
fails if the current directory is not writable. This can easily happen in a web server.
Python provides a standard way to create a temporory file with the tempfile module as follows:
PR to follow.