IO.select does not report TCP out-of-band data as priority readiness
Maintainer thường phản hồi trong vòng 2 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Ít trao đổi
- Lĩnh vực
- networking
Hướng nghiên cứu
Start by running the reproduction script on JRuby to confirm the priority array comes back nil after Socket::MSG_OOB is sent. The payload does not name the JRuby source files that implement IO.select, so locate that code first. The fix needs to make a TCP urgent (OOB) byte mark the socket as priority-ready. Done means the script prints priority: true and exits 0, and the io-event IO::PRIORITY test can stop being skipped on JRuby.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Environment
jruby 10.1.0.0 (4.0.0) 2026-04-20 32f988b78c OpenJDK 64-Bit Server VM 21.0.11 on 21.0.11 +indy +jit [arm64-darwin]
Compared with:
ruby 4.0.5 (2026-05-20 revision 64336ffd0e) +PRISM [arm64-darwin24]
Reproduction
# frozen_string_literal: true
require "socket"
server = TCPServer.new("127.0.0.1", 0)
client = TCPSocket.new("127.0.0.1", server.addr[1])
socket = server.accept
begin
client.send("!", Socket::MSG_OOB)
readable, writable, priority = IO.select(nil, nil, [socket], 1)
puts RUBY_DESCRIPTION
puts "priority: #{priority&.include?(socket).inspect}"
unless priority&.include?(socket)
warn "Expected socket to be reported as priority-ready."
exit 1
end
ensure
socket&.close
client&.close
server&.close
end
Expected behavior
After sending TCP out-of-band data with Socket::MSG_OOB, IO.select(nil, nil, [socket], timeout) should report the socket in the priority result array.
CRuby reports:
ruby 4.0.5 (2026-05-20 revision 64336ffd0e) +PRISM [arm64-darwin24]
priority: true
Actual behavior
JRuby times out without reporting priority readiness:
jruby 10.1.0.0 (4.0.0) 2026-04-20 32f988b78c OpenJDK 64-Bit Server VM 21.0.11 on 21.0.11 +indy +jit [arm64-darwin]
priority: nil
Expected socket to be reported as priority-ready.
Context
This came up while enabling JRuby support in io-event. IO::Event::Selector::Select supports IO::PRIORITY using Ruby's IO.select priority array. The corresponding test passes on CRuby but has to be skipped on JRuby because the priority event is not reported.
- Ngôn ngữ chính
- Ruby
- Star
- 3.9k
- Fork
- 951
- Merge trung bình
- 2 ngày 21 giờ
- Pull request đã merge (30 ngày)
- 75
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của jruby/jruby
-
jrubyc-compiled code with an array pattern fails to load (NullPointerException reading persisted IR)Có thể đã có người làm @sferik đã nhận 1 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
Maintainer thường phản hồi trong vòng 2 ngày
-
ffi stdlib
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
jruby/jruby#4863 · 9 bình luận ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Binding#local_variable_get fails inside a block in a for loopCó thể đã có người làm @sferik đã nhận hôm nay. Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 22/100
Maintainer thường phản hồi trong vòng 2 ngày
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
ossf/best-practices-badge#3081 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
documentation
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
NatLabRockies/OpenStudio-HPXML#2284 ·
-
aikido security:critical
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
dequelabs/axe-core-gems#532 ·
-
"Audio Effects" example too oldĐang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 67/100
ossia/score-docs#97 · 1 bình luận ·
-
print_table with indent and truncate lets lines run up to indent characters past the widthCó thể đã có người làm @sebxt đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100