Skip to content
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

Backtrace set with set_backtrace is not dup'd properly in 9.2.7.0 #5738

Closed
mvz opened this issue May 19, 2019 · 2 comments

Comments

@mvz
Copy link

commented May 19, 2019

Environment

  • jruby -v: jruby 9.2.7.0 (2.5.3) 2019-04-09 8a269e3 OpenJDK 64-Bit Server VM 11.0.4+2-Debian-1 on 11.0.4+2-Debian-1 [linux-x86_64]
  • JRUBY_OPTS: --dev
  • Operating system and platform (e.g. uname -a): Linux bean 4.19.0-5-amd64 #1 SMP Debian 4.19.37-3 (2019-05-15) x86_64 GNU/Linux

Expected Behavior

Given the following ruby code:

begin
  raise
rescue => err
  err.set_backtrace ['hi']
  p err.backtrace
  p err.dup.backtrace
end

In MRI and JRuby 9.2.6.0, this prints:

["hi"]
["hi"]

Actual Behavior

In JRuby 9.2.7.0, this prints:

["hi"]
["foo.rb:2:in `<main>'"]
@headius

This comment has been minimized.

Copy link
Member

commented May 20, 2019

Nice find! Maybe I don't want to know how you found it...

@headius headius added this to the JRuby 9.2.8.0 milestone May 20, 2019

@headius headius closed this in 7a693e0 May 20, 2019

headius added a commit that referenced this issue May 20, 2019

@mvz

This comment has been minimized.

Copy link
Author

commented May 20, 2019

Thanks, @headius!

mvz added a commit to cucumber/aruba that referenced this issue Jun 12, 2019

Avoid building with JRuby 9.2.7.0
There's an issue with dup-ing an exception after its backtrace has been
set manually in JRuby 9.2.7.0. It should be resolved in 9.2.8.0 once that's
released.

See jruby/jruby#5738 for more details.

mvz added a commit to cucumber/aruba that referenced this issue Jun 15, 2019

Avoid building with JRuby 9.2.7.0
There's an issue with dup-ing an exception after its backtrace has been
set manually in JRuby 9.2.7.0. It should be resolved in 9.2.8.0 once that's
released.

See jruby/jruby#5738 for more details.

@mvz mvz referenced this issue Jun 16, 2019

Merged

Fix JRuby builds #637

1 of 1 task complete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.