Skip to content

Commit c2aa4ae

Browse files
dapplionpawanjay176
authored andcommitted
Revert type change in UnexpectedRequestId
1 parent 7488755 commit c2aa4ae

File tree

1 file changed

+7
-7
lines changed
  • beacon_node/network/src/sync/network_context

1 file changed

+7
-7
lines changed

beacon_node/network/src/sync/network_context/custody.rs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use beacon_chain::BeaconChainTypes;
55
use beacon_chain::validator_monitor::timestamp_now;
66
use fnv::FnvHashMap;
77
use lighthouse_network::PeerId;
8-
use lighthouse_network::service::api_types::{CustodyId, DataColumnsByRootRequester, Id};
8+
use lighthouse_network::service::api_types::{CustodyId, DataColumnsByRootRequester};
99
use lighthouse_tracing::SPAN_OUTGOING_CUSTODY_REQUEST;
1010
use parking_lot::RwLock;
1111
use std::collections::HashSet;
@@ -46,8 +46,8 @@ pub enum Error {
4646
/// There should only exist a single request at a time. Having multiple requests is a bug and
4747
/// can result in undefined state, so it's treated as a hard error and the lookup is dropped.
4848
UnexpectedRequestId {
49-
expected_req_id: Id,
50-
req_id: Id,
49+
expected_req_id: DataColumnsByRootRequestId,
50+
req_id: DataColumnsByRootRequestId,
5151
},
5252
}
5353

@@ -424,8 +424,8 @@ impl<E: EthSpec> ColumnRequest<E> {
424424
Status::Downloading(expected_req_id) => {
425425
if req_id != *expected_req_id {
426426
return Err(Error::UnexpectedRequestId {
427-
expected_req_id: expected_req_id.id,
428-
req_id: req_id.id,
427+
expected_req_id: *expected_req_id,
428+
req_id,
429429
});
430430
}
431431
self.status = Status::NotStarted(Instant::now());
@@ -457,8 +457,8 @@ impl<E: EthSpec> ColumnRequest<E> {
457457
Status::Downloading(expected_req_id) => {
458458
if req_id != *expected_req_id {
459459
return Err(Error::UnexpectedRequestId {
460-
expected_req_id: expected_req_id.id,
461-
req_id: req_id.id,
460+
expected_req_id: *expected_req_id,
461+
req_id,
462462
});
463463
}
464464
self.status = Status::Downloaded(peer_id, data_column, seen_timestamp);

0 commit comments

Comments
 (0)