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

Differences in vote column in mem_accounts while syncing from scratch #2420

Closed
ManuGowda opened this Issue Sep 25, 2018 · 2 comments

Comments

Projects
4 participants
@ManuGowda
Copy link
Member

ManuGowda commented Sep 25, 2018

Expected behavior

Use the logic which was part of the protocol and persisted in the blockchain.

Actual behavior

When a 1.1.0 node sync from scratch with test network, the 1.1.0 node failed to sync due to differences in mem_accounts table (vote column) leading to change in delegate list order, the change in order of delegate resulting in unrecoverable fork3, here is the logs for more information.

[inf] 2018-09-24 15:58:54 | Verify->verifyBlock succeeded for block 14304594437763848243 at height 809518.
[ERR] 2018-09-24 15:58:54 | Expected generator: e156529dae0f0f586539ff2f8eebc1b735e67687f6d2fff45ea01d7dbd71533e Received generator: f4a319a653a3d5f3bbe54fabd563d9444e05a776eec005bcf961c31ec6f89c15
[inf] 2018-09-24 15:58:54 | Fork - {"delegate":"f4a319a653a3d5f3bbe54fabd563d9444e05a776eec005bcf961c31ec6f89c15","block":{"id":"14304594437763848243","timestamp":14261020,"height":809518,"previousBlock":"781869470176582773"},"cause":3}
[inf] 2018-09-24 15:58:54 | Banned peer - 46.101.22.213:7001
[ERR] 2018-09-24 15:58:54 | Error loading blocks: Failed to verify slot: 1426102
[ERR] 2018-09-24 15:58:54 | Failed to load blocks from: 46.101.22.213:7001
[inf] 2018-09-24 15:58:54 | Looking for common block with: 178.62.106.202:7001
[inf] 2018-09-24 15:58:54 | Releasing enqueued broadcasts
[inf] 2018-09-24 15:58:54 | Queue empty
[inf] 2018-09-24 15:58:54 | Found common block: 781869470176582773 with: 178.62.106.202:7001
[inf] 2018-09-24 15:58:54 | Loading blocks from: 178.62.106.202:7001
[inf] 2018-09-24 15:58:54 | Verify->verifyBlock succeeded for block 14304594437763848243 at height 809518.
[ERR] 2018-09-24 15:58:54 | Expected generator: e156529dae0f0f586539ff2f8eebc1b735e67687f6d2fff45ea01d7dbd71533e Received generator: f4a319a653a3d5f3bbe54fabd563d9444e05a776eec005bcf961c31ec6f89c15
[inf] 2018-09-24 15:58:54 | Fork - {"delegate":"f4a319a653a3d5f3bbe54fabd563d9444e05a776eec005bcf961c31ec6f89c15","block":{"id":"14304594437763848243","timestamp":14261020,"height":809518,"previousBlock":"781869470176582773"},"cause":3}
[inf] 2018-09-24 15:58:54 | Banned peer - 178.62.106.202:7001
[ERR] 2018-09-24 15:58:54 | Error loading blocks: Failed to verify slot: 1426102
[ERR] 2018-09-24 15:58:54 | Failed to load blocks from: 178.62.106.202:7001

The vote column in mem_accounts is impacted due to the changes #716 introduced in 1.1.0, before this change there was a difference of 1 beddow due to the way we handled javascript number, after the fixes in this PR #2187 the issue was fixed, however this changes will invalidate the blockchain.

Steps to reproduce

Run 1.1.0 node and sync from scratch with the test network

Which version(s) does this affect? (Environment, OS, etc...)

1.1.0

@nazarhussain

This comment has been minimized.

Copy link
Contributor

nazarhussain commented Sep 25, 2018

Here are some details for the problem, comparing of accounts votes and balances between 1.0.0 and 1.1.0 upto round 8015.

lisk_test_1_1_delegate_bug.xlsx

@nazarhussain

This comment has been minimized.

Copy link
Contributor

nazarhussain commented Sep 25, 2018

@4miners Can you confirm that difference is caught up during the snapshotting as well?

@nazarhussain nazarhussain added this to the Version 1.1.0 milestone Sep 26, 2018

@nazarhussain nazarhussain self-assigned this Sep 26, 2018

@shuse2 shuse2 closed this in 4ae8553 Sep 26, 2018

@4miners 4miners reopened this Oct 1, 2018

@nazarhussain nazarhussain added this to New Issues in Version 1.1.0 via automation Oct 2, 2018

@MaciejBaj MaciejBaj added the bug label Oct 3, 2018

@MaciejBaj MaciejBaj added this to Sprint Backlog in Lisk Pipelines Oct 5, 2018

MaciejBaj added a commit that referenced this issue Oct 8, 2018

Merge pull request #2441 from LiskHQ/2420-revert-round-logic
Differences in vote column in mem_accounts while syncing from scratch - Closes #2420

@MaciejBaj MaciejBaj closed this Oct 8, 2018

Version 1.1.0 automation moved this from New Issues to Closed Issues Oct 8, 2018

@MaciejBaj MaciejBaj removed this from Sprint Backlog in Lisk Pipelines Oct 9, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.