- This topic has 17 replies, 6 voices, and was last updated 19 years, 6 months ago by Ashutosh Jindal.
-
AuthorPosts
-
bilbothebagginsMemberHi there.
I have set up MyEclipse 3.8.4 with eclipse 3.0.2Though the JSP Editor will underline any syntax error. when the project is built, no errors appear in the problems tab!
Java errors are reported just fine.The JSP validation setting is [on].
HTML validation is off.
The webroot folder is the same as the project folder.So … what have I missed ??
best regards,
Martin
bilbothebagginsMember… after futher searching I have found that the validation seems to be done — the validation markers are in place at the side of the editor, and mouseOver reports the actual error.
The errors & warnings just don’t get reported to the Problems Tab.
Any ideas ?
Riyad KallaMemberMatrin,
This is a quick fix, what you need is to have javac.exe in your system’s PATH environment variable, that is what MyEclipse uses to validate the JSP pages.
bilbothebagginsMemberHi.
I _have_ javac on my PATH. (Also note that the Validation seems to be done in the editor (err+warn markers with mouseOver error-description)
The errors are just not reported to the problems page, and if I validate the jsp I get: “The JSP File is valid.”To summarize:
– JSP error don’t get reported to the problem page, but are displayed in the editor.
– <Validate> will not report errors
* I have javac on my Path (…/sun/appserver/jdk/bin)
* the vm I use is 1.5.0_02 (-vm …\Sun\AppServer\jdk\bin\javaw )
* JSP Validation is on
* the .log file in the workspace does not contain any errors.Sorry – should’ve posted the detailed Info sooner 🙂
hope this sheds more light on this,
best regards,
Martin– System Setup ——————————-
Operating System and version: Win2000 sp4
Eclipse version: 3.0.2
Eclipse build id: 200503110845
Fresh Eclipse install (y/n): y
Number of plugins in the <eclipse>/plugins directory that begin with org.eclipse.pde.*: 8
MyEclipse version: 3.8.4
Eclipse JDK version: 1.5.0_02
Application Server JDK version: 1.5.0_02
Are there any exceptions in the Eclipse log file?
Scott AndersonParticipantI _have_ javac on my PATH. (Also note that the Validation seems to be done in the editor (err+warn markers with mouseOver error-description)
Actually, the realtime validation reported in the right margin is done a different way than the error validation done through compilation. So, it’s not unusual to have one work and the other not if there’s a configuration issue.
One thing to try, can you run Eclipse with a 1.4.2 JDK and place the path to it on your path? Eclipse 3.0 is not certified to work on JDK 1.5 and MyEclipse 3.8.4 wasn’t tested on it either as a result. This could easily be the cause of the issue as we’ve seen JDK 1.5 problems with both Eclipse itself and MyEclipse in the past.
bilbothebagginsMember… hmm … I’ve tried to start Eclipse with all 4 ‘javas’ I have on my machine.
i.e. the ones from the appserver SDK/JRE and the ones from the installed 1.4.2 JDK.
No difference.
No validation errors for the jsps. Nothing in the .log file.Are there any settings I may have missed for the jsp validation /editor?
best regards,
Martin
Scott AndersonParticipant.. hmm … I’ve tried to start Eclipse with all 4 ‘javas’ I have on my machine.
OK, but did you change the path to place each of those instances jdk\bin and jdk\jre\bin directories on the front of the path as well?
Are there any settings I may have missed for the jsp validation /editor?
With no errors in the log it sure sounds like it might be likely. The settings for the workspace are at Window > Preferences > MyEclipse > Validation. And, each project can override those settings at Properties > MyEclipse-Validation.
Also, in the Problems tab, can you open the preferences and verify that you’ve selected that you want to see all MyEclipse problems? The Problems view might be set to filter them out, which would explain the issue you’re seeing as well. The options are available from the Problem View’s toolbar.
bilbothebagginsMemberHi all.
I have done a reinstall, putting everything right, but the validation will still not work.
I use java 1.4.2_07 and the 1.4.2 javac is on my PATH.*) When I create a new WebProject and put a new JSP file there, this will validate _correctly_.
*) The existing webapplication … jsp validation does _not_ work. (also not for new JSP files I may create there)
*) Java will validate correctly.-) I have quit MyEclipse, cleared the .log file and restarted MyEclipse: Nothing will be written in the .log file.
— The webprojects continains some .jsp files and a few java classes for taglib. The webRoot is specified to “/”. The build path contains an additional ojdbc.jar.
So … any (more 🙂 ideas what could cause this non-validation, since it seems to be specific to this project …
thanks,
best regards,
Martin
Scott AndersonParticipantMartin,
So … any (more 🙂 ideas what could cause this non-validation, since it seems to be specific to this project …
First, I assume you haven’t overridden the validation settings just for that project at Properites > MyEclipse-Validation? Since we do allow you to do that, it’s something to check.
If that’s not the case, can you create a new web project and copy your existing project’s contents into it and see if that validates properly? It seems you have a proper configuration, since other projects work, and that this project has somehow “gone bad”, for whatever reason. Creating a new project and copying over your content will allow us to see if the problem is project related or content related.
bilbothebagginsMemberHello.
I have now found out what causes the non-validation.
The Project contains a file tagPlugins.xml … when I remove this file from the WEB-INF directory, the validation / problems tab will work as expected.Now I’m not very deep into the whole webapp stuff … so maybe this is needed, maybe not. ❓
thanks for your help!
best regards,
MartintagPlugins.xml:
<tag-plugins> <tag-plugin> <tag-class>org.apache.taglibs.standard.tag.rt.core.IfTag</tag-class> <plugin-class>org.apache.jasper.tagplugins.jstl.If</plugin-class> </tag-plugin> <tag-plugin> <tag-class>org.apache.taglibs.standard.tag.common.core.ChooseTag</tag-class> <plugin-class>org.apache.jasper.tagplugins.jstl.Choose</plugin-class> </tag-plugin> <tag-plugin> <tag-class>org.apache.taglibs.standard.tag.rt.core.WhenTag</tag-class> <plugin-class>org.apache.jasper.tagplugins.jstl.When</plugin-class> </tag-plugin> <tag-plugin> <tag-class>org.apache.taglibs.standard.tag.common.core.OtherwiseTag</tag-class> <plugin-class>org.apache.jasper.tagplugins.jstl.Otherwise</plugin-class> </tag-plugin> <tag-plugin> <tag-class>org.apache.taglibs.standard.tag.rt.core.ForEachTag</tag-class> <plugin-class>org.apache.jasper.tagplugins.jstl.ForEach</plugin-class> </tag-plugin> </tag-plugins>
Riyad KallaMemberMartin,
I just tried to reproduce this with our 4.0 Milestone 1 build and the good news is that validation still works just fine, so maybe this was a flaky bug that got fixed during our development cycle. 4.0 should fix this for you (we haven’t done our GA release yet, we are shooting for another couple of weeks of testing and stabalizing).
bilbothebagginsMemberSounds good.
Thanks,
best regards,
Martin
fkalichMemberI was having the problem as described above. At least I thought I was. On closer inspection I found that validation does occur on methods, method signatures, fields.
However it does not check for valid object names. For example I can enter:
asdfasua = adfasdf;
And the validator is happy with that. I am using myeclipse 3.1 and jre 1.5.0_03.
Perhaps this is a ‘tag thing’, i.e. the validator cannot be sure that the reference is in a tag so it allows bogus object names?
frank kalich
lawrence kansas
Riyad KallaMemberLawrence, this is a sign that “javac” is not in your system path and the validator is unable to find it to valid (for real) the pages. Can you double check that it is? Also there is a validator bug that doesn’t show errors until the files are “built” that will be fixed in milestone 3.
fkalichMemberrkalla: Hi, this is frank. Lawrence is the name of my town. But to the point.
Thanks for your response. I read what you said. I am running myeclipse on Windows XP.
1) I put javac in my system path. I know it is there now because it will run from a dos screen with the command ‘javac’. It had not been in the path before. However this did not change things on eclipse.
2) Then I tried setting my jre to the sdk directory in eclipse. There is a jre in that directory. I never fully understood what sun was doing there, just thought that jre was a virtual machine without all the development features. However eclipse says to set the jre, not the sdk. I am not sure how eclipes compiles, considering that, however that is a different question. But nothing changed when I set the prefererece compiler to the sdk directory.
However now it seems that the methods and fields are no longer validated for jsp. I set the jre back to what it had been set to (the jre directory that is created when java is installed.
I am almost sure that what happened was:
1) A few days ago, nothing was being validated in jsp pages.
2) I built a new project, and then the class fields and methods were being validated. However it was not checking for ‘bogus’ object names.
3) Now I am back to where I was before, nothing is validatated again for jsp pages.Servlets and Java Beans validate just fine though. Thanks again! If anything I said made sense to you and you have a suggestion, I appreciate. I know this stuff is hard to figure. If I find out more I will post it.
I am not complaining about myeclipse. I love using it, it is a real bargain!
frank
-
AuthorPosts