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

Unhandled rejections when handler is cancelled #5

Open
bergus opened this issue Jul 22, 2016 · 0 comments
Open

Unhandled rejections when handler is cancelled #5

bergus opened this issue Jul 22, 2016 · 0 comments

Comments

@bergus
Copy link
Owner

bergus commented Jul 22, 2016

Should a promise be reported as unhandled when it had a catch handler installed but that was later cancelled?

const {token, cancel} = CancelToken.source();
setTimeout(cancel, 500);

const promise = new Promise((resolve, reject) => {
    setTimeout(reject, 1000);
});
token.catch(e => { /* do something */ }, token);

The current proposal does not, as [[PromiseIsHandled]] is set to true when the handler is installed, and that's it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant