-
Notifications
You must be signed in to change notification settings - Fork 788
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
Fork aware max values in rpc #6847
base: unstable
Are you sure you want to change the base?
Conversation
@@ -455,7 +459,6 @@ impl<T: BeaconChainTypes> SyncNetworkContext<T> { | |||
(None, None) | |||
}; | |||
|
|||
// TODO(pawan): this would break if a batch contains multiple epochs |
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.
Even if a batch contains multiple epochs (which it doesn't), this is a very niche case that would only break during fork boundaries.
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 Pawan, left some suggestions :)
@@ -258,10 +260,11 @@ pub fn spawn<T: BeaconChainTypes>( | |||
network_send: mpsc::UnboundedSender<NetworkMessage<T::EthSpec>>, | |||
beacon_processor: Arc<NetworkBeaconProcessor<T>>, | |||
sync_recv: mpsc::UnboundedReceiver<SyncMessage<T::EthSpec>>, | |||
fork_context: Arc<ForkContext>, |
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.
nit: we can just pass the ForkName
which is Copy
and avoid clonning the Arc
when passing it
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.
current_fork
can change during runtime so we may use the outdated value if we do that . its just an Arc clone so it's okay imo
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.
makes sense, thanks for explaining Pawan!
Issue Addressed
N/A
Proposed Changes
In #6329 we changed
max_blobs_per_block
from a preset to a config value.We weren't using the right value based on fork in that PR. This is a follow up PR to use the fork dependent values.
In the proces, I also updated other places where we weren't using fork dependent values from the ChainSpec.
Note to reviewer: easier to go through by commit