( env_consts: LeanList<LeanBorrowed<'_>>, )
| 3421 | let mut active = self.active.lock().unwrap(); |
| 3422 | let mut active_slow_lines = Vec::new(); |
| 3423 | if let Some(active_slow_threshold) = self.active_slow_threshold { |
| 3424 | for slot in active.iter_mut() { |
| 3425 | if let Some(check) = slot.as_mut() { |
| 3426 | let age = check.started.elapsed(); |
| 3427 | if !check.reported_active_slow && age >= active_slow_threshold { |
| 3428 | check.reported_active_slow = true; |
| 3429 | active_slow_lines.push(format!( |
| 3430 | "[rs_kernel_check] still checking {} after {:.0}s", |
| 3431 | compact_in_flight_label( |
| 3432 | &check.label, |
| 3433 | self.in_flight_label_chars |
| 3434 | ), |
| 3435 | age.as_secs_f64() |
| 3436 | )); |
| 3437 | } |
| 3438 | } |
| 3439 | } |
| 3440 | } |
| 3441 | |
| 3442 | let mut entries: Vec<_> = active |
| 3443 | .iter() |
| 3444 | .filter_map(|slot| { |
| 3445 | slot.as_ref().map(|check| (check.started, check.label.clone())) |
| 3446 | }) |
| 3447 | .collect(); |
| 3448 | entries.sort_by_key(|(started, _)| *started); |
| 3449 | let in_flight = entries |
| 3450 | .into_iter() |
| 3451 | .take(self.in_flight_limit) |
| 3452 | .map(|(started, label)| { |
| 3453 | format!( |
| 3454 | "{} ({:.0}s)", |
| 3455 | compact_in_flight_label(&label, self.in_flight_label_chars), |
| 3456 | started.elapsed().as_secs_f64() |
| 3457 | ) |
| 3458 | }) |
| 3459 | .collect::<Vec<_>>(); |
| 3460 | (in_flight, active_slow_lines) |
| 3461 | }; |
| 3462 | let active_suffix = if in_flight.is_empty() { |
| 3463 | String::new() |
| 3464 | } else { |
| 3465 | format!(" · in-flight: {}", in_flight.join(", ")) |
| 3466 | }; |
| 3467 | let mem_suffix = kernel_check_mem_suffix(Some(&self.peak_rss_mib)); |
| 3468 | |
| 3469 | self.log(&format!( |
| 3470 | "[rs_kernel_check] {done}/{} ({pct:.1}%) · {:.1}/s · elapsed {:.0}s{eta}{mem_suffix}{active_suffix}", |
| 3471 | self.total, |
| 3472 | rate, |
| 3473 | elapsed, |
| 3474 | )); |
nothing calls this directly
no test coverage detected