Skip to content

feat: copy session path#5569

Open
replicas-connector[bot] wants to merge 2 commits intomainfrom
ENG-3869
Open

feat: copy session path#5569
replicas-connector[bot] wants to merge 2 commits intomainfrom
ENG-3869

Conversation

@replicas-connector
Copy link
Contributor

Ticket

ENG-3869

Component/Service

What part of Helicone does this affect?

  • Web (Frontend)
  • Jawn (Backend)
  • Worker (Proxy)
  • Bifrost (Marketing)
  • AI Gateway
  • Packages
  • Infrastructure/Docker
  • Documentation

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Documentation update
  • Performance improvement
  • Refactoring

Deployment Notes

  • No special deployment steps required
  • Database migrations need to run
  • Environment variable changes required
  • Coordination with other teams needed

Screenshots / Demos

Before After
No copy path button on session trace rows Copy icon appears on hover in the path column, clicking copies the full trace path to clipboard

Extra Notes

  • The copy button uses the existing useNotification hook for clipboard feedback, consistent with other copy actions in the codebase (e.g., session ID copy in breadCrumb.tsx)
  • Uses CopyIcon from lucide-react, same icon used elsewhere
  • Button is hidden by default and appears on row hover via group-hover:opacity-100 (the <tr> already has the group class)
  • Copies the completePath property (e.g., /agent/step1/llm_call) which represents the full hierarchical trace path
  • e.stopPropagation() prevents row selection when clicking the copy button

Context

Users need a quick way to copy the trace path from session detail views. This adds a small copy icon button that appears on hover in the path column of the session timeline table, allowing one-click copy of the complete trace path to the clipboard.

Replicas workspace

Adds a copy-to-clipboard button for the trace path in the session
timeline table. The button appears on row hover in the path column
and copies the complete trace path (e.g. /agent/step1/llm_call).

Co-Authored-By: Hammad Shami <H2Shami@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@vercel
Copy link

vercel bot commented Feb 16, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
helicone Ready Ready Preview, Comment Feb 20, 2026 11:08pm
helicone-eu Ready Ready Preview, Comment Feb 20, 2026 11:08pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
helicone-bifrost Skipped Skipped Feb 20, 2026 11:08pm

Request Review

@supabase
Copy link

supabase bot commented Feb 16, 2026

This pull request has been ignored for the connected project bolqqmqbrciybnypvklh because there are no changes detected in supbase/supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@supabase
Copy link

supabase bot commented Feb 16, 2026

This pull request has been ignored for the connected project lmahfbbnchpworytrrqk because there are no changes detected in .supabase/supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.

@claude
Copy link
Contributor

claude bot commented Feb 16, 2026

Claude finished @replicas-connector[bot]'s task —— View job


Code Review Complete ✅

Score: 8/10 - Well-implemented feature with good design system adherence and user experience. Minor suggestions for improvement.

Detailed Analysis

Strengths

  1. Excellent Design System Compliance

    • Uses CopyIcon from lucide-react with consistent size={14} prop (line 534 in SessionTimelineTable.tsx)
    • Follows established color system with semantic classes (text-muted-foreground, hover:text-primary)
    • Uses proper Button component with variant="ghost" and size="icon"
    • Consistent with existing copy patterns in the codebase
  2. Good UX Implementation

    • Hidden by default with opacity-0 and shows on hover via group-hover:opacity-100
    • Proper e.stopPropagation() prevents row selection when clicking copy button
    • Uses existing useNotification hook for consistent clipboard feedback
    • Copies the meaningful completePath property rather than just raw path
  3. Smart Tooltip → Popover Fix

    • Correctly identified that Radix Tooltips dismiss on cursor movement, making buttons unusable
    • Proper migration to Popover with controlled open state
    • Good accessibility improvement using button instead of div for PopoverTrigger

🔧 Minor Issues & Suggestions

  1. Icon Sizing Inconsistency (SessionTimelineTable.tsx:534)

    // Current: Mixed sizing approach
    <CopyIcon className="h-3 w-3" />
    
    // Recommended: Use size prop consistently
    <CopyIcon size={12} />

    While functional, the codebase guidelines recommend using the size prop for lucide-react icons.

  2. Accessibility Enhancement (SessionTimelineTable.tsx:518-536)

    // Current implementation is good, but could add aria-label
    <Button
      variant="ghost"
      size="icon"
      className="ml-auto h-6 w-6 shrink-0 opacity-0 transition-opacity group-hover:opacity-100"
      onClick={...}
     
      // Add this
    >
  3. Conditional Rendering Check (SessionTimelineTable.tsx:516-517)

    // Current condition could be more explicit
    {cell.column.id === "path" && row.original.completePath && (
    
    // Consider adding type safety
    {cell.column.id === "path" && row.original.completePath?.trim() && (

🚀 Performance & Security

  • ✅ No security concerns - uses standard navigator.clipboard.writeText()
  • ✅ Good performance - button only renders when needed
  • ✅ No memory leaks - proper event handling with stopPropagation()
  • ✅ Proper error handling via notification system

📐 Code Quality

  • ✅ Clean, readable implementation
  • ✅ Follows existing patterns in the codebase
  • ✅ Proper TypeScript usage
  • ✅ Good separation of concerns

Suggestions Summary:

  1. Use size prop instead of className for icon sizing - Minor consistency improvement
  2. Add aria-label for better accessibility - Enhancement for screen readers
  3. Add string trim check for completePath - Minor defensive programming improvement

Critical Issues: None found

This is a well-executed feature that follows the project's design system guidelines and provides good user experience. The implementation is clean, secure, and maintainable. The Popover fix demonstrates good understanding of UI component behavior.


@H2Shami
Copy link
Collaborator

H2Shami commented Feb 20, 2026

@tryreplicas this didn't make the change on the sessions page's request drawer. theres an option to copy the id or view

neither work still. try again

The RequestDescTooltip component was using a Radix UI Tooltip to display
interactive "Copy ID" and "View" buttons. Radix tooltips dismiss when
the cursor moves away from the trigger, making it impossible to click
the buttons inside. This converts it to a Popover which stays open and
supports interactive content. The popover closes after clicking an action.

Co-Authored-By: Hammad Shami <H2Shami@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@vercel vercel bot temporarily deployed to Preview – helicone-bifrost February 20, 2026 23:05 Inactive
@replicas-connector
Copy link
Contributor Author

@tryreplicas this didn't make the change on the sessions page's request drawer. theres an option to copy the id or view

neither work still. try again

@H2Shami Fixed! The issue was that the RequestDescTooltip component in the request drawer was using a Radix UI Tooltip to display interactive "Copy ID" and "View" buttons. Radix tooltips are designed for non-interactive content — they dismiss as soon as the cursor moves away from the trigger, making it impossible to actually click the buttons inside.

I've converted it to use a Popover instead, which stays open and properly supports clicking the interactive "Copy ID" and "View" actions. The popover also closes automatically after an action is taken.

Changes in bf3d10eaa:

  • Replaced Tooltip/TooltipContent/TooltipProvider/TooltipTrigger with Popover/PopoverContent/PopoverTrigger in RequestDescTooltip
  • Added controlled open state so the popover closes after clicking "Copy ID" or "View"
  • Changed trigger from div to button for proper accessibility with Popover

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