Skip to content

[python] Add manifest sidecar codec and block-pruned reads - #9908

Merged
JingsongLi merged 2 commits into
apache:masterfrom
leaves12138:codex/python-manifest-sidecar-read
Sep 17, 2026
Merged

JingsongLi merged 2 commits into
apache:masterfrom
leaves12138:codex/python-manifest-sidecar-read

Conversation

@leaves12138

@leaves12138 leaves12138 commented Sep 17, 2026

Copy link
Copy Markdown
Contributor

Purpose

Extract the Python sidecar core and read integration from #9743, on top of the merged Java v1 format and read support (#9845, #9886, #9889, #9897).

Changes

  • Add the standalone v1 sidecar codec, complete block directory, exact row-ID intervals, partition dictionary and bucket coverage, using the shared Java golden file.
  • Prune manifest blocks before decoding entries in the Python scan path. Preserve normal entry predicates, column groups and ADD/DELETE reconciliation.
  • Read only explicitly referenced sidecars, fall back to normal manifest reads for missing/unusable sidecars, and propagate cancellation/interruption.
  • Skip sidecar I/O when disabled, without relevant filters, and in explain/statistics mode.
  • Classify sidecars as metadata so existing local FileIO caching can reuse their bytes.

Scope

This is a read/core-only draft. The low-level codec can produce bytes for fixtures and callers, but Python manifest writers do not automatically create or publish sidecars in this PR. Writer, merger and failed-write cleanup changes are deferred to a follow-up. No Java cache changes are included.

Validation

  • Python 3.11: 159 manifest/read/file-type tests passed.
  • Python 3.6: all 91 focused sidecar/file-type tests passed with isolated dependencies. The broader suite has 133 passed, 9 skipped and 17 failures; the same 17 failures reproduce on unmodified master in the same environment (PyArrow 6 lacks Table.from_pylist / sort_by, and Lance is not installed).
  • Shared Java v1 golden file: byte-for-byte encoding agreement and read selection checks passed.
  • Python lint passed using the repository configuration.
  • AST comparison confirms only read and read_entries_parallel changed in ManifestFileManager; all writer methods remain identical to master.

@XiaoHongbo-Hope

Copy link
Copy Markdown
Contributor

+1

@JingsongLi
JingsongLi marked this pull request as ready for review September 17, 2026 07:12
@JingsongLi

Copy link
Copy Markdown
Contributor

+1

@JingsongLi
JingsongLi merged commit 8b7fbff into apache:master Sep 17, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants