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

formal-models: extend dBFT with additional post-commit phase #116

Merged
merged 1 commit into from
Jun 24, 2024

Conversation

AnnaShaleva
Copy link
Member

@AnnaShaleva AnnaShaleva commented Apr 25, 2024

Close #111.

The extended model includes additional ackSent RM state and additional Ack message type. Speaking in terms of anti-MEV solution, preBlock approval corresponds to the commitSent RM state, and the only possible transition from commitSent stage is to move to ackSent stage via Ack message sending (Block approval).

Presented model has the same 4-nodes deadlock scenario with a single dead node described in neo-project/neo-modules#792 (comment):
Screenshot from 2024-04-25 19-20-49

Also, the presented model has additional TerminatingFourNodesDeadlock action that allows infinite stuttering in the described deadlock to enable further model checking. If this action is enabled, then one more deadlock is being found (not related to the additional phase), this deadlock is yet another face of the same liveness lock described previously:
image

TODO:

  • Add description to the README;
  • Add a picture;
  • Update configuration;
  • Improve commit message.

@AnnaShaleva AnnaShaleva modified the milestone: v0.3.0 Apr 25, 2024
Copy link

codecov bot commented Apr 25, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 63.31%. Comparing base (96105d0) to head (de50c7b).

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #116   +/-   ##
=======================================
  Coverage   63.31%   63.31%           
=======================================
  Files          27       27           
  Lines        1510     1510           
=======================================
  Hits          956      956           
  Misses        489      489           
  Partials       65       65           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@AnnaShaleva AnnaShaleva force-pushed the add-postblock-handling branch 2 times, most recently from 2b6c4cf to 0095b94 Compare June 20, 2024 12:09
@AnnaShaleva AnnaShaleva marked this pull request as ready for review June 20, 2024 12:12
@AnnaShaleva
Copy link
Member Author

Ready for review. @roman-khimov, I think the best way to review it is to check the diff between this model and our basic dBFT model.

Copy link
Member

@roman-khimov roman-khimov left a comment

Choose a reason for hiding this comment

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

Looks OK otherwise.

formal-models/README.md Outdated Show resolved Hide resolved
formal-models/README.md Outdated Show resolved Hide resolved
formal-models/README.md Outdated Show resolved Hide resolved
formal-models/README.md Outdated Show resolved Hide resolved
formal-models/dbft3.0/dbft.tla Outdated Show resolved Hide resolved
Close #111. The additional step is called RMSendAck and allows to send
Ack message once enough Commit messages are received. Block can be
accepted only if BFT number of Ack messages are collected.

Signed-off-by: Anna Shaleva <[email protected]>
@AnnaShaleva
Copy link
Member Author

@roman-khimov, ready for review.

@roman-khimov roman-khimov merged commit 351c29a into master Jun 24, 2024
12 checks passed
@roman-khimov roman-khimov deleted the add-postblock-handling branch June 24, 2024 13:20
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.

TLA+ model for enhanced Bane dBFT with an additional phase
2 participants