title: In Jython, how can I raise a Python Exception, not a java.lang.Exception?
body: <p>Python and Jython newbie here.</p>
  
  <p>I am passably familiar with how to raise exceptions in normal Python.</p>
  
  <p>However, in the Jython environment I find myself in (<a href="https://docs.oracle.com/middleware/1221/wls/WLSTG/using_wlst.htm#WLSTG119" rel="nofollow"><code>WLST</code></a>), if I do:</p>
  
  <pre><code>raise Exception("hello")
  </code></pre>
  
  <p>...then it appears to raise a <code>java.lang.Exception</code>:</p>
  
  <pre><code>wls:/offline&gt; raise Exception("hello")
  Traceback (innermost last):
    File "&lt;console&gt;", line 1, in ?
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
  
  java.lang.Exception: java.lang.Exception: hello
  wls:/offline&gt; 
  </code></pre>
  
  <p>How can I raise a Python <code>Exception</code> in this environment?  Or, at least: why is it a <code>java.lang.Exception</code> that is raised here?</p>