Skip to content

Commit

Permalink
Revert "[RUMF-802] add support for capacitor app stack traces (DataDo…
Browse files Browse the repository at this point in the history
…g#685)"

This reverts commit af19314.
  • Loading branch information
kcaffrey authored Jan 29, 2021
1 parent 8f6e3df commit 1a6933e
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 26 deletions.
2 changes: 1 addition & 1 deletion packages/core/src/domain/tracekit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -502,7 +502,7 @@ export const computeStackTrace = (function computeStackTraceWrapper() {
// tslint:disable-next-line max-line-length
const chrome = /^\s*at (.*?) ?\(((?:file|https?|blob|chrome-extension|native|eval|webpack|<anonymous>|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i
// tslint:disable-next-line max-line-length
const gecko = /^\s*(.*?)(?:\((.*?)\))?(?:^|@)((?:file|https?|blob|chrome|webpack|resource|capacitor|\[native).*?|[^@]*bundle)(?::(\d+))?(?::(\d+))?\s*$/i
const gecko = /^\s*(.*?)(?:\((.*?)\))?(?:^|@)((?:file|https?|blob|chrome|webpack|resource|\[native).*?|[^@]*bundle)(?::(\d+))?(?::(\d+))?\s*$/i
// tslint:disable-next-line max-line-length
const winjs = /^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i

Expand Down
20 changes: 0 additions & 20 deletions packages/core/src/domain/tracekitParser.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1151,24 +1151,4 @@ describe('Parser', () => {
url: '[native code]',
})
})

it('should parse iOS capacitor', () => {
const stackFrames = computeStackTrace(CapturedExceptions.IOS_CAPACITOR)

expect(stackFrames.stack.length).toEqual(2)
expect(stackFrames.stack[0]).toEqual({
args: [],
column: 99546,
func: '?',
line: 34,
url: 'capacitor://localhost/media/dist/bundle.js',
})
expect(stackFrames.stack[1]).toEqual({
args: [],
column: 47950,
func: 'r',
line: 34,
url: 'capacitor://localhost/media/dist/bundle.js',
})
})
})
5 changes: 0 additions & 5 deletions packages/core/test/capturedExceptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -440,8 +440,3 @@ value@index.android.bundle:29:2417
value@index.android.bundle:29:927
[native code]`,
}

export const IOS_CAPACITOR = {
stack: `capacitor://localhost/media/dist/bundle.js:34:99546
r@capacitor://localhost/media/dist/bundle.js:34:47950`,
}

0 comments on commit 1a6933e

Please sign in to comment.