Configuring App Engine path for PyDev on Mac

拟墨画扇 提交于 2019-12-18 05:51:13

问题


I've just installed Eclipse and the Pydev plug-in on my Mac (OS X 10.6.6) and I'm having trouble using the Google App Engine project 'template'. I'm really stuck here so your help would be really appreciated.

I can get as far as adding a New Project > Pydev > Pydev Google App Engine Project and setup the project name, directory and type etc no problem.

It then asks for the Google App Engine directory "Select the Google App Engine root directory (dir containing dev_appserver.py, appcfg.py, lib etc" but I can't find these files anywhere. I have of course already installed the Google App Engine SDK.

I did find a post that says I should specify the following path:

"/Applications/**GoogleAppEngineLauncher.app**/Contents/Resources/ 
GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/"

Notice this path includes a .app file (!?). I tried to navigate this structure and I can find the GoogleAppEngineLauncher.app file but can't navigate into it. I even tried pasting the path into the dialog directly... no luck.

What am I doing wrong? Help!

Yours, Confoosed.


回答1:


Put /usr/local/google_appengine as the path to ${GOOGLE_APP_ENGINE} and Eclipse will resolve that symlink to /Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine.

You should be able to see the /usr folder under Eclipse, which you normally won't see under Finder.




回答2:


I had the same problem and I was stuck for days. I simply searched for the dev_appserver.py file in the Finder and inserted that dir. Mine was just under the folder I initially pointed it toward on my Desktop and I was wasting time looking in the App folder. I hope that helps, even though its so simple to just search your whole dir sys for the file.

I had downloaded this AppEngine SDK for Python on Mac OS X and it seemed like it was just the SDK without the dir that we need for the lib.

Good luck,




回答3:


You need to download and run the Google App Engine SDK for Python (the AppEngine SDK for Python on Mac OS X may be found at that link), and you need to run the installer program. It will install the dev_appserver binary in /usr/local/bin/. You shouldn't try running the bundled code; one of the reasons why it is necessary to run in the installer and have it install the code in /usr/local/bin/, is that the installer will also periodically update those files which it has installed; if you run them directly from within the bundle, then you risk running out-of-date versions of those files.



来源:https://stackoverflow.com/questions/4911823/configuring-app-engine-path-for-pydev-on-mac

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