MetaMask / MetaMask/metamask-sdk

[Bug]: Async call fails to return to Dapp

Open
#979 14 comments 0 reactions 1 assignee Claimed by @abretonc7s View on GitHub
Bug Triage
Dominant language
TypeScript
Stars
338
Forks
260
PR merge metrics
No merged PRs in 30d

Description

### SDK

Node.js

### Provide environment information

works fine for me in Missouri, Does not work for my tester in St Louis or Poland

### MetaMask SDK Version

0.27.0

### MetaMask Mobile app Version

7.27.1 (1369)

### What browser are you using? (if relevant)

_No response_

### How are you deploying your application? (if relevant)

pure js provided

### Describe the Bug

the first call to approve a spending cap never returns execution back to the calling application.

So the next call to spend the allowance never gets called.

weird thing, when i run this it works. when my tester run this it doesn't return.

if they cancel the allowance/spend cap, execution returns to the app.

### Expected Behavior

user can approve a spending cap, execution returns to my app and the user then approves my bridge to spend and burn the allowance.

### Link to reproduction - Issues with a link to complete (but minimal) reproduction code will be addressed faster

https://github.com/muscleman/web3-tester

### To Reproduce

run tester app.

app invokes the following method.
await tokenContract.methods.approve(this.bridge_address, web3.utils.toWei(1, "ether")).send({ from: tokenWalletAddress })

approve the spending cap in the mobile wallet

never returns execution in the app, no further code is executed.

when i run this locally, all works fine.

now, for me running the script, all works fine.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.