-
Notifications
You must be signed in to change notification settings - Fork 550
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
feat(network
): initialize prepare
command
#1806
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.
lgtm
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.
👌🏽
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.
👏
@@ -0,0 +1,79 @@ | |||
package networktypes |
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.
Can we move this to the network pkg?
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.
Why? The information is used by networkchain
so we don't have a network
dependency in networkchain
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.
ok I just noticed that. but still, I'm a bit un comfortable with with the networktypes pkg in general. because it feels like we define all of the types of network pkg to there whereas we only put the shared types there between the network and networkchain.
Anyways, I'll try to make a refactoring on this later and see if we can rm this pkg completely.
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.
we define all of the types of network pkg to there whereas we only put the shared types there between the network and networkchain.
I didn't get this statement. The point is actually to define what is shared between network
and networkchain
. Example, networkchain
should be agnostic to spn
communication but it should still have somewhere the concept of a genesis account in order to build the chain with Genesis Information
I'm not closed to a refactoring for this but I think it's better if we discuss the new architecture before creating a PR
Co-authored-by: İlker G. Öztürk <ilkergoktugozturk@gmail.com>
Co-authored-by: Danilo Pantani <danpantani@gmail.com>
* Initialize command * add requests for prepare * Initialize prepare * fix * Initialize cosmosaddress * get prefux * Apply genesis accounts * Apply vesting options * lint * Genesis setup validators * lint * Add todo comment * Support path for prepare * Add prepare option * Set genesis time * Initialize genesis state * Genesis test * Remove launch dir * Initial genesis * lint * fixes * fix utc time * Fix time test * small refactor * Update TODO comment * refactor queries * Revert queries * comments * Fix gentx path * Network types * Genesis information query * Use genesis info * Comments * Add launch time * fix join * refactor * lint * type tests * from flag * Update starport/services/network/networktypes/genesisinformation.go Co-authored-by: İlker G. Öztürk <ilkergoktugozturk@gmail.com> * Update starport/services/network/networkchain/prepare.go Co-authored-by: Danilo Pantani <danpantani@gmail.com> * Renaming Co-authored-by: Danilo Pantani <danpantani@gmail.com> Co-authored-by: Barrie Byron <barrie.byron@tendermint.com> Co-authored-by: İlker G. Öztürk <ilkergoktugozturk@gmail.com>
Will initialize and set up the genesis and config of the chain from the approved requests
If the config dir doesn't exist, the chain is fully initialized with a validator key
If the config dir exists, the genesis file is reinitialized and the validator remains the same