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

Turn off thread exception reporting only if it's an available method #10900

Merged
merged 5 commits into from Nov 2, 2018

Conversation

Projects
None yet
5 participants
@busterb
Contributor

busterb commented Nov 1, 2018

Seems that Ruby 2.3.8 has issues with always turning off thread reporting on exceptions. Strange since it should already be off.

Update: Thread::report_on_exception doesn't exist in 2.3.8. The error was swallowed in our tests.

Fixes #10899.

@busterb busterb requested a review from wvu-r7 Nov 1, 2018

@wvu-r7

Looks like it's still failing. :(

@wvu-r7 wvu-r7 self-assigned this Nov 1, 2018

@wvu-r7

wvu-r7 approved these changes Nov 1, 2018

Looks good now.

Fix thread exception reporting for Ruby 2.3.8
Thread::report_on_exception doesn't exist.

@wvu-r7 wvu-r7 changed the title from only turn off thread reporting if it is already on to Turn off thread exception reporting only if it's an available method Nov 2, 2018

@bcoles

This comment has been minimized.

Contributor

bcoles commented Nov 2, 2018

Patch works as described. Resolves the issue on Ruby 2.3.0.

Perhaps it would be cleaner to instead, or additionally, check whether the method is defined?

Something like this (untested):

if Thread.method_defined?(:report_on_exception)
  # ...
@wvu-r7

This comment has been minimized.

Contributor

wvu-r7 commented Nov 2, 2018

@bcoles: Please see the linked PR. Thank you.

Fixed

@jmartin-r7 jmartin-r7 self-assigned this Nov 2, 2018

@jmartin-r7 jmartin-r7 merged commit 8372007 into rapid7:master Nov 2, 2018

2 checks passed

Metasploit Automation - Sanity Test Execution Successfully completed all tests.
Details
Metasploit Automation - Test Execution Successfully completed all tests.
Details

jmartin-r7 added a commit that referenced this pull request Nov 2, 2018

msjenkins-r7 added a commit that referenced this pull request Nov 2, 2018

@wvu-r7

This comment has been minimized.

Contributor

wvu-r7 commented Nov 2, 2018

Release Notes

This updates the supplementary stack trace fix to account for Ruby 2.3 not having the required method.

@gdavidson-r7 gdavidson-r7 added the rn-fix label Nov 6, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment