Made application Python 3 compatible.