from google.appengine.ext import dbImportError: No module named google.appengine.extdjango.core.exceptions.ImproperlyConfigured: 'appengine' isn't an available database backend.Try using django.db.backends.XXX, where XXX is one of:'dummy', 'mysql', 'oracle', 'postgresql', 'postgresql_psycopg2', 'sqlite3'Error was: No module named appengine.basegoogle.appengine.dist._library.UnacceptableVersionError
Monday, November 15, 2010
App Engine Helper for Django - Part I
Friday, November 12, 2010
Exporting Contacts from Facebook - How many care?
Thursday, November 11, 2010
GAE Error when displaying datastore entity key
TypeError: write() argument 1 must be string or read-only character buffer, not Key Reason
I was trying to display key for an entity. Python/ Java API returns keys as an instance of the entity class. Convert it to string to pass it or to display.
Running Django on Google App Engine
application: gaeappversion: 1runtime: pythonapi_version: 1handlers:- url: /staticstatic_dir: static- url: .*script: main.py
import os, loggingfrom google.appengine.ext import webappfrom google.appengine.ext.webapp import utilfrom django.conf import settingssettings._target=Noneos.environ['DJANGO_SETTINGS_MODULE']='djprj.settings'import django.core.handlers.wsgiimport django.core.signalsimport django.dbimport django.dispatch.dispatcher#class MainHandler(webapp.RequestHandler):# def get(self):# self.response.out.write('Hello World!')def main():#application = webapp.WSGIApplication([('/', MainHandler)], debug=True)application=django.core.handlers.wsgi.WSGIHandler()util.run_wsgi_app(application)if __name__ == '__main__':main()
- Comment out all of the middleware parameter else you might get this error "AttributeError: 'module' object has no attribute 'messages'".
- Ensure ROOT_URLCONF = 'urls' if Django files are in GAE dir. Else it will be djprj.urls since our project is called djprj.
Tuesday, November 09, 2010
An African Elephant Sketch
Monday, November 08, 2010
Friday, November 05, 2010
Mac OSX Disk Sweeper
With over year and half of data, my mac harddrive is choking. With backups for previous machines and trip photographs and applications etc. Although I've backup on external harddrive, my fingers still refuse to delete anything worthwhile from my mac. So until I bought another harddrive to backup my backup, I had to do some clean up. A quick googling helped me find this awesome software called Disk Sweeper that gives the directories in the descending order of size.
http://www.omnigroup.com/products/omnidisksweeper/
Jeff Dunham Show
Amazon Kindle has games
Amazon buying your old books
Amazon is offering a trade in of amazon gift card worth $5 or more for your used books in good condition. These books will be purchased by a Third Party Merchant. How convenient is it that that shipping is free. So no more selling your books for the same amount and wait in queue at halfprice bookstore or reposting those craigslist advts.
Cute Puss sans boots
If you have seen any of the Shrek movies, well not any, but ones after 1st Shrek you know who Puss is. Puss is the ninja cat - nimble, fast, sharp and in the boots at that. This is how Puss looked before.