Skip to content

Add docstrings to pyiceberg/table/inspect.py - #3802

Merged
Fokko merged 2 commits into
apache:mainfrom
daviddallakyan2005:docstrings-inspect-py
Aug 15, 2026
Merged

Add docstrings to pyiceberg/table/inspect.py#3802
Fokko merged 2 commits into
apache:mainfrom
daviddallakyan2005:docstrings-inspect-py

Conversation

@daviddallakyan2005

@daviddallakyan2005 daviddallakyan2005 commented Aug 15, 2026

Copy link
Copy Markdown
Contributor

Closes #1191

Rationale for this change

InspectTable in pyiceberg/table/inspect.py had no docstrings. This ports the review-approved text from #3457 (RyukR1; approved by Fokko, rambleraptor, and ebyhr) onto current main.

#3457 was CI-green and approved, then stale-closed. #3555 was a later attempt that closed unreviewed; there is no open PR.

Two docstring-only adjustments versus #3457, because main moved:

  • document the key_metadata column on all_manifests / _get_all_manifests_schema
  • spacing on spec_id in partitions

Follow-up: partitions() Raises now matches entries(). Both call _get_snapshot(), which raises ValueError when the specified snapshot is missing or the table has no snapshots and snapshot_id is None.

No code changes. RyukR1 is credited as co-author.

Are these changes tested?

  • make lint — all hooks pass, including pydocstyle and mypy
  • make test — 3929 passed, 3 skipped

Are there any user-facing changes?

No behavior or API changes. Docstrings only; help text / IDE discoverability for the existing inspect methods.

daviddallakyan2005 and others added 2 commits August 15, 2026 13:52
The inspect API had no docstrings. This ports the review-approved
text from apache#3457 onto current main, including key_metadata on
all_manifests which landed after that PR.

Co-authored-by: RyukR1 <biplovsingh785@gmail.com>
entries() already documents this ValueError from _get_snapshot();
partitions() uses the same helper.

@Fokko Fokko 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.

Thanks for adding this @daviddallakyan2005 🙌

@Fokko
Fokko merged commit 2612f28 into apache:main Aug 15, 2026
18 checks passed
@daviddallakyan2005
daviddallakyan2005 deleted the docstrings-inspect-py branch August 15, 2026 18:36
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.

Add Docstrings to pyiceberg/table/inspect.py

2 participants