Google App Engine “no module named requests” PyDev

∥☆過路亽.° 提交于 2019-12-31 00:31:08

问题


I downloaded and installed requests library for Python 2.7. Using the shell I can make "import requests" and actually use it without problems.

Thing is that when running Google App Engine it can't find it and prompts the error:

ImportError: No module named requests

I'm using PyDev-Eclipse as IDE for my project and tried adding the path (/usr/local/lib/python2.7/dist-packages/requests) both in

Project > properties > PyDev - PYTHONPATH > External Libraries

and in

Window > preferences > Pydev -Interpreter > Libraries

and none worked! Still having the same issue when trying to run my GAE app

Anyone could help?

Thanks!


回答1:


Any 3rd party lib you use must be physically included in your project and deployed to appengine. This means it is not sufficient to just install with easy_install or pip

See the docs https://developers.google.com/appengine/docs/python/runtime#Pure_Python



来源:https://stackoverflow.com/questions/15960017/google-app-engine-no-module-named-requests-pydev

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!