Django: Update to version 1.5.1

This series of patches make the Django based application work with the latest version available version (1.5.1).

This is a requirement for Autotest 1.0 release and better documented on issue #605.