Skip to content

feat(pyramid): Gate user info behind data_collection config#6873

Open
ericapisani wants to merge 1 commit into
py-2583-tornadofrom
py-2583-pyramid
Open

feat(pyramid): Gate user info behind data_collection config#6873
ericapisani wants to merge 1 commit into
py-2583-tornadofrom
py-2583-pyramid

Conversation

@ericapisani

@ericapisani ericapisani commented Jul 23, 2026

Copy link
Copy Markdown
Member

Apply the data_collection.user_info setting to the Pyramid integration's user id collection, giving it precedence over the legacy send_default_pii boolean when explicitly configured. This covers both the user.id segment attribute under span streaming and the user id attached to error events, mirroring the behavior already shipped for Flask, WSGI, ASGI, Django, Sanic, and Tornado.

The user id segment test is reparametrized with the shared DATA_COLLECTION_USER_INFO_CASES matrix from tests/integrations/utils.py, and a new test adds the first coverage of the user id on error events.

Refs PY-2583
Refs #6746

@linear-code

linear-code Bot commented Jul 23, 2026

Copy link
Copy Markdown

PY-2583

@github-actions

github-actions Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Codecov Results 📊

96668 passed | ⏭️ 6410 skipped | Total: 103078 | Pass Rate: 93.78% | Execution Time: 340m 10s

📊 Comparison with Base Branch

Metric Change
Total Tests 📈 +808
Passed Tests 📈 +738
Failed Tests
Skipped Tests 📈 +70

All tests are passing successfully.

✅ Patch coverage is 100.00%. Project has 2521 uncovered lines.
❌ Project coverage is 89.66%. Comparing base (base) to head (head).

Files with missing lines (1)
File Patch % Lines
sentry_sdk/integrations/pyramid.py 100.00% ⚠️ 2 partials
Coverage diff
@@            Coverage Diff             @@
##          main       #PR       +/-##
==========================================
- Coverage    89.68%    89.66%    -0.02%
==========================================
  Files          193       193         —
  Lines        24321     24371       +50
  Branches      8572      8624       +52
==========================================
+ Hits         21809     21850       +41
- Misses        2512      2521        +9
- Partials      1397      1399        +2

Generated by Codecov Action

@ericapisani
ericapisani marked this pull request as ready for review July 23, 2026 18:10
@ericapisani
ericapisani requested a review from a team as a code owner July 23, 2026 18:10
Apply the data_collection.user_info setting to the Pyramid integration's user id collection, giving it precedence over the legacy send_default_pii boolean when explicitly configured. This covers both the user.id segment attribute under span streaming and the user id attached to error events, mirroring the behavior already shipped for Flask, WSGI, ASGI, Django, Sanic, and Tornado.

The user id segment test is reparametrized with the shared DATA_COLLECTION_USER_INFO_CASES matrix from tests/integrations/utils.py, and a new test adds the first coverage of the user id on error events.

Refs PY-2583
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant