-
Notifications
You must be signed in to change notification settings - Fork 17
Open
Description
Description
When users have multiple wallet extensions installed (e.g., MetaMask + Trust Wallet + Phantom), wallet connection can fail or connect to the wrong wallet due to provider conflicts.
Current Behavior
- Multiple wallets inject into
window.ethereum - Some wallets (like Trust Wallet) set
isMetaMask: trueeven though they're not MetaMask - Users selecting MetaMask may inadvertently connect to Trust Wallet
- Connection attempts may fail with unclear error messages
Expected Behavior
- Each wallet should be correctly identified and isolated
- Selecting a specific wallet should always connect to that wallet
- Clear error messages when wallet conflicts occur
Related Issues
- [Bug] Connection Refused: Security risk detected when connecting Brave Wallet to GenLayer Points #408 - Security risk with Brave Wallet
- Cant connect metamask #412, Not able to connect Metamask wallet #415, Wallet connection issue #420 - MetaMask connection issues
- Phantom wallet #440, Phantom wallet does not work #441 - Phantom wallet issues
Current Mitigation
The WalletSelector.svelte component already implements:
- EIP-6963 provider detection
- Specific provider checks (
isPhantom,isTrust,_metamask) - Conflict detection with user confirmation dialog
Suggested Improvements
- Improve EIP-6963 adoption: Prioritize wallets that announce via EIP-6963
- Better error messages: Show which wallet is causing conflicts
- Wallet priority settings: Let users set preferred wallet order
- Connection retry logic: Implement automatic retry with exponential backoff
Environment
- Frontend: Svelte 5 with wagmi
- Wallet detection: EIP-6963 + legacy window.ethereum
Code Location
frontend/src/components/WalletSelector.svelte
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels