{"action":"created","issue":{"url":"https://api.github.com/repos/apache/spark/issues/8899","labels_url":"https://api.github.com/repos/apache/spark/issues/8899/labels{/name}","comments_url":"https://api.github.com/repos/apache/spark/issues/8899/comments","events_url":"https://api.github.com/repos/apache/spark/issues/8899/events","html_url":"https://github.com/apache/spark/pull/8899","id":108058053,"number":8899,"title":"[SPARK-10709] [SQL] When loading a json dataset as a data frame, if the input path is wrong, the error message is very confusing","user":{"login":"navis","id":809395,"avatar_url":"https://avatars.githubusercontent.com/u/809395?v=3","gravatar_id":"","url":"https://api.github.com/users/navis","html_url":"https://github.com/navis","followers_url":"https://api.github.com/users/navis/followers","following_url":"https://api.github.com/users/navis/following{/other_user}","gists_url":"https://api.github.com/users/navis/gists{/gist_id}","starred_url":"https://api.github.com/users/navis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/navis/subscriptions","organizations_url":"https://api.github.com/users/navis/orgs","repos_url":"https://api.github.com/users/navis/repos","events_url":"https://api.github.com/users/navis/events{/privacy}","received_events_url":"https://api.github.com/users/navis/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2015-09-24T04:49:00Z","updated_at":"2015-10-05T02:07:12Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/apache/spark/pulls/8899","html_url":"https://github.com/apache/spark/pull/8899","diff_url":"https://github.com/apache/spark/pull/8899.diff","patch_url":"https://github.com/apache/spark/pull/8899.patch"},"body":"\r\nIf you do something like {{sqlContext.read.json(\"a wrong path\")}}, when we actually read data, the error message is \r\n```\r\njava.io.IOException: No input paths specified in job\r\n\tat org.apache.hadoop.mapred.FileInputFormat.listStatus(FileInputFormat.java:198)\r\n\tat org.apache.hadoop.mapred.FileInputFormat.getSplits(FileInputFormat.java:270)\r\n\tat org.apache.spark.rdd.HadoopRDD.getPartitions(HadoopRDD.scala:207)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.ShuffleDependency.<init>(Dependency.scala:91)\r\n\tat org.apache.spark.sql.execution.ShuffledRowRDD.getDependencies(ShuffledRowRDD.scala:59)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$dependencies$2.apply(RDD.scala:226)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$dependencies$2.apply(RDD.scala:224)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.dependencies(RDD.scala:224)\r\n\tat org.apache.spark.scheduler.DAGScheduler.visit$2(DAGScheduler.scala:427)\r\n\tat org.apache.spark.scheduler.DAGScheduler.getAncestorShuffleDependencies(DAGScheduler.scala:442)\r\n\tat org.apache.spark.scheduler.DAGScheduler.org$apache$spark$scheduler$DAGScheduler$$getShuffleMapStage(DAGScheduler.scala:301)\r\n\tat org.apache.spark.scheduler.DAGScheduler$$anonfun$visit$1$1.apply(DAGScheduler.scala:403)\r\n\tat org.apache.spark.scheduler.DAGScheduler$$anonfun$visit$1$1.apply(DAGScheduler.scala:400)\r\n\tat scala.collection.immutable.List.foreach(List.scala:318)\r\n\tat org.apache.spark.scheduler.DAGScheduler.visit$1(DAGScheduler.scala:400)\r\n\tat org.apache.spark.scheduler.DAGScheduler.getParentStages(DAGScheduler.scala:412)\r\n\tat org.apache.spark.scheduler.DAGScheduler.getParentStagesAndId(DAGScheduler.scala:315)\r\n\tat org.apache.spark.scheduler.DAGScheduler.newResultStage(DAGScheduler.scala:350)\r\n\tat org.apache.spark.scheduler.DAGScheduler.handleJobSubmitted(DAGScheduler.scala:846)\r\n\tat org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.doOnReceive(DAGScheduler.scala:1637)\r\n\tat org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1629)\r\n\tat org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1618)\r\n\tat org.apache.spark.util.EventLoop$$anon$1.run(EventLoop.scala:48)\r\njava.io.IOException: No input paths specified in job\r\n\tat org.apache.hadoop.mapred.FileInputFormat.listStatus(FileInputFormat.java:198)\r\n\tat org.apache.hadoop.mapred.FileInputFormat.getSplits(FileInputFormat.java:270)\r\n\tat org.apache.spark.rdd.HadoopRDD.getPartitions(HadoopRDD.scala:207)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.rdd.MapPartitionsRDD.getPartitions(MapPartitionsRDD.scala:35)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:239)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$partitions$2.apply(RDD.scala:237)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.partitions(RDD.scala:237)\r\n\tat org.apache.spark.ShuffleDependency.<init>(Dependency.scala:91)\r\n\tat org.apache.spark.sql.execution.ShuffledRowRDD.getDependencies(ShuffledRowRDD.scala:59)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$dependencies$2.apply(RDD.scala:226)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$dependencies$2.apply(RDD.scala:224)\r\n\tat scala.Option.getOrElse(Option.scala:120)\r\n\tat org.apache.spark.rdd.RDD.dependencies(RDD.scala:224)\r\n\tat org.apache.spark.scheduler.DAGScheduler.visit$2(DAGScheduler.scala:427)\r\n\tat org.apache.spark.scheduler.DAGScheduler.getAncestorShuffleDependencies(DAGScheduler.scala:442)\r\n\tat org.apache.spark.scheduler.DAGScheduler.org$apache$spark$scheduler$DAGScheduler$$getShuffleMapStage(DAGScheduler.scala:301)\r\n\tat org.apache.spark.scheduler.DAGScheduler$$anonfun$visit$1$1.apply(DAGScheduler.scala:403)\r\n\tat org.apache.spark.scheduler.DAGScheduler$$anonfun$visit$1$1.apply(DAGScheduler.scala:400)\r\n\tat scala.collection.immutable.List.foreach(List.scala:318)\r\n\tat org.apache.spark.scheduler.DAGScheduler.visit$1(DAGScheduler.scala:400)\r\n\tat org.apache.spark.scheduler.DAGScheduler.getParentStages(DAGScheduler.scala:412)\r\n\tat org.apache.spark.scheduler.DAGScheduler.getParentStagesAndId(DAGScheduler.scala:315)\r\n\tat org.apache.spark.scheduler.DAGScheduler.newResultStage(DAGScheduler.scala:350)\r\n\tat org.apache.spark.scheduler.DAGScheduler.handleJobSubmitted(DAGScheduler.scala:846)\r\n\tat org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.doOnReceive(DAGScheduler.scala:1637)\r\n\tat org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1629)\r\n\tat org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1618)\r\n\tat org.apache.spark.util.EventLoop$$anon$1.run(EventLoop.scala:48)\r\n\tat org.apache.spark.scheduler.DAGScheduler.runJob(DAGScheduler.scala:630)\r\n\tat org.apache.spark.SparkContext.runJob(SparkContext.scala:1823)\r\n\tat org.apache.spark.SparkContext.runJob(SparkContext.scala:1943)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$reduce$1.apply(RDD.scala:997)\r\n\tat org.apache.spark.rdd.RDDOperationScope$.withScope(RDDOperationScope.scala:150)\r\n\tat org.apache.spark.rdd.RDDOperationScope$.withScope(RDDOperationScope.scala:111)\r\n\tat org.apache.spark.rdd.RDD.withScope(RDD.scala:306)\r\n\tat org.apache.spark.rdd.RDD.reduce(RDD.scala:979)\r\n\tat org.apache.spark.rdd.RDD$$anonfun$takeOrdered$1.apply(RDD.scala:1360)\r\n\tat org.apache.spark.rdd.RDDOperationScope$.withScope(RDDOperationScope.scala:150)\r\n\tat org.apache.spark.rdd.RDDOperationScope$.withScope(RDDOperationScope.scala:111)\r\n\tat org.apache.spark.rdd.RDD.withScope(RDD.scala:306)\r\n\tat org.apache.spark.rdd.RDD.takeOrdered(RDD.scala:1347)\r\n\tat org.apache.spark.sql.execution.TakeOrderedAndProject.collectData(basicOperators.scala:257)\r\n\tat org.apache.spark.sql.execution.TakeOrderedAndProject.executeCollect(basicOperators.scala:263)\r\n\tat org.apache.spark.sql.DataFrame$$anonfun$collect$1.apply(DataFrame.scala:1399)\r\n\tat org.apache.spark.sql.DataFrame$$anonfun$collect$1.apply(DataFrame.scala:1399)\r\n\tat org.apache.spark.sql.execution.SQLExecution$.withNewExecutionId(SQLExecution.scala:56)\r\n\tat org.apache.spark.sql.DataFrame.withNewExecutionId(DataFrame.scala:1917)\r\n\tat org.apache.spark.sql.DataFrame.collect(DataFrame.scala:1398)\r\n\tat org.apache.spark.sql.DataFrame.head(DataFrame.scala:1328)\r\n\tat org.apache.spark.sql.DataFrame.take(DataFrame.scala:1391)\r\n\tat org.apache.spark.sql.DataFrame.showString(DataFrame.scala:178)\r\n\tat org.apache.spark.sql.DataFrame.show(DataFrame.scala:402)\r\n\tat $iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC.<init>(<console>:37)\r\n\tat $iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC.<init>(<console>:42)\r\n\tat $iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC.<init>(<console>:44)\r\n\tat $iwC$$iwC$$iwC$$iwC$$iwC$$iwC$$iwC.<init>(<console>:46)\r\n\tat $iwC$$iwC$$iwC$$iwC$$iwC$$iwC.<init>(<console>:48)\r\n\tat $iwC$$iwC$$iwC$$iwC$$iwC.<init>(<console>:50)\r\n\tat $iwC$$iwC$$iwC$$iwC.<init>(<console>:52)\r\n\tat $iwC$$iwC$$iwC.<init>(<console>:54)\r\n\tat $iwC$$iwC.<init>(<console>:56)\r\n\tat $iwC.<init>(<console>:58)\r\n\tat <init>(<console>:60)\r\n\tat .<init>(<console>:64)\r\n\tat .<clinit>(<console>)\r\n\tat .<init>(<console>:7)\r\n\tat .<clinit>(<console>)\r\n\tat $print(<console>)\r\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\r\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\r\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\r\n\tat java.lang.reflect.Method.invoke(Method.java:606)\r\n\tat org.apache.spark.repl.SparkIMain$ReadEvalPrint.call(SparkIMain.scala:1065)\r\n\tat org.apache.spark.repl.SparkIMain$Request.loadAndRun(SparkIMain.scala:1340)\r\n\tat org.apache.spark.repl.SparkIMain.loadAndRunReq$1(SparkIMain.scala:840)\r\n\tat org.apache.spark.repl.SparkIMain.interpret(SparkIMain.scala:871)\r\n\tat org.apache.spark.repl.SparkIMain.interpret(SparkIMain.scala:819)\r\n\tat org.apache.spark.repl.SparkILoop.reallyInterpret$1(SparkILoop.scala:857)\r\n\tat org.apache.spark.repl.SparkILoop.interpretStartingWith(SparkILoop.scala:902)\r\n\tat org.apache.spark.repl.SparkILoop.command(SparkILoop.scala:814)\r\n\tat org.apache.spark.repl.SparkILoop.processLine$1(SparkILoop.scala:657)\r\n\tat org.apache.spark.repl.SparkILoop.innerLoop$1(SparkILoop.scala:665)\r\n\tat org.apache.spark.repl.SparkILoop.org$apache$spark$repl$SparkILoop$$loop(SparkILoop.scala:670)\r\n\tat org.apache.spark.repl.SparkILoop$$anonfun$org$apache$spark$repl$SparkILoop$$process$1.apply$mcZ$sp(SparkILoop.scala:997)\r\n\tat org.apache.spark.repl.SparkILoop$$anonfun$org$apache$spark$repl$SparkILoop$$process$1.apply(SparkILoop.scala:945)\r\n\tat org.apache.spark.repl.SparkILoop$$anonfun$org$apache$spark$repl$SparkILoop$$process$1.apply(SparkILoop.scala:945)\r\n\tat scala.tools.nsc.util.ScalaClassLoader$.savingContextLoader(ScalaClassLoader.scala:135)\r\n\tat org.apache.spark.repl.SparkILoop.org$apache$spark$repl$SparkILoop$$process(SparkILoop.scala:945)\r\n\tat org.apache.spark.repl.SparkILoop.process(SparkILoop.scala:1059)\r\n\tat org.apache.spark.repl.Main$.main(Main.scala:31)\r\n\tat org.apache.spark.repl.Main.main(Main.scala)\r\n```\r\nThis message is very confusing."},"comment":{"url":"https://api.github.com/repos/apache/spark/issues/comments/145411566","html_url":"https://github.com/apache/spark/pull/8899#issuecomment-145411566","issue_url":"https://api.github.com/repos/apache/spark/issues/8899","id":145411566,"user":{"login":"AmplabJenkins","id":4031291,"avatar_url":"https://avatars.githubusercontent.com/u/4031291?v=3","gravatar_id":"","url":"https://api.github.com/users/AmplabJenkins","html_url":"https://github.com/AmplabJenkins","followers_url":"https://api.github.com/users/AmplabJenkins/followers","following_url":"https://api.github.com/users/AmplabJenkins/following{/other_user}","gists_url":"https://api.github.com/users/AmplabJenkins/gists{/gist_id}","starred_url":"https://api.github.com/users/AmplabJenkins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AmplabJenkins/subscriptions","organizations_url":"https://api.github.com/users/AmplabJenkins/orgs","repos_url":"https://api.github.com/users/AmplabJenkins/repos","events_url":"https://api.github.com/users/AmplabJenkins/events{/privacy}","received_events_url":"https://api.github.com/users/AmplabJenkins/received_events","type":"User","site_admin":false},"created_at":"2015-10-05T02:07:12Z","updated_at":"2015-10-05T02:07:12Z","body":" Merged build triggered."}}