[GRASS-dev] porting r.in.wms to python

Glynn Clements glynn at gclements.plus.com
Sun Sep 28 19:00:58 EDT 2008


Hamish wrote:

> before anyone spends any time porting r.in.wms/r.tileset to python,

I was planning on leaving those until last ;)

Are there any other scripts which don't need to be converted?

g.mlist/g.mremove are low priority now that there is a C version.

Do {r,r3}.mapcalculator need to be kept? ISTR that the original
motivation was the fact that {r,r3}.mapcalc couldn't be run from the
GUI due to not using G_parser(), but that's no longer the case.

> I assume python has some great built in libexpat stuff for managing XML.
> This could really help with the download list available capabilities,
> again the current self-parsing works, but is pushing the boundaries of
> what a bash script should be asked to do (and it shows).

Processing XML using xml.dom.minidom.parse() is very straightforward. 
I wish that there was something similar for HTML/SGML; it would have
made replacing g.html2man much simpler.

> Perhaps there is some overlap with v.in.wfs as well? (currently relies on
> lynx, which I guess is not commonly installed with MS-Windows..)

In 7.0, it has been converted to Python, and uses Python's
urllib.urlopen() rather than lynx.

-- 
Glynn Clements <glynn at gclements.plus.com>


More information about the grass-dev mailing list