[
https://issues.apache.org/jira/browse/COCOON-1978?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12526587
]
Grzegorz Kossakowski commented on COCOON-1978:
----------------------------------------------
Simone, can you test if this issue is still present? I've been debugging JEXL
many times lately so I know internals of JEXL quite well and maybe could do
something with it.
> JXTemplate often fail a method call without giving any error
> ------------------------------------------------------------
>
> Key: COCOON-1978
> URL: https://issues.apache.org/jira/browse/COCOON-1978
> Project: Cocoon
> Issue Type: Bug
> Components: Blocks: Templating
> Affects Versions: 2.2-dev (Current SVN)
> Reporter: Simone Gianni
>
> When calling a method on an instance in JXTemplate, if that method does not
> exist (or JX cannot find the proper method based on parameters), it fails
> without any error. IMO it should raise an error, or at least should raise it
> in dev mode, because not having a debugger it takes hours to figure out why
> it's not working.
> As an example, take a JX and try to call a method that does not exist :
> <jx:set var="any"
> value="${obj.getSomethingThatDoesNotExist(cocoon.request)}"/>
> Any will simply be null. Moreover, even if "any" is then used :
> ${any.getSomethingElse()}
> Again it will fail without any error, resulting simply in an empty string,
> making it even harder.
> Being a non compiled language already makes it difficult to make sure calls
> are correct, having this "silent fail" behavior makes it even harder, and if
> you add also the non typized nature it can make it a nightmare.
> Anyway, I don't know if there is a way to fix this in cocoon or if it is a
> Jexl design problem.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.