When running Python model adapters within FEWS, Python should be installed on your system and the dependencies (Python packages) of your adapter as well. The proposed way to do this is to:
- work in virtual environment
- organize model adapter code as python package
make sure that all dependencies are listed in the
setup.py
of the package, to allow straightforward installation
Working with virtual environment
Anchor | ||||
---|---|---|---|---|
|
A Python virtual environment, put simply, is an isolated working copy of Python which allows you to work on a specific project without worry of affecting other projects. You can have multiple virtual environments on your system, all having their own specific (versions of) packages available. The virtualenv package provides the basic needs, but virtualenvwrapper makes life a bit easier.
...