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

Implement KnownBackedCandidate tracker knowledge #4573

Open
1 task
EclesioMeloJunior opened this issue Feb 26, 2025 · 0 comments
Open
1 task

Implement KnownBackedCandidate tracker knowledge #4573

EclesioMeloJunior opened this issue Feb 26, 2025 · 0 comments
Labels
T-implementation this issue/pr is a new feature or functionality.

Comments

@EclesioMeloJunior
Copy link
Member

EclesioMeloJunior commented Feb 26, 2025

Issue summary

Create the struct that helps the Grid Tracker to map information about statement distribution of already known backed candidates

Given that this struct is per candidate, it should have:

  • Candidate backing group index
  • Local knowledge (statements we already have for the candidate)
  • Mutual Knowledge
    • For each validator we interact with we should create a MutualKnowledge that is composed of
      • remote knowledge: if the peer interact with us we should register his knowledge (provided by him)
      • local knowledge: if we interact with a peer we should register the knowledge we provided
      • received knowledge: this field preserves the received knowledge from the remote w/o changing after manifest exchange.

Functionalities:

  • Check for pending statements (check method) and retrieve pending statements (retrieve pending method) for a given validator index, based on our local knowledge (not from the mutual knowledge, given that the mutual might be out of date and that is what we should consider as pending)
  • record interactions with peers (incoming or outgoing)
  • retrieve possible senders and possible recipients
  • check if we already have sent manifest to a given peer

As part of this issue we should implement StatementFilter given that is a dependency for Mutual Knowledge

Other information and links

Acceptance criteria

  • New code is 60% covered with unit tests
@EclesioMeloJunior EclesioMeloJunior added the T-implementation this issue/pr is a new feature or functionality. label Feb 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-implementation this issue/pr is a new feature or functionality.
Projects
None yet
Development

No branches or pull requests

1 participant