Skip to content

Conversation

@Nokel81
Copy link
Contributor

@Nokel81 Nokel81 commented Jan 4, 2023

Signed-off-by: Sebastian Malton [email protected]

@Nokel81
Copy link
Contributor Author

Nokel81 commented Jan 4, 2023

According to Typescript the typing for an ErrnoException (which is what Node generally throws when doing IO activity) is the following:

interface ErrnoException extends Error {
      errno?: number | undefined;
      code?: string | undefined;
      path?: string | undefined;
      syscall?: string | undefined;
}

And it is useful to have the path as part of the error

@G-Rath G-Rath changed the title Add path field to errors to more closely align with Node fix: set path on errors when possible Jan 7, 2023
@G-Rath G-Rath merged commit fb6e1e6 into streamich:master Jan 7, 2023
streamich pushed a commit that referenced this pull request Jan 7, 2023
## [3.4.13](v3.4.12...v3.4.13) (2023-01-07)

### Bug Fixes

* set `path` on errors when possible ([#893](#893)) ([fb6e1e6](fb6e1e6))
@streamich
Copy link
Owner

🎉 This PR is included in version 3.4.13 🎉

The release is available on:

Your semantic-release bot 📦🚀

@Nokel81 Nokel81 deleted the add-path-to-errors branch April 28, 2023 14:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants