Skip to content

CLI: Show metadata location in describe view - #4153

Merged
geruh merged 1 commit into
apache:mainfrom
kevinjqliu:kevinjqliu-cli-describe-view-metadata-location
Oct 25, 2026
Merged

geruh merged 1 commit into
apache:mainfrom
kevinjqliu:kevinjqliu-cli-describe-view-metadata-location

Conversation

@kevinjqliu

@kevinjqliu kevinjqliu commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

Rationale for this change

Follow-up to #4088, which added View.metadata_location.

pyiceberg describe view now shows the view's metadata location, matching describe table. JSON output is unchanged. Also documents the view CLI commands in cli.md.

Are these changes tested?

Yes, test_describe_view now checks the full text output.

  • uv run pytest tests/cli/ tests/catalog/test_rest.py: 275 passed
  • prek run --from-ref origin/main --to-ref HEAD (ruff, mypy, markdownlint, codespell): passed

Are there any user-facing changes?

Yes, pyiceberg describe view shows a new "Metadata location" row.

Copilot AI balanced review requested due to automatic review settings October 25, 2026 03:26

Copilot AI 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.

🟢 Approval recommended

The changes are narrowly scoped, preserve constructor compatibility and JSON output, and have relevant regression coverage with no blocking issues identified.

No open issues 🎉

What changed in this PR

Adds the metadata location to pyiceberg describe view, matching describe table while leaving JSON output unchanged. This builds on the REST metadata-location support from #4088.

Changes:

  • Preserves REST metadata locations on View and includes them in equality checks.
  • Adds a “Metadata location” row to console output.
  • Updates REST and CLI regression assertions.
File Description
tests/​integration/​test_rest_catalog.py Verifies created views expose a metadata location.
tests/​cli/​test_console.py Checks full view output, including metadata location.
tests/​catalog/​test_rest.py Checks metadata locations for create, load, and register responses.
pyiceberg/​view/​__init__.py Adds an optional metadata location and compares it in equality.
pyiceberg/​cli/​output.py Displays the view’s metadata location.
pyiceberg/​catalog/​rest/​__init__.py Passes the REST response’s metadata location to View.

Review effort: Balanced

@rambleraptor rambleraptor left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This looks great and a super simple fix.

Could you update the docs (cli.md) to mention that the CLI supports views? I didn't see anything on first look.

@kevinjqliu
kevinjqliu force-pushed the kevinjqliu-cli-describe-view-metadata-location branch 3 times, most recently from 367c83d to 45e35b1 Compare October 25, 2026 03:59
Match describe table text output by including the view's metadata location,
and document the view CLI commands.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@kevinjqliu
kevinjqliu force-pushed the kevinjqliu-cli-describe-view-metadata-location branch from 45e35b1 to fbcd65a Compare October 25, 2026 04:01
@kevinjqliu
kevinjqliu requested review from Fokko and geruh October 25, 2026 04:02
@kevinjqliu

Copy link
Copy Markdown
Contributor Author

Could you update the docs (cli.md) to mention that the CLI supports views? I didn't see anything on first look.

ty, i added it

@geruh
geruh added this pull request to the merge queue Oct 25, 2026
Merged via the queue into apache:main with commit e2c1e78 Oct 25, 2026
21 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.

5 participants