Skip to content

357/359/377 - bug fixes #370

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

Merged
merged 7 commits into from
Oct 28, 2019
Merged

357/359/377 - bug fixes #370

merged 7 commits into from
Oct 28, 2019

Conversation

capt4ce
Copy link
Contributor

@capt4ce capt4ce commented Oct 24, 2019

Description

Fix bug fixes related to download blockchain and rollback

Breakdown

Reference Issue

Close #359 #357 #377

Step to Test (optional)

  • run 1 node as a longer fork with corrupter DB (2953 blockchain height inconsistent)
  • run another node to download the blocks. The blocks should stuck at height 2952, because at height 2953, there was transaction that should not pass the validation.

@capt4ce capt4ce added the WIP label Oct 24, 2019
@capt4ce capt4ce self-assigned this Oct 24, 2019
}
} else {
forkBlocks = append(forkBlocks, block)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should there be special handle once notice fork block is pushed? I mean if we already notice a single fork block, that mean we won't be able to validate the rest of the block anymore right? but this is just an open question, I'm not sure about the overall implementation regarding the fork process.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice catch! I have handled it by breaking from the loop. Thank you

@capt4ce capt4ce changed the title 359 - validate incoming block is not our last block 357/359/377 - bug fixes Oct 25, 2019
@andy-shi88
Copy link
Contributor

please fix the tests, and update base branch. @capt4ce

@capt4ce
Copy link
Contributor Author

capt4ce commented Oct 28, 2019

@andy-shi88 Just fixed the failed CI. Please kindly check it again

@andy-shi88 andy-shi88 merged commit 8e245ce into develop Oct 28, 2019
@andy-shi88 andy-shi88 deleted the 359-downloadblockchain-bug branch October 28, 2019 06:30
@andy-shi88 andy-shi88 restored the 359-downloadblockchain-bug branch October 28, 2019 06:30
@andy-shi88 andy-shi88 deleted the 359-downloadblockchain-bug branch October 28, 2019 06:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: Download Blockchain stucks at arbitrary point
3 participants