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
Closed
Assignees
Milestone

Comments

@ManuGowda
Copy link
Contributor

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
Copy link
Contributor

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
Copy link
Contributor

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

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

4 participants