This repository was archived by the owner on Jun 18, 2025. It is now read-only.
feat: raw and process snapshot commands - #6
Open
Pantani wants to merge 34 commits into
Open
Conversation
# Conflicts: # .gitignore # Makefile
Pantani
marked this pull request as ready for review
December 21, 2022 16:14
Pantani
requested review from
aljo242,
fadeev,
giunatale,
jeronimoalbi,
lubtd and
tbruyelle
as code owners
December 21, 2022 16:14
Welcome to Codecov 🎉Once merged to your default branch, Codecov will compare your coverage reports and display the results in this comment. Thanks for integrating Codecov - We've got you covered ☂️ |
lubtd
reviewed
Dec 22, 2022
| func NewAirdropRaw() *cobra.Command { | ||
| return &cobra.Command{ | ||
| Use: "raw [input-genesis]", | ||
| Short: "Generate raw airdrop data based on the input genesis", |
Contributor
There was a problem hiding this comment.
What is the input genesis for the raw command? Is it the genesis that has been exported from the chain to parse snapshot from? It's a bit unclear since we should also have the "input genesis" where we populate the claim genesis state from the snapshot data
This may be implemented but I think we should let the use the ability to provide a RPC address for the chain, where the genesis would be automatically exported
Pantani
marked this pull request as draft
December 26, 2022 04:13
- add comments - unexport config validate method
tbruyelle
reviewed
Jan 5, 2023
# Conflicts: # .github/workflows/test.yml # go.mod # go.sum
Contributor
|
Still in draft @Pantani ? |
Contributor
Author
yes, I'm working on it today |
Pantani
marked this pull request as ready for review
January 10, 2023 22:55
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
cmdcommands;debugmain package to test locally;snapshotpackage to generate a raw snapshot and filter based on the stake and bank modules;configpackage to parse the snapshot config file;formulapackage to calculate the airdrop balance (WIP/Blocked);genesispackage to handle genesis files;encodepackage to decode/encode the genesis state;How to test
Run the raw airdrop command to generate the raw data
go run cmd/debug/debug.go airdrop raw testdata/genesis.json 2> raw-snapshot.jsonRun the process command to generate the claim records
go run cmd/debug/debug.go airdrop process testdata/config.yml raw-snapshot.json 2> snapshot.jsonGenerate the new genesis json with the claimable state based on the output genesis
Or you can only use the generate command to run all four above with one command