[ 
https://issues.apache.org/jira/browse/PIG-4353?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Madhavi Nadig resolved PIG-4353.
--------------------------------
    Resolution: Not a Problem

Here's the correct way to use python-embedded-pig :
{code}
pig -embedded jython myjob.py
{code}

> Python script with embedded PIG fails throws ImportError: No module named 
> org.apache.pig.scripting
> --------------------------------------------------------------------------------------------------
>
>                 Key: PIG-4353
>                 URL: https://issues.apache.org/jira/browse/PIG-4353
>             Project: Pig
>          Issue Type: Bug
>    Affects Versions: 0.13.1
>            Reporter: Madhavi Nadig
>
> Python script with embedded pig fails to import org.apache.pig.scripting.
> {code}
> $ python myjob.py 
> Traceback (most recent call last):
>   File "myjob.py", line 12, in <module>
>     from org.apache.pig.scripting import *
> ImportError: No module named org.apache.pig.scripting
> {code}
> Have tried to import the bundled jython jar explicitly with
> {code}
> import sys
> sys.path.append('/opt/mapr/pig/pig-0.13/lib/jython-standalone-2.5.3.jar')
> from org.apache.pig.scripting import *
> {code}
> Still get the same error.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to