Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include error message when error raised by object macro #341

Merged

Conversation

gleuch
Copy link
Contributor

@gleuch gleuch commented May 24, 2020

This PR includes the error message in the response when error is raised within an object macro.

When an error is raised in an object, the error message is included along with the default error response, e.g. [ERR: Error when executing JavaScript object: TypeError]. Very useful for debugging & testing!

However, when an error is raised in an async object macro, instead of returning the above default error reply, it only returns [ERR: Error raised by object macro]. Adding error message to follow similar pattern above.

Test added to cover this.

👉 Take note of the misspelling in the tests of asyc that was preventing await tests from running.

@kirsle kirsle merged commit f80dd8b into aichaos:master Jun 5, 2020
@kirsle
Copy link
Member

kirsle commented Jun 5, 2020

Thank you!

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