[ 
https://issues.apache.org/jira/browse/SPARK-7367?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15145651#comment-15145651
 ] 

Marcelo Vanzin commented on SPARK-7367:
---------------------------------------

I think this bug has been fixed since 1.4

help in app args:
{noformat}
$ spark-submit --master local --class MyClass /my.jar --help
Exception in thread "main" scala.MatchError: List(--help) (of class 
scala.collection.immutable.$colon$colon)
{noformat}


help in spark args:
{noformat}
$ spark-submit --master local --class MyClass --help /my.jar
Usage: spark-submit [options] <app jar | python file> [app arguments]
...
{noformat}


> spark-submit CLI --help -h overrides the application arguments
> --------------------------------------------------------------
>
>                 Key: SPARK-7367
>                 URL: https://issues.apache.org/jira/browse/SPARK-7367
>             Project: Spark
>          Issue Type: Bug
>          Components: Spark Submit
>            Reporter: Gianmario Spacagna
>            Priority: Minor
>
> The spark-submit script will parse the --help argument even if is provided as 
> application argument.
> E.g. 
> spark-submit --master local[*] --driver-memory 4G --class bar.foo.MyClass 
> /MyLocalJAR.jar --help
> or
> spark-submit --master local[*] --driver-memory 4G --class bar.foo.MyClass 
> /MyLocalJAR.jar -h
> If my application is using a parsing library, such as Scallop, then it will 
> never be able to run the application with --help as argument.
> I think the spark-submit script should only print the help message when is 
> provided as single argument like this:
> spark-submit --help
> or it should provide a separator for trailing arguments:
> spark-submit --master local[*] --driver-memory 4G --class bar.foo.MyClass 
> /MyLocalJAR.jar -- --help --arg1 --arg2



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

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to