Fix Rust beta compiler errors (1.77) (#5180)

* Lint fixes

* More fixes for beta compiler.

* Format fixes

* Move `#[allow(dead_code)]` to field level.

* Remove old comment.

* Update beacon_node/execution_layer/src/test_utils/mod.rs

Co-authored-by: João Oliveira <hello@jxs.pt>

* remove duplicate line
This commit is contained in:
Jimmy Chen
2024-02-06 04:54:11 +11:00
committed by GitHub
parent 8fb6989801
commit 39e9f7dc6b
19 changed files with 64 additions and 46 deletions

View File

@@ -434,7 +434,7 @@ impl<E: EthSpec> Environment<E> {
async move { rx.next().await.ok_or("Internal shutdown channel exhausted") };
futures::pin_mut!(inner_shutdown);
match self.runtime().block_on(async {
let register_handlers = async {
let mut handles = vec![];
// setup for handling SIGTERM
@@ -465,7 +465,9 @@ impl<E: EthSpec> Environment<E> {
}
future::select(inner_shutdown, future::select_all(handles.into_iter())).await
}) {
};
match self.runtime().block_on(register_handlers) {
future::Either::Left((Ok(reason), _)) => {
info!(self.log, "Internal shutdown received"; "reason" => reason.message());
Ok(reason)