Prerequisites
Steps to reproduce
Note: This is a regression from Windows PowerShell and affects both the Minimal and Classic views (selectable via $PSStyle.Progress.View)
$arr = 1..10
$arr |
ForEach-Object {
[int] $percentComplete = ($_ / $arr.Count) * 100
Write-Progress -Activity Test -Status "$percentComplete% complete" -PercentComplete $percentComplete
# !! Without sleeping for a while, the progress display stops updating after the FIRST call.
# Start-Sleep -Milliseconds 200
}
Start-Sleep 5 # Ensure that the progress bar stays visible for a while.
Expected behavior
The progress bar should show 100% and stay visible for 5 seconds.
Actual behavior
The progress bar shows 10% - that is, only the first call took effect.
Error details
No response
Environment data
Visuals
No response
Prerequisites
Steps to reproduce
Note: This is a regression from Windows PowerShell and affects both the
MinimalandClassicviews (selectable via$PSStyle.Progress.View)Expected behavior
The progress bar should show 100% and stay visible for 5 seconds.
Actual behavior
The progress bar shows 10% - that is, only the first call took effect.
Error details
No response
Environment data
Visuals
No response