

def setup_paths(module_paths):
    'Set up sys.path on the mappers and reducers.\n\n    module_paths is an array of path names where the sources or other\n    supporting files are found. In particular, module_paths[0] is the location\n    of the PyCascading Python sources, and modules_paths[1] is the location of\n    the source file defining the function.\n\n    In Hadoop mode (with remote_deploy.sh), the first two -a options must\n    specify the archives of the PyCascading sources and the job sources,\n    respectively.\n\n    Arguments:\n    module_paths -- the locations of the Python sources \n    '
    from com.twitter.pycascading import Util
    cascading_jar = Util.getCascadingJar()
    jython_dir = module_paths[0]
    sys.path.extend((cascading_jar, (jython_dir + '/python'), (jython_dir + '/python/Lib')))
    sys.path.extend(module_paths[1:])
    import site
    site.addsitedir((jython_dir + 'python/Lib/site-packages'))

dataset/ETHPy150Open twitter/pycascading/python/pycascading/init_module.py setup_paths/original