[ruby-core:113745] [Ruby master Bug#19709] `Thread.join(timeout)` hangs in fiber scheduler.
From:
"ioquatix (Samuel Williams) via ruby-core" <ruby-core@...>
Date:
2023-06-03 01:43:14 UTC
List:
ruby-core #113745
Issue #19709 has been reported by ioquatix (Samuel Williams).
----------------------------------------
Bug #19709: `Thread.join(timeout)` hangs in fiber scheduler.
https://bugs.ruby-lang.org/issues/19709
* Author: ioquatix (Samuel Williams)
* Status: Assigned
* Priority: Normal
* Assignee: ioquatix (Samuel Williams)
* Backport: 3.0: REQUIRED, 3.1: REQUIRED, 3.2: REQUIRED
----------------------------------------
Unfortunately the following script can hang:
```ruby
require_relative 'test/fiber/scheduler'
scheduler = Scheduler.new
Fiber.set_scheduler scheduler
Fiber.schedule do
thread = Thread.new{sleep}
thread.join(0.1)
end
```
The termination condition in the `thread_join` is not expressed correctly.
--
https://bugs.ruby-lang.org/
______________________________________________
ruby-core mailing list -- ruby-core@ml.ruby-lang.org
To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/