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

Randomization for unknown sessions at a random frequency #2022

Merged
merged 7 commits into from
Nov 2, 2021

Conversation

yondonfu
Copy link
Member

@yondonfu yondonfu commented Sep 9, 2021

What does this pull request do? Explain your changes. (required)

This PR adds a randFreq field to MinLSSelector which defines a random frequency at which to randomize the selection of unknown sessions instead of running stake weighted selection when in on-chain mode.

Specific updates (required)

See commit history.

How did you test each of these updates (required)

Added unit tests, but only for simple scenarios as unit testing randomization is a bit tricky so my plan is to also do some manual testing with non-trivial values of randFreq i.e. not 0.0 or 1.0.

Checklist:

@yondonfu yondonfu force-pushed the yf/selection-randomization branch 3 times, most recently from 9335c1a to c3559a4 Compare September 28, 2021 22:06
@yondonfu yondonfu force-pushed the yf/selection-randomization branch 2 times, most recently from c7f72b4 to 1a35579 Compare October 21, 2021 17:40
@yondonfu yondonfu changed the base branch from nv/alt-discovery to fast-verification October 21, 2021 17:40
@yondonfu yondonfu force-pushed the yf/selection-randomization branch 2 times, most recently from 7911663 to 8fb8409 Compare October 23, 2021 14:45
Base automatically changed from fast-verification to master November 2, 2021 15:12
@yondonfu yondonfu marked this pull request as ready for review November 2, 2021 15:21
Copy link
Contributor

@jailuthra jailuthra left a comment

Choose a reason for hiding this comment

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

LGTM

@yondonfu yondonfu merged commit fbcdccb into master Nov 2, 2021
@yondonfu yondonfu deleted the yf/selection-randomization branch November 2, 2021 15:44
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.

None yet

2 participants