File tree 1 file changed +5
-0
lines changed
1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -167,6 +167,7 @@ def transaction(self, value):
167
167
"""When set this forces a specific transaction name to be set.
168
168
169
169
Deprecated: use set_transaction_name instead."""
170
+
170
171
# XXX: the docstring above is misleading. The implementation of
171
172
# apply_to_event prefers an existing value of event.transaction over
172
173
# anything set in the scope.
@@ -176,6 +177,10 @@ def transaction(self, value):
176
177
# Without breaking version compatibility, we could make the setter set a
177
178
# transaction name or transaction (self._span) depending on the type of
178
179
# the value argument.
180
+
181
+ logger .warning (
182
+ "Assigning to scope.transaction directly is deprecated: use scope.set_transaction_name() instead."
183
+ )
179
184
self ._transaction = value
180
185
if self ._span and self ._span .containing_transaction :
181
186
self ._span .containing_transaction .name = value
You can’t perform that action at this time.
0 commit comments