diff --git a/api/Cargo.toml b/api/Cargo.toml index 9f1db3f..3d8f76a 100644 --- a/api/Cargo.toml +++ b/api/Cargo.toml @@ -12,5 +12,3 @@ thiserror = "1.0.30" url = "2.2.2" urlencoding = "2.1.0" alphanumeric-sort = "1.4.3" -tracing = "0.1.29" -tracing-subscriber = "0.2.25" diff --git a/ui/Cargo.toml b/ui/Cargo.toml index 6e87b7f..66eac82 100644 --- a/ui/Cargo.toml +++ b/ui/Cargo.toml @@ -8,5 +8,3 @@ edition = "2021" api = { path = "../api" } eframe = "0.14.0" image = "0.23.14" -tracing = "0.1.29" -tracing-subscriber = "0.2.25" diff --git a/ui/src/candidates.rs b/ui/src/candidates.rs index daf9d22..9c181ae 100644 --- a/ui/src/candidates.rs +++ b/ui/src/candidates.rs @@ -260,11 +260,10 @@ impl SdkmanApp { } Err(e) => { *selected_candidate = None; - let msg = format!( - "Loading all versions for candidate '{}' failed", - candidate.name - ); - tracing::error!("{}:\n{}", msg, e) + println!( + "Loading all versions for candidate '{}' failed with {}", + candidate.name, e + ) } } } @@ -419,11 +418,10 @@ impl SdkmanApp { } Err(e) => { *selected_candidate = None; - let msg = format!( - "Loading all versions for candidate '{}' failed", - candidate_search_term + println!( + "Loading all versions for candidate '{}' failed with {}", + candidate_search_term, e ); - tracing::error!("{}:\n{}", msg, e) } } *candidate_search_dialog = false; diff --git a/ui/src/main.rs b/ui/src/main.rs index 80b7ea2..a9561b2 100644 --- a/ui/src/main.rs +++ b/ui/src/main.rs @@ -46,25 +46,24 @@ fn main() { } else if env::var("SDKMAN_DIR").is_err() { println!("sdkman is not installed!") } else { - tracing_subscriber::fmt::init(); let remote_candidates_handle = thread::spawn(|| match fetch_remote_candidates() { Ok(candidates) => { - tracing::info!("Fetched {} candidates from server", candidates.len()); + println!("Fetched {} candidates from server", candidates.len()); candidates } Err(e) => { - tracing::error!("Failed to retrieve remote candidates: {}", e); + println!("Failed to retrieve remote candidates: {}", e); Vec::new() } }); let local_candidates_handle = thread::spawn(|| match retrieve_local_candidates() { Ok(candidates) => { - tracing::info!("Found {} locally installed candidates.", candidates.len()); + println!("Found {} locally installed candidates.", candidates.len()); candidates } Err(e) => { - tracing::error!("Failed to retrieve local candidates: {}", e); + println!("Failed to retrieve local candidates: {}", e); Vec::new() } }); @@ -80,10 +79,10 @@ fn main() { run_native(Box::new(app), win_option); } (Err(_), _) => { - tracing::error!("Remote candidates retrieval thread failed."); + println!("Remote candidates retrieval thread failed."); } (_, Err(_)) => { - tracing::error!("Local candidates retrieval thread failed."); + println!("Local candidates retrieval thread failed."); } } }