From 653d08c80167477f4011cdb157af9ecbaeb1504a Mon Sep 17 00:00:00 2001 From: neon_arch Date: Sat, 5 Aug 2023 19:16:27 +0300 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=A7=20chore:=20fix=20link=20in=20the?= =?UTF-8?q?=20logs=20&=20add=20logs=20for=20engine=20error=20(#170)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/bin/websurfx.rs | 2 +- src/config/parser.rs | 2 +- src/results/aggregator.rs | 2 ++ 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/bin/websurfx.rs b/src/bin/websurfx.rs index b4b989e..6807749 100644 --- a/src/bin/websurfx.rs +++ b/src/bin/websurfx.rs @@ -24,8 +24,8 @@ async fn main() -> std::io::Result<()> { ); log::info!( "Open http://{}:{}/ in your browser", + config.binding_ip, config.port, - config.binding_ip ); let listener = TcpListener::bind((config.binding_ip.clone(), config.port))?; diff --git a/src/config/parser.rs b/src/config/parser.rs index 33421b0..201e579 100644 --- a/src/config/parser.rs +++ b/src/config/parser.rs @@ -98,7 +98,7 @@ impl Config { let threads: u8 = if parsed_threads == 0 { let total_num_of_threads: usize = available_parallelism()?.get() / 2; log::error!("Config Error: The value of `threads` option should be a non zero positive integer"); - log::info!("Falling back to using {} threads", total_num_of_threads); + log::error!("Falling back to using {} threads", total_num_of_threads); total_num_of_threads as u8 } else { parsed_threads diff --git a/src/results/aggregator.rs b/src/results/aggregator.rs index b8d7346..4ffaaf5 100644 --- a/src/results/aggregator.rs +++ b/src/results/aggregator.rs @@ -144,6 +144,7 @@ pub async fn aggregate( initial = false } Err(error_type) => { + log::error!("Engine Error: {:?}", error_type); engine_errors_info.push(EngineErrorInfo::new( error_type.downcast_ref::().unwrap(), upstream_search_engines[counter].clone(), @@ -172,6 +173,7 @@ pub async fn aggregate( counter += 1 } Err(error_type) => { + log::error!("Engine Error: {:?}", error_type); engine_errors_info.push(EngineErrorInfo::new( error_type.downcast_ref::().unwrap(), upstream_search_engines[counter].clone(),