Hi I installed on a Google App Engine Python 2.7, opencv using
pip install -t lib -r requirements.txt
requirements.txt is:
Flask==0.12.1
Werkzeug==0.12.2
Opencv_python==3.3.0.10
Install worked, I can use other libraries, but when I try to import opencv on code, it throws the next exception:
File "/google/google-cloud-sdk/platform/google_appengine/google/appengine/runtime/wsgi.py", line 85, in LoadObject
obj = __import__(path[0])
File "/home/tcarrillof/python-docs-hello-world/main.py", line 23, in <module>
import cv2
File "/home/tcarrillof/python-docs-hello-world/lib/cv2/__init__.py", line 6, in <module>
os.environ["PATH"] += os.pathsep + os.path.dirname(os.path.realpath(__file__))
File "/google/google-cloud-sdk/platform/google_appengine/google/appengine/runtime/request_environment.py", line 126, in __getitem__
return self._request.environ[key]
KeyError: 'PATH'
Is it there something I need to configure?, Any help is welcome in advance :)
Note:
app.yaml is:
runtime: python27
api_version: 1
threadsafe: true
handlers:
- url: /static
static_dir: static
- url: /.*
script: main.app
and appengine_config.py is:
import os
from google.appengine.ext import vendor
vendor.add(os.path.join(os.path.dirname(os.path.realpath(__file__)), 'lib'))