[GRASS-dev] [GRASS GIS] #2875: Python testsuite failing with UnicodeDecodeError

GRASS GIS trac at osgeo.org
Mon Jan 25 05:08:10 PST 2016


#2875: Python testsuite failing with UnicodeDecodeError
--------------------+-------------------------
 Reporter:  marisn  |      Owner:  grass-dev@…
     Type:  defect  |     Status:  new
 Priority:  normal  |  Milestone:  7.1.0
Component:  Tests   |    Version:  svn-trunk
 Keywords:          |        CPU:  Unspecified
 Platform:  Linux   |
--------------------+-------------------------
 Unfortunately it is not possible to run tests as test suite is failing
 itself (has anyone written tests for test suite?):

 {{{
 ERROR: test_seed_required (__main__.TestRandFunction)
 Test that seed is required when rand() is used
 ----------------------------------------------------------------------
 Traceback (most recent call last):
   File "raster/r.mapcalc/testsuite/test_r_mapcalc.py", line 99, in
 test_seed_required
     self.assertModuleFail('r.mapcalc', expression='rand_x = rand(1, 200)')
   File "/home/maris/soft/grass_trunk/dist.x86_64-pc-linux-
 gnu/etc/python/grass/gunittest/case.py", line 1180, in assertModuleFail
     module.run()
   File "/home/maris/soft/grass_trunk/dist.x86_64-pc-linux-
 gnu/etc/python/grass/pygrass/modules/interface/module.py", line 713, in
 run
     module=self.name, errors=stderr)
   File "/home/maris/soft/grass_trunk/dist.x86_64-pc-linux-
 gnu/etc/python/grass/exceptions/__init__.py", line 71, in __init__
     msg += _(". See the following errors:\n%s") % errors
 UnicodeDecodeError: 'ascii' codec can't decode byte 0xc4 in position 29:
 ordinal not in range(128)
 }}}

 The largest question is - should there be strings for translation at all?
 I think not as most of low level errors and debug information is not
 marked for translation. Tests should be run by developers not end users
 thus I don't see a point in translating such strings.

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/2875>
GRASS GIS <https://grass.osgeo.org>



More information about the grass-dev mailing list