Skip to content

Add pks parameter to render_cell() plugin hook#2641

Merged
simonw merged 1 commit intomainfrom
claude/add-pk-to-render-cell-WUQVv
Feb 17, 2026
Merged

Add pks parameter to render_cell() plugin hook#2641
simonw merged 1 commit intomainfrom
claude/add-pk-to-render-cell-WUQVv

Conversation

@simonw
Copy link
Owner

@simonw simonw commented Feb 17, 2026

The render_cell() hook now receives a pks parameter containing the list
of primary key column names for the table being rendered. This avoids
plugins needing to make redundant async calls to look up primary keys.

For tables without an explicit primary key, pks is ["rowid"]. For custom
SQL queries and views, pks is an empty list [].

https://claude.ai/code/session_01HFYfevAziq4fSYTNRD9ZCh


📚 Documentation preview 📚: https://datasette--2641.org.readthedocs.build/en/2641/

The render_cell() hook now receives a pks parameter containing the list
of primary key column names for the table being rendered. This avoids
plugins needing to make redundant async calls to look up primary keys.

For tables without an explicit primary key, pks is ["rowid"]. For custom
SQL queries and views, pks is an empty list [].

https://claude.ai/code/session_01HFYfevAziq4fSYTNRD9ZCh
@simonw simonw merged commit 170f9de into main Feb 17, 2026
7 of 38 checks passed
@simonw simonw deleted the claude/add-pk-to-render-cell-WUQVv branch February 17, 2026 19:13
simonw added a commit that referenced this pull request Feb 26, 2026
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.

2 participants