title: How can I raise an Exception that includes a Unicode string?
body: <p>I'm writing Python 2 code with Unicode strings, importing unicode_literals and I'm having issues with raising exceptions.</p>
  
  <pre><code># -*- coding: utf-8 -*-
  
  from __future__ import unicode_literals
  
  raise Exception('Tést')
  </code></pre>
  
  <p>When doing this, the 'Tést' string is stripped off the terminal.</p>
  
  <p>I can workaround this with</p>
  
  <pre><code>raise Exception('Tést'.encode('utf-8'))
  </code></pre>
  
  <p>I'd rather find a global solution than having to do this in all <code>raise Exception</code> statements.</p>
  
  <p>(Since I'm using PyQt's <code>tr()</code> function in Exception messages, special characters must be handled, I can't know at coding time whether <code>encode('utf-8')</code> is necessary.)</p>
  
  <p>Worse. Sometimes, I want to catch an Exception, get its message, and raise a new Exception, concatenating a base string with the first Exception string.</p>
  
  <p>I have to do it this way:</p>
  
  <pre><code>try:
      raise TypeError('Tést'.encode('utf-8'))
  except Exception as e:
      raise Exception('Exception: {}'.format(str(e).decode('utf-8')).encode('utf-8'))
  </code></pre>
  
  <p>but I really wish it could be less cumbersome (and this example doesn't even include the <code>self.tr()</code> calls).</p>
  
  <p>Is there any simpler way ?</p>
  
  <p>(And as a side question, are things simpler with Python3 ? Can Exception use unicode strings ?)</p>