feat: add joinable-tables and joinable-columns endpoints - #117
Open
fredj wants to merge 1 commit into
Open
Conversation
fredj
marked this pull request as ready for review
August 27, 2026 08:59
tonio
reviewed
Sep 8, 2026
| summary="List tables available for join", | ||
| description="List tables available for join with role-based filtering. " | ||
| "Normal users see only their own links, administrators see all links. " | ||
| "No filtering on COPY mode or reference datasets yet.", |
Contributor
There was a problem hiding this comment.
«copy mode» ? Reference datasets is for future I guess?
Collaborator
Author
There was a problem hiding this comment.
Right — list_joinable_tables currently only returns final tables from regular (non-COPY) imports; COPY-mode and reference-dataset filtering aren't implemented yet, this endpoint just returns everything with a final_table_name for now.
| data_session: DataSessionDep, | ||
| geo_ctx: GeorchestraContextDep, | ||
| group_ids: GroupIdsDep, | ||
| ) -> list[JoinableTable]: |
Contributor
There was a problem hiding this comment.
what if there are table with the same names in different schemas ?
Either we should return schema names, or it will be resolved from integrity_link_id ?
Collaborator
Author
There was a problem hiding this comment.
Resolution is via integrity_link_id (JoinableTable.id), not table_name, so same-named tables in different schemas don't collide.
Adds two read-only endpoints for the join-table picker: listing final tables available as join targets, and listing a table's columns. Both apply the same owner/METADATA-rule visibility rule used by the integrity-links list. Extracts that rule into a shared visibility_condition helper in core/security.py, reused by both endpoints.
fredj
force-pushed
the
joinable-tables-endpoints
branch
from
September 8, 2026 14:57
8772862 to
e155516
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds two read-only endpoints for the join-table picker: listing final tables available as join targets, and listing a table's columns. Both apply the same owner/METADATA-rule visibility rule used by the integrity-links list. Extracts that rule into a shared _visibility_condition helper reused by both endpoints.