bazel-xcode / PodToBUILD

An easy way to integrate CocoaPods into Bazel
Apache License 2.0
322 stars 69 forks source link

Have shell use `waitUntilExit` instead of `CFRunLoopRun` #116

Closed FuegoFro closed 4 years ago

FuegoFro commented 4 years ago

This changes how we run subprocesses to wait for the subprocesses with process.waitUntilExit() rather than relying on NotificationCenter to deliver a process terminated exception. I ran into cases where this notification wasn't being delivered even when the process had exited (I'm not sure why). This does have the downside that if the process ignores SIGTERM we'll hang, but it seems reasonable safe to assume processes we launch will be well behaved and terminate upon getting a SIGTERM. This also attempts to clean up the process running code to be a bit easier to read.

jerrymarino commented 4 years ago

Thanks for the PR @FuegoFro - I've also been hitting a few issues on Catalina with this.