TITLE: FAQ AUTHOR: jachym DATE: DESC: Frequently asked questions FORMAT: raw ----- BODY:

FAQ

General questions

Error codes hints


General answares

Which version of PyWPS should I use?
Currently, you should use the latest stable version. Older versions (1.0.0) are really outdated and you should better not use them.
How to debug PyWPS processes?
You have two possibilities:
How to run command line commands?
Use build-in method Cmd(string):
                        self.Cmd("ogr2ogr .... ")
                
How to run GRASS commands?
Use build-in method GCmd(string):

                        self.GCmd("r.surf.rst in=%s elev=dem" % (self.GetInputValue("dem")))
                
Where can I find documentation to process writing in general?
Try this sources of documentation:
Why do I have to rename processes/__init__.py-dist and other files to __init__.py?

The files

  • processes/__init__.py
  • etc/setup.py
  • etc/grass.py
do have -dist suffix. You have to rename them and remove this suffix from the file name (e.g. processes/__init__.py-dist -> processes/__init__.py) in order to get PyWPS running and configured.

Why this? If you make some change to this files (by tuning PyWPS), and later you would update your installation of PyWPS, this original files will be overwritten. In this case, only the "-dist" will be overwritten and your changes should be save.


Error code hints

The process seems not to exist (InvalidParametrValue code).
Try this:
  • Is the project listed in GetCapabilities responce?
  • Is the project registerd in pywps/processes/__init__.py file?
The process returns ERROR: G_malloc: out of memory.
You have to setup GRASS region, while operating with raster maps.
                        self.GCmd("g.region rast=input_map")
                    
or
                        self.GCmd("g.region -d")
                    
END-----