-
-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Console still doesn't quite work with Ractors #55
Comments
Thanks, I'll take a look. |
Do you have any way to reproduce the error? I couldn't figure out how to reproduce it. |
I managed to make a similar reproduction:
Any time |
One thing I can suggest is don't share |
My guess as to why the frozen error occurs is when objects are sent over as messages between ractors, ruby implicitly freezes things that can be frozen (it even does this recursively). The IO object is probably being frozen as Console is being passed between ractors. So, this is more so a limitation with Ractor messages than with Console. In case other people also encounter this challenge, I'll briefly explain here what I did. To work around this limitation, I made it so that there is one "logger" ractor that actually holds on to the Here's the code for what I do. I just include the module everywhere where |
The |
I really appreciate the quick response with #54 , but it still doesn't seem to be fully compatible with Ractors.
I'm still running into an error with my architecture
'write': can't modify frozen IO: #<IO:<STDERR>> (FrozenError)
The full stack trace is
.../console/terminal/logger.rb:116 in call .../console/filter.rb:148 in call .../console/filger.rb:40 in block (3 levels) in []
and my architecture can be found here
The text was updated successfully, but these errors were encountered: