The way to do exception printing in python2/3 compatible way is using sys.exc_info()[0/1].
Attach a file by drag & drop or click to upload