Connection declined. Connection can be declined if a previous request is still active #4310
Replies: 5 comments 5 replies
This comment was marked as spam.
This comment was marked as spam.
-
Hi, please share a minimal reproducible example and steps to reproduce the issue. Thanks! |
Beta Was this translation helpful? Give feedback.
-
This works in a dApp browser like metamask or trustwallet. If you also put it in a browser where an extension is installed, it also works. |
Beta Was this translation helpful? Give feedback.
-
Same issue... |
Beta Was this translation helpful? Give feedback.
-
The whole problem is in the dashboard https://cloud.reown.com/ you have to verify the project domain through settings and then everything will work. Every application key in reown.com cabinet should be for verified domains. This didn't used to happen when wallectconnect.... |
Beta Was this translation helpful? Give feedback.
-
This is my first time working with Web3Modal and I'm using react. I'm running into a kind of bug. When Itry to connect from a mobile browser or a browser that doesn't have an extension installed, i get the error Connection declined. Connection can be declined if a previous request is still active.
My Context provider code looks like this:
`import { createWeb3Modal } from '@web3modal/wagmi/react'
import { defaultWagmiConfig } from '@web3modal/wagmi/react/config'
import { injected, metaMask, safe, walletConnect } from 'wagmi/connectors'
import { WagmiProvider } from 'wagmi'
import { arbitrum, mainnet } from 'wagmi/chains'
import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
// 0. Setup queryClient
const queryClient = new QueryClient()
// 1. Get projectId at https://cloud.walletconnect.com
const projectId = 'MY_PROJECT_ID'
// 2. Create wagmiConfig
const metadata = {
name: 'Web3Modal',
description: 'Web3Modal Example',
url: 'http://localhost:5173', // origin must match your domain & subdomain
icons: ['https://avatars.githubusercontent.com/u/37784886']
}
const chains = [mainnet, arbitrum]
const config = defaultWagmiConfig({
chains, // required
projectId, // required
metadata, // required
})
// 3. Create modal
createWeb3Modal({
wagmiConfig: config,
projectId,
enableAnalytics: true // Optional - defaults to your Cloud configuration
})
export function ContextProvider({ children }) {
return (
{children}
)
}`
I basically followed the doc on installation and I dont know why this is happening.
My button is in my app folder and yes, i wrapped my App in ContextProvider.
Beta Was this translation helpful? Give feedback.
All reactions