-
Notifications
You must be signed in to change notification settings - Fork 8.2k
Wait-Event should allow more granularity #19704
Copy link
Copy link
Open
Labels
In-PRIndicates that a PR is out for the issueIndicates that a PR is out for the issueIssue-Enhancementthe issue is more of a feature request than a bugthe issue is more of a feature request than a bugUp-for-GrabsUp-for-grabs issues are not high priorities, and may be opportunities for external contributorsUp-for-grabs issues are not high priorities, and may be opportunities for external contributors
Description
Summary of the new feature / enhancement
As a user of PowerShell events, I often find myself frustrated with the ways Wait-Event works.
Primarily this concerns the Timeout being in seconds.
That may seem like a little thing, but it has a major downside: when I'm expecting events to be quick, this makes me wait a whole second I may not need to wait.
Additionally, based off of the way the command is written, the shortest possible wait is 1/5th of a second.
Proposed technical implementation details (optional)
Wait-Event should have a -Timespan parameter that takes a particular Timespan.
Most of the internal logic should remain the same, with the exception of modifying the "floor" value, which is currently 200ms.
The floor value should instead be one tenth of the timeout.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
In-PRIndicates that a PR is out for the issueIndicates that a PR is out for the issueIssue-Enhancementthe issue is more of a feature request than a bugthe issue is more of a feature request than a bugUp-for-GrabsUp-for-grabs issues are not high priorities, and may be opportunities for external contributorsUp-for-grabs issues are not high priorities, and may be opportunities for external contributors