-
Notifications
You must be signed in to change notification settings - Fork 137
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(beacon): load trusted block root from embedded file #1689
Conversation
4ae8337
to
a38a06a
Compare
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 think we should use include_str!("../../resources/genesis/mainnet.json")
, RustEmbed seems pretty overkill, for something include_str!()
can accomplish easily and is also apart of the Rust Core Library
a38a06a
to
9cf77e9
Compare
I changed it to |
9cf77e9
to
48f0e98
Compare
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.
🚀
857388c
to
ce12808
Compare
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.
much cleaner 🚀
@@ -52,7 +53,7 @@ impl BeaconNetwork { | |||
header_oracle: Arc<RwLock<HeaderOracle>>, | |||
) -> anyhow::Result<Self> { | |||
let config = OverlayConfig { | |||
bootnode_enrs: portal_config.bootnodes, | |||
bootnode_enrs: portal_config.bootnodes.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.
bootnode_enrs: portal_config.bootnodes.clone(), | |
bootnode_enrs: portal_config.bootnodes, |
Does this need a 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.
Yeah, because portal_config is used again below.
ce12808
to
9ec14dc
Compare
What was wrong?
To facilitate deployments and UX, on the last call we agreed to rely on an embedded trusted block root file as a fallback mechanism (if the user does not provide it via a
--trusted-block-root
flag and if the beacon network is enabled).How was it fixed?
The trusted block root is: 0x107ebc42ce260968c32fba62e2fa6c779f188a0a8c22db0d8afc75801c692fc7.
To-Do