Skip to content

[python] Add --snapshot-id to table read and explain for Python CLI. - #11297

Open
fengruotj wants to merge 1 commit into
apache:masterfrom
fengruotj:feat/cli-table-snapshot-id-support
Open

fengruotj wants to merge 1 commit into
apache:masterfrom
fengruotj:feat/cli-table-snapshot-id-support

Conversation

@fengruotj

Copy link
Copy Markdown
Contributor

Purpose

Closes #11073

adding --snapshot-id to table read and table explain in the PyPaimon CLI.

  • paimon table read mydb.orders --snapshot-id 42 reads rows visible at snapshot 42 on the table's branch. Column names in --select and --where are resolved against that snapshot's schema.
  • paimon table explain mydb.orders --snapshot-id 42 shows the scan plan for the same snapshot without reading data files.

An explicit snapshot ID takes precedence over configured snapshot or tag selectors. The CLI documentation includes examples for both commands.

Tests

  • paimon-python/pypaimon/tests/cli_table_test.py passed all 106 tests, including coverage for schema evolution, branch selection, and invalid or missing snapshot IDs.
  • flake8 passed for both changed Python files.

@fengruotj fengruotj changed the title [python] Add --snapshot-id to table read and explain. [python] Add --snapshot-id to table read and explain for Python CLI. Nov 20, 2026
@fengruotj
fengruotj force-pushed the feat/cli-table-snapshot-id-support branch from d36b300 to a3bcfbd Compare November 20, 2026 08:06
@fengruotj
fengruotj marked this pull request as draft November 20, 2026 09:02
@fengruotj
fengruotj marked this pull request as ready for review November 20, 2026 09:02
@fengruotj fengruotj closed this Nov 20, 2026
@fengruotj fengruotj reopened this Nov 20, 2026
@fengruotj fengruotj closed this Nov 20, 2026
@fengruotj fengruotj reopened this Nov 20, 2026
@fengruotj
fengruotj force-pushed the feat/cli-table-snapshot-id-support branch from a3bcfbd to e41c280 Compare November 20, 2026 09:06
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.

[Feature] Add manifest, snapshot, schema, files commands to the PyPaimon CLI

1 participant