You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Henri Biestro (Jira)" <ji...@apache.org> on 2021/02/02 20:58:00 UTC

[jira] [Commented] (JEXL-341) Errors needs to provide more information on caught exceptions.

    [ https://issues.apache.org/jira/browse/JEXL-341?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17277450#comment-17277450 ] 

Henri Biestro commented on JEXL-341:
------------------------------------

Same as JEXL-340, have you made any progress trying to use the code as it stands ? I'm a bit confused at how much change you expect or need. Any public method exposed from JEXL is yet another one to maintain forever so we must be absolutely convinced of the actual value this would bring. I kinda expect GUISE to handle its own errors with its own contextualised messages so you'll need error handling on your end; adding the 3 lines of logic on your required end (per JEXL-340 comment) seems a reasonable trade-off, doesn't it ?

> Errors needs to provide more information on caught exceptions.
> --------------------------------------------------------------
>
>                 Key: JEXL-341
>                 URL: https://issues.apache.org/jira/browse/JEXL-341
>             Project: Commons JEXL
>          Issue Type: Improvement
>    Affects Versions: 3.1
>            Reporter: Garret Wilson
>            Assignee: Henri Biestro
>            Priority: Trivial
>
> I have a method {{bar()}} that happens to throw a {{NullPointerException}}. A bug, of course. But when I use the following expression in JEXL:
> {noformat}foo.bar(){noformat}
> The {{JexlException.getMessage()}} result is:
> {noformat}io.guise.mesh.JexlMexlEvaluator.evaluate@1:… bar{noformat}
> This is too little information to be helpful (and too much irrelevant information— see JEXL-340). If a {{NullPointerException}} occurred during invocation of the method, it would be nice to know that. Otherwise the developer has no idea if JEXL couldn't find {{bar()}} or what exactly the problem was.
> Obviously this is is a low priority bug that is in no way blocking anything. But it sure would be helpful if it could be improved one day.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)