Skip to content

Commit 7911570

Browse files
committed
Make scrubber initialization more explicit
1 parent d9b3879 commit 7911570

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

sentry_sdk/client.py

+5-1
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,11 @@ def _get_options(*args, **kwargs):
128128
rv["traces_sample_rate"] = 1.0
129129

130130
if rv["event_scrubber"] is None:
131-
rv["event_scrubber"] = EventScrubber(send_default_pii=rv["send_default_pii"])
131+
rv["event_scrubber"] = EventScrubber(
132+
send_default_pii=(
133+
False if rv["send_default_pii"] is None else rv["send_default_pii"]
134+
)
135+
)
132136

133137
if rv["socket_options"] and not isinstance(rv["socket_options"], list):
134138
logger.warning(

tests/test_scope.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -811,7 +811,7 @@ def test_should_send_default_pii_false(sentry_init):
811811
assert should_send_default_pii() is False
812812

813813

814-
def test_should_send_default_pii_default_fals(sentry_init):
814+
def test_should_send_default_pii_default_false(sentry_init):
815815
sentry_init()
816816

817817
assert should_send_default_pii() is False

0 commit comments

Comments
 (0)