Skip to content

(Bug) React key prop error when opening login modal with Solana wallet connectors #135

@rxrxrxrx

Description

@rxrxrxrx

Description

When opening the Privy login modal, a React console error appears in the console about missing unique key props. The warning originates from Privy's internal rendering (minified as yf in the stack trace).

Environment

  • privy-next-starter @privy-io/react-auth version: @privy-io/react-auth@2.25.0
  • React version: 19.1.0
  • Next.js version: 15.5.9
  • Browser: Chrome
  • OS: macOS

Steps to Reproduce

  1. Set up PrivyProvider with Solana wallet connectors:
  import { PrivyProvider } from "@privy-io/react-auth";
  import { toSolanaWalletConnectors } from "@privy-io/react-auth/solana";

  <PrivyProvider
    appId={process.env.NEXT_PUBLIC_PRIVY_APP_ID!}
    clientId={process.env.NEXT_PUBLIC_PRIVY_CLIENT_ID!}
    config={{
      embeddedWallets: {
        ethereum: { createOnLogin: "users-without-wallets" },
        solana: { createOnLogin: "users-without-wallets" },
      },
      appearance: { walletChainType: "ethereum-and-solana" },
      externalWallets: { solana: { connectors: toSolanaWalletConnectors() } },
    }}
  >
    {children}
  </PrivyProvider>
  1. Call login() from usePrivy() hook
  2. Observe console when modal opens

Expected Behavior

No React error in console.

Actual Behavior

Console shows:
Each child in a list should have a unique "key" prop.

Check the render method of div. It was passed a child from yf.

The error points to src/providers/providers.tsx (PrivyProvider), but the actual source is Privy's internal modal rendering (minified code yf).

Impact

  • Severity: Low (non-blocking, modal works correctly)
  • Functionality: Not affected - login modal works fine
  • User experience: No impact, console warning only

Additional Context

This may be related to how toSolanaWalletConnectors() returns an array that gets rendered without proper keys.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions