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

Integrate go-ibft consensus engine to polybft consensus protocol #891

Merged
merged 9 commits into from
Nov 10, 2022

Conversation

Stefan-Ethernal
Copy link
Collaborator

@Stefan-Ethernal Stefan-Ethernal commented Nov 9, 2022

Description

Placeholder PR for go-ibft integration feature, which integrates go-ibft consensus engine into polybft consensus protocol.

Changes include

  • Bugfix (non-breaking change that solves an issue)
  • Hotfix (change that solves an urgent issue, and requires immediate attention)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (change that is not backwards-compatible and/or changes current functionality)

Checklist

  • I have assigned this PR to myself
  • I have added at least 1 reviewer
  • I have added the relevant labels
  • I have updated the official documentation
  • I have added sufficient documentation in code

Testing

  • I have tested this code with the official test suite
  • I have tested this code manually

Nemanja0x and others added 4 commits November 4, 2022 09:34
* consensus runtime backend metohod (not buildable)

* transport

* polybft - run cycle

* transport fix 2

* small changes

* less complex ibft consennsus wrapper.Example: https://replit.com/@crewce/Newest#main.go

* small changes

* runSequence better

* remove pbftTransportWrapper

* noone likes temp variables

* Comment fixed

* jm fixes

Co-authored-by: Igor Crevar <crewce@gmail.com>
* consensus runtime backend metohod (not buildable)

* transport

* polybft - run cycle

* transport fix 2

* less complex ibft consennsus wrapper.Example: https://replit.com/@crewce/Newest#main.go

* Implement MessageConstructor interface.

* Tidy linter errors.

* runSequence better

* remove pbftTransportWrapper

* Add quorum size implementation.

* Remove one part of pbft.NodeID reference.

* Add some comments.

* IsValid, Build proposal on FSM

* Add block validation.

* Add stub for IsValidSender method.

* Sender validation is always true.

* fsm - Insert block

* simplify build proposal

* Tidy logs.

* IsValidSender

* pbft.Proposal removed

* Tidy errors.

* restartEpoch if epoch is nil, remove hook in fsm

* initialization fix

* Fix compare.

* quorum fixes and error propagation

* evm-151 changes + additional needed in this task

* Increase test timeout.

* bring back some part of fsm

* just execute syn test 100 times in a row

* Tidy part of errors.

* Revert e2e test.

* Remove unused code and move message creator interface implementation.

* minor fix

* Add comments.

* code organization - valdateSender + recoverAddress

* Fix compile after merge.

* small change

* restart epoch on better place. lastBuiltBlock and epoch should not be nil

* small reorg in polybft

* pr fix

* Update comments

* pr fixes no 2

* Add voting power to the validators (#880)

* Add voting power to the validator account

* Rename ValidatorAccount to ValidatorMetadata

* Set voting power to the existing test

* Comment fixes

* Rename files

* Address comments

* Remove extra space from the comment

* pr fixes

* Rename GetValidatorAccount to GetValidatorMetadata

Co-authored-by: Nemanja0x <nemanja@ethernal.tech>
Co-authored-by: Igor Crevar <crewce@gmail.com>
Co-authored-by: Stefan Negovanović <stefan@ethernal.tech>
Co-authored-by: Stefan Negovanović <93934272+Stefan-Ethernal@users.noreply.github.com>
@codecov
Copy link

codecov bot commented Nov 9, 2022

Codecov Report

❗ No coverage uploaded for pull request base (feature/v3-parity@2f06ecd). Click here to learn what that means.
The diff coverage is n/a.

❗ Current head 25bb44e differs from pull request most recent head d92c70f. Consider uploading reports for the commit d92c70f to get more accurate results

@@                 Coverage Diff                  @@
##             feature/v3-parity     #891   +/-   ##
====================================================
  Coverage                     ?   49.31%           
====================================================
  Files                        ?      161           
  Lines                        ?    21633           
  Branches                     ?        0           
====================================================
  Hits                         ?    10668           
  Misses                       ?    10113           
  Partials                     ?      852           

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

* Populate round info and change proposal hash

* Adopt currentRound from BuildProposal

* Fix logs

* Fix proposal hash calculation inside IsValidProposalHash

* Update go-ibft version

* Igor's feedback addressed
@Stefan-Ethernal Stefan-Ethernal added the feature New update to Polygon Edge label Nov 9, 2022
goran-ethernal and others added 2 commits November 9, 2022 15:35
* EVM-187 Handling bundles on both sync and consensus

* consensus_runtime tests

* UT fix

Co-authored-by: Goran Rojovic <goran.rojovic@ethernal.tech>
@Stefan-Ethernal Stefan-Ethernal changed the title Go ibft integration Integrate go-ibft consensus engine to polybft consensus protocol Nov 10, 2022
@Stefan-Ethernal Stefan-Ethernal marked this pull request as ready for review November 10, 2022 08:49
@Stefan-Ethernal Stefan-Ethernal merged commit 234eacb into feature/v3-parity Nov 10, 2022
@Stefan-Ethernal Stefan-Ethernal deleted the go-ibft-integration branch November 10, 2022 13:02
@github-actions github-actions bot locked and limited conversation to collaborators Nov 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature New update to Polygon Edge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants