PyWPS is an implementation of the Web Processing Service standard from the Open Geospatial Consortium. PyWPS is written in Python.
Python
cehbrecht Merge pull request #341 from Ouranosinc/dblog-multiprocess-safety
Disabled connection pooling to make pywps fork()/clone() safe
Latest commit cde7d3d May 22, 2018
Permalink
Failed to load latest commit information.
.github updating pull request template as per #102 Mar 4, 2016
debian update copyright headers Mar 30, 2018
docs update copyright headers Mar 30, 2018
pywps Disabled connection pooling to make pywps fork()/clone() safe May 16, 2018
tests update copyright headers Mar 30, 2018
.gitignore bug 177 - we already moved to readthedocs, closes 177 Sep 5, 2016
.travis.yml Fix #327: install gdal=2 from ubuntugis repo Mar 26, 2018
CODE_OF_CONDUCT.md add Code of Conduct Mar 21, 2018
CONTRIBUTING.rst Update CONTRIBUTING.rst Jul 22, 2017
CONTRIBUTORS.md Better formating Oct 18, 2016
INSTALL.md Merging with current master branch Sep 1, 2017
LICENSE.txt update README, normalize text, abstract version Feb 15, 2016
MANIFEST.in update README, normalize text, abstract version Feb 15, 2016
README.md Closes #272 Jun 14, 2017
RELEASE-howto.md Merging with current master branch Sep 1, 2017
VERSION.txt Creating new release of PYWPS 4.0.0 Dec 7, 2016
default-sample.cfg added processing package with scheduler extension Sep 1, 2017
requirements-dev.txt fix import error Mar 22, 2018
requirements-gdal.txt response separation Sep 28, 2017
requirements-processing.txt added processing package with scheduler extension Sep 1, 2017
requirements.txt fix issue #301: binary input files not handled on python 3.x Oct 12, 2017
setup.cfg implement flake8 setup (#196) Oct 16, 2016
setup.py update copyright headers Mar 30, 2018
tox.ini Implementing SQLalchemy for logging mechanism Aug 27, 2016

README.md

PyWPS

PyWPS is an implementation of the Web Processing Service standard from the Open Geospatial Consortium. PyWPS is written in Python.

Documentation Status Build Status Coverage Status PyPI GitHub license

Join the chat at https://gitter.im/geopython/pywps

License

As of PyWPS 4.0.0, PyWPS is released under an MIT license (see LICENSE.txt).

Dependencies

See requirements.txt file

Run tests

pip install -r requirements-dev.txt
# run unit tests
python -m unittest tests
# run code coverage
python -m coverage run --source=pywps -m unittest tests
python -m coverage report -m

Run web application

Example service

Clone the example service after having installed PyWPS:

git clone git://github.com/geopython/pywps-flask.git pywps-flask
cd pywps-flask
python demo.py

Apache configuration

  1. Enable WSGI extension

  2. Add configuration:

    WSGIDaemonProcess pywps user=user group=group processes=2 threads=5
    WSGIScriptAlias /pywps /path/to/www/htdocs/wps/pywps.wsgi
    
    <Directory /path/to/www/htdocs/wps/>
        WSGIProcessGroup group
        WSGIApplicationGroup %{GLOBAL}
        Order deny,allow
        Allow from all
    </Directory>
  3. Create wsgi file:

    #!/usr/bin/env python3
    import sys
    sys.path.append('/path/to/src/pywps/')
    
    import pywps
    from pywps.app import Service, WPS, Process
    
    def pr1():
        """This is the execute method of the process
        """
        pass
    
    
    application = Service(processes=[Process(pr1)])
  4. Run via web browser

    http://localhost/pywps/?service=WPS&request=GetCapabilities&version=1.0.0

  5. Run in command line:

    curl 'http://localhost/pywps/?service=WPS&request=GetCapabilities&version=1.0.0'

Issues

On Windows PyWPS does not support multiprocessing which is used when making requests storing the response document and updating the status to displaying to the user the progression of a process.