You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Jim Moore <ji...@veritas.com> on 2001/10/03 20:17:17 UTC

log4j.dtd Line=3: Element type "log4j:configuration" is not decla red

When I try to run a test under ant 1.4 I get the following error regarding
log4j 1.1.  It does in fact log, but what's with all the errors?


    [junit] Warning: validation was turned on but an
org.xml.sax.ErrorHandler wa
s not
    [junit] set, which is probably not what is desired.  Parser will use a
defau
lt
    [junit] ErrorHandler to print the first 10 errors.  Please call
    [junit] the 'setErrorHandler' method to fix this.
    [junit] Error:
URI=jar:file:/C:/src/titan3_8/common/lib/log4j.jar!/org/apach
e/log4j/xml/log4j.dtd Line=3: Element type "log4j:configuration" is not
declared
.
    [junit] Error:
URI=jar:file:/C:/src/titan3_8/common/lib/log4j.jar!/org/apach
e/log4j/xml/log4j.dtd Line=3: Attribute "xmlns:log4j" is not declared for
elemen
t "log4j:configuration".
    [junit] Error:
URI=jar:file:/C:/src/titan3_8/common/lib/log4j.jar!/org/apach
e/log4j/xml/log4j.dtd Line=4: Element type "root" is not declared.
    [junit] Error:
URI=jar:file:/C:/src/titan3_8/common/lib/log4j.jar!/org/apach
e/log4j/xml/log4j.dtd Line=4: Attribute "class" is not declared for element
"roo
t".
    [junit] Error:
URI=jar:file:/C:/src/titan3_8/common/lib/log4j.jar!/org/apach
e/log4j/xml/log4j.dtd Line=5: Element type "priority" is not declared.
    [junit] Error:
URI=jar:file:/C:/src/titan3_8/common/lib/log4j.jar!/org/apach
e/log4j/xml/log4j.dtd Line=5: Attribute "value" is not declared for element
"pri
ority".
    [junit] Error:
URI=jar:file:/C:/src/titan3_8/common/lib/log4j.jar!/org/apach
e/log4j/xml/log4j.dtd Line=6: Element type "appender-ref" is not declared.
    [junit] Error:
URI=jar:file:/C:/src/titan3_8/common/lib/log4j.jar!/org/apach
e/log4j/xml/log4j.dtd Line=6: Attribute "ref" is not declared for element
"appen
der-ref".
    [junit] Error:
URI=jar:file:/C:/src/titan3_8/common/lib/log4j.jar!/org/apach
e/log4j/xml/log4j.dtd Line=7: Attribute "ref" is not declared for element
"appen
der-ref".
    [junit] Error:
URI=jar:file:/C:/src/titan3_8/common/lib/log4j.jar!/org/apach
e/log4j/xml/log4j.dtd Line=12: Element type "category" is not declared.
    [junit] log4j:ERROR No appenders could be found for category (root).
    [junit] log4j:ERROR Please initialize the log4j system properly.

I looked at the DTD and those elements are defined.  Any ideas?

-Jim Moore

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: log4j-user-help@jakarta.apache.org


RE: log4j.dtd Line=3: Element type "log4j:configuration" is not declared

Posted by Mark Masterson <ma...@compuserve.com>.
Jim,

I've gotten this one recently.  I discovered that I had some stuff in my
class path that included older copies of XML parsers (Crimson, for example).
When I cleaned up the class path, so I was sure which parser was loading and
which version, this went away...


---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: log4j-user-help@jakarta.apache.org