Transactions failed to be sent to mobile device
See original GitHub issueRandomly it seems like when a user is prompted to submit a tx - the tx is never sent to their connected device.
This is hard to replicate as in our dapp it works sometimes, and fails sometimes. Almost like its an internet issue (although its not, as I have a stable fast connection on both devices).
Replication is hard - but I’ve noticed:
If a user directly connects to walletconnect -> accepts in their mobile device -> then uses the dapp to submit a tx it almost never fails.
But when a user has already connected their wallet, and then they refresh the page or come back to it after a day or two, then once connecting again (not via their device just by clicking on walletconnect in web3modal) there is a good chance the transaction will never appear on their device.
I’ve posted in the discord with no real support, but here is the code I’m using for walletconnect and web3modal:
const providerOptions = {
walletconnect: {
package: WalletConnectProvider, // required
options: {
infuraId: "a6xxxxxxxxxxxxxxx1", // required
},
},
fortmatic: {
package: Fortmatic, // required
options: {
key: "FORTMATIC_KEY", // required
},
},
};
const web3Modal = new Web3Modal({
cacheProvider: false, // optional
providerOptions, // required
});
const provider = await web3Modal.connect();
store.dispatch({ type: "WEB3_CONNECTED", data: provider });
this.props.handleCloseWalletModal();
The connection seems fine - in terms of when a user refreshes the page and presses walletconnect again - the web3 connection is on the correct network, and is able to create the instance of contract/estimate gas/present the tx data to web3.
It just fails hits the users device for them to submit, somewhat randomly.
Why would this happen? What aspect of our code/walletconnect would affect this? Is there something we can check/confirm is working that would make the tx fail to be sent to the user after reconnecting from page refresh?
Issue Analytics
- State:
- Created 3 years ago
- Reactions:7
- Comments:19 (2 by maintainers)
Top GitHub Comments
Hello guys,
Any update of this problem ?
I’m able to reproduce it any time even on Uniswap.
It’s a really annoying problem even for the biggest dApps like Uniswap! This should be a priority in your backlog guys !
@VexyCats , @DefiOfThrones , @auuunya are you still experiencing the issue?