We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d066a23 commit 749b2f4Copy full SHA for 749b2f4
src/tools/opt-dist/src/training.rs
@@ -236,11 +236,9 @@ pub fn gather_bolt_profiles(
236
log::info!("Profile file count: {}", profiles.len());
237
238
// Delete the gathered profiles
239
- for profile in glob::glob(&format!("{profile_prefix}*"))?.into_iter() {
240
- if let Ok(profile) = profile {
241
- if let Err(error) = std::fs::remove_file(&profile) {
242
- log::error!("Cannot delete BOLT profile {}: {error:?}", profile.display());
243
- }
+ for profile in glob::glob(&format!("{profile_prefix}*"))?.flatten() {
+ if let Err(error) = std::fs::remove_file(&profile) {
+ log::error!("Cannot delete BOLT profile {}: {error:?}", profile.display());
244
}
245
246
0 commit comments