File tree Expand file tree Collapse file tree 1 file changed +9
-7
lines changed Expand file tree Collapse file tree 1 file changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -334,20 +334,22 @@ def _send_message_to_server(
334
334
"line" : frames [0 ]["line" ],
335
335
"column" : frames [0 ]["column" ],
336
336
}
337
- if len ( frames ) > 0
337
+ if frames
338
338
else None
339
339
)
340
+ metadata = {
341
+ "wallTime" : int (datetime .datetime .now ().timestamp () * 1000 ),
342
+ "apiName" : stack_trace_information ["apiName" ],
343
+ "internal" : not stack_trace_information ["apiName" ],
344
+ }
345
+ if location :
346
+ metadata ["location" ] = location # type: ignore
340
347
message = {
341
348
"id" : id ,
342
349
"guid" : object ._guid ,
343
350
"method" : method ,
344
351
"params" : self ._replace_channels_with_guids (params ),
345
- "metadata" : {
346
- "wallTime" : int (datetime .datetime .now ().timestamp () * 1000 ),
347
- "apiName" : stack_trace_information ["apiName" ],
348
- "location" : location ,
349
- "internal" : not stack_trace_information ["apiName" ],
350
- },
352
+ "metadata" : metadata ,
351
353
}
352
354
if self ._tracing_count > 0 and frames and object ._guid != "localUtils" :
353
355
self .local_utils .add_stack_to_tracing_no_reply (id , frames )
You can’t perform that action at this time.
0 commit comments