Skip to content

Commit 22feb0f

Browse files
committed
Update to 0.8.0
1 parent a7136bf commit 22feb0f

File tree

4 files changed

+645
-580
lines changed

4 files changed

+645
-580
lines changed

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ sql-sqlite = ["sqlalchemy>=2.0.18,<3"]
9292
gcsfs = ["gcsfs>=2023.1.0"]
9393
rest-sigv4 = ["boto3>=1.24.59"]
9494
hf = ["huggingface-hub>=0.24.0"]
95-
pyiceberg-core = ["pyiceberg-core==0.8.0rc1"]
95+
pyiceberg-core = ["pyiceberg-core==0.8.0"]
9696
datafusion = ["datafusion==50.*"]
9797
gcp-auth = ["google-auth>=2.4.0"]
9898

tests/integration/test_writes/test_writes.py

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1649,7 +1649,8 @@ def test_merge_manifests_file_content(session_catalog: Catalog, arrow_table_with
16491649
assert tbl_a_entries["file_sequence_number"] == [3, 2, 1] if format_version == 2 else [0, 0, 0]
16501650
for i in range(3):
16511651
tbl_a_data_file = tbl_a_entries["data_file"][i]
1652-
assert tbl_a_data_file["column_sizes"] == [
1652+
# Use set comparison since pyiceberg_core may return items in different order
1653+
assert set(tbl_a_data_file["column_sizes"]) == {
16531654
(1, 51),
16541655
(2, 80),
16551656
(3, 130),
@@ -1662,7 +1663,7 @@ def test_merge_manifests_file_content(session_catalog: Catalog, arrow_table_with
16621663
(10, 96),
16631664
(11, 80),
16641665
(12, 111),
1665-
]
1666+
}
16661667
assert tbl_a_data_file["content"] == 0
16671668
assert tbl_a_data_file["equality_ids"] is None
16681669
assert tbl_a_data_file["file_format"] == "PARQUET"
@@ -1671,7 +1672,8 @@ def test_merge_manifests_file_content(session_catalog: Catalog, arrow_table_with
16711672
# verify that the snapshot id recorded should be the one where the file was added
16721673
assert tbl_a_entries["snapshot_id"][i] == first_snapshot_id
16731674
assert tbl_a_data_file["key_metadata"] is None
1674-
assert tbl_a_data_file["lower_bounds"] == [
1675+
# Use set comparison since pyiceberg_core may return items in different order
1676+
assert set(tbl_a_data_file["lower_bounds"]) == {
16751677
(1, b"\x00"),
16761678
(2, b"a"),
16771679
(3, b"aaaaaaaaaaaaaaaa"),
@@ -1684,9 +1686,10 @@ def test_merge_manifests_file_content(session_catalog: Catalog, arrow_table_with
16841686
(10, b"\x9eK\x00\x00"),
16851687
(11, b"\x01"),
16861688
(12, b"\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"),
1687-
]
1689+
}
16881690
assert tbl_a_data_file["nan_value_counts"] == []
1689-
assert tbl_a_data_file["null_value_counts"] == [
1691+
# Use set comparison since pyiceberg_core may return items in different order
1692+
assert set(tbl_a_data_file["null_value_counts"]) == {
16901693
(1, 1),
16911694
(2, 1),
16921695
(3, 1),
@@ -1699,12 +1702,13 @@ def test_merge_manifests_file_content(session_catalog: Catalog, arrow_table_with
16991702
(10, 1),
17001703
(11, 1),
17011704
(12, 1),
1702-
]
1705+
}
17031706
assert tbl_a_data_file["partition"] == {}
17041707
assert tbl_a_data_file["record_count"] == 3
17051708
assert tbl_a_data_file["sort_order_id"] is None
17061709
assert tbl_a_data_file["split_offsets"] == [4]
1707-
assert tbl_a_data_file["upper_bounds"] == [
1710+
# Use set comparison since pyiceberg_core may return items in different order
1711+
assert set(tbl_a_data_file["upper_bounds"]) == {
17081712
(1, b"\x01"),
17091713
(2, b"z"),
17101714
(3, b"zzzzzzzzzzzzzzz{"),
@@ -1717,8 +1721,9 @@ def test_merge_manifests_file_content(session_catalog: Catalog, arrow_table_with
17171721
(10, b"\xd9K\x00\x00"),
17181722
(11, b"\x12"),
17191723
(12, b"\x11\x11\x11\x11\x11\x11\x11\x11\x11\x11\x11\x11\x11\x11\x11\x11"),
1720-
]
1721-
assert tbl_a_data_file["value_counts"] == [
1724+
}
1725+
# Use set comparison since pyiceberg_core may return items in different order
1726+
assert set(tbl_a_data_file["value_counts"]) == {
17221727
(1, 3),
17231728
(2, 3),
17241729
(3, 3),
@@ -1731,7 +1736,7 @@ def test_merge_manifests_file_content(session_catalog: Catalog, arrow_table_with
17311736
(10, 3),
17321737
(11, 3),
17331738
(12, 3),
1734-
]
1739+
}
17351740

17361741

17371742
@pytest.mark.integration

tests/table/test_datafusion.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def test_datafusion_register_pyiceberg_table(catalog: Catalog, arrow_table_with_
4949
iceberg_table.append(arrow_table_with_null)
5050

5151
ctx = SessionContext()
52-
ctx.register_table_provider("test", iceberg_table)
52+
ctx.register_table("test", iceberg_table)
5353

5454
datafusion_table = ctx.table("test")
5555
assert datafusion_table is not None

0 commit comments

Comments
 (0)