Skip to content
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

Handle unknown networks #725

Merged
merged 2 commits into from
Apr 4, 2023
Merged

Handle unknown networks #725

merged 2 commits into from
Apr 4, 2023

Conversation

tombeynon
Copy link
Contributor

Currently running the autostake script will fail if the network is not included in networks.json or networks.local.json. Networks only present in Chain Registry had to be added to networks.local.json with empty config before the script would recognise them.

This PR instead assumes the network will be found in Chain Registry if the script is run with a network name, and will only fail if the network is not present in Chain Registry. E.g. npm run autostake nois will now lookup nois in the Registry and work as expected.

Running the script without a network (npm run autostake) will continue to run the script for all networks in networks.json AND networks.local.json. It will not run for every chain in Registry, as this will take a long time.

Future updates will change this npm run autostake command without arguments to only run for chains in networks.local.json, since this is more adaptable, but for now it remains as-is.

@tombeynon tombeynon linked an issue Apr 4, 2023 that may be closed by this pull request
@tombeynon tombeynon merged commit de58cdd into master Apr 4, 2023
@tombeynon tombeynon deleted the handle-unknown-networks branch April 4, 2023 21:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

restake jackal
1 participant