mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-09 19:51:47 +00:00
Fix context bytes logic for DataColumn RPC responses (#6325)
* Fix context byte logic for data columns.
This commit is contained in:
@@ -426,11 +426,12 @@ fn context_bytes<E: EthSpec>(
|
||||
RPCResponse::BlobsByRange(_) | RPCResponse::BlobsByRoot(_) => {
|
||||
return fork_context.to_context_bytes(ForkName::Deneb);
|
||||
}
|
||||
RPCResponse::DataColumnsByRoot(_) | RPCResponse::DataColumnsByRange(_) => {
|
||||
RPCResponse::DataColumnsByRoot(d) | RPCResponse::DataColumnsByRange(d) => {
|
||||
// TODO(das): Remove deneb fork after `peerdas-devnet-2`.
|
||||
return if fork_context.spec.eip7594_fork_epoch
|
||||
== fork_context.spec.deneb_fork_epoch
|
||||
{
|
||||
return if matches!(
|
||||
fork_context.spec.fork_name_at_slot::<E>(d.slot()),
|
||||
ForkName::Deneb
|
||||
) {
|
||||
fork_context.to_context_bytes(ForkName::Deneb)
|
||||
} else {
|
||||
fork_context.to_context_bytes(ForkName::Electra)
|
||||
|
||||
Reference in New Issue
Block a user