Skip to content
This repository has been archived by the owner on Apr 15, 2019. It is now read-only.

Sent two transactions when only one transaction was actioned #1036

Closed
jfernanz opened this issue Jan 26, 2018 · 2 comments
Closed

Sent two transactions when only one transaction was actioned #1036

jfernanz opened this issue Jan 26, 2018 · 2 comments
Labels

Comments

@jfernanz
Copy link

jfernanz commented Jan 26, 2018

Hey Vit, check this bug out it's really important. It sent out two transactions with 5,000 LSK each instead of sending only one transaction. Luckily, I sent it over to my Bittrex account so there was no harm done but it can be critical if sending P2P. I would advise to lock Nano down until this is figured out.

Expected behaviour

I expect to send one transaction after typing my first and second passphrase and clicking SEND.

Actual behaviour

Entered my first and second passphrase and clicked SEND. Two transactions were sent instead of one.
Transaction # 1: https://explorer.lisk.io/tx/6912361628873457132
Transaction # 2: https://explorer.lisk.io/tx/8919049967530319582

Notice that the transactions are made within one second. I don't do sequential transactions that fast using Lisk Nano since I double check LSK addresses everytime I'm sending a transaction.

Steps to reproduce

I just upgraded to the new version and did my normal routine of making sure the LSK address was correct and writing my first and second passphrase and then clicking SEND.

Specs:
Lisk Nano Version 1.3.3
macOS High Sierra Version 10.13.2

@slaweet slaweet added the bug label Jan 26, 2018
@slaweet
Copy link
Contributor

slaweet commented Jan 26, 2018

Hi Joel,
thank you for reporting this.
I couldn't reproduce it, so it is most likely a very rarely occurring bug and not related to 1.3.3. But still, it is critical, so we will investigate it more and publish a fix as soon as possible.

@karmacoma karmacoma changed the title **CRITICAL BUG** Duplicate Transaction Sent two transactions when only one transactions was actioned Jan 26, 2018
@karmacoma karmacoma changed the title Sent two transactions when only one transactions was actioned Sent two transactions when only one transaction was actioned Jan 26, 2018
@alepop
Copy link
Contributor

alepop commented Jan 26, 2018

@slaweet I reproduce @jfernanz bug and sent 4 transactions in the test net with 1 sec difference.
https://testnet-explorer.lisk.io/tx/12874981639845717085
https://testnet-explorer.lisk.io/tx/11768000214022215171
https://testnet-explorer.lisk.io/tx/16438514967811730729
https://testnet-explorer.lisk.io/tx/9380774010211557400
How to reproduce. In the Lisk Nano open developers tools -> Performance -> Capture settings -> and add CPU throttling (I use x10). Then in the Send transaction dialog click many times to the send button. A possible fix is added to Send constructor component a flag like executed, and add a statement to the send handler to check this flag:
lisk-nano/src/components/send/send.js

  send(event) {
    event.preventDefault();
    if (!this.execued) {
      this.execued = true;
      this.props.sent({
          activePeer: this.props.activePeer,
          account: this.props.account,
          recipientId: this.state.recipient.value,
          amount: this.state.amount.value,
          passphrase: this.state.passphrase.value,
          secondPassphrase: this.state.secondPassphrase.value,
      });
    }
  }

@karmacoma karmacoma added this to Open Issues in Version 1.3.4 Jan 29, 2018
@slaweet slaweet closed this as completed in a26adc4 Feb 6, 2018
Version 1.3.4 automation moved this from Open Issues to Closed Issues Feb 6, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
No open projects
Version 1.3.4
  
Closed Issues
Development

No branches or pull requests

3 participants