WalletConnect / web3modal

A single Web3 provider solution for all Wallets

Home Page:https://web3modal.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[bug] Connection declined when using the wagmi Safe connector

paintoshi opened this issue · comments

Link to minimal reproducible example

https://github.com/paintoshi/web3modal-next-test

Summary

The safe connector from wagmi/connectors always saying "Connection declined, Connection can be declined if a previous request is still active". Tested on mobile too, served from a validated wallet connect domain and with the Safe mobile app installed, but it says the same thing. I would expect it to use the Safe wallet just as it uses Metamask.

image
image

I made a minimal next.js app where you can click connect, then Safe to see the issue. Just have to yarn install and yarn dev to run it.

I also modified your stackblitz demo, using the exact same web3modal/wagmi config and library versions, but getting a different modal, see below. https://stackblitz.com/edit/web3modal-next-template-qwflf1?file=config%2Findex.tsx

image

I can't see any differences in the code, so I'm not sure why it works differently in stackblitz. But downloading the stackblitz project and running it locally (or on a server) will result in the same problem anyway.
Appreciate any help to track this down.

List of related npm package versions

Node v20.12.2
"next": "14.2.2",
"react": "18.2.0",
"@web3modal/wagmi": "^4.1.11"
"viem": "^2.9.25"
"wagmi": "^2.5.20"

commented

I could not reproduce this issue. please re-open if it remains a problem