Skip to main content

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

Project description

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 Conda 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

Install

Install it from GitHub:

$ git clone https://github.com/geopython/pywps.git
$ cd pywps/
$ pip install .

Run tests

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

Quick Guide with Conda

Checkout source from GitHub:

$ git clone https://github.com/geopython/pywps.git
$ cd pywps/

Build conda environment:

conda env create -f environment.yml

Install pywps:

make install

Or the development version:

make develop

Run tests:

make tests

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

Access example service: http://localhost:5000

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.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pywps-4.7.0.tar.gz (87.5 kB view details)

Uploaded Source

File details

Details for the file pywps-4.7.0.tar.gz.

File metadata

  • Download URL: pywps-4.7.0.tar.gz
  • Upload date:
  • Size: 87.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for pywps-4.7.0.tar.gz
Algorithm Hash digest
SHA256 c282fbcc574193763e6686cd6073c63aeac3927ea452b76d3c257294e3e35d36
MD5 ee9a0dd0d36679033aa0ccf2a87b77e7
BLAKE2b-256 fd417d6882620ab2a9361bcf5883cd406aeef715a44a5f59e6a7b15fb4a79035

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page