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

[anitithesis] increase number of keys from 5 to 6 #3369

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

tsachiherman
Copy link
Contributor

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.

@tsachiherman tsachiherman self-assigned this Sep 6, 2024
@tsachiherman tsachiherman linked an issue Sep 6, 2024 that may be closed by this pull request
Copy link
Contributor

@marun marun left a 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 that network.EnsureDefaultConfiguration is called and that network.Genesis is set (likely to network.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
Copy link
Contributor

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?

Copy link

This PR has become stale because it has been open for 30 days with no activity. Adding the lifecycle/frozen label will cause this PR to ignore lifecycle events.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

increase the number of nodes during antithesis testing
2 participants