Removed python version basestring try block in imports and replaced with a sys import and version checking if statement
Fixed if statement syntax error