Kaynağa Gözat

avoid gettext warnings

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@44024 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa 14 yıl önce
ebeveyn
işleme
a99926b02a
2 değiştirilmiş dosya ile 4 ekleme ve 3 silme
  1. 2 2
      lib/python/raster.py
  2. 2 1
      lib/python/vector.py

+ 2 - 2
lib/python/raster.py

@@ -47,8 +47,8 @@ def raster_history(map):
         run_command('r.support', map = map, history = os.environ['CMDLINE'])
         return True
     
-    warning(_("Unable to write history for <%s>. "
-              "Raster map <%s> not found in current mapset." % (map, map)))
+    warning(_("Unable to write history for <%(map)s>. "
+              "Raster map <%(map)s> not found in current mapset." % { 'map' : map, 'map' : map}))
     return False
 
 # run "r.info -rgstmpud ..." and parse output

+ 2 - 1
lib/python/vector.py

@@ -183,7 +183,8 @@ def vector_db_select(map, layer = 1, **kwargs):
     try:
         key = vector_db(map = map)[layer]['key']
     except KeyError:
-        error(_('Missing layer %d in vector map <%s>') % (layer, map))
+        error(_('Missing layer %(layer)d in vector map <%(map)s>') % \
+                  { 'layer' : layer, 'map' : map })
         return { 'columns' : [], 'values' : {} }
         
     if kwargs.has_key('columns'):