facebook

EL expression does not evaluate to expected types for this a

  1. MyEclipse Archived
  2.  > 
  3. Bugs
Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #254375 Reply

    svadu
    Member

    I have the following JSF code:

    <h:form id=”hiddenForm”>
    <h:panelGroup id=”hiddenPanel”>
    <h:inputHidden id=”a” value=”#{handler.found[0].a}” />
    <h:inputHidden id=”b” value=”#{handler.found[0].b}” />
    <h:inputHidden id=”memo” value=”memo: #{handler.found[0].memo}” />
    </h:panelGroup>
    </h:form>

    For fields like <h:inputHidden id=”a” value=”#{handler.found[0].a}” /> (that is where attribure value has only el expression and no other text) I have the following errors: “EL expression does not evaluate to expected types for this attribute” the other field which has regular text like <h:inputHidden id=”memo” value=”memo: #{handler.found[0].memo}” /> doesn’t have this problem. As soon as I enter any text in from of the el expression I get that error.

    This started happening when I upgraded to MyEclipse 5.0M2.

    #254406 Reply

    Riyad Kalla
    Member

    The EL support and validation isn’t quite complete yet, I am sending your report ot the dev team.

    #254414 Reply

    @svadu wrote:

    I have the following JSF code:

    <h:form id=”hiddenForm”>
    <h:panelGroup id=”hiddenPanel”>
    <h:inputHidden id=”a” value=”#{handler.found[0].a}” />
    <h:inputHidden id=”b” value=”#{handler.found[0].b}” />
    <h:inputHidden id=”memo” value=”memo: #{handler.found[0].memo}” />
    </h:panelGroup>
    </h:form>

    For fields like <h:inputHidden id=”a” value=”#{handler.found[0].a}” /> (that is where attribure value has only el expression and no other text) I have the following errors: “EL expression does not evaluate to expected types for this attribute” the other field which has regular text like <h:inputHidden id=”memo” value=”memo: #{handler.found[0].memo}” /> doesn’t have this problem. As soon as I enter any text in from of the el expression I get that error.

    This started happening when I upgraded to MyEclipse 5.0M2.

    That kind of messages should be treated as warnings – it mistakenly got classified as errors (we have a bug in bugtracker on that). JSF EL validator is not aware of the convertors so it expects the values to be String, boolean, etc. depending on controls. Please consider those messages warnings, we will update this behavior in the next releases.

    #254443 Reply

    svadu
    Member

    Why does it even have to give warning on perfectly valid expressions? The specified method of the backing bean does return String so not even warning should be displayed.

    I am saying this because I am trying to keep number of warnings to 0 and having warnings on fine expressions a bit confuses andmakes it difficult to keep repository clean.

    I hope I didn’t misunderstand anything…

    #254498 Reply

    @svadu wrote:

    Why does it even have to give warning on perfectly valid expressions? The specified method of the backing bean does return String so not even warning should be displayed.

    I am saying this because I am trying to keep number of warnings to 0 and having warnings on fine expressions a bit confuses andmakes it difficult to keep repository clean.

    I hope I didn’t misunderstand anything…

    I have never seen it to mark string exceptions as errors – I will test that.
    On non-string values it returns warnings as you need a configured converter to convert that value.

    I’m really sorry for this validator behaviour – we spotted it too late in the cycle and had to either ship it with this problem or not ship it at all. We will fix these issues in upcoming releases.

    #254528 Reply

    Scott Anderson
    Participant

    As a temporary workaround, the EL validator can be turned off at the project level (under Properties > MyEclipse-Validation) or at the workspace level at Preferences > MyEclipse > Validation.

    Thanks again for reporting this so we’re aware of the full scope of the issue and can address it for the GA release in early August.

    #254540 Reply

    svadu
    Member

    I tried that, unfortunately the setting did not seem to work (on both workbench and project level even after forcing validation via MyEclipse->Validate All).

    Could someone have a look at this problem as well? I tried to disable EL Validation and JSF validation.

    Thanks

    #254558 Reply

    Riyad Kalla
    Member

    Try running Project > Clean after disabling validation, sometimes that is required to clear the old warnings.

    #254672 Reply

    svadu
    Member

    It seems to be like it helped.

    Thanks

    #274755 Reply

    Shashi Solipuram
    Participant

    Version 6.0 did not resolve this issue:
    EL expression does not evaluate to expected types for this attribute

    @support-scott wrote:

    As a temporary workaround, the EL validator can be turned off at the project level (under Properties > MyEclipse-Validation) or at the workspace level at Preferences > MyEclipse > Validation.

    Thanks again for reporting this so we’re aware of the full scope of the issue and can address it for the GA release in early August.

    #274779 Reply

    Riyad Kalla
    Member

    ACR,
    Do you have an example page that I can use for testing?

    #274790 Reply

    Shashi Solipuram
    Participant

    @support-rkalla wrote:

    ACR,
    Do you have an example page that I can use for testing?

    I do not have problem running the page.

    El expression errors:

    We are using Sun JSF and we get the error messages only in IDE for JSP page where ever it is referencing JSF tags like below:

    <h:commandButton value=”Correct Form” action=”#{confirmFormReg.correctFormAction}” image=”../images/correctForm.png” onmouseover=”src =’../images/mCorrectForm.png'” onmouseout=”src =’../images/correctForm.png'”/>

    #274793 Reply

    Riyad Kalla
    Member

    ACR I am going to file the bug for the devs to look into it.

Viewing 13 posts - 1 through 13 (of 13 total)
Reply To: EL expression does not evaluate to expected types for this a

You must be logged in to post in the forum log in