You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add Iceberg unknown type parsing and conversions across schema, Arrow, Avro, HMS, and Glue paths.
Reject non-null defaults for unknown fields and make set predicate formatting deterministic for stable tests.
Co-authored-by: Codex <codex@openai.com>
Copy file name to clipboardExpand all lines: crates/iceberg/src/expr/visitors/strict_projection.rs
+10-10Lines changed: 10 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -424,7 +424,7 @@ mod tests {
424
424
.bind(schema.clone(),false)
425
425
.unwrap();
426
426
let result = strict_projection.strict_project(&predicate).unwrap();
427
-
assert_eq!(result.to_string(),"((((pcol1 NOT IN (0, -1)) AND (pcol2 NOT IN (0, -1))) AND (pcol3 NOT IN (0, -1))) AND (pcol4 NOT IN (0, -1))) AND (pcol5 NOT IN (0, -1))".to_string());
427
+
assert_eq!(result.to_string(),"((((pcol1 NOT IN (-1, 0)) AND (pcol2 NOT IN (-1, 0))) AND (pcol3 NOT IN (-1, 0))) AND (pcol4 NOT IN (-1, 0))) AND (pcol5 NOT IN (-1, 0))".to_string());
428
428
429
429
// test in
430
430
let predicate =
@@ -658,7 +658,7 @@ mod tests {
658
658
.bind(schema.clone(),false)
659
659
.unwrap();
660
660
let result = strict_projection.strict_project(&predicate).unwrap();
661
-
assert_eq!(result.to_string(),"((((pcol1 NOT IN (575, 564)) AND (pcol2 NOT IN (575, 564))) AND (pcol3 NOT IN (575, 564))) AND (pcol4 NOT IN (575, 564))) AND (pcol5 NOT IN (575, 564))".to_string());
661
+
assert_eq!(result.to_string(),"((((pcol1 NOT IN (564, 575)) AND (pcol2 NOT IN (564, 575))) AND (pcol3 NOT IN (564, 575))) AND (pcol4 NOT IN (564, 575))) AND (pcol5 NOT IN (564, 575))".to_string());
662
662
663
663
// test in
664
664
let predicate = Reference::new("col1")
@@ -1114,7 +1114,7 @@ mod tests {
1114
1114
.bind(schema.clone(),false)
1115
1115
.unwrap();
1116
1116
let result = strict_projection.strict_project(&predicate).unwrap();
1117
-
assert_eq!(result.to_string(),"((((pcol1 NOT IN (575, 564)) AND (pcol2 NOT IN (575, 564))) AND (pcol3 NOT IN (575, 564))) AND (pcol4 NOT IN (575, 564))) AND (pcol5 NOT IN (575, 564))".to_string());
1117
+
assert_eq!(result.to_string(),"((((pcol1 NOT IN (564, 575)) AND (pcol2 NOT IN (564, 575))) AND (pcol3 NOT IN (564, 575))) AND (pcol4 NOT IN (564, 575))) AND (pcol5 NOT IN (564, 575))".to_string());
1118
1118
1119
1119
// test in
1120
1120
let predicate = Reference::new("col1")
@@ -1724,7 +1724,7 @@ mod tests {
1724
1724
.bind(schema.clone(),false)
1725
1725
.unwrap();
1726
1726
let result = strict_projection.strict_project(&predicate).unwrap();
1727
-
assert_eq!(result.to_string(),"((((pcol1 NOT IN (1969-12-31, 1969-12-30)) AND (pcol2 NOT IN (1969-12-31, 1969-12-30))) AND (pcol3 NOT IN (1969-12-31, 1969-12-30))) AND (pcol4 NOT IN (1969-12-31, 1969-12-30))) AND (pcol5 NOT IN (1969-12-31, 1969-12-30))".to_string());
1727
+
assert_eq!(result.to_string(),"((((pcol1 NOT IN (1969-12-30, 1969-12-31)) AND (pcol2 NOT IN (1969-12-30, 1969-12-31))) AND (pcol3 NOT IN (1969-12-30, 1969-12-31))) AND (pcol4 NOT IN (1969-12-30, 1969-12-31))) AND (pcol5 NOT IN (1969-12-30, 1969-12-31))".to_string());
1728
1728
1729
1729
// test in
1730
1730
let predicate = Reference::new("col1")
@@ -1952,7 +1952,7 @@ mod tests {
1952
1952
.bind(schema.clone(),false)
1953
1953
.unwrap();
1954
1954
let result = strict_projection.strict_project(&predicate).unwrap();
1955
-
assert_eq!(result.to_string(),"((((pcol1 NOT IN (47, 46)) AND (pcol2 NOT IN (47, 46))) AND (pcol3 NOT IN (47, 46))) AND (pcol4 NOT IN (47, 46))) AND (pcol5 NOT IN (47, 46))".to_string());
1955
+
assert_eq!(result.to_string(),"((((pcol1 NOT IN (46, 47)) AND (pcol2 NOT IN (46, 47))) AND (pcol3 NOT IN (46, 47))) AND (pcol4 NOT IN (46, 47))) AND (pcol5 NOT IN (46, 47))".to_string());
1956
1956
1957
1957
// test in
1958
1958
let predicate = Reference::new("col1")
@@ -2384,7 +2384,7 @@ mod tests {
2384
2384
.bind(schema.clone(),false)
2385
2385
.unwrap();
2386
2386
let result = strict_projection.strict_project(&predicate).unwrap();
2387
-
assert_eq!(result.to_string(),"((((pcol1 NOT IN (47, 46)) AND (pcol2 NOT IN (47, 46))) AND (pcol3 NOT IN (47, 46))) AND (pcol4 NOT IN (47, 46))) AND (pcol5 NOT IN (47, 46))".to_string());
2387
+
assert_eq!(result.to_string(),"((((pcol1 NOT IN (46, 47)) AND (pcol2 NOT IN (46, 47))) AND (pcol3 NOT IN (46, 47))) AND (pcol4 NOT IN (46, 47))) AND (pcol5 NOT IN (46, 47))".to_string());
2388
2388
2389
2389
// test in
2390
2390
let predicate = Reference::new("col1")
@@ -2593,7 +2593,7 @@ mod tests {
2593
2593
.bind(schema.clone(),false)
2594
2594
.unwrap();
2595
2595
let result = strict_projection.strict_project(&predicate).unwrap();
2596
-
assert_eq!(result.to_string(),"(((((pcol1 NOT IN (8, 7, 6)) AND (pcol2 NOT IN (8, 7, 6))) AND (pcol3 NOT IN (6, 2))) AND (pcol4 NOT IN (9, 4))) AND (pcol5 NOT IN (4, 6))) AND (pcol6 NOT IN (4, 6))".to_string());
2596
+
assert_eq!(result.to_string(),"(((((pcol1 NOT IN (6, 7, 8)) AND (pcol2 NOT IN (6, 7, 8))) AND (pcol3 NOT IN (2, 6))) AND (pcol4 NOT IN (4, 9))) AND (pcol5 NOT IN (4, 6))) AND (pcol6 NOT IN (4, 6))".to_string());
2597
2597
}
2598
2598
2599
2599
#[tokio::test]
@@ -2690,15 +2690,15 @@ mod tests {
2690
2690
.bind(schema.clone(),false)
2691
2691
.unwrap();
2692
2692
let result = strict_projection.strict_project(&predicate).unwrap();
2693
-
assert_eq!(result.to_string(),"pcol1 IN (101, 100)".to_string());
2693
+
assert_eq!(result.to_string(),"pcol1 IN (100, 101)".to_string());
0 commit comments