-
Notifications
You must be signed in to change notification settings - Fork 82
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
Currently, if neither a copybook nor copybook contents are specified, spark-cobol
will fail with the following error message:
Exception in thread "main" java.lang.IllegalStateException: Cannot define path to source files: missing parameter: 'path'
at za.co.absa.cobrix.spark.cobol.source.parameters.CobolParametersValidator$.validateOrThrow(CobolParametersValidator.scala:97)
at za.co.absa.cobrix.spark.cobol.source.DefaultSource.createRelation(DefaultSource.scala:52)
at za.co.absa.cobrix.spark.cobol.source.DefaultSource.createRelation(DefaultSource.scala:48)
at org.apache.spark.sql.execution.datasources.DataSource.resolveRelation(DataSource.scala:318)
To Reproduce
val df = spark
.read
.format("cobol")
.load("/path/file")
Expected behaviour
The error message should say clearly that a copybook is missing.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working