Use string formatting with % here instead of string concatenation, e.g. "Exception is %s" % str(e)