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

Fixes syncing getting stuck at intervals of 500 blocks. #1

Merged
merged 5 commits into from
Dec 29, 2017

Conversation

5mil
Copy link

@5mil 5mil commented Dec 29, 2017

The problem is Proof of Stake blocks are not stored when the previous transaction of the CoinStake is missing. So the initial download process is broken.

To solve this:
The reference block is now the best block, whatever the proof.

The client asks for missing blocks when it receives a PoS block and
it doesn't have the CoinStake previous transaction.

Block request are retried immediately during initial download because
the same last block is asked multiple times until we have the full
chain.

Solution by Sigmike.

The problem is Proof of Stake blocks are not stored when the previous transaction of the CoinStake is missing. So the initial download process is broken.

To solve this:
The reference block is now the best block, whatever the proof.

The client asks for missing blocks when it receives a PoS block and
it doesn't have the CoinStake previous transaction.

Block request are retried immediately during initial download because
the same last block is asked multiple times until we have the full
chain.

Solution inspired by Sigmike.
@maxxine maxxine merged commit fade14f into maxxine:master Dec 29, 2017
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.

2 participants