Skip to content

Conversation

@jeclrsg
Copy link
Contributor

@jeclrsg jeclrsg commented Jun 13, 2025

catch exception thrown in wuResult.fetchRows() and pass that message back to the dgrid table to display instead of the normal noDataMessage

HPCC-32576 (Viewing a file does not pass back errors to the user)

Checklist:

  • The commit message is properly formatted and free of typos.
    • The commit message title makes sense in a changelog, by itself.
    • The commit message includes a "fixes" reference if appropriate.
    • The commit is signed.
  • The change has been fully tested:
    • I have viewed all related gallery items
    • I have viewed all related dermatology items
  • There are no similar instances of the same problem that should be addressed
    • I have addressed them here
    • I have raised new issues to address them separately

Testing:

@jeclrsg jeclrsg requested a review from Copilot June 13, 2025 13:26
Copy link

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 enhances error handling in the WUResult table by catching exceptions from wuResult.fetchRows() and conveying the error message back to the UI.

  • Updates the Store class to accept an onError callback and capture the last error.
  • Modifies WUResult to pass a callback that updates the dgrid noDataMessage with the exception message.
  • Adds a published property for exceptionMessage in the dgrid Common class.

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
packages/eclwatch/src/WUResultStore.ts Adds error handling in the Store with an onError callback and _lastError tracking.
packages/eclwatch/src/WUResult.ts Passes an error callback to Store to update exceptionMessage and refresh dgrid messaging.
packages/dgrid/src/Common.ts Publishes the exceptionMessage property to support UI error updates.
Comments suppressed due to low confidence (1)

packages/eclwatch/src/WUResultStore.ts:189

  • Verify that the Exception object always provides a 'Message' property (with uppercase M). If the standard property name is 'message' (lowercase), the error message may be incorrectly captured.
this._lastError = err.Message || "An exception has occurred";

@jeclrsg jeclrsg requested a review from GordonSmith June 13, 2025 13:30
catch exception thrown in wuResult.fetchRows() and pass that message
back to the dgrid table to display instead of the normal noDataMessage

HPCC-32576 (Viewing a file does not pass back errors to the user)

Signed-off-by: Jeremy Clements <[email protected]>
@jeclrsg jeclrsg force-pushed the fix-WUResult-fetch-exceptions branch from 6318863 to 934c413 Compare June 17, 2025 12:54
@GordonSmith GordonSmith merged commit d4ee8b8 into hpcc-systems:candidate-2.x.x Jun 17, 2025
5 checks passed
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.

2 participants