Skip to content

fix(service): properly wrap luna errors in asyncCall#222

Open
kitsuned wants to merge 1 commit intowebosbrew:mainfrom
kitsuned:fix/asyncCall-wrap-error
Open

fix(service): properly wrap luna errors in asyncCall#222
kitsuned wants to merge 1 commit intowebosbrew:mainfrom
kitsuned:fix/asyncCall-wrap-error

Conversation

@kitsuned
Copy link
Copy Markdown
Member

if luna callee returns an error (returnValue is false), asyncCall throws the raw payload object instead of an Error.

further down the call stack, tryRespond catches this value and calls assertNodeError.

assertNodeError checks whether the argument's prototype is Error and throws a new error if a raw payload is passed.

as a result, this leads to an unhandled promise rejection. HBC's Luna service does not send a response to client, which causes request calls to hang indefinitely.


this PR fixes promise rejection.

@kitsuned kitsuned requested a review from throwaway96 January 24, 2026 11:18
@kitsuned kitsuned self-assigned this Jan 24, 2026
@throwaway96
Copy link
Copy Markdown
Member

This sounds extremely familiar... I thought I fixed (something exactly like?) this.

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