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

FIX: Add (optional) timeout to parent sync Ethereum API queries #758

Merged
merged 3 commits into from
Feb 29, 2024

Conversation

aakoshh
Copy link
Contributor

@aakoshh aakoshh commented Feb 29, 2024

Related to #755

The setting is added as optional so that existing deployments won't get an error if it's missing, and that I don't have to hardcode some default. Instead it's added in the infra scripts, so we can see if it has any effect.

It also fixes the default majority to be larger than 2/3, which is standard in Byzantine settings.

@@ -67,7 +67,7 @@ const ETH_PROVIDER_POLLING_TIME: Duration = Duration::from_secs(1);
const TRANSACTION_RECEIPT_RETRIES: usize = 200;

/// The majority vote percentage for checkpoint submission when creating a subnet.
const SUBNET_MAJORITY_PERCENTAGE: u8 = 60;
const SUBNET_MAJORITY_PERCENTAGE: u8 = 67;
Copy link
Contributor

Choose a reason for hiding this comment

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

In contract this default is set as 70. Would it make sense to unify it one way or another so it's at least simpler to answer the question "what is the default?"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

From Byzantine literature it has to be n * 2/3 + 1, which if we go from 1 to 100 is 67. Not sure where 60 came from, or why it should be 70.

@aakoshh aakoshh merged commit b2bdb1f into main Feb 29, 2024
19 checks passed
@aakoshh aakoshh deleted the fix-sync-add-timeout branch February 29, 2024 14:35
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.

2 participants