changeset 97d96f59c229 in modules/account_fr:default
details:
https://hg.tryton.org/modules/account_fr?cmd=changeset;node=97d96f59c229
description:
Pass iterable to writerow instead of a list
This reduce the memory consumption.
issue8874
review276461003
diffstat:
account.py | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diffs (16 lines):
diff -r 4f2f60404654 -r 97d96f59c229 account.py
--- a/account.py Wed Dec 04 11:09:35 2019 +0100
+++ b/account.py Fri Dec 13 23:10:22 2019 +0100
@@ -112,10 +112,10 @@
convert = replace_delimiter
for row in self.get_start_balance():
- writer.writerow(list(map(convert, row)))
+ writer.writerow(map(convert, row))
for line in self.get_lines():
row = self.get_row(line, format_date, format_number)
- writer.writerow(list(map(convert, row)))
+ writer.writerow(map(convert, row))
value = fec.getvalue()
if not isinstance(value, bytes):
value = value.encode('utf-8')