You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2006/03/08 19:33:01 UTC
DO NOT REPLY [Bug 38897] New: - Invalid TLDs receive cryptic error
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38897>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=38897
Summary: Invalid TLDs receive cryptic error
Product: Tomcat 5
Version: Nightly Build
Platform: Macintosh
OS/Version: Mac OS X 10.4
Status: NEW
Severity: normal
Priority: P3
Component: Jasper
AssignedTo: tomcat-dev@jakarta.apache.org
ReportedBy: awiner@gmail.com
Install a JSP 1.2 TLD that is missing the <tlib-version>. Invalid, yes.
However, all you get is the following stack trace:
org.apache.jasper.JasperException: /components/panelGroup.jspx(6,70) Could not
add one or more tag libraries.
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:39)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:405)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:86)
org.apache.jasper.compiler.JspDocumentParser.parse(JspDocumentParser.java:211)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:196)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:100)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:155)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:303)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
(etc...)
The actual and completely helpful error is swallowed and does not appear in the
log or on the console; its stack trace, from adding (omitting duplicates):
org.apache.jasper.JasperException: Unable to read TLD "META-INF/afu.tld" from
JAR file
"file:/Users/adamwiner/Work/cvs/tomcat5/build/build/webapps/ard/WEB-INF/lib/adf-unified-impl-11-m3-SNAPSHOT.jar":
org.apache.jasper.JasperException: Mandatory TLD element missing or empty:
tlib-version
at
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:50)
at
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407)
at
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:179)
at
org.apache.jasper.compiler.TagLibraryInfoImpl.<init>(TagLibraryInfoImpl.java:181)
at
org.apache.jasper.compiler.JspDocumentParser.getTaglibInfo(JspDocumentParser.java:1260)
at
org.apache.jasper.compiler.JspDocumentParser.startPrefixMapping(JspDocumentParser.java:767)
at
org.apache.xerces.parsers.AbstractSAXParser.startNamespaceMapping(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
at
org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
at
org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher.scanRootElementHook(Unknown
Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown
Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:375)
at
org.apache.jasper.compiler.JspDocumentParser.parse(JspDocumentParser.java:176)
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 38897] - Invalid TLDs receive cryptic error
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38897>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=38897
------- Additional Comments From Michiel.Meeuwissen@gmail.com 2007-08-03 04:38 -------
I think this bug may be fixed in tomcat 6.
I get helpful messages like:
org.apache.jasper.JasperException: File "/META-INF/tags/mm/u/option.tagx" not found
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 38897] - Invalid TLDs receive cryptic error
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38897>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=38897
------- Additional Comments From apache@planetxml.de 2007-08-06 15:14 -------
I had a very similar problem in Tomcat 6.0.13 that was caused by a missing tld
file in my deployment. The stacktrace was the same as in the first comment and
did not indicate which tag library caused the problem. I used the following
patch to track down the problem and log the cause of the exception:
Index: java/org/apache/jasper/compiler/JspDocumentParser.java
===================================================================
--- java/org/apache/jasper/compiler/JspDocumentParser.java (revision
563257)
+++ java/org/apache/jasper/compiler/JspDocumentParser.java (working copy)
@@ -214,7 +214,8 @@
jspDocParser.err.jspError
(new Mark(jspDocParser.ctxt, path, e.getLineNumber(),
e.getColumnNumber()),
- e.getMessage());
+ e.getMessage(),
+ e);
} catch (Exception e) {
jspDocParser.err.jspError(e);
}
Index: java/org/apache/jasper/compiler/ErrorDispatcher.java
===================================================================
--- java/org/apache/jasper/compiler/ErrorDispatcher.java (revision
563257)
+++ java/org/apache/jasper/compiler/ErrorDispatcher.java (working copy)
@@ -225,6 +225,22 @@
* resource bundle for localized error messages, it is used as the error
* message.
*
+ * @param where Error location
+ * @param errCode Error code
+ * @param exception Exception
+ */
+
+ public void jspError(Mark where, String errCode, Exception exception)
+ throws JasperException {
+ dispatch(where, errCode, null, exception);
+ }
+ /*
+ * Dispatches the given JSP parse error to the configured error handler.
+ *
+ * The given error code is localized. If it is not found in the
+ * resource bundle for localized error messages, it is used as the error
+ * message.
+ *
* @param n Node that caused the error
* @param errCode Error code
* @param arg1 First argument for parametric replacement
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 38897] - Invalid TLDs receive cryptic error
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38897>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=38897
------- Additional Comments From awiner@gmail.com 2006-06-15 19:39 -------
I rebuilt a version of Tomcat and added a printStackTrace() to at least see the buried message.
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 38897] - Invalid TLDs receive cryptic error
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38897>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=38897
Michiel.Meeuwissen@gmail.com changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |Michiel.Meeuwissen@gmail.com
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 38897] - Invalid TLDs receive cryptic error
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38897>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=38897
------- Additional Comments From yoavs@computer.org 2006-06-15 19:52 -------
Where did you add that printStackTrace call?
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 38897] - Invalid TLDs receive cryptic error
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38897>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=38897
------- Additional Comments From awiner@gmail.com 2006-06-15 20:25 -------
I don't remember, to be honest - this was three months ago. I'd guess DefaultErrorHandler.jspError(), but
that's just a guess.
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 38897] - Invalid TLDs receive cryptic error
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38897>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=38897
yoavs@computer.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |NEEDINFO
------- Additional Comments From yoavs@computer.org 2006-06-15 19:26 -------
So where did you get the useful error text from?
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org