Open thesmart opened 7 years ago
Seems like a legit issue.
Might be an issue with Celluloid, not the bot or client lib. If celluloid switched to a trapped run loop, the mutex in their UUID class could occur outside the trap Proc and thus avoid the ThreadError.
I'm having this issue as well.
Starting the bot using
celluloid-io
is not compatible with signal trapping. I discovered this when using Puma to run a threaded Sinatra server. Sinatra has code that traps exit signals so thatctrl+c
can shutdown the server.After Sinatra shuts down,
slack-ruby-bot
gem callsstop!
which results in anThreadError
deep insidecelluloid
:I believe that
slack-ruby-bot
is usingSignal.trap
improperly, and maybe needs to use Celluloid's specialtrap_exit
method to be notified when tostop!
There may be a similar handler viacelluloid-io
such thatSignal.trap
does not need to be used directly.https://github.com/celluloid/celluloid/blob/41ff4713dac7d40b24ed6cc8906e20c23c5c6de3/spec/shared/actor_examples.rb#L582