-
Notifications
You must be signed in to change notification settings - Fork 671
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
[anitithesis] increase number of keys from 5 to 6 #3369
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As per Stephen, it will be more involved to change the number of nodes. The local network configuration is hard-coded for 5 nodes, and a different number of nodes will require a different genesis. Up to you if you want to hard-code or generate the required network configuration. Some relevant details for the generate option:
- tmpnet currently populates network configuration (i.e. node keys/ids and genesis) as part of network start. For the xsvm test setup this is already performed because its necessary to start the network to initialize the db state:
https://github.com/ava-labs/avalanchego/blob/master/tests/antithesis/compose.go#L65
-
For the avalanchego setup, it will be necessary to ensure thatnetwork.EnsureDefaultConfiguration
is called and thatnetwork.Genesis
is set (likely tonetwork.DefaultGenesis
) to ensure that configuration is populated before compose configuration is generated. -
It will also be necessary for both setups to ensure that the compose configuration for each node embeds the network genesis. For the local case the genesis is hard-coded in the avalanchego binary, but for a custom genesis it will need to be provided.
Edit: Maybe makes sense for compose.go to always init a bootstrap DB (i.e. remove check for subnet count)? That would ensure consistent initialization of a generated network.
@@ -39,7 +39,7 @@ import ( | |||
xbuilder "github.com/ava-labs/avalanchego/wallet/chain/x/builder" | |||
) | |||
|
|||
const NumKeys = 5 | |||
const NumKeys = 6 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(No action required) Maybe this value should be defined in tests/antithesis and reused elsewhere?
This PR has become stale because it has been open for 30 days with no activity. Adding the |
Why this should be merged
Increasing the number of nodes from 5 to 6 would allow us to test the 50% case and it's recovery.
How this works
trivial
How this was tested
CI.