Skip to content

Commit 9860966

Browse files
committed
notifications: log directly when looking for toolchains
1 parent 5424877 commit 9860966

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

src/config.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ use anyhow::{Context, Result, anyhow, bail};
88
use serde::Deserialize;
99
use thiserror::Error as ThisError;
1010
use tokio_stream::StreamExt;
11-
use tracing::{error, info, trace};
11+
use tracing::{debug, error, info, trace};
1212

1313
use crate::dist::AutoInstallMode;
1414
use crate::{
@@ -815,7 +815,7 @@ impl<'a> Cfg<'a> {
815815
force_non_host,
816816
)?;
817817
if verbose {
818-
(self.notify_handler)(Notification::LookingForToolchain(toolchain));
818+
debug!("looking for installed toolchain {toolchain}");
819819
}
820820
let components: Vec<_> = components.iter().map(AsRef::as_ref).collect();
821821
let targets: Vec<_> = targets.iter().map(AsRef::as_ref).collect();

src/notifications.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ pub(crate) enum Notification<'a> {
2626
/// member, but the notification callback is already narrowed to
2727
/// utils::notifications by the time tar unpacking is called.
2828
SetDefaultBufferSize(usize),
29-
LookingForToolchain(&'a ToolchainDesc),
3029
ToolchainDirectory(&'a Path),
3130
UpdatingToolchain(&'a str),
3231
InstallingToolchain(&'a str),
@@ -59,7 +58,6 @@ impl Notification<'_> {
5958
| DownloadFinished(_)
6059
| DownloadFailed(_) => NotificationLevel::Debug,
6160
ToolchainDirectory(_)
62-
| LookingForToolchain(_)
6361
| InstallingToolchain(_)
6462
| UpdatingToolchain(_)
6563
| ReadMetadataVersion(_)
@@ -98,7 +96,6 @@ impl Display for Notification<'_> {
9896
DownloadDataReceived(data, _) => write!(f, "received some data of size {}", data.len()),
9997
DownloadFinished(_) => write!(f, "download finished"),
10098
DownloadFailed(_) => write!(f, "download failed"),
101-
LookingForToolchain(name) => write!(f, "looking for installed toolchain '{name}'"),
10299
ToolchainDirectory(path) => write!(f, "toolchain directory: '{}'", path.display()),
103100
UpdatingToolchain(name) => write!(f, "updating existing install for '{name}'"),
104101
InstallingToolchain(name) => write!(f, "installing toolchain '{name}'"),

0 commit comments

Comments
 (0)