Logging long/async JS stack traces to Sentry (we use async/await)


#1

Hi, I was wondering: does Sentry recommend a way to log async stack traces (aka long stack traces) from using JS promises and async functions?


#2

The support we get from browsers here is non existing. To support traces here we would have to serialize them out whenever you create a promise which is very slow. Not sure if there are any low-hanging fruits to make this work.


#3

We’re using Raven on our Node server and it’s fast enough (the work the V8 team has done to make async functions 4x faster recently is awesome) for us to be willing to pay for the overhead of creating stacks when we create promises. Usually when we make a promise we’re doing I/O anyway.

Similar to how “breadcrumbs” in raven-node are opt-in, we’d be interested in opting into a hypothetical “async stack traces” option if you guys were to add one.