Skip to content
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

Merge unstable into electra_attestation_changes #5832

Merged
Changes from 1 commit
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
6d792b4
Revise contributors guide (#5720)
jimmygchen May 7, 2024
93e0649
Notify lookup sync of gossip processing results (#5722)
dapplion May 13, 2024
f37ffe4
Do not request current child lookup peers (#5724)
dapplion May 13, 2024
ce66ab3
Enforce sync lookup receives a single result (#5777)
dapplion May 14, 2024
683d9df
Don't request block components until having block (#5774)
dapplion May 14, 2024
6f45ad4
Log stuck lookups (#5778)
dapplion May 14, 2024
6636167
Log block import source (#5738)
eserilev May 15, 2024
1d61605
use electra feature in notifier completeness check (#5786)
realbigsean May 15, 2024
0f49951
Skip CI's `test-suite` when the `skip-ci` label is present (#5790)
antondlr May 16, 2024
319b4a2
Skip creating child lookup if parent is never created (#5803)
dapplion May 17, 2024
8006418
Type sync network context send errors (#5808)
dapplion May 17, 2024
b5de925
Use JSON header by default for `/eth/v1/beacon/deposit_snapshot` (#5813)
chong-he May 20, 2024
2a87016
Fix lookup disconnect peer (#5815)
dapplion May 20, 2024
52e3112
Reduce frequency of polling unknown validators to avoid overwhelming …
jimmygchen May 22, 2024
8762d82
Fix hot state disk leak (#5768)
michaelsproul May 23, 2024
17d9086
Drop stuck lookups (#5824)
dapplion May 23, 2024
61b29fa
Update default target peers documentation (#5727)
eserilev May 23, 2024
7073242
Suppress RPC Error disconnect log (#5802)
dapplion May 23, 2024
3070cb7
Markdown linter (#5494)
chong-he May 24, 2024
987abe0
Merge remote-tracking branch 'upstream/unstable'
ethDreamer May 24, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Skip creating child lookup if parent is never created (#5803)
* Skip creating child lookup if parent is never created
  • Loading branch information
dapplion authored May 17, 2024
commit 319b4a246733e106a4608c22fa8e0dcba9043da5
16 changes: 11 additions & 5 deletions beacon_node/network/src/sync/block_lookups/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -298,9 +298,12 @@ impl<T: BeaconChainTypes> BlockLookups<T> {
};

let result = lookup.continue_requests(cx);
self.on_lookup_result(id, result, "new_current_lookup", cx);
self.update_metrics();
true
if self.on_lookup_result(id, result, "new_current_lookup", cx) {
self.update_metrics();
true
} else {
false
}
}

/* Lookup responses */
Expand Down Expand Up @@ -622,15 +625,16 @@ impl<T: BeaconChainTypes> BlockLookups<T> {
}

/// Common handler a lookup request error, drop it and update metrics
/// Returns true if the lookup is created or already exists
fn on_lookup_result(
&mut self,
id: SingleLookupId,
result: Result<LookupResult, LookupRequestError>,
source: &str,
cx: &mut SyncNetworkContext<T>,
) {
) -> bool {
match result {
Ok(LookupResult::Pending) => {} // no action
Ok(LookupResult::Pending) => true, // no action
Ok(LookupResult::Completed) => {
if let Some(lookup) = self.single_block_lookups.remove(&id) {
debug!(self.log, "Dropping completed lookup"; "block" => ?lookup.block_root(), "id" => id);
Expand All @@ -641,12 +645,14 @@ impl<T: BeaconChainTypes> BlockLookups<T> {
} else {
debug!(self.log, "Attempting to drop non-existent lookup"; "id" => id);
}
false
}
Err(error) => {
debug!(self.log, "Dropping lookup on request error"; "id" => id, "source" => source, "error" => ?error);
metrics::inc_counter_vec(&metrics::SYNC_LOOKUP_DROPPED, &[error.into()]);
self.drop_lookup_and_children(id);
self.update_metrics();
false
}
}
}
Expand Down
Loading