Made exception Python 3 friendly
Made print Python 3 friendly