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

ConfigurationLoader needs to share context of execution during exception wrap #11753

Open
romani opened this issue Jun 19, 2022 · 0 comments
Open

Comments

@romani
Copy link
Member

romani commented Jun 19, 2022

detected at https://github.com/checkstyle/checkstyle/pull/11701/files

catch (final CheckstyleException ex) {
    // -@cs[IllegalInstantiation] SAXException is in the overriden
    // method signature
    throw new SAXException(ex);
}

should be something like:

catch (final CheckstyleException ex) {
    // -@cs[IllegalInstantiation] SAXException is in the overridden
    // method signature
    throw new SAXException("Exception during replacing values in property " + attributes.getValue(VALUE), ex);
}

Rationale: we need to share context of execution during exception wrap.
https://docs.oracle.com/javase/7/docs/api/org/xml/sax/SAXException.html#SAXException(java.lang.String,%20java.lang.Exception)

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

1 participant