-
Notifications
You must be signed in to change notification settings - Fork 13
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(iota-genesis-builder): create a Hornet snapshot filter framework + filter out voting outputs #4513
base: sc-platform/address-swap-test
Are you sure you want to change the base?
feat(iota-genesis-builder): create a Hornet snapshot filter framework + filter out voting outputs #4513
Conversation
This pull request has been deployed to Vercel. Latest commit: 2a536f7 ✅ Preview: https://apps-ui-20pcmxjby-iota1.vercel.app |
This pull request has been deployed to Vercel. Latest commit: 2a536f7 ✅ Preview: https://apps-backend-29a719c9ccbdb9b80c97b599a599d8953354da-lwv68nnrd.vercel.app |
This pull request has been deployed to Vercel. Latest commit: 2a536f7 ✅ Preview: https://iota-rebased-explorer-092603f1de8088243ccb8b861b23e-ewtpgx65v.vercel.app |
This pull request has been deployed to Vercel. Latest commit: 2a536f7 ✅ Preview: https://wallet-dashboard-a225fcfa1e2f852205a61a7cd1d5d93e92-qvghimk2q.vercel.app |
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.
This seems like a quite complicated way of applying three static filters in order during iteration. IMO these could be functions as there is no need to unify these with a trait.
This pull request has been deployed to Vercel. Latest commit: f3a439d ✅ Preview: https://apps-ui-hj16vihms-iota1.vercel.app |
This pull request has been deployed to Vercel. Latest commit: f3a439d ✅ Preview: https://apps-backend-29a719c9ccbdb9b80c97b599a599d8953354da-e8448wny2.vercel.app |
This pull request has been deployed to Vercel. Latest commit: f3a439d ✅ Preview: https://iota-rebased-explorer-092603f1de8088243ccb8b861b23e-j2tjza35r.vercel.app |
This pull request has been deployed to Vercel. Latest commit: f3a439d ✅ Preview: https://wallet-dashboard-a225fcfa1e2f852205a61a7cd1d5d93e92-429cow23n.vercel.app |
Description of change
This PR builds on top of #4389. In there, the
MergingIterator
was simply moved into its own file. This iterator was already filtering some outputs to: (i) scale the amount of iota from micro to nano, (ii) find unlockable vesting outputs and merge them (implemented in #1238).In this PR, these filtering operations are firstly standardized into a trait
HornetFilter
and then a third filter is added ->ParticipationOutputFilter
. This one matches basic outputs having a tag being the voting "Participation Tag" and then removes all features from the basic output.[edit]
After this comment and a discussion on Slack, me and @muXxer came to the conclusion that not only "voting" basic outputs should be filtered for feature and metadata removal, but also "staking" basic outputs (unintentionally the implementation was already done to do so).
Links to any relevant issues
#4380 + staking basic outputs
Type of change
How the change has been tested
cargo run --release --bin iota-genesis-builder -- --disable-global-snapshot-verification iota --snapshot-path ../latest-full_snapshot.bin --target-network alphanet-test --address-swap-map-path ../swap.csv
Change checklist