[GRASS-dev] Re: module problem in wxgui

Martin Landa landa.martin at gmail.com
Tue Oct 23 04:01:53 EDT 2007


Hi,

I am not sure if there is a replacement for xmlproc which can be used
for validation of xml file. I found useful only xmlproc. expat seems
to be a non-validation parser.

"xmlproc is a Python native parser that performs nearly complete
validation. If you need a validating parser, xmlproc is currently your
only choice in Python. Further, xmlproc provides a variety of
high-level and experimental interfaces that other parsers do not."

For now xml validation is disabled...

Martin


2007/10/23, Michael Barton <michael.barton at asu.edu>:
> Martin,
>
> xmlproc is not available on my Mac version of Python 2.5. See below. I've
> got xml.dom, xml.etree, xml.parsers, and xml.sax.
>
> Within xml.parsers is only expat
>
> cmb-MBP-2:~ cmbarton$ python
> Python 2.5.1 (r251:54869, Apr 18 2007, 22:08:04)
> [GCC 4.0.1 (Apple Computer, Inc. build 5367)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import xml.parsers
> >>> import xml.parsers.xmlproc
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
> ImportError: No module named xmlproc
> >>> help(xml.parsers)
>
> Help on package xml.parsers in xml:
>
> NAME
>     xml.parsers - Python interfaces to XML parsers.
>
> FILE
>
> /Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/xml/parsers/
> __init__.py
>
> MODULE DOCS
>     http://www.python.org/doc/current/lib/module-xml.parsers.html
>
> DESCRIPTION
>     This package contains one module:
>
>     expat -- Python wrapper for James Clark's Expat parser, with namespace
>              support.
>
> PACKAGE CONTENTS
>     expat
>
>
> Michael
>
> On 10/22/07 12:35 AM, "Martin Landa" <landa.martin at gmail.com> wrote:
>
> > Hi,
> >
> > 2007/10/22, Michael Barton <michael.barton at asu.edu>:
> >>
> >>  Hi Martin,
> >>
> >>  I'm trying to get gis_set.py to work. I came across this error in trying to
> >> start up.
> >>
> >>  Traceback (most recent call last):
> >>    File
> >> "/Applications/Grass/GRASS-6.3.app/Contents/MacOS/etc/wx/wxgui.py",
> >> line 33, in <module>
> >>      from xml.parsers.xmlproc import xmlproc
> >>  ImportError: No module named xmlproc
> >>
> >>  I have xml.parsers but not xml.parsers.xmlproc
> >
> > xml.parser.xmlproc is currently used for validation of grc xml
> > workspace file. xmlproc should be standard part of python-xml.
> >
> > Martin
> >
> >>
> >>  Michael
> >>
> >>  __________________________________________
> >>  Michael Barton, Professor of Anthropology
> >>  Director of Graduate Studies
> >>  School of Human Evolution & Social Change
> >>  Center for Social Dynamics & Complexity
> >>  Arizona State University
> >>
> >>  phone: 480-965-6213
> >>  fax: 480-965-7671
> >>  www: http://www.public.asu.edu/~cmbarton
> >>
> >>
> >
>
> __________________________________________
> Michael Barton, Professor of Anthropology
> Director of Graduate Studies
> School of Human Evolution & Social Change
> Center for Social Dynamics & Complexity
> Arizona State University
>
> phone: 480-965-6213
> fax: 480-965-7671
> www: http://www.public.asu.edu/~cmbarton
>
>
>


-- 
Martin Landa <landa.martin at gmail.com> * http://gama.fsv.cvut.cz/~landa *




More information about the grass-dev mailing list