Skip to content

Commit

Permalink
Wait until ProgressBar worker starts
Browse files Browse the repository at this point in the history
  • Loading branch information
hschimpf committed Apr 10, 2023
1 parent 2956a69 commit c212cfb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Internals/ProgressBarWorker.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ protected function registerWorker(string $worker, int $steps = 0): void {
// update steps
$this->progressBar->setMaxSteps($steps);
}

$this->release();
}

protected function progressBarAction(string $action, array $args): void {
Expand Down
1 change: 1 addition & 0 deletions src/Internals/Runner.php
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,7 @@ protected function enableProgressBar(string $worker_id, int $steps): bool {
worker: $worker->getWorkerClass(),
steps: $steps,
));
$this->progressbar_channel->receive();

return $this->send(true);
}
Expand Down

0 comments on commit c212cfb

Please sign in to comment.