Zouxxyy opened a new pull request, #11161:
URL: https://github.com/apache/paimon/pull/11161

   ### Purpose
   
   Fix Spark schema evolution failing with `Not a supported type: void` when 
INSERT or MERGE sources contain untyped NULLs or empty collections. Resolve 
`NullType` recursively against the corresponding target fields before 
converting to Paimon types, while preserving concrete sibling types and new 
fields for normal schema merging and widening.
   
   An untyped new field fails with its full field path and a CAST hint, without 
changing the table schema. Resolution respects case sensitivity and handles 
structs, array elements, and map keys/values.
   
   ### Tests
   
   - Added 23 regression cases covering INSERT and MERGE, NULLs and empty 
collections, nested field additions, sibling type widening, explicit casts, 
case sensitivity, MERGE UPDATE, and failed writes leaving the table unchanged.
   - Confirmed the new suite reproduces the problem on unmodified master: 20 
failures out of 23 tests.
   - Spark 3.5.9 / Scala 2.12 / JDK 8: all 84 tests passed across 
`SchemaEvolutionNullTypeTest`, `WriteMergeSchemaTest`, and 
`MergeIntoAlignmentTest`.
   - Spark 4.1.4 / Scala 2.13 / JDK 17: the same 84 tests passed.
   - Maven build validation (without `fast-build`), Spotless, and `git diff 
--check` passed.
   


-- 
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]

Reply via email to