parameters: (e)
return_statement: return u'Unrecoverably corrupt evalue'
docstring: unicode(e) with various fallbacks. Used for exceptions, which may not be
      safe to call unicode() on.
docstring_summary: unicode(e) with various fallbacks. Used for exceptions, which may not be
      safe to call unicode() on.
docstring_tokens: unicode ( e ) with various fallbacks . Used for exceptions which may not be safe to call unicode () on .
function: def safe_unicode(e):
      """unicode(e) with various fallbacks. Used for exceptions, which may not be
      safe to call unicode() on.
      """
      try:
          return unicode_type(e)
      except UnicodeError:
          pass
  
      try:
          return str_to_unicode(str(e))
      except UnicodeError:
          pass
  
      try:
          return str_to_unicode(repr(e))
      except UnicodeError:
          pass
  
      return u'Unrecoverably corrupt evalue'
function_tokens: def safe_unicode ( e ) : try : return unicode_type ( e ) except UnicodeError : pass try : return str_to_unicode ( str ( e ) ) except UnicodeError : pass try : return str_to_unicode ( repr ( e ) ) except UnicodeError : pass return u'Unrecoverably corrupt evalue'