Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Ambiguous StackOverflow Exceptions: JRuby or Programmer Bug? #4783
It's not clear to me whether these traces are indicative of programmer error or a JRuby bug; if the traces are due to programmer error, it would be ideal to have a useful stack trace that mentions Ruby code.
Long stacktraces that only mention JRuby internals. An example trace (redacted because it's so long; full captured trace: https://gist.github.com/aryeh-looker/0288adbbafb8c40b24ce18a55748d6b4) — I get a lot of these in my application, but have been unable to consistently reproduce the problem:
They could be a problem in the Ruby code you're running or they could be a problem in JRuby. A quick glance at your trace makes me think it's probably a JRuby bug.
CompilerIRBlockBody's next target should be the jitted version of that block, which would show up with a Ruby line number. Instead, it goes straight to another call site that calls the same method with the same block and it starts over again.
I see also you are running JRuby 9.1.8, which is several months old. There's a very good chance this has been fixed in more recent JRuby versions. Could you try updating and see if the problem goes away before we dig deeper?
There's really no bug here.
If a stack overflow happens, we may rewrite it as a Ruby exception...but in both cases we consider it a fatal, unrecoverable error. We also are not generally in the habit of rewriting every Java exception that passes through Ruby, so you may see Java internals in this case.