Skip to content

fix: show truncation notice when table list exceeds API page limit (#40407)#41485

Closed
01zhas wants to merge 1 commit into
apache:masterfrom
01zhas:fix/41335-german-translations
Closed

fix: show truncation notice when table list exceeds API page limit (#40407)#41485
01zhas wants to merge 1 commit into
apache:masterfrom
01zhas:fix/41335-german-translations

Conversation

@01zhas

@01zhas 01zhas commented Jun 27, 2026

Copy link
Copy Markdown

SUMMARY

The useTables hook already computes a hasMore flag (json.count > json.result.length), but it was never consumed by TableSelector. When a database schema has more tables than the API page limit, users saw a truncated list with no indication that tables were missing.

BEFORE

No indication when the table list is truncated.

AFTER

A helper message appears below the table selector when hasMore is true:

"Some tables are not shown. Refine your search."

CHANGES

  • superset-frontend/src/components/TableSelector/index.tsx — Added TruncationNotice styled component and conditional rendering of the message when data?.hasMore is true.

TESTING INSTRUCTIONS

  1. Connect a database schema with 100+ tables
  2. Open SQL Lab, select that database and schema
  3. Observe the helper message below the table selector informing users that the list is truncated

ADDITIONAL INFORMATION

Closes #40407

…#40407)

Signed-off-by: Ydyrys Olzhas <im01zhas@icloud.com>
@dosubot dosubot Bot added change:frontend Requires changing the frontend sqllab:design Related to the SQL Lab UI/UX labels Jun 27, 2026
@bito-code-review

bito-code-review Bot commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

Code Review Agent Run #f7506b

Actionable Suggestions - 0
Review Details
  • Files reviewed - 1 · Commit Range: 7870cec..7870cec
    • superset-frontend/src/components/TableSelector/index.tsx
  • Files skipped - 0
  • Tools
    • Whispers (Secret Scanner) - ✔︎ Successful
    • Detect-secrets (Secret Scanner) - ✔︎ Successful

Bito Usage Guide

Commands

Type the following command in the pull request comment and save the comment.

  • /review - Manually triggers a full AI review.

  • /pause - Pauses automatic reviews on this pull request.

  • /resume - Resumes automatic reviews.

  • /resolve - Marks all Bito-posted review comments as resolved.

  • /abort - Cancels all in-progress reviews.

Refer to the documentation for additional commands.

Configuration

This repository uses Superset You can customize the agent settings here or contact your Bito workspace admin at evan@preset.io.

Documentation & Help

AI Code Review powered by Bito Logo

@codecov

codecov Bot commented Jun 27, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 50.00000% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 63.95%. Comparing base (0a18779) to head (7870cec).

Files with missing lines Patch % Lines
...et-frontend/src/components/TableSelector/index.tsx 50.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master   #41485      +/-   ##
==========================================
- Coverage   63.95%   63.95%   -0.01%     
==========================================
  Files        2664     2664              
  Lines      146217   146221       +4     
  Branches    33731    33733       +2     
==========================================
+ Hits        93511    93513       +2     
- Misses      50991    50993       +2     
  Partials     1715     1715              
Flag Coverage Δ
javascript 68.96% <50.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@rusackas

rusackas commented Jul 5, 2026

Copy link
Copy Markdown
Member

Thanks @01zhas! There are three open PRs for #40407, and we're consolidating on #41617 since it includes a regression test and reuses the existing styling for this message. Closing this one to keep things tidy, but happy to reopen if you think there's more to add on as a follow-up to the other PR. Appreciate you taking a swing at it, and welcome more contributions in the future!

@rusackas rusackas closed this Jul 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

change:frontend Requires changing the frontend size/S sqllab:design Related to the SQL Lab UI/UX

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] TableSelector silently truncates table list when DB has more tables than API page limit

2 participants