[GRASS-SVN] r67323 - in grass/branches/releasebranch_7_0: gui/wxpython/gui_core lib/python/script

svn_grass at osgeo.org svn_grass at osgeo.org
Tue Dec 22 06:01:05 PST 2015


Author: annakrat
Date: 2015-12-22 06:01:05 -0800 (Tue, 22 Dec 2015)
New Revision: 67323

Modified:
   grass/branches/releasebranch_7_0/gui/wxpython/gui_core/forms.py
   grass/branches/releasebranch_7_0/lib/python/script/task.py
Log:
wxGUI: fix encoding issues (r67187, r67205, r67262 merged from trunk)

Modified: grass/branches/releasebranch_7_0/gui/wxpython/gui_core/forms.py
===================================================================
--- grass/branches/releasebranch_7_0/gui/wxpython/gui_core/forms.py	2015-12-22 11:37:49 UTC (rev 67322)
+++ grass/branches/releasebranch_7_0/gui/wxpython/gui_core/forms.py	2015-12-22 14:01:05 UTC (rev 67323)
@@ -2263,7 +2263,7 @@
                                    ignoreRequired = ignoreRequired)
         except ValueError as err:
             dlg = wx.MessageDialog(parent = self,
-                                   message = unicode(err),
+                                   message = gcmd.DecodeString(str(err)),
                                    caption = _("Error in %s") % self.task.name,
                                    style = wx.OK | wx.ICON_ERROR | wx.CENTRE)
             dlg.ShowModal()

Modified: grass/branches/releasebranch_7_0/lib/python/script/task.py
===================================================================
--- grass/branches/releasebranch_7_0/lib/python/script/task.py	2015-12-22 11:37:49 UTC (rev 67322)
+++ grass/branches/releasebranch_7_0/lib/python/script/task.py	2015-12-22 14:01:05 UTC (rev 67323)
@@ -32,7 +32,7 @@
 else:
     ETREE_EXCEPTIONS = (expat.ExpatError)
 
-from utils import decode
+from utils import encode, decode
 from core import *
 
 
@@ -200,7 +200,7 @@
                     if not desc:
                         desc = p['description']
                     errorList.append(_("Parameter '%(name)s' (%(desc)s) is missing.") % \
-                                     {'name': p['name'], 'desc': desc})
+                                     {'name': p['name'], 'desc': encode(desc)})
 
         return errorList
 



More information about the grass-commit mailing list