HyukjinKwon opened a new pull request, #58722: URL: https://github.com/apache/spark/pull/58722
### What changes were proposed in this pull request? Follow-up to SPARK-59311. `parseCatalystType`/`parseStampedStringType` hardcoded `spark.sql.catalyst.type` in the overflow (`IncompatibleSchemaException`) message, but they are also used to parse the map-key type carried in `spark.sql.catalyst.mapKey.type`. A too-deeply nested map-key type therefore reported the wrong property. This threads the source property name through both helpers so the message names the property the type actually came from. Also reduces the overflow regression test's nesting depth from 6000 to 1000 (still overflows the 256 KiB test stack deterministically, but runs much faster) and factors the small-stack runner into a shared helper. ### Why are the changes needed? The error message pointed users at the wrong Avro schema property when a map-key Catalyst type was malformed, making the failure harder to diagnose. ### Does this PR introduce _any_ user-facing change? Yes, within the unreleased branch: the exception for an over-deep map-key Catalyst type now names `spark.sql.catalyst.mapKey.type` instead of `spark.sql.catalyst.type`. No change compared to released versions. ### How was this patch tested? Added a regression test asserting the map-key property name appears in the overflow message, and strengthened the existing overflow test to also assert its property name. To be verified by the Apache Spark GitHub Actions CI on this PR. ### Was this patch authored or co-authored using generative AI tooling? Generated-by: Isaac Co-authored-by: Isaac <[email protected]> This pull request and its description were written by Isaac. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
