[GRASSGUI] Re: [GRASS-dev] wxgrass prototype
Daniel Calvelo
dca.gis at gmail.com
Thu Mar 22 05:56:52 EDT 2007
Moritz, that's SAX not finding its DTD file. Try this patch:
--- menuform.py 2007-03-22 04:51:49.000000000 -0500
+++ mff.py 2007-03-22 04:55:08.000000000 -0500
@@ -578,7 +578,7 @@
cmd = cmd + r' --interface-description'
cmdout = os.popen(cmd, "r").read()
p = re.compile( '(grass-interface.dtd)')
- cmdout2 = p.sub( gmpath+r'/grass-interface.dtd', cmdout)
+ cmdout2 = p.sub( gmpath+r'grass-interface.dtd', cmdout)
handler = processTask()
xml.sax.parseString(cmdout2, handler)
Daniel.
On 3/22/07, Moritz Lennert <mlennert at club.worldonline.be> wrote:
> On 22/03/07 10:21, Daniel Calvelo wrote:
> > Hi Moritz,
> >
> > As a temporary workaround, revert to revision 239 in svn:
> >
> > svn update -r 239 gism.py
>
> Yes, thanks, now I can start wxgrass again.
>
> Good news: I can now add several layers !
>
> Bad news: whenever I add a layer I get (for raster this is +/- the same):
>
> GRASS 6.3.cvs (BELGIQUE):~ > Traceback (most recent call last):
> File "/usr/lib/grass/etc/wx/gism.py", line 363, in addVector
> self.SetTree('vector')
> File "/usr/lib/grass/etc/wx/gism.py", line 378, in SetTree
> self.maptree.AddLayer(disp_idx, layertype)
> File "/usr/lib/grass/etc/wx/Gism/gismutils.py", line 150, in AddLayer
> menuform.GUI().parseCommand('d.vect', gmpath,
> completed=(self.getOptData,layer), parentframe=self)
> File "/usr/lib/grass/etc/wx/Gism/menuform.py", line 535, in parseCommand
> xml.sax.parseString(cmdout2, handler)
> File "/usr/lib/python2.4/site-packages/_xmlplus/sax/__init__.py",
> line 47, in parseString
> parser.parse(inpsrc)
> File "/usr/lib/python2.4/site-packages/_xmlplus/sax/expatreader.py",
> line 109, in parse
> xmlreader.IncrementalParser.parse(self, source)
> File "/usr/lib/python2.4/site-packages/_xmlplus/sax/xmlreader.py",
> line 123, in parse
> self.feed(buffer)
> File "/usr/lib/python2.4/site-packages/_xmlplus/sax/expatreader.py",
> line 216, in feed
> self._parser.Parse(data, isFinal)
> File "/usr/lib/python2.4/site-packages/_xmlplus/sax/expatreader.py",
> line 395, in external_entity_ref
> self._source.getSystemId() or
> File "/usr/lib/python2.4/site-packages/_xmlplus/sax/saxutils.py",
> line 523, in prepare_input_source
> f = urllib2.urlopen(source.getSystemId())
> File "/usr/lib/python2.4/urllib2.py", line 130, in urlopen
> return _opener.open(url, data)
> File "/usr/lib/python2.4/urllib2.py", line 350, in open
> protocol = req.get_type()
> File "/usr/lib/python2.4/urllib2.py", line 233, in get_type
> raise ValueError, "unknown url type: %s" % self.__original
> ValueError: unknown url type:
> /usr/lib/grass/etc/wx/gism//grass-interface.dtd
>
> Moritz
>
--
-- Daniel Calvelo Aros
More information about the grass-gui
mailing list