Skip to content

Commit 3dab362

Browse files
authored
Merge branch 'apache:main' into add-s3fs-method
2 parents c208a2d + a84689d commit 3dab362

27 files changed

Lines changed: 410 additions & 248 deletions

.github/pull_request_template.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<!--
2+
Thanks for opening a pull request!
3+
-->
4+
5+
<!-- In the case this PR will resolve an issue, please replace ${GITHUB_ISSUE_ID} below with the actual Github issue id. -->
6+
<!-- Closes #${GITHUB_ISSUE_ID} -->
7+
8+
# Rationale for this change
9+
10+
# Are these changes tested?
11+
12+
# Are there any user-facing changes?
13+
14+
<!-- In the case of user-facing changes, please add the changelog label. -->

.github/workflows/pypi-build-artifacts.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ jobs:
6262
if: startsWith(matrix.os, 'ubuntu')
6363

6464
- name: Build wheels
65-
uses: pypa/cibuildwheel@v2.23.0
65+
uses: pypa/cibuildwheel@v2.23.1
6666
with:
6767
output-dir: wheelhouse
6868
config-file: "pyproject.toml"

.github/workflows/svn-build-artifacts.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ jobs:
5757
if: startsWith(matrix.os, 'ubuntu')
5858

5959
- name: Build wheels
60-
uses: pypa/cibuildwheel@v2.23.0
60+
uses: pypa/cibuildwheel@v2.23.1
6161
with:
6262
output-dir: wheelhouse
6363
config-file: "pyproject.toml"

dev/.rat-excludes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
.github/*
12
.rat-excludes
23
build
34
.git

mkdocs/docs/how-to-release.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -379,6 +379,8 @@ Then, select the previous release version as the **Previous tag** to use the dif
379379

380380
**Set as the latest release** and **Publish**.
381381

382+
Make sure to check the `changelog` label on GitHub to see if anything needs to be highlighted.
383+
382384
### Release the docs
383385

384386
Run the [`Release Docs` Github Action](https://github.com/apache/iceberg-python/actions/workflows/python-release-docs.yml).

poetry.lock

Lines changed: 205 additions & 205 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyiceberg/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,4 @@
1515
# specific language governing permissions and limitations
1616
# under the License.
1717

18-
__version__ = "0.9.0"
18+
__version__ = "0.10.0"

pyiceberg/avro/encoder.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
# KIND, either express or implied. See the License for the
1515
# specific language governing permissions and limitations
1616
# under the License.
17+
from typing import Any
1718
from uuid import UUID
1819

1920
from pyiceberg.avro import STRUCT_DOUBLE, STRUCT_FLOAT
@@ -74,3 +75,6 @@ def write_uuid(self, uuid: UUID) -> None:
7475
if len(uuid.bytes) != 16:
7576
raise ValueError(f"Expected UUID to have 16 bytes, got: len({uuid.bytes!r})")
7677
return self.write(uuid.bytes)
78+
79+
def write_unknown(self, _: Any) -> None:
80+
"""Nulls are written as 0 bytes in avro, so we do nothing."""

pyiceberg/avro/reader.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -201,6 +201,14 @@ def skip(self, decoder: BinaryDecoder) -> None:
201201
decoder.skip(16)
202202

203203

204+
class UnknownReader(Reader):
205+
def read(self, decoder: BinaryDecoder) -> None:
206+
return None
207+
208+
def skip(self, decoder: BinaryDecoder) -> None:
209+
pass
210+
211+
204212
@dataclass(frozen=True)
205213
class FixedReader(Reader):
206214
_len: int = dataclassfield()

pyiceberg/avro/resolver.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
TimeReader,
4747
TimestampReader,
4848
TimestamptzReader,
49+
UnknownReader,
4950
UUIDReader,
5051
)
5152
from pyiceberg.avro.writer import (
@@ -66,6 +67,7 @@
6667
TimestamptzWriter,
6768
TimestampWriter,
6869
TimeWriter,
70+
UnknownWriter,
6971
UUIDWriter,
7072
Writer,
7173
)
@@ -100,6 +102,7 @@
100102
TimestampType,
101103
TimestamptzType,
102104
TimeType,
105+
UnknownType,
103106
UUIDType,
104107
)
105108

@@ -193,6 +196,9 @@ def visit_uuid(self, uuid_type: UUIDType) -> Writer:
193196
def visit_binary(self, binary_type: BinaryType) -> Writer:
194197
return BinaryWriter()
195198

199+
def visit_unknown(self, unknown_type: UnknownType) -> Writer:
200+
return UnknownWriter()
201+
196202

197203
CONSTRUCT_WRITER_VISITOR = ConstructWriter()
198204

@@ -341,6 +347,9 @@ def visit_fixed(self, fixed_type: FixedType, partner: Optional[IcebergType]) ->
341347
def visit_binary(self, binary_type: BinaryType, partner: Optional[IcebergType]) -> Writer:
342348
return BinaryWriter()
343349

350+
def visit_unknown(self, unknown_type: UnknownType, partner: Optional[IcebergType]) -> Writer:
351+
return UnknownWriter()
352+
344353

345354
class ReadSchemaResolver(PrimitiveWithPartnerVisitor[IcebergType, Reader]):
346355
__slots__ = ("read_types", "read_enums", "context")
@@ -471,6 +480,9 @@ def visit_fixed(self, fixed_type: FixedType, partner: Optional[IcebergType]) ->
471480
def visit_binary(self, binary_type: BinaryType, partner: Optional[IcebergType]) -> Reader:
472481
return BinaryReader()
473482

483+
def visit_unknown(self, unknown_type: UnknownType, partner: Optional[IcebergType]) -> Reader:
484+
return UnknownReader()
485+
474486

475487
class SchemaPartnerAccessor(PartnerAccessor[IcebergType]):
476488
def schema_partner(self, partner: Optional[IcebergType]) -> Optional[IcebergType]:

0 commit comments

Comments
 (0)