Hi Pietro,
the build log on a server which is creating the documentation is full of syntax errors in coming from pygrass. It’s actually just one error but in broadly used part (t.* as well as gunittest are affected). I guess that the other error is just the result of the first one (see end of email for tracebacks).
It seems that syntax:
grc = [“A: C”, “B: D”, “C: E”]
env = {k.strip(): v.strip() for k, v in [row.split(‘:’) for row in grc if row]}
env
{‘A’: ‘C’, ‘C’: ‘E’, ‘B’: ‘D’}
is not supported.
It seems to me that dictionary comprehension is not supported in Python 2.6 but I was not able to confirm this in the Python documentation.
I’m also not sure if the server still uses Python 2.6. Markus are you able to check this?
Thanks for looking into that,
Vaclav
[1] http://grass.osgeo.org/grass71/binary/linux/snapshot/build.log
Traceback (most recent call last):
File “…/scripts/t.vect.observe.strds”, line 51, in
import grass.temporal as tgis
File “…/etc/python/grass/temporal/init.py”, line 28, in
from temporal_algebra import *
File “…/etc/python/grass/temporal/temporal_algebra.py”, line 450, in
import grass.pygrass.modules as pymod
File “…/etc/python/grass/pygrass/modules/init.py”, line 2, in
from grass.pygrass.modules.interface import Module, ParallelModuleQueue
File “…/etc/python/grass/pygrass/modules/interface/init.py”, line 9, in
from grass.pygrass.modules.interface import module
File “…/etc/python/grass/pygrass/modules/interface/module.py”, line 16, in
from .env import G_debug
File “…/etc/python/grass/pygrass/modules/interface/env.py”, line 18
env = {k.strip(): v.strip() for k, v in [row.split(‘:’)
^
SyntaxError: invalid syntax
Traceback (most recent call last):
File “/usr/local/lib/python2.6/dist-packages/Sphinx-1.3.1-py2.6.egg/sphinx/ext/autodoc.py”, line 385, in import_object
import(self.modname)
File “…/etc/python/grass/temporal/init.py”, line 28, in
from temporal_algebra import *
File “…/etc/python/grass/temporal/temporal_algebra.py”, line 450, in
import grass.pygrass.modules as pymod
File “…/etc/python/grass/pygrass/modules/init.py”, line 2, in
from grass.pygrass.modules.interface import Module, ParallelModuleQueue
File “…/etc/python/grass/pygrass/modules/interface/init.py”, line 7, in
from grass.pygrass.modules.interface import flag
ImportError: cannot import name flag