Skip to content

fix: Pending events are not showing in some cases#1098

Merged
Assem-Uber merged 2 commits intocadence-workflow:masterfrom
Assem-Uber:fix/17027/grouper-not-notifying-subsicribers-on-pending-updates
Dec 2, 2025
Merged

fix: Pending events are not showing in some cases#1098
Assem-Uber merged 2 commits intocadence-workflow:masterfrom
Assem-Uber:fix/17027/grouper-not-notifying-subsicribers-on-pending-updates

Conversation

@Assem-Uber
Copy link
Contributor

@Assem-Uber Assem-Uber commented Dec 2, 2025

Summary
Pending events are not showing on history in some cases as the Grouper doesn't notify History component that groups are updated. This happens in few cases when the pending events are fetched after the history timeline is loaded.

Fix

  • Notify subscribers after pending events are processeed

Testing

  • Added test cases to validate onChange is called after pending events processing
  • Verified it is working on the workflow that this was found at:
    Before:
Screenshot 2025-12-02 at 12 02 27

After:
Screenshot 2025-12-02 at 12 04 15

@Assem-Uber Assem-Uber requested a review from Copilot December 2, 2025 11:04
@Assem-Uber Assem-Uber changed the title Fix/17027/grouper-not-notifying-subsicribers-on-pending-updates fix: Pending events are not showing in some cases Dec 2, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes a bug where pending events weren't being displayed in the workflow history timeline when they were fetched after the initial history load. The issue occurred because the Grouper class wasn't notifying subscribers after processing pending events.

  • Added subscriber notification after pending events are processed in processPendingEvents method
  • Added comprehensive test coverage to validate that onChange callbacks are triggered after pending event processing

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/views/workflow-history/helpers/workflow-history-grouper.ts Added subscriber notification after pending events are processed, ensuring the History component is notified of state changes
src/views/workflow-history/helpers/tests/workflow-history-grouper.test.tsx Added test case to verify that subscribers are notified after pending events processing

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Assem-Uber Assem-Uber merged commit 5a1b5f3 into cadence-workflow:master Dec 2, 2025
9 of 12 checks passed
@Assem-Uber Assem-Uber deleted the fix/17027/grouper-not-notifying-subsicribers-on-pending-updates branch December 2, 2025 11:49
adhityamamallan pushed a commit to adhityamamallan/cadence-web that referenced this pull request Dec 3, 2025
)

* Notify subscirbers on pending event changes

* remove .only from test case

Signed-off-by: Adhitya Mamallan <adhitya.mamallan@uber.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.

3 participants