adhearsion / blather

XMPP/Jabber Library and DSL for Ruby written on EventMachine and Nokogiri.
adhearsion.com/blather
Other
557 stars 89 forks source link

`synchronize': can't be called from trap context (ThreadError) #146

Open paradisaeidae opened 9 years ago

paradisaeidae commented 9 years ago

From this: https://github.com/ConradIrwin/pry-rescue/issues/52 (zach) " ...I found what seems to be the root cause, which is that Ruby has a very limited ability to perform I/O (in this case, apparently including reading files via require) inside signal handlers in Ruby 2.0. In 1.9.x performing such actions could cause deadlock, so in 2.0 they are simply not allowed. Thanks to @mperham I was able to pick up on this quickly, since he wrote up his experience encountering this in...."

Ref: https://bugs.ruby-lang.org/issues/7648

Some refactoring for someone smarter than myself.