databricks / spark-xml

XML data source for Spark SQL and DataFrames
Apache License 2.0
500 stars 226 forks source link

Improve error reporting for unsupported XSD elements #557

Closed srowen closed 3 years ago

srowen commented 3 years ago

Unsupported elements in XSDs lead to scala MatchError, without detail. This just throws an exception with some clue about what was not matched in several places.

codecov-commenter commented 3 years ago

Codecov Report

Merging #557 (7757056) into master (ccbb866) will decrease coverage by 0.35%. The diff coverage is 0.00%.

:exclamation: Current head 7757056 differs from pull request most recent head 3cc1064. Consider uploading reports for the commit 3cc1064 to get more accurate results Impacted file tree graph

@@            Coverage Diff             @@
##           master     #557      +/-   ##
==========================================
- Coverage   86.05%   85.69%   -0.36%     
==========================================
  Files          18       18              
  Lines         954      958       +4     
  Branches       95       91       -4     
==========================================
  Hits          821      821              
- Misses        133      137       +4     
Impacted Files Coverage Δ
.../main/scala/com/databricks/spark/xml/package.scala 21.42% <ø> (ø)
...la/com/databricks/spark/xml/util/XSDToSchema.scala 62.02% <0.00%> (-3.31%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update ccbb866...3cc1064. Read the comment docs.