diff --git a/Cargo.lock b/Cargo.lock index 4f8271ae..3e0dcff0 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1033,7 +1033,7 @@ dependencies = [ [[package]] name = "pewpew" -version = "0.5.6-beta3" +version = "0.5.6-beta4" dependencies = [ "atty 0.2.14 (registry+https://github.com/rust-lang/crates.io-index)", "base64 0.12.0 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/Cargo.toml b/Cargo.toml index 3feb9a99..e96b02ca 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "pewpew" -version = "0.5.6-beta3" +version = "0.5.6-beta4" edition = "2018" default-run = "pewpew" publish = false diff --git a/README.md b/README.md index 3d101814..ed47be85 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,7 @@ Bugfix: - Fix regression introduced in v0.5.5 where specifying a `provider` multiple times in a `provides` would only use the last specified one. - Fix bug where non-ascii characters could cause an error reading a file when using the `line` (default) `format`. - Fix bug where the `line` `format` of a file provider would incorrectly parse files with lines longer than 8KB. +- Fix issue when, under heavy load, pewpew panics with message "found a left over previous bucket". ### v0.5.5 Changes: diff --git a/src/stats.rs b/src/stats.rs index 4baabf65..3c20bcb7 100644 --- a/src/stats.rs +++ b/src/stats.rs @@ -419,7 +419,6 @@ where i } }; - self.check_current_bucket(); self.current.append(stat, index); if let Some(new_tag) = new_tag { let a = self.write_file_message(&FileMessage::Tags(new_tag)); @@ -834,16 +833,15 @@ where } join_all(futures).then(|_| Ok::<_, TestError>(())) }, - ) - .join(print_stats) - .map(|_| TestEndReason::Completed) - .or_else(move |e| test_killer.send(Err(e.clone())).then(move |_| Err(e))) - .select(test_complete.map(|e| *e).map_err(|e| (&*e).clone())) - // .map_err(|e| e.0) - // .and_then(move |(b, _)| stats2.lock().persist(console4()).map(move |_| b)) - .then(move |_| { - let mut stats = stats3.lock(); - stats.close_out_bucket(true).then(|_| Ok(())) - }); - Ok((tx, receiver)) + ); + let task = print_stats + .join(receiver) + .map(|_| TestEndReason::Completed) + .or_else(move |e| test_killer.send(Err(e.clone())).then(move |_| Err(e))) + .select(test_complete.map(|e| *e).map_err(|e| (&*e).clone())) + .then(move |_| { + let mut stats = stats3.lock(); + stats.close_out_bucket(true).then(|_| Ok(())) + }); + Ok((tx, task)) }