Ava: Display internal Node.js stacktrace if no user stacktrace is present

Created on 29 Apr 2019  路  6Comments  路  Source: avajs/ava


Issuehunt badges

Current behavior

image

Expected behavior

{ Error: self signed certificate
    at TLSSocket.onConnectSecure (_tls_wrap.js:1177:34)
    at TLSSocket.emit (events.js:193:13)
    at TLSSocket._finishInit (_tls_wrap.js:668:8) code: 'DEPTH_ZERO_SELF_SIGNED_CERT' }




IssueHunt Summary

bunysae bunysae has been rewarded.

Backers (Total: $40.00)

Submitted pull Requests

- #2420 Show node internal stack trace

Tips


Rewarded on Issuehunt enhancement help wanted assertions

Most helpful comment

It's the difference between the error originating from your own code or from Node.js itself. If it originates from your own code, you don't really care or want the Node.js code frames, but if the error originates from Node.js, you definitely want them for context or being able to report it to the Node.js team.

All 6 comments

Makes sense to me.

I also notice we don't show the .code property. We should show that if it's not empty, no matter what.

It should also display No user stacktrace present. IMHO

It's a little jarring when there is no stack trace. But, if the Node.js trace lines are useful here, why wouldn't they be useful in other situations?

Should we perhaps color code the trace lines but not filter any?

Agreed we should show all properties of the error.

It's the difference between the error originating from your own code or from Node.js itself. If it originates from your own code, you don't really care or want the Node.js code frames, but if the error originates from Node.js, you definitely want them for context or being able to report it to the Node.js team.

@issuehunt has funded $40.00 to this issue.


@novemberborn has rewarded $36.00 to @bunysae. See it on IssueHunt

  • :moneybag: Total deposit: $40.00
  • :tada: Repository reward(0%): $0.00
  • :wrench: Service fee(10%): $4.00
Was this page helpful?
0 / 5 - 0 ratings