You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Feike Visser (JIRA)" <ji...@apache.org> on 2017/03/23 10:28:41 UTC

[jira] [Comment Edited] (SLING-6637) [htl] data-sly-use should not raise an exception when resource doesn't exist

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

Feike Visser edited comment on SLING-6637 at 3/23/17 10:28 AM:
---------------------------------------------------------------

I like to reopen this issue, and like to see if we can log these exceptions (warn or error).
Reason for this is that you have common use-cases where you are 100% sure if the resource exist.


was (Author: fvisser):
I like to reopen this issue, and like to see if we can log these exceptions (warn or error).
Reason for this is that you can common use-cases where you are 100% sure if the resource exist.

> [htl] data-sly-use should not raise an exception when resource doesn't exist
> ----------------------------------------------------------------------------
>
>                 Key: SLING-6637
>                 URL: https://issues.apache.org/jira/browse/SLING-6637
>             Project: Sling
>          Issue Type: Bug
>          Components: Scripting
>            Reporter: Feike Visser
>            Assignee: Radu Cotescu
>
> Following code: 
> {code}
> <sly data-sly-use.x="${ 'x/y/z' }"/>
> {code}
> You get now the following exception:
> {code}
> org.apache.sling.scripting.sightly.SightlyException: No use provider could resolve identifier x/y/z
> {code}
> In practice you want to have a null-value assigned to x, now developers will make a lot of checks to make sure the resource does exist.
> In addition we can log warning message when this happens.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)