Skip to content

fix: action buttons visible immediately despite slow pipelineStatus API#27139

Merged
Rohit0301 merged 6 commits intomainfrom
fix-3480
Apr 11, 2026
Merged

fix: action buttons visible immediately despite slow pipelineStatus API#27139
Rohit0301 merged 6 commits intomainfrom
fix-3480

Conversation

@Rohit0301
Copy link
Copy Markdown
Contributor

@Rohit0301 Rohit0301 commented Apr 7, 2026

Describe your changes:

On the Ingestion List table, the action buttons (Run, Pause, Logs) were not visible until the pipelineStatus API responded. When this API had high latency, users were blocked from interacting with pipelines.

Root cause: Permissions and run history were fetched sequentially — action buttons only rendered after both APIs settled.

Fire permissions and run history fetches concurrently. Each updates state independently as soon as it settles:

Permissions settle → action buttons render immediately
Run history settles → status dots render (independently)

Fixes 27100

I worked on ... because ...

Screenshot 2026-04-07 at 10 51 09 PM

Fixed the recent runs overlapping issue.

Screenshot 2026-04-07 at 11 31 02 PM

Type of change:

  • Bug fix
  • Improvement
  • New feature
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation

Checklist:

  • I have read the CONTRIBUTING document.
  • My PR title is Fixes <issue-number>: <short explanation>
  • 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.

@Rohit0301 Rohit0301 self-assigned this Apr 7, 2026
@Rohit0301 Rohit0301 added the safe to test Add this label to run secure Github workflows on PRs label Apr 7, 2026
@Rohit0301 Rohit0301 requested a review from a team as a code owner April 7, 2026 17:39
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 7, 2026

Jest test Coverage

UI tests summary

Lines Statements Branches Functions
Coverage: 64%
64.28% (59497/92555) 43.78% (31019/70851) 46.94% (9357/19930)

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 7, 2026

🔴 Playwright Results — 1 failure(s), 19 flaky

✅ 3621 passed · ❌ 1 failed · 🟡 19 flaky · ⏭️ 209 skipped

Shard Passed Failed Flaky Skipped
🟡 Shard 1 477 0 3 4
🟡 Shard 2 640 0 2 32
🟡 Shard 3 648 0 3 26
🟡 Shard 4 617 0 5 47
🔴 Shard 5 605 1 1 67
🟡 Shard 6 634 0 5 33

Genuine Failures (failed on all attempts)

Pages/Glossary.spec.ts › Add and Remove Assets (shard 5)
�[31mTest timeout of 180000ms exceeded.�[39m
🟡 19 flaky test(s) (passed on retry)
  • Flow/SearchRBAC.spec.ts › User without permission (shard 1, 1 retry)
  • Features/CustomizeDetailPage.spec.ts › API Endpoint - customization should work (shard 1, 1 retry)
  • Pages/UserCreationWithPersona.spec.ts › Create user with persona and verify on profile (shard 1, 1 retry)
  • Features/BulkEditEntity.spec.ts › Table (shard 2, 1 retry)
  • Features/BulkImport.spec.ts › Keyboard Delete selection (shard 2, 1 retry)
  • Features/Permissions/GlossaryPermissions.spec.ts › Team-based permissions work correctly (shard 3, 1 retry)
  • Features/UserProfileOnlineStatus.spec.ts › Should not show online status for inactive users (shard 3, 1 retry)
  • Flow/ExploreDiscovery.spec.ts › Should not display soft deleted assets in search suggestions (shard 3, 1 retry)
  • Pages/Customproperties-part2.spec.ts › entityReferenceList shows item count, scrollable list, no expand toggle (shard 4, 1 retry)
  • Pages/DataContracts.spec.ts › Create Data Contract and validate for Directory (shard 4, 1 retry)
  • Pages/DomainDataProductsRightPanel.spec.ts › Should display overview tab for data product (shard 4, 1 retry)
  • Pages/Domains.spec.ts › Data Product announcement create, edit & delete (shard 4, 1 retry)
  • Pages/Domains.spec.ts › Multiple consecutive domain renames preserve all associations (shard 4, 1 retry)
  • Pages/ExploreTree.spec.ts › Verify Database and Database Schema available in explore tree (shard 5, 1 retry)
  • Pages/Lineage/DataAssetLineage.spec.ts › Column lineage for dashboard -> dashboardDataModel (shard 6, 1 retry)
  • Pages/Lineage/LineageFilters.spec.ts › Verify lineage schema filter selection (shard 6, 1 retry)
  • Pages/ProfilerConfigurationPage.spec.ts › Non admin user (shard 6, 1 retry)
  • Pages/UserDetails.spec.ts › Create team with domain and verify visibility of inherited domain in user profile after team removal (shard 6, 1 retry)
  • Pages/Users.spec.ts › Permissions for table details page for Data Consumer (shard 6, 1 retry)

📦 Download artifacts

How to debug locally
# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip    # view trace

slowTestPipeline.fullyQualifiedName
)}/pipelineStatus**`,
async (route) => {
await page.waitForTimeout(8000);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why we are adding manual wait?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ShaileshParmar11 This timeout is added to increase the latency of that API to test few changes on UI.

// Verify the run was triggered by checking the pipeline row shows a running state
await expect(
pipelineRow.getByTestId('pipeline-status').first()
).toBeVisible({ timeout: 15000 });
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in every step i see random timeout, what the reason of it, and do we even need it?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added this timeout is added because we need to check few things on UI after the api response came for the api for which we have increased the latency by mocking it.

@gitar-bot
Copy link
Copy Markdown

gitar-bot bot commented Apr 10, 2026

Code Review ✅ Approved 2 resolved / 2 findings

Fixes action buttons now displaying immediately by silencing permission promise errors and removing unreachable .catch() handlers that relied on Promise.allSettled rejecting.

✅ 2 resolved
Bug: Permission promise errors are silently swallowed

📄 openmetadata-ui/src/main/resources/ui/src/components/Settings/Services/Ingestion/IngestionListTable/IngestionListTable.tsx:204-213
The Promise.allSettled(permissionPromises).then(...) chain at line 204 has no .catch() handler. While Promise.allSettled itself never rejects, the .then() callback can throw (e.g., if ingestionData[index] is unexpectedly undefined and .name access throws). If that happens, the rejection is unhandled — no error toast, no loading state cleanup, and it may trigger an unhandledrejection warning in the browser.

In contrast, the run-history chain at line 215 correctly has .catch() and .finally().

This is also a minor semantic issue: isIngestionRunsLoading is set to true at the top but only cleared when the run-history promise settles. If the permission promise errors, there's no issue with loading state — but if the run-history promise somehow doesn't execute (unlikely but defensive), loading would remain true forever.

Quality: Promise.allSettled never rejects — .catch() handlers are dead code

📄 openmetadata-ui/src/main/resources/ui/src/components/Settings/Services/Ingestion/IngestionListTable/IngestionListTable.tsx:215 📄 openmetadata-ui/src/main/resources/ui/src/components/Settings/Services/Ingestion/IngestionListTable/IngestionListTable.tsx:241
Promise.allSettled() by specification always resolves (never rejects), even when individual promises fail. The .catch() handlers on lines 215 and 241 are unreachable dead code, which gives a false sense of error coverage.

Because the individual results are already handled inside .then() via cv.status === 'fulfilled', no additional error handling is needed at the outer promise level.

Options

Display: compact → Showing less information.

Comment with these commands to change:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

@Rohit0301 Rohit0301 merged commit 2ca0109 into main Apr 11, 2026
45 checks passed
@Rohit0301 Rohit0301 deleted the fix-3480 branch April 11, 2026 18:23
SaaiAravindhRaja pushed a commit to SaaiAravindhRaja/OpenMetadata that referenced this pull request Apr 12, 2026
…PI (open-metadata#27139)

* fix: action buttons visible immediately despite slow pipelineStatus API

* fixed the recent run overlapping issue

* addressed gitar comment

* addressed PR comment

* addressed gitar comment

* fixed lint checks
SaaiAravindhRaja pushed a commit to SaaiAravindhRaja/OpenMetadata that referenced this pull request Apr 12, 2026
…PI (open-metadata#27139)

* fix: action buttons visible immediately despite slow pipelineStatus API

* fixed the recent run overlapping issue

* addressed gitar comment

* addressed PR comment

* addressed gitar comment

* fixed lint checks
Rohit0301 added a commit that referenced this pull request Apr 17, 2026
…PI (#27139)

* fix: action buttons visible immediately despite slow pipelineStatus API

* fixed the recent run overlapping issue

* addressed gitar comment

* addressed PR comment

* addressed gitar comment

* fixed lint checks
@nikhilchennam nikhilchennam added the To release Will cherry-pick this PR into the release branch label Apr 17, 2026
@sonarqubecloud
Copy link
Copy Markdown

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

Labels

safe to test Add this label to run secure Github workflows on PRs To release Will cherry-pick this PR into the release branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

"Recent Runs" and "Status" columns overlapping in Metadata Agents table

3 participants