Skip to content

[Data] Restoring ray.air.util.object_extensions.arrow class aliases to fix deserialization of existing datasets#59828

Merged
alexeykudinkin merged 2 commits into
ray-project:masterfrom
alexeykudinkin:ak/tnr-ext-serde-fix-2
Jan 4, 2026
Merged

[Data] Restoring ray.air.util.object_extensions.arrow class aliases to fix deserialization of existing datasets#59828
alexeykudinkin merged 2 commits into
ray-project:masterfrom
alexeykudinkin:ak/tnr-ext-serde-fix-2

Conversation

@alexeykudinkin

@alexeykudinkin alexeykudinkin commented Jan 3, 2026

Copy link
Copy Markdown
Contributor

Description

Follow-up for #59818

  1. Fixing serde for ArrowPythonObjectType
  2. Missing __init__.py files making packages omitted at build time

Related issues

Link related issues: "Fixes #1234", "Closes #1234", or "Related to #1234".

Additional information

Optional: Add implementation details, API changes, usage examples, screenshots, etc.

Signed-off-by: Alexey Kudinkin <ak@anyscale.com>
Signed-off-by: Alexey Kudinkin <ak@anyscale.com>
@alexeykudinkin alexeykudinkin requested a review from a team as a code owner January 3, 2026 23:20
@alexeykudinkin alexeykudinkin added the go add ONLY when ready to merge, run all tests label Jan 3, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request addresses a deserialization issue by restoring class aliases for ArrowPythonObjectType under the ray.air.util.object_extensions.arrow path, ensuring backward compatibility. The approach is sound and consistent with how similar aliases are handled for tensor extensions. I have one minor suggestion to improve a comment for clarity. Otherwise, the change looks good.

Comment on lines +1 to +3
# NOTE: We provide these as aliases to maintain compatibility with older version
# of Arrow `PyExtensionType` that relies on picked class references that
# reference `ray.air.util.{tensor|object}_extensions.arrow.*` classes

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The comment uses a generic path placeholder {tensor|object}. To improve clarity and align with the convention in similar files (e.g., python/ray/air/util/tensor_extensions/arrow.py), it would be better to specify the exact path for this module.

Suggested change
# NOTE: We provide these as aliases to maintain compatibility with older version
# of Arrow `PyExtensionType` that relies on picked class references that
# reference `ray.air.util.{tensor|object}_extensions.arrow.*` classes
# NOTE: We provide these as aliases to maintain compatibility with older versions
# of Arrow `PyExtensionType` that relies on picked class references that
# reference `ray.air.util.object_extensions.arrow.*` classes
@alexeykudinkin alexeykudinkin enabled auto-merge (squash) January 4, 2026 00:08
@alexeykudinkin alexeykudinkin merged commit 3d1e84b into ray-project:master Jan 4, 2026
6 of 7 checks passed
AYou0207 pushed a commit to AYou0207/ray that referenced this pull request Jan 13, 2026
… to fix deserialization of existing datasets (ray-project#59828)

## Description

Follow-up for ray-project#59818

 1. Fixing serde for `ArrowPythonObjectType`
 2. Missing `__init__.py` files making packages omitted at build time

## Related issues
> Link related issues: "Fixes ray-project#1234", "Closes ray-project#1234", or "Related to
ray-project#1234".

## Additional information
> Optional: Add implementation details, API changes, usage examples,
screenshots, etc.

---------

Signed-off-by: Alexey Kudinkin <ak@anyscale.com>
Signed-off-by: jasonwrwang <jasonwrwang@tencent.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

go add ONLY when ready to merge, run all tests

2 participants