facebook

Errors in taglibs not underlined [Closed]

  1. MyEclipse IDE
  2.  > 
  3. General Development
Viewing 15 posts - 1 through 15 (of 30 total)
  • Author
    Posts
  • #216055 Reply

    Terry Roe
    Member

    Invalid JSP tag attributes used to be shown in bold red at some point in the past. I distinctly remember seeing MyEclipse work this way. However, I haven’t seen this functionality since the Beta versions of 3.8. Has it been removed? Is there some place I can configure or reenable it? (With all the installs, uninstalls, reinstalls required with the recent releases, I’m not sure if I had to enable it manually or it came that way “out of the box”.)

    I did notice on Windows->Prferences->Workbench->Editors->Annotaction page that all the “Highlight in text” options for MyEclipse are disabled. Perhaps this is what used to be used to show invalid tags in bold red?

    Also, I am using Struts 1.2.4. Could this be what is causing this functionality to not work? Are there any configuration changes I should make other than changing the DTD in struts-config.xml? (I’ve installed the jars and dtds.)

    Thanks for your help.

    TR

    #216072 Reply

    Riyad Kalla
    Member

    TR,
    This changed after 3.8.0 Beta when all of our editors were completely replaced. If you turn on annotations then unknown tags will likely be underlined with a yellow squiggle, this is the new behavior.

    #216076 Reply

    Scott Anderson
    Participant

    Actually, this particular error isn’t detected by the reconciler, but when JSP validation is turned on it will be flagged as an error when the file is validated.

    #216085 Reply

    Terry Roe
    Member

    Scott,

    Yes, this is the behavior I’m seeing. However, it would be very useful if the error were highlighted in the text somehow. Right now, I get a red X in the left column, a red square in the right column, but nothing in the text that points to the actual error. So, I have to hover over the red X or square in order to get popup help that points me to the problem. Is there any way to configure this so I can get an indication in the text? Or is this supposed to be working and it’s just not working for me? I have enabled all the options for MyEclipse annotations.

    I get yellow squiggles for HTML validation warnings/errors, though when hovering over the actual error in the code I don’t get popup help on the error, but a description of the tag. In order to find out what the actual error is, I have to go to the right margin and hover. Unfortunately, I have inherited code with a lot of badly formed HTML. So it is very difficult to match the error popup message with the actual problem in the text.

    I get red squiggles for Java scriptlet errors, and I do get a description of the error when I hover over the problem code in the text.

    Obvioulsy, there is no popup error text when I hover over the unknown tags. I would at least like an indication in the text of where the error is in these cases, if possible.

    Do you need any further information to look into this?

    Thanks,

    TR

    #216089 Reply

    Riyad Kalla
    Member

    Is there any way to configure this so I can get an indication in the text? Or is this supposed to be working and it’s just not working for me? I have enabled all the options for MyEclipse annotations.

    Do you mean items in your problem view? Anything shown in your LEFT margin should be in your problems view, please click the little down arrow in your problems view then “Filters…” and make sure ALL the filters are selected (Select All), then hit OK… they should be shown now.

    I get yellow squiggles for HTML validation warnings/errors, though when hovering over the actual error in the code I don’t get popup help on the error, but a description of the tag.

    I believe this is on purpose because as a lot of people are finding out, common HTML practice can turn out to be completely wrong according to HTML spec so we didn’t want to completely litter the code with useless popups. You can probably safely turn off HTML validation to get rid of all this ‘clutter’ until you are able to get the rest of the code cleaned up.

    Unfortunately, I have inherited code with a lot of badly formed HTML. So it is very difficult to match the error popup message with the actual problem in the text.

    I see your point…

    #216099 Reply

    Terry Roe
    Member

    Riyad,

    [I can’t seem to succesfully quote your text, so I hope the following will suffice.]

    Quote one: I never mentioned the Problems view. I do not have any issues with it. The issue is that there is no indication in the JSP editor when there is an unknown tag. I have enabled everything in the Annotations for MyEclipse as well as the other Error/Warning annotations for Java files. I only get a red X in the left margin and a red square in the right margin when there is an unknown tag. There is no indication in the text area when there is an unknown tag error.

    Quote two: I understand that there may be a lot of popups in the HTML code for HTML validation. However, I think this should be configurable if one desires to have them. One would hope to continually reduce the the number of HTML validation errors if one wants to write valid HTML code. Having a near solid yellow right margin is not of much use when trying to match the error with the offending markup.

    TR

    #216102 Reply

    Riyad Kalla
    Member

    TR,
    w.r.t. to the unknown tag, this is what happened on a fresh Eclipse 3.0.1 install with a fresh MyEclipse 3.8.2 install for me:

    Are you not seeing this behavior?

    #216110 Reply

    Terry Roe
    Member

    Yes, I get the popup as you described just above.

    Sorry, I lost track of my terminology. What I meant is that I don’t get the error indication in the source, nor a popup, for unknown tag “attributes”.

    TR

    #216125 Reply

    Riyad Kalla
    Member

    What I meant is that I don’t get the error indication in the source, nor a popup, for unknown tag “attributes”.

    Oh I see, is this what you are talking about? (I will file it if it is)

    #216129 Reply

    Terry Roe
    Member

    Riyad,

    Now you’ve got it. In the “old” editor, the tag named “ham” would appear in bold red in the text of the editor. It was blatantly obvious you had a bad attribute. With Eclipse Annotations, you can configure errors to show up with a little squiggly underline. You can also select “Highlight in text” which will use the color selected for the background color of the text that has the errors. (I’d prefer a little more control, but that’s the way Eclipse works right now.) At minimum, I’d like to be able to get the squiggly, or some indication of any kind, within the text indicating the bad attribute(s). As it stands now, I have to go hover over one of the error indicators to see which attribute is bad. Almost anything would be better than nothing, in this case.

    TR

    #216130 Reply

    Scott Anderson
    Participant

    I have to go hover over one of the error indicators to see which attribute is bad.

    Or look in the problems view, as shown in Riyad’s screenshot.

    #216132 Reply

    Terry Roe
    Member

    Scott,

    I do appreciate the various options. But the point is that there should be an indication in the source itself. At least, that’s what I would expect given the way things work elsewhere both in Eclipse and MyEclipse.

    TR

    #216133 Reply

    Scott Anderson
    Participant

    I appreciate that, but there is a limit to the amount of things that can be found during real-time reconciliation versus compile time validation.
    Take the Java editor for instance. It doesn’t give you a reconciler warning every time a synthetic accessor method will be generated since
    a private variable is used by an inner class. You only see those after you save and compile. It’s the same here. The reconciler can’t catch
    everything that a full compilation can.

    #216138 Reply

    Terry Roe
    Member

    Scott,

    I’m not talking about real time indicators (thought that would be nice). There is no inidication in the source at all even after the page is saved/compiled. There are indicators in the margins and the problems view. There should also be an indication in the source indicating where in the line the error has occurred. If you look back at Riyad’s post at 9:01, youll see what I’m talking about. The tag attribute ‘ham=”blah”‘ should be underlined with a squiggly line indicating it is the casue of the problem. That’s how it works with all the other errors/warnings in Eclipse/MyEclipse.

    TR

    TR

    #216139 Reply

    Scott Anderson
    Participant

    ‘ham=”blah”‘ should be underlined with a squiggly line indicating it is the casue of the problem. That’s how it works with all the other errors/warnings

    The squigglys are caused by the editor’s reconciler, while the left margin errors / warnings are caused by compilation / validation. They’re different processes and are each
    capable of flagging different kinds of errors, just as in the Java editor example I gave you above.

Viewing 15 posts - 1 through 15 (of 30 total)
Reply To: Errors in taglibs not underlined [Closed]

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