[ expat-Bugs-946222 ] error message

"SourceForge.net" <[email protected]>
Newsgroups gmane.text.xml.expat.bugs
Message-ID <[email protected]>
Bugs item #946222, was opened at 2004-05-02 00:02
Message generated for change (Comment added) made by fdrake
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=110127&aid=946222&group_id=10127

Category: None
Group: Feature Request
>Status: Closed
>Resolution: Fixed
Priority: 5
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Karl Waclawek (kwaclaw)
Summary: error message

Initial Comment:
I use tcl tdom that uses the expat lib. I was told that 
the error of xml parsing comes from the expat live
 when there is parsing error I wished the error Info would 
be a bit 
 more informative.
 for example:
  dom parse <test><a><b><c></c></a></test>
 error "mismatched tag" at line 1 character 21
 "test><a><b><c></c></a <--Error-- ></test>"
 
 will be better if it was like microsoft explorer error:
 
 End tag 'a' does not match the start tag 'b'. Error 
rocessing 
 resource 'file:///C:/Documents and 
 Settings/Administrator/Desktop/test.xml'. Line 1, 
Position 22 
 
 <test><a><b><c></c></a></test>
 ---------------------^
 you can know immediatly that tag b was not closed.



----------------------------------------------------------------------

>Comment By: Fred L. Drake, Jr. (fdrake)
Date: 2004-07-15 19:35

Message:
Logged In: YES 
user_id=3066

This is good.  I've updated the unit tests to reflect the
new error codes where applicable.

----------------------------------------------------------------------

Comment By: Karl Waclawek (kwaclaw)
Date: 2004-05-18 09:56

Message:
Logged In: YES 
user_id=290026

Committed additional error codes and messages.
See expat.h rev. 1.69 and xmlparse.c rev. 1.134.

----------------------------------------------------------------------

Comment By: Karl Waclawek (kwaclaw)
Date: 2004-05-02 13:51

Message:
Logged In: YES 
user_id=290026

The attached patch MoreErrors.diff (against current CVS)
adds a few more error codes in place of the generic
XML_ERROR_SYNTAX.

I leave this issue open for review before committing the
patch. Fred, please have a look as well.

----------------------------------------------------------------------

Comment By: Karl Waclawek (kwaclaw)
Date: 2004-05-02 08:31

Message:
Logged In: YES 
user_id=290026

In principle you are correct, the error messages, and more so, 
the error codes, in Expat are not informative enough. Often
you just get a syntax error.

In this case, however, I would say the message is quite clear.

Nevertheless, the really correct way for an application would
be to just use the error code and generate a localized and/or
application specific error message based on this code.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=110127&aid=946222&group_id=10127
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.