Skip to content

Commit 0b5283e

Browse files
committed
Replace tracing::debug! with debug! same for other levels
1 parent 4b522d7 commit 0b5283e

File tree

7 files changed

+23
-22
lines changed

7 files changed

+23
-22
lines changed

beacon_node/lighthouse_network/src/types/globals.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ impl<E: EthSpec> NetworkGlobals<E> {
7979
sampling_subnets.extend(subnets);
8080
}
8181

82-
tracing::debug!(
82+
debug!(
8383
cgc = custody_group_count,
8484
?sampling_subnets,
8585
"Starting node with custody params"

beacon_node/lighthouse_network/tests/rpc_tests.rs

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1037,7 +1037,7 @@ fn test_tcp_columns_by_root_chunked_rpc() {
10371037
loop {
10381038
match sender.next_event().await {
10391039
NetworkEvent::PeerConnectedOutgoing(peer_id) => {
1040-
tracing::info!("Sending RPC");
1040+
info!("Sending RPC");
10411041
tokio::time::sleep(Duration::from_secs(1)).await;
10421042
sender
10431043
.send_request(peer_id, AppRequestId::Router, rpc_request.clone())
@@ -1051,7 +1051,7 @@ fn test_tcp_columns_by_root_chunked_rpc() {
10511051
Response::DataColumnsByRoot(Some(sidecar)) => {
10521052
assert_eq!(sidecar, data_column.clone());
10531053
messages_received += 1;
1054-
tracing::info!("Chunk received");
1054+
info!("Chunk received");
10551055
}
10561056
Response::DataColumnsByRoot(None) => {
10571057
// should be exactly messages_to_send
@@ -1078,27 +1078,27 @@ fn test_tcp_columns_by_root_chunked_rpc() {
10781078
} => {
10791079
if request_type == rpc_request {
10801080
// send the response
1081-
tracing::info!("Receiver got request");
1081+
info!("Receiver got request");
10821082

10831083
for _ in 0..messages_to_send {
10841084
receiver.send_response(
10851085
peer_id,
10861086
inbound_request_id,
10871087
rpc_response.clone(),
10881088
);
1089-
tracing::info!("Sending message");
1089+
info!("Sending message");
10901090
}
10911091
// send the stream termination
10921092
receiver.send_response(
10931093
peer_id,
10941094
inbound_request_id,
10951095
Response::DataColumnsByRoot(None),
10961096
);
1097-
tracing::info!("Send stream term");
1097+
info!("Send stream term");
10981098
}
10991099
}
11001100
e => {
1101-
tracing::info!(?e, "Got event");
1101+
info!(?e, "Got event");
11021102
} // Ignore other events
11031103
}
11041104
}
@@ -1179,7 +1179,7 @@ fn test_tcp_columns_by_range_chunked_rpc() {
11791179
loop {
11801180
match sender.next_event().await {
11811181
NetworkEvent::PeerConnectedOutgoing(peer_id) => {
1182-
tracing::info!("Sending RPC");
1182+
info!("Sending RPC");
11831183
sender
11841184
.send_request(peer_id, AppRequestId::Router, rpc_request.clone())
11851185
.unwrap();
@@ -1192,7 +1192,7 @@ fn test_tcp_columns_by_range_chunked_rpc() {
11921192
Response::DataColumnsByRange(Some(sidecar)) => {
11931193
assert_eq!(sidecar, data_column.clone());
11941194
messages_received += 1;
1195-
tracing::info!("Chunk received");
1195+
info!("Chunk received");
11961196
}
11971197
Response::DataColumnsByRange(None) => {
11981198
// should be exactly messages_to_send
@@ -1219,23 +1219,23 @@ fn test_tcp_columns_by_range_chunked_rpc() {
12191219
} => {
12201220
if request_type == rpc_request {
12211221
// send the response
1222-
tracing::info!("Receiver got request");
1222+
info!("Receiver got request");
12231223

12241224
for _ in 0..messages_to_send {
12251225
receiver.send_response(
12261226
peer_id,
12271227
inbound_request_id,
12281228
rpc_response.clone(),
12291229
);
1230-
tracing::info!("Sending message");
1230+
info!("Sending message");
12311231
}
12321232
// send the stream termination
12331233
receiver.send_response(
12341234
peer_id,
12351235
inbound_request_id,
12361236
Response::DataColumnsByRange(None),
12371237
);
1238-
tracing::info!("Send stream term");
1238+
info!("Send stream term");
12391239
}
12401240
}
12411241
_ => {} // Ignore other events

beacon_node/network/src/sync/backfill_sync/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -346,7 +346,7 @@ impl<T: BeaconChainTypes> BackFillSync<T> {
346346
}
347347
}
348348
CouplingError::BlobPeerFailure(msg) => {
349-
tracing::debug!(?batch_id, msg, "Blob peer failure");
349+
debug!(?batch_id, msg, "Blob peer failure");
350350
}
351351
CouplingError::InternalError(msg) => {
352352
error!(?batch_id, msg, "Block components coupling internal error");

beacon_node/network/src/sync/block_sidecar_coupling.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@ impl<E: EthSpec> RangeBlockComponentsRequest<E> {
356356
// we request the data from.
357357
// If there are duplicated indices, its likely a peer sending us the same index multiple times.
358358
// However we can still proceed even if there are extra columns, just log an error.
359-
tracing::debug!(?block_root, ?index, "Repeated column for block_root");
359+
debug!(?block_root, ?index, "Repeated column for block_root");
360360
continue;
361361
}
362362
}
@@ -407,7 +407,7 @@ impl<E: EthSpec> RangeBlockComponentsRequest<E> {
407407
if !data_columns_by_index.is_empty() {
408408
let remaining_indices = data_columns_by_index.keys().collect::<Vec<_>>();
409409
// log the error but don't return an error, we can still progress with extra columns.
410-
tracing::debug!(
410+
debug!(
411411
?block_root,
412412
?remaining_indices,
413413
"Not all columns consumed for block"
@@ -427,7 +427,7 @@ impl<E: EthSpec> RangeBlockComponentsRequest<E> {
427427
let remaining_roots = data_columns_by_block.keys().collect::<Vec<_>>();
428428
// log the error but don't return an error, we can still progress with responses.
429429
// this is most likely an internal error with overrequesting or a client bug.
430-
tracing::debug!(?remaining_roots, "Not all columns consumed for block");
430+
debug!(?remaining_roots, "Not all columns consumed for block");
431431
}
432432

433433
Ok(rpc_blocks)

beacon_node/network/src/sync/range_sync/chain.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -942,10 +942,10 @@ impl<T: BeaconChainTypes> SyncingChain<T> {
942942
}
943943
}
944944
CouplingError::BlobPeerFailure(msg) => {
945-
tracing::debug!(?batch_id, msg, "Blob peer failure");
945+
debug!(?batch_id, msg, "Blob peer failure");
946946
}
947947
CouplingError::InternalError(msg) => {
948-
tracing::error!(?batch_id, msg, "Block components coupling internal error");
948+
error!(?batch_id, msg, "Block components coupling internal error");
949949
}
950950
}
951951
}

boot_node/src/config.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ use ssz::Encode;
1414
use std::net::{SocketAddrV4, SocketAddrV6};
1515
use std::time::Duration;
1616
use std::{marker::PhantomData, path::PathBuf};
17+
use tracing::{info, warn};
1718
use types::EthSpec;
1819

1920
/// A set of configuration parameters for the bootnode, established from CLI arguments.
@@ -117,15 +118,15 @@ impl<E: EthSpec> BootNodeConfig<E> {
117118
let genesis_state_root = genesis_state
118119
.canonical_root()
119120
.map_err(|e| format!("Error hashing genesis state: {e:?}"))?;
120-
tracing::info!(root = ?genesis_state_root, "Genesis state found");
121+
info!(root = ?genesis_state_root, "Genesis state found");
121122
let enr_fork = spec.enr_fork_id::<E>(
122123
types::Slot::from(0u64),
123124
genesis_state.genesis_validators_root(),
124125
);
125126

126127
Some(enr_fork.as_ssz_bytes())
127128
} else {
128-
tracing::warn!("No genesis state provided. No Eth2 field added to the ENR");
129+
warn!("No genesis state provided. No Eth2 field added to the ENR");
129130
None
130131
}
131132
};

lighthouse/src/main.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ use std::path::PathBuf;
2828
use std::process::exit;
2929
use std::sync::LazyLock;
3030
use task_executor::ShutdownReason;
31-
use tracing::{Level, info};
31+
use tracing::{Level, info, warn};
3232
use tracing_subscriber::{Layer, filter::EnvFilter, layer::SubscriberExt, util::SubscriberInitExt};
3333
use types::{EthSpec, EthSpecId};
3434
use validator_client::ProductionValidatorClient;
@@ -730,7 +730,7 @@ fn run<E: EthSpec>(
730730

731731
#[cfg(all(feature = "modern", target_arch = "x86_64"))]
732732
if !std::is_x86_feature_detected!("adx") {
733-
tracing::warn!(
733+
warn!(
734734
advice = "If you get a SIGILL, please try Lighthouse portable build",
735735
"CPU seems incompatible with optimized Lighthouse build"
736736
);

0 commit comments

Comments
 (0)