@@ -10,7 +10,7 @@ use anyhow::{Context, Result, anyhow, bail};
10
10
use futures_util:: stream:: StreamExt ;
11
11
use std:: sync:: Arc ;
12
12
use tokio:: sync:: Semaphore ;
13
- use tracing:: info;
13
+ use tracing:: { info, warn } ;
14
14
use url:: Url ;
15
15
16
16
use crate :: dist:: component:: {
@@ -229,13 +229,7 @@ impl Manifestation {
229
229
component. target . as_ref ( ) ,
230
230
) ) ;
231
231
232
- tx = self . uninstall_component (
233
- component,
234
- new_manifest,
235
- tx,
236
- & download_cfg. notify_handler ,
237
- download_cfg. process ,
238
- ) ?;
232
+ tx = self . uninstall_component ( component, new_manifest, tx, download_cfg. process ) ?;
239
233
}
240
234
241
235
// Install components
@@ -313,7 +307,6 @@ impl Manifestation {
313
307
& self ,
314
308
manifest : & Manifest ,
315
309
tmp_cx : & temp:: Context ,
316
- notify_handler : & dyn Fn ( Notification < ' _ > ) ,
317
310
process : & Process ,
318
311
) -> Result < ( ) > {
319
312
let prefix = self . installation . prefix ( ) ;
@@ -331,7 +324,7 @@ impl Manifestation {
331
324
tx. remove_file ( "dist config" , rel_config_path) ?;
332
325
333
326
for component in config. components {
334
- tx = self . uninstall_component ( & component, manifest, tx, notify_handler , process) ?;
327
+ tx = self . uninstall_component ( & component, manifest, tx, process) ?;
335
328
}
336
329
tx. commit ( ) ;
337
330
@@ -343,7 +336,6 @@ impl Manifestation {
343
336
component : & Component ,
344
337
manifest : & Manifest ,
345
338
mut tx : Transaction < ' a > ,
346
- notify_handler : & dyn Fn ( Notification < ' _ > ) ,
347
339
process : & Process ,
348
340
) -> Result < Transaction < ' a > > {
349
341
// For historical reasons, the rust-installer component
@@ -357,9 +349,10 @@ impl Manifestation {
357
349
} else if let Some ( c) = self . installation . find ( short_name) ? {
358
350
tx = c. uninstall ( tx, process) ?;
359
351
} else {
360
- notify_handler ( Notification :: MissingInstalledComponent (
361
- & component. short_name ( manifest) ,
362
- ) ) ;
352
+ warn ! (
353
+ component = %component. short_name( manifest) ,
354
+ "component not found during uninstall"
355
+ ) ;
363
356
}
364
357
365
358
Ok ( tx)
0 commit comments