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

IOException is not propagated #86

Closed
chavolla opened this issue May 9, 2022 · 1 comment
Closed

IOException is not propagated #86

chavolla opened this issue May 9, 2022 · 1 comment

Comments

@chavolla
Copy link

chavolla commented May 9, 2022

} catch (IOException error) {
String message = String.format("file open failure {file=%s}", config.getFile());
throw new RuntimeException(message);
}

If an error happens while opening the file the IOException is ignored just a generic Runtime Exception is thrown. The original exception should be added as the inner cause for the Runtime Exception.

 throw new RuntimeException(message, error);

or at least log the IOException

@vy
Copy link
Owner

vy commented May 9, 2022

@chavolla, thanks so much for the heads up. I've fixed the issue and released 0.9.5.

@vy vy closed this as completed May 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants