“You can always start a weekend experiment but you can never know how it will end” (Moti Karmona, 2008 ;)
I was very curios and wanted to take the GAE for a quick test drive but the Google documentation have few inaccuracies and isn’t sufficient if it is your first Python encounter so I lost three hours of precious beauty sleep and compiled this blog-post-capsule for future generations.
How to setup your development environment to work with Google-App-Engine
- Get yourself a GAE Account
- Install Google App Engine SDK, Python and Eclipse.
- Install the PyDev Eclipse extension
- Help –> Software Updates –> Available Software –> Add the http://pydev.sourceforge.net/updates site –> Install it –> Restart Eclipse
- Configure Eclipse to use the Python interpreter by navigating to Window –> Preferences –> PyDev –> Interpreter –> Python –> New and select the location of python.exe on your system
- Create your first project
- File –> New –> PyDev project and click next –> Name your project and make sure Python 2.5 is selected.
- Add necessary App Engine libraries to your project | Right click your Project folder –> Properties –> PyDev – PythonPath (see image below)
- C:\Program Files\Google\google_appengine
- C:\Program Files\Google\google_appengine\lib\django
- C:\Program Files\Google\google_appengine\lib\webob
- C:\Program Files\Google\google_appengine\lib\yaml\lib
- Create your project files (e.g. GAE examples)
- app.yaml
- Your first python file
- Test your Local application
- Update your Run configuration (see image below)
- Change the Main Module field to C:\Program Files\Google\google appengine\dev_appserver.py
- On the Arguments tab, type in “${project_loc}/src”
- Name this configuration and click apply and click run.
- Open http://localhost:8080 with your browser and enojoy your stupid app :)
- Update your Run configuration (see image below)
- Upload your code to Google App Engine
- Open a command prompt and navigate to your application directory.
- Type appcfg.py –email=yourgmailaccount@gmail.com update src\
- To publish code within Eclipse, open Run –> Run configurations and make a copy of your previous run configuration. Change the Main Module to appcfg.py, and change the argument tab to –email=yourgmailaccount@gmail.com update “${project_loc}/src”
- Your code is now live! Test it by going to http://yourapp.appspot.com
Enjoy :)
P.S. More about the framework in future posts.




3 responses so far ↓
1
Pasha
// Nov 22, 2008 at 8:24 am
Very useful!!
2
Moti Karmona
// Nov 22, 2008 at 9:29 am
You welcome :)
3
YT
// Nov 23, 2008 at 2:42 am
I also gave the app engine framework a run through a while ago.
I just used ultraedit so saved myself a lot of installs :-)
Though I guess for lots of development an IDE will be nicer.
Leave a Comment