Skip to content

fix(conversations): improve truncation of non-UUID conversation IDs#115978

Merged
obostjancic merged 2 commits into
masterfrom
fix/conversation-id-truncation
May 21, 2026
Merged

fix(conversations): improve truncation of non-UUID conversation IDs#115978
obostjancic merged 2 commits into
masterfrom
fix/conversation-id-truncation

Conversation

@sentry-junior
Copy link
Copy Markdown
Contributor

@sentry-junior sentry-junior Bot commented May 21, 2026

Summary

The conversation detail heading and breadcrumb were hard-truncating conversation IDs to 8 characters via .slice(0, 8). This works for UUIDs (showing a1b2c3d4) but produces nonsensical results for structured IDs like slack:C0B595QDZLL:1779310456.221179slack:C0.

Changes

Heading (conversationSummary.tsx):

  • Uses CSS text-overflow: ellipsis with a Tooltip (showOnlyOnOverflow) that reveals the full ID on hover
  • Keeps .slice(0, 8) only for UUID-shaped IDs

Breadcrumb (layout.tsx):

  • Same isUUID check; non-UUID labels pass the full ID with a wrapping Tooltip
  • Relies on the Breadcrumbs component's existing maxWidth / ellipsis handling for visual truncation

This matches the pattern already used in the conversations table for non-UUID IDs.

Evidence

Reported via this conversation where the ID slack:C0B595QDZLL:1779310456.221179 was rendered as slack:C0 in both the heading and breadcrumb.

Verification

  • Type-checked (tsc --noEmit) — no errors on changed files
  • Could not run Jest in sandbox (no node_modules); existing tests should pass unchanged since the rendering logic only differs for non-UUID inputs

The conversation detail heading and breadcrumb were hard-truncating
conversation IDs to 8 characters via .slice(0, 8). This works fine for
UUIDs (e.g. showing 'a1b2c3d4') but produces nonsensical results for
structured IDs like 'slack:C0B595QDZLL:1779310456.221179' → 'slack:C0'.

Changes:
- Heading: use CSS text-overflow ellipsis with a Tooltip that shows the
  full ID on hover (showOnlyOnOverflow), keeping .slice(0, 8) only for
  UUID-shaped IDs
- Breadcrumb: same isUUID check; non-UUID labels show the full ID with
  a Tooltip, relying on the Breadcrumbs component's existing maxWidth
  and ellipsis handling for visual truncation

This matches the pattern already used in the conversations table.
@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label May 21, 2026
@dcramer dcramer marked this pull request as ready for review May 21, 2026 03:31
@dcramer dcramer requested a review from a team as a code owner May 21, 2026 03:31
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 21, 2026

📊 Type Coverage Diff

✅ No new type safety issues introduced. Coverage: 93.59%

@dcramer dcramer added the Trigger: getsentry tests Once code is reviewed: apply label to PR to trigger getsentry tests label May 21, 2026
Copy link
Copy Markdown
Contributor

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 3f580fb. Configure here.

Comment thread static/app/views/explore/conversations/components/conversationSummary.tsx Outdated
Address cursor bot feedback: Heading from @sentry/scraps/text already
supports an ellipsis prop that handles overflow/text-overflow/nowrap.
Remove the ConversationHeading styled component and use the native prop
directly, keeping only min-width/flex-shrink via the style prop for
flex-item sizing.
@github-actions github-actions Bot removed the Trigger: getsentry tests Once code is reviewed: apply label to PR to trigger getsentry tests label May 21, 2026
@dcramer dcramer added the Trigger: getsentry tests Once code is reviewed: apply label to PR to trigger getsentry tests label May 21, 2026
@obostjancic obostjancic merged commit f4b94a9 into master May 21, 2026
85 of 86 checks passed
@obostjancic obostjancic deleted the fix/conversation-id-truncation branch May 21, 2026 08:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components Trigger: getsentry tests Once code is reviewed: apply label to PR to trigger getsentry tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants