lightstep / lightstep-tracer-javascript

Lightstep distributed tracing library for Node.js and the browser
https://lightstep.com
MIT License
77 stars 66 forks source link

remove throw in fetch onError handler #246

Closed Karan-Taneja closed 4 years ago

Karan-Taneja commented 4 years ago

Currently we are throwing an exception in the error handler of the request. This exception cannot be caught in a try-catch block which results in node crashing when an invalid fetch request is made. This PR fixes that issues by removing the error handler which was only being used to throw the error.

mwear commented 4 years ago

Thanks @Karan-Taneja!

mwear commented 4 years ago

This fix has been released in:

https://www.npmjs.com/package/lightstep-tracer/v/0.30.2 https://www.npmjs.com/package/lightstep-tracer/v/0.30.2-no-protobuf