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

Add configurable threshold for 'future block' check #800

Merged

Conversation

SatpalSandhu61
Copy link
Contributor

@SatpalSandhu61 SatpalSandhu61 commented Aug 13, 2019

Fixes #792
Added configurable threshold for 'future block' check, in order to avoid spurious "block in the future" messages for Istanbul and Clique.
Threshold is specified in seconds, using--allowedfutureblocktime command line argument.

Note that there is a similar change for ethash in upstream geth (albeit a fixed threshold, not configurable): https://github.com/ethereum/go-ethereum/blob/master/consensus/ethash/consensus.go#L248

Copy link
Contributor

@trung trung left a comment

Choose a reason for hiding this comment

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

Some nitpicks in code. Also please run goimports for the modified files

cmd/utils/flags.go Outdated Show resolved Hide resolved
@trung trung changed the title Add allowedFutureBlockTime flag for Istanbul. cmd,consensus/istanbul: add configurable threshold for 'future block' check Mar 11, 2020
trung
trung previously approved these changes Mar 17, 2020
Copy link
Contributor

@trung trung left a comment

Choose a reason for hiding this comment

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

LGTM

@SatpalSandhu61
Copy link
Contributor Author

Temporarily closing this PR as I want to make the parameter name generic, not just for Istanbul.

@SatpalSandhu61 SatpalSandhu61 changed the title cmd,consensus/istanbul: add configurable threshold for 'future block' check Add configurable threshold for 'future block' check Mar 20, 2020
@SatpalSandhu61
Copy link
Contributor Author

PR has been reopened with changes to make it more generic and include Clique.

Copy link
Contributor

@trung trung left a comment

Choose a reason for hiding this comment

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

LGTM

@jpmsam jpmsam merged commit 4c9740b into Consensys:master Apr 8, 2020
@SatpalSandhu61 SatpalSandhu61 deleted the issue-792-add-allowedFutureBlockTime branch May 1, 2020 15:43
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.

Add configurable threshold for 'block in the future' check
3 participants