data-sly-call: expression evaluates to null | Community
Skip to main content
amrit1993
Level 3
Mar 7, 2017 10:41 AM UTC
Solved

data-sly-call: expression evaluates to null

Hi all,

After migrating from 6.0 to 6.2 we are facing issues in opening some pages. They are being opened with an error:

Error during include of component '/apps/xyz/components/page/groupsmapping'

Error Message:

org.apache.sling.api.scripting.ScriptEvaluationException: org.apache.sling.scripting.sightly.SightlyException: data-sly-call: expression evaluates to null

Below is the HTML for it

groupsmapping.html:

 


    <head data-sly-use.clientLib="${'/apps/acs-commons/sightly/templates/dhlm.html'}"  data-sly-use.clientLib="${'/libs/granite/sightly/templates/clientlib.html'}">
        <div data-sly-include="/libs/wcm/core/components/init/init.jsp" data-sly-unwrap></div>
        <style data-sly-call="${clientLib.head @ mode='all'}" data-sly-unwrap></style>
        <style data-sly-call="${xyz.vendor @ mode='all'}" data-sly-unwrap></style>
    </head>
    <body>

        <div data-sly-resource="${ @path='groupsmapping', resourceType='xyz/components/content/groupsmappingconfig'}" data-sly-unwrap></div>
    </body>
</html>

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
amrit1993
amrit1993Accepted solution
Level 3
Mar 10, 2017 1:55 PM UTC

I just commented out the data-sly-call tags and the pages started rendering. Need to debug more for root cause.

13 replies

Feike_Visser1
Employee
Mar 8, 2017 7:53 AM UTC

Can you create a sample so we can help you further?

Translate
Level 2
Mar 7, 2017 4:22 PM UTC

Hello,

We also had similar issues going from 6.1 to 6.2. The issue was with some of our custom components / views, and the dev team had to update their code package to be compatible. Only pages using specific components or views had the issue. I would recommend turning on additional logging if the existing logs don't have enough detail to know which component / view is causing the issue, or you can't narrow it down otherwise. 

Andrew

Translate
Feike_Visser1
Employee
Mar 7, 2017 11:28 AM UTC

I see twice a declaration of 'clientLib', but no declaration for 'xyz' or 'dhlm'

Translate