title: 'No module named happybase' when running from PIG
body: <p>I have a Python UDF which is connecting to HBase using Happybase. If I run the code from Python 2.7 it works perfectly.</p>
  
  <p>However when I call the Python UDF from Pig 0.15.0 I am getting the following error:</p>
  
  <blockquote>
    <p>ERROR org.apache.pig.tools.grunt.Grunt - ERROR 1121: Python Error. Traceback (most recent call last): import happybase ImportError: No module named happybase</p>
  </blockquote>
  
  <p>In my Pig script I am registering my Python script (pigtest.py) like this:</p>
  
  <pre><code>REGISTER 'pigtest.py' using jython as myfuncs;
  </code></pre>
  
  <p>I tried to set the Happybase path in my Python script as follows but that didn't make a difference:</p>
  
  <pre><code>import sys
  sys.path.append('/usr/local/lib/python2.7/dist-packages/happybase')
  import happybase
  </code></pre>
  
  <p>I also tried adding "<em>/usr/local/lib/python2.7/dist-packages/happybase</em>" to the JYTHON_PATH in the .bashrc file (I'm on Ubuntu) but same error comes up.</p>
  
  <p>It seems to me like I need to set the Happybase path somewhere, but I can't figure out where.</p>