Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

fix(python): allow _rowid in Permutation.select_columns#3277

Open
Zelys-DFKH wants to merge 1 commit intolancedb:mainlancedb/lancedb:mainfrom
Zelys-DFKH:fix/permutation-rowid-selectionZelys-DFKH/lancedb:fix/permutation-rowid-selectionCopy head branch name to clipboard
Open

fix(python): allow _rowid in Permutation.select_columns#3277
Zelys-DFKH wants to merge 1 commit intolancedb:mainlancedb/lancedb:mainfrom
Zelys-DFKH:fix/permutation-rowid-selectionZelys-DFKH/lancedb:fix/permutation-rowid-selectionCopy head branch name to clipboard

Conversation

@Zelys-DFKH
Copy link
Copy Markdown
Contributor

@Zelys-DFKH Zelys-DFKH commented Apr 14, 2026

Summary

Permutation.select_columns(["_rowid", ...]) raised a ValueError because the Python validation layer built its allowed set from Arrow schema names, and _rowid is a virtual column not present in the schema.

The Rust PermutationReader already handles _rowid selection via has_row_id(). The fix treats _rowid as a special case in select_columns and passes it through directly.

Changes

  • python/python/lancedb/permutation.py: skip the schema lookup for _rowid in select_columns
  • python/python/tests/test_permutation.py: add test_select_columns_rowid covering ["_rowid", "id"] and ["_rowid"] alone

Related

Fixes #3132

`_rowid` is a virtual column emitted by the Rust PermutationReader
but not present in the Arrow schema.  Because `select_columns` built
its allowed set from schema names only, requesting `_rowid` always
raised a ValueError even though the Rust layer handles it correctly.

Fixes lancedb#3132
@github-actions github-actions Bot added bug Something isn't working Python Python SDK labels Apr 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working Python Python SDK

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug(python): Permutation select_columns rejects _rowid, breaking Blob V2 workflows

1 participant

Morty Proxy This is a proxified and sanitized view of the page, visit original site.