Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pending transaction from a side chain was executed on the mainnet #5762

Closed
joaoaguiam opened this issue Nov 15, 2018 · 18 comments
Closed

Pending transaction from a side chain was executed on the mainnet #5762

joaoaguiam opened this issue Nov 15, 2018 · 18 comments

Comments

@joaoaguiam
Copy link

Describe the bug
I was using the xDAI POA side chain and my transaction was pending for several days. After changing to the mainnet and launch a new transaction, my previous side chain transaction was executed.

To Reproduce
Not sure I am able to reproduce it again.
I was using xdai.io burner wallet, which uses the xDAI POA sidechain. Somehow the transaction was not going through and stays in the pending state on my wallet. When moving to the mainnet, the pending transaction was still there.
I then executed a new transaction on the mainnet, and suddenly my pending transactions from the side chain were executed. Therefore some ethers went to a unknown address and got lost forever!

Expected behavior
Transactions from private RPCs should not be mixed in the list of transactions on the mainnet

Screenshots
screen shot 2018-11-14 at 23 28 17

Tx link: https://etherscan.io/tx/0x20d1787d23ff345b64314559294f03f06e2f8d23e79037709d3ab7778959939c

Browser details (please complete the following information):

  • OS: OS X
  • Browser: Chrome
  • MetaMask Version: 5.0.2
@riusricardo
Copy link

riusricardo commented Nov 20, 2018

I experienced the exact same issue using xDAI POA side chain with a custom RPC on https://dai.poa.network. xDai pending transactions resolved on the Ethereum main net when I changed the Metamask selector to main net.
The transactions should not be sent if I change my RPC.

OS: Linux Ubuntu 16.04
Browser: Chrome
Metamask Version: 5.0.2

@danfinlay
Copy link
Contributor

Hi all, sorry for the slow reply. If you're able to reproduce this, please contact us at [email protected] so we can get some logs to help us diagnose how this could happen.

@joaoaguiam
Copy link
Author

Hi @danfinlay , this issue just happened to me again, I had a transaction that was rejected or pending (not sure which state) on the xDai POA side chain, and when I moved to the Mainnet and executed another transaction, the one from the POA side chain was executed on the mainnet.
The failed transaction didn't have much value luckily, otherwise, it would have been lost.

Here is the transaction on the mainnet: https://etherscan.io/tx/0xec77021ae69a93cc4f6a72bfaa6f90d98f35b0c813aa5733f160379b3d9c3a3d

Metamask version: 5.3.1

Feel free to contact me on telegram at @joaoaguiam to help you debugging.

@riusricardo
Copy link

riusricardo commented Jan 28, 2019

I think that the issue is still there. @joaoaguiam next time, you should try by sending the pending transaction into a test net. I haven't tried to use an xDai advanced custom RPC. But my guess is that if we create a new custom RPC with network id under advance preferences, the issue will probably be mitigated.
I think that it keeps pending because of the transaction gas. We need to get deeper into this issue, and create some replication steps.

A related issue was reported in the burner-wallet repo: austintgriffith/burner-wallet#82

@joaoaguiam as far as I can see, you where playing with the Burner token.
https://blockscout.com/poa/dai/tokens/0xdec31651bec1fbbff392aa7de956d6ee4559498b/token_transfers
https://blockscout.com/poa/dai/address/0xdec31651bec1fbbff392aa7de956d6ee4559498b/transactions

@frankiebee
Copy link
Contributor

frankiebee commented Jan 28, 2019

it's possible if the xDAI POA has the same netID and chainID as ethereum main net it is possible for the pending tx to be submitted to the ethereum main net. do you have a url enpoint i could use for xDAI POA chain?

@frankiebee
Copy link
Contributor

^ @joaoaguiam

@frankiebee
Copy link
Contributor

oh scratch that found one

@riusricardo
Copy link

riusricardo commented Jan 28, 2019

Ethereum mainnet -> 1
https://dai.poa.network -> 100
https://core.poa.network -> 99
https://sokol.poa.network -> 77

I don't think it is the case. xDai is 100.

@frankiebee
Copy link
Contributor

yeah just confirmed that

@frankiebee
Copy link
Contributor

might be related to #5956

@joaoaguiam
Copy link
Author

@riusricardo Yes I was playing with the Burner Wallet and Burn token.

I didn't set the chain id when I added the xDai RPC. Do you think if this is set to 100 there should be no issue?

Next time it fails I will move to the test net then. Thanks!

@rstormsf
Copy link

rstormsf commented Jan 29, 2019

@joaoaguiam just make sure you don't have more than 1 custom rpc in your list. Remove all RPCs and only use one Custom RPC in metamask for now.

@danfinlay
Copy link
Contributor

Remove all RPCs and only use one Custom RPC in metamask for now.

If that's a user-side workaround, we should just make add custom rpc overwrite any existing rpc, to do the same programmatically. @frankiebee

@joaoaguiam
Copy link
Author

I have two custom rpc indeed, but just allow one rpc is very limiting in my opinion.

screen shot 2019-01-29 at 18 30 51

@rstormsf
Copy link

@joaoaguiam
Hopefully this PR fixes this issue
#6044
Please let us know

@frankiebee
Copy link
Contributor

Remove all RPCs and only use one Custom RPC in metamask for now.

@joaoaguiam @danfinlay that is not an effective workaround; best to just put the chain Id in settings when you use the rpc till the new update has reached all users

the update will not be able to fix miss-assigned chainID's so you will still need to reenter them on the new update if they have a cached value that is incorrect.

@danfinlay
Copy link
Contributor

This should be fixed in v5.3.4, let us know if not!

@joaoaguiam
Copy link
Author

Thanks for the fix 👍

If I fall on the same problem I will let you know here!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants