Skip to content

Copy-to-clipboard button on 'no model selected' page does not work #115

@jezekra1

Description

@jezekra1

Pre-requisities

  • I am using the newest version of the platform

Describe the bug

The copy button next to the kagenti-adk model setup command on the "no model selected" error page does not copy the command to the clipboard. Clicking the button appears to do nothing — the text is not available for pasting afterward.

The root cause is likely that navigator.clipboard.writeText() in CopyButton is called without awaiting the returned Promise and without error handling, so failures are silently swallowed. The Clipboard API also requires a secure context (HTTPS or localhost), which may not be available in all deployment scenarios.

To Reproduce

  1. Launch the UI without a model configured
  2. Observe the "no model selected" error page with the kagenti-adk model setup snippet
  3. Click the copy button next to the command
  4. Try to paste — nothing was copied

Expected behavior

Clicking the copy button should copy the command text to the clipboard, or show an error/fallback if clipboard access is unavailable.

Logs / Screenshots / Code snippets

Relevant components:

  • apps/adk-ui/src/components/CopyButton/CopyButton.tsx
  • apps/adk-ui/src/components/CopySnippet/CopySnippet.tsx
  • apps/adk-ui/src/modules/runs/components/NoModelSelectedErrorPage.tsx

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions