Hi,
2011/4/13 Mathieu Baudier <mbaudier@argeo.org>:
ignoredDelimiter = ignoredDelimiter if ignoredDelimiter is not None else ''
[...]
On CentOS 5 (and RHEL 5 and Scientific Linux 5), the python version is 2.4.3.
We use wxPython from the EPEL repository (version 2.8.11).
python 2.4 doesn't support these kind of statements, it can be fixed by
if if ignoredDelimiter is None:
ignoredDelimiter = ''
done in r45959
There is important question: shouldn't we change requirement from
python 2.4 to python 2.5 [1]. Beside reported issue, python 2.5 comes
with ctypes included. I would personally vote to change requirement
for GRASS 6.4.2 to python 2.5 (released in Sep 2006).
Martin
[1] http://trac.osgeo.org/grass/browser/grass/branches/releasebranch_6_4/REQUIREMENTS.html
--
Martin Landa <landa.martin gmail.com> * http://geo.fsv.cvut.cz/~landa
Hi,
2011/4/13 Mathieu Baudier <mbaudier@argeo.org>:
if if ignoredDelimiter is None:
ignoredDelimiter = ''
Thanks a lot, I will try to patch it.
probably you will find more such statements in the code (see eg.
r45962). In that case, could you send a patch which I could apply in
SVN?
Thanks, Martin
--
Martin Landa <landa.martin gmail.com> * http://geo.fsv.cvut.cz/~landa
Hi,
2011/4/13 Mathieu Baudier <mbaudier@argeo.org>:
http://trac.osgeo.org/grass/browser/grass/trunk/gui/wxpython?
yes,
wxpython/wxgui.py
and
wxpython/gui_modules/*py.
Thanks, Martin
--
Martin Landa <landa.martin gmail.com> * http://geo.fsv.cvut.cz/~landa
Martin Landa wrote:
> On CentOS 5 (and RHEL 5 and Scientific Linux 5), the python version is 2.4.3.
> We use wxPython from the EPEL repository (version 2.8.11).
python 2.4 doesn't support these kind of statements, it can be fixed by
if if ignoredDelimiter is None:
ignoredDelimiter = ''
done in r45959
There is important question: shouldn't we change requirement from
python 2.4 to python 2.5 [1].
I feel that we should support 2.4 unless doing so becomes particularly
burdensome. Lack of "x if t else y" doesn't qualify, IMHO.
Beside reported issue, python 2.5 comes with ctypes included.
Regardless of version, we shouldn't assume the availability of ctypes.
The core wxGUI should work without it.
One of the main issues is that some systems remove ctypes for security
or reliability reasons. As a matter of policy, nothing in Python's
standard library uses ctypes.
--
Glynn Clements <glynn@gclements.plus.com>
On Thu, Apr 14, 2011 at 1:02 PM, Mathieu Baudier <mbaudier@argeo.org> wrote:
...
I applied your fixes from yesterday (rev 45959 to 45964 from the 6.4
release branch) and the wxPython UI now starts properly (an updated
version is now available in the ELGIS testing repository).
Thanks for your efforts, Mathieu, and the quick packaging!
Markus
if if ignoredDelimiter is None:
ignoredDelimiter = ''
Thanks a lot, I will try to patch it.
I'm packaging GRASS for the Enterprise Linux GIS effort:
http://wiki.osgeo.org/wiki/Enterprise_Linux_GIS
with ctypes included. I would personally vote to change requirement
for GRASS 6.4.2 to python 2.5 (released in Sep 2006).
Then GRASS wx UI would be harder to support on Enterprise Linux 5 (Red
Hat Enterprise Linux, CentOS, Scientific Linux).
A python26 package is available in the EPEL repository, but we would
then need to rebuild wxPython as well etc.
I just point to that in order to underscore the impact such changes
have on "old but stable" distributions.
Thanks again for your quick answer!
Mathieu
probably you will find more such statements in the code (see eg.
r45962). In that case, could you send a patch which I could apply in
SVN?
I will try
(but maybe not before a few days: I just quickly packaged GRASS 6.4.1
when I saw that it was out, and I don't have time right now to dig
into this issue).
In which area of the code should I search for such statements?
http://trac.osgeo.org/grass/browser/grass/trunk/gui/wxpython?
and sub directories as well?
if if ignoredDelimiter is None:
ignoredDelimiter = ''
Thanks a lot, I will try to patch it.
probably you will find more such statements in the code (see eg.
r45962). In that case, could you send a patch which I could apply in
SVN?
I applied your fixes from yesterday (rev 45959 to 45964 from the 6.4
release branch) and the wxPython UI now starts properly (an updated
version is now available in the ELGIS testing repository).
I did various searches for other ternary operators but could not find any other.
So maybe the issue will happen again when executing some actions, but
at least the UI is now usable (I quickly opened a map set).
Thanks again for your quick help!
Mathieu
PS: for reference, the description of this feature available in Python
2.5 but not in Python 2.4:
http://www.python.org/dev/peps/pep-0308/