Add sqllogictests for scans after a schema change with no write since
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 35/100
Hướng nghiên cứu
Start with the sqllogictest files in the datafusion-iceberg repo and the engine setup that runs DataFusion only, then find where a test could call Transaction::update_schema() in iceberg-rust. Confirm the dependency includes apache/iceberg-rust#2904 before writing tests. Done means sqllogictests cover column add, drop, drop-and-re-add with the same name, and rename after a schema change with no write, and they pass.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Is your feature request related to a problem or challenge?
apache/iceberg-rust#2904 changes TableScanBuilder::build so that a scan that doesn't pin a snapshot projects the table's current schema, not the schema of the snapshot it reads. Before it, a scan of a table whose schema changed after its last write resolved columns against the older schema. That is the root cause of #42.
That PR checks the snapshot and schema a scan resolves with unit tests. End-to-end checks of the rows read back were asked to live here as sqllogictests rather than as integration tests in iceberg-rust (review comment).
Describe the solution you'd like
Once this crate depends on an iceberg-rust release that includes apache/iceberg-rust#2904, add sqllogictests that change a table's schema after its last write, with no write since, and check what queries return:
- Column added:
SELECT *returns the new column as NULL for every existing row.WHERE c IS NULLmatches every row, andWHERE c = <value>matches none. This covers #42. - Column dropped: selecting the dropped column fails with a column-not-found error, and
SELECT *no longer returns it. - Column dropped and added back under the same name: the new column reads as NULL, not the old column's values. Data files are matched by field ID, and the new field ID isn't in any file.
- Column renamed: the values read back under the new name.
The sqllogictest engine here runs only DataFusion, and DataFusion SQL can't change an Iceberg table's schema. These tests need a way to do it, for example a setup step that calls Transaction::update_schema() or a Spark engine, as the README lists.
Additional context
- #42:
SELECT *fails after a column is added until the next write to the table. - #57 is related but not covered here: a provider built before the schema change keeps its cached schema.
- Ngôn ngữ chính
- Rust
- Star
- 30
- Fork
- 30
- Merge trung bình
- 3 ngày 19 giờ
- Pull request đã merge (30 ngày)
- 15
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của apache/datafusion-iceberg
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
apache/datafusion-iceberg#100 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
apache/datafusion-iceberg#85 · 1 bình luận · 5 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
apache/datafusion-iceberg#84 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Slow CI runnersĐang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 18/100
apache/datafusion-iceberg#74 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
apache/datafusion-iceberg#73 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của apache/datafusion-iceberg
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
rubys/roundhouse#1917 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 2 ngày
-
good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[cosmic-applet-battery] Division by zero displays NaN% when UPower reports max_brightness = 0Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
pop-os/cosmic-applets#1619 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
binding:python bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
Maintainer thường phản hồi trong vòng 1 ngày