Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion lib/internal/errors.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ const {
JSONStringify,
Map,
MathAbs,
MathMax,
NumberIsInteger,
ObjectDefineProperty,
ObjectKeys,
Expand Down Expand Up @@ -700,7 +701,11 @@ const fatalExceptionStackEnhancers = {
require('internal/tty').hasColors()) ||
defaultColors);
try {
return inspect(error, { colors });
return inspect(error, {
colors,
customInspect: false,
depth: MathMax(inspect.defaultOptions.depth, 5)
});
} catch {
return originalStack;
}
Expand Down
2 changes: 1 addition & 1 deletion test/message/assert_throws_stack.out
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,6 @@ AssertionError [ERR_ASSERTION]: Expected values to be strictly deep-equal:
at *
at *
at *,
expected: [Object],
expected: { bar: true },
operator: 'throws'
}