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

Support nesting with cause #64

Open
conartist6 opened this issue Sep 28, 2021 · 2 comments
Open

Support nesting with cause #64

conartist6 opened this issue Sep 28, 2021 · 2 comments

Comments

@conartist6
Copy link

I'm building an application which really needs nested errors. The fs can throw, but in my application just seeing what failed isn't enough to understand what action was being attempted when a failure occurred. Instead I must catch the source error, attach some additional context, and rethrow.

I'd like to be able to attach the original error as a cause. Spec-level support for this is already underway. A shim has been published as well, but while it can get a cause property set up correctly, it doesn't contain any logic about rendering causes. This library has an opportunity to be the first to present such information in a useful way and kickstart the community's ability to use this feature.

I'm going to make a fork and see what I can do.

@conartist6
Copy link
Author

The only slight problem is that my personal temptation is to hard fork it as I don't know coffeescript and I don't want to.

@AriaMinaei
Copy link
Owner

Supporting cause sounds like a good idea!

As to coffeescript, I'll be happy to merge back TS or ESNext :)

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

No branches or pull requests

2 participants