【发布时间】:2016-06-02 05:58:32
【问题描述】:
我们刚刚在 Mac 上升级了 Google App Engine Launcher,现在运行良好的脚本在通过 PyCharm 启动时抛出“ImportError: No module named webapp2”错误。
这是踪迹:
Traceback(最近一次调用最后一次):文件 “/usr/local/google_appengine/google/appengine/runtime/wsgi.py”,行 240,处理中 handler = _config_handle.add_wsgi_middleware(self._LoadHandler()) 文件“/usr/local/google_appengine/google/appengine/runtime/wsgi.py”, 第 299 行,在 _LoadHandler 中 处理程序,路径,错误 = LoadObject(self._handler) 文件“/usr/local/google_appengine/google/appengine/runtime/wsgi.py”,行 85、在LoadObject中 obj = import(path[0]) 文件“/Users/Michael/Documents/GitHub/velocitybyathla/main.py”,第 17 行,在 import webapp2 ImportError: No module named webapp2 INFO 2016-06-02 05:39:58,835 module.py:788] 默认值:"GET / HTTP/1.1" 500 -
我们尝试按照here 的建议在 Google App Engine Launcher 中添加 Python 的路径 - 但错误仍然存在。
webapp2 已明确安装。它在升级之前工作,如果我们执行“pip install webapp2”,它会说它存在。
我们还尝试了“制作符号链接”,但没有成功。
Google App Engine Launcher 是如何丢失模块路径的?我们如何解决它?
【问题讨论】:
标签: macos python-2.7 google-app-engine pycharm upgrade