[Qgis-user] [Fwd: Python problem]

Martin Dobias wonder.sk at gmail.com
Sun May 25 07:18:51 PDT 2008


Hi Paolo,

On Sun, May 25, 2008 at 2:22 PM, Paolo Cavallini <cavallini at faunalia.it> wrote:
> anyone knows the origin (nad maybe a solution) for this problem?
> all the best.
> pc
>
> -------- Messaggio Originale  --------
>
> An error has occured while executing Python code:
>
> Traceback (most recent call last):
> File "C:/Program Files/Quantum
> GIS/./python/plugins\plugin_installer\dialog.py", line 105, in installPlugin
>  plugindir = str(QgsApplication.qgisSettingsDirPath()) + "/python/plugins"
> UnicodeEncodeError: 'ascii' codec can't encode character u'\xf3' in
> position 29: ordinal not in range(128)

this will be caused by some non-ascii characters in path reported by
qgisSettingsDirPath(). Please try changing this expression:
str(QgsApplication.qgisSettingsDirPath())
to:
unicode(QgsApplication.qgisSettingsDirPath(),'utf-8')

... and let me know whether it helps, I can do the same also in trunk.

Martin



More information about the Qgis-user mailing list