-
-
Notifications
You must be signed in to change notification settings - Fork 925
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
Issue requiring 'yaml' on SwingWorker on jruby 9.0.0.0.rc2 #3149
Comments
This was fixed when we reverted our context class loader change. I can run your script with HEAD. |
when I run the test.rb on current HEAD I see all kind of stacktrace including the reported one. and the jar with the missing class is loaded via JRuby.runtime.jruby_class_loader not with thread-context-classloader. I am on ubuntu 15.04 with OpenJDK Runtime Environment (IcedTea 2.5.5) (7u79-2.5.5-0ubuntu1) |
This is super weird:
I positively did not rebuild JRuby between the two but I cannot get this script to run past the very first time I tried :| |
:) |
I changed from Java 1.7 to 1.8 and it worked....once. |
I can add to the mistery: the first two times I got:
but never again |
Tip of the hat to @headius. This is not technically a bug. Add a 'sleep' or 'gets' at the end of the script to prevent Main thread from trying to exit and shutdown. There may be some special swing way of preventing main thread for leaving? |
Shouldn't be the open JFrame enough to keep the Main thread? |
@blerins Swing does not block the main thread and the actual rendering happens in Swing thread so the script falls off the end and then script finalization happens. In the occasional cases where the script does not error invokeLater triggers and the Java thread executes Ruby code which then we 'adopt' the Java thread by virtue of it executing Ruby. If it adopts this thread in time then when we fall off the main script we still have a running Ruby thread so finalization does not start. |
Hummm, so I need to wait the thread to execute before reaching the end of the script. Something like that?:
That seem to work always. |
@blerins yeah that seems reasonable to me since it guarantees that executes. |
Hi
I have an issue requiring some libraries inside a SwingWorker. Here is a broken example:
test.rb
Execution with JRuby 9 and JRuby 1.7:
Thanks
The text was updated successfully, but these errors were encountered: