Skip to content

Fixes #38368: paginate glossary approval-task fetch so all pending proposals stay decidable - #38404

Merged
harsh-vador merged 2 commits into
mainfrom
detail/bug-fix/fixes-38368-paginate-glossary-approval-task-fetch-e4fb65
Nov 23, 2026
Merged

harsh-vador merged 2 commits into
mainfrom
detail/bug-fix/fixes-38368-paginate-glossary-approval-task-fetch-e4fb65

Conversation

@detail-app

@detail-app detail-app Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Detail bug report: View on Detail

Describe your changes:

Fixes #38368

I paginated the glossary approval-task fetch in the Terms tab and the proposal hook because a single listTasks call was hard-capped at 50 results and discarded paging.after, so glossaries with more than 50 open approval tasks silently dropped the oldest pending proposals — hiding their Approve/Reject buttons in the Terms table and showing the term's last editor as the "Proposed by" author instead of the actual proposer.

Type of change:

  • Bug fix

High-level design:

N/A — small change.

Tests:

Use cases covered

  • A glossary with more than 50 open RequestApproval tasks loads every task into the Terms-tab task map, so the oldest pending InReview terms still show Approve/Reject for assigned deciders.
  • The "Proposed by …" badge on a person-proposed InReview term whose task falls past the first page shows the approval task's creator, not the term's last editor.
  • A glossary with ≤50 open tasks behaves exactly as before (one listTasks call, no extra rendering churn).
  • The proposal-hook path (useGlossaryProposal → fetchProposal) pages through approval tasks the same way, so a term whose task is on a later page still resolves its approvalTask.

Unit tests

  • I added unit tests for the new/changed logic.
  • Files added/updated:
    • openmetadata-ui/.../GlossaryTermTab/GlossaryTermTab.test.tsx — 3 tests: cursor is followed across pages; loop terminates when the cursor is exhausted; an oldest page-2 proposal renders Approve/Reject buttons end-to-end.
    • openmetadata-ui/.../hooks/governance/glossary/useGlossaryProposals.test.tsx — 1 test: the hook pages through approval tasks so a page-2 task becomes proposal.approvalTask.

Backend integration tests

  • Not applicable (no backend API changes).

Ingestion integration tests

  • Not applicable (no ingestion changes).

Playwright (UI) tests

  • Not applicable — the scenario requires a glossary seeded with >50 concurrently open approval tasks, which the seeded Playwright datasets don't provide; the Jest layer covers the map-population that drives the rendered Approve/Reject and "Proposed by" behavior. No existing Playwright spec gained coverage from this fix.

Manual testing performed

  • Verified the unit tests, TypeScript check, ESLint, Prettier, organize-imports, and knip all pass on the changed files.
  • Attempted to validate end-to-end against a running 2.0.0-SNAPSHOT server but could not boot the backend in this environment: the pinned dev Docker images (docker.getcollate.io/openmetadata/…:2.0.0-SNAPSHOT) are not published on the registry, and booting the server from the pre-built local jar against locally-started MySQL 8 + Elasticsearch 8.11 (with migrations run via OpenMetadataOperations … migrate) failed during registerResources with UnhandledServerException: App Scheduler is not Initialized — AppScheduler.initialize is only called from the separate migrate JVM / lazily from AppResource, not on the server boot path. The full boot was reproduced with both the noop and AirflowREST pipeline clients, with the same stack trace; the rendered-UI end-to-end therefore remains unverified here.

UI screen recording:

Not applicable — standalone bug fix in existing glossary Terms-tab code (no new feature or feature task).

Checklist:

  • I have read the CONTRIBUTING document.
  • My PR title is Fixes <issue-number>: <short explanation>
  • My PR is linked to a GitHub issue via Fixes #<issue-number> above.
  • I have commented on my code, particularly in hard-to-understand areas.
  • For JSON Schema changes: I updated the migration scripts or explained why it is not needed. — N/A, no schema changes.
  • For a UI feature or feature task: as part of PR creation, I ran the PR build in Docker with sample data and embedded a verified GitHub-hosted recording plus build/health evidence above (or explained why this requirement is not applicable).
  • I have added tests (unit / integration / Playwright as applicable) and listed them above.
  • Self-review: I reviewed the final diff against REVIEW.md (the pr-checklist skill runs it) and fixed every 🔴 finding, or answered it on the line below.
  • Decision check: if this PR decides something the next contributor could undo — a schema field, REST path or format another component or repo must agree with, a new default or limit, an ordering that must hold, or a rule stated only in this description — it adds a record under docs/decisions/ (see its README.md). — N/A, no cross-repo decisions.
  • I have added a test that covers the exact scenario we are fixing. For complex issues, comment the issue number in the test for future reference.

Automatic Fixes PRs can be configured here.

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; no blocking issue was found.

Summary

The PR loads every page of open glossary approval tasks and shares that code through listOpenApprovalTasks.

  • Glossary review views load approval tasks across every page.

Reviews (2) · Last reviewed commit: "refactor(ui): share the paged approval-t..." · Reviewed by Greptile

@harsh-vador
harsh-vador merged commit 5cacec0 into main Nov 23, 2026
53 checks passed
@harsh-vador
harsh-vador deleted the detail/bug-fix/fixes-38368-paginate-glossary-approval-task-fetch-e4fb65 branch November 23, 2026 08:37
harsh-vador added a commit that referenced this pull request Nov 23, 2026
…ing proposals stay decidable (backport 2.1 #38404) (#38425)

* Fixes #38368: paginate glossary approval-task fetch so all pending proposals stay decidable

(cherry picked from commit b38b604)

* refactor(ui): share the paged approval-task fetch between the Terms tab and proposals hook

(cherry picked from commit d7e70d6)

---------

Co-authored-by: detail-app[bot] <180357370+detail-app[bot]@users.noreply.github.com>
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.

[Detail Bug] Glossary Terms tab hides Approve/Reject actions and misattributes proposers when >50 proposals are pending

3 participants