search close

Python Module Install

access_time Updated Jun 29, 2022

Compatibility

The Signal Sciences Python module is compatible with latest Python 2.X and 3.X

Installation

  1. Install the Signal Sciences Python module via pip:

    pip install https://dl.signalsciences.net/sigsci-module-python/sigsci-module-python_latest.tar.gz
  2. In the setup.py file of your Flask application, add the following line to reference the sigscimodule package:

    packages = ['flask', '......', 'sigscimodule']
  3. In the app.py file of your application, add the following line to import the import the sigscimodule middleware:

    from sigscimodule import Middleware
  4. Below the from sigscimodule import Middleware line, wrap the application object to apply the sigscimodule middleware:

    app.wsgi_app = Middleware(app.wsgi_app)