Skip to content

Commit 7be78f1

Browse files
committed
Expose set_transaction_name
1 parent 69d65db commit 7be78f1

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

sentry_sdk/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@
4949
"logger",
5050
"start_session",
5151
"end_session",
52+
"set_transaction_name",
5253
]
5354

5455
# Initialize the debug support after everything is loaded

sentry_sdk/api.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ def overload(x):
8484
"monitor",
8585
"start_session",
8686
"end_session",
87+
"set_transaction_name",
8788
]
8889

8990

@@ -466,3 +467,8 @@ def start_session(
466467
def end_session():
467468
# type: () -> None
468469
return get_isolation_scope().end_session()
470+
471+
472+
@scopemethod
473+
def set_transaction_name(name: str, source: Optional[str] = None) -> None:
474+
return get_current_scope().set_transaction_name(name, source)

0 commit comments

Comments
 (0)