Martin-Jung / LecoS

LecoS QGis Plugin - Contains several analytical functions for land cover analysis
GNU General Public License v3.0
21 stars 19 forks source link

Fixed CSV quotechar #26

Closed pzatelli closed 1 year ago

pzatelli commented 1 year ago

I fixed the (missing) quote character (quotechar) when creating a CSV . The original code leads to

2023-05-16T13:08:37 WARNING Traceback (most recent call last): File "/home/paolo/.local/share/QGIS/QGIS3/profiles/default/python/plugins/LecoS/lecos_dlg.py", line 425, in accept func.saveToCSV(res,res_tit,dataPath) File "/home/paolo/.local/share/QGIS/QGIS3/profiles/default/python/plugins/LecoS/lecos_functions.py", line 68, in saveToCSV writer = csv.writer(f,delimiter=';',quotechar="",quoting=csv.QUOTE_NONE) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ TypeError: "quotechar" must be a 1-character string

and no CSV file is created.

Martin-Jung commented 1 year ago

Thanks!