-
Notifications
You must be signed in to change notification settings - Fork 189
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(sozo): output block number after successful migration #717
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.
I believe outputting the block number is so that torii
can start syncing from when the World contract is deployed, instead of starting from block 0.
This would not output the block of when the World is deployed though but instead the block of when the migration is finished.
thats what i thought earlier, but world is redeployed for any kind of migration so afaik |
World will not be redeployed on component/system updates. It will only migrate the changed components/systems.
that would skip the prev blocks, no? |
oh, i saw
hmm so is the linked issue asking for block number at which the first deployment happened? but that means we would return the same i think we basically need to prune blocks to only process ones that have relevant state now, for that would returning i am not sure how |
Yeah, as kairy mentioned, torii would use the block from where the world is first deployed so it can process registration events and create component/system specific db tables. So I think two scenarios - If |
okay i have updated it to return block number only when Because there isn't a good way to store the |
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
Fixes: #687
print block number in stdout