Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 941411 - dev-ruby/io-event-1.6.5 and dev-ruby/io-event-1.5.1: tests fail
Summary: dev-ruby/io-event-1.6.5 and dev-ruby/io-event-1.5.1: tests fail
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal
Assignee: Gentoo Ruby Team
URL:
Whiteboard:
Keywords: PATCH, PullRequest, TESTFAILURE
Depends on:
Blocks: 940984
  Show dependency tree
 
Reported: 2024-10-12 16:02 UTC by Gabi Falk
Modified: 2024-12-01 12:37 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (emerge--info,5.23 KB, text/plain)
2024-10-12 16:02 UTC, Gabi Falk
Details
emerge --info =dev-ruby/io-event-1.6.5 (emerge--info-io-event-1.6.5,5.33 KB, text/plain)
2024-10-12 16:03 UTC, Gabi Falk
Details
emerge --info =dev-ruby/io-event-1.5.1 (emerge--info-io-event-1.5.1,5.33 KB, text/plain)
2024-10-12 16:04 UTC, Gabi Falk
Details
/var/tmp/portage/dev-ruby/io-event-1.6.5/temp/build.log (io-event-1.6.5-build.log,139.07 KB, text/plain)
2024-10-12 16:04 UTC, Gabi Falk
Details
/var/tmp/portage/dev-ruby/io-event-1.5.1/temp/build.log (io-event-1.5.1-build.log,125.33 KB, text/plain)
2024-10-12 16:05 UTC, Gabi Falk
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gabi Falk 2024-10-12 16:02:34 UTC
Created attachment 905344 [details]
emerge --info

Both the stable version 1.5.1 and the to-be-stable (bug#940984) 1.6.5 fail tests:

32 passed 3 skipped 145 errored out of 180 total (1174 assertions)
🏁 Finished in 284.1ms; 4132.733 assertions per second.
🐇 No slow tests found! Well done!

🔥 Errored assertions:
describe IO::Event::Selector::Select it behaves like buffered io with a pipe it can read using a buffer test/io/event/selector/buffered_io.rb:Select:95:19
        expect 128 to
                be == 128
                        ✓ assertion passed test/io/event/selector/buffered_io.rb:22
        expect 64 to
                be == 64
                        ✓ assertion passed test/io/event/selector/buffered_io.rb:27
        expect 1 to
                be >= 1
                        ✓ assertion passed test/io/event/selector/buffered_io.rb:33
        ⚠ ArgumentError: wrong number of arguments (given 1, expected 0)
[...]

I tried doing:
$ mkdir -p /etc/portage/patches/dev-ruby/io-event
$ curl https://github.com/socketry/io-event/commit/c2ffc28e97a08534e003eaf25abfa35279274263.patch >/etc/portage/patches/dev-ruby/io-event/c2ffc28e97a08534e003eaf25abfa35279274263.patch

... it fixes the issue for both versions.

$ git describe --tag c2ffc28e97a08534e003eaf25abfa35279274263
v1.6.5-2-gc2ffc28

so the newer versions are fixed upstream.
Comment 1 Gabi Falk 2024-10-12 16:03:40 UTC
Created attachment 905345 [details]
emerge --info =dev-ruby/io-event-1.6.5
Comment 2 Gabi Falk 2024-10-12 16:04:17 UTC
Created attachment 905346 [details]
emerge --info =dev-ruby/io-event-1.5.1
Comment 3 Gabi Falk 2024-10-12 16:04:40 UTC
Created attachment 905347 [details]
/var/tmp/portage/dev-ruby/io-event-1.6.5/temp/build.log
Comment 4 Gabi Falk 2024-10-12 16:05:01 UTC
Created attachment 905348 [details]
/var/tmp/portage/dev-ruby/io-event-1.5.1/temp/build.log
Comment 5 Hans de Graaff gentoo-dev Security 2024-10-13 06:55:26 UTC
With these patches applied I get core dumps on ruby 3.2. Both ruby 3.1 and 3.3 work fine.

 * Running test phase for ruby32
/var/tmp/portage/dev-ruby/io-event-1.6.5-r1/work/ruby32/io-event-1.6.5/lib/io/event/support.rb:27: warning: IO::Buffer is experimental and both the Ruby and C interface may change in the future!
/usr/lib64/ruby/gems/3.2.0/gems/sus-0.31.0/lib/sus/assertions.rb:36: [BUG] Segmentation fault at 0x0000000000000000
ruby 3.2.5 (2024-07-26 revision 31d0f1a2e7) [x86_64-linux]

-- Control frame information -----------------------------------------------
c:0005 p:---- s:0031 e:000030 CFUNC  :new
c:0004 p:0072 s:0027 e:000026 METHOD /usr/lib64/ruby/gems/3.2.0/gems/sus-0.31.0/lib/sus/assertions.rb:36 [FINISH]
c:0003 p:---- s:0013 e:000012 CFUNC  :new
c:0002 p:0022 s:0008 e:000007 BLOCK  /usr/lib64/ruby/gems/3.2.0/gems/sus-0.31.0/bin/sus-parallel:52 [FINISH]
c:0001 p:---- s:0003 e:000002 DUMMY  [FINISH]

-- Ruby level backtrace information ----------------------------------------
/usr/lib64/ruby/gems/3.2.0/gems/sus-0.31.0/bin/sus-parallel:52:in `block (2 levels) in <top (required)>'
/usr/lib64/ruby/gems/3.2.0/gems/sus-0.31.0/bin/sus-parallel:52:in `new'
/usr/lib64/ruby/gems/3.2.0/gems/sus-0.31.0/lib/sus/assertions.rb:36:in `initialize'
/usr/lib64/ruby/gems/3.2.0/gems/sus-0.31.0/lib/sus/assertions.rb:36:in `new'
Comment 6 Gabi Falk 2024-10-13 23:08:07 UTC
I tested it  with ruby 3.2.4-r1, but now I'm also seeing segfaults with ruby 3.2.5, both with and without my PR.  The upstream commit https://github.com/socketry/io-event/commit/4279fb513625d0db40c5e7966f8c9ca291a18b86 (v1.6.6~1) mentions regressions in Ruby 3.2.5; applying it fixes the segfault.

Although this is a different issue, it could be more important than the tests.
Comment 7 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-10-17 05:54:09 UTC
I'll add blocks to bug 940984 given this will end up blocking automated stablereqs.

graaff, can you handle https://bugs.gentoo.org/941411#c6 or shall I?
Comment 8 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-10-17 09:29:11 UTC
Actually, I'll handle it.
Comment 9 Larry the Git Cow gentoo-dev 2024-12-01 12:37:50 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=be34a2ecb62c1757d5f31d3534f8c897e6719a98

commit be34a2ecb62c1757d5f31d3534f8c897e6719a98
Author:     Gabi Falk <gabifalk@gmx.com>
AuthorDate: 2024-10-12 16:40:00 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-12-01 12:37:02 +0000

    dev-ruby/io-event: 1.5.1: apply upstream commit to fix the testsuite
    
    Link: https://github.com/socketry/io-event/commit/c2ffc28e97a08534e003eaf25abfa35279274263
    Closes: https://bugs.gentoo.org/941411
    Signed-off-by: Gabi Falk <gabifalk@gmx.com>
    Closes: https://github.com/gentoo/gentoo/pull/38956
    Signed-off-by: Sam James <sam@gentoo.org>

 dev-ruby/io-event/io-event-1.5.1-r1.ebuild | 40 ++++++++++++++++++++++++++++++
 1 file changed, 40 insertions(+)

Additionally, it has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=732e3c6f88d3433bf9d8e3e253680f88fbfdfe7b

commit 732e3c6f88d3433bf9d8e3e253680f88fbfdfe7b
Author:     Gabi Falk <gabifalk@gmx.com>
AuthorDate: 2024-10-12 16:40:00 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-12-01 12:37:01 +0000

    dev-ruby/io-event: 1.6.5: backport upstream commit to fix the testsuite
    
    Link: https://github.com/socketry/io-event/commit/c2ffc28e97a08534e003eaf25abfa35279274263
    Bug: https://bugs.gentoo.org/941411
    Signed-off-by: Gabi Falk <gabifalk@gmx.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 .../files/io-event-1.6.5-update-test-hooks.patch   | 157 +++++++++++++++++++++
 ...event-1.6.5.ebuild => io-event-1.6.5-r1.ebuild} |   4 +
 2 files changed, 161 insertions(+)