Bug #18443


IO read/write/wait hook bug fixes.

Added by ioquatix (Samuel Williams) 6 months ago. Updated 5 months ago.

Target version:


After testing Ruby 3.1.0 extensively, I found some obscure bugs which should be fixed. This should be back ported to 3.1.1 ASAP.

  • console.c incorrect rb_io_wait argument.
  • rb_read_internal incorrect logic when handling partial non-blocking reads in io.c.
  • Prefer wait_readable rather than in irb implementation.

Please see for details.

Actions #1

Updated by nagachika (Tomoyuki Chikanaga) 6 months ago

  • Backport changed from 2.6: UNKNOWN, 2.7: UNKNOWN, 3.0: UNKNOWN, 3.1: UNKNOWN to 2.6: DONTNEED, 2.7: DONTNEED, 3.0: DONTNEED, 3.1: REQUIRED
  • Status changed from Open to Closed

Updated by nagachika (Tomoyuki Chikanaga) 5 months ago

I have confirmed the PR contains the two whole backports and a partial backport from master branch.

I think e4cd319f3d6560b76dbc1c7e89aa4d790a2d1e43 should be backported. @naruse (Yui NARUSE) can I backport it?

The others are changesets for default gems stdlibs (irb and io-console).
I prefer to sync released version from upstream for default gems.

io-console-0.5.11.gem was released with the corresponding commits. I think these changesets are okey to backport. f27eb8148f5a72bbacfebfecc7de9305471bb5c9, d5836db1b398a7936b0461b3011db66f6cc8c490, d75f7078c831d45ab5ba2fae4fbb308d01a21e46.

irb was not released yet with the changeset @aycabta (aycabta .), do you have any plan to release new version of irb?

Updated by naruse (Yui NARUSE) 5 months ago

  • Backport changed from 2.6: DONTNEED, 2.7: DONTNEED, 3.0: DONTNEED, 3.1: REQUIRED to 2.6: DONTNEED, 2.7: DONTNEED, 3.0: DONTNEED, 3.1: DONE

ruby_3_1 cd4aae430da8303dac9f1be2d1e1b7ce1bc8a458 merged revision(s) f27eb8148f5a72bbacfebfecc7de9305471bb5c9,d75f7078c831d45ab5ba2fae4fbb308d01a21e46,d5836db1b398a7936b0461b3011db66f6cc8c490.


Also available in: Atom PDF