File tree Expand file tree Collapse file tree 2 files changed +21
-14
lines changed Expand file tree Collapse file tree 2 files changed +21
-14
lines changed Original file line number Diff line number Diff line change @@ -42,47 +42,47 @@ snapshot[`captureException 1`] = `
42
42
stacktrace: {
43
43
frames: [
44
44
{
45
- colno: 20 ,
45
+ colno: " {{colno}} " ,
46
46
filename: " ext:cli/40_testing.js" ,
47
47
function: " outerWrapped" ,
48
48
in_app: false ,
49
- lineno: 472 ,
49
+ lineno: " {{lineno}} " ,
50
50
},
51
51
{
52
- colno: 33 ,
52
+ colno: " {{colno}} " ,
53
53
filename: " ext:cli/40_testing.js" ,
54
54
function: " exitSanitizer" ,
55
55
in_app: false ,
56
- lineno: 458 ,
56
+ lineno: " {{lineno}} " ,
57
57
},
58
58
{
59
- colno: 31 ,
59
+ colno: " {{colno}} " ,
60
60
filename: " ext:cli/40_testing.js" ,
61
61
function: " resourceSanitizer" ,
62
62
in_app: false ,
63
- lineno: 410 ,
63
+ lineno: " {{lineno}} " ,
64
64
},
65
65
{
66
- colno: 33 ,
66
+ colno: " {{colno}} " ,
67
67
filename: " ext:cli/40_testing.js" ,
68
68
function: " asyncOpSanitizer" ,
69
69
in_app: false ,
70
- lineno: 177 ,
70
+ lineno: " {{lineno}} " ,
71
71
},
72
72
{
73
- colno: 11 ,
73
+ colno: " {{colno}} " ,
74
74
filename: " ext:cli/40_testing.js" ,
75
75
function: " innerWrapped" ,
76
76
in_app: false ,
77
- lineno: 526 ,
77
+ lineno: " {{lineno}} " ,
78
78
},
79
79
{
80
- colno: 27 ,
80
+ colno: " {{colno}} " ,
81
81
context_line: " client.captureException(something());" ,
82
82
filename: " app:///test/mod.test.ts" ,
83
83
function: " <anonymous>" ,
84
84
in_app: true ,
85
- lineno: 47 ,
85
+ lineno: " {{lineno}} " ,
86
86
post_context: [
87
87
" " ,
88
88
" await delay(200);" ,
@@ -103,12 +103,12 @@ snapshot[`captureException 1`] = `
103
103
],
104
104
},
105
105
{
106
- colno: 12 ,
106
+ colno: " {{colno}} " ,
107
107
context_line: " return new Error('Some unhandled error');" ,
108
108
filename: " app:///test/mod.test.ts" ,
109
109
function: " something" ,
110
110
in_app: true ,
111
- lineno: 44 ,
111
+ lineno: " {{lineno}} " ,
112
112
post_context: [
113
113
" }" ,
114
114
" " ,
Original file line number Diff line number Diff line change @@ -156,6 +156,13 @@ function normalizeEvent(event: sentryTypes.Event): sentryTypes.Event {
156
156
event . exception . values [ 0 ] . stacktrace . frames = event . exception . values [ 0 ] . stacktrace . frames . filter (
157
157
frame => ! frame . filename ?. includes ( 'deno:' ) ,
158
158
) ;
159
+
160
+ // @ts -expect-error - we're setting a string as lineno/colno for normalization
161
+ event . exception . values [ 0 ] . stacktrace . frames = event . exception . values [ 0 ] . stacktrace . frames . map ( frame => ( {
162
+ ...frame ,
163
+ lineno : '{{lineno}}' ,
164
+ colno : '{{colno}}' ,
165
+ } ) ) ;
159
166
}
160
167
161
168
event . timestamp = 0 ;
You can’t perform that action at this time.
0 commit comments