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

Handle errors thrown in async functions #421

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Apr 4, 2022

  1. Handle errors thrown in async functions

    If a callback passed to setTimeout (and other timer functions) throws an error, the error propogates up through the host node process, potentially crashing it unless process.on('uncaughtException') is used.
    
    Wrap all callback functions passed to the various host timer functions in a try/catch, so errors are handled and emitted as events on the vm.
    
    Handle several cases where a promise could end up in an unhandledRejection state (which will cause the process to exit in a future version of Node).
    bespokebob committed Apr 4, 2022
    Configuration menu
    Copy the full SHA
    418dd3b View commit details
    Browse the repository at this point in the history