Skip to content

Validate genesis blocks on network change #667

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

Open
tuliomir opened this issue Mar 10, 2025 · 0 comments
Open

Validate genesis blocks on network change #667

tuliomir opened this issue Mar 10, 2025 · 0 comments
Labels
enhancement New feature or request

Comments

@tuliomir
Copy link
Contributor

tuliomir commented Mar 10, 2025

After #660, all registered tokens and registered nano contracts are cleared from the app when the network is changed.

However, the change may be happening for nodes within the same network, like changing the fullnode from node1.mainnet to node2.mainnet, which shouldn't trigger a registered token cleanup. This is an edge case of the issue raised by #385

To implement this, we could read the hashes of the genesis block obtained from the fullnode status request and compare to the previous network. If both are the same, we can assume the network hasn't changed and the registrated data cleanup should not occur.

@tuliomir tuliomir added the enhancement New feature or request label Mar 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant