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

Don't system exit on ohai CriticalPluginFailure #8098

Merged
merged 1 commit into from
Jan 10, 2019

Conversation

joshuamiller01
Copy link
Contributor

Description

When critical ohai plugins fail, they currently cause the chef run to exit(false), which makes the chef run_exception "SystemExit: exit", which isn't very clear as to what actually went wrong.

Issues Resolved

By removing the rescue block the run fails with Ohai::Exceptions::CriticalPluginFailure, with a run_exception akin to ""Ohai::Exceptions::CriticalPluginFailure: The following Ohai plugins marked as critical failed: [:BlockDevice]. Failing Chef run."

Check List

@joshuamiller01 joshuamiller01 requested a review from a team January 6, 2019 01:11
@joshuamiller01 joshuamiller01 force-pushed the critical_ohai_plugin_failure branch from 0c99412 to be9b213 Compare January 6, 2019 01:14
@jaymzh
Copy link
Collaborator

jaymzh commented Jan 8, 2019

I approve this change in general. BUt you have some test failures.

Signed-off-by: Joshua Miller <joshmiller@fb.com>
@joshuamiller01 joshuamiller01 force-pushed the critical_ohai_plugin_failure branch from be9b213 to 44cc5ce Compare January 9, 2019 22:17
@jaymzh
Copy link
Collaborator

jaymzh commented Jan 10, 2019

@lamont - there's a ton of apt failures - doesn't seem related to the PR... am I missing something?

@jaymzh
Copy link
Collaborator

jaymzh commented Jan 10, 2019

Nevermind a few more retries did it.

👍 for me. @chef/client-maintainers - any thoughts before I merge?

@lamont-granquist
Copy link
Contributor

yeah, rescuing and swallowing the useful error to throw a meaningless one seems like something nobody would really want...

@jaymzh jaymzh merged commit 095474c into chef:master Jan 10, 2019
@joshuamiller01 joshuamiller01 deleted the critical_ohai_plugin_failure branch January 10, 2019 17:13
@lock
Copy link

lock bot commented Mar 11, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Mar 11, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants