u70b3 opened a new issue, #2722:
URL: https://github.com/apache/iceberg-rust/issues/2722

   ### Apache Iceberg Rust version
   
   main
   
   ### Describe the bug
   
   `EqualityDeleteWriterConfig::new` currently allows invalid equality delete 
field ID configurations:
   
   - an empty `equality_ids` list
   - duplicate equality field IDs
   - schema-missing field IDs surfacing through the projector as a generic 
error instead of a clear writer configuration error
   
   Equality delete files identify rows by one or more equality column values, 
so an empty equality ID list should be rejected at writer configuration time. 
Duplicate IDs can also produce an invalid delete schema with repeated projected 
columns.
   
   ### To Reproduce
   
   Construct an equality delete writer config with invalid IDs:
   
   ```rust
   EqualityDeleteWriterConfig::new(vec![], schema.clone());
   EqualityDeleteWriterConfig::new(vec![1, 1], schema.clone());
   EqualityDeleteWriterConfig::new(vec![99], schema.clone());
   ```
   
   Before the fix, empty and duplicate IDs are accepted. Missing IDs are 
rejected later with a less specific projector error.
   
   ### Expected behavior
   
   `EqualityDeleteWriterConfig::new` should return `ErrorKind::DataInvalid` for:
   
   - empty equality ID lists
   - duplicate equality field IDs
   - equality field IDs that do not exist in the schema
   
   The writer should continue to rely on the existing projector logic for 
unsupported field types and map/list reachability rules.
   
   ### Willingness to contribute
   
   I can contribute a fix for this bug independently.
   


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

Reply via email to