str_types = (str,) try: str_types += (unicode,) except: pass