mirror of
https://github.com/kennethreitz/tablib.git
synced 2026-06-05 23:10:17 +00:00
remove file must be close it.
in windows if you don't close template file, remove it will raise WindowsError: [Error 32]
This commit is contained in:
@@ -55,6 +55,7 @@ def export_set(dataset):
|
||||
else:
|
||||
stream = StringIO(dbf_stream.read())
|
||||
dbf_stream.close()
|
||||
os.close(temp_file)
|
||||
os.remove(temp_uri)
|
||||
return stream.getvalue()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user