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

Update finality depth check headtracker #13089

Conversation

silaslenihan
Copy link
Contributor

@silaslenihan silaslenihan commented May 2, 2024

Update finality check in HeadTracker to use chain specific LatestFinalizedHead
Relevant ticket: BCI-2919

@silaslenihan silaslenihan force-pushed the BCI-2919-Update-FinalityDepth-check-logic-on-Head-Tracker branch from a6d7c2b to fc9c081 Compare May 2, 2024 22:08
@silaslenihan silaslenihan force-pushed the BCI-2919-Update-FinalityDepth-check-logic-on-Head-Tracker branch from e60f5dc to c20bfd0 Compare May 3, 2024 14:09
@silaslenihan silaslenihan marked this pull request as ready for review May 8, 2024 14:07
@silaslenihan silaslenihan requested review from a team as code owners May 8, 2024 14:07
if head.BlockNumber() < prevUnFinalizedHead {
prevLatestFinalized := prevHead.LatestFinalizedHead()

if prevLatestFinalized != nil && prevLatestFinalized.IsValid() && head.BlockNumber() <= prevLatestFinalized.BlockNumber() {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Add isValid check

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It is already checking prevLatestFinalized.IsValid()

amit-momin
amit-momin previously approved these changes May 8, 2024
@silaslenihan silaslenihan force-pushed the BCI-2919-Update-FinalityDepth-check-logic-on-Head-Tracker branch from a953dcc to 216c11a Compare May 20, 2024 15:44
@silaslenihan silaslenihan force-pushed the BCI-2919-Update-FinalityDepth-check-logic-on-Head-Tracker branch from 87fe2ca to e854293 Compare May 20, 2024 16:37
@prashantkumar1982 prashantkumar1982 added this pull request to the merge queue May 20, 2024
Merged via the queue into develop with commit b00ad69 May 20, 2024
107 checks passed
@prashantkumar1982 prashantkumar1982 deleted the BCI-2919-Update-FinalityDepth-check-logic-on-Head-Tracker branch May 20, 2024 21:04
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.

5 participants