-
Notifications
You must be signed in to change notification settings - Fork 112
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
seed
command
#83
seed
command
#83
Conversation
whaaat is going on with the Actions |
57f05da
to
5dd2717
Compare
And more flushed out but incomplete
This may need some cleaning up, but this is the first iteration to appease the compiler.
1a85732
to
9f94f83
Compare
Moved SeedService out of the command closure Command currently spawns a tokio task to DOS the seed service with `Request::GetPeers` every second. Pertains to #54
Co-Authored-By: Henry de Valence <hdevalence@hdevalence.ca>
Co-Authored-By: Henry de Valence <hdevalence@hdevalence.ca>
Co-Authored-By: Henry de Valence <hdevalence@hdevalence.ca>
Network::Mainnet => Config::parse_peers(self.initial_mainnet_peers.clone()), | ||
Network::Testnet => Config::parse_peers(self.initial_testnet_peers.clone()), | ||
} | ||
} |
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.
take-or-leave-it: since parse_peers
is never used outside of initial_peers
, it could be folded in as match self.network { ... } .iter().flat_map(...).flatten().collect()
, and this saves an allocation by only doing one collect
instead of two.
Yay, this is great! |
Not great: my ability to identify buttons |
…sitive response first, otherwise panic Co-Authored-By: Henry de Valence <hdevalence@hdevalence.ca>
Co-Authored-By: Henry de Valence <hdevalence@hdevalence.ca>
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
Also includes some
Config
updates to populate default initial seeds based on the selected network (mainnet and testnet for now).