Skip to content

fix(admin): name the schema on an Operations table row - #984

Merged
cevheri merged 1 commit into
libredb:mainfrom
JavierparraDev:fix/977-operations-row-schema
Sep 19, 2026
Merged

cevheri merged 1 commit into
libredb:mainfrom
JavierparraDev:fix/977-operations-row-schema

Conversation

@JavierparraDev

Copy link
Copy Markdown
Contributor

Description

The admin Operations page listed tables without their schema, so two tables that share a name in different schemas rendered as identical rows and an operator choosing between them could not tell which was which. The row now prints schema.table.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)

Related Issue

Closes #977

Changes Made

  • src/components/admin/tabs/OperationsTab.tsx: the table row now renders the schema in a muted span outside the truncating span, followed by . and the table name. The table name keeps its existing truncate max-w-[160px], so a long name still truncates and the schema survives it.
  • tests/components/admin/OperationsTab.test.tsx: added a test that pins the schema on the row for two schemas sharing a label (it goes red if the schema is dropped), and a test that pins the truncation on the table name. Corrected the now-stale comment in the deep-link collision test that recorded the row did not print its schema.

Testing

  • I have tested this locally
  • I have added/updated tests
  • All existing tests pass

Ran locally (Bun 1.4.2, linux-x64):

  • bun run format — clean
  • bun run lint — 0 errors (228 pre-existing warnings)
  • bun run typecheck — clean
  • bun run knip — clean
  • bun tests/run-tests.ts tests/components — 92 files, 2983 tests pass
  • bun tests/run-tests.ts tests/components/admin/OperationsTab.test.tsx --coverage --merge-into=coverage/lcov.info — OperationsTab.tsx 507/507 lines (100%)

Not run locally: bun run build, bun run build:lib + bun run attw, and the full bun run test:coverage over every file. I ran coverage for the changed component only; the required CI job runs the whole suite. Please approve the workflow run for this fork so CI can verify the rest.

Test Environment

  • Bun: 1.4.2 · Node: 24 · OS: linux-x64

Checklist

  • My code follows the project's code style guidelines
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have updated the documentation accordingly
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • The required CI test job passes the 100% line-coverage gate (bun run test:coverage and bun run coverage:check) — for the changed component; the whole-suite run is left to CI
  • If I changed src/lib/db/providers/, I updated the matching docs/providers/ documentation and tests/integration/db/ tests in the same PR (provider triad) — not applicable, no provider touched
  • Any dependent changes have been merged and published

Two tables that share a name in different schemas rendered as identical rows,
so an operator choosing between them could not tell which was which. The row
now prints `schema.table`: the schema sits in a muted span OUTSIDE the
truncating span, so a long table name still truncates at max-w-[160px] and the
schema survives it.

The component test pins the schema on the row (it goes red the moment the
schema is dropped) and pins the truncation on the table name. The stale comment
in the deep-link collision test, which recorded that the row did not print its
schema, is corrected.

Closes libredb#977
@cevheri cevheri added the enhancement New feature or request label Sep 19, 2026
@codecov

codecov Bot commented Sep 19, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@cevheri
cevheri merged commit cd76a88 into libredb:main Sep 19, 2026
24 checks passed
@cevheri

cevheri commented Sep 19, 2026

Copy link
Copy Markdown
Member

thanks and welcome

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Admin Operations table list does not show a row's schema

2 participants