@@ -27,7 +27,7 @@ const metamaskSendTransaction = async (txn: FakeSignableTx, web3: Web3) => {
27 data: data.toString(),
27 data: data.toString(),
30− nonce: Number(nonce),
30+ nonce: Number(nonce).toString(),
31 to: to.toString(),
31 to: to.toString(),
32 from: toHex(from),
32 from: toHex(from),
@@ -48,6 +48,12 @@ const metamaskSendTransaction = async (txn: FakeSignableTx, web3: Web3) => {
48 // signed tx, it makes us wait for confirmation outside of our own
48 // signed tx, it makes us wait for confirmation outside of our own
49 // waitForTransactionConfirm. because of this the progress bar loses
49 // waitForTransactionConfirm. because of this the progress bar loses
50 // its progressiveness for metamask users.
50 // its progressiveness for metamask users.
52+ // Per the web3 lib's Typescript declarations, sendTransaction
53+ // expects a Transaction nonce of type number to be passed in.
54+ // However, at runtime, Metamask throws an error indicating that
55+ // nonce should be a string.
51 let receipt = await web3.eth.sendTransaction(metamaskFormattedTxn);
57 let receipt = await web3.eth.sendTransaction(metamaskFormattedTxn);
52 txHash = receipt.transactionHash;
58 txHash = receipt.transactionHash;