Updated version number from 0.4.0 to 0.5.0.ejs to distinguish from 0.4.0.

Updated code to allow running on Python 2.6.