Skip to content

incompatible with ractors #53

Description

@HoneyryderChuck

currently, timeout can't be used in ractors:

Ractor.new do
  Timeout.timeout(4) do
    sleep(5)
  end
end.take
# .rubies/ruby-3.3.0/lib/ruby/3.3.0/timeout.rb:129:in `ensure_timeout_thread_created': can not access non-shareable objects in # # constant Timeout::TIMEOUT_THREAD_MUTEX by non-main ractor. (Ractor::IsolationError)
#         from .rubies/ruby-3.3.0/lib/ruby/3.3.0/timeout.rb:178:in `timeout'
#         from (irb):8:in `block in <top (required)>'

Lots of downstream dependencies rely on timeout, and this makes them unusable under ractors.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions