You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pig.apache.org by "Rohini Palaniswamy (JIRA)" <ji...@apache.org> on 2013/02/22 00:10:12 UTC
[jira] [Created] (PIG-3205) Passing arguments to python script does
not work with -f option
Rohini Palaniswamy created PIG-3205:
---------------------------------------
Summary: Passing arguments to python script does not work with -f option
Key: PIG-3205
URL: https://issues.apache.org/jira/browse/PIG-3205
Project: Pig
Issue Type: Bug
Affects Versions: 0.10.1
Reporter: Rohini Palaniswamy
Assignee: Rohini Palaniswamy
Fix For: 0.12
With "pig sample.py arg1 arg2", arguments can be accessed in the embedded python script using sys.argv[]. But not in the case "pig -f sample.py arg1 arg2".
In case of ExecMode.FILE, we don't set PigContext.PIG_CMD_ARGS_REMAINDERS and so the arguments are not passed to JythonScriptEngine or GroovyScriptEngine. This is specially a problem with Oozie as it always uses -f option to specify the pig script.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira