node-bunyan icon indicating copy to clipboard operation
node-bunyan copied to clipboard

Handle non-function `cause` field in error serializer

Open yelworc opened this issue 11 months ago • 2 comments

Current versions of Node.js/V8 formally added the cause property as an "official" error field, but are suggesting to store the source error object in it (as opposed to a function, as expected by Bunyan).

Bunyan should probably handle error-type cause properties accordingly in its default error serializer (it can still accept functions as before, of course, for the sake of backwards compatibility).

yelworc avatar Jul 24 '23 10:07 yelworc

The cause property is a JS standard:

rpaterson avatar Mar 10 '24 17:03 rpaterson

This would be fixed by #665

rpaterson avatar Mar 10 '24 17:03 rpaterson