Skip to content

[Feature] Support for synchronous use. #207

@dabrahams

Description

@dabrahams

I learned recently if you Foundation.Process.waitUntilExit without first draining the standard output and error streams the system can deadlock, because it refuses to allow more data to be streamed out of the child process when its output buffers become full. I don't see any code for handling that situation here.
Here's an example of how it's done. The number of examples of doing this wrong out there are astounding. I know the new hotness is to await everything but I have synchronous code that really does need to block until another process completes, and I'd rather use an off-the-shelf package than repeat my own code. It would be great if this package could provide an answer for these situations, but I don't see one.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions