Skip to content

Commit

Permalink
Set progressbar to 0 initially to remove gap between running and prog…
Browse files Browse the repository at this point in the history
…ressbar actually showing. Remove debug statements from lsf example
  • Loading branch information
BradenEverson committed Sep 6, 2024
1 parent c0d411d commit f593806
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
5 changes: 1 addition & 4 deletions crankshaft/examples/lsf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,7 @@ async fn main() {
.unwrap();

let receivers = (0..1000)
.map(|i| {
println!("Submitting task number: {}", i + 1);
engine.submit(task.clone()).callback
})
.map(|_| engine.submit(task.clone()).callback)
.collect::<Vec<_>>();

engine.run().await;
Expand Down
1 change: 1 addition & 0 deletions crankshaft/src/engine.rs
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ impl Engine {
);

let mut count = 1;
task_completion_bar.inc(0);

while let Some(()) = self.runner.tasks.next().await {
task_completion_bar.set_message(format!("task #{}", count));
Expand Down

0 comments on commit f593806

Please sign in to comment.