From 61bf095c2ba86c24411cbbb13e9411df52cd65e2 Mon Sep 17 00:00:00 2001 From: Dominik Buszowiecki Date: Wed, 8 Apr 2026 17:14:53 -0400 Subject: [PATCH] fix(slack): Cast user id to string in set_user call sentry_sdk.set_user expects a string for the id field. Passing an int could prevent user.id from being indexed correctly in EAP spans. Co-Authored-By: Claude Opus 4.6 --- src/sentry/integrations/slack/webhooks/event.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sentry/integrations/slack/webhooks/event.py b/src/sentry/integrations/slack/webhooks/event.py index 51450d9d8249f0..d43eaf046bc2d3 100644 --- a/src/sentry/integrations/slack/webhooks/event.py +++ b/src/sentry/integrations/slack/webhooks/event.py @@ -281,7 +281,7 @@ def on_link_shared(self, request: Request, slack_request: SlackDMRequest) -> boo if identity_user: sentry_sdk.set_user( { - "id": identity_user.id, + "id": str(identity_user.id), "email": identity_user.email, "username": identity_user.username, }