Uh oh!
There was an error while loading. Please reload this page.
ref(browser): Split stack line parsers into individual functions and simplify further - #4555
Conversation
Revert "More simplify" This reverts commit 84d194e. More working
For reference, the entire
Dropping default Opera support for v7 will save us another ~360 bytes. |
timfish
commented
Feb 11, 2022
Sorry, this PR got a lot bigger than I wanted. It needed a lot of extra changes to get the tests passing. The good news is that the integration tests are working well! |
timfish
commented
Feb 11, 2022
It looks like overall this results in 70 byte increase for ES5 min bundle and almost no change for ES6 min. |
AbhiPrasad
left a comment
There was a problem hiding this comment.
Super busy, but one quick comment I saw, will come back and do a full review on monday!
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
stack-parsers.tsTraceKitStackTraceand instead just returnsStackFrame[]exceptionFromStacktrace(computeStackTrace(e))withexceptionFromError(e))eventFromStacktrace(computeStackTrace(e))witheventFromError(e))Exceptionwhich meant frames needed reversing andin_appaddingcreateStackParserandStackLineParsertype to@sentry/utilswhere there was already astacktrace.tsprepareFramesForEventtostripSentryFramesAndReverseand moved to utils too. This is nearly identical to the node.js code and means the parser now returns frames ready to go intoExceptionin_apptocreateFramein stack parsers since everything browser is consideredin_appstack.split('\n').slice(skipFirst)