Bug report #1048

Mapserver export writes file in wrong encoding

Added by Redmine Admin about 16 years ago. Updated almost 15 years ago.

Assignee:nobody -
Affected QGIS version: Regression?:No
Operating System:All Easy fix?:No
Pull Request or Patch supplied: Resolution:fixed
Crashes QGIS or corrupts data: Copied to github as #:11108


Not all character strings in files .map exported by Mapserver are in UTF-8 enocoding. Strings in LAYER object are exported correctly but non-Latin1 characters used in WEB object and in heading of document ("NAME" of MAP object) are replaced by "?".


#1 Updated by Paolo Cavallini over 15 years ago

The plugin has been replaced by a new one, written in python.
However, essentially the same problem seems to occur, as I get an error when trying to export a project with a high ascii in layer neme (città):
An error has occured while executing Python code:

Traceback (most recent call last):
File "/usr/share/qgis/python/plugins/mapserver_export/mapserverexport.py", line 94, in run
result = exporter.writeMapFile()
File "/usr/share/qgis/python/plugins/mapserver_export/ms_export.py", line 103, in writeMapFile
File "/usr/share/qgis/python/plugins/mapserver_export/ms_export.py", line 380, in writeMapLayers
layer_def += self.simpleRenderer(lyr, symbolNode)
File "/usr/share/qgis/python/plugins/mapserver_export/ms_export.py", line 420, in simpleRenderer
class_def += " OUTLINECOLOR " + outlineNode.getAttribute('red') + ' ' + outlineNode.getAttribute('green') + ' ' + outlineNode.getAttribute('blue') + "\
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 27: ordinal not in range(128)

#2 Updated by Martin Dobias over 15 years ago

  • Resolution set to fixed
  • Status changed from Open to Closed

Fixed in (trunk) and (1.0 branch)

#3 Updated by Anonymous almost 15 years ago

Milestone Version 1.0.1 deleted

Also available in: Atom PDF