[#105450] [Ruby master Feature#18228] Add a `timeout` option to `IO.copy_stream` — "byroot (Jean Boussier)" <noreply@...>
Issue #18228 has been reported by byroot (Jean Boussier).
11 messages
2021/09/27
[ruby-core:105435] [Ruby master Feature#17369] Introduce non-blocking `Process.wait`, `Kernel.system` and related methods.
From:
"ioquatix (Samuel Williams)" <noreply@...>
Date:
2021-09-27 04:01:32 UTC
List:
ruby-core #105435
Issue #17369 has been updated by ioquatix (Samuel Williams). The implementation is completed. However, some parts are still pretty messy, including leaking `$?` process status. We need to make `$?` fiber local. However this might cause some issues in existing code. Should we consider to deprecate `$?`? ---------------------------------------- Feature #17369: Introduce non-blocking `Process.wait`, `Kernel.system` and related methods. https://bugs.ruby-lang.org/issues/17369#change-93882 * Author: ioquatix (Samuel Williams) * Status: Assigned * Priority: Normal * Assignee: ioquatix (Samuel Williams) ---------------------------------------- https://github.com/ruby/ruby/pull/3853 This PR introduces optional hooks to the scheduler interface for handling `Process.wait`, `Kernel.system` and other related methods (`waitpid`, `wait2`, etc). It funnels all methods through a new interface `Process::Status.wait` which is almost identical to `Process.wait` except for several key differences: - The return value is a single instance of `Process::Status`. - It does not set thread local `$?`. This is necessary for keeping the scheduler interface simple (and side effects are generally bad anyway). -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>