You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ref(stackparse): More stack parse improvements and consolidation (#4669)
- Removes browser SDK `parsers.ts` and moves code to `eventbuilder.ts` to match node SDK
- There is no actual parsing occurring here any more so the filename didn't make much sense
- As per the node SDK, renames browser parsers to be more clear `chrome` -> `chromeStackParser`
- Adds priority to all stack parsers and sorts them when creating the parser
- This is preliminary work to allow user to configure parsers
- Renames `eventFromError` to `eventFromUnknownInput` to match browser SDK
- Renames `extractStackFromError` to `parseStackFrames` to match browser SDK
// Access and store the stacktrace property before doing ANYTHING
98
+
// else to it because Opera is not very good at providing it
99
+
// reliably in other circumstances.
100
+
conststacktrace=ex.stacktrace||ex.stack||'';
101
+
102
+
constpopSize=getPopSize(ex);
103
+
104
+
try{
105
+
returncreateStackParser(
106
+
opera10StackParser,
107
+
opera11StackParser,
108
+
chromeStackParser,
109
+
winjsStackParser,
110
+
geckoStackParser,
111
+
)(stacktrace,popSize);
112
+
}catch(e){
113
+
// no-empty
114
+
}
115
+
116
+
return[];
117
+
}
118
+
119
+
// Based on our own mapping pattern - https://github.com/getsentry/sentry/blob/9f08305e09866c8bd6d0c24f5b0aabdd7dd6c59c/src/sentry/lang/javascript/errormapping.py#L83-L108
0 commit comments