File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -474,12 +474,13 @@ def _prepare_event(
474474 scope , # type: Optional[Scope]
475475 ):
476476 # type: (...) -> Optional[Event]
477+ is_transaction = event .get ("type" ) == "transaction"
478+ is_checkin = event .get ("type" ) == "check_in"
477479
478480 if event .get ("timestamp" ) is None :
479481 event ["timestamp" ] = datetime .now (timezone .utc )
480482
481483 if scope is not None :
482- is_transaction = event .get ("type" ) == "transaction"
483484 spans_before = len (event .get ("spans" , []))
484485 event_ = scope .apply_to_event (event , hint , self .options )
485486
@@ -541,6 +542,11 @@ def _prepare_event(
541542 if event .get ("platform" ) is None :
542543 event ["platform" ] = "python"
543544
545+ if not is_transaction and not is_checkin :
546+ event .setdefault ("debug_meta" , {}).update (
547+ {"project_root" : self .options ["project_root" ]}
548+ )
549+
544550 event = handle_in_app (
545551 event ,
546552 self .options ["in_app_exclude" ],
You can’t perform that action at this time.
0 commit comments